@gientech/modual 2.1.19 → 2.1.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/chat.js +8 -8
- package/package.json +1 -1
package/chat.js
CHANGED
|
@@ -176,7 +176,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
176
176
|
0 -6px 16px 0 rgba(0, 0, 0, 0.08),
|
|
177
177
|
0 -3px 6px -4px rgba(0, 0, 0, 0.12),
|
|
178
178
|
0 -9px 28px 8px rgba(0, 0, 0, 0.05)
|
|
179
|
-
`,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)"}),r)}var M3=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const rI={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},lG={motionBase:!0,motionUnit:!0},cG={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},oI=(e,t,n)=>{const r=n.getDerivativeToken(e),{override:o}=t,i=M3(t,["override"]);let a=Object.assign(Object.assign({},r),{override:o});return a=nI(a),i&&Object.entries(i).forEach(([s,l])=>{const{theme:c}=l,u=M3(l,["theme"]);let d=u;c&&(d=oI(Object.assign(Object.assign({},a),u),{override:u},c)),a[s]=d}),a};function ii(){const{token:e,hashed:t,theme:n,override:r,cssVar:o}=we.useContext(ZP),i=`${aG}-${t||""}`,a=n||KP,[s,l,c]=H4(a,[Qu,e],{salt:i,override:r,getComputedToken:oI,formatToken:nI,cssVar:o&&{prefix:o.prefix,key:o.key,unitless:rI,ignore:lG,preserve:cG}});return[a,c,t?l:"",s,o]}const c0={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},br=(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}),kd=()=>({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"}}),uG=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),dG=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"}}}),fG=(e,t,n,r)=>{const o=`[class^="${t}"], [class*=" ${t}"]`,i=n?`.${n}`:o,a={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let s={};return r!==!1&&(s={fontFamily:e.fontFamily,fontSize:e.fontSize}),{[i]:Object.assign(Object.assign(Object.assign({},s),a),{[o]:a})}},FC=(e,t)=>({outline:`${Ce(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),iI=(e,t)=>({"&:focus-visible":FC(e)}),aI=e=>({[`.${e}`]:Object.assign(Object.assign({},kd()),{[`.${e} .${e}-icon`]:{display:"block"}})}),{genStyleHooks:Pr,genComponentStyleHook:hG,genSubStyleComponent:vp}=iG({usePrefix:()=>{const{getPrefixCls:e,iconPrefixCls:t}=pr(pn);return{rootPrefixCls:e(),iconPrefixCls:t}},useToken:()=>{const[e,t,n,r,o]=ii();return{theme:e,realToken:t,hashId:n,token:r,cssVar:o}},useCSP:()=>{const{csp:e}=pr(pn);return e??{}},getResetStyles:(e,t)=>{var n;const r=dG(e);return[r,{"&":r},aI((n=t==null?void 0:t.prefix.iconPrefixCls)!==null&&n!==void 0?n:mp)]},getCommonStyle:fG,getCompUnitless:()=>rI});function yp(e,t){return Js.reduce((n,r)=>{const o=e[`${r}1`],i=e[`${r}3`],a=e[`${r}6`],s=e[`${r}7`];return Object.assign(Object.assign({},n),t(r,{lightColor:o,lightBorderColor:i,darkColor:a,textColor:s}))},{})}const pG=(e,t)=>{const[n,r]=ii();return t2({token:r,hashId:"",path:["ant-design-icons",e],nonce:()=>t==null?void 0:t.nonce,layer:{name:"antd"}},()=>aI(e))},gG=Object.assign({},C),{useId:N3}=gG,mG=()=>"",vG=typeof N3>"u"?mG:N3;function yG(e,t,n){var r;gp();const o=e||{},i=o.inherit===!1||!t?Object.assign(Object.assign({},p2),{hashed:(r=t==null?void 0:t.hashed)!==null&&r!==void 0?r:p2.hashed,cssVar:t==null?void 0:t.cssVar}):t,a=vG();return up(()=>{var s,l;if(!e)return t;const c=Object.assign({},i.components);Object.keys(e.components||{}).forEach(f=>{c[f]=Object.assign(Object.assign({},c[f]),e.components[f])});const u=`css-var-${a.replace(/:/g,"")}`,d=((s=o.cssVar)!==null&&s!==void 0?s:i.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:n==null?void 0:n.prefixCls},typeof i.cssVar=="object"?i.cssVar:{}),typeof o.cssVar=="object"?o.cssVar:{}),{key:typeof o.cssVar=="object"&&((l=o.cssVar)===null||l===void 0?void 0:l.key)||u});return Object.assign(Object.assign(Object.assign({},i),o),{token:Object.assign(Object.assign({},i.token),o.token),components:c,cssVar:d})},[o,i],(s,l)=>s.some((c,u)=>{const d=l[u];return!a0(c,d,!0)}))}var bG=["children"],sI=C.createContext({});function xG(e){var t=e.children,n=tn(e,bG);return C.createElement(sI.Provider,{value:n},t)}var EG=(function(e){ds(n,e);var t=fs(n);function n(){return xr(this,n),t.apply(this,arguments)}return Er(n,[{key:"render",value:function(){return this.props.children}}]),n})(C.Component);function wG(e){var t=C.useReducer(function(s){return s+1},0),n=te(t,2),r=n[1],o=C.useRef(e),i=cn(function(){return o.current}),a=cn(function(s){o.current=typeof s=="function"?s(o.current):s,r()});return[i,a]}var Fa="none",Kd="appear",Zd="enter",Qd="leave",D3="none",vi="prepare",Kl="start",Zl="active",PC="end",lI="prepared";function T3(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit".concat(e)]="webkit".concat(t),n["Moz".concat(e)]="moz".concat(t),n["ms".concat(e)]="MS".concat(t),n["O".concat(e)]="o".concat(t.toLowerCase()),n}function CG(e,t){var n={animationend:T3("Animation","AnimationEnd"),transitionend:T3("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete n.animationend.animation,"TransitionEvent"in t||delete n.transitionend.transition),n}var kG=CG($o(),typeof window<"u"?window:{}),cI={};if($o()){var SG=document.createElement("div");cI=SG.style}var Jd={};function uI(e){if(Jd[e])return Jd[e];var t=kG[e];if(t)for(var n=Object.keys(t),r=n.length,o=0;o<r;o+=1){var i=n[o];if(Object.prototype.hasOwnProperty.call(t,i)&&i in cI)return Jd[e]=t[i],Jd[e]}return""}var dI=uI("animationend"),fI=uI("transitionend"),hI=!!(dI&&fI),F3=dI||"animationend",P3=fI||"transitionend";function I3(e,t){if(!e)return null;if(At(e)==="object"){var n=t.replace(/-\w/g,function(r){return r[1].toUpperCase()});return e[n]}return"".concat(e,"-").concat(t)}const AG=(function(e){var t=et();function n(o){o&&(o.removeEventListener(P3,e),o.removeEventListener(F3,e))}function r(o){t.current&&t.current!==o&&n(t.current),o&&o!==t.current&&(o.addEventListener(P3,e),o.addEventListener(F3,e),t.current=o)}return C.useEffect(function(){return function(){n(t.current)}},[]),[r,n]});var pI=$o()?$F:Et;const $G=(function(){var e=C.useRef(null);function t(){en.cancel(e.current)}function n(r){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var i=en(function(){o<=1?r({isCanceled:function(){return i!==e.current}}):n(r,o-1)});e.current=i}return C.useEffect(function(){return function(){t()}},[]),[n,t]});var OG=[vi,Kl,Zl,PC],MG=[vi,lI],gI=!1,NG=!0;function mI(e){return e===Zl||e===PC}const DG=(function(e,t,n){var r=mc(D3),o=te(r,2),i=o[0],a=o[1],s=$G(),l=te(s,2),c=l[0],u=l[1];function d(){a(vi,!0)}var f=t?MG:OG;return pI(function(){if(i!==D3&&i!==PC){var h=f.indexOf(i),m=f[h+1],p=n(i);p===gI?a(m,!0):m&&c(function(g){function v(){g.isCanceled()||a(m,!0)}p===!0?v():Promise.resolve(p).then(v)})}},[e,i]),C.useEffect(function(){return function(){u()}},[]),[d,i]});function TG(e,t,n,r){var o=r.motionEnter,i=o===void 0?!0:o,a=r.motionAppear,s=a===void 0?!0:a,l=r.motionLeave,c=l===void 0?!0:l,u=r.motionDeadline,d=r.motionLeaveImmediately,f=r.onAppearPrepare,h=r.onEnterPrepare,m=r.onLeavePrepare,p=r.onAppearStart,g=r.onEnterStart,v=r.onLeaveStart,y=r.onAppearActive,b=r.onEnterActive,w=r.onLeaveActive,x=r.onAppearEnd,E=r.onEnterEnd,k=r.onLeaveEnd,S=r.onVisibleChanged,O=mc(),A=te(O,2),$=A[0],M=A[1],N=wG(Fa),D=te(N,2),T=D[0],P=D[1],I=mc(null),R=te(I,2),H=R[0],V=R[1],L=T(),j=et(!1),_=et(null);function F(){return n()}var B=et(!1);function z(){P(Fa),V(null,!0)}var G=cn(function(ye){var be=T();if(be!==Fa){var ce=F();if(!(ye&&!ye.deadline&&ye.target!==ce)){var he=B.current,Te;be===Kd&&he?Te=x==null?void 0:x(ce,ye):be===Zd&&he?Te=E==null?void 0:E(ce,ye):be===Qd&&he&&(Te=k==null?void 0:k(ce,ye)),he&&Te!==!1&&z()}}}),W=AG(G),q=te(W,1),U=q[0],Y=function(ye){switch(ye){case Kd:return X(X(X({},vi,f),Kl,p),Zl,y);case Zd:return X(X(X({},vi,h),Kl,g),Zl,b);case Qd:return X(X(X({},vi,m),Kl,v),Zl,w);default:return{}}},ie=C.useMemo(function(){return Y(L)},[L]),K=DG(L,!e,function(ye){if(ye===vi){var be=ie[vi];return be?be(F()):gI}if(ne in ie){var ce;V(((ce=ie[ne])===null||ce===void 0?void 0:ce.call(ie,F(),null))||null)}return ne===Zl&&L!==Fa&&(U(F()),u>0&&(clearTimeout(_.current),_.current=setTimeout(function(){G({deadline:!0})},u))),ne===lI&&z(),NG}),re=te(K,2),oe=re[0],ne=re[1],ae=mI(ne);B.current=ae;var de=et(null);pI(function(){if(!(j.current&&de.current===t)){M(t);var ye=j.current;j.current=!0;var be;!ye&&t&&s&&(be=Kd),ye&&t&&i&&(be=Zd),(ye&&!t&&c||!ye&&d&&!t&&c)&&(be=Qd);var ce=Y(be);be&&(e||ce[vi])?(P(be),oe()):P(Fa),de.current=t}},[t]),Et(function(){(L===Kd&&!s||L===Zd&&!i||L===Qd&&!c)&&P(Fa)},[s,i,c]),Et(function(){return function(){j.current=!1,clearTimeout(_.current)}},[]);var ge=C.useRef(!1);Et(function(){$&&(ge.current=!0),$!==void 0&&L===Fa&&((ge.current||$)&&(S==null||S($)),ge.current=!0)},[$,L]);var Se=H;return ie[vi]&&ne===Kl&&(Se=Q({transition:"none"},Se)),[L,ne,Se,$??t]}function FG(e){var t=e;At(e)==="object"&&(t=e.transitionSupport);function n(o,i){return!!(o.motionName&&t&&i!==!1)}var r=C.forwardRef(function(o,i){var a=o.visible,s=a===void 0?!0:a,l=o.removeOnLeave,c=l===void 0?!0:l,u=o.forceRender,d=o.children,f=o.motionName,h=o.leavedClassName,m=o.eventProps,p=C.useContext(sI),g=p.motion,v=n(o,g),y=et(),b=et();function w(){try{return y.current instanceof HTMLElement?y.current:th(b.current)}catch{return null}}var x=TG(v,s,w,o),E=te(x,4),k=E[0],S=E[1],O=E[2],A=E[3],$=C.useRef(A);A&&($.current=!0);var M=C.useCallback(function(R){y.current=R,wC(i,R)},[i]),N,D=Q(Q({},m),{},{visible:s});if(!d)N=null;else if(k===Fa)A?N=d(Q({},D),M):!c&&$.current&&h?N=d(Q(Q({},D),{},{className:h}),M):u||!c&&!h?N=d(Q(Q({},D),{},{style:{display:"none"}}),M):N=null;else{var T;S===vi?T="prepare":mI(S)?T="active":S===Kl&&(T="start");var P=I3(f,"".concat(k,"-").concat(T));N=d(Q(Q({},D),{},{className:me(I3(f,k),X(X({},P,P&&T),f,typeof f=="string")),style:O}),M)}if(C.isValidElement(N)&&Mc(N)){var I=wd(N);I||(N=C.cloneElement(N,{ref:M}))}return C.createElement(EG,{ref:b},N)});return r.displayName="CSSMotion",r}const fl=FG(hI);var m2="add",v2="keep",y2="remove",am="removed";function PG(e){var t;return e&&At(e)==="object"&&"key"in e?t=e:t={key:e},Q(Q({},t),{},{key:String(t.key)})}function b2(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(PG)}function IG(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=[],r=0,o=t.length,i=b2(e),a=b2(t);i.forEach(function(c){for(var u=!1,d=r;d<o;d+=1){var f=a[d];if(f.key===c.key){r<d&&(n=n.concat(a.slice(r,d).map(function(h){return Q(Q({},h),{},{status:m2})})),r=d),n.push(Q(Q({},f),{},{status:v2})),r+=1,u=!0;break}}u||n.push(Q(Q({},c),{},{status:y2}))}),r<o&&(n=n.concat(a.slice(r).map(function(c){return Q(Q({},c),{},{status:m2})})));var s={};n.forEach(function(c){var u=c.key;s[u]=(s[u]||0)+1});var l=Object.keys(s).filter(function(c){return s[c]>1});return l.forEach(function(c){n=n.filter(function(u){var d=u.key,f=u.status;return d!==c||f!==y2}),n.forEach(function(u){u.key===c&&(u.status=v2)})}),n}var BG=["component","children","onVisibleChanged","onAllRemoved"],RG=["status"],_G=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function jG(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:fl,n=(function(r){ds(i,r);var o=fs(i);function i(){var a;xr(this,i);for(var s=arguments.length,l=new Array(s),c=0;c<s;c++)l[c]=arguments[c];return a=o.call.apply(o,[this].concat(l)),X(fn(a),"state",{keyEntities:[]}),X(fn(a),"removeKey",function(u){a.setState(function(d){var f=d.keyEntities.map(function(h){return h.key!==u?h:Q(Q({},h),{},{status:am})});return{keyEntities:f}},function(){var d=a.state.keyEntities,f=d.filter(function(h){var m=h.status;return m!==am}).length;f===0&&a.props.onAllRemoved&&a.props.onAllRemoved()})}),a}return Er(i,[{key:"render",value:function(){var a=this,s=this.state.keyEntities,l=this.props,c=l.component,u=l.children,d=l.onVisibleChanged,f=tn(l,BG),h=c||C.Fragment,m={};return _G.forEach(function(p){m[p]=f[p],delete f[p]}),delete f.keys,C.createElement(h,f,s.map(function(p,g){var v=p.status,y=tn(p,RG),b=v===m2||v===v2;return C.createElement(t,Qe({},m,{key:y.key,visible:b,eventProps:y,onVisibleChanged:function(w){d==null||d(w,{key:y.key}),w||a.removeKey(y.key)}}),function(w,x){return u(Q(Q({},w),{},{index:g}),x)})}))}}],[{key:"getDerivedStateFromProps",value:function(a,s){var l=a.keys,c=s.keyEntities,u=b2(l),d=IG(c,u);return{keyEntities:d.filter(function(f){var h=c.find(function(m){var p=m.key;return f.key===p});return!(h&&h.status===am&&f.status===y2)})}}}]),i})(C.Component);return X(n,"defaultProps",{component:"div"}),n}const vI=jG(hI),B3=C.createContext(!0);function LG(e){const t=C.useContext(B3),{children:n}=e,[,r]=ii(),{motion:o}=r,i=C.useRef(!1);return i.current||(i.current=t!==o),i.current?C.createElement(B3.Provider,{value:o},C.createElement(xG,{motion:o},n)):n}const zG=()=>null;var HG=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const WG=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let IC,yI,bI,xI;function lh(){return IC||ed}function VG(){return yI||mp}function GG(e){return Object.keys(e).some(t=>t.endsWith("Color"))}const UG=e=>{const{prefixCls:t,iconPrefixCls:n,theme:r,holderRender:o}=e;t!==void 0&&(IC=t),n!==void 0&&(yI=n),"holderRender"in e&&(xI=o),r&&(GG(r)?GV(lh(),r):bI=r)},qG=()=>({getPrefixCls:(e,t)=>t||(e?`${lh()}-${e}`:lh()),getIconPrefixCls:VG,getRootPrefixCls:()=>IC||lh(),getTheme:()=>bI,holderRender:xI}),YG=e=>{const{children:t,csp:n,autoInsertSpaceInButton:r,alert:o,anchor:i,form:a,locale:s,componentSize:l,direction:c,space:u,splitter:d,virtual:f,dropdownMatchSelectWidth:h,popupMatchSelectWidth:m,popupOverflow:p,legacyLocale:g,parentContext:v,iconPrefixCls:y,theme:b,componentDisabled:w,segmented:x,statistic:E,spin:k,calendar:S,carousel:O,cascader:A,collapse:$,typography:M,checkbox:N,descriptions:D,divider:T,drawer:P,skeleton:I,steps:R,image:H,layout:V,list:L,mentions:j,modal:_,progress:F,result:B,slider:z,breadcrumb:G,menu:W,pagination:q,input:U,textArea:Y,empty:ie,badge:K,radio:re,rate:oe,switch:ne,transfer:ae,avatar:de,message:ge,tag:Se,table:ye,card:be,tabs:ce,timeline:he,timePicker:Te,upload:se,notification:Pe,tree:De,colorPicker:He,datePicker:ue,rangePicker:ve,flex:xe,wave:fe,dropdown:pe,warning:ke,tour:Ve,tooltip:Ee,popover:yt,popconfirm:Dt,floatButton:Ft,floatButtonGroup:Ut,variant:Ge,inputNumber:Xe,treeSelect:qe}=e,lt=C.useCallback((kt,Pt)=>{const{prefixCls:Xt}=e;if(Pt)return Pt;const on=Xt||v.getPrefixCls("");return kt?`${on}-${kt}`:on},[v.getPrefixCls,e.prefixCls]),je=y||v.iconPrefixCls||mp,Rt=n||v.csp;pG(je,Rt);const zt=yG(b,v.theme,{prefixCls:lt("")}),dt={csp:Rt,autoInsertSpaceInButton:r,alert:o,anchor:i,locale:s||g,direction:c,space:u,splitter:d,virtual:f,popupMatchSelectWidth:m??h,popupOverflow:p,getPrefixCls:lt,iconPrefixCls:je,theme:zt,segmented:x,statistic:E,spin:k,calendar:S,carousel:O,cascader:A,collapse:$,typography:M,checkbox:N,descriptions:D,divider:T,drawer:P,skeleton:I,steps:R,image:H,input:U,textArea:Y,layout:V,list:L,mentions:j,modal:_,progress:F,result:B,slider:z,breadcrumb:G,menu:W,pagination:q,empty:ie,badge:K,radio:re,rate:oe,switch:ne,transfer:ae,avatar:de,message:ge,tag:Se,table:ye,card:be,tabs:ce,timeline:he,timePicker:Te,upload:se,notification:Pe,tree:De,colorPicker:He,datePicker:ue,rangePicker:ve,flex:xe,wave:fe,dropdown:pe,warning:ke,tour:Ve,tooltip:Ee,popover:yt,popconfirm:Dt,floatButton:Ft,floatButtonGroup:Ut,variant:Ge,inputNumber:Xe,treeSelect:qe},Ct=Object.assign({},v);Object.keys(dt).forEach(kt=>{dt[kt]!==void 0&&(Ct[kt]=dt[kt])}),WG.forEach(kt=>{const Pt=e[kt];Pt&&(Ct[kt]=Pt)}),typeof r<"u"&&(Ct.button=Object.assign({autoInsertSpace:r},Ct.button));const jt=up(()=>Ct,Ct,(kt,Pt)=>{const Xt=Object.keys(kt),on=Object.keys(Pt);return Xt.length!==on.length||Xt.some(qt=>kt[qt]!==Pt[qt])}),{layer:Ie}=C.useContext(Cd),Ne=C.useMemo(()=>({prefixCls:je,csp:Rt,layer:Ie?"antd":void 0}),[je,Rt,Ie]);let Oe=C.createElement(C.Fragment,null,C.createElement(zG,{dropdownMatchSelectWidth:h}),t);const _e=C.useMemo(()=>{var kt,Pt,Xt,on;return Xl(((kt=Ja.Form)===null||kt===void 0?void 0:kt.defaultValidateMessages)||{},((Xt=(Pt=jt.locale)===null||Pt===void 0?void 0:Pt.Form)===null||Xt===void 0?void 0:Xt.defaultValidateMessages)||{},((on=jt.form)===null||on===void 0?void 0:on.validateMessages)||{},(a==null?void 0:a.validateMessages)||{})},[jt,a==null?void 0:a.validateMessages]);Object.keys(_e).length>0&&(Oe=C.createElement(VP.Provider,{value:_e},Oe)),s&&(Oe=C.createElement(AV,{locale:s,_ANT_MARK__:SV},Oe)),Oe=C.createElement(DC.Provider,{value:Ne},Oe),l&&(Oe=C.createElement(UV,{size:l},Oe)),Oe=C.createElement(LG,null,Oe);const mt=C.useMemo(()=>{const kt=zt||{},{algorithm:Pt,token:Xt,components:on,cssVar:qt}=kt,wn=HG(kt,["algorithm","token","components","cssVar"]),vn=Pt&&(!Array.isArray(Pt)||Pt.length>0)?ZE(Pt):KP,Kt={};Object.entries(on||{}).forEach(([On,ur])=>{const We=Object.assign({},ur);"algorithm"in We&&(We.algorithm===!0?We.theme=vn:(Array.isArray(We.algorithm)||typeof We.algorithm=="function")&&(We.theme=ZE(We.algorithm)),delete We.algorithm),Kt[On]=We});const $n=Object.assign(Object.assign({},Qu),Xt);return Object.assign(Object.assign({},wn),{theme:vn,token:$n,components:Kt,override:Object.assign({override:$n},Kt),cssVar:qt})},[zt]);return b&&(Oe=C.createElement(ZP.Provider,{value:mt},Oe)),jt.warning&&(Oe=C.createElement(xV.Provider,{value:jt.warning},Oe)),w!==void 0&&(Oe=C.createElement(QP,{disabled:w},Oe)),C.createElement(pn.Provider,{value:jt},Oe)},hs=e=>{const t=C.useContext(pn),n=C.useContext(TC);return C.createElement(YG,Object.assign({parentContext:t,legacyLocale:n},e))};hs.ConfigContext=pn;hs.SizeContext=Qs;hs.config=UG;hs.useConfig=qV;Object.defineProperty(hs,"SizeContext",{get:()=>Qs});var XG={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"};function EI(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}function KG(e){return EI(e)instanceof ShadowRoot}function u0(e){return KG(e)?EI(e):null}function ZG(e){return e.replace(/-(.)/g,function(t,n){return n.toUpperCase()})}function QG(e,t){qr(e,"[@ant-design/icons] ".concat(t))}function R3(e){return At(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(At(e.icon)==="object"||typeof e.icon=="function")}function _3(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(e).reduce(function(t,n){var r=e[n];switch(n){case"class":t.className=r,delete t.class;break;default:delete t[n],t[ZG(n)]=r}return t},{})}function x2(e,t,n){return n?we.createElement(e.tag,Q(Q({key:t},_3(e.attrs)),n),(e.children||[]).map(function(r,o){return x2(r,"".concat(t,"-").concat(e.tag,"-").concat(o))})):we.createElement(e.tag,Q({key:t},_3(e.attrs)),(e.children||[]).map(function(r,o){return x2(r,"".concat(t,"-").concat(e.tag,"-").concat(o))}))}function wI(e){return Ju(e)[0]}function CI(e){return e?Array.isArray(e)?e:[e]:[]}var JG=`
|
|
179
|
+
`,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)"}),r)}var M3=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const rI={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},lG={motionBase:!0,motionUnit:!0},cG={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},oI=(e,t,n)=>{const r=n.getDerivativeToken(e),{override:o}=t,i=M3(t,["override"]);let a=Object.assign(Object.assign({},r),{override:o});return a=nI(a),i&&Object.entries(i).forEach(([s,l])=>{const{theme:c}=l,u=M3(l,["theme"]);let d=u;c&&(d=oI(Object.assign(Object.assign({},a),u),{override:u},c)),a[s]=d}),a};function ii(){const{token:e,hashed:t,theme:n,override:r,cssVar:o}=we.useContext(ZP),i=`${aG}-${t||""}`,a=n||KP,[s,l,c]=H4(a,[Qu,e],{salt:i,override:r,getComputedToken:oI,formatToken:nI,cssVar:o&&{prefix:o.prefix,key:o.key,unitless:rI,ignore:lG,preserve:cG}});return[a,c,t?l:"",s,o]}const c0={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},br=(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}),kd=()=>({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"}}),uG=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),dG=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"}}}),fG=(e,t,n,r)=>{const o=`[class^="${t}"], [class*=" ${t}"]`,i=n?`.${n}`:o,a={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let s={};return r!==!1&&(s={fontFamily:e.fontFamily,fontSize:e.fontSize}),{[i]:Object.assign(Object.assign(Object.assign({},s),a),{[o]:a})}},FC=(e,t)=>({outline:`${Ce(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),iI=(e,t)=>({"&:focus-visible":FC(e)}),aI=e=>({[`.${e}`]:Object.assign(Object.assign({},kd()),{[`.${e} .${e}-icon`]:{display:"block"}})}),{genStyleHooks:Pr,genComponentStyleHook:hG,genSubStyleComponent:vp}=iG({usePrefix:()=>{const{getPrefixCls:e,iconPrefixCls:t}=pr(pn);return{rootPrefixCls:e(),iconPrefixCls:t}},useToken:()=>{const[e,t,n,r,o]=ii();return{theme:e,realToken:t,hashId:n,token:r,cssVar:o}},useCSP:()=>{const{csp:e}=pr(pn);return e??{}},getResetStyles:(e,t)=>{var n;const r=dG(e);return[r,{"&":r},aI((n=t==null?void 0:t.prefix.iconPrefixCls)!==null&&n!==void 0?n:mp)]},getCommonStyle:fG,getCompUnitless:()=>rI});function yp(e,t){return Js.reduce((n,r)=>{const o=e[`${r}1`],i=e[`${r}3`],a=e[`${r}6`],s=e[`${r}7`];return Object.assign(Object.assign({},n),t(r,{lightColor:o,lightBorderColor:i,darkColor:a,textColor:s}))},{})}const pG=(e,t)=>{const[n,r]=ii();return t2({token:r,hashId:"",path:["ant-design-icons",e],nonce:()=>t==null?void 0:t.nonce,layer:{name:"antd"}},()=>aI(e))},gG=Object.assign({},C),{useId:N3}=gG,mG=()=>"",vG=typeof N3>"u"?mG:N3;function yG(e,t,n){var r;gp();const o=e||{},i=o.inherit===!1||!t?Object.assign(Object.assign({},p2),{hashed:(r=t==null?void 0:t.hashed)!==null&&r!==void 0?r:p2.hashed,cssVar:t==null?void 0:t.cssVar}):t,a=vG();return up(()=>{var s,l;if(!e)return t;const c=Object.assign({},i.components);Object.keys(e.components||{}).forEach(f=>{c[f]=Object.assign(Object.assign({},c[f]),e.components[f])});const u=`css-var-${a.replace(/:/g,"")}`,d=((s=o.cssVar)!==null&&s!==void 0?s:i.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:n==null?void 0:n.prefixCls},typeof i.cssVar=="object"?i.cssVar:{}),typeof o.cssVar=="object"?o.cssVar:{}),{key:typeof o.cssVar=="object"&&((l=o.cssVar)===null||l===void 0?void 0:l.key)||u});return Object.assign(Object.assign(Object.assign({},i),o),{token:Object.assign(Object.assign({},i.token),o.token),components:c,cssVar:d})},[o,i],(s,l)=>s.some((c,u)=>{const d=l[u];return!a0(c,d,!0)}))}var bG=["children"],sI=C.createContext({});function xG(e){var t=e.children,n=tn(e,bG);return C.createElement(sI.Provider,{value:n},t)}var EG=(function(e){ds(n,e);var t=fs(n);function n(){return xr(this,n),t.apply(this,arguments)}return Er(n,[{key:"render",value:function(){return this.props.children}}]),n})(C.Component);function wG(e){var t=C.useReducer(function(s){return s+1},0),n=te(t,2),r=n[1],o=C.useRef(e),i=cn(function(){return o.current}),a=cn(function(s){o.current=typeof s=="function"?s(o.current):s,r()});return[i,a]}var Fa="none",Kd="appear",Zd="enter",Qd="leave",D3="none",vi="prepare",Kl="start",Zl="active",PC="end",lI="prepared";function T3(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit".concat(e)]="webkit".concat(t),n["Moz".concat(e)]="moz".concat(t),n["ms".concat(e)]="MS".concat(t),n["O".concat(e)]="o".concat(t.toLowerCase()),n}function CG(e,t){var n={animationend:T3("Animation","AnimationEnd"),transitionend:T3("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete n.animationend.animation,"TransitionEvent"in t||delete n.transitionend.transition),n}var kG=CG($o(),typeof window<"u"?window:{}),cI={};if($o()){var SG=document.createElement("div");cI=SG.style}var Jd={};function uI(e){if(Jd[e])return Jd[e];var t=kG[e];if(t)for(var n=Object.keys(t),r=n.length,o=0;o<r;o+=1){var i=n[o];if(Object.prototype.hasOwnProperty.call(t,i)&&i in cI)return Jd[e]=t[i],Jd[e]}return""}var dI=uI("animationend"),fI=uI("transitionend"),hI=!!(dI&&fI),F3=dI||"animationend",P3=fI||"transitionend";function I3(e,t){if(!e)return null;if(At(e)==="object"){var n=t.replace(/-\w/g,function(r){return r[1].toUpperCase()});return e[n]}return"".concat(e,"-").concat(t)}const AG=(function(e){var t=et();function n(o){o&&(o.removeEventListener(P3,e),o.removeEventListener(F3,e))}function r(o){t.current&&t.current!==o&&n(t.current),o&&o!==t.current&&(o.addEventListener(P3,e),o.addEventListener(F3,e),t.current=o)}return C.useEffect(function(){return function(){n(t.current)}},[]),[r,n]});var pI=$o()?$F:Et;const $G=(function(){var e=C.useRef(null);function t(){en.cancel(e.current)}function n(r){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var i=en(function(){o<=1?r({isCanceled:function(){return i!==e.current}}):n(r,o-1)});e.current=i}return C.useEffect(function(){return function(){t()}},[]),[n,t]});var OG=[vi,Kl,Zl,PC],MG=[vi,lI],gI=!1,NG=!0;function mI(e){return e===Zl||e===PC}const DG=(function(e,t,n){var r=mc(D3),o=te(r,2),i=o[0],a=o[1],s=$G(),l=te(s,2),c=l[0],u=l[1];function d(){a(vi,!0)}var f=t?MG:OG;return pI(function(){if(i!==D3&&i!==PC){var h=f.indexOf(i),m=f[h+1],p=n(i);p===gI?a(m,!0):m&&c(function(g){function v(){g.isCanceled()||a(m,!0)}p===!0?v():Promise.resolve(p).then(v)})}},[e,i]),C.useEffect(function(){return function(){u()}},[]),[d,i]});function TG(e,t,n,r){var o=r.motionEnter,i=o===void 0?!0:o,a=r.motionAppear,s=a===void 0?!0:a,l=r.motionLeave,c=l===void 0?!0:l,u=r.motionDeadline,d=r.motionLeaveImmediately,f=r.onAppearPrepare,h=r.onEnterPrepare,m=r.onLeavePrepare,p=r.onAppearStart,g=r.onEnterStart,v=r.onLeaveStart,y=r.onAppearActive,b=r.onEnterActive,w=r.onLeaveActive,x=r.onAppearEnd,E=r.onEnterEnd,k=r.onLeaveEnd,S=r.onVisibleChanged,O=mc(),A=te(O,2),$=A[0],M=A[1],N=wG(Fa),D=te(N,2),T=D[0],P=D[1],I=mc(null),R=te(I,2),H=R[0],V=R[1],L=T(),j=et(!1),_=et(null);function F(){return n()}var B=et(!1);function z(){P(Fa),V(null,!0)}var G=cn(function(ye){var be=T();if(be!==Fa){var ce=F();if(!(ye&&!ye.deadline&&ye.target!==ce)){var he=B.current,Te;be===Kd&&he?Te=x==null?void 0:x(ce,ye):be===Zd&&he?Te=E==null?void 0:E(ce,ye):be===Qd&&he&&(Te=k==null?void 0:k(ce,ye)),he&&Te!==!1&&z()}}}),W=AG(G),q=te(W,1),U=q[0],Y=function(ye){switch(ye){case Kd:return X(X(X({},vi,f),Kl,p),Zl,y);case Zd:return X(X(X({},vi,h),Kl,g),Zl,b);case Qd:return X(X(X({},vi,m),Kl,v),Zl,w);default:return{}}},ie=C.useMemo(function(){return Y(L)},[L]),K=DG(L,!e,function(ye){if(ye===vi){var be=ie[vi];return be?be(F()):gI}if(ne in ie){var ce;V(((ce=ie[ne])===null||ce===void 0?void 0:ce.call(ie,F(),null))||null)}return ne===Zl&&L!==Fa&&(U(F()),u>0&&(clearTimeout(_.current),_.current=setTimeout(function(){G({deadline:!0})},u))),ne===lI&&z(),NG}),re=te(K,2),oe=re[0],ne=re[1],ae=mI(ne);B.current=ae;var de=et(null);pI(function(){if(!(j.current&&de.current===t)){M(t);var ye=j.current;j.current=!0;var be;!ye&&t&&s&&(be=Kd),ye&&t&&i&&(be=Zd),(ye&&!t&&c||!ye&&d&&!t&&c)&&(be=Qd);var ce=Y(be);be&&(e||ce[vi])?(P(be),oe()):P(Fa),de.current=t}},[t]),Et(function(){(L===Kd&&!s||L===Zd&&!i||L===Qd&&!c)&&P(Fa)},[s,i,c]),Et(function(){return function(){j.current=!1,clearTimeout(_.current)}},[]);var ge=C.useRef(!1);Et(function(){$&&(ge.current=!0),$!==void 0&&L===Fa&&((ge.current||$)&&(S==null||S($)),ge.current=!0)},[$,L]);var Se=H;return ie[vi]&&ne===Kl&&(Se=Q({transition:"none"},Se)),[L,ne,Se,$??t]}function FG(e){var t=e;At(e)==="object"&&(t=e.transitionSupport);function n(o,i){return!!(o.motionName&&t&&i!==!1)}var r=C.forwardRef(function(o,i){var a=o.visible,s=a===void 0?!0:a,l=o.removeOnLeave,c=l===void 0?!0:l,u=o.forceRender,d=o.children,f=o.motionName,h=o.leavedClassName,m=o.eventProps,p=C.useContext(sI),g=p.motion,v=n(o,g),y=et(),b=et();function w(){try{return y.current instanceof HTMLElement?y.current:th(b.current)}catch{return null}}var x=TG(v,s,w,o),E=te(x,4),k=E[0],S=E[1],O=E[2],A=E[3],$=C.useRef(A);A&&($.current=!0);var M=C.useCallback(function(R){y.current=R,wC(i,R)},[i]),N,D=Q(Q({},m),{},{visible:s});if(!d)N=null;else if(k===Fa)A?N=d(Q({},D),M):!c&&$.current&&h?N=d(Q(Q({},D),{},{className:h}),M):u||!c&&!h?N=d(Q(Q({},D),{},{style:{display:"none"}}),M):N=null;else{var T;S===vi?T="prepare":mI(S)?T="active":S===Kl&&(T="start");var P=I3(f,"".concat(k,"-").concat(T));N=d(Q(Q({},D),{},{className:me(I3(f,k),X(X({},P,P&&T),f,typeof f=="string")),style:O}),M)}if(C.isValidElement(N)&&Mc(N)){var I=wd(N);I||(N=C.cloneElement(N,{ref:M}))}return C.createElement(EG,{ref:b},N)});return r.displayName="CSSMotion",r}const fl=FG(hI);var m2="add",v2="keep",y2="remove",am="removed";function PG(e){var t;return e&&At(e)==="object"&&"key"in e?t=e:t={key:e},Q(Q({},t),{},{key:String(t.key)})}function b2(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(PG)}function IG(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=[],r=0,o=t.length,i=b2(e),a=b2(t);i.forEach(function(c){for(var u=!1,d=r;d<o;d+=1){var f=a[d];if(f.key===c.key){r<d&&(n=n.concat(a.slice(r,d).map(function(h){return Q(Q({},h),{},{status:m2})})),r=d),n.push(Q(Q({},f),{},{status:v2})),r+=1,u=!0;break}}u||n.push(Q(Q({},c),{},{status:y2}))}),r<o&&(n=n.concat(a.slice(r).map(function(c){return Q(Q({},c),{},{status:m2})})));var s={};n.forEach(function(c){var u=c.key;s[u]=(s[u]||0)+1});var l=Object.keys(s).filter(function(c){return s[c]>1});return l.forEach(function(c){n=n.filter(function(u){var d=u.key,f=u.status;return d!==c||f!==y2}),n.forEach(function(u){u.key===c&&(u.status=v2)})}),n}var BG=["component","children","onVisibleChanged","onAllRemoved"],RG=["status"],_G=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function jG(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:fl,n=(function(r){ds(i,r);var o=fs(i);function i(){var a;xr(this,i);for(var s=arguments.length,l=new Array(s),c=0;c<s;c++)l[c]=arguments[c];return a=o.call.apply(o,[this].concat(l)),X(fn(a),"state",{keyEntities:[]}),X(fn(a),"removeKey",function(u){a.setState(function(d){var f=d.keyEntities.map(function(h){return h.key!==u?h:Q(Q({},h),{},{status:am})});return{keyEntities:f}},function(){var d=a.state.keyEntities,f=d.filter(function(h){var m=h.status;return m!==am}).length;f===0&&a.props.onAllRemoved&&a.props.onAllRemoved()})}),a}return Er(i,[{key:"render",value:function(){var a=this,s=this.state.keyEntities,l=this.props,c=l.component,u=l.children,d=l.onVisibleChanged,f=tn(l,BG),h=c||C.Fragment,m={};return _G.forEach(function(p){m[p]=f[p],delete f[p]}),delete f.keys,C.createElement(h,f,s.map(function(p,g){var v=p.status,y=tn(p,RG),b=v===m2||v===v2;return C.createElement(t,Qe({},m,{key:y.key,visible:b,eventProps:y,onVisibleChanged:function(w){d==null||d(w,{key:y.key}),w||a.removeKey(y.key)}}),function(w,x){return u(Q(Q({},w),{},{index:g}),x)})}))}}],[{key:"getDerivedStateFromProps",value:function(a,s){var l=a.keys,c=s.keyEntities,u=b2(l),d=IG(c,u);return{keyEntities:d.filter(function(f){var h=c.find(function(m){var p=m.key;return f.key===p});return!(h&&h.status===am&&f.status===y2)})}}}]),i})(C.Component);return X(n,"defaultProps",{component:"div"}),n}const vI=jG(hI),B3=C.createContext(!0);function LG(e){const t=C.useContext(B3),{children:n}=e,[,r]=ii(),{motion:o}=r,i=C.useRef(!1);return i.current||(i.current=t!==o),i.current?C.createElement(B3.Provider,{value:o},C.createElement(xG,{motion:o},n)):n}const zG=()=>null;var HG=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const WG=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let IC,yI,bI,xI;function lh(){return IC||ed}function VG(){return yI||mp}function GG(e){return Object.keys(e).some(t=>t.endsWith("Color"))}const UG=e=>{const{prefixCls:t,iconPrefixCls:n,theme:r,holderRender:o}=e;t!==void 0&&(IC=t),n!==void 0&&(yI=n),"holderRender"in e&&(xI=o),r&&(GG(r)?GV(lh(),r):bI=r)},qG=()=>({getPrefixCls:(e,t)=>t||(e?`${lh()}-${e}`:lh()),getIconPrefixCls:VG,getRootPrefixCls:()=>IC||lh(),getTheme:()=>bI,holderRender:xI}),YG=e=>{const{children:t,csp:n,autoInsertSpaceInButton:r,alert:o,anchor:i,form:a,locale:s,componentSize:l,direction:c,space:u,splitter:d,virtual:f,dropdownMatchSelectWidth:h,popupMatchSelectWidth:m,popupOverflow:p,legacyLocale:g,parentContext:v,iconPrefixCls:y,theme:b,componentDisabled:w,segmented:x,statistic:E,spin:k,calendar:S,carousel:O,cascader:A,collapse:$,typography:M,checkbox:N,descriptions:D,divider:T,drawer:P,skeleton:I,steps:R,image:H,layout:V,list:L,mentions:j,modal:_,progress:F,result:B,slider:z,breadcrumb:G,menu:W,pagination:q,input:U,textArea:Y,empty:ie,badge:K,radio:re,rate:oe,switch:ne,transfer:ae,avatar:de,message:ge,tag:Se,table:ye,card:be,tabs:ce,timeline:he,timePicker:Te,upload:se,notification:Pe,tree:De,colorPicker:He,datePicker:ue,rangePicker:ve,flex:xe,wave:fe,dropdown:pe,warning:ke,tour:Ve,tooltip:Ee,popover:yt,popconfirm:Dt,floatButton:Pt,floatButtonGroup:Ut,variant:Ge,inputNumber:Xe,treeSelect:qe}=e,lt=C.useCallback((kt,It)=>{const{prefixCls:Xt}=e;if(It)return It;const on=Xt||v.getPrefixCls("");return kt?`${on}-${kt}`:on},[v.getPrefixCls,e.prefixCls]),je=y||v.iconPrefixCls||mp,Rt=n||v.csp;pG(je,Rt);const zt=yG(b,v.theme,{prefixCls:lt("")}),dt={csp:Rt,autoInsertSpaceInButton:r,alert:o,anchor:i,locale:s||g,direction:c,space:u,splitter:d,virtual:f,popupMatchSelectWidth:m??h,popupOverflow:p,getPrefixCls:lt,iconPrefixCls:je,theme:zt,segmented:x,statistic:E,spin:k,calendar:S,carousel:O,cascader:A,collapse:$,typography:M,checkbox:N,descriptions:D,divider:T,drawer:P,skeleton:I,steps:R,image:H,input:U,textArea:Y,layout:V,list:L,mentions:j,modal:_,progress:F,result:B,slider:z,breadcrumb:G,menu:W,pagination:q,empty:ie,badge:K,radio:re,rate:oe,switch:ne,transfer:ae,avatar:de,message:ge,tag:Se,table:ye,card:be,tabs:ce,timeline:he,timePicker:Te,upload:se,notification:Pe,tree:De,colorPicker:He,datePicker:ue,rangePicker:ve,flex:xe,wave:fe,dropdown:pe,warning:ke,tour:Ve,tooltip:Ee,popover:yt,popconfirm:Dt,floatButton:Pt,floatButtonGroup:Ut,variant:Ge,inputNumber:Xe,treeSelect:qe},Ct=Object.assign({},v);Object.keys(dt).forEach(kt=>{dt[kt]!==void 0&&(Ct[kt]=dt[kt])}),WG.forEach(kt=>{const It=e[kt];It&&(Ct[kt]=It)}),typeof r<"u"&&(Ct.button=Object.assign({autoInsertSpace:r},Ct.button));const jt=up(()=>Ct,Ct,(kt,It)=>{const Xt=Object.keys(kt),on=Object.keys(It);return Xt.length!==on.length||Xt.some(qt=>kt[qt]!==It[qt])}),{layer:Ie}=C.useContext(Cd),Ne=C.useMemo(()=>({prefixCls:je,csp:Rt,layer:Ie?"antd":void 0}),[je,Rt,Ie]);let Oe=C.createElement(C.Fragment,null,C.createElement(zG,{dropdownMatchSelectWidth:h}),t);const _e=C.useMemo(()=>{var kt,It,Xt,on;return Xl(((kt=Ja.Form)===null||kt===void 0?void 0:kt.defaultValidateMessages)||{},((Xt=(It=jt.locale)===null||It===void 0?void 0:It.Form)===null||Xt===void 0?void 0:Xt.defaultValidateMessages)||{},((on=jt.form)===null||on===void 0?void 0:on.validateMessages)||{},(a==null?void 0:a.validateMessages)||{})},[jt,a==null?void 0:a.validateMessages]);Object.keys(_e).length>0&&(Oe=C.createElement(VP.Provider,{value:_e},Oe)),s&&(Oe=C.createElement(AV,{locale:s,_ANT_MARK__:SV},Oe)),Oe=C.createElement(DC.Provider,{value:Ne},Oe),l&&(Oe=C.createElement(UV,{size:l},Oe)),Oe=C.createElement(LG,null,Oe);const mt=C.useMemo(()=>{const kt=zt||{},{algorithm:It,token:Xt,components:on,cssVar:qt}=kt,wn=HG(kt,["algorithm","token","components","cssVar"]),vn=It&&(!Array.isArray(It)||It.length>0)?ZE(It):KP,Kt={};Object.entries(on||{}).forEach(([On,ur])=>{const We=Object.assign({},ur);"algorithm"in We&&(We.algorithm===!0?We.theme=vn:(Array.isArray(We.algorithm)||typeof We.algorithm=="function")&&(We.theme=ZE(We.algorithm)),delete We.algorithm),Kt[On]=We});const $n=Object.assign(Object.assign({},Qu),Xt);return Object.assign(Object.assign({},wn),{theme:vn,token:$n,components:Kt,override:Object.assign({override:$n},Kt),cssVar:qt})},[zt]);return b&&(Oe=C.createElement(ZP.Provider,{value:mt},Oe)),jt.warning&&(Oe=C.createElement(xV.Provider,{value:jt.warning},Oe)),w!==void 0&&(Oe=C.createElement(QP,{disabled:w},Oe)),C.createElement(pn.Provider,{value:jt},Oe)},hs=e=>{const t=C.useContext(pn),n=C.useContext(TC);return C.createElement(YG,Object.assign({parentContext:t,legacyLocale:n},e))};hs.ConfigContext=pn;hs.SizeContext=Qs;hs.config=UG;hs.useConfig=qV;Object.defineProperty(hs,"SizeContext",{get:()=>Qs});var XG={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"};function EI(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}function KG(e){return EI(e)instanceof ShadowRoot}function u0(e){return KG(e)?EI(e):null}function ZG(e){return e.replace(/-(.)/g,function(t,n){return n.toUpperCase()})}function QG(e,t){qr(e,"[@ant-design/icons] ".concat(t))}function R3(e){return At(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(At(e.icon)==="object"||typeof e.icon=="function")}function _3(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(e).reduce(function(t,n){var r=e[n];switch(n){case"class":t.className=r,delete t.class;break;default:delete t[n],t[ZG(n)]=r}return t},{})}function x2(e,t,n){return n?we.createElement(e.tag,Q(Q({key:t},_3(e.attrs)),n),(e.children||[]).map(function(r,o){return x2(r,"".concat(t,"-").concat(e.tag,"-").concat(o))})):we.createElement(e.tag,Q({key:t},_3(e.attrs)),(e.children||[]).map(function(r,o){return x2(r,"".concat(t,"-").concat(e.tag,"-").concat(o))}))}function wI(e){return Ju(e)[0]}function CI(e){return e?Array.isArray(e)?e:[e]:[]}var JG=`
|
|
180
180
|
.anticon {
|
|
181
181
|
display: inline-flex;
|
|
182
182
|
align-items: center;
|
|
@@ -282,9 +282,9 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
282
282
|
html body {
|
|
283
283
|
overflow-y: hidden;
|
|
284
284
|
`.concat(a?"width: calc(100% - ".concat(i,"px);"):"",`
|
|
285
|
-
}`),o)}else Xu(o);return function(){Xu(o)}},[t,o])}var qY=!1;function YY(e){return qY}var u6=function(e){return e===!1?!1:!$o()||!e?null:typeof e=="string"?document.querySelector(e):typeof e=="function"?e():e},qI=C.forwardRef(function(e,t){var n=e.open,r=e.autoLock,o=e.getContainer;e.debug;var i=e.autoDestroy,a=i===void 0?!0:i,s=e.children,l=C.useState(n),c=te(l,2),u=c[0],d=c[1],f=u||n;C.useEffect(function(){(a||n)&&d(n)},[n,a]);var h=C.useState(function(){return u6(o)}),m=te(h,2),p=m[0],g=m[1];C.useEffect(function(){var $=u6(o);g($??null)});var v=zY(f&&!p),y=te(v,2),b=y[0],w=y[1],x=p??b;UY(r&&n&&$o()&&(x===b||x===document.body));var E=null;if(s&&Mc(s)&&t){var k=s;E=k.ref}var S=Ed(E,t);if(!f||!$o()||p===void 0)return null;var O=x===!1||YY(),A=s;return t&&(A=C.cloneElement(s,{ref:S})),C.createElement(UI.Provider,{value:w},O?A:IF(A,x))});function XY(){var e=Q({},C);return e.useId}var d6=0,f6=XY();const qC=f6?(function(e){var t=f6();return e||t}):(function(e){var t=C.useState("ssr-id"),n=te(t,2),r=n[0],o=n[1];return C.useEffect(function(){var i=d6;d6+=1,o("rc_unique_".concat(i))},[]),e||r});var Rs="RC_FORM_INTERNAL_HOOKS",Wn=function(){qr(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},el=C.createContext({getFieldValue:Wn,getFieldsValue:Wn,getFieldError:Wn,getFieldWarning:Wn,getFieldsError:Wn,isFieldsTouched:Wn,isFieldTouched:Wn,isFieldValidating:Wn,isFieldsValidating:Wn,resetFields:Wn,setFields:Wn,setFieldValue:Wn,setFieldsValue:Wn,validateFields:Wn,submit:Wn,getInternalHooks:function(){return Wn(),{dispatch:Wn,initEntityValue:Wn,registerField:Wn,useSubscribe:Wn,setInitialValues:Wn,destroyForm:Wn,setCallbacks:Wn,registerWatch:Wn,getFields:Wn,setValidateMessages:Wn,setPreserve:Wn,getInitialValue:Wn}}}),td=C.createContext(null);function O2(e){return e==null?[]:Array.isArray(e)?e:[e]}function KY(e){return e&&!!e._init}function M2(){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",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 e=JSON.parse(JSON.stringify(this));return e.clone=this.clone,e}}}var N2=M2();function ZY(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function QY(e,t,n){if(CC())return Reflect.construct.apply(null,arguments);var r=[null];r.push.apply(r,t);var o=new(e.bind.apply(e,r));return n&&Uu(o,n.prototype),o}function D2(e){var t=typeof Map=="function"?new Map:void 0;return D2=function(n){if(n===null||!ZY(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,r)}function r(){return QY(n,arguments,qu(this).constructor)}return r.prototype=Object.create(n.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Uu(r,n)},D2(e)}var JY=/%[sdj%]/g,eX=function(){};function T2(e){if(!e||!e.length)return null;var t={};return e.forEach(function(n){var r=n.field;t[r]=t[r]||[],t[r].push(n)}),t}function Io(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=0,i=n.length;if(typeof e=="function")return e.apply(null,n);if(typeof e=="string"){var a=e.replace(JY,function(s){if(s==="%%")return"%";if(o>=i)return s;switch(s){case"%s":return String(n[o++]);case"%d":return Number(n[o++]);case"%j":try{return JSON.stringify(n[o++])}catch{return"[Circular]"}break;default:return s}});return a}return e}function tX(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Lr(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||tX(t)&&typeof e=="string"&&!e)}function nX(e,t,n){var r=[],o=0,i=e.length;function a(s){r.push.apply(r,ze(s||[])),o++,o===i&&n(r)}e.forEach(function(s){t(s,a)})}function h6(e,t,n){var r=0,o=e.length;function i(a){if(a&&a.length){n(a);return}var s=r;r=r+1,s<o?t(e[s],i):n([])}i([])}function rX(e){var t=[];return Object.keys(e).forEach(function(n){t.push.apply(t,ze(e[n]||[]))}),t}var p6=(function(e){ds(n,e);var t=fs(n);function n(r,o){var i;return xr(this,n),i=t.call(this,"Async Validation Error"),X(fn(i),"errors",void 0),X(fn(i),"fields",void 0),i.errors=r,i.fields=o,i}return Er(n)})(D2(Error));function oX(e,t,n,r,o){if(t.first){var i=new Promise(function(f,h){var m=function(g){return r(g),g.length?h(new p6(g,T2(g))):f(o)},p=rX(e);h6(p,n,m)});return i.catch(function(f){return f}),i}var a=t.firstFields===!0?Object.keys(e):t.firstFields||[],s=Object.keys(e),l=s.length,c=0,u=[],d=new Promise(function(f,h){var m=function(p){if(u.push.apply(u,p),c++,c===l)return r(u),u.length?h(new p6(u,T2(u))):f(o)};s.length||(r(u),f(o)),s.forEach(function(p){var g=e[p];a.indexOf(p)!==-1?h6(g,n,m):nX(g,n,m)})});return d.catch(function(f){return f}),d}function iX(e){return!!(e&&e.message!==void 0)}function aX(e,t){for(var n=e,r=0;r<t.length;r++){if(n==null)return n;n=n[t[r]]}return n}function g6(e,t){return function(n){var r;return e.fullFields?r=aX(t,e.fullFields):r=t[n.field||e.fullField],iX(n)?(n.field=n.field||e.fullField,n.fieldValue=r,n):{message:typeof n=="function"?n():n,fieldValue:r,field:n.field||e.fullField}}}function m6(e,t){if(t){for(var n in t)if(t.hasOwnProperty(n)){var r=t[n];At(r)==="object"&&At(e[n])==="object"?e[n]=Q(Q({},e[n]),r):e[n]=r}}return e}var Ol="enum",sX=function(e,t,n,r,o){e[Ol]=Array.isArray(e[Ol])?e[Ol]:[],e[Ol].indexOf(t)===-1&&r.push(Io(o.messages[Ol],e.fullField,e[Ol].join(", ")))},lX=function(e,t,n,r,o){if(e.pattern){if(e.pattern instanceof RegExp)e.pattern.lastIndex=0,e.pattern.test(t)||r.push(Io(o.messages.pattern.mismatch,e.fullField,t,e.pattern));else if(typeof e.pattern=="string"){var i=new RegExp(e.pattern);i.test(t)||r.push(Io(o.messages.pattern.mismatch,e.fullField,t,e.pattern))}}},cX=function(e,t,n,r,o){var i=typeof e.len=="number",a=typeof e.min=="number",s=typeof e.max=="number",l=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,c=t,u=null,d=typeof t=="number",f=typeof t=="string",h=Array.isArray(t);if(d?u="number":f?u="string":h&&(u="array"),!u)return!1;h&&(c=t.length),f&&(c=t.replace(l,"_").length),i?c!==e.len&&r.push(Io(o.messages[u].len,e.fullField,e.len)):a&&!s&&c<e.min?r.push(Io(o.messages[u].min,e.fullField,e.min)):s&&!a&&c>e.max?r.push(Io(o.messages[u].max,e.fullField,e.max)):a&&s&&(c<e.min||c>e.max)&&r.push(Io(o.messages[u].range,e.fullField,e.min,e.max))},YI=function(e,t,n,r,o,i){e.required&&(!n.hasOwnProperty(e.field)||Lr(t,i||e.type))&&r.push(Io(o.messages.required,e.fullField))},nf;const uX=(function(){if(nf)return nf;var e="[a-fA-F\\d:]",t=function(x){return x&&x.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(e,")|(?<=").concat(e,")(?=\\s|$))"):""},n="(?: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}",r="[a-fA-F\\d]{1,4}",o=["(?:".concat(r,":){7}(?:").concat(r,"|:)"),"(?:".concat(r,":){6}(?:").concat(n,"|:").concat(r,"|:)"),"(?:".concat(r,":){5}(?::").concat(n,"|(?::").concat(r,"){1,2}|:)"),"(?:".concat(r,":){4}(?:(?::").concat(r,"){0,1}:").concat(n,"|(?::").concat(r,"){1,3}|:)"),"(?:".concat(r,":){3}(?:(?::").concat(r,"){0,2}:").concat(n,"|(?::").concat(r,"){1,4}|:)"),"(?:".concat(r,":){2}(?:(?::").concat(r,"){0,3}:").concat(n,"|(?::").concat(r,"){1,5}|:)"),"(?:".concat(r,":){1}(?:(?::").concat(r,"){0,4}:").concat(n,"|(?::").concat(r,"){1,6}|:)"),"(?::(?:(?::".concat(r,"){0,5}:").concat(n,"|(?::").concat(r,"){1,7}|:))")],i="(?:%[0-9a-zA-Z]{1,})?",a="(?:".concat(o.join("|"),")").concat(i),s=new RegExp("(?:^".concat(n,"$)|(?:^").concat(a,"$)")),l=new RegExp("^".concat(n,"$")),c=new RegExp("^".concat(a,"$")),u=function(x){return x&&x.exact?s:new RegExp("(?:".concat(t(x)).concat(n).concat(t(x),")|(?:").concat(t(x)).concat(a).concat(t(x),")"),"g")};u.v4=function(x){return x&&x.exact?l:new RegExp("".concat(t(x)).concat(n).concat(t(x)),"g")},u.v6=function(x){return x&&x.exact?c:new RegExp("".concat(t(x)).concat(a).concat(t(x)),"g")};var d="(?:(?:[a-z]+:)?//)",f="(?:\\S+(?::\\S*)?@)?",h=u.v4().source,m=u.v6().source,p="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",g="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",v="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",y="(?::\\d{2,5})?",b='(?:[/?#][^\\s"]*)?',w="(?:".concat(d,"|www\\.)").concat(f,"(?:localhost|").concat(h,"|").concat(m,"|").concat(p).concat(g).concat(v,")").concat(y).concat(b);return nf=new RegExp("(?:^".concat(w,"$)"),"i"),nf});var v6={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,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},Eu={integer:function(e){return Eu.number(e)&&parseInt(e,10)===e},float:function(e){return Eu.number(e)&&!Eu.integer(e)},array:function(e){return Array.isArray(e)},regexp:function(e){if(e instanceof RegExp)return!0;try{return!!new RegExp(e)}catch{return!1}},date:function(e){return typeof e.getTime=="function"&&typeof e.getMonth=="function"&&typeof e.getYear=="function"&&!isNaN(e.getTime())},number:function(e){return isNaN(e)?!1:typeof e=="number"},object:function(e){return At(e)==="object"&&!Eu.array(e)},method:function(e){return typeof e=="function"},email:function(e){return typeof e=="string"&&e.length<=320&&!!e.match(v6.email)},url:function(e){return typeof e=="string"&&e.length<=2048&&!!e.match(uX())},hex:function(e){return typeof e=="string"&&!!e.match(v6.hex)}},dX=function(e,t,n,r,o){if(e.required&&t===void 0){YI(e,t,n,r,o);return}var i=["integer","float","array","regexp","object","method","email","number","date","url","hex"],a=e.type;i.indexOf(a)>-1?Eu[a](t)||r.push(Io(o.messages.types[a],e.fullField,e.type)):a&&At(t)!==e.type&&r.push(Io(o.messages.types[a],e.fullField,e.type))},fX=function(e,t,n,r,o){(/^\s+$/.test(t)||t==="")&&r.push(Io(o.messages.whitespace,e.fullField))};const bn={required:YI,whitespace:fX,type:dX,range:cX,enum:sX,pattern:lX};var hX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o)}n(i)},pX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(t==null&&!e.required)return n();bn.required(e,t,r,i,o,"array"),t!=null&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},gX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},mX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"date")&&!e.required)return n();if(bn.required(e,t,r,i,o),!Lr(t,"date")){var s;t instanceof Date?s=t:s=new Date(t),bn.type(e,s,r,i,o),s&&bn.range(e,s.getTime(),r,i,o)}}n(i)},vX="enum",yX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn[vX](e,t,r,i,o)}n(i)},bX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},xX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},EX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},wX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(t===""&&(t=void 0),Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},CX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},kX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"string")&&!e.required)return n();bn.required(e,t,r,i,o),Lr(t,"string")||bn.pattern(e,t,r,i,o)}n(i)},SX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),Lr(t)||bn.type(e,t,r,i,o)}n(i)},AX=function(e,t,n,r,o){var i=[],a=Array.isArray(t)?"array":At(t);bn.required(e,t,r,i,o,a),n(i)},$X=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"string")&&!e.required)return n();bn.required(e,t,r,i,o,"string"),Lr(t,"string")||(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o),bn.pattern(e,t,r,i,o),e.whitespace===!0&&bn.whitespace(e,t,r,i,o))}n(i)},gm=function(e,t,n,r,o){var i=e.type,a=[],s=e.required||!e.required&&r.hasOwnProperty(e.field);if(s){if(Lr(t,i)&&!e.required)return n();bn.required(e,t,r,a,o,i),Lr(t,i)||bn.type(e,t,r,a,o)}n(a)};const Fu={string:$X,method:EX,number:wX,boolean:gX,regexp:SX,integer:xX,float:bX,array:pX,object:CX,enum:yX,pattern:kX,date:mX,url:gm,hex:gm,email:gm,required:AX,any:hX};var Od=(function(){function e(t){xr(this,e),X(this,"rules",null),X(this,"_messages",N2),this.define(t)}return Er(e,[{key:"define",value:function(t){var n=this;if(!t)throw new Error("Cannot configure a schema with no rules");if(At(t)!=="object"||Array.isArray(t))throw new Error("Rules must be an object");this.rules={},Object.keys(t).forEach(function(r){var o=t[r];n.rules[r]=Array.isArray(o)?o:[o]})}},{key:"messages",value:function(t){return t&&(this._messages=m6(M2(),t)),this._messages}},{key:"validate",value:function(t){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},i=t,a=r,s=o;if(typeof a=="function"&&(s=a,a={}),!this.rules||Object.keys(this.rules).length===0)return s&&s(null,i),Promise.resolve(i);function l(f){var h=[],m={};function p(v){if(Array.isArray(v)){var y;h=(y=h).concat.apply(y,ze(v))}else h.push(v)}for(var g=0;g<f.length;g++)p(f[g]);h.length?(m=T2(h),s(h,m)):s(null,i)}if(a.messages){var c=this.messages();c===N2&&(c=M2()),m6(c,a.messages),a.messages=c}else a.messages=this.messages();var u={},d=a.keys||Object.keys(this.rules);return d.forEach(function(f){var h=n.rules[f],m=i[f];h.forEach(function(p){var g=p;typeof g.transform=="function"&&(i===t&&(i=Q({},i)),m=i[f]=g.transform(m),m!=null&&(g.type=g.type||(Array.isArray(m)?"array":At(m)))),typeof g=="function"?g={validator:g}:g=Q({},g),g.validator=n.getValidationMethod(g),g.validator&&(g.field=f,g.fullField=g.fullField||f,g.type=n.getType(g),u[f]=u[f]||[],u[f].push({rule:g,value:m,source:i,field:f}))})}),oX(u,a,function(f,h){var m=f.rule,p=(m.type==="object"||m.type==="array")&&(At(m.fields)==="object"||At(m.defaultField)==="object");p=p&&(m.required||!m.required&&f.value),m.field=f.field;function g(x,E){return Q(Q({},E),{},{fullField:"".concat(m.fullField,".").concat(x),fullFields:m.fullFields?[].concat(ze(m.fullFields),[x]):[x]})}function v(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],E=Array.isArray(x)?x:[x];!a.suppressWarning&&E.length&&e.warning("async-validator:",E),E.length&&m.message!==void 0&&(E=[].concat(m.message));var k=E.map(g6(m,i));if(a.first&&k.length)return h(k);if(!p)h(k);else{if(m.required&&!f.value)return m.message!==void 0?k=[].concat(m.message).map(g6(m,i)):a.error&&(k=[a.error(m,Io(a.messages.required,m.field))]),h(k);var S={};m.defaultField&&Object.keys(f.value).map(function($){S[$]=m.defaultField}),S=Q(Q({},S),f.rule.fields);var O={};Object.keys(S).forEach(function($){var M=S[$],N=Array.isArray(M)?M:[M];O[$]=N.map(g.bind(null,$))});var A=new e(O);A.messages(a.messages),f.rule.options&&(f.rule.options.messages=a.messages,f.rule.options.error=a.error),A.validate(f.value,f.rule.options||a,function($){var M=[];k&&k.length&&M.push.apply(M,ze(k)),$&&$.length&&M.push.apply(M,ze($)),h(M.length?M:null)})}}var y;if(m.asyncValidator)y=m.asyncValidator(m,f.value,v,f.source,a);else if(m.validator){try{y=m.validator(m,f.value,v,f.source,a)}catch(x){var b,w;(b=(w=console).error)===null||b===void 0||b.call(w,x),a.suppressValidatorError||setTimeout(function(){throw x},0),v(x.message)}y===!0?v():y===!1?v(typeof m.message=="function"?m.message(m.fullField||m.field):m.message||"".concat(m.fullField||m.field," fails")):y instanceof Array?v(y):y instanceof Error&&v(y.message)}y&&y.then&&y.then(function(){return v()},function(x){return v(x)})},function(f){l(f)},i)}},{key:"getType",value:function(t){if(t.type===void 0&&t.pattern instanceof RegExp&&(t.type="pattern"),typeof t.validator!="function"&&t.type&&!Fu.hasOwnProperty(t.type))throw new Error(Io("Unknown rule type %s",t.type));return t.type||"string"}},{key:"getValidationMethod",value:function(t){if(typeof t.validator=="function")return t.validator;var n=Object.keys(t),r=n.indexOf("message");return r!==-1&&n.splice(r,1),n.length===1&&n[0]==="required"?Fu.required:Fu[this.getType(t)]||void 0}}]),e})();X(Od,"register",function(e,t){if(typeof t!="function")throw new Error("Cannot register a validator by type, validator is not a function");Fu[e]=t});X(Od,"warning",eX);X(Od,"messages",N2);X(Od,"validators",Fu);var Mo="'${name}' is not a valid ${type}",XI={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:Mo,method:Mo,array:Mo,object:Mo,number:Mo,date:Mo,boolean:Mo,integer:Mo,float:Mo,regexp:Mo,email:Mo,url:Mo,hex:Mo},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}"}},y6=Od;function OX(e,t){return e.replace(/\\?\$\{\w+\}/g,function(n){if(n.startsWith("\\"))return n.slice(1);var r=n.slice(2,-1);return t[r]})}var b6="CODE_LOGIC_ERROR";function F2(e,t,n,r,o){return P2.apply(this,arguments)}function P2(){return P2=hl(fo().mark(function e(t,n,r,o,i){var a,s,l,c,u,d,f,h,m;return fo().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:return a=Q({},r),delete a.ruleIndex,y6.warning=function(){},a.validator&&(s=a.validator,a.validator=function(){try{return s.apply(void 0,arguments)}catch(g){return console.error(g),Promise.reject(b6)}}),l=null,a&&a.type==="array"&&a.defaultField&&(l=a.defaultField,delete a.defaultField),c=new y6(X({},t,[a])),u=Xl(XI,o.validateMessages),c.messages(u),d=[],p.prev=10,p.next=13,Promise.resolve(c.validate(X({},t,n),Q({},o)));case 13:p.next=18;break;case 15:p.prev=15,p.t0=p.catch(10),p.t0.errors&&(d=p.t0.errors.map(function(g,v){var y=g.message,b=y===b6?u.default:y;return C.isValidElement(b)?C.cloneElement(b,{key:"error_".concat(v)}):b}));case 18:if(!(!d.length&&l&&Array.isArray(n)&&n.length>0)){p.next=23;break}return p.next=21,Promise.all(n.map(function(g,v){return F2("".concat(t,".").concat(v),g,l,o,i)}));case 21:return f=p.sent,p.abrupt("return",f.reduce(function(g,v){return[].concat(ze(g),ze(v))},[]));case 23:return h=Q(Q({},r),{},{name:t,enum:(r.enum||[]).join(", ")},i),m=d.map(function(g){return typeof g=="string"?OX(g,h):g}),p.abrupt("return",m);case 26:case"end":return p.stop()}},e,null,[[10,15]])})),P2.apply(this,arguments)}function MX(e,t,n,r,o,i){var a=e.join("."),s=n.map(function(u,d){var f=u.validator,h=Q(Q({},u),{},{ruleIndex:d});return f&&(h.validator=function(m,p,g){var v=!1,y=function(){for(var w=arguments.length,x=new Array(w),E=0;E<w;E++)x[E]=arguments[E];Promise.resolve().then(function(){qr(!v,"Your validator function has already return a promise. `callback` will be ignored."),v||g.apply(void 0,x)})},b=f(m,p,y);v=b&&typeof b.then=="function"&&typeof b.catch=="function",qr(v,"`callback` is deprecated. Please return a promise instead."),v&&b.then(function(){g()}).catch(function(w){g(w||" ")})}),h}).sort(function(u,d){var f=u.warningOnly,h=u.ruleIndex,m=d.warningOnly,p=d.ruleIndex;return!!f==!!m?h-p:f?1:-1}),l;if(o===!0)l=new Promise((function(){var u=hl(fo().mark(function d(f,h){var m,p,g;return fo().wrap(function(v){for(;;)switch(v.prev=v.next){case 0:m=0;case 1:if(!(m<s.length)){v.next=12;break}return p=s[m],v.next=5,F2(a,t,p,r,i);case 5:if(g=v.sent,!g.length){v.next=9;break}return h([{errors:g,rule:p}]),v.abrupt("return");case 9:m+=1,v.next=1;break;case 12:f([]);case 13:case"end":return v.stop()}},d)}));return function(d,f){return u.apply(this,arguments)}})());else{var c=s.map(function(u){return F2(a,t,u,r,i).then(function(d){return{errors:d,rule:u}})});l=(o?DX(c):NX(c)).then(function(u){return Promise.reject(u)})}return l.catch(function(u){return u}),l}function NX(e){return I2.apply(this,arguments)}function I2(){return I2=hl(fo().mark(function e(t){return fo().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.all(t).then(function(r){var o,i=(o=[]).concat.apply(o,ze(r));return i}));case 1:case"end":return n.stop()}},e)})),I2.apply(this,arguments)}function DX(e){return B2.apply(this,arguments)}function B2(){return B2=hl(fo().mark(function e(t){var n;return fo().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return n=0,r.abrupt("return",new Promise(function(o){t.forEach(function(i){i.then(function(a){a.errors.length&&o([a]),n+=1,n===t.length&&o([])})})}));case 2:case"end":return r.stop()}},e)})),B2.apply(this,arguments)}function Sr(e){return O2(e)}function x6(e,t){var n={};return t.forEach(function(r){var o=ei(e,r);n=Zo(n,r,o)}),n}function oc(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return e&&e.some(function(r){return KI(t,r,n)})}function KI(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return!e||!t||!n&&e.length!==t.length?!1:t.every(function(r,o){return e[o]===r})}function TX(e,t){if(e===t)return!0;if(!e&&t||e&&!t||!e||!t||At(e)!=="object"||At(t)!=="object")return!1;var n=Object.keys(e),r=Object.keys(t),o=new Set([].concat(n,r));return ze(o).every(function(i){var a=e[i],s=t[i];return typeof a=="function"&&typeof s=="function"?!0:a===s})}function FX(e){var t=arguments.length<=1?void 0:arguments[1];return t&&t.target&&At(t.target)==="object"&&e in t.target?t.target[e]:t}function E6(e,t,n){var r=e.length;if(t<0||t>=r||n<0||n>=r)return e;var o=e[t],i=t-n;return i>0?[].concat(ze(e.slice(0,n)),[o],ze(e.slice(n,t)),ze(e.slice(t+1,r))):i<0?[].concat(ze(e.slice(0,t)),ze(e.slice(t+1,n+1)),[o],ze(e.slice(n+1,r))):e}var PX=["name"],Lo=[];function mm(e,t,n,r,o,i){return typeof e=="function"?e(t,n,"source"in i?{source:i.source}:{}):r!==o}var YC=(function(e){ds(n,e);var t=fs(n);function n(r){var o;if(xr(this,n),o=t.call(this,r),X(fn(o),"state",{resetCount:0}),X(fn(o),"cancelRegisterFunc",null),X(fn(o),"mounted",!1),X(fn(o),"touched",!1),X(fn(o),"dirty",!1),X(fn(o),"validatePromise",void 0),X(fn(o),"prevValidating",void 0),X(fn(o),"errors",Lo),X(fn(o),"warnings",Lo),X(fn(o),"cancelRegister",function(){var l=o.props,c=l.preserve,u=l.isListField,d=l.name;o.cancelRegisterFunc&&o.cancelRegisterFunc(u,c,Sr(d)),o.cancelRegisterFunc=null}),X(fn(o),"getNamePath",function(){var l=o.props,c=l.name,u=l.fieldContext,d=u.prefixName,f=d===void 0?[]:d;return c!==void 0?[].concat(ze(f),ze(c)):[]}),X(fn(o),"getRules",function(){var l=o.props,c=l.rules,u=c===void 0?[]:c,d=l.fieldContext;return u.map(function(f){return typeof f=="function"?f(d):f})}),X(fn(o),"refresh",function(){o.mounted&&o.setState(function(l){var c=l.resetCount;return{resetCount:c+1}})}),X(fn(o),"metaCache",null),X(fn(o),"triggerMetaEvent",function(l){var c=o.props.onMetaChange;if(c){var u=Q(Q({},o.getMeta()),{},{destroy:l});a0(o.metaCache,u)||c(u),o.metaCache=u}else o.metaCache=null}),X(fn(o),"onStoreChange",function(l,c,u){var d=o.props,f=d.shouldUpdate,h=d.dependencies,m=h===void 0?[]:h,p=d.onReset,g=u.store,v=o.getNamePath(),y=o.getValue(l),b=o.getValue(g),w=c&&oc(c,v);switch(u.type==="valueUpdate"&&u.source==="external"&&!a0(y,b)&&(o.touched=!0,o.dirty=!0,o.validatePromise=null,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent()),u.type){case"reset":if(!c||w){o.touched=!1,o.dirty=!1,o.validatePromise=void 0,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent(),p==null||p(),o.refresh();return}break;case"remove":{if(f&&mm(f,l,g,y,b,u)){o.reRender();return}break}case"setField":{var x=u.data;if(w){"touched"in x&&(o.touched=x.touched),"validating"in x&&!("originRCField"in x)&&(o.validatePromise=x.validating?Promise.resolve([]):null),"errors"in x&&(o.errors=x.errors||Lo),"warnings"in x&&(o.warnings=x.warnings||Lo),o.dirty=!0,o.triggerMetaEvent(),o.reRender();return}else if("value"in x&&oc(c,v,!0)){o.reRender();return}if(f&&!v.length&&mm(f,l,g,y,b,u)){o.reRender();return}break}case"dependenciesUpdate":{var E=m.map(Sr);if(E.some(function(k){return oc(u.relatedFields,k)})){o.reRender();return}break}default:if(w||(!m.length||v.length||f)&&mm(f,l,g,y,b,u)){o.reRender();return}break}f===!0&&o.reRender()}),X(fn(o),"validateRules",function(l){var c=o.getNamePath(),u=o.getValue(),d=l||{},f=d.triggerName,h=d.validateOnly,m=h===void 0?!1:h,p=Promise.resolve().then(hl(fo().mark(function g(){var v,y,b,w,x,E,k;return fo().wrap(function(S){for(;;)switch(S.prev=S.next){case 0:if(o.mounted){S.next=2;break}return S.abrupt("return",[]);case 2:if(v=o.props,y=v.validateFirst,b=y===void 0?!1:y,w=v.messageVariables,x=v.validateDebounce,E=o.getRules(),f&&(E=E.filter(function(O){return O}).filter(function(O){var A=O.validateTrigger;if(!A)return!0;var $=O2(A);return $.includes(f)})),!(x&&f)){S.next=10;break}return S.next=8,new Promise(function(O){setTimeout(O,x)});case 8:if(o.validatePromise===p){S.next=10;break}return S.abrupt("return",[]);case 10:return k=MX(c,u,E,l,b,w),k.catch(function(O){return O}).then(function(){var O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Lo;if(o.validatePromise===p){var A;o.validatePromise=null;var $=[],M=[];(A=O.forEach)===null||A===void 0||A.call(O,function(N){var D=N.rule.warningOnly,T=N.errors,P=T===void 0?Lo:T;D?M.push.apply(M,ze(P)):$.push.apply($,ze(P))}),o.errors=$,o.warnings=M,o.triggerMetaEvent(),o.reRender()}}),S.abrupt("return",k);case 13:case"end":return S.stop()}},g)})));return m||(o.validatePromise=p,o.dirty=!0,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent(),o.reRender()),p}),X(fn(o),"isFieldValidating",function(){return!!o.validatePromise}),X(fn(o),"isFieldTouched",function(){return o.touched}),X(fn(o),"isFieldDirty",function(){if(o.dirty||o.props.initialValue!==void 0)return!0;var l=o.props.fieldContext,c=l.getInternalHooks(Rs),u=c.getInitialValue;return u(o.getNamePath())!==void 0}),X(fn(o),"getErrors",function(){return o.errors}),X(fn(o),"getWarnings",function(){return o.warnings}),X(fn(o),"isListField",function(){return o.props.isListField}),X(fn(o),"isList",function(){return o.props.isList}),X(fn(o),"isPreserve",function(){return o.props.preserve}),X(fn(o),"getMeta",function(){o.prevValidating=o.isFieldValidating();var l={touched:o.isFieldTouched(),validating:o.prevValidating,errors:o.errors,warnings:o.warnings,name:o.getNamePath(),validated:o.validatePromise===null};return l}),X(fn(o),"getOnlyChild",function(l){if(typeof l=="function"){var c=o.getMeta();return Q(Q({},o.getOnlyChild(l(o.getControlled(),c,o.props.fieldContext))),{},{isFunction:!0})}var u=fc(l);return u.length!==1||!C.isValidElement(u[0])?{child:u,isFunction:!1}:{child:u[0],isFunction:!1}}),X(fn(o),"getValue",function(l){var c=o.props.fieldContext.getFieldsValue,u=o.getNamePath();return ei(l||c(!0),u)}),X(fn(o),"getControlled",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=o.props,u=c.name,d=c.trigger,f=c.validateTrigger,h=c.getValueFromEvent,m=c.normalize,p=c.valuePropName,g=c.getValueProps,v=c.fieldContext,y=f!==void 0?f:v.validateTrigger,b=o.getNamePath(),w=v.getInternalHooks,x=v.getFieldsValue,E=w(Rs),k=E.dispatch,S=o.getValue(),O=g||function(D){return X({},p,D)},A=l[d],$=u!==void 0?O(S):{},M=Q(Q({},l),$);M[d]=function(){o.touched=!0,o.dirty=!0,o.triggerMetaEvent();for(var D,T=arguments.length,P=new Array(T),I=0;I<T;I++)P[I]=arguments[I];h?D=h.apply(void 0,P):D=FX.apply(void 0,[p].concat(P)),m&&(D=m(D,S,x(!0))),D!==S&&k({type:"updateValue",namePath:b,value:D}),A&&A.apply(void 0,P)};var N=O2(y||[]);return N.forEach(function(D){var T=M[D];M[D]=function(){T&&T.apply(void 0,arguments);var P=o.props.rules;P&&P.length&&k({type:"validateField",namePath:b,triggerName:D})}}),M}),r.fieldContext){var i=r.fieldContext.getInternalHooks,a=i(Rs),s=a.initEntityValue;s(fn(o))}return o}return Er(n,[{key:"componentDidMount",value:function(){var r=this.props,o=r.shouldUpdate,i=r.fieldContext;if(this.mounted=!0,i){var a=i.getInternalHooks,s=a(Rs),l=s.registerField;this.cancelRegisterFunc=l(this)}o===!0&&this.reRender()}},{key:"componentWillUnmount",value:function(){this.cancelRegister(),this.triggerMetaEvent(!0),this.mounted=!1}},{key:"reRender",value:function(){this.mounted&&this.forceUpdate()}},{key:"render",value:function(){var r=this.state.resetCount,o=this.props.children,i=this.getOnlyChild(o),a=i.child,s=i.isFunction,l;return s?l=a:C.isValidElement(a)?l=C.cloneElement(a,this.getControlled(a.props)):(qr(!a,"`children` of Field is not validate ReactElement."),l=a),C.createElement(C.Fragment,{key:r},l)}}]),n})(C.Component);X(YC,"contextType",el);X(YC,"defaultProps",{trigger:"onChange",valuePropName:"value"});function XC(e){var t,n=e.name,r=tn(e,PX),o=C.useContext(el),i=C.useContext(td),a=n!==void 0?Sr(n):void 0,s=(t=r.isListField)!==null&&t!==void 0?t:!!i,l="keep";return s||(l="_".concat((a||[]).join("_"))),C.createElement(YC,Qe({key:l,name:a,isListField:s},r,{fieldContext:o}))}function ZI(e){var t=e.name,n=e.initialValue,r=e.children,o=e.rules,i=e.validateTrigger,a=e.isListField,s=C.useContext(el),l=C.useContext(td),c=C.useRef({keys:[],id:0}),u=c.current,d=C.useMemo(function(){var p=Sr(s.prefixName)||[];return[].concat(ze(p),ze(Sr(t)))},[s.prefixName,t]),f=C.useMemo(function(){return Q(Q({},s),{},{prefixName:d})},[s,d]),h=C.useMemo(function(){return{getKey:function(p){var g=d.length,v=p[g];return[u.keys[v],p.slice(g+1)]}}},[d]);if(typeof r!="function")return qr(!1,"Form.List only accepts function as children."),null;var m=function(p,g,v){var y=v.source;return y==="internal"?!1:p!==g};return C.createElement(td.Provider,{value:h},C.createElement(el.Provider,{value:f},C.createElement(XC,{name:[],shouldUpdate:m,rules:o,validateTrigger:i,initialValue:n,isList:!0,isListField:a??!!l},function(p,g){var v=p.value,y=v===void 0?[]:v,b=p.onChange,w=s.getFieldValue,x=function(){var S=w(d||[]);return S||[]},E={add:function(S,O){var A=x();O>=0&&O<=A.length?(u.keys=[].concat(ze(u.keys.slice(0,O)),[u.id],ze(u.keys.slice(O))),b([].concat(ze(A.slice(0,O)),[S],ze(A.slice(O))))):(u.keys=[].concat(ze(u.keys),[u.id]),b([].concat(ze(A),[S]))),u.id+=1},remove:function(S){var O=x(),A=new Set(Array.isArray(S)?S:[S]);A.size<=0||(u.keys=u.keys.filter(function($,M){return!A.has(M)}),b(O.filter(function($,M){return!A.has(M)})))},move:function(S,O){if(S!==O){var A=x();S<0||S>=A.length||O<0||O>=A.length||(u.keys=E6(u.keys,S,O),b(E6(A,S,O)))}}},k=y||[];return Array.isArray(k)||(k=[]),r(k.map(function(S,O){var A=u.keys[O];return A===void 0&&(u.keys[O]=u.id,A=u.keys[O],u.id+=1),{name:O,key:A,isListField:!0}}),E,g)})))}function IX(e){var t=!1,n=e.length,r=[];return e.length?new Promise(function(o,i){e.forEach(function(a,s){a.catch(function(l){return t=!0,l}).then(function(l){n-=1,r[s]=l,!(n>0)&&(t&&i(r),o(r))})})}):Promise.resolve([])}var QI="__@field_split__";function vm(e){return e.map(function(t){return"".concat(At(t),":").concat(t)}).join(QI)}var Ml=(function(){function e(){xr(this,e),X(this,"kvs",new Map)}return Er(e,[{key:"set",value:function(t,n){this.kvs.set(vm(t),n)}},{key:"get",value:function(t){return this.kvs.get(vm(t))}},{key:"update",value:function(t,n){var r=this.get(t),o=n(r);o?this.set(t,o):this.delete(t)}},{key:"delete",value:function(t){this.kvs.delete(vm(t))}},{key:"map",value:function(t){return ze(this.kvs.entries()).map(function(n){var r=te(n,2),o=r[0],i=r[1],a=o.split(QI);return t({key:a.map(function(s){var l=s.match(/^([^:]*):(.*)$/),c=te(l,3),u=c[1],d=c[2];return u==="number"?Number(d):d}),value:i})})}},{key:"toJSON",value:function(){var t={};return this.map(function(n){var r=n.key,o=n.value;return t[r.join(".")]=o,null}),t}}]),e})(),BX=["name"],RX=Er(function e(t){var n=this;xr(this,e),X(this,"formHooked",!1),X(this,"forceRootUpdate",void 0),X(this,"subscribable",!0),X(this,"store",{}),X(this,"fieldEntities",[]),X(this,"initialValues",{}),X(this,"callbacks",{}),X(this,"validateMessages",null),X(this,"preserve",null),X(this,"lastValidatePromise",null),X(this,"getForm",function(){return{getFieldValue:n.getFieldValue,getFieldsValue:n.getFieldsValue,getFieldError:n.getFieldError,getFieldWarning:n.getFieldWarning,getFieldsError:n.getFieldsError,isFieldsTouched:n.isFieldsTouched,isFieldTouched:n.isFieldTouched,isFieldValidating:n.isFieldValidating,isFieldsValidating:n.isFieldsValidating,resetFields:n.resetFields,setFields:n.setFields,setFieldValue:n.setFieldValue,setFieldsValue:n.setFieldsValue,validateFields:n.validateFields,submit:n.submit,_init:!0,getInternalHooks:n.getInternalHooks}}),X(this,"getInternalHooks",function(r){return r===Rs?(n.formHooked=!0,{dispatch:n.dispatch,initEntityValue:n.initEntityValue,registerField:n.registerField,useSubscribe:n.useSubscribe,setInitialValues:n.setInitialValues,destroyForm:n.destroyForm,setCallbacks:n.setCallbacks,setValidateMessages:n.setValidateMessages,getFields:n.getFields,setPreserve:n.setPreserve,getInitialValue:n.getInitialValue,registerWatch:n.registerWatch}):(qr(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),X(this,"useSubscribe",function(r){n.subscribable=r}),X(this,"prevWithoutPreserves",null),X(this,"setInitialValues",function(r,o){if(n.initialValues=r||{},o){var i,a=Xl(r,n.store);(i=n.prevWithoutPreserves)===null||i===void 0||i.map(function(s){var l=s.key;a=Zo(a,l,ei(r,l))}),n.prevWithoutPreserves=null,n.updateStore(a)}}),X(this,"destroyForm",function(r){if(r)n.updateStore({});else{var o=new Ml;n.getFieldEntities(!0).forEach(function(i){n.isMergedPreserve(i.isPreserve())||o.set(i.getNamePath(),!0)}),n.prevWithoutPreserves=o}}),X(this,"getInitialValue",function(r){var o=ei(n.initialValues,r);return r.length?Xl(o):o}),X(this,"setCallbacks",function(r){n.callbacks=r}),X(this,"setValidateMessages",function(r){n.validateMessages=r}),X(this,"setPreserve",function(r){n.preserve=r}),X(this,"watchList",[]),X(this,"registerWatch",function(r){return n.watchList.push(r),function(){n.watchList=n.watchList.filter(function(o){return o!==r})}}),X(this,"notifyWatch",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(n.watchList.length){var o=n.getFieldsValue(),i=n.getFieldsValue(!0);n.watchList.forEach(function(a){a(o,i,r)})}}),X(this,"timeoutId",null),X(this,"warningUnhooked",function(){}),X(this,"updateStore",function(r){n.store=r}),X(this,"getFieldEntities",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return r?n.fieldEntities.filter(function(o){return o.getNamePath().length}):n.fieldEntities}),X(this,"getFieldsMap",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,o=new Ml;return n.getFieldEntities(r).forEach(function(i){var a=i.getNamePath();o.set(a,i)}),o}),X(this,"getFieldEntitiesForNamePathList",function(r){if(!r)return n.getFieldEntities(!0);var o=n.getFieldsMap(!0);return r.map(function(i){var a=Sr(i);return o.get(a)||{INVALIDATE_NAME_PATH:Sr(i)}})}),X(this,"getFieldsValue",function(r,o){n.warningUnhooked();var i,a,s;if(r===!0||Array.isArray(r)?(i=r,a=o):r&&At(r)==="object"&&(s=r.strict,a=r.filter),i===!0&&!a)return n.store;var l=n.getFieldEntitiesForNamePathList(Array.isArray(i)?i:null),c=[];return l.forEach(function(u){var d,f,h="INVALIDATE_NAME_PATH"in u?u.INVALIDATE_NAME_PATH:u.getNamePath();if(s){var m,p;if((m=(p=u).isList)!==null&&m!==void 0&&m.call(p))return}else if(!i&&(d=(f=u).isListField)!==null&&d!==void 0&&d.call(f))return;if(!a)c.push(h);else{var g="getMeta"in u?u.getMeta():null;a(g)&&c.push(h)}}),x6(n.store,c.map(Sr))}),X(this,"getFieldValue",function(r){n.warningUnhooked();var o=Sr(r);return ei(n.store,o)}),X(this,"getFieldsError",function(r){n.warningUnhooked();var o=n.getFieldEntitiesForNamePathList(r);return o.map(function(i,a){return i&&!("INVALIDATE_NAME_PATH"in i)?{name:i.getNamePath(),errors:i.getErrors(),warnings:i.getWarnings()}:{name:Sr(r[a]),errors:[],warnings:[]}})}),X(this,"getFieldError",function(r){n.warningUnhooked();var o=Sr(r),i=n.getFieldsError([o])[0];return i.errors}),X(this,"getFieldWarning",function(r){n.warningUnhooked();var o=Sr(r),i=n.getFieldsError([o])[0];return i.warnings}),X(this,"isFieldsTouched",function(){n.warningUnhooked();for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=o[0],s=o[1],l,c=!1;o.length===0?l=null:o.length===1?Array.isArray(a)?(l=a.map(Sr),c=!1):(l=null,c=a):(l=a.map(Sr),c=s);var u=n.getFieldEntities(!0),d=function(p){return p.isFieldTouched()};if(!l)return c?u.every(function(p){return d(p)||p.isList()}):u.some(d);var f=new Ml;l.forEach(function(p){f.set(p,[])}),u.forEach(function(p){var g=p.getNamePath();l.forEach(function(v){v.every(function(y,b){return g[b]===y})&&f.update(v,function(y){return[].concat(ze(y),[p])})})});var h=function(p){return p.some(d)},m=f.map(function(p){var g=p.value;return g});return c?m.every(h):m.some(h)}),X(this,"isFieldTouched",function(r){return n.warningUnhooked(),n.isFieldsTouched([r])}),X(this,"isFieldsValidating",function(r){n.warningUnhooked();var o=n.getFieldEntities();if(!r)return o.some(function(a){return a.isFieldValidating()});var i=r.map(Sr);return o.some(function(a){var s=a.getNamePath();return oc(i,s)&&a.isFieldValidating()})}),X(this,"isFieldValidating",function(r){return n.warningUnhooked(),n.isFieldsValidating([r])}),X(this,"resetWithFieldInitialValue",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=new Ml,i=n.getFieldEntities(!0);i.forEach(function(l){var c=l.props.initialValue,u=l.getNamePath();if(c!==void 0){var d=o.get(u)||new Set;d.add({entity:l,value:c}),o.set(u,d)}});var a=function(l){l.forEach(function(c){var u=c.props.initialValue;if(u!==void 0){var d=c.getNamePath(),f=n.getInitialValue(d);if(f!==void 0)qr(!1,"Form already set 'initialValues' with path '".concat(d.join("."),"'. Field can not overwrite it."));else{var h=o.get(d);if(h&&h.size>1)qr(!1,"Multiple Field with path '".concat(d.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(h){var m=n.getFieldValue(d),p=c.isListField();!p&&(!r.skipExist||m===void 0)&&n.updateStore(Zo(n.store,d,ze(h)[0].value))}}}})},s;r.entities?s=r.entities:r.namePathList?(s=[],r.namePathList.forEach(function(l){var c=o.get(l);if(c){var u;(u=s).push.apply(u,ze(ze(c).map(function(d){return d.entity})))}})):s=i,a(s)}),X(this,"resetFields",function(r){n.warningUnhooked();var o=n.store;if(!r){n.updateStore(Xl(n.initialValues)),n.resetWithFieldInitialValue(),n.notifyObservers(o,null,{type:"reset"}),n.notifyWatch();return}var i=r.map(Sr);i.forEach(function(a){var s=n.getInitialValue(a);n.updateStore(Zo(n.store,a,s))}),n.resetWithFieldInitialValue({namePathList:i}),n.notifyObservers(o,i,{type:"reset"}),n.notifyWatch(i)}),X(this,"setFields",function(r){n.warningUnhooked();var o=n.store,i=[];r.forEach(function(a){var s=a.name,l=tn(a,BX),c=Sr(s);i.push(c),"value"in l&&n.updateStore(Zo(n.store,c,l.value)),n.notifyObservers(o,[c],{type:"setField",data:a})}),n.notifyWatch(i)}),X(this,"getFields",function(){var r=n.getFieldEntities(!0),o=r.map(function(i){var a=i.getNamePath(),s=i.getMeta(),l=Q(Q({},s),{},{name:a,value:n.getFieldValue(a)});return Object.defineProperty(l,"originRCField",{value:!0}),l});return o}),X(this,"initEntityValue",function(r){var o=r.props.initialValue;if(o!==void 0){var i=r.getNamePath(),a=ei(n.store,i);a===void 0&&n.updateStore(Zo(n.store,i,o))}}),X(this,"isMergedPreserve",function(r){var o=r!==void 0?r:n.preserve;return o??!0}),X(this,"registerField",function(r){n.fieldEntities.push(r);var o=r.getNamePath();if(n.notifyWatch([o]),r.props.initialValue!==void 0){var i=n.store;n.resetWithFieldInitialValue({entities:[r],skipExist:!0}),n.notifyObservers(i,[r.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(a,s){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(n.fieldEntities=n.fieldEntities.filter(function(d){return d!==r}),!n.isMergedPreserve(s)&&(!a||l.length>1)){var c=a?void 0:n.getInitialValue(o);if(o.length&&n.getFieldValue(o)!==c&&n.fieldEntities.every(function(d){return!KI(d.getNamePath(),o)})){var u=n.store;n.updateStore(Zo(u,o,c,!0)),n.notifyObservers(u,[o],{type:"remove"}),n.triggerDependenciesUpdate(u,o)}}n.notifyWatch([o])}}),X(this,"dispatch",function(r){switch(r.type){case"updateValue":{var o=r.namePath,i=r.value;n.updateValue(o,i);break}case"validateField":{var a=r.namePath,s=r.triggerName;n.validateFields([a],{triggerName:s});break}}}),X(this,"notifyObservers",function(r,o,i){if(n.subscribable){var a=Q(Q({},i),{},{store:n.getFieldsValue(!0)});n.getFieldEntities().forEach(function(s){var l=s.onStoreChange;l(r,o,a)})}else n.forceRootUpdate()}),X(this,"triggerDependenciesUpdate",function(r,o){var i=n.getDependencyChildrenFields(o);return i.length&&n.validateFields(i),n.notifyObservers(r,i,{type:"dependenciesUpdate",relatedFields:[o].concat(ze(i))}),i}),X(this,"updateValue",function(r,o){var i=Sr(r),a=n.store;n.updateStore(Zo(n.store,i,o)),n.notifyObservers(a,[i],{type:"valueUpdate",source:"internal"}),n.notifyWatch([i]);var s=n.triggerDependenciesUpdate(a,i),l=n.callbacks.onValuesChange;if(l){var c=x6(n.store,[i]);l(c,n.getFieldsValue())}n.triggerOnFieldsChange([i].concat(ze(s)))}),X(this,"setFieldsValue",function(r){n.warningUnhooked();var o=n.store;if(r){var i=Xl(n.store,r);n.updateStore(i)}n.notifyObservers(o,null,{type:"valueUpdate",source:"external"}),n.notifyWatch()}),X(this,"setFieldValue",function(r,o){n.setFields([{name:r,value:o,errors:[],warnings:[]}])}),X(this,"getDependencyChildrenFields",function(r){var o=new Set,i=[],a=new Ml;n.getFieldEntities().forEach(function(l){var c=l.props.dependencies;(c||[]).forEach(function(u){var d=Sr(u);a.update(d,function(){var f=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return f.add(l),f})})});var s=function l(c){var u=a.get(c)||new Set;u.forEach(function(d){if(!o.has(d)){o.add(d);var f=d.getNamePath();d.isFieldDirty()&&f.length&&(i.push(f),l(f))}})};return s(r),i}),X(this,"triggerOnFieldsChange",function(r,o){var i=n.callbacks.onFieldsChange;if(i){var a=n.getFields();if(o){var s=new Ml;o.forEach(function(c){var u=c.name,d=c.errors;s.set(u,d)}),a.forEach(function(c){c.errors=s.get(c.name)||c.errors})}var l=a.filter(function(c){var u=c.name;return oc(r,u)});l.length&&i(l,a)}}),X(this,"validateFields",function(r,o){n.warningUnhooked();var i,a;Array.isArray(r)||typeof r=="string"||typeof o=="string"?(i=r,a=o):a=r;var s=!!i,l=s?i.map(Sr):[],c=[],u=String(Date.now()),d=new Set,f=a||{},h=f.recursive,m=f.dirty;n.getFieldEntities(!0).forEach(function(y){if(s||l.push(y.getNamePath()),!(!y.props.rules||!y.props.rules.length)&&!(m&&!y.isFieldDirty())){var b=y.getNamePath();if(d.add(b.join(u)),!s||oc(l,b,h)){var w=y.validateRules(Q({validateMessages:Q(Q({},XI),n.validateMessages)},a));c.push(w.then(function(){return{name:b,errors:[],warnings:[]}}).catch(function(x){var E,k=[],S=[];return(E=x.forEach)===null||E===void 0||E.call(x,function(O){var A=O.rule.warningOnly,$=O.errors;A?S.push.apply(S,ze($)):k.push.apply(k,ze($))}),k.length?Promise.reject({name:b,errors:k,warnings:S}):{name:b,errors:k,warnings:S}}))}}});var p=IX(c);n.lastValidatePromise=p,p.catch(function(y){return y}).then(function(y){var b=y.map(function(w){var x=w.name;return x});n.notifyObservers(n.store,b,{type:"validateFinish"}),n.triggerOnFieldsChange(b,y)});var g=p.then(function(){return n.lastValidatePromise===p?Promise.resolve(n.getFieldsValue(l)):Promise.reject([])}).catch(function(y){var b=y.filter(function(w){return w&&w.errors.length});return Promise.reject({values:n.getFieldsValue(l),errorFields:b,outOfDate:n.lastValidatePromise!==p})});g.catch(function(y){return y});var v=l.filter(function(y){return d.has(y.join(u))});return n.triggerOnFieldsChange(v),g}),X(this,"submit",function(){n.warningUnhooked(),n.validateFields().then(function(r){var o=n.callbacks.onFinish;if(o)try{o(r)}catch(i){console.error(i)}}).catch(function(r){var o=n.callbacks.onFinishFailed;o&&o(r)})}),this.forceRootUpdate=t});function KC(e){var t=C.useRef(),n=C.useState({}),r=te(n,2),o=r[1];if(!t.current)if(e)t.current=e;else{var i=function(){o({})},a=new RX(i);t.current=a.getForm()}return[t.current]}var R2=C.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),JI=function(e){var t=e.validateMessages,n=e.onFormChange,r=e.onFormFinish,o=e.children,i=C.useContext(R2),a=C.useRef({});return C.createElement(R2.Provider,{value:Q(Q({},i),{},{validateMessages:Q(Q({},i.validateMessages),t),triggerFormChange:function(s,l){n&&n(s,{changedFields:l,forms:a.current}),i.triggerFormChange(s,l)},triggerFormFinish:function(s,l){r&&r(s,{values:l,forms:a.current}),i.triggerFormFinish(s,l)},registerForm:function(s,l){s&&(a.current=Q(Q({},a.current),{},X({},s,l))),i.registerForm(s,l)},unregisterForm:function(s){var l=Q({},a.current);delete l[s],a.current=l,i.unregisterForm(s)}})},o)},_X=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed","clearOnDestroy"],jX=function(e,t){var n=e.name,r=e.initialValues,o=e.fields,i=e.form,a=e.preserve,s=e.children,l=e.component,c=l===void 0?"form":l,u=e.validateMessages,d=e.validateTrigger,f=d===void 0?"onChange":d,h=e.onValuesChange,m=e.onFieldsChange,p=e.onFinish,g=e.onFinishFailed,v=e.clearOnDestroy,y=tn(e,_X),b=C.useRef(null),w=C.useContext(R2),x=KC(i),E=te(x,1),k=E[0],S=k.getInternalHooks(Rs),O=S.useSubscribe,A=S.setInitialValues,$=S.setCallbacks,M=S.setValidateMessages,N=S.setPreserve,D=S.destroyForm;C.useImperativeHandle(t,function(){return Q(Q({},k),{},{nativeElement:b.current})}),C.useEffect(function(){return w.registerForm(n,k),function(){w.unregisterForm(n)}},[w,k,n]),M(Q(Q({},w.validateMessages),u)),$({onValuesChange:h,onFieldsChange:function(j){if(w.triggerFormChange(n,j),m){for(var _=arguments.length,F=new Array(_>1?_-1:0),B=1;B<_;B++)F[B-1]=arguments[B];m.apply(void 0,[j].concat(F))}},onFinish:function(j){w.triggerFormFinish(n,j),p&&p(j)},onFinishFailed:g}),N(a);var T=C.useRef(null);A(r,!T.current),T.current||(T.current=!0),C.useEffect(function(){return function(){return D(v)}},[]);var P,I=typeof s=="function";if(I){var R=k.getFieldsValue(!0);P=s(R,k)}else P=s;O(!I);var H=C.useRef();C.useEffect(function(){TX(H.current||[],o||[])||k.setFields(o||[]),H.current=o},[o,k]);var V=C.useMemo(function(){return Q(Q({},k),{},{validateTrigger:f})},[k,f]),L=C.createElement(td.Provider,{value:null},C.createElement(el.Provider,{value:V},P));return c===!1?L:C.createElement(c,Qe({},y,{ref:b,onSubmit:function(j){j.preventDefault(),j.stopPropagation(),k.submit()},onReset:function(j){var _;j.preventDefault(),k.resetFields(),(_=y.onReset)===null||_===void 0||_.call(y,j)}}),L)};function w6(e){try{return JSON.stringify(e)}catch{return Math.random()}}function eB(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],o=t[1],i=o===void 0?{}:o,a=KY(i)?{form:i}:i,s=a.form,l=nt(),c=te(l,2),u=c[0],d=c[1],f=Gt(function(){return w6(u)},[u]),h=et(f);h.current=f;var m=pr(el),p=s||m,g=p&&p._init,v=Sr(r),y=et(v);return y.current=v,Et(function(){if(g){var b=p.getFieldsValue,w=p.getInternalHooks,x=w(Rs),E=x.registerWatch,k=function(A,$){var M=a.preserve?$:A;return typeof r=="function"?r(M):ei(M,y.current)},S=E(function(A,$){var M=k(A,$),N=w6(M);h.current!==N&&(h.current=N,d(M))}),O=k(b(),b(!0));return u!==O&&d(O),S}},[g]),u}var LX=C.forwardRef(jX),Tc=LX;Tc.FormProvider=JI;Tc.Field=XC;Tc.List=ZI;Tc.useForm=KC;Tc.useWatch=eB;const ma=C.createContext({labelAlign:"right",layout:"horizontal",itemRef:()=>{}}),tB=C.createContext(null),nB=e=>{const t=ta(e,["prefixCls"]);return C.createElement(JI,Object.assign({},t))},ZC=C.createContext({prefixCls:""}),Yr=C.createContext({}),rB=({children:e,status:t,override:n})=>{const r=C.useContext(Yr),o=C.useMemo(()=>{const i=Object.assign({},r);return n&&delete i.isFormItemInput,t&&(delete i.status,delete i.hasFeedback,delete i.feedbackIcon),i},[t,n,r]);return C.createElement(Yr.Provider,{value:o},e)},oB=C.createContext(void 0),ts=e=>{const{space:t,form:n,children:r}=e;if(r==null)return null;let o=r;return n&&(o=we.createElement(rB,{override:!0,status:!0},o)),t&&(o=we.createElement(Sq,null,o)),o},zX=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"}}}},HX=e=>{const{componentCls:t}=e;return{[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},WX=(e,t)=>{const{prefixCls:n,componentCls:r,gridColumns:o}=e,i={};for(let a=o;a>=0;a--)a===0?(i[`${r}${t}-${a}`]={display:"none"},i[`${r}-push-${a}`]={insetInlineStart:"auto"},i[`${r}-pull-${a}`]={insetInlineEnd:"auto"},i[`${r}${t}-push-${a}`]={insetInlineStart:"auto"},i[`${r}${t}-pull-${a}`]={insetInlineEnd:"auto"},i[`${r}${t}-offset-${a}`]={marginInlineStart:0},i[`${r}${t}-order-${a}`]={order:0}):(i[`${r}${t}-${a}`]=[{"--ant-display":"block",display:"block"},{display:"var(--ant-display)",flex:`0 0 ${a/o*100}%`,maxWidth:`${a/o*100}%`}],i[`${r}${t}-push-${a}`]={insetInlineStart:`${a/o*100}%`},i[`${r}${t}-pull-${a}`]={insetInlineEnd:`${a/o*100}%`},i[`${r}${t}-offset-${a}`]={marginInlineStart:`${a/o*100}%`},i[`${r}${t}-order-${a}`]={order:a});return i[`${r}${t}-flex`]={flex:`var(--${n}${t}-flex)`},i},_2=(e,t)=>WX(e,t),VX=(e,t,n)=>({[`@media (min-width: ${Ce(t)})`]:Object.assign({},_2(e,n))}),GX=()=>({}),UX=()=>({}),qX=Pr("Grid",zX,GX),YX=e=>({xs:e.screenXSMin,sm:e.screenSMMin,md:e.screenMDMin,lg:e.screenLGMin,xl:e.screenXLMin,xxl:e.screenXXLMin}),XX=Pr("Grid",e=>{const t=Mn(e,{gridColumns:24}),n=YX(t);return delete n.xs,[HX(t),_2(t,""),_2(t,"-xs"),Object.keys(n).map(r=>VX(t,n[r],`-${r}`)).reduce((r,o)=>Object.assign(Object.assign({},r),o),{})]},UX),KX=we.createContext({});function ZX(e){return t=>C.createElement(hs,{theme:{token:{motion:!1,zIndexPopupBase:0}}},C.createElement(e,Object.assign({},t)))}const QC=(e,t,n,r,o)=>ZX(i=>{const{prefixCls:a,style:s}=i,l=C.useRef(null),[c,u]=C.useState(0),[d,f]=C.useState(0),[h,m]=yr(!1,{value:i.open}),{getPrefixCls:p}=C.useContext(pn),g=p(r||"select",a);C.useEffect(()=>{if(m(!0),typeof ResizeObserver<"u"){const b=new ResizeObserver(x=>{const E=x[0].target;u(E.offsetHeight+8),f(E.offsetWidth)}),w=setInterval(()=>{var x;const E=`.${g}-dropdown`,k=(x=l.current)===null||x===void 0?void 0:x.querySelector(E);k&&(clearInterval(w),b.observe(k))},10);return()=>{clearInterval(w),b.disconnect()}}},[g]);let v=Object.assign(Object.assign({},i),{style:Object.assign(Object.assign({},s),{margin:0}),open:h,visible:h,getPopupContainer:()=>l.current});t&&Object.assign(v,{[t]:{overflow:{adjustX:!1,adjustY:!1}}});const y={paddingBottom:c,position:"relative",minWidth:d};return C.createElement("div",{ref:l,style:y},C.createElement(e,Object.assign({},v)))}),JC=(function(){if(typeof navigator>"u"||typeof window>"u")return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|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|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(e==null?void 0:e.substr(0,4))});var Dp=function(e){var t=e.className,n=e.customizeIcon,r=e.customizeIconProps,o=e.children,i=e.onMouseDown,a=e.onClick,s=typeof n=="function"?n(r):n;return C.createElement("span",{className:t,onMouseDown:function(l){l.preventDefault(),i==null||i(l)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:a,"aria-hidden":!0},s!==void 0?s:C.createElement("span",{className:me(t.split(/\s+/).map(function(l){return"".concat(l,"-icon")}))},o))},QX=function(e,t,n,r,o){var i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,a=arguments.length>6?arguments[6]:void 0,s=arguments.length>7?arguments[7]:void 0,l=we.useMemo(function(){if(At(r)==="object")return r.clearIcon;if(o)return o},[r,o]),c=we.useMemo(function(){return!!(!i&&r&&(n.length||a)&&!(s==="combobox"&&a===""))},[r,i,n.length,a,s]);return{allowClear:c,clearIcon:we.createElement(Dp,{className:"".concat(e,"-clear"),onMouseDown:t,customizeIcon:l},"\xD7")}},iB=C.createContext(null);function JX(){return C.useContext(iB)}function eK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,t=C.useState(!1),n=te(t,2),r=n[0],o=n[1],i=C.useRef(null),a=function(){window.clearTimeout(i.current)};C.useEffect(function(){return a},[]);var s=function(l,c){a(),i.current=window.setTimeout(function(){o(l),c&&c()},e)};return[r,s,a]}function aB(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,t=C.useRef(null),n=C.useRef(null);C.useEffect(function(){return function(){window.clearTimeout(n.current)}},[]);function r(o){(o||t.current===null)&&(t.current=o),window.clearTimeout(n.current),n.current=window.setTimeout(function(){t.current=null},e)}return[function(){return t.current},r]}function tK(e,t,n,r){var o=C.useRef(null);o.current={open:t,triggerOpen:n,customizedTrigger:r},C.useEffect(function(){function i(a){var s;if(!((s=o.current)!==null&&s!==void 0&&s.customizedTrigger)){var l=a.target;l.shadowRoot&&a.composed&&(l=a.composedPath()[0]||l),o.current.open&&e().filter(function(c){return c}).every(function(c){return!c.contains(l)&&c!==l})&&o.current.triggerOpen(!1)}}return window.addEventListener("mousedown",i),function(){return window.removeEventListener("mousedown",i)}},[])}function nK(e){return e&&![St.ESC,St.SHIFT,St.BACKSPACE,St.TAB,St.WIN_KEY,St.ALT,St.META,St.WIN_KEY_RIGHT,St.CTRL,St.SEMICOLON,St.EQUALS,St.CAPS_LOCK,St.CONTEXT_MENU,St.F1,St.F2,St.F3,St.F4,St.F5,St.F6,St.F7,St.F8,St.F9,St.F10,St.F11,St.F12].includes(e)}var rK=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],Nl=void 0;function oK(e,t){var n=e.prefixCls,r=e.invalidate,o=e.item,i=e.renderItem,a=e.responsive,s=e.responsiveDisabled,l=e.registerSize,c=e.itemKey,u=e.className,d=e.style,f=e.children,h=e.display,m=e.order,p=e.component,g=p===void 0?"div":p,v=tn(e,rK),y=a&&!h;function b(S){l(c,S)}C.useEffect(function(){return function(){b(null)}},[]);var w=i&&o!==Nl?i(o,{index:m}):f,x;r||(x={opacity:y?0:1,height:y?0:Nl,overflowY:y?"hidden":Nl,order:a?m:Nl,pointerEvents:y?"none":Nl,position:y?"absolute":Nl});var E={};y&&(E["aria-hidden"]=!0);var k=C.createElement(g,Qe({className:me(!r&&n,u),style:Q(Q({},x),d)},E,v,{ref:t}),w);return a&&(k=C.createElement(ea,{onResize:function(S){var O=S.offsetWidth;b(O)},disabled:s},k)),k}var Ql=C.forwardRef(oK);Ql.displayName="Item";function iK(e){if(typeof MessageChannel>"u")en(e);else{var t=new MessageChannel;t.port1.onmessage=function(){return e()},t.port2.postMessage(void 0)}}function aK(){var e=C.useRef(null),t=function(n){e.current||(e.current=[],iK(function(){Qz(function(){e.current.forEach(function(r){r()}),e.current=null})})),e.current.push(n)};return t}function Dl(e,t){var n=C.useState(t),r=te(n,2),o=r[0],i=r[1],a=cn(function(s){e(function(){i(s)})});return[o,a]}var g0=we.createContext(null),sK=["component"],lK=["className"],cK=["className"],uK=function(e,t){var n=C.useContext(g0);if(!n){var r=e.component,o=r===void 0?"div":r,i=tn(e,sK);return C.createElement(o,Qe({},i,{ref:t}))}var a=n.className,s=tn(n,lK),l=e.className,c=tn(e,cK);return C.createElement(g0.Provider,{value:null},C.createElement(Ql,Qe({ref:t,className:me(a,l)},s,c)))},sB=C.forwardRef(uK);sB.displayName="RawItem";var dK=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","prefix","suffix","component","itemComponent","onVisibleChange"],lB="responsive",cB="invalidate";function fK(e){return"+ ".concat(e.length," ...")}function hK(e,t){var n=e.prefixCls,r=n===void 0?"rc-overflow":n,o=e.data,i=o===void 0?[]:o,a=e.renderItem,s=e.renderRawItem,l=e.itemKey,c=e.itemWidth,u=c===void 0?10:c,d=e.ssr,f=e.style,h=e.className,m=e.maxCount,p=e.renderRest,g=e.renderRawRest,v=e.prefix,y=e.suffix,b=e.component,w=b===void 0?"div":b,x=e.itemComponent,E=e.onVisibleChange,k=tn(e,dK),S=d==="full",O=aK(),A=Dl(O,null),$=te(A,2),M=$[0],N=$[1],D=M||0,T=Dl(O,new Map),P=te(T,2),I=P[0],R=P[1],H=Dl(O,0),V=te(H,2),L=V[0],j=V[1],_=Dl(O,0),F=te(_,2),B=F[0],z=F[1],G=Dl(O,0),W=te(G,2),q=W[0],U=W[1],Y=Dl(O,0),ie=te(Y,2),K=ie[0],re=ie[1],oe=nt(null),ne=te(oe,2),ae=ne[0],de=ne[1],ge=nt(null),Se=te(ge,2),ye=Se[0],be=Se[1],ce=C.useMemo(function(){return ye===null&&S?Number.MAX_SAFE_INTEGER:ye||0},[ye,M]),he=nt(!1),Te=te(he,2),se=Te[0],Pe=Te[1],De="".concat(r,"-item"),He=Math.max(L,B),ue=m===lB,ve=i.length&&ue,xe=m===cB,fe=ve||typeof m=="number"&&i.length>m,pe=Gt(function(){var Ne=i;return ve?M===null&&S?Ne=i:Ne=i.slice(0,Math.min(i.length,D/u)):typeof m=="number"&&(Ne=i.slice(0,m)),Ne},[i,u,M,m,ve]),ke=Gt(function(){return ve?i.slice(ce+1):i.slice(pe.length)},[i,pe,ve,ce]),Ve=Yl(function(Ne,Oe){var _e;return typeof l=="function"?l(Ne):(_e=l&&(Ne==null?void 0:Ne[l]))!==null&&_e!==void 0?_e:Oe},[l]),Ee=Yl(a||function(Ne){return Ne},[a]);function yt(Ne,Oe,_e){ye===Ne&&(Oe===void 0||Oe===ae)||(be(Ne),_e||(Pe(Ne<i.length-1),E==null||E(Ne)),Oe!==void 0&&de(Oe))}function Dt(Ne,Oe){N(Oe.clientWidth)}function Ft(Ne,Oe){R(function(_e){var mt=new Map(_e);return Oe===null?mt.delete(Ne):mt.set(Ne,Oe),mt})}function Ut(Ne,Oe){z(Oe),j(B)}function Ge(Ne,Oe){U(Oe)}function Xe(Ne,Oe){re(Oe)}function qe(Ne){return I.get(Ve(pe[Ne],Ne))}mn(function(){if(D&&typeof He=="number"&&pe){var Ne=q+K,Oe=pe.length,_e=Oe-1;if(!Oe){yt(0,null);return}for(var mt=0;mt<Oe;mt+=1){var kt=qe(mt);if(S&&(kt=kt||0),kt===void 0){yt(mt-1,void 0,!0);break}if(Ne+=kt,_e===0&&Ne<=D||mt===_e-1&&Ne+qe(_e)<=D){yt(_e,null);break}else if(Ne+He>D){yt(mt-1,Ne-kt-K+B);break}}y&&qe(0)+K>D&&de(null)}},[D,I,B,q,K,Ve,pe]);var lt=se&&!!ke.length,je={};ae!==null&&ve&&(je={position:"absolute",left:ae,top:0});var Rt={prefixCls:De,responsive:ve,component:x,invalidate:xe},zt=s?function(Ne,Oe){var _e=Ve(Ne,Oe);return C.createElement(g0.Provider,{key:_e,value:Q(Q({},Rt),{},{order:Oe,item:Ne,itemKey:_e,registerSize:Ft,display:Oe<=ce})},s(Ne,Oe))}:function(Ne,Oe){var _e=Ve(Ne,Oe);return C.createElement(Ql,Qe({},Rt,{order:Oe,key:_e,item:Ne,renderItem:Ee,itemKey:_e,registerSize:Ft,display:Oe<=ce}))},dt={order:lt?ce:Number.MAX_SAFE_INTEGER,className:"".concat(De,"-rest"),registerSize:Ut,display:lt},Ct=p||fK,jt=g?C.createElement(g0.Provider,{value:Q(Q({},Rt),dt)},g(ke)):C.createElement(Ql,Qe({},Rt,dt),typeof Ct=="function"?Ct(ke):Ct),Ie=C.createElement(w,Qe({className:me(!xe&&r,h),style:f,ref:t},k),v&&C.createElement(Ql,Qe({},Rt,{responsive:ue,responsiveDisabled:!ve,order:-1,className:"".concat(De,"-prefix"),registerSize:Ge,display:!0}),v),pe.map(zt),fe?jt:null,y&&C.createElement(Ql,Qe({},Rt,{responsive:ue,responsiveDisabled:!ve,order:ce,className:"".concat(De,"-suffix"),registerSize:Xe,display:!0,style:je}),y));return ue?C.createElement(ea,{onResize:Dt,disabled:!ve},Ie):Ie}var Fc=C.forwardRef(hK);Fc.displayName="Overflow";Fc.Item=sB;Fc.RESPONSIVE=lB;Fc.INVALIDATE=cB;function pK(e,t,n){var r=Q(Q({},e),t);return Object.keys(t).forEach(function(o){var i=t[o];typeof i=="function"&&(r[o]=function(){for(var a,s=arguments.length,l=new Array(s),c=0;c<s;c++)l[c]=arguments[c];return i.apply(void 0,l),(a=e[o])===null||a===void 0?void 0:a.call.apply(a,[e].concat(l))})}),r}var gK=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],mK=function(e,t){var n=e.prefixCls,r=e.id,o=e.inputElement,i=e.autoFocus,a=e.autoComplete,s=e.editable,l=e.activeDescendantId,c=e.value,u=e.open,d=e.attrs,f=tn(e,gK),h=o||C.createElement("input",null),m=h,p=m.ref,g=m.props;return"maxLength"in h.props,h=C.cloneElement(h,Q(Q(Q({type:"search"},pK(f,g)),{},{id:r,ref:oi(t,p),autoComplete:a||"off",autoFocus:i,className:me("".concat(n,"-selection-search-input"),g==null?void 0:g.className),role:"combobox","aria-expanded":u||!1,"aria-haspopup":"listbox","aria-owns":"".concat(r,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(r,"_list"),"aria-activedescendant":u?l:void 0},d),{},{value:s?c:"",readOnly:!s,unselectable:s?null:"on",style:Q(Q({},g.style),{},{opacity:s?null:0})})),h},uB=C.forwardRef(mK);function dB(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}var vK=typeof window<"u"&&window.document&&window.document.documentElement,yK=vK;function bK(e){return e!=null}function xK(e){return!e&&e!==0}function C6(e){return["string","number"].includes(At(e))}function fB(e){var t=void 0;return e&&(C6(e.title)?t=e.title.toString():C6(e.label)&&(t=e.label.toString())),t}function EK(e,t){yK?C.useLayoutEffect(e,t):C.useEffect(e,t)}function wK(e){var t;return(t=e.key)!==null&&t!==void 0?t:e.value}var k6=function(e){e.preventDefault(),e.stopPropagation()},CK=function(e){var t=e.id,n=e.prefixCls,r=e.values,o=e.open,i=e.searchValue,a=e.autoClearSearchValue,s=e.inputRef,l=e.placeholder,c=e.disabled,u=e.mode,d=e.showSearch,f=e.autoFocus,h=e.autoComplete,m=e.activeDescendantId,p=e.tabIndex,g=e.removeIcon,v=e.maxTagCount,y=e.maxTagTextLength,b=e.maxTagPlaceholder,w=b===void 0?function(K){return"+ ".concat(K.length," ...")}:b,x=e.tagRender,E=e.onToggleOpen,k=e.onRemove,S=e.onInputChange,O=e.onInputPaste,A=e.onInputKeyDown,$=e.onInputMouseDown,M=e.onInputCompositionStart,N=e.onInputCompositionEnd,D=e.onInputBlur,T=C.useRef(null),P=nt(0),I=te(P,2),R=I[0],H=I[1],V=nt(!1),L=te(V,2),j=L[0],_=L[1],F="".concat(n,"-selection"),B=o||u==="multiple"&&a===!1||u==="tags"?i:"",z=u==="tags"||u==="multiple"&&a===!1||d&&(o||j);EK(function(){H(T.current.scrollWidth)},[B]);var G=function(K,re,oe,ne,ae){return C.createElement("span",{title:fB(K),className:me("".concat(F,"-item"),X({},"".concat(F,"-item-disabled"),oe))},C.createElement("span",{className:"".concat(F,"-item-content")},re),ne&&C.createElement(Dp,{className:"".concat(F,"-item-remove"),onMouseDown:k6,onClick:ae,customizeIcon:g},"\xD7"))},W=function(K,re,oe,ne,ae,de){var ge=function(Se){k6(Se),E(!o)};return C.createElement("span",{onMouseDown:ge},x({label:re,value:K,disabled:oe,closable:ne,onClose:ae,isMaxTag:!!de}))},q=function(K){var re=K.disabled,oe=K.label,ne=K.value,ae=!c&&!re,de=oe;if(typeof y=="number"&&(typeof oe=="string"||typeof oe=="number")){var ge=String(de);ge.length>y&&(de="".concat(ge.slice(0,y),"..."))}var Se=function(ye){ye&&ye.stopPropagation(),k(K)};return typeof x=="function"?W(ne,de,re,ae,Se):G(K,de,re,ae,Se)},U=function(K){if(!r.length)return null;var re=typeof w=="function"?w(K):w;return typeof x=="function"?W(void 0,re,!1,!1,void 0,!0):G({title:re},re,!1)},Y=C.createElement("div",{className:"".concat(F,"-search"),style:{width:R},onFocus:function(){_(!0)},onBlur:function(){_(!1)}},C.createElement(uB,{ref:s,open:o,prefixCls:n,id:t,inputElement:null,disabled:c,autoFocus:f,autoComplete:h,editable:z,activeDescendantId:m,value:B,onKeyDown:A,onMouseDown:$,onChange:S,onPaste:O,onCompositionStart:M,onCompositionEnd:N,onBlur:D,tabIndex:p,attrs:Si(e,!0)}),C.createElement("span",{ref:T,className:"".concat(F,"-search-mirror"),"aria-hidden":!0},B,"\xA0")),ie=C.createElement(Fc,{prefixCls:"".concat(F,"-overflow"),data:r,renderItem:q,renderRest:U,suffix:Y,itemKey:wK,maxCount:v});return C.createElement("span",{className:"".concat(F,"-wrap")},ie,!r.length&&!B&&C.createElement("span",{className:"".concat(F,"-placeholder")},l))},kK=function(e){var t=e.inputElement,n=e.prefixCls,r=e.id,o=e.inputRef,i=e.disabled,a=e.autoFocus,s=e.autoComplete,l=e.activeDescendantId,c=e.mode,u=e.open,d=e.values,f=e.placeholder,h=e.tabIndex,m=e.showSearch,p=e.searchValue,g=e.activeValue,v=e.maxLength,y=e.onInputKeyDown,b=e.onInputMouseDown,w=e.onInputChange,x=e.onInputPaste,E=e.onInputCompositionStart,k=e.onInputCompositionEnd,S=e.onInputBlur,O=e.title,A=C.useState(!1),$=te(A,2),M=$[0],N=$[1],D=c==="combobox",T=D||m,P=d[0],I=p||"";D&&g&&!M&&(I=g),C.useEffect(function(){D&&N(!1)},[D,g]);var R=c!=="combobox"&&!u&&!m?!1:!!I,H=O===void 0?fB(P):O,V=C.useMemo(function(){return P?null:C.createElement("span",{className:"".concat(n,"-selection-placeholder"),style:R?{visibility:"hidden"}:void 0},f)},[P,R,f,n]);return C.createElement("span",{className:"".concat(n,"-selection-wrap")},C.createElement("span",{className:"".concat(n,"-selection-search")},C.createElement(uB,{ref:o,prefixCls:n,id:r,open:u,inputElement:t,disabled:i,autoFocus:a,autoComplete:s,editable:T,activeDescendantId:l,value:I,onKeyDown:y,onMouseDown:b,onChange:function(L){N(!0),w(L)},onPaste:x,onCompositionStart:E,onCompositionEnd:k,onBlur:S,tabIndex:h,attrs:Si(e,!0),maxLength:D?v:void 0})),!D&&P?C.createElement("span",{className:"".concat(n,"-selection-item"),title:H,style:R?{visibility:"hidden"}:void 0},P.label):null,V)},SK=function(e,t){var n=et(null),r=et(!1),o=e.prefixCls,i=e.open,a=e.mode,s=e.showSearch,l=e.tokenWithEnter,c=e.disabled,u=e.prefix,d=e.autoClearSearchValue,f=e.onSearch,h=e.onSearchSubmit,m=e.onToggleOpen,p=e.onInputKeyDown,g=e.onInputBlur,v=e.domRef;C.useImperativeHandle(t,function(){return{focus:function(R){n.current.focus(R)},blur:function(){n.current.blur()}}});var y=aB(0),b=te(y,2),w=b[0],x=b[1],E=function(R){var H=R.which,V=n.current instanceof HTMLTextAreaElement;!V&&i&&(H===St.UP||H===St.DOWN)&&R.preventDefault(),p&&p(R),H===St.ENTER&&a==="tags"&&!r.current&&!i&&(h==null||h(R.target.value)),!(V&&!i&&~[St.UP,St.DOWN,St.LEFT,St.RIGHT].indexOf(H))&&nK(H)&&m(!0)},k=function(){x(!0)},S=et(null),O=function(R){f(R,!0,r.current)!==!1&&m(!0)},A=function(){r.current=!0},$=function(R){r.current=!1,a!=="combobox"&&O(R.target.value)},M=function(R){var H=R.target.value;if(l&&S.current&&/[\r\n]/.test(S.current)){var V=S.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");H=H.replace(V,S.current)}S.current=null,O(H)},N=function(R){var H=R.clipboardData,V=H==null?void 0:H.getData("text");S.current=V||""},D=function(R){var H=R.target;if(H!==n.current){var V=document.body.style.msTouchAction!==void 0;V?setTimeout(function(){n.current.focus()}):n.current.focus()}},T=function(R){var H=w();R.target!==n.current&&!H&&!(a==="combobox"&&c)&&R.preventDefault(),(a!=="combobox"&&(!s||!H)||!i)&&(i&&d!==!1&&f("",!0,!1),m())},P={inputRef:n,onInputKeyDown:E,onInputMouseDown:k,onInputChange:M,onInputPaste:N,onInputCompositionStart:A,onInputCompositionEnd:$,onInputBlur:g},I=a==="multiple"||a==="tags"?C.createElement(CK,Qe({},e,P)):C.createElement(kK,Qe({},e,P));return C.createElement("div",{ref:v,className:"".concat(o,"-selector"),onClick:D,onMouseDown:T},u&&C.createElement("div",{className:"".concat(o,"-prefix")},u),I)},AK=C.forwardRef(SK);function $K(e){var t=e.prefixCls,n=e.align,r=e.arrow,o=e.arrowPos,i=r||{},a=i.className,s=i.content,l=o.x,c=l===void 0?0:l,u=o.y,d=u===void 0?0:u,f=C.useRef();if(!n||!n.points)return null;var h={position:"absolute"};if(n.autoArrow!==!1){var m=n.points[0],p=n.points[1],g=m[0],v=m[1],y=p[0],b=p[1];g===y||!["t","b"].includes(g)?h.top=d:g==="t"?h.top=0:h.bottom=0,v===b||!["l","r"].includes(v)?h.left=c:v==="l"?h.left=0:h.right=0}return C.createElement("div",{ref:f,className:me("".concat(t,"-arrow"),a),style:h},s)}function OK(e){var t=e.prefixCls,n=e.open,r=e.zIndex,o=e.mask,i=e.motion;return o?C.createElement(fl,Qe({},i,{motionAppear:!0,visible:n,removeOnLeave:!0}),function(a){var s=a.className;return C.createElement("div",{style:{zIndex:r},className:me("".concat(t,"-mask"),s)})}):null}var MK=C.memo(function(e){var t=e.children;return t},function(e,t){return t.cache}),NK=C.forwardRef(function(e,t){var n=e.popup,r=e.className,o=e.prefixCls,i=e.style,a=e.target,s=e.onVisibleChanged,l=e.open,c=e.keepDom,u=e.fresh,d=e.onClick,f=e.mask,h=e.arrow,m=e.arrowPos,p=e.align,g=e.motion,v=e.maskMotion,y=e.forceRender,b=e.getPopupContainer,w=e.autoDestroy,x=e.portal,E=e.zIndex,k=e.onMouseEnter,S=e.onMouseLeave,O=e.onPointerEnter,A=e.onPointerDownCapture,$=e.ready,M=e.offsetX,N=e.offsetY,D=e.offsetR,T=e.offsetB,P=e.onAlign,I=e.onPrepare,R=e.stretch,H=e.targetWidth,V=e.targetHeight,L=typeof n=="function"?n():n,j=l||c,_=(b==null?void 0:b.length)>0,F=C.useState(!b||!_),B=te(F,2),z=B[0],G=B[1];if(mn(function(){!z&&_&&a&&G(!0)},[z,_,a]),!z)return null;var W="auto",q={left:"-1000vw",top:"-1000vh",right:W,bottom:W};if($||!l){var U,Y=p.points,ie=p.dynamicInset||((U=p._experimental)===null||U===void 0?void 0:U.dynamicInset),K=ie&&Y[0][1]==="r",re=ie&&Y[0][0]==="b";K?(q.right=D,q.left=W):(q.left=M,q.right=W),re?(q.bottom=T,q.top=W):(q.top=N,q.bottom=W)}var oe={};return R&&(R.includes("height")&&V?oe.height=V:R.includes("minHeight")&&V&&(oe.minHeight=V),R.includes("width")&&H?oe.width=H:R.includes("minWidth")&&H&&(oe.minWidth=H)),l||(oe.pointerEvents="none"),C.createElement(x,{open:y||j,getContainer:b&&function(){return b(a)},autoDestroy:w},C.createElement(OK,{prefixCls:o,open:l,zIndex:E,mask:f,motion:v}),C.createElement(ea,{onResize:P,disabled:!l},function(ne){return C.createElement(fl,Qe({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:y,leavedClassName:"".concat(o,"-hidden")},g,{onAppearPrepare:I,onEnterPrepare:I,visible:l,onVisibleChanged:function(ae){var de;g==null||(de=g.onVisibleChanged)===null||de===void 0||de.call(g,ae),s(ae)}}),function(ae,de){var ge=ae.className,Se=ae.style,ye=me(o,ge,r);return C.createElement("div",{ref:oi(ne,t,de),className:ye,style:Q(Q(Q(Q({"--arrow-x":"".concat(m.x||0,"px"),"--arrow-y":"".concat(m.y||0,"px")},q),oe),Se),{},{boxSizing:"border-box",zIndex:E},i),onMouseEnter:k,onMouseLeave:S,onPointerEnter:O,onClick:d,onPointerDownCapture:A},h&&C.createElement($K,{prefixCls:o,arrow:h,arrowPos:m,align:p}),C.createElement(MK,{cache:!l&&!u},L))})}))}),DK=C.forwardRef(function(e,t){var n=e.children,r=e.getTriggerDOMNode,o=Mc(n),i=C.useCallback(function(s){wC(t,r?r(s):s)},[r]),a=Ed(i,wd(n));return o?C.cloneElement(n,{ref:a}):n}),S6=C.createContext(null);function A6(e){return e?Array.isArray(e)?e:[e]:[]}function TK(e,t,n,r){return C.useMemo(function(){var o=A6(n??t),i=A6(r??t),a=new Set(o),s=new Set(i);return e&&(a.has("hover")&&(a.delete("hover"),a.add("click")),s.has("hover")&&(s.delete("hover"),s.add("click"))),[a,s]},[e,t,n,r])}function FK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0;return n?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}function PK(e,t,n,r){for(var o=n.points,i=Object.keys(e),a=0;a<i.length;a+=1){var s,l=i[a];if(FK((s=e[l])===null||s===void 0?void 0:s.points,o,r))return"".concat(t,"-placement-").concat(l)}return""}function $6(e,t,n,r){return t||(n?{motionName:"".concat(e,"-").concat(n)}:r?{motionName:r}:null)}function Md(e){return e.ownerDocument.defaultView}function j2(e){for(var t=[],n=e==null?void 0:e.parentElement,r=["hidden","scroll","clip","auto"];n;){var o=Md(n).getComputedStyle(n),i=o.overflowX,a=o.overflowY,s=o.overflow;[i,a,s].some(function(l){return r.includes(l)})&&t.push(n),n=n.parentElement}return t}function nd(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(e)?t:e}function tu(e){return nd(parseFloat(e),0)}function O6(e,t){var n=Q({},e);return(t||[]).forEach(function(r){if(!(r instanceof HTMLBodyElement||r instanceof HTMLHtmlElement)){var o=Md(r).getComputedStyle(r),i=o.overflow,a=o.overflowClipMargin,s=o.borderTopWidth,l=o.borderBottomWidth,c=o.borderLeftWidth,u=o.borderRightWidth,d=r.getBoundingClientRect(),f=r.offsetHeight,h=r.clientHeight,m=r.offsetWidth,p=r.clientWidth,g=tu(s),v=tu(l),y=tu(c),b=tu(u),w=nd(Math.round(d.width/m*1e3)/1e3),x=nd(Math.round(d.height/f*1e3)/1e3),E=(m-p-y-b)*w,k=(f-h-g-v)*x,S=g*x,O=v*x,A=y*w,$=b*w,M=0,N=0;if(i==="clip"){var D=tu(a);M=D*w,N=D*x}var T=d.x+A-M,P=d.y+S-N,I=T+d.width+2*M-A-$-E,R=P+d.height+2*N-S-O-k;n.left=Math.max(n.left,T),n.top=Math.max(n.top,P),n.right=Math.min(n.right,I),n.bottom=Math.min(n.bottom,R)}}),n}function M6(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n="".concat(t),r=n.match(/^(.*)\%$/);return r?e*(parseFloat(r[1])/100):parseFloat(n)}function N6(e,t){var n=t||[],r=te(n,2),o=r[0],i=r[1];return[M6(e.width,o),M6(e.height,i)]}function D6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return[e[0],e[1]]}function Tl(e,t){var n=t[0],r=t[1],o,i;return n==="t"?i=e.y:n==="b"?i=e.y+e.height:i=e.y+e.height/2,r==="l"?o=e.x:r==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:i}}function Ma(e,t){var n={t:"b",b:"t",l:"r",r:"l"};return e.map(function(r,o){return o===t?n[r]||"c":r}).join("")}function IK(e,t,n,r,o,i,a){var s=C.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[r]||{}}),l=te(s,2),c=l[0],u=l[1],d=C.useRef(0),f=C.useMemo(function(){return t?j2(t):[]},[t]),h=C.useRef({}),m=function(){h.current={}};e||m();var p=cn(function(){if(t&&n&&e){let gr=function(di,$a){var fi=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Te,Oa=j.x+di,ws=j.y+$a,eo=Oa+re,Di=ws+K,Qn=Math.max(Oa,fi.left),Je=Math.max(ws,fi.top),Nt=Math.min(eo,fi.right),Vt=Math.min(Di,fi.bottom);return Math.max(0,(Nt-Qn)*(Vt-Je))},ia=function(){vn=j.y+Ct,Kt=vn+K,$n=j.x+dt,On=$n+re};var y,b,w,x,E=t,k=E.ownerDocument,S=Md(E),O=S.getComputedStyle(E),A=O.position,$=E.style.left,M=E.style.top,N=E.style.right,D=E.style.bottom,T=E.style.overflow,P=Q(Q({},o[r]),i),I=k.createElement("div");(y=E.parentElement)===null||y===void 0||y.appendChild(I),I.style.left="".concat(E.offsetLeft,"px"),I.style.top="".concat(E.offsetTop,"px"),I.style.position=A,I.style.height="".concat(E.offsetHeight,"px"),I.style.width="".concat(E.offsetWidth,"px"),E.style.left="0",E.style.top="0",E.style.right="auto",E.style.bottom="auto",E.style.overflow="hidden";var R;if(Array.isArray(n))R={x:n[0],y:n[1],width:0,height:0};else{var H,V,L=n.getBoundingClientRect();L.x=(H=L.x)!==null&&H!==void 0?H:L.left,L.y=(V=L.y)!==null&&V!==void 0?V:L.top,R={x:L.x,y:L.y,width:L.width,height:L.height}}var j=E.getBoundingClientRect(),_=S.getComputedStyle(E),F=_.height,B=_.width;j.x=(b=j.x)!==null&&b!==void 0?b:j.left,j.y=(w=j.y)!==null&&w!==void 0?w:j.top;var z=k.documentElement,G=z.clientWidth,W=z.clientHeight,q=z.scrollWidth,U=z.scrollHeight,Y=z.scrollTop,ie=z.scrollLeft,K=j.height,re=j.width,oe=R.height,ne=R.width,ae={left:0,top:0,right:G,bottom:W},de={left:-ie,top:-Y,right:q-ie,bottom:U-Y},ge=P.htmlRegion,Se="visible",ye="visibleFirst";ge!=="scroll"&&ge!==ye&&(ge=Se);var be=ge===ye,ce=O6(de,f),he=O6(ae,f),Te=ge===Se?he:ce,se=be?he:Te;E.style.left="auto",E.style.top="auto",E.style.right="0",E.style.bottom="0";var Pe=E.getBoundingClientRect();E.style.left=$,E.style.top=M,E.style.right=N,E.style.bottom=D,E.style.overflow=T,(x=E.parentElement)===null||x===void 0||x.removeChild(I);var De=nd(Math.round(re/parseFloat(B)*1e3)/1e3),He=nd(Math.round(K/parseFloat(F)*1e3)/1e3);if(De===0||He===0||Gu(n)&&!wp(n))return;var ue=P.offset,ve=P.targetOffset,xe=N6(j,ue),fe=te(xe,2),pe=fe[0],ke=fe[1],Ve=N6(R,ve),Ee=te(Ve,2),yt=Ee[0],Dt=Ee[1];R.x-=yt,R.y-=Dt;var Ft=P.points||[],Ut=te(Ft,2),Ge=Ut[0],Xe=Ut[1],qe=D6(Xe),lt=D6(Ge),je=Tl(R,qe),Rt=Tl(j,lt),zt=Q({},P),dt=je.x-Rt.x+pe,Ct=je.y-Rt.y+ke,jt=gr(dt,Ct),Ie=gr(dt,Ct,he),Ne=Tl(R,["t","l"]),Oe=Tl(j,["t","l"]),_e=Tl(R,["b","r"]),mt=Tl(j,["b","r"]),kt=P.overflow||{},Pt=kt.adjustX,Xt=kt.adjustY,on=kt.shiftX,qt=kt.shiftY,wn=function(di){return typeof di=="boolean"?di:di>=0},vn,Kt,$n,On;ia();var ur=wn(Xt),We=lt[0]===qe[0];if(ur&<[0]==="t"&&(Kt>se.bottom||h.current.bt)){var pt=Ct;We?pt-=K-oe:pt=Ne.y-mt.y-ke;var Ke=gr(dt,pt),rt=gr(dt,pt,he);Ke>jt||Ke===jt&&(!be||rt>=Ie)?(h.current.bt=!0,Ct=pt,ke=-ke,zt.points=[Ma(lt,0),Ma(qe,0)]):h.current.bt=!1}if(ur&<[0]==="b"&&(vn<se.top||h.current.tb)){var ht=Ct;We?ht+=K-oe:ht=_e.y-Oe.y-ke;var an=gr(dt,ht),dn=gr(dt,ht,he);an>jt||an===jt&&(!be||dn>=Ie)?(h.current.tb=!0,Ct=ht,ke=-ke,zt.points=[Ma(lt,0),Ma(qe,0)]):h.current.tb=!1}var Un=wn(Pt),dr=lt[1]===qe[1];if(Un&<[1]==="l"&&(On>se.right||h.current.rl)){var Nn=dt;dr?Nn-=re-ne:Nn=Ne.x-mt.x-pe;var Dn=gr(Nn,Ct),wr=gr(Nn,Ct,he);Dn>jt||Dn===jt&&(!be||wr>=Ie)?(h.current.rl=!0,dt=Nn,pe=-pe,zt.points=[Ma(lt,1),Ma(qe,1)]):h.current.rl=!1}if(Un&<[1]==="r"&&($n<se.left||h.current.lr)){var ar=dt;dr?ar+=re-ne:ar=_e.x-Oe.x-pe;var J=gr(ar,Ct),Z=gr(ar,Ct,he);J>jt||J===jt&&(!be||Z>=Ie)?(h.current.lr=!0,dt=ar,pe=-pe,zt.points=[Ma(lt,1),Ma(qe,1)]):h.current.lr=!1}ia();var $e=on===!0?0:on;typeof $e=="number"&&($n<he.left&&(dt-=$n-he.left-pe,R.x+ne<he.left+$e&&(dt+=R.x-he.left+ne-$e)),On>he.right&&(dt-=On-he.right-pe,R.x>he.right-$e&&(dt+=R.x-he.right+$e)));var Ae=qt===!0?0:qt;typeof Ae=="number"&&(vn<he.top&&(Ct-=vn-he.top-ke,R.y+oe<he.top+Ae&&(Ct+=R.y-he.top+oe-Ae)),Kt>he.bottom&&(Ct-=Kt-he.bottom-ke,R.y>he.bottom-Ae&&(Ct+=R.y-he.bottom+Ae)));var tt=j.x+dt,vt=tt+re,Ot=j.y+Ct,wt=Ot+K,ot=R.x,Mt=ot+ne,Zt=R.y,Ue=Zt+oe,Ye=Math.max(tt,ot),ct=Math.min(vt,Mt),It=(Ye+ct)/2,Cn=It-tt,bt=Math.max(Ot,Zt),Wt=Math.min(wt,Ue),Fn=(bt+Wt)/2,ft=Fn-Ot;a==null||a(t,zt);var Tt=Pe.right-j.x-(dt+j.width),Bn=Pe.bottom-j.y-(Ct+j.height);De===1&&(dt=Math.round(dt),Tt=Math.round(Tt)),He===1&&(Ct=Math.round(Ct),Bn=Math.round(Bn));var zn={ready:!0,offsetX:dt/De,offsetY:Ct/He,offsetR:Tt/De,offsetB:Bn/He,arrowX:Cn/De,arrowY:ft/He,scaleX:De,scaleY:He,align:zt};u(zn)}}),g=function(){d.current+=1;var y=d.current;Promise.resolve().then(function(){d.current===y&&p()})},v=function(){u(function(y){return Q(Q({},y),{},{ready:!1})})};return mn(v,[r]),mn(function(){e||v()},[e]),[c.ready,c.offsetX,c.offsetY,c.offsetR,c.offsetB,c.arrowX,c.arrowY,c.scaleX,c.scaleY,c.align,g]}function BK(e,t,n,r,o){mn(function(){if(e&&t&&n){let d=function(){r(),o()};var i=t,a=n,s=j2(i),l=j2(a),c=Md(a),u=new Set([c].concat(ze(s),ze(l)));return u.forEach(function(f){f.addEventListener("scroll",d,{passive:!0})}),c.addEventListener("resize",d,{passive:!0}),r(),function(){u.forEach(function(f){f.removeEventListener("scroll",d),c.removeEventListener("resize",d)})}}},[e,t,n])}function RK(e,t,n,r,o,i,a,s){var l=C.useRef(e);l.current=e;var c=C.useRef(!1);C.useEffect(function(){if(t&&r&&(!o||i)){var d=function(){c.current=!1},f=function(p){var g;l.current&&!a(((g=p.composedPath)===null||g===void 0||(g=g.call(p))===null||g===void 0?void 0:g[0])||p.target)&&!c.current&&s(!1)},h=Md(r);h.addEventListener("pointerdown",d,!0),h.addEventListener("mousedown",f,!0),h.addEventListener("contextmenu",f,!0);var m=u0(n);return m&&(m.addEventListener("mousedown",f,!0),m.addEventListener("contextmenu",f,!0)),function(){h.removeEventListener("pointerdown",d,!0),h.removeEventListener("mousedown",f,!0),h.removeEventListener("contextmenu",f,!0),m&&(m.removeEventListener("mousedown",f,!0),m.removeEventListener("contextmenu",f,!0))}}},[t,n,r,o,i]);function u(){c.current=!0}return u}var _K=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function jK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:qI,t=C.forwardRef(function(n,r){var o=n.prefixCls,i=o===void 0?"rc-trigger-popup":o,a=n.children,s=n.action,l=s===void 0?"hover":s,c=n.showAction,u=n.hideAction,d=n.popupVisible,f=n.defaultPopupVisible,h=n.onPopupVisibleChange,m=n.afterPopupVisibleChange,p=n.mouseEnterDelay,g=n.mouseLeaveDelay,v=g===void 0?.1:g,y=n.focusDelay,b=n.blurDelay,w=n.mask,x=n.maskClosable,E=x===void 0?!0:x,k=n.getPopupContainer,S=n.forceRender,O=n.autoDestroy,A=n.destroyPopupOnHide,$=n.popup,M=n.popupClassName,N=n.popupStyle,D=n.popupPlacement,T=n.builtinPlacements,P=T===void 0?{}:T,I=n.popupAlign,R=n.zIndex,H=n.stretch,V=n.getPopupClassNameFromAlign,L=n.fresh,j=n.alignPoint,_=n.onPopupClick,F=n.onPopupAlign,B=n.arrow,z=n.popupMotion,G=n.maskMotion,W=n.popupTransitionName,q=n.popupAnimation,U=n.maskTransitionName,Y=n.maskAnimation,ie=n.className,K=n.getTriggerDOMNode,re=tn(n,_K),oe=O||A||!1,ne=C.useState(!1),ae=te(ne,2),de=ae[0],ge=ae[1];mn(function(){ge(JC())},[]);var Se=C.useRef({}),ye=C.useContext(S6),be=C.useMemo(function(){return{registerSubPopup:function(Je,Nt){Se.current[Je]=Nt,ye==null||ye.registerSubPopup(Je,Nt)}}},[ye]),ce=qC(),he=C.useState(null),Te=te(he,2),se=Te[0],Pe=Te[1],De=C.useRef(null),He=cn(function(Je){De.current=Je,Gu(Je)&&se!==Je&&Pe(Je),ye==null||ye.registerSubPopup(ce,Je)}),ue=C.useState(null),ve=te(ue,2),xe=ve[0],fe=ve[1],pe=C.useRef(null),ke=cn(function(Je){Gu(Je)&&xe!==Je&&(fe(Je),pe.current=Je)}),Ve=C.Children.only(a),Ee=(Ve==null?void 0:Ve.props)||{},yt={},Dt=cn(function(Je){var Nt,Vt,Hn=xe;return(Hn==null?void 0:Hn.contains(Je))||((Nt=u0(Hn))===null||Nt===void 0?void 0:Nt.host)===Je||Je===Hn||(se==null?void 0:se.contains(Je))||((Vt=u0(se))===null||Vt===void 0?void 0:Vt.host)===Je||Je===se||Object.values(Se.current).some(function(An){return(An==null?void 0:An.contains(Je))||Je===An})}),Ft=$6(i,z,q,W),Ut=$6(i,G,Y,U),Ge=C.useState(f||!1),Xe=te(Ge,2),qe=Xe[0],lt=Xe[1],je=d??qe,Rt=cn(function(Je){d===void 0&<(Je)});mn(function(){lt(d||!1)},[d]);var zt=C.useRef(je);zt.current=je;var dt=C.useRef([]);dt.current=[];var Ct=cn(function(Je){var Nt;Rt(Je),((Nt=dt.current[dt.current.length-1])!==null&&Nt!==void 0?Nt:je)!==Je&&(dt.current.push(Je),h==null||h(Je))}),jt=C.useRef(),Ie=function(){clearTimeout(jt.current)},Ne=function(Je){var Nt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;Ie(),Nt===0?Ct(Je):jt.current=setTimeout(function(){Ct(Je)},Nt*1e3)};C.useEffect(function(){return Ie},[]);var Oe=C.useState(!1),_e=te(Oe,2),mt=_e[0],kt=_e[1];mn(function(Je){(!Je||je)&&kt(!0)},[je]);var Pt=C.useState(null),Xt=te(Pt,2),on=Xt[0],qt=Xt[1],wn=C.useState(null),vn=te(wn,2),Kt=vn[0],$n=vn[1],On=function(Je){$n([Je.clientX,Je.clientY])},ur=IK(je,se,j&&Kt!==null?Kt:xe,D,P,I,F),We=te(ur,11),pt=We[0],Ke=We[1],rt=We[2],ht=We[3],an=We[4],dn=We[5],Un=We[6],dr=We[7],Nn=We[8],Dn=We[9],wr=We[10],ar=TK(de,l,c,u),J=te(ar,2),Z=J[0],$e=J[1],Ae=Z.has("click"),tt=$e.has("click")||$e.has("contextMenu"),vt=cn(function(){mt||wr()}),Ot=function(){zt.current&&j&&tt&&Ne(!1)};BK(je,xe,se,vt,Ot),mn(function(){vt()},[Kt,D]),mn(function(){je&&!(P!=null&&P[D])&&vt()},[JSON.stringify(I)]);var wt=C.useMemo(function(){var Je=PK(P,i,Dn,j);return me(Je,V==null?void 0:V(Dn))},[Dn,V,P,i,j]);C.useImperativeHandle(r,function(){return{nativeElement:pe.current,popupElement:De.current,forceAlign:vt}});var ot=C.useState(0),Mt=te(ot,2),Zt=Mt[0],Ue=Mt[1],Ye=C.useState(0),ct=te(Ye,2),It=ct[0],Cn=ct[1],bt=function(){if(H&&xe){var Je=xe.getBoundingClientRect();Ue(Je.width),Cn(Je.height)}},Wt=function(){bt(),vt()},Fn=function(Je){kt(!1),wr(),m==null||m(Je)},ft=function(){return new Promise(function(Je){bt(),qt(function(){return Je})})};mn(function(){on&&(wr(),on(),qt(null))},[on]);function Tt(Je,Nt,Vt,Hn){yt[Je]=function(An){var Ti;Hn==null||Hn(An),Ne(Nt,Vt);for(var Zc=arguments.length,IS=new Array(Zc>1?Zc-1:0),Ud=1;Ud<Zc;Ud++)IS[Ud-1]=arguments[Ud];(Ti=Ee[Je])===null||Ti===void 0||Ti.call.apply(Ti,[Ee,An].concat(IS))}}(Ae||tt)&&(yt.onClick=function(Je){var Nt;zt.current&&tt?Ne(!1):!zt.current&&Ae&&(On(Je),Ne(!0));for(var Vt=arguments.length,Hn=new Array(Vt>1?Vt-1:0),An=1;An<Vt;An++)Hn[An-1]=arguments[An];(Nt=Ee.onClick)===null||Nt===void 0||Nt.call.apply(Nt,[Ee,Je].concat(Hn))});var Bn=RK(je,tt,xe,se,w,E,Dt,Ne),zn=Z.has("hover"),gr=$e.has("hover"),ia,di;zn&&(Tt("onMouseEnter",!0,p,function(Je){On(Je)}),Tt("onPointerEnter",!0,p,function(Je){On(Je)}),ia=function(Je){(je||mt)&&se!==null&&se!==void 0&&se.contains(Je.target)&&Ne(!0,p)},j&&(yt.onMouseMove=function(Je){var Nt;(Nt=Ee.onMouseMove)===null||Nt===void 0||Nt.call(Ee,Je)})),gr&&(Tt("onMouseLeave",!1,v),Tt("onPointerLeave",!1,v),di=function(){Ne(!1,v)}),Z.has("focus")&&Tt("onFocus",!0,y),$e.has("focus")&&Tt("onBlur",!1,b),Z.has("contextMenu")&&(yt.onContextMenu=function(Je){var Nt;zt.current&&$e.has("contextMenu")?Ne(!1):(On(Je),Ne(!0)),Je.preventDefault();for(var Vt=arguments.length,Hn=new Array(Vt>1?Vt-1:0),An=1;An<Vt;An++)Hn[An-1]=arguments[An];(Nt=Ee.onContextMenu)===null||Nt===void 0||Nt.call.apply(Nt,[Ee,Je].concat(Hn))}),ie&&(yt.className=me(Ee.className,ie));var $a=C.useRef(!1);$a.current||($a.current=S||je||mt);var fi=Q(Q({},Ee),yt),Oa={},ws=["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"];ws.forEach(function(Je){re[Je]&&(Oa[Je]=function(){for(var Nt,Vt=arguments.length,Hn=new Array(Vt),An=0;An<Vt;An++)Hn[An]=arguments[An];(Nt=fi[Je])===null||Nt===void 0||Nt.call.apply(Nt,[fi].concat(Hn)),re[Je].apply(re,Hn)})});var eo=C.cloneElement(Ve,Q(Q({},fi),Oa)),Di={x:dn,y:Un},Qn=B?Q({},B!==!0?B:{}):null;return C.createElement(C.Fragment,null,C.createElement(ea,{disabled:!je,ref:ke,onResize:Wt},C.createElement(DK,{getTriggerDOMNode:K},eo)),$a.current&&C.createElement(S6.Provider,{value:be},C.createElement(NK,{portal:e,ref:He,prefixCls:i,popup:$,className:me(M,wt),style:N,target:xe,onMouseEnter:ia,onMouseLeave:di,onPointerEnter:ia,zIndex:R,open:je,keepDom:mt,fresh:L,onClick:_,onPointerDownCapture:Bn,mask:w,motion:Ft,maskMotion:Ut,onVisibleChanged:Fn,onPrepare:ft,forceRender:S,autoDestroy:oe,getPopupContainer:k,align:Dn,arrow:Qn,arrowPos:Di,ready:pt,offsetX:Ke,offsetY:rt,offsetR:ht,offsetB:an,onAlign:vt,stretch:H,targetWidth:Zt/dr,targetHeight:It/Nn})))});return t}const ek=jK(qI);var LK=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],zK=function(e){var 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"}}},HK=function(e,t){var n=e.prefixCls,r=e.visible,o=e.children,i=e.popupElement,a=e.animation,s=e.transitionName,l=e.dropdownStyle,c=e.dropdownClassName,u=e.direction,d=u===void 0?"ltr":u,f=e.placement,h=e.builtinPlacements,m=e.dropdownMatchSelectWidth,p=e.dropdownRender,g=e.dropdownAlign,v=e.getPopupContainer,y=e.empty,b=e.getTriggerDOMNode,w=e.onPopupVisibleChange,x=e.onPopupMouseEnter,E=tn(e,LK),k="".concat(n,"-dropdown"),S=i;p&&(S=p(i));var O=C.useMemo(function(){return h||zK(m)},[h,m]),A=a?"".concat(k,"-").concat(a):s,$=typeof m=="number",M=C.useMemo(function(){return $?null:m===!1?"minWidth":"width"},[m,$]),N=l;$&&(N=Q(Q({},N),{},{width:m}));var D=C.useRef(null);return C.useImperativeHandle(t,function(){return{getPopupElement:function(){var T;return(T=D.current)===null||T===void 0?void 0:T.popupElement}}}),C.createElement(ek,Qe({},E,{showAction:w?["click"]:[],hideAction:w?["click"]:[],popupPlacement:f||(d==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:O,prefixCls:k,popupTransitionName:A,popup:C.createElement("div",{onMouseEnter:x},S),ref:D,stretch:M,popupAlign:g,popupVisible:r,getPopupContainer:v,popupClassName:me(c,X({},"".concat(k,"-empty"),y)),popupStyle:N,getTriggerDOMNode:b,onPopupVisibleChange:w}),o)},WK=C.forwardRef(HK);function T6(e,t){var n=e.key,r;return"value"in e&&(r=e.value),n??(r!==void 0?r:"rc-index-key-".concat(t))}function L2(e){return typeof e<"u"&&!Number.isNaN(e)}function hB(e,t){var n=e||{},r=n.label,o=n.value,i=n.options,a=n.groupLabel,s=r||(t?"children":"label");return{label:s,value:o||"value",options:i||"options",groupLabel:a||s}}function VK(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.fieldNames,r=t.childrenAsData,o=[],i=hB(n,!1),a=i.label,s=i.value,l=i.options,c=i.groupLabel;function u(d,f){Array.isArray(d)&&d.forEach(function(h){if(f||!(l in h)){var m=h[s];o.push({key:T6(h,o.length),groupOption:f,data:h,label:h[a],value:m})}else{var p=h[c];p===void 0&&r&&(p=h.label),o.push({key:T6(h,o.length),group:!0,data:h,label:p}),u(h[l],!0)}})}return u(e,!1),o}function z2(e){var t=Q({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return qr(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}var GK=function(e,t,n){if(!t||!t.length)return null;var r=!1,o=function a(s,l){var c=HP(l),u=c[0],d=c.slice(1);if(!u)return[s];var f=s.split(u);return r=r||f.length>1,f.reduce(function(h,m){return[].concat(ze(h),ze(a(m,d)))},[]).filter(Boolean)},i=o(e,t);return r?typeof n<"u"?i.slice(0,n):i:null},tk=C.createContext(null);function UK(e){var t=e.visible,n=e.values;if(!t)return null;var r=50;return C.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(n.slice(0,r).map(function(o){var i=o.label,a=o.value;return["number","string"].includes(At(i))?i:a}).join(", ")),n.length>r?", ...":null)}var qK=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],YK=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],H2=function(e){return e==="tags"||e==="multiple"},XK=C.forwardRef(function(e,t){var n,r=e.id,o=e.prefixCls,i=e.className,a=e.showSearch,s=e.tagRender,l=e.direction,c=e.omitDomProps,u=e.displayValues,d=e.onDisplayValuesChange,f=e.emptyOptions,h=e.notFoundContent,m=h===void 0?"Not Found":h,p=e.onClear,g=e.mode,v=e.disabled,y=e.loading,b=e.getInputElement,w=e.getRawInputElement,x=e.open,E=e.defaultOpen,k=e.onDropdownVisibleChange,S=e.activeValue,O=e.onActiveValueChange,A=e.activeDescendantId,$=e.searchValue,M=e.autoClearSearchValue,N=e.onSearch,D=e.onSearchSplit,T=e.tokenSeparators,P=e.allowClear,I=e.prefix,R=e.suffixIcon,H=e.clearIcon,V=e.OptionList,L=e.animation,j=e.transitionName,_=e.dropdownStyle,F=e.dropdownClassName,B=e.dropdownMatchSelectWidth,z=e.dropdownRender,G=e.dropdownAlign,W=e.placement,q=e.builtinPlacements,U=e.getPopupContainer,Y=e.showAction,ie=Y===void 0?[]:Y,K=e.onFocus,re=e.onBlur,oe=e.onKeyUp,ne=e.onKeyDown,ae=e.onMouseDown,de=tn(e,qK),ge=H2(g),Se=(a!==void 0?a:ge)||g==="combobox",ye=Q({},de);YK.forEach(function(ot){delete ye[ot]}),c==null||c.forEach(function(ot){delete ye[ot]});var be=C.useState(!1),ce=te(be,2),he=ce[0],Te=ce[1];C.useEffect(function(){Te(JC())},[]);var se=C.useRef(null),Pe=C.useRef(null),De=C.useRef(null),He=C.useRef(null),ue=C.useRef(null),ve=C.useRef(!1),xe=eK(),fe=te(xe,3),pe=fe[0],ke=fe[1],Ve=fe[2];C.useImperativeHandle(t,function(){var ot,Mt;return{focus:(ot=He.current)===null||ot===void 0?void 0:ot.focus,blur:(Mt=He.current)===null||Mt===void 0?void 0:Mt.blur,scrollTo:function(Zt){var Ue;return(Ue=ue.current)===null||Ue===void 0?void 0:Ue.scrollTo(Zt)},nativeElement:se.current||Pe.current}});var Ee=C.useMemo(function(){var ot;if(g!=="combobox")return $;var Mt=(ot=u[0])===null||ot===void 0?void 0:ot.value;return typeof Mt=="string"||typeof Mt=="number"?String(Mt):""},[$,g,u]),yt=g==="combobox"&&typeof b=="function"&&b()||null,Dt=typeof w=="function"&&w(),Ft=Ed(Pe,Dt==null||(n=Dt.props)===null||n===void 0?void 0:n.ref),Ut=C.useState(!1),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1];mn(function(){qe(!0)},[]);var lt=yr(!1,{defaultValue:E,value:x}),je=te(lt,2),Rt=je[0],zt=je[1],dt=Xe?Rt:!1,Ct=!m&&f;(v||Ct&&dt&&g==="combobox")&&(dt=!1);var jt=Ct?!1:dt,Ie=C.useCallback(function(ot){var Mt=ot!==void 0?ot:!dt;v||(zt(Mt),dt!==Mt&&(k==null||k(Mt)))},[v,dt,zt,k]),Ne=C.useMemo(function(){return(T||[]).some(function(ot){return[`
|
|
285
|
+
}`),o)}else Xu(o);return function(){Xu(o)}},[t,o])}var qY=!1;function YY(e){return qY}var u6=function(e){return e===!1?!1:!$o()||!e?null:typeof e=="string"?document.querySelector(e):typeof e=="function"?e():e},qI=C.forwardRef(function(e,t){var n=e.open,r=e.autoLock,o=e.getContainer;e.debug;var i=e.autoDestroy,a=i===void 0?!0:i,s=e.children,l=C.useState(n),c=te(l,2),u=c[0],d=c[1],f=u||n;C.useEffect(function(){(a||n)&&d(n)},[n,a]);var h=C.useState(function(){return u6(o)}),m=te(h,2),p=m[0],g=m[1];C.useEffect(function(){var $=u6(o);g($??null)});var v=zY(f&&!p),y=te(v,2),b=y[0],w=y[1],x=p??b;UY(r&&n&&$o()&&(x===b||x===document.body));var E=null;if(s&&Mc(s)&&t){var k=s;E=k.ref}var S=Ed(E,t);if(!f||!$o()||p===void 0)return null;var O=x===!1||YY(),A=s;return t&&(A=C.cloneElement(s,{ref:S})),C.createElement(UI.Provider,{value:w},O?A:IF(A,x))});function XY(){var e=Q({},C);return e.useId}var d6=0,f6=XY();const qC=f6?(function(e){var t=f6();return e||t}):(function(e){var t=C.useState("ssr-id"),n=te(t,2),r=n[0],o=n[1];return C.useEffect(function(){var i=d6;d6+=1,o("rc_unique_".concat(i))},[]),e||r});var Rs="RC_FORM_INTERNAL_HOOKS",Wn=function(){qr(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},el=C.createContext({getFieldValue:Wn,getFieldsValue:Wn,getFieldError:Wn,getFieldWarning:Wn,getFieldsError:Wn,isFieldsTouched:Wn,isFieldTouched:Wn,isFieldValidating:Wn,isFieldsValidating:Wn,resetFields:Wn,setFields:Wn,setFieldValue:Wn,setFieldsValue:Wn,validateFields:Wn,submit:Wn,getInternalHooks:function(){return Wn(),{dispatch:Wn,initEntityValue:Wn,registerField:Wn,useSubscribe:Wn,setInitialValues:Wn,destroyForm:Wn,setCallbacks:Wn,registerWatch:Wn,getFields:Wn,setValidateMessages:Wn,setPreserve:Wn,getInitialValue:Wn}}}),td=C.createContext(null);function O2(e){return e==null?[]:Array.isArray(e)?e:[e]}function KY(e){return e&&!!e._init}function M2(){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",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 e=JSON.parse(JSON.stringify(this));return e.clone=this.clone,e}}}var N2=M2();function ZY(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function QY(e,t,n){if(CC())return Reflect.construct.apply(null,arguments);var r=[null];r.push.apply(r,t);var o=new(e.bind.apply(e,r));return n&&Uu(o,n.prototype),o}function D2(e){var t=typeof Map=="function"?new Map:void 0;return D2=function(n){if(n===null||!ZY(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,r)}function r(){return QY(n,arguments,qu(this).constructor)}return r.prototype=Object.create(n.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Uu(r,n)},D2(e)}var JY=/%[sdj%]/g,eX=function(){};function T2(e){if(!e||!e.length)return null;var t={};return e.forEach(function(n){var r=n.field;t[r]=t[r]||[],t[r].push(n)}),t}function Io(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=0,i=n.length;if(typeof e=="function")return e.apply(null,n);if(typeof e=="string"){var a=e.replace(JY,function(s){if(s==="%%")return"%";if(o>=i)return s;switch(s){case"%s":return String(n[o++]);case"%d":return Number(n[o++]);case"%j":try{return JSON.stringify(n[o++])}catch{return"[Circular]"}break;default:return s}});return a}return e}function tX(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Lr(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||tX(t)&&typeof e=="string"&&!e)}function nX(e,t,n){var r=[],o=0,i=e.length;function a(s){r.push.apply(r,ze(s||[])),o++,o===i&&n(r)}e.forEach(function(s){t(s,a)})}function h6(e,t,n){var r=0,o=e.length;function i(a){if(a&&a.length){n(a);return}var s=r;r=r+1,s<o?t(e[s],i):n([])}i([])}function rX(e){var t=[];return Object.keys(e).forEach(function(n){t.push.apply(t,ze(e[n]||[]))}),t}var p6=(function(e){ds(n,e);var t=fs(n);function n(r,o){var i;return xr(this,n),i=t.call(this,"Async Validation Error"),X(fn(i),"errors",void 0),X(fn(i),"fields",void 0),i.errors=r,i.fields=o,i}return Er(n)})(D2(Error));function oX(e,t,n,r,o){if(t.first){var i=new Promise(function(f,h){var m=function(g){return r(g),g.length?h(new p6(g,T2(g))):f(o)},p=rX(e);h6(p,n,m)});return i.catch(function(f){return f}),i}var a=t.firstFields===!0?Object.keys(e):t.firstFields||[],s=Object.keys(e),l=s.length,c=0,u=[],d=new Promise(function(f,h){var m=function(p){if(u.push.apply(u,p),c++,c===l)return r(u),u.length?h(new p6(u,T2(u))):f(o)};s.length||(r(u),f(o)),s.forEach(function(p){var g=e[p];a.indexOf(p)!==-1?h6(g,n,m):nX(g,n,m)})});return d.catch(function(f){return f}),d}function iX(e){return!!(e&&e.message!==void 0)}function aX(e,t){for(var n=e,r=0;r<t.length;r++){if(n==null)return n;n=n[t[r]]}return n}function g6(e,t){return function(n){var r;return e.fullFields?r=aX(t,e.fullFields):r=t[n.field||e.fullField],iX(n)?(n.field=n.field||e.fullField,n.fieldValue=r,n):{message:typeof n=="function"?n():n,fieldValue:r,field:n.field||e.fullField}}}function m6(e,t){if(t){for(var n in t)if(t.hasOwnProperty(n)){var r=t[n];At(r)==="object"&&At(e[n])==="object"?e[n]=Q(Q({},e[n]),r):e[n]=r}}return e}var Ol="enum",sX=function(e,t,n,r,o){e[Ol]=Array.isArray(e[Ol])?e[Ol]:[],e[Ol].indexOf(t)===-1&&r.push(Io(o.messages[Ol],e.fullField,e[Ol].join(", ")))},lX=function(e,t,n,r,o){if(e.pattern){if(e.pattern instanceof RegExp)e.pattern.lastIndex=0,e.pattern.test(t)||r.push(Io(o.messages.pattern.mismatch,e.fullField,t,e.pattern));else if(typeof e.pattern=="string"){var i=new RegExp(e.pattern);i.test(t)||r.push(Io(o.messages.pattern.mismatch,e.fullField,t,e.pattern))}}},cX=function(e,t,n,r,o){var i=typeof e.len=="number",a=typeof e.min=="number",s=typeof e.max=="number",l=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,c=t,u=null,d=typeof t=="number",f=typeof t=="string",h=Array.isArray(t);if(d?u="number":f?u="string":h&&(u="array"),!u)return!1;h&&(c=t.length),f&&(c=t.replace(l,"_").length),i?c!==e.len&&r.push(Io(o.messages[u].len,e.fullField,e.len)):a&&!s&&c<e.min?r.push(Io(o.messages[u].min,e.fullField,e.min)):s&&!a&&c>e.max?r.push(Io(o.messages[u].max,e.fullField,e.max)):a&&s&&(c<e.min||c>e.max)&&r.push(Io(o.messages[u].range,e.fullField,e.min,e.max))},YI=function(e,t,n,r,o,i){e.required&&(!n.hasOwnProperty(e.field)||Lr(t,i||e.type))&&r.push(Io(o.messages.required,e.fullField))},nf;const uX=(function(){if(nf)return nf;var e="[a-fA-F\\d:]",t=function(x){return x&&x.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(e,")|(?<=").concat(e,")(?=\\s|$))"):""},n="(?: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}",r="[a-fA-F\\d]{1,4}",o=["(?:".concat(r,":){7}(?:").concat(r,"|:)"),"(?:".concat(r,":){6}(?:").concat(n,"|:").concat(r,"|:)"),"(?:".concat(r,":){5}(?::").concat(n,"|(?::").concat(r,"){1,2}|:)"),"(?:".concat(r,":){4}(?:(?::").concat(r,"){0,1}:").concat(n,"|(?::").concat(r,"){1,3}|:)"),"(?:".concat(r,":){3}(?:(?::").concat(r,"){0,2}:").concat(n,"|(?::").concat(r,"){1,4}|:)"),"(?:".concat(r,":){2}(?:(?::").concat(r,"){0,3}:").concat(n,"|(?::").concat(r,"){1,5}|:)"),"(?:".concat(r,":){1}(?:(?::").concat(r,"){0,4}:").concat(n,"|(?::").concat(r,"){1,6}|:)"),"(?::(?:(?::".concat(r,"){0,5}:").concat(n,"|(?::").concat(r,"){1,7}|:))")],i="(?:%[0-9a-zA-Z]{1,})?",a="(?:".concat(o.join("|"),")").concat(i),s=new RegExp("(?:^".concat(n,"$)|(?:^").concat(a,"$)")),l=new RegExp("^".concat(n,"$")),c=new RegExp("^".concat(a,"$")),u=function(x){return x&&x.exact?s:new RegExp("(?:".concat(t(x)).concat(n).concat(t(x),")|(?:").concat(t(x)).concat(a).concat(t(x),")"),"g")};u.v4=function(x){return x&&x.exact?l:new RegExp("".concat(t(x)).concat(n).concat(t(x)),"g")},u.v6=function(x){return x&&x.exact?c:new RegExp("".concat(t(x)).concat(a).concat(t(x)),"g")};var d="(?:(?:[a-z]+:)?//)",f="(?:\\S+(?::\\S*)?@)?",h=u.v4().source,m=u.v6().source,p="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",g="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",v="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",y="(?::\\d{2,5})?",b='(?:[/?#][^\\s"]*)?',w="(?:".concat(d,"|www\\.)").concat(f,"(?:localhost|").concat(h,"|").concat(m,"|").concat(p).concat(g).concat(v,")").concat(y).concat(b);return nf=new RegExp("(?:^".concat(w,"$)"),"i"),nf});var v6={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,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},Eu={integer:function(e){return Eu.number(e)&&parseInt(e,10)===e},float:function(e){return Eu.number(e)&&!Eu.integer(e)},array:function(e){return Array.isArray(e)},regexp:function(e){if(e instanceof RegExp)return!0;try{return!!new RegExp(e)}catch{return!1}},date:function(e){return typeof e.getTime=="function"&&typeof e.getMonth=="function"&&typeof e.getYear=="function"&&!isNaN(e.getTime())},number:function(e){return isNaN(e)?!1:typeof e=="number"},object:function(e){return At(e)==="object"&&!Eu.array(e)},method:function(e){return typeof e=="function"},email:function(e){return typeof e=="string"&&e.length<=320&&!!e.match(v6.email)},url:function(e){return typeof e=="string"&&e.length<=2048&&!!e.match(uX())},hex:function(e){return typeof e=="string"&&!!e.match(v6.hex)}},dX=function(e,t,n,r,o){if(e.required&&t===void 0){YI(e,t,n,r,o);return}var i=["integer","float","array","regexp","object","method","email","number","date","url","hex"],a=e.type;i.indexOf(a)>-1?Eu[a](t)||r.push(Io(o.messages.types[a],e.fullField,e.type)):a&&At(t)!==e.type&&r.push(Io(o.messages.types[a],e.fullField,e.type))},fX=function(e,t,n,r,o){(/^\s+$/.test(t)||t==="")&&r.push(Io(o.messages.whitespace,e.fullField))};const bn={required:YI,whitespace:fX,type:dX,range:cX,enum:sX,pattern:lX};var hX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o)}n(i)},pX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(t==null&&!e.required)return n();bn.required(e,t,r,i,o,"array"),t!=null&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},gX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},mX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"date")&&!e.required)return n();if(bn.required(e,t,r,i,o),!Lr(t,"date")){var s;t instanceof Date?s=t:s=new Date(t),bn.type(e,s,r,i,o),s&&bn.range(e,s.getTime(),r,i,o)}}n(i)},vX="enum",yX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn[vX](e,t,r,i,o)}n(i)},bX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},xX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},EX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},wX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(t===""&&(t=void 0),Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o))}n(i)},CX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),t!==void 0&&bn.type(e,t,r,i,o)}n(i)},kX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"string")&&!e.required)return n();bn.required(e,t,r,i,o),Lr(t,"string")||bn.pattern(e,t,r,i,o)}n(i)},SX=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t)&&!e.required)return n();bn.required(e,t,r,i,o),Lr(t)||bn.type(e,t,r,i,o)}n(i)},AX=function(e,t,n,r,o){var i=[],a=Array.isArray(t)?"array":At(t);bn.required(e,t,r,i,o,a),n(i)},$X=function(e,t,n,r,o){var i=[],a=e.required||!e.required&&r.hasOwnProperty(e.field);if(a){if(Lr(t,"string")&&!e.required)return n();bn.required(e,t,r,i,o,"string"),Lr(t,"string")||(bn.type(e,t,r,i,o),bn.range(e,t,r,i,o),bn.pattern(e,t,r,i,o),e.whitespace===!0&&bn.whitespace(e,t,r,i,o))}n(i)},gm=function(e,t,n,r,o){var i=e.type,a=[],s=e.required||!e.required&&r.hasOwnProperty(e.field);if(s){if(Lr(t,i)&&!e.required)return n();bn.required(e,t,r,a,o,i),Lr(t,i)||bn.type(e,t,r,a,o)}n(a)};const Fu={string:$X,method:EX,number:wX,boolean:gX,regexp:SX,integer:xX,float:bX,array:pX,object:CX,enum:yX,pattern:kX,date:mX,url:gm,hex:gm,email:gm,required:AX,any:hX};var Od=(function(){function e(t){xr(this,e),X(this,"rules",null),X(this,"_messages",N2),this.define(t)}return Er(e,[{key:"define",value:function(t){var n=this;if(!t)throw new Error("Cannot configure a schema with no rules");if(At(t)!=="object"||Array.isArray(t))throw new Error("Rules must be an object");this.rules={},Object.keys(t).forEach(function(r){var o=t[r];n.rules[r]=Array.isArray(o)?o:[o]})}},{key:"messages",value:function(t){return t&&(this._messages=m6(M2(),t)),this._messages}},{key:"validate",value:function(t){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},i=t,a=r,s=o;if(typeof a=="function"&&(s=a,a={}),!this.rules||Object.keys(this.rules).length===0)return s&&s(null,i),Promise.resolve(i);function l(f){var h=[],m={};function p(v){if(Array.isArray(v)){var y;h=(y=h).concat.apply(y,ze(v))}else h.push(v)}for(var g=0;g<f.length;g++)p(f[g]);h.length?(m=T2(h),s(h,m)):s(null,i)}if(a.messages){var c=this.messages();c===N2&&(c=M2()),m6(c,a.messages),a.messages=c}else a.messages=this.messages();var u={},d=a.keys||Object.keys(this.rules);return d.forEach(function(f){var h=n.rules[f],m=i[f];h.forEach(function(p){var g=p;typeof g.transform=="function"&&(i===t&&(i=Q({},i)),m=i[f]=g.transform(m),m!=null&&(g.type=g.type||(Array.isArray(m)?"array":At(m)))),typeof g=="function"?g={validator:g}:g=Q({},g),g.validator=n.getValidationMethod(g),g.validator&&(g.field=f,g.fullField=g.fullField||f,g.type=n.getType(g),u[f]=u[f]||[],u[f].push({rule:g,value:m,source:i,field:f}))})}),oX(u,a,function(f,h){var m=f.rule,p=(m.type==="object"||m.type==="array")&&(At(m.fields)==="object"||At(m.defaultField)==="object");p=p&&(m.required||!m.required&&f.value),m.field=f.field;function g(x,E){return Q(Q({},E),{},{fullField:"".concat(m.fullField,".").concat(x),fullFields:m.fullFields?[].concat(ze(m.fullFields),[x]):[x]})}function v(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],E=Array.isArray(x)?x:[x];!a.suppressWarning&&E.length&&e.warning("async-validator:",E),E.length&&m.message!==void 0&&(E=[].concat(m.message));var k=E.map(g6(m,i));if(a.first&&k.length)return h(k);if(!p)h(k);else{if(m.required&&!f.value)return m.message!==void 0?k=[].concat(m.message).map(g6(m,i)):a.error&&(k=[a.error(m,Io(a.messages.required,m.field))]),h(k);var S={};m.defaultField&&Object.keys(f.value).map(function($){S[$]=m.defaultField}),S=Q(Q({},S),f.rule.fields);var O={};Object.keys(S).forEach(function($){var M=S[$],N=Array.isArray(M)?M:[M];O[$]=N.map(g.bind(null,$))});var A=new e(O);A.messages(a.messages),f.rule.options&&(f.rule.options.messages=a.messages,f.rule.options.error=a.error),A.validate(f.value,f.rule.options||a,function($){var M=[];k&&k.length&&M.push.apply(M,ze(k)),$&&$.length&&M.push.apply(M,ze($)),h(M.length?M:null)})}}var y;if(m.asyncValidator)y=m.asyncValidator(m,f.value,v,f.source,a);else if(m.validator){try{y=m.validator(m,f.value,v,f.source,a)}catch(x){var b,w;(b=(w=console).error)===null||b===void 0||b.call(w,x),a.suppressValidatorError||setTimeout(function(){throw x},0),v(x.message)}y===!0?v():y===!1?v(typeof m.message=="function"?m.message(m.fullField||m.field):m.message||"".concat(m.fullField||m.field," fails")):y instanceof Array?v(y):y instanceof Error&&v(y.message)}y&&y.then&&y.then(function(){return v()},function(x){return v(x)})},function(f){l(f)},i)}},{key:"getType",value:function(t){if(t.type===void 0&&t.pattern instanceof RegExp&&(t.type="pattern"),typeof t.validator!="function"&&t.type&&!Fu.hasOwnProperty(t.type))throw new Error(Io("Unknown rule type %s",t.type));return t.type||"string"}},{key:"getValidationMethod",value:function(t){if(typeof t.validator=="function")return t.validator;var n=Object.keys(t),r=n.indexOf("message");return r!==-1&&n.splice(r,1),n.length===1&&n[0]==="required"?Fu.required:Fu[this.getType(t)]||void 0}}]),e})();X(Od,"register",function(e,t){if(typeof t!="function")throw new Error("Cannot register a validator by type, validator is not a function");Fu[e]=t});X(Od,"warning",eX);X(Od,"messages",N2);X(Od,"validators",Fu);var Mo="'${name}' is not a valid ${type}",XI={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:Mo,method:Mo,array:Mo,object:Mo,number:Mo,date:Mo,boolean:Mo,integer:Mo,float:Mo,regexp:Mo,email:Mo,url:Mo,hex:Mo},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}"}},y6=Od;function OX(e,t){return e.replace(/\\?\$\{\w+\}/g,function(n){if(n.startsWith("\\"))return n.slice(1);var r=n.slice(2,-1);return t[r]})}var b6="CODE_LOGIC_ERROR";function F2(e,t,n,r,o){return P2.apply(this,arguments)}function P2(){return P2=hl(fo().mark(function e(t,n,r,o,i){var a,s,l,c,u,d,f,h,m;return fo().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:return a=Q({},r),delete a.ruleIndex,y6.warning=function(){},a.validator&&(s=a.validator,a.validator=function(){try{return s.apply(void 0,arguments)}catch(g){return console.error(g),Promise.reject(b6)}}),l=null,a&&a.type==="array"&&a.defaultField&&(l=a.defaultField,delete a.defaultField),c=new y6(X({},t,[a])),u=Xl(XI,o.validateMessages),c.messages(u),d=[],p.prev=10,p.next=13,Promise.resolve(c.validate(X({},t,n),Q({},o)));case 13:p.next=18;break;case 15:p.prev=15,p.t0=p.catch(10),p.t0.errors&&(d=p.t0.errors.map(function(g,v){var y=g.message,b=y===b6?u.default:y;return C.isValidElement(b)?C.cloneElement(b,{key:"error_".concat(v)}):b}));case 18:if(!(!d.length&&l&&Array.isArray(n)&&n.length>0)){p.next=23;break}return p.next=21,Promise.all(n.map(function(g,v){return F2("".concat(t,".").concat(v),g,l,o,i)}));case 21:return f=p.sent,p.abrupt("return",f.reduce(function(g,v){return[].concat(ze(g),ze(v))},[]));case 23:return h=Q(Q({},r),{},{name:t,enum:(r.enum||[]).join(", ")},i),m=d.map(function(g){return typeof g=="string"?OX(g,h):g}),p.abrupt("return",m);case 26:case"end":return p.stop()}},e,null,[[10,15]])})),P2.apply(this,arguments)}function MX(e,t,n,r,o,i){var a=e.join("."),s=n.map(function(u,d){var f=u.validator,h=Q(Q({},u),{},{ruleIndex:d});return f&&(h.validator=function(m,p,g){var v=!1,y=function(){for(var w=arguments.length,x=new Array(w),E=0;E<w;E++)x[E]=arguments[E];Promise.resolve().then(function(){qr(!v,"Your validator function has already return a promise. `callback` will be ignored."),v||g.apply(void 0,x)})},b=f(m,p,y);v=b&&typeof b.then=="function"&&typeof b.catch=="function",qr(v,"`callback` is deprecated. Please return a promise instead."),v&&b.then(function(){g()}).catch(function(w){g(w||" ")})}),h}).sort(function(u,d){var f=u.warningOnly,h=u.ruleIndex,m=d.warningOnly,p=d.ruleIndex;return!!f==!!m?h-p:f?1:-1}),l;if(o===!0)l=new Promise((function(){var u=hl(fo().mark(function d(f,h){var m,p,g;return fo().wrap(function(v){for(;;)switch(v.prev=v.next){case 0:m=0;case 1:if(!(m<s.length)){v.next=12;break}return p=s[m],v.next=5,F2(a,t,p,r,i);case 5:if(g=v.sent,!g.length){v.next=9;break}return h([{errors:g,rule:p}]),v.abrupt("return");case 9:m+=1,v.next=1;break;case 12:f([]);case 13:case"end":return v.stop()}},d)}));return function(d,f){return u.apply(this,arguments)}})());else{var c=s.map(function(u){return F2(a,t,u,r,i).then(function(d){return{errors:d,rule:u}})});l=(o?DX(c):NX(c)).then(function(u){return Promise.reject(u)})}return l.catch(function(u){return u}),l}function NX(e){return I2.apply(this,arguments)}function I2(){return I2=hl(fo().mark(function e(t){return fo().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.all(t).then(function(r){var o,i=(o=[]).concat.apply(o,ze(r));return i}));case 1:case"end":return n.stop()}},e)})),I2.apply(this,arguments)}function DX(e){return B2.apply(this,arguments)}function B2(){return B2=hl(fo().mark(function e(t){var n;return fo().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return n=0,r.abrupt("return",new Promise(function(o){t.forEach(function(i){i.then(function(a){a.errors.length&&o([a]),n+=1,n===t.length&&o([])})})}));case 2:case"end":return r.stop()}},e)})),B2.apply(this,arguments)}function Sr(e){return O2(e)}function x6(e,t){var n={};return t.forEach(function(r){var o=ei(e,r);n=Zo(n,r,o)}),n}function oc(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return e&&e.some(function(r){return KI(t,r,n)})}function KI(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return!e||!t||!n&&e.length!==t.length?!1:t.every(function(r,o){return e[o]===r})}function TX(e,t){if(e===t)return!0;if(!e&&t||e&&!t||!e||!t||At(e)!=="object"||At(t)!=="object")return!1;var n=Object.keys(e),r=Object.keys(t),o=new Set([].concat(n,r));return ze(o).every(function(i){var a=e[i],s=t[i];return typeof a=="function"&&typeof s=="function"?!0:a===s})}function FX(e){var t=arguments.length<=1?void 0:arguments[1];return t&&t.target&&At(t.target)==="object"&&e in t.target?t.target[e]:t}function E6(e,t,n){var r=e.length;if(t<0||t>=r||n<0||n>=r)return e;var o=e[t],i=t-n;return i>0?[].concat(ze(e.slice(0,n)),[o],ze(e.slice(n,t)),ze(e.slice(t+1,r))):i<0?[].concat(ze(e.slice(0,t)),ze(e.slice(t+1,n+1)),[o],ze(e.slice(n+1,r))):e}var PX=["name"],Lo=[];function mm(e,t,n,r,o,i){return typeof e=="function"?e(t,n,"source"in i?{source:i.source}:{}):r!==o}var YC=(function(e){ds(n,e);var t=fs(n);function n(r){var o;if(xr(this,n),o=t.call(this,r),X(fn(o),"state",{resetCount:0}),X(fn(o),"cancelRegisterFunc",null),X(fn(o),"mounted",!1),X(fn(o),"touched",!1),X(fn(o),"dirty",!1),X(fn(o),"validatePromise",void 0),X(fn(o),"prevValidating",void 0),X(fn(o),"errors",Lo),X(fn(o),"warnings",Lo),X(fn(o),"cancelRegister",function(){var l=o.props,c=l.preserve,u=l.isListField,d=l.name;o.cancelRegisterFunc&&o.cancelRegisterFunc(u,c,Sr(d)),o.cancelRegisterFunc=null}),X(fn(o),"getNamePath",function(){var l=o.props,c=l.name,u=l.fieldContext,d=u.prefixName,f=d===void 0?[]:d;return c!==void 0?[].concat(ze(f),ze(c)):[]}),X(fn(o),"getRules",function(){var l=o.props,c=l.rules,u=c===void 0?[]:c,d=l.fieldContext;return u.map(function(f){return typeof f=="function"?f(d):f})}),X(fn(o),"refresh",function(){o.mounted&&o.setState(function(l){var c=l.resetCount;return{resetCount:c+1}})}),X(fn(o),"metaCache",null),X(fn(o),"triggerMetaEvent",function(l){var c=o.props.onMetaChange;if(c){var u=Q(Q({},o.getMeta()),{},{destroy:l});a0(o.metaCache,u)||c(u),o.metaCache=u}else o.metaCache=null}),X(fn(o),"onStoreChange",function(l,c,u){var d=o.props,f=d.shouldUpdate,h=d.dependencies,m=h===void 0?[]:h,p=d.onReset,g=u.store,v=o.getNamePath(),y=o.getValue(l),b=o.getValue(g),w=c&&oc(c,v);switch(u.type==="valueUpdate"&&u.source==="external"&&!a0(y,b)&&(o.touched=!0,o.dirty=!0,o.validatePromise=null,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent()),u.type){case"reset":if(!c||w){o.touched=!1,o.dirty=!1,o.validatePromise=void 0,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent(),p==null||p(),o.refresh();return}break;case"remove":{if(f&&mm(f,l,g,y,b,u)){o.reRender();return}break}case"setField":{var x=u.data;if(w){"touched"in x&&(o.touched=x.touched),"validating"in x&&!("originRCField"in x)&&(o.validatePromise=x.validating?Promise.resolve([]):null),"errors"in x&&(o.errors=x.errors||Lo),"warnings"in x&&(o.warnings=x.warnings||Lo),o.dirty=!0,o.triggerMetaEvent(),o.reRender();return}else if("value"in x&&oc(c,v,!0)){o.reRender();return}if(f&&!v.length&&mm(f,l,g,y,b,u)){o.reRender();return}break}case"dependenciesUpdate":{var E=m.map(Sr);if(E.some(function(k){return oc(u.relatedFields,k)})){o.reRender();return}break}default:if(w||(!m.length||v.length||f)&&mm(f,l,g,y,b,u)){o.reRender();return}break}f===!0&&o.reRender()}),X(fn(o),"validateRules",function(l){var c=o.getNamePath(),u=o.getValue(),d=l||{},f=d.triggerName,h=d.validateOnly,m=h===void 0?!1:h,p=Promise.resolve().then(hl(fo().mark(function g(){var v,y,b,w,x,E,k;return fo().wrap(function(S){for(;;)switch(S.prev=S.next){case 0:if(o.mounted){S.next=2;break}return S.abrupt("return",[]);case 2:if(v=o.props,y=v.validateFirst,b=y===void 0?!1:y,w=v.messageVariables,x=v.validateDebounce,E=o.getRules(),f&&(E=E.filter(function(O){return O}).filter(function(O){var A=O.validateTrigger;if(!A)return!0;var $=O2(A);return $.includes(f)})),!(x&&f)){S.next=10;break}return S.next=8,new Promise(function(O){setTimeout(O,x)});case 8:if(o.validatePromise===p){S.next=10;break}return S.abrupt("return",[]);case 10:return k=MX(c,u,E,l,b,w),k.catch(function(O){return O}).then(function(){var O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Lo;if(o.validatePromise===p){var A;o.validatePromise=null;var $=[],M=[];(A=O.forEach)===null||A===void 0||A.call(O,function(N){var D=N.rule.warningOnly,T=N.errors,P=T===void 0?Lo:T;D?M.push.apply(M,ze(P)):$.push.apply($,ze(P))}),o.errors=$,o.warnings=M,o.triggerMetaEvent(),o.reRender()}}),S.abrupt("return",k);case 13:case"end":return S.stop()}},g)})));return m||(o.validatePromise=p,o.dirty=!0,o.errors=Lo,o.warnings=Lo,o.triggerMetaEvent(),o.reRender()),p}),X(fn(o),"isFieldValidating",function(){return!!o.validatePromise}),X(fn(o),"isFieldTouched",function(){return o.touched}),X(fn(o),"isFieldDirty",function(){if(o.dirty||o.props.initialValue!==void 0)return!0;var l=o.props.fieldContext,c=l.getInternalHooks(Rs),u=c.getInitialValue;return u(o.getNamePath())!==void 0}),X(fn(o),"getErrors",function(){return o.errors}),X(fn(o),"getWarnings",function(){return o.warnings}),X(fn(o),"isListField",function(){return o.props.isListField}),X(fn(o),"isList",function(){return o.props.isList}),X(fn(o),"isPreserve",function(){return o.props.preserve}),X(fn(o),"getMeta",function(){o.prevValidating=o.isFieldValidating();var l={touched:o.isFieldTouched(),validating:o.prevValidating,errors:o.errors,warnings:o.warnings,name:o.getNamePath(),validated:o.validatePromise===null};return l}),X(fn(o),"getOnlyChild",function(l){if(typeof l=="function"){var c=o.getMeta();return Q(Q({},o.getOnlyChild(l(o.getControlled(),c,o.props.fieldContext))),{},{isFunction:!0})}var u=fc(l);return u.length!==1||!C.isValidElement(u[0])?{child:u,isFunction:!1}:{child:u[0],isFunction:!1}}),X(fn(o),"getValue",function(l){var c=o.props.fieldContext.getFieldsValue,u=o.getNamePath();return ei(l||c(!0),u)}),X(fn(o),"getControlled",function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=o.props,u=c.name,d=c.trigger,f=c.validateTrigger,h=c.getValueFromEvent,m=c.normalize,p=c.valuePropName,g=c.getValueProps,v=c.fieldContext,y=f!==void 0?f:v.validateTrigger,b=o.getNamePath(),w=v.getInternalHooks,x=v.getFieldsValue,E=w(Rs),k=E.dispatch,S=o.getValue(),O=g||function(D){return X({},p,D)},A=l[d],$=u!==void 0?O(S):{},M=Q(Q({},l),$);M[d]=function(){o.touched=!0,o.dirty=!0,o.triggerMetaEvent();for(var D,T=arguments.length,P=new Array(T),I=0;I<T;I++)P[I]=arguments[I];h?D=h.apply(void 0,P):D=FX.apply(void 0,[p].concat(P)),m&&(D=m(D,S,x(!0))),D!==S&&k({type:"updateValue",namePath:b,value:D}),A&&A.apply(void 0,P)};var N=O2(y||[]);return N.forEach(function(D){var T=M[D];M[D]=function(){T&&T.apply(void 0,arguments);var P=o.props.rules;P&&P.length&&k({type:"validateField",namePath:b,triggerName:D})}}),M}),r.fieldContext){var i=r.fieldContext.getInternalHooks,a=i(Rs),s=a.initEntityValue;s(fn(o))}return o}return Er(n,[{key:"componentDidMount",value:function(){var r=this.props,o=r.shouldUpdate,i=r.fieldContext;if(this.mounted=!0,i){var a=i.getInternalHooks,s=a(Rs),l=s.registerField;this.cancelRegisterFunc=l(this)}o===!0&&this.reRender()}},{key:"componentWillUnmount",value:function(){this.cancelRegister(),this.triggerMetaEvent(!0),this.mounted=!1}},{key:"reRender",value:function(){this.mounted&&this.forceUpdate()}},{key:"render",value:function(){var r=this.state.resetCount,o=this.props.children,i=this.getOnlyChild(o),a=i.child,s=i.isFunction,l;return s?l=a:C.isValidElement(a)?l=C.cloneElement(a,this.getControlled(a.props)):(qr(!a,"`children` of Field is not validate ReactElement."),l=a),C.createElement(C.Fragment,{key:r},l)}}]),n})(C.Component);X(YC,"contextType",el);X(YC,"defaultProps",{trigger:"onChange",valuePropName:"value"});function XC(e){var t,n=e.name,r=tn(e,PX),o=C.useContext(el),i=C.useContext(td),a=n!==void 0?Sr(n):void 0,s=(t=r.isListField)!==null&&t!==void 0?t:!!i,l="keep";return s||(l="_".concat((a||[]).join("_"))),C.createElement(YC,Qe({key:l,name:a,isListField:s},r,{fieldContext:o}))}function ZI(e){var t=e.name,n=e.initialValue,r=e.children,o=e.rules,i=e.validateTrigger,a=e.isListField,s=C.useContext(el),l=C.useContext(td),c=C.useRef({keys:[],id:0}),u=c.current,d=C.useMemo(function(){var p=Sr(s.prefixName)||[];return[].concat(ze(p),ze(Sr(t)))},[s.prefixName,t]),f=C.useMemo(function(){return Q(Q({},s),{},{prefixName:d})},[s,d]),h=C.useMemo(function(){return{getKey:function(p){var g=d.length,v=p[g];return[u.keys[v],p.slice(g+1)]}}},[d]);if(typeof r!="function")return qr(!1,"Form.List only accepts function as children."),null;var m=function(p,g,v){var y=v.source;return y==="internal"?!1:p!==g};return C.createElement(td.Provider,{value:h},C.createElement(el.Provider,{value:f},C.createElement(XC,{name:[],shouldUpdate:m,rules:o,validateTrigger:i,initialValue:n,isList:!0,isListField:a??!!l},function(p,g){var v=p.value,y=v===void 0?[]:v,b=p.onChange,w=s.getFieldValue,x=function(){var S=w(d||[]);return S||[]},E={add:function(S,O){var A=x();O>=0&&O<=A.length?(u.keys=[].concat(ze(u.keys.slice(0,O)),[u.id],ze(u.keys.slice(O))),b([].concat(ze(A.slice(0,O)),[S],ze(A.slice(O))))):(u.keys=[].concat(ze(u.keys),[u.id]),b([].concat(ze(A),[S]))),u.id+=1},remove:function(S){var O=x(),A=new Set(Array.isArray(S)?S:[S]);A.size<=0||(u.keys=u.keys.filter(function($,M){return!A.has(M)}),b(O.filter(function($,M){return!A.has(M)})))},move:function(S,O){if(S!==O){var A=x();S<0||S>=A.length||O<0||O>=A.length||(u.keys=E6(u.keys,S,O),b(E6(A,S,O)))}}},k=y||[];return Array.isArray(k)||(k=[]),r(k.map(function(S,O){var A=u.keys[O];return A===void 0&&(u.keys[O]=u.id,A=u.keys[O],u.id+=1),{name:O,key:A,isListField:!0}}),E,g)})))}function IX(e){var t=!1,n=e.length,r=[];return e.length?new Promise(function(o,i){e.forEach(function(a,s){a.catch(function(l){return t=!0,l}).then(function(l){n-=1,r[s]=l,!(n>0)&&(t&&i(r),o(r))})})}):Promise.resolve([])}var QI="__@field_split__";function vm(e){return e.map(function(t){return"".concat(At(t),":").concat(t)}).join(QI)}var Ml=(function(){function e(){xr(this,e),X(this,"kvs",new Map)}return Er(e,[{key:"set",value:function(t,n){this.kvs.set(vm(t),n)}},{key:"get",value:function(t){return this.kvs.get(vm(t))}},{key:"update",value:function(t,n){var r=this.get(t),o=n(r);o?this.set(t,o):this.delete(t)}},{key:"delete",value:function(t){this.kvs.delete(vm(t))}},{key:"map",value:function(t){return ze(this.kvs.entries()).map(function(n){var r=te(n,2),o=r[0],i=r[1],a=o.split(QI);return t({key:a.map(function(s){var l=s.match(/^([^:]*):(.*)$/),c=te(l,3),u=c[1],d=c[2];return u==="number"?Number(d):d}),value:i})})}},{key:"toJSON",value:function(){var t={};return this.map(function(n){var r=n.key,o=n.value;return t[r.join(".")]=o,null}),t}}]),e})(),BX=["name"],RX=Er(function e(t){var n=this;xr(this,e),X(this,"formHooked",!1),X(this,"forceRootUpdate",void 0),X(this,"subscribable",!0),X(this,"store",{}),X(this,"fieldEntities",[]),X(this,"initialValues",{}),X(this,"callbacks",{}),X(this,"validateMessages",null),X(this,"preserve",null),X(this,"lastValidatePromise",null),X(this,"getForm",function(){return{getFieldValue:n.getFieldValue,getFieldsValue:n.getFieldsValue,getFieldError:n.getFieldError,getFieldWarning:n.getFieldWarning,getFieldsError:n.getFieldsError,isFieldsTouched:n.isFieldsTouched,isFieldTouched:n.isFieldTouched,isFieldValidating:n.isFieldValidating,isFieldsValidating:n.isFieldsValidating,resetFields:n.resetFields,setFields:n.setFields,setFieldValue:n.setFieldValue,setFieldsValue:n.setFieldsValue,validateFields:n.validateFields,submit:n.submit,_init:!0,getInternalHooks:n.getInternalHooks}}),X(this,"getInternalHooks",function(r){return r===Rs?(n.formHooked=!0,{dispatch:n.dispatch,initEntityValue:n.initEntityValue,registerField:n.registerField,useSubscribe:n.useSubscribe,setInitialValues:n.setInitialValues,destroyForm:n.destroyForm,setCallbacks:n.setCallbacks,setValidateMessages:n.setValidateMessages,getFields:n.getFields,setPreserve:n.setPreserve,getInitialValue:n.getInitialValue,registerWatch:n.registerWatch}):(qr(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),X(this,"useSubscribe",function(r){n.subscribable=r}),X(this,"prevWithoutPreserves",null),X(this,"setInitialValues",function(r,o){if(n.initialValues=r||{},o){var i,a=Xl(r,n.store);(i=n.prevWithoutPreserves)===null||i===void 0||i.map(function(s){var l=s.key;a=Zo(a,l,ei(r,l))}),n.prevWithoutPreserves=null,n.updateStore(a)}}),X(this,"destroyForm",function(r){if(r)n.updateStore({});else{var o=new Ml;n.getFieldEntities(!0).forEach(function(i){n.isMergedPreserve(i.isPreserve())||o.set(i.getNamePath(),!0)}),n.prevWithoutPreserves=o}}),X(this,"getInitialValue",function(r){var o=ei(n.initialValues,r);return r.length?Xl(o):o}),X(this,"setCallbacks",function(r){n.callbacks=r}),X(this,"setValidateMessages",function(r){n.validateMessages=r}),X(this,"setPreserve",function(r){n.preserve=r}),X(this,"watchList",[]),X(this,"registerWatch",function(r){return n.watchList.push(r),function(){n.watchList=n.watchList.filter(function(o){return o!==r})}}),X(this,"notifyWatch",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(n.watchList.length){var o=n.getFieldsValue(),i=n.getFieldsValue(!0);n.watchList.forEach(function(a){a(o,i,r)})}}),X(this,"timeoutId",null),X(this,"warningUnhooked",function(){}),X(this,"updateStore",function(r){n.store=r}),X(this,"getFieldEntities",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return r?n.fieldEntities.filter(function(o){return o.getNamePath().length}):n.fieldEntities}),X(this,"getFieldsMap",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,o=new Ml;return n.getFieldEntities(r).forEach(function(i){var a=i.getNamePath();o.set(a,i)}),o}),X(this,"getFieldEntitiesForNamePathList",function(r){if(!r)return n.getFieldEntities(!0);var o=n.getFieldsMap(!0);return r.map(function(i){var a=Sr(i);return o.get(a)||{INVALIDATE_NAME_PATH:Sr(i)}})}),X(this,"getFieldsValue",function(r,o){n.warningUnhooked();var i,a,s;if(r===!0||Array.isArray(r)?(i=r,a=o):r&&At(r)==="object"&&(s=r.strict,a=r.filter),i===!0&&!a)return n.store;var l=n.getFieldEntitiesForNamePathList(Array.isArray(i)?i:null),c=[];return l.forEach(function(u){var d,f,h="INVALIDATE_NAME_PATH"in u?u.INVALIDATE_NAME_PATH:u.getNamePath();if(s){var m,p;if((m=(p=u).isList)!==null&&m!==void 0&&m.call(p))return}else if(!i&&(d=(f=u).isListField)!==null&&d!==void 0&&d.call(f))return;if(!a)c.push(h);else{var g="getMeta"in u?u.getMeta():null;a(g)&&c.push(h)}}),x6(n.store,c.map(Sr))}),X(this,"getFieldValue",function(r){n.warningUnhooked();var o=Sr(r);return ei(n.store,o)}),X(this,"getFieldsError",function(r){n.warningUnhooked();var o=n.getFieldEntitiesForNamePathList(r);return o.map(function(i,a){return i&&!("INVALIDATE_NAME_PATH"in i)?{name:i.getNamePath(),errors:i.getErrors(),warnings:i.getWarnings()}:{name:Sr(r[a]),errors:[],warnings:[]}})}),X(this,"getFieldError",function(r){n.warningUnhooked();var o=Sr(r),i=n.getFieldsError([o])[0];return i.errors}),X(this,"getFieldWarning",function(r){n.warningUnhooked();var o=Sr(r),i=n.getFieldsError([o])[0];return i.warnings}),X(this,"isFieldsTouched",function(){n.warningUnhooked();for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];var a=o[0],s=o[1],l,c=!1;o.length===0?l=null:o.length===1?Array.isArray(a)?(l=a.map(Sr),c=!1):(l=null,c=a):(l=a.map(Sr),c=s);var u=n.getFieldEntities(!0),d=function(p){return p.isFieldTouched()};if(!l)return c?u.every(function(p){return d(p)||p.isList()}):u.some(d);var f=new Ml;l.forEach(function(p){f.set(p,[])}),u.forEach(function(p){var g=p.getNamePath();l.forEach(function(v){v.every(function(y,b){return g[b]===y})&&f.update(v,function(y){return[].concat(ze(y),[p])})})});var h=function(p){return p.some(d)},m=f.map(function(p){var g=p.value;return g});return c?m.every(h):m.some(h)}),X(this,"isFieldTouched",function(r){return n.warningUnhooked(),n.isFieldsTouched([r])}),X(this,"isFieldsValidating",function(r){n.warningUnhooked();var o=n.getFieldEntities();if(!r)return o.some(function(a){return a.isFieldValidating()});var i=r.map(Sr);return o.some(function(a){var s=a.getNamePath();return oc(i,s)&&a.isFieldValidating()})}),X(this,"isFieldValidating",function(r){return n.warningUnhooked(),n.isFieldsValidating([r])}),X(this,"resetWithFieldInitialValue",function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=new Ml,i=n.getFieldEntities(!0);i.forEach(function(l){var c=l.props.initialValue,u=l.getNamePath();if(c!==void 0){var d=o.get(u)||new Set;d.add({entity:l,value:c}),o.set(u,d)}});var a=function(l){l.forEach(function(c){var u=c.props.initialValue;if(u!==void 0){var d=c.getNamePath(),f=n.getInitialValue(d);if(f!==void 0)qr(!1,"Form already set 'initialValues' with path '".concat(d.join("."),"'. Field can not overwrite it."));else{var h=o.get(d);if(h&&h.size>1)qr(!1,"Multiple Field with path '".concat(d.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(h){var m=n.getFieldValue(d),p=c.isListField();!p&&(!r.skipExist||m===void 0)&&n.updateStore(Zo(n.store,d,ze(h)[0].value))}}}})},s;r.entities?s=r.entities:r.namePathList?(s=[],r.namePathList.forEach(function(l){var c=o.get(l);if(c){var u;(u=s).push.apply(u,ze(ze(c).map(function(d){return d.entity})))}})):s=i,a(s)}),X(this,"resetFields",function(r){n.warningUnhooked();var o=n.store;if(!r){n.updateStore(Xl(n.initialValues)),n.resetWithFieldInitialValue(),n.notifyObservers(o,null,{type:"reset"}),n.notifyWatch();return}var i=r.map(Sr);i.forEach(function(a){var s=n.getInitialValue(a);n.updateStore(Zo(n.store,a,s))}),n.resetWithFieldInitialValue({namePathList:i}),n.notifyObservers(o,i,{type:"reset"}),n.notifyWatch(i)}),X(this,"setFields",function(r){n.warningUnhooked();var o=n.store,i=[];r.forEach(function(a){var s=a.name,l=tn(a,BX),c=Sr(s);i.push(c),"value"in l&&n.updateStore(Zo(n.store,c,l.value)),n.notifyObservers(o,[c],{type:"setField",data:a})}),n.notifyWatch(i)}),X(this,"getFields",function(){var r=n.getFieldEntities(!0),o=r.map(function(i){var a=i.getNamePath(),s=i.getMeta(),l=Q(Q({},s),{},{name:a,value:n.getFieldValue(a)});return Object.defineProperty(l,"originRCField",{value:!0}),l});return o}),X(this,"initEntityValue",function(r){var o=r.props.initialValue;if(o!==void 0){var i=r.getNamePath(),a=ei(n.store,i);a===void 0&&n.updateStore(Zo(n.store,i,o))}}),X(this,"isMergedPreserve",function(r){var o=r!==void 0?r:n.preserve;return o??!0}),X(this,"registerField",function(r){n.fieldEntities.push(r);var o=r.getNamePath();if(n.notifyWatch([o]),r.props.initialValue!==void 0){var i=n.store;n.resetWithFieldInitialValue({entities:[r],skipExist:!0}),n.notifyObservers(i,[r.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(a,s){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(n.fieldEntities=n.fieldEntities.filter(function(d){return d!==r}),!n.isMergedPreserve(s)&&(!a||l.length>1)){var c=a?void 0:n.getInitialValue(o);if(o.length&&n.getFieldValue(o)!==c&&n.fieldEntities.every(function(d){return!KI(d.getNamePath(),o)})){var u=n.store;n.updateStore(Zo(u,o,c,!0)),n.notifyObservers(u,[o],{type:"remove"}),n.triggerDependenciesUpdate(u,o)}}n.notifyWatch([o])}}),X(this,"dispatch",function(r){switch(r.type){case"updateValue":{var o=r.namePath,i=r.value;n.updateValue(o,i);break}case"validateField":{var a=r.namePath,s=r.triggerName;n.validateFields([a],{triggerName:s});break}}}),X(this,"notifyObservers",function(r,o,i){if(n.subscribable){var a=Q(Q({},i),{},{store:n.getFieldsValue(!0)});n.getFieldEntities().forEach(function(s){var l=s.onStoreChange;l(r,o,a)})}else n.forceRootUpdate()}),X(this,"triggerDependenciesUpdate",function(r,o){var i=n.getDependencyChildrenFields(o);return i.length&&n.validateFields(i),n.notifyObservers(r,i,{type:"dependenciesUpdate",relatedFields:[o].concat(ze(i))}),i}),X(this,"updateValue",function(r,o){var i=Sr(r),a=n.store;n.updateStore(Zo(n.store,i,o)),n.notifyObservers(a,[i],{type:"valueUpdate",source:"internal"}),n.notifyWatch([i]);var s=n.triggerDependenciesUpdate(a,i),l=n.callbacks.onValuesChange;if(l){var c=x6(n.store,[i]);l(c,n.getFieldsValue())}n.triggerOnFieldsChange([i].concat(ze(s)))}),X(this,"setFieldsValue",function(r){n.warningUnhooked();var o=n.store;if(r){var i=Xl(n.store,r);n.updateStore(i)}n.notifyObservers(o,null,{type:"valueUpdate",source:"external"}),n.notifyWatch()}),X(this,"setFieldValue",function(r,o){n.setFields([{name:r,value:o,errors:[],warnings:[]}])}),X(this,"getDependencyChildrenFields",function(r){var o=new Set,i=[],a=new Ml;n.getFieldEntities().forEach(function(l){var c=l.props.dependencies;(c||[]).forEach(function(u){var d=Sr(u);a.update(d,function(){var f=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return f.add(l),f})})});var s=function l(c){var u=a.get(c)||new Set;u.forEach(function(d){if(!o.has(d)){o.add(d);var f=d.getNamePath();d.isFieldDirty()&&f.length&&(i.push(f),l(f))}})};return s(r),i}),X(this,"triggerOnFieldsChange",function(r,o){var i=n.callbacks.onFieldsChange;if(i){var a=n.getFields();if(o){var s=new Ml;o.forEach(function(c){var u=c.name,d=c.errors;s.set(u,d)}),a.forEach(function(c){c.errors=s.get(c.name)||c.errors})}var l=a.filter(function(c){var u=c.name;return oc(r,u)});l.length&&i(l,a)}}),X(this,"validateFields",function(r,o){n.warningUnhooked();var i,a;Array.isArray(r)||typeof r=="string"||typeof o=="string"?(i=r,a=o):a=r;var s=!!i,l=s?i.map(Sr):[],c=[],u=String(Date.now()),d=new Set,f=a||{},h=f.recursive,m=f.dirty;n.getFieldEntities(!0).forEach(function(y){if(s||l.push(y.getNamePath()),!(!y.props.rules||!y.props.rules.length)&&!(m&&!y.isFieldDirty())){var b=y.getNamePath();if(d.add(b.join(u)),!s||oc(l,b,h)){var w=y.validateRules(Q({validateMessages:Q(Q({},XI),n.validateMessages)},a));c.push(w.then(function(){return{name:b,errors:[],warnings:[]}}).catch(function(x){var E,k=[],S=[];return(E=x.forEach)===null||E===void 0||E.call(x,function(O){var A=O.rule.warningOnly,$=O.errors;A?S.push.apply(S,ze($)):k.push.apply(k,ze($))}),k.length?Promise.reject({name:b,errors:k,warnings:S}):{name:b,errors:k,warnings:S}}))}}});var p=IX(c);n.lastValidatePromise=p,p.catch(function(y){return y}).then(function(y){var b=y.map(function(w){var x=w.name;return x});n.notifyObservers(n.store,b,{type:"validateFinish"}),n.triggerOnFieldsChange(b,y)});var g=p.then(function(){return n.lastValidatePromise===p?Promise.resolve(n.getFieldsValue(l)):Promise.reject([])}).catch(function(y){var b=y.filter(function(w){return w&&w.errors.length});return Promise.reject({values:n.getFieldsValue(l),errorFields:b,outOfDate:n.lastValidatePromise!==p})});g.catch(function(y){return y});var v=l.filter(function(y){return d.has(y.join(u))});return n.triggerOnFieldsChange(v),g}),X(this,"submit",function(){n.warningUnhooked(),n.validateFields().then(function(r){var o=n.callbacks.onFinish;if(o)try{o(r)}catch(i){console.error(i)}}).catch(function(r){var o=n.callbacks.onFinishFailed;o&&o(r)})}),this.forceRootUpdate=t});function KC(e){var t=C.useRef(),n=C.useState({}),r=te(n,2),o=r[1];if(!t.current)if(e)t.current=e;else{var i=function(){o({})},a=new RX(i);t.current=a.getForm()}return[t.current]}var R2=C.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),JI=function(e){var t=e.validateMessages,n=e.onFormChange,r=e.onFormFinish,o=e.children,i=C.useContext(R2),a=C.useRef({});return C.createElement(R2.Provider,{value:Q(Q({},i),{},{validateMessages:Q(Q({},i.validateMessages),t),triggerFormChange:function(s,l){n&&n(s,{changedFields:l,forms:a.current}),i.triggerFormChange(s,l)},triggerFormFinish:function(s,l){r&&r(s,{values:l,forms:a.current}),i.triggerFormFinish(s,l)},registerForm:function(s,l){s&&(a.current=Q(Q({},a.current),{},X({},s,l))),i.registerForm(s,l)},unregisterForm:function(s){var l=Q({},a.current);delete l[s],a.current=l,i.unregisterForm(s)}})},o)},_X=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed","clearOnDestroy"],jX=function(e,t){var n=e.name,r=e.initialValues,o=e.fields,i=e.form,a=e.preserve,s=e.children,l=e.component,c=l===void 0?"form":l,u=e.validateMessages,d=e.validateTrigger,f=d===void 0?"onChange":d,h=e.onValuesChange,m=e.onFieldsChange,p=e.onFinish,g=e.onFinishFailed,v=e.clearOnDestroy,y=tn(e,_X),b=C.useRef(null),w=C.useContext(R2),x=KC(i),E=te(x,1),k=E[0],S=k.getInternalHooks(Rs),O=S.useSubscribe,A=S.setInitialValues,$=S.setCallbacks,M=S.setValidateMessages,N=S.setPreserve,D=S.destroyForm;C.useImperativeHandle(t,function(){return Q(Q({},k),{},{nativeElement:b.current})}),C.useEffect(function(){return w.registerForm(n,k),function(){w.unregisterForm(n)}},[w,k,n]),M(Q(Q({},w.validateMessages),u)),$({onValuesChange:h,onFieldsChange:function(j){if(w.triggerFormChange(n,j),m){for(var _=arguments.length,F=new Array(_>1?_-1:0),B=1;B<_;B++)F[B-1]=arguments[B];m.apply(void 0,[j].concat(F))}},onFinish:function(j){w.triggerFormFinish(n,j),p&&p(j)},onFinishFailed:g}),N(a);var T=C.useRef(null);A(r,!T.current),T.current||(T.current=!0),C.useEffect(function(){return function(){return D(v)}},[]);var P,I=typeof s=="function";if(I){var R=k.getFieldsValue(!0);P=s(R,k)}else P=s;O(!I);var H=C.useRef();C.useEffect(function(){TX(H.current||[],o||[])||k.setFields(o||[]),H.current=o},[o,k]);var V=C.useMemo(function(){return Q(Q({},k),{},{validateTrigger:f})},[k,f]),L=C.createElement(td.Provider,{value:null},C.createElement(el.Provider,{value:V},P));return c===!1?L:C.createElement(c,Qe({},y,{ref:b,onSubmit:function(j){j.preventDefault(),j.stopPropagation(),k.submit()},onReset:function(j){var _;j.preventDefault(),k.resetFields(),(_=y.onReset)===null||_===void 0||_.call(y,j)}}),L)};function w6(e){try{return JSON.stringify(e)}catch{return Math.random()}}function eB(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],o=t[1],i=o===void 0?{}:o,a=KY(i)?{form:i}:i,s=a.form,l=nt(),c=te(l,2),u=c[0],d=c[1],f=Gt(function(){return w6(u)},[u]),h=et(f);h.current=f;var m=pr(el),p=s||m,g=p&&p._init,v=Sr(r),y=et(v);return y.current=v,Et(function(){if(g){var b=p.getFieldsValue,w=p.getInternalHooks,x=w(Rs),E=x.registerWatch,k=function(A,$){var M=a.preserve?$:A;return typeof r=="function"?r(M):ei(M,y.current)},S=E(function(A,$){var M=k(A,$),N=w6(M);h.current!==N&&(h.current=N,d(M))}),O=k(b(),b(!0));return u!==O&&d(O),S}},[g]),u}var LX=C.forwardRef(jX),Tc=LX;Tc.FormProvider=JI;Tc.Field=XC;Tc.List=ZI;Tc.useForm=KC;Tc.useWatch=eB;const ma=C.createContext({labelAlign:"right",layout:"horizontal",itemRef:()=>{}}),tB=C.createContext(null),nB=e=>{const t=ta(e,["prefixCls"]);return C.createElement(JI,Object.assign({},t))},ZC=C.createContext({prefixCls:""}),Yr=C.createContext({}),rB=({children:e,status:t,override:n})=>{const r=C.useContext(Yr),o=C.useMemo(()=>{const i=Object.assign({},r);return n&&delete i.isFormItemInput,t&&(delete i.status,delete i.hasFeedback,delete i.feedbackIcon),i},[t,n,r]);return C.createElement(Yr.Provider,{value:o},e)},oB=C.createContext(void 0),ts=e=>{const{space:t,form:n,children:r}=e;if(r==null)return null;let o=r;return n&&(o=we.createElement(rB,{override:!0,status:!0},o)),t&&(o=we.createElement(Sq,null,o)),o},zX=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"}}}},HX=e=>{const{componentCls:t}=e;return{[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},WX=(e,t)=>{const{prefixCls:n,componentCls:r,gridColumns:o}=e,i={};for(let a=o;a>=0;a--)a===0?(i[`${r}${t}-${a}`]={display:"none"},i[`${r}-push-${a}`]={insetInlineStart:"auto"},i[`${r}-pull-${a}`]={insetInlineEnd:"auto"},i[`${r}${t}-push-${a}`]={insetInlineStart:"auto"},i[`${r}${t}-pull-${a}`]={insetInlineEnd:"auto"},i[`${r}${t}-offset-${a}`]={marginInlineStart:0},i[`${r}${t}-order-${a}`]={order:0}):(i[`${r}${t}-${a}`]=[{"--ant-display":"block",display:"block"},{display:"var(--ant-display)",flex:`0 0 ${a/o*100}%`,maxWidth:`${a/o*100}%`}],i[`${r}${t}-push-${a}`]={insetInlineStart:`${a/o*100}%`},i[`${r}${t}-pull-${a}`]={insetInlineEnd:`${a/o*100}%`},i[`${r}${t}-offset-${a}`]={marginInlineStart:`${a/o*100}%`},i[`${r}${t}-order-${a}`]={order:a});return i[`${r}${t}-flex`]={flex:`var(--${n}${t}-flex)`},i},_2=(e,t)=>WX(e,t),VX=(e,t,n)=>({[`@media (min-width: ${Ce(t)})`]:Object.assign({},_2(e,n))}),GX=()=>({}),UX=()=>({}),qX=Pr("Grid",zX,GX),YX=e=>({xs:e.screenXSMin,sm:e.screenSMMin,md:e.screenMDMin,lg:e.screenLGMin,xl:e.screenXLMin,xxl:e.screenXXLMin}),XX=Pr("Grid",e=>{const t=Mn(e,{gridColumns:24}),n=YX(t);return delete n.xs,[HX(t),_2(t,""),_2(t,"-xs"),Object.keys(n).map(r=>VX(t,n[r],`-${r}`)).reduce((r,o)=>Object.assign(Object.assign({},r),o),{})]},UX),KX=we.createContext({});function ZX(e){return t=>C.createElement(hs,{theme:{token:{motion:!1,zIndexPopupBase:0}}},C.createElement(e,Object.assign({},t)))}const QC=(e,t,n,r,o)=>ZX(i=>{const{prefixCls:a,style:s}=i,l=C.useRef(null),[c,u]=C.useState(0),[d,f]=C.useState(0),[h,m]=yr(!1,{value:i.open}),{getPrefixCls:p}=C.useContext(pn),g=p(r||"select",a);C.useEffect(()=>{if(m(!0),typeof ResizeObserver<"u"){const b=new ResizeObserver(x=>{const E=x[0].target;u(E.offsetHeight+8),f(E.offsetWidth)}),w=setInterval(()=>{var x;const E=`.${g}-dropdown`,k=(x=l.current)===null||x===void 0?void 0:x.querySelector(E);k&&(clearInterval(w),b.observe(k))},10);return()=>{clearInterval(w),b.disconnect()}}},[g]);let v=Object.assign(Object.assign({},i),{style:Object.assign(Object.assign({},s),{margin:0}),open:h,visible:h,getPopupContainer:()=>l.current});t&&Object.assign(v,{[t]:{overflow:{adjustX:!1,adjustY:!1}}});const y={paddingBottom:c,position:"relative",minWidth:d};return C.createElement("div",{ref:l,style:y},C.createElement(e,Object.assign({},v)))}),JC=(function(){if(typeof navigator>"u"||typeof window>"u")return!1;var e=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|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|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(e)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(e==null?void 0:e.substr(0,4))});var Dp=function(e){var t=e.className,n=e.customizeIcon,r=e.customizeIconProps,o=e.children,i=e.onMouseDown,a=e.onClick,s=typeof n=="function"?n(r):n;return C.createElement("span",{className:t,onMouseDown:function(l){l.preventDefault(),i==null||i(l)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:a,"aria-hidden":!0},s!==void 0?s:C.createElement("span",{className:me(t.split(/\s+/).map(function(l){return"".concat(l,"-icon")}))},o))},QX=function(e,t,n,r,o){var i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,a=arguments.length>6?arguments[6]:void 0,s=arguments.length>7?arguments[7]:void 0,l=we.useMemo(function(){if(At(r)==="object")return r.clearIcon;if(o)return o},[r,o]),c=we.useMemo(function(){return!!(!i&&r&&(n.length||a)&&!(s==="combobox"&&a===""))},[r,i,n.length,a,s]);return{allowClear:c,clearIcon:we.createElement(Dp,{className:"".concat(e,"-clear"),onMouseDown:t,customizeIcon:l},"\xD7")}},iB=C.createContext(null);function JX(){return C.useContext(iB)}function eK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,t=C.useState(!1),n=te(t,2),r=n[0],o=n[1],i=C.useRef(null),a=function(){window.clearTimeout(i.current)};C.useEffect(function(){return a},[]);var s=function(l,c){a(),i.current=window.setTimeout(function(){o(l),c&&c()},e)};return[r,s,a]}function aB(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,t=C.useRef(null),n=C.useRef(null);C.useEffect(function(){return function(){window.clearTimeout(n.current)}},[]);function r(o){(o||t.current===null)&&(t.current=o),window.clearTimeout(n.current),n.current=window.setTimeout(function(){t.current=null},e)}return[function(){return t.current},r]}function tK(e,t,n,r){var o=C.useRef(null);o.current={open:t,triggerOpen:n,customizedTrigger:r},C.useEffect(function(){function i(a){var s;if(!((s=o.current)!==null&&s!==void 0&&s.customizedTrigger)){var l=a.target;l.shadowRoot&&a.composed&&(l=a.composedPath()[0]||l),o.current.open&&e().filter(function(c){return c}).every(function(c){return!c.contains(l)&&c!==l})&&o.current.triggerOpen(!1)}}return window.addEventListener("mousedown",i),function(){return window.removeEventListener("mousedown",i)}},[])}function nK(e){return e&&![St.ESC,St.SHIFT,St.BACKSPACE,St.TAB,St.WIN_KEY,St.ALT,St.META,St.WIN_KEY_RIGHT,St.CTRL,St.SEMICOLON,St.EQUALS,St.CAPS_LOCK,St.CONTEXT_MENU,St.F1,St.F2,St.F3,St.F4,St.F5,St.F6,St.F7,St.F8,St.F9,St.F10,St.F11,St.F12].includes(e)}var rK=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],Nl=void 0;function oK(e,t){var n=e.prefixCls,r=e.invalidate,o=e.item,i=e.renderItem,a=e.responsive,s=e.responsiveDisabled,l=e.registerSize,c=e.itemKey,u=e.className,d=e.style,f=e.children,h=e.display,m=e.order,p=e.component,g=p===void 0?"div":p,v=tn(e,rK),y=a&&!h;function b(S){l(c,S)}C.useEffect(function(){return function(){b(null)}},[]);var w=i&&o!==Nl?i(o,{index:m}):f,x;r||(x={opacity:y?0:1,height:y?0:Nl,overflowY:y?"hidden":Nl,order:a?m:Nl,pointerEvents:y?"none":Nl,position:y?"absolute":Nl});var E={};y&&(E["aria-hidden"]=!0);var k=C.createElement(g,Qe({className:me(!r&&n,u),style:Q(Q({},x),d)},E,v,{ref:t}),w);return a&&(k=C.createElement(ea,{onResize:function(S){var O=S.offsetWidth;b(O)},disabled:s},k)),k}var Ql=C.forwardRef(oK);Ql.displayName="Item";function iK(e){if(typeof MessageChannel>"u")en(e);else{var t=new MessageChannel;t.port1.onmessage=function(){return e()},t.port2.postMessage(void 0)}}function aK(){var e=C.useRef(null),t=function(n){e.current||(e.current=[],iK(function(){Qz(function(){e.current.forEach(function(r){r()}),e.current=null})})),e.current.push(n)};return t}function Dl(e,t){var n=C.useState(t),r=te(n,2),o=r[0],i=r[1],a=cn(function(s){e(function(){i(s)})});return[o,a]}var g0=we.createContext(null),sK=["component"],lK=["className"],cK=["className"],uK=function(e,t){var n=C.useContext(g0);if(!n){var r=e.component,o=r===void 0?"div":r,i=tn(e,sK);return C.createElement(o,Qe({},i,{ref:t}))}var a=n.className,s=tn(n,lK),l=e.className,c=tn(e,cK);return C.createElement(g0.Provider,{value:null},C.createElement(Ql,Qe({ref:t,className:me(a,l)},s,c)))},sB=C.forwardRef(uK);sB.displayName="RawItem";var dK=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","prefix","suffix","component","itemComponent","onVisibleChange"],lB="responsive",cB="invalidate";function fK(e){return"+ ".concat(e.length," ...")}function hK(e,t){var n=e.prefixCls,r=n===void 0?"rc-overflow":n,o=e.data,i=o===void 0?[]:o,a=e.renderItem,s=e.renderRawItem,l=e.itemKey,c=e.itemWidth,u=c===void 0?10:c,d=e.ssr,f=e.style,h=e.className,m=e.maxCount,p=e.renderRest,g=e.renderRawRest,v=e.prefix,y=e.suffix,b=e.component,w=b===void 0?"div":b,x=e.itemComponent,E=e.onVisibleChange,k=tn(e,dK),S=d==="full",O=aK(),A=Dl(O,null),$=te(A,2),M=$[0],N=$[1],D=M||0,T=Dl(O,new Map),P=te(T,2),I=P[0],R=P[1],H=Dl(O,0),V=te(H,2),L=V[0],j=V[1],_=Dl(O,0),F=te(_,2),B=F[0],z=F[1],G=Dl(O,0),W=te(G,2),q=W[0],U=W[1],Y=Dl(O,0),ie=te(Y,2),K=ie[0],re=ie[1],oe=nt(null),ne=te(oe,2),ae=ne[0],de=ne[1],ge=nt(null),Se=te(ge,2),ye=Se[0],be=Se[1],ce=C.useMemo(function(){return ye===null&&S?Number.MAX_SAFE_INTEGER:ye||0},[ye,M]),he=nt(!1),Te=te(he,2),se=Te[0],Pe=Te[1],De="".concat(r,"-item"),He=Math.max(L,B),ue=m===lB,ve=i.length&&ue,xe=m===cB,fe=ve||typeof m=="number"&&i.length>m,pe=Gt(function(){var Ne=i;return ve?M===null&&S?Ne=i:Ne=i.slice(0,Math.min(i.length,D/u)):typeof m=="number"&&(Ne=i.slice(0,m)),Ne},[i,u,M,m,ve]),ke=Gt(function(){return ve?i.slice(ce+1):i.slice(pe.length)},[i,pe,ve,ce]),Ve=Yl(function(Ne,Oe){var _e;return typeof l=="function"?l(Ne):(_e=l&&(Ne==null?void 0:Ne[l]))!==null&&_e!==void 0?_e:Oe},[l]),Ee=Yl(a||function(Ne){return Ne},[a]);function yt(Ne,Oe,_e){ye===Ne&&(Oe===void 0||Oe===ae)||(be(Ne),_e||(Pe(Ne<i.length-1),E==null||E(Ne)),Oe!==void 0&&de(Oe))}function Dt(Ne,Oe){N(Oe.clientWidth)}function Pt(Ne,Oe){R(function(_e){var mt=new Map(_e);return Oe===null?mt.delete(Ne):mt.set(Ne,Oe),mt})}function Ut(Ne,Oe){z(Oe),j(B)}function Ge(Ne,Oe){U(Oe)}function Xe(Ne,Oe){re(Oe)}function qe(Ne){return I.get(Ve(pe[Ne],Ne))}mn(function(){if(D&&typeof He=="number"&&pe){var Ne=q+K,Oe=pe.length,_e=Oe-1;if(!Oe){yt(0,null);return}for(var mt=0;mt<Oe;mt+=1){var kt=qe(mt);if(S&&(kt=kt||0),kt===void 0){yt(mt-1,void 0,!0);break}if(Ne+=kt,_e===0&&Ne<=D||mt===_e-1&&Ne+qe(_e)<=D){yt(_e,null);break}else if(Ne+He>D){yt(mt-1,Ne-kt-K+B);break}}y&&qe(0)+K>D&&de(null)}},[D,I,B,q,K,Ve,pe]);var lt=se&&!!ke.length,je={};ae!==null&&ve&&(je={position:"absolute",left:ae,top:0});var Rt={prefixCls:De,responsive:ve,component:x,invalidate:xe},zt=s?function(Ne,Oe){var _e=Ve(Ne,Oe);return C.createElement(g0.Provider,{key:_e,value:Q(Q({},Rt),{},{order:Oe,item:Ne,itemKey:_e,registerSize:Pt,display:Oe<=ce})},s(Ne,Oe))}:function(Ne,Oe){var _e=Ve(Ne,Oe);return C.createElement(Ql,Qe({},Rt,{order:Oe,key:_e,item:Ne,renderItem:Ee,itemKey:_e,registerSize:Pt,display:Oe<=ce}))},dt={order:lt?ce:Number.MAX_SAFE_INTEGER,className:"".concat(De,"-rest"),registerSize:Ut,display:lt},Ct=p||fK,jt=g?C.createElement(g0.Provider,{value:Q(Q({},Rt),dt)},g(ke)):C.createElement(Ql,Qe({},Rt,dt),typeof Ct=="function"?Ct(ke):Ct),Ie=C.createElement(w,Qe({className:me(!xe&&r,h),style:f,ref:t},k),v&&C.createElement(Ql,Qe({},Rt,{responsive:ue,responsiveDisabled:!ve,order:-1,className:"".concat(De,"-prefix"),registerSize:Ge,display:!0}),v),pe.map(zt),fe?jt:null,y&&C.createElement(Ql,Qe({},Rt,{responsive:ue,responsiveDisabled:!ve,order:ce,className:"".concat(De,"-suffix"),registerSize:Xe,display:!0,style:je}),y));return ue?C.createElement(ea,{onResize:Dt,disabled:!ve},Ie):Ie}var Fc=C.forwardRef(hK);Fc.displayName="Overflow";Fc.Item=sB;Fc.RESPONSIVE=lB;Fc.INVALIDATE=cB;function pK(e,t,n){var r=Q(Q({},e),t);return Object.keys(t).forEach(function(o){var i=t[o];typeof i=="function"&&(r[o]=function(){for(var a,s=arguments.length,l=new Array(s),c=0;c<s;c++)l[c]=arguments[c];return i.apply(void 0,l),(a=e[o])===null||a===void 0?void 0:a.call.apply(a,[e].concat(l))})}),r}var gK=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],mK=function(e,t){var n=e.prefixCls,r=e.id,o=e.inputElement,i=e.autoFocus,a=e.autoComplete,s=e.editable,l=e.activeDescendantId,c=e.value,u=e.open,d=e.attrs,f=tn(e,gK),h=o||C.createElement("input",null),m=h,p=m.ref,g=m.props;return"maxLength"in h.props,h=C.cloneElement(h,Q(Q(Q({type:"search"},pK(f,g)),{},{id:r,ref:oi(t,p),autoComplete:a||"off",autoFocus:i,className:me("".concat(n,"-selection-search-input"),g==null?void 0:g.className),role:"combobox","aria-expanded":u||!1,"aria-haspopup":"listbox","aria-owns":"".concat(r,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(r,"_list"),"aria-activedescendant":u?l:void 0},d),{},{value:s?c:"",readOnly:!s,unselectable:s?null:"on",style:Q(Q({},g.style),{},{opacity:s?null:0})})),h},uB=C.forwardRef(mK);function dB(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}var vK=typeof window<"u"&&window.document&&window.document.documentElement,yK=vK;function bK(e){return e!=null}function xK(e){return!e&&e!==0}function C6(e){return["string","number"].includes(At(e))}function fB(e){var t=void 0;return e&&(C6(e.title)?t=e.title.toString():C6(e.label)&&(t=e.label.toString())),t}function EK(e,t){yK?C.useLayoutEffect(e,t):C.useEffect(e,t)}function wK(e){var t;return(t=e.key)!==null&&t!==void 0?t:e.value}var k6=function(e){e.preventDefault(),e.stopPropagation()},CK=function(e){var t=e.id,n=e.prefixCls,r=e.values,o=e.open,i=e.searchValue,a=e.autoClearSearchValue,s=e.inputRef,l=e.placeholder,c=e.disabled,u=e.mode,d=e.showSearch,f=e.autoFocus,h=e.autoComplete,m=e.activeDescendantId,p=e.tabIndex,g=e.removeIcon,v=e.maxTagCount,y=e.maxTagTextLength,b=e.maxTagPlaceholder,w=b===void 0?function(K){return"+ ".concat(K.length," ...")}:b,x=e.tagRender,E=e.onToggleOpen,k=e.onRemove,S=e.onInputChange,O=e.onInputPaste,A=e.onInputKeyDown,$=e.onInputMouseDown,M=e.onInputCompositionStart,N=e.onInputCompositionEnd,D=e.onInputBlur,T=C.useRef(null),P=nt(0),I=te(P,2),R=I[0],H=I[1],V=nt(!1),L=te(V,2),j=L[0],_=L[1],F="".concat(n,"-selection"),B=o||u==="multiple"&&a===!1||u==="tags"?i:"",z=u==="tags"||u==="multiple"&&a===!1||d&&(o||j);EK(function(){H(T.current.scrollWidth)},[B]);var G=function(K,re,oe,ne,ae){return C.createElement("span",{title:fB(K),className:me("".concat(F,"-item"),X({},"".concat(F,"-item-disabled"),oe))},C.createElement("span",{className:"".concat(F,"-item-content")},re),ne&&C.createElement(Dp,{className:"".concat(F,"-item-remove"),onMouseDown:k6,onClick:ae,customizeIcon:g},"\xD7"))},W=function(K,re,oe,ne,ae,de){var ge=function(Se){k6(Se),E(!o)};return C.createElement("span",{onMouseDown:ge},x({label:re,value:K,disabled:oe,closable:ne,onClose:ae,isMaxTag:!!de}))},q=function(K){var re=K.disabled,oe=K.label,ne=K.value,ae=!c&&!re,de=oe;if(typeof y=="number"&&(typeof oe=="string"||typeof oe=="number")){var ge=String(de);ge.length>y&&(de="".concat(ge.slice(0,y),"..."))}var Se=function(ye){ye&&ye.stopPropagation(),k(K)};return typeof x=="function"?W(ne,de,re,ae,Se):G(K,de,re,ae,Se)},U=function(K){if(!r.length)return null;var re=typeof w=="function"?w(K):w;return typeof x=="function"?W(void 0,re,!1,!1,void 0,!0):G({title:re},re,!1)},Y=C.createElement("div",{className:"".concat(F,"-search"),style:{width:R},onFocus:function(){_(!0)},onBlur:function(){_(!1)}},C.createElement(uB,{ref:s,open:o,prefixCls:n,id:t,inputElement:null,disabled:c,autoFocus:f,autoComplete:h,editable:z,activeDescendantId:m,value:B,onKeyDown:A,onMouseDown:$,onChange:S,onPaste:O,onCompositionStart:M,onCompositionEnd:N,onBlur:D,tabIndex:p,attrs:Si(e,!0)}),C.createElement("span",{ref:T,className:"".concat(F,"-search-mirror"),"aria-hidden":!0},B,"\xA0")),ie=C.createElement(Fc,{prefixCls:"".concat(F,"-overflow"),data:r,renderItem:q,renderRest:U,suffix:Y,itemKey:wK,maxCount:v});return C.createElement("span",{className:"".concat(F,"-wrap")},ie,!r.length&&!B&&C.createElement("span",{className:"".concat(F,"-placeholder")},l))},kK=function(e){var t=e.inputElement,n=e.prefixCls,r=e.id,o=e.inputRef,i=e.disabled,a=e.autoFocus,s=e.autoComplete,l=e.activeDescendantId,c=e.mode,u=e.open,d=e.values,f=e.placeholder,h=e.tabIndex,m=e.showSearch,p=e.searchValue,g=e.activeValue,v=e.maxLength,y=e.onInputKeyDown,b=e.onInputMouseDown,w=e.onInputChange,x=e.onInputPaste,E=e.onInputCompositionStart,k=e.onInputCompositionEnd,S=e.onInputBlur,O=e.title,A=C.useState(!1),$=te(A,2),M=$[0],N=$[1],D=c==="combobox",T=D||m,P=d[0],I=p||"";D&&g&&!M&&(I=g),C.useEffect(function(){D&&N(!1)},[D,g]);var R=c!=="combobox"&&!u&&!m?!1:!!I,H=O===void 0?fB(P):O,V=C.useMemo(function(){return P?null:C.createElement("span",{className:"".concat(n,"-selection-placeholder"),style:R?{visibility:"hidden"}:void 0},f)},[P,R,f,n]);return C.createElement("span",{className:"".concat(n,"-selection-wrap")},C.createElement("span",{className:"".concat(n,"-selection-search")},C.createElement(uB,{ref:o,prefixCls:n,id:r,open:u,inputElement:t,disabled:i,autoFocus:a,autoComplete:s,editable:T,activeDescendantId:l,value:I,onKeyDown:y,onMouseDown:b,onChange:function(L){N(!0),w(L)},onPaste:x,onCompositionStart:E,onCompositionEnd:k,onBlur:S,tabIndex:h,attrs:Si(e,!0),maxLength:D?v:void 0})),!D&&P?C.createElement("span",{className:"".concat(n,"-selection-item"),title:H,style:R?{visibility:"hidden"}:void 0},P.label):null,V)},SK=function(e,t){var n=et(null),r=et(!1),o=e.prefixCls,i=e.open,a=e.mode,s=e.showSearch,l=e.tokenWithEnter,c=e.disabled,u=e.prefix,d=e.autoClearSearchValue,f=e.onSearch,h=e.onSearchSubmit,m=e.onToggleOpen,p=e.onInputKeyDown,g=e.onInputBlur,v=e.domRef;C.useImperativeHandle(t,function(){return{focus:function(R){n.current.focus(R)},blur:function(){n.current.blur()}}});var y=aB(0),b=te(y,2),w=b[0],x=b[1],E=function(R){var H=R.which,V=n.current instanceof HTMLTextAreaElement;!V&&i&&(H===St.UP||H===St.DOWN)&&R.preventDefault(),p&&p(R),H===St.ENTER&&a==="tags"&&!r.current&&!i&&(h==null||h(R.target.value)),!(V&&!i&&~[St.UP,St.DOWN,St.LEFT,St.RIGHT].indexOf(H))&&nK(H)&&m(!0)},k=function(){x(!0)},S=et(null),O=function(R){f(R,!0,r.current)!==!1&&m(!0)},A=function(){r.current=!0},$=function(R){r.current=!1,a!=="combobox"&&O(R.target.value)},M=function(R){var H=R.target.value;if(l&&S.current&&/[\r\n]/.test(S.current)){var V=S.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");H=H.replace(V,S.current)}S.current=null,O(H)},N=function(R){var H=R.clipboardData,V=H==null?void 0:H.getData("text");S.current=V||""},D=function(R){var H=R.target;if(H!==n.current){var V=document.body.style.msTouchAction!==void 0;V?setTimeout(function(){n.current.focus()}):n.current.focus()}},T=function(R){var H=w();R.target!==n.current&&!H&&!(a==="combobox"&&c)&&R.preventDefault(),(a!=="combobox"&&(!s||!H)||!i)&&(i&&d!==!1&&f("",!0,!1),m())},P={inputRef:n,onInputKeyDown:E,onInputMouseDown:k,onInputChange:M,onInputPaste:N,onInputCompositionStart:A,onInputCompositionEnd:$,onInputBlur:g},I=a==="multiple"||a==="tags"?C.createElement(CK,Qe({},e,P)):C.createElement(kK,Qe({},e,P));return C.createElement("div",{ref:v,className:"".concat(o,"-selector"),onClick:D,onMouseDown:T},u&&C.createElement("div",{className:"".concat(o,"-prefix")},u),I)},AK=C.forwardRef(SK);function $K(e){var t=e.prefixCls,n=e.align,r=e.arrow,o=e.arrowPos,i=r||{},a=i.className,s=i.content,l=o.x,c=l===void 0?0:l,u=o.y,d=u===void 0?0:u,f=C.useRef();if(!n||!n.points)return null;var h={position:"absolute"};if(n.autoArrow!==!1){var m=n.points[0],p=n.points[1],g=m[0],v=m[1],y=p[0],b=p[1];g===y||!["t","b"].includes(g)?h.top=d:g==="t"?h.top=0:h.bottom=0,v===b||!["l","r"].includes(v)?h.left=c:v==="l"?h.left=0:h.right=0}return C.createElement("div",{ref:f,className:me("".concat(t,"-arrow"),a),style:h},s)}function OK(e){var t=e.prefixCls,n=e.open,r=e.zIndex,o=e.mask,i=e.motion;return o?C.createElement(fl,Qe({},i,{motionAppear:!0,visible:n,removeOnLeave:!0}),function(a){var s=a.className;return C.createElement("div",{style:{zIndex:r},className:me("".concat(t,"-mask"),s)})}):null}var MK=C.memo(function(e){var t=e.children;return t},function(e,t){return t.cache}),NK=C.forwardRef(function(e,t){var n=e.popup,r=e.className,o=e.prefixCls,i=e.style,a=e.target,s=e.onVisibleChanged,l=e.open,c=e.keepDom,u=e.fresh,d=e.onClick,f=e.mask,h=e.arrow,m=e.arrowPos,p=e.align,g=e.motion,v=e.maskMotion,y=e.forceRender,b=e.getPopupContainer,w=e.autoDestroy,x=e.portal,E=e.zIndex,k=e.onMouseEnter,S=e.onMouseLeave,O=e.onPointerEnter,A=e.onPointerDownCapture,$=e.ready,M=e.offsetX,N=e.offsetY,D=e.offsetR,T=e.offsetB,P=e.onAlign,I=e.onPrepare,R=e.stretch,H=e.targetWidth,V=e.targetHeight,L=typeof n=="function"?n():n,j=l||c,_=(b==null?void 0:b.length)>0,F=C.useState(!b||!_),B=te(F,2),z=B[0],G=B[1];if(mn(function(){!z&&_&&a&&G(!0)},[z,_,a]),!z)return null;var W="auto",q={left:"-1000vw",top:"-1000vh",right:W,bottom:W};if($||!l){var U,Y=p.points,ie=p.dynamicInset||((U=p._experimental)===null||U===void 0?void 0:U.dynamicInset),K=ie&&Y[0][1]==="r",re=ie&&Y[0][0]==="b";K?(q.right=D,q.left=W):(q.left=M,q.right=W),re?(q.bottom=T,q.top=W):(q.top=N,q.bottom=W)}var oe={};return R&&(R.includes("height")&&V?oe.height=V:R.includes("minHeight")&&V&&(oe.minHeight=V),R.includes("width")&&H?oe.width=H:R.includes("minWidth")&&H&&(oe.minWidth=H)),l||(oe.pointerEvents="none"),C.createElement(x,{open:y||j,getContainer:b&&function(){return b(a)},autoDestroy:w},C.createElement(OK,{prefixCls:o,open:l,zIndex:E,mask:f,motion:v}),C.createElement(ea,{onResize:P,disabled:!l},function(ne){return C.createElement(fl,Qe({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:y,leavedClassName:"".concat(o,"-hidden")},g,{onAppearPrepare:I,onEnterPrepare:I,visible:l,onVisibleChanged:function(ae){var de;g==null||(de=g.onVisibleChanged)===null||de===void 0||de.call(g,ae),s(ae)}}),function(ae,de){var ge=ae.className,Se=ae.style,ye=me(o,ge,r);return C.createElement("div",{ref:oi(ne,t,de),className:ye,style:Q(Q(Q(Q({"--arrow-x":"".concat(m.x||0,"px"),"--arrow-y":"".concat(m.y||0,"px")},q),oe),Se),{},{boxSizing:"border-box",zIndex:E},i),onMouseEnter:k,onMouseLeave:S,onPointerEnter:O,onClick:d,onPointerDownCapture:A},h&&C.createElement($K,{prefixCls:o,arrow:h,arrowPos:m,align:p}),C.createElement(MK,{cache:!l&&!u},L))})}))}),DK=C.forwardRef(function(e,t){var n=e.children,r=e.getTriggerDOMNode,o=Mc(n),i=C.useCallback(function(s){wC(t,r?r(s):s)},[r]),a=Ed(i,wd(n));return o?C.cloneElement(n,{ref:a}):n}),S6=C.createContext(null);function A6(e){return e?Array.isArray(e)?e:[e]:[]}function TK(e,t,n,r){return C.useMemo(function(){var o=A6(n??t),i=A6(r??t),a=new Set(o),s=new Set(i);return e&&(a.has("hover")&&(a.delete("hover"),a.add("click")),s.has("hover")&&(s.delete("hover"),s.add("click"))),[a,s]},[e,t,n,r])}function FK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0;return n?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}function PK(e,t,n,r){for(var o=n.points,i=Object.keys(e),a=0;a<i.length;a+=1){var s,l=i[a];if(FK((s=e[l])===null||s===void 0?void 0:s.points,o,r))return"".concat(t,"-placement-").concat(l)}return""}function $6(e,t,n,r){return t||(n?{motionName:"".concat(e,"-").concat(n)}:r?{motionName:r}:null)}function Md(e){return e.ownerDocument.defaultView}function j2(e){for(var t=[],n=e==null?void 0:e.parentElement,r=["hidden","scroll","clip","auto"];n;){var o=Md(n).getComputedStyle(n),i=o.overflowX,a=o.overflowY,s=o.overflow;[i,a,s].some(function(l){return r.includes(l)})&&t.push(n),n=n.parentElement}return t}function nd(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(e)?t:e}function tu(e){return nd(parseFloat(e),0)}function O6(e,t){var n=Q({},e);return(t||[]).forEach(function(r){if(!(r instanceof HTMLBodyElement||r instanceof HTMLHtmlElement)){var o=Md(r).getComputedStyle(r),i=o.overflow,a=o.overflowClipMargin,s=o.borderTopWidth,l=o.borderBottomWidth,c=o.borderLeftWidth,u=o.borderRightWidth,d=r.getBoundingClientRect(),f=r.offsetHeight,h=r.clientHeight,m=r.offsetWidth,p=r.clientWidth,g=tu(s),v=tu(l),y=tu(c),b=tu(u),w=nd(Math.round(d.width/m*1e3)/1e3),x=nd(Math.round(d.height/f*1e3)/1e3),E=(m-p-y-b)*w,k=(f-h-g-v)*x,S=g*x,O=v*x,A=y*w,$=b*w,M=0,N=0;if(i==="clip"){var D=tu(a);M=D*w,N=D*x}var T=d.x+A-M,P=d.y+S-N,I=T+d.width+2*M-A-$-E,R=P+d.height+2*N-S-O-k;n.left=Math.max(n.left,T),n.top=Math.max(n.top,P),n.right=Math.min(n.right,I),n.bottom=Math.min(n.bottom,R)}}),n}function M6(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n="".concat(t),r=n.match(/^(.*)\%$/);return r?e*(parseFloat(r[1])/100):parseFloat(n)}function N6(e,t){var n=t||[],r=te(n,2),o=r[0],i=r[1];return[M6(e.width,o),M6(e.height,i)]}function D6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return[e[0],e[1]]}function Tl(e,t){var n=t[0],r=t[1],o,i;return n==="t"?i=e.y:n==="b"?i=e.y+e.height:i=e.y+e.height/2,r==="l"?o=e.x:r==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:i}}function Ma(e,t){var n={t:"b",b:"t",l:"r",r:"l"};return e.map(function(r,o){return o===t?n[r]||"c":r}).join("")}function IK(e,t,n,r,o,i,a){var s=C.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[r]||{}}),l=te(s,2),c=l[0],u=l[1],d=C.useRef(0),f=C.useMemo(function(){return t?j2(t):[]},[t]),h=C.useRef({}),m=function(){h.current={}};e||m();var p=cn(function(){if(t&&n&&e){let gr=function(di,$a){var fi=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Te,Oa=j.x+di,ws=j.y+$a,eo=Oa+re,Di=ws+K,Qn=Math.max(Oa,fi.left),Je=Math.max(ws,fi.top),Nt=Math.min(eo,fi.right),Vt=Math.min(Di,fi.bottom);return Math.max(0,(Nt-Qn)*(Vt-Je))},ia=function(){vn=j.y+Ct,Kt=vn+K,$n=j.x+dt,On=$n+re};var y,b,w,x,E=t,k=E.ownerDocument,S=Md(E),O=S.getComputedStyle(E),A=O.position,$=E.style.left,M=E.style.top,N=E.style.right,D=E.style.bottom,T=E.style.overflow,P=Q(Q({},o[r]),i),I=k.createElement("div");(y=E.parentElement)===null||y===void 0||y.appendChild(I),I.style.left="".concat(E.offsetLeft,"px"),I.style.top="".concat(E.offsetTop,"px"),I.style.position=A,I.style.height="".concat(E.offsetHeight,"px"),I.style.width="".concat(E.offsetWidth,"px"),E.style.left="0",E.style.top="0",E.style.right="auto",E.style.bottom="auto",E.style.overflow="hidden";var R;if(Array.isArray(n))R={x:n[0],y:n[1],width:0,height:0};else{var H,V,L=n.getBoundingClientRect();L.x=(H=L.x)!==null&&H!==void 0?H:L.left,L.y=(V=L.y)!==null&&V!==void 0?V:L.top,R={x:L.x,y:L.y,width:L.width,height:L.height}}var j=E.getBoundingClientRect(),_=S.getComputedStyle(E),F=_.height,B=_.width;j.x=(b=j.x)!==null&&b!==void 0?b:j.left,j.y=(w=j.y)!==null&&w!==void 0?w:j.top;var z=k.documentElement,G=z.clientWidth,W=z.clientHeight,q=z.scrollWidth,U=z.scrollHeight,Y=z.scrollTop,ie=z.scrollLeft,K=j.height,re=j.width,oe=R.height,ne=R.width,ae={left:0,top:0,right:G,bottom:W},de={left:-ie,top:-Y,right:q-ie,bottom:U-Y},ge=P.htmlRegion,Se="visible",ye="visibleFirst";ge!=="scroll"&&ge!==ye&&(ge=Se);var be=ge===ye,ce=O6(de,f),he=O6(ae,f),Te=ge===Se?he:ce,se=be?he:Te;E.style.left="auto",E.style.top="auto",E.style.right="0",E.style.bottom="0";var Pe=E.getBoundingClientRect();E.style.left=$,E.style.top=M,E.style.right=N,E.style.bottom=D,E.style.overflow=T,(x=E.parentElement)===null||x===void 0||x.removeChild(I);var De=nd(Math.round(re/parseFloat(B)*1e3)/1e3),He=nd(Math.round(K/parseFloat(F)*1e3)/1e3);if(De===0||He===0||Gu(n)&&!wp(n))return;var ue=P.offset,ve=P.targetOffset,xe=N6(j,ue),fe=te(xe,2),pe=fe[0],ke=fe[1],Ve=N6(R,ve),Ee=te(Ve,2),yt=Ee[0],Dt=Ee[1];R.x-=yt,R.y-=Dt;var Pt=P.points||[],Ut=te(Pt,2),Ge=Ut[0],Xe=Ut[1],qe=D6(Xe),lt=D6(Ge),je=Tl(R,qe),Rt=Tl(j,lt),zt=Q({},P),dt=je.x-Rt.x+pe,Ct=je.y-Rt.y+ke,jt=gr(dt,Ct),Ie=gr(dt,Ct,he),Ne=Tl(R,["t","l"]),Oe=Tl(j,["t","l"]),_e=Tl(R,["b","r"]),mt=Tl(j,["b","r"]),kt=P.overflow||{},It=kt.adjustX,Xt=kt.adjustY,on=kt.shiftX,qt=kt.shiftY,wn=function(di){return typeof di=="boolean"?di:di>=0},vn,Kt,$n,On;ia();var ur=wn(Xt),We=lt[0]===qe[0];if(ur&<[0]==="t"&&(Kt>se.bottom||h.current.bt)){var pt=Ct;We?pt-=K-oe:pt=Ne.y-mt.y-ke;var Ke=gr(dt,pt),rt=gr(dt,pt,he);Ke>jt||Ke===jt&&(!be||rt>=Ie)?(h.current.bt=!0,Ct=pt,ke=-ke,zt.points=[Ma(lt,0),Ma(qe,0)]):h.current.bt=!1}if(ur&<[0]==="b"&&(vn<se.top||h.current.tb)){var ht=Ct;We?ht+=K-oe:ht=_e.y-Oe.y-ke;var an=gr(dt,ht),dn=gr(dt,ht,he);an>jt||an===jt&&(!be||dn>=Ie)?(h.current.tb=!0,Ct=ht,ke=-ke,zt.points=[Ma(lt,0),Ma(qe,0)]):h.current.tb=!1}var Un=wn(It),dr=lt[1]===qe[1];if(Un&<[1]==="l"&&(On>se.right||h.current.rl)){var Nn=dt;dr?Nn-=re-ne:Nn=Ne.x-mt.x-pe;var Dn=gr(Nn,Ct),wr=gr(Nn,Ct,he);Dn>jt||Dn===jt&&(!be||wr>=Ie)?(h.current.rl=!0,dt=Nn,pe=-pe,zt.points=[Ma(lt,1),Ma(qe,1)]):h.current.rl=!1}if(Un&<[1]==="r"&&($n<se.left||h.current.lr)){var ar=dt;dr?ar+=re-ne:ar=_e.x-Oe.x-pe;var J=gr(ar,Ct),Z=gr(ar,Ct,he);J>jt||J===jt&&(!be||Z>=Ie)?(h.current.lr=!0,dt=ar,pe=-pe,zt.points=[Ma(lt,1),Ma(qe,1)]):h.current.lr=!1}ia();var $e=on===!0?0:on;typeof $e=="number"&&($n<he.left&&(dt-=$n-he.left-pe,R.x+ne<he.left+$e&&(dt+=R.x-he.left+ne-$e)),On>he.right&&(dt-=On-he.right-pe,R.x>he.right-$e&&(dt+=R.x-he.right+$e)));var Ae=qt===!0?0:qt;typeof Ae=="number"&&(vn<he.top&&(Ct-=vn-he.top-ke,R.y+oe<he.top+Ae&&(Ct+=R.y-he.top+oe-Ae)),Kt>he.bottom&&(Ct-=Kt-he.bottom-ke,R.y>he.bottom-Ae&&(Ct+=R.y-he.bottom+Ae)));var tt=j.x+dt,vt=tt+re,Ot=j.y+Ct,wt=Ot+K,ot=R.x,Mt=ot+ne,Zt=R.y,Ue=Zt+oe,Ye=Math.max(tt,ot),ct=Math.min(vt,Mt),Tt=(Ye+ct)/2,Cn=Tt-tt,bt=Math.max(Ot,Zt),Wt=Math.min(wt,Ue),Fn=(bt+Wt)/2,ft=Fn-Ot;a==null||a(t,zt);var Ft=Pe.right-j.x-(dt+j.width),Bn=Pe.bottom-j.y-(Ct+j.height);De===1&&(dt=Math.round(dt),Ft=Math.round(Ft)),He===1&&(Ct=Math.round(Ct),Bn=Math.round(Bn));var zn={ready:!0,offsetX:dt/De,offsetY:Ct/He,offsetR:Ft/De,offsetB:Bn/He,arrowX:Cn/De,arrowY:ft/He,scaleX:De,scaleY:He,align:zt};u(zn)}}),g=function(){d.current+=1;var y=d.current;Promise.resolve().then(function(){d.current===y&&p()})},v=function(){u(function(y){return Q(Q({},y),{},{ready:!1})})};return mn(v,[r]),mn(function(){e||v()},[e]),[c.ready,c.offsetX,c.offsetY,c.offsetR,c.offsetB,c.arrowX,c.arrowY,c.scaleX,c.scaleY,c.align,g]}function BK(e,t,n,r,o){mn(function(){if(e&&t&&n){let d=function(){r(),o()};var i=t,a=n,s=j2(i),l=j2(a),c=Md(a),u=new Set([c].concat(ze(s),ze(l)));return u.forEach(function(f){f.addEventListener("scroll",d,{passive:!0})}),c.addEventListener("resize",d,{passive:!0}),r(),function(){u.forEach(function(f){f.removeEventListener("scroll",d),c.removeEventListener("resize",d)})}}},[e,t,n])}function RK(e,t,n,r,o,i,a,s){var l=C.useRef(e);l.current=e;var c=C.useRef(!1);C.useEffect(function(){if(t&&r&&(!o||i)){var d=function(){c.current=!1},f=function(p){var g;l.current&&!a(((g=p.composedPath)===null||g===void 0||(g=g.call(p))===null||g===void 0?void 0:g[0])||p.target)&&!c.current&&s(!1)},h=Md(r);h.addEventListener("pointerdown",d,!0),h.addEventListener("mousedown",f,!0),h.addEventListener("contextmenu",f,!0);var m=u0(n);return m&&(m.addEventListener("mousedown",f,!0),m.addEventListener("contextmenu",f,!0)),function(){h.removeEventListener("pointerdown",d,!0),h.removeEventListener("mousedown",f,!0),h.removeEventListener("contextmenu",f,!0),m&&(m.removeEventListener("mousedown",f,!0),m.removeEventListener("contextmenu",f,!0))}}},[t,n,r,o,i]);function u(){c.current=!0}return u}var _K=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function jK(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:qI,t=C.forwardRef(function(n,r){var o=n.prefixCls,i=o===void 0?"rc-trigger-popup":o,a=n.children,s=n.action,l=s===void 0?"hover":s,c=n.showAction,u=n.hideAction,d=n.popupVisible,f=n.defaultPopupVisible,h=n.onPopupVisibleChange,m=n.afterPopupVisibleChange,p=n.mouseEnterDelay,g=n.mouseLeaveDelay,v=g===void 0?.1:g,y=n.focusDelay,b=n.blurDelay,w=n.mask,x=n.maskClosable,E=x===void 0?!0:x,k=n.getPopupContainer,S=n.forceRender,O=n.autoDestroy,A=n.destroyPopupOnHide,$=n.popup,M=n.popupClassName,N=n.popupStyle,D=n.popupPlacement,T=n.builtinPlacements,P=T===void 0?{}:T,I=n.popupAlign,R=n.zIndex,H=n.stretch,V=n.getPopupClassNameFromAlign,L=n.fresh,j=n.alignPoint,_=n.onPopupClick,F=n.onPopupAlign,B=n.arrow,z=n.popupMotion,G=n.maskMotion,W=n.popupTransitionName,q=n.popupAnimation,U=n.maskTransitionName,Y=n.maskAnimation,ie=n.className,K=n.getTriggerDOMNode,re=tn(n,_K),oe=O||A||!1,ne=C.useState(!1),ae=te(ne,2),de=ae[0],ge=ae[1];mn(function(){ge(JC())},[]);var Se=C.useRef({}),ye=C.useContext(S6),be=C.useMemo(function(){return{registerSubPopup:function(Je,Nt){Se.current[Je]=Nt,ye==null||ye.registerSubPopup(Je,Nt)}}},[ye]),ce=qC(),he=C.useState(null),Te=te(he,2),se=Te[0],Pe=Te[1],De=C.useRef(null),He=cn(function(Je){De.current=Je,Gu(Je)&&se!==Je&&Pe(Je),ye==null||ye.registerSubPopup(ce,Je)}),ue=C.useState(null),ve=te(ue,2),xe=ve[0],fe=ve[1],pe=C.useRef(null),ke=cn(function(Je){Gu(Je)&&xe!==Je&&(fe(Je),pe.current=Je)}),Ve=C.Children.only(a),Ee=(Ve==null?void 0:Ve.props)||{},yt={},Dt=cn(function(Je){var Nt,Vt,Hn=xe;return(Hn==null?void 0:Hn.contains(Je))||((Nt=u0(Hn))===null||Nt===void 0?void 0:Nt.host)===Je||Je===Hn||(se==null?void 0:se.contains(Je))||((Vt=u0(se))===null||Vt===void 0?void 0:Vt.host)===Je||Je===se||Object.values(Se.current).some(function(An){return(An==null?void 0:An.contains(Je))||Je===An})}),Pt=$6(i,z,q,W),Ut=$6(i,G,Y,U),Ge=C.useState(f||!1),Xe=te(Ge,2),qe=Xe[0],lt=Xe[1],je=d??qe,Rt=cn(function(Je){d===void 0&<(Je)});mn(function(){lt(d||!1)},[d]);var zt=C.useRef(je);zt.current=je;var dt=C.useRef([]);dt.current=[];var Ct=cn(function(Je){var Nt;Rt(Je),((Nt=dt.current[dt.current.length-1])!==null&&Nt!==void 0?Nt:je)!==Je&&(dt.current.push(Je),h==null||h(Je))}),jt=C.useRef(),Ie=function(){clearTimeout(jt.current)},Ne=function(Je){var Nt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;Ie(),Nt===0?Ct(Je):jt.current=setTimeout(function(){Ct(Je)},Nt*1e3)};C.useEffect(function(){return Ie},[]);var Oe=C.useState(!1),_e=te(Oe,2),mt=_e[0],kt=_e[1];mn(function(Je){(!Je||je)&&kt(!0)},[je]);var It=C.useState(null),Xt=te(It,2),on=Xt[0],qt=Xt[1],wn=C.useState(null),vn=te(wn,2),Kt=vn[0],$n=vn[1],On=function(Je){$n([Je.clientX,Je.clientY])},ur=IK(je,se,j&&Kt!==null?Kt:xe,D,P,I,F),We=te(ur,11),pt=We[0],Ke=We[1],rt=We[2],ht=We[3],an=We[4],dn=We[5],Un=We[6],dr=We[7],Nn=We[8],Dn=We[9],wr=We[10],ar=TK(de,l,c,u),J=te(ar,2),Z=J[0],$e=J[1],Ae=Z.has("click"),tt=$e.has("click")||$e.has("contextMenu"),vt=cn(function(){mt||wr()}),Ot=function(){zt.current&&j&&tt&&Ne(!1)};BK(je,xe,se,vt,Ot),mn(function(){vt()},[Kt,D]),mn(function(){je&&!(P!=null&&P[D])&&vt()},[JSON.stringify(I)]);var wt=C.useMemo(function(){var Je=PK(P,i,Dn,j);return me(Je,V==null?void 0:V(Dn))},[Dn,V,P,i,j]);C.useImperativeHandle(r,function(){return{nativeElement:pe.current,popupElement:De.current,forceAlign:vt}});var ot=C.useState(0),Mt=te(ot,2),Zt=Mt[0],Ue=Mt[1],Ye=C.useState(0),ct=te(Ye,2),Tt=ct[0],Cn=ct[1],bt=function(){if(H&&xe){var Je=xe.getBoundingClientRect();Ue(Je.width),Cn(Je.height)}},Wt=function(){bt(),vt()},Fn=function(Je){kt(!1),wr(),m==null||m(Je)},ft=function(){return new Promise(function(Je){bt(),qt(function(){return Je})})};mn(function(){on&&(wr(),on(),qt(null))},[on]);function Ft(Je,Nt,Vt,Hn){yt[Je]=function(An){var Ti;Hn==null||Hn(An),Ne(Nt,Vt);for(var Zc=arguments.length,IS=new Array(Zc>1?Zc-1:0),Ud=1;Ud<Zc;Ud++)IS[Ud-1]=arguments[Ud];(Ti=Ee[Je])===null||Ti===void 0||Ti.call.apply(Ti,[Ee,An].concat(IS))}}(Ae||tt)&&(yt.onClick=function(Je){var Nt;zt.current&&tt?Ne(!1):!zt.current&&Ae&&(On(Je),Ne(!0));for(var Vt=arguments.length,Hn=new Array(Vt>1?Vt-1:0),An=1;An<Vt;An++)Hn[An-1]=arguments[An];(Nt=Ee.onClick)===null||Nt===void 0||Nt.call.apply(Nt,[Ee,Je].concat(Hn))});var Bn=RK(je,tt,xe,se,w,E,Dt,Ne),zn=Z.has("hover"),gr=$e.has("hover"),ia,di;zn&&(Ft("onMouseEnter",!0,p,function(Je){On(Je)}),Ft("onPointerEnter",!0,p,function(Je){On(Je)}),ia=function(Je){(je||mt)&&se!==null&&se!==void 0&&se.contains(Je.target)&&Ne(!0,p)},j&&(yt.onMouseMove=function(Je){var Nt;(Nt=Ee.onMouseMove)===null||Nt===void 0||Nt.call(Ee,Je)})),gr&&(Ft("onMouseLeave",!1,v),Ft("onPointerLeave",!1,v),di=function(){Ne(!1,v)}),Z.has("focus")&&Ft("onFocus",!0,y),$e.has("focus")&&Ft("onBlur",!1,b),Z.has("contextMenu")&&(yt.onContextMenu=function(Je){var Nt;zt.current&&$e.has("contextMenu")?Ne(!1):(On(Je),Ne(!0)),Je.preventDefault();for(var Vt=arguments.length,Hn=new Array(Vt>1?Vt-1:0),An=1;An<Vt;An++)Hn[An-1]=arguments[An];(Nt=Ee.onContextMenu)===null||Nt===void 0||Nt.call.apply(Nt,[Ee,Je].concat(Hn))}),ie&&(yt.className=me(Ee.className,ie));var $a=C.useRef(!1);$a.current||($a.current=S||je||mt);var fi=Q(Q({},Ee),yt),Oa={},ws=["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"];ws.forEach(function(Je){re[Je]&&(Oa[Je]=function(){for(var Nt,Vt=arguments.length,Hn=new Array(Vt),An=0;An<Vt;An++)Hn[An]=arguments[An];(Nt=fi[Je])===null||Nt===void 0||Nt.call.apply(Nt,[fi].concat(Hn)),re[Je].apply(re,Hn)})});var eo=C.cloneElement(Ve,Q(Q({},fi),Oa)),Di={x:dn,y:Un},Qn=B?Q({},B!==!0?B:{}):null;return C.createElement(C.Fragment,null,C.createElement(ea,{disabled:!je,ref:ke,onResize:Wt},C.createElement(DK,{getTriggerDOMNode:K},eo)),$a.current&&C.createElement(S6.Provider,{value:be},C.createElement(NK,{portal:e,ref:He,prefixCls:i,popup:$,className:me(M,wt),style:N,target:xe,onMouseEnter:ia,onMouseLeave:di,onPointerEnter:ia,zIndex:R,open:je,keepDom:mt,fresh:L,onClick:_,onPointerDownCapture:Bn,mask:w,motion:Pt,maskMotion:Ut,onVisibleChanged:Fn,onPrepare:ft,forceRender:S,autoDestroy:oe,getPopupContainer:k,align:Dn,arrow:Qn,arrowPos:Di,ready:pt,offsetX:Ke,offsetY:rt,offsetR:ht,offsetB:an,onAlign:vt,stretch:H,targetWidth:Zt/dr,targetHeight:Tt/Nn})))});return t}const ek=jK(qI);var LK=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],zK=function(e){var 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"}}},HK=function(e,t){var n=e.prefixCls,r=e.visible,o=e.children,i=e.popupElement,a=e.animation,s=e.transitionName,l=e.dropdownStyle,c=e.dropdownClassName,u=e.direction,d=u===void 0?"ltr":u,f=e.placement,h=e.builtinPlacements,m=e.dropdownMatchSelectWidth,p=e.dropdownRender,g=e.dropdownAlign,v=e.getPopupContainer,y=e.empty,b=e.getTriggerDOMNode,w=e.onPopupVisibleChange,x=e.onPopupMouseEnter,E=tn(e,LK),k="".concat(n,"-dropdown"),S=i;p&&(S=p(i));var O=C.useMemo(function(){return h||zK(m)},[h,m]),A=a?"".concat(k,"-").concat(a):s,$=typeof m=="number",M=C.useMemo(function(){return $?null:m===!1?"minWidth":"width"},[m,$]),N=l;$&&(N=Q(Q({},N),{},{width:m}));var D=C.useRef(null);return C.useImperativeHandle(t,function(){return{getPopupElement:function(){var T;return(T=D.current)===null||T===void 0?void 0:T.popupElement}}}),C.createElement(ek,Qe({},E,{showAction:w?["click"]:[],hideAction:w?["click"]:[],popupPlacement:f||(d==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:O,prefixCls:k,popupTransitionName:A,popup:C.createElement("div",{onMouseEnter:x},S),ref:D,stretch:M,popupAlign:g,popupVisible:r,getPopupContainer:v,popupClassName:me(c,X({},"".concat(k,"-empty"),y)),popupStyle:N,getTriggerDOMNode:b,onPopupVisibleChange:w}),o)},WK=C.forwardRef(HK);function T6(e,t){var n=e.key,r;return"value"in e&&(r=e.value),n??(r!==void 0?r:"rc-index-key-".concat(t))}function L2(e){return typeof e<"u"&&!Number.isNaN(e)}function hB(e,t){var n=e||{},r=n.label,o=n.value,i=n.options,a=n.groupLabel,s=r||(t?"children":"label");return{label:s,value:o||"value",options:i||"options",groupLabel:a||s}}function VK(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.fieldNames,r=t.childrenAsData,o=[],i=hB(n,!1),a=i.label,s=i.value,l=i.options,c=i.groupLabel;function u(d,f){Array.isArray(d)&&d.forEach(function(h){if(f||!(l in h)){var m=h[s];o.push({key:T6(h,o.length),groupOption:f,data:h,label:h[a],value:m})}else{var p=h[c];p===void 0&&r&&(p=h.label),o.push({key:T6(h,o.length),group:!0,data:h,label:p}),u(h[l],!0)}})}return u(e,!1),o}function z2(e){var t=Q({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return qr(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}var GK=function(e,t,n){if(!t||!t.length)return null;var r=!1,o=function a(s,l){var c=HP(l),u=c[0],d=c.slice(1);if(!u)return[s];var f=s.split(u);return r=r||f.length>1,f.reduce(function(h,m){return[].concat(ze(h),ze(a(m,d)))},[]).filter(Boolean)},i=o(e,t);return r?typeof n<"u"?i.slice(0,n):i:null},tk=C.createContext(null);function UK(e){var t=e.visible,n=e.values;if(!t)return null;var r=50;return C.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(n.slice(0,r).map(function(o){var i=o.label,a=o.value;return["number","string"].includes(At(i))?i:a}).join(", ")),n.length>r?", ...":null)}var qK=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],YK=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],H2=function(e){return e==="tags"||e==="multiple"},XK=C.forwardRef(function(e,t){var n,r=e.id,o=e.prefixCls,i=e.className,a=e.showSearch,s=e.tagRender,l=e.direction,c=e.omitDomProps,u=e.displayValues,d=e.onDisplayValuesChange,f=e.emptyOptions,h=e.notFoundContent,m=h===void 0?"Not Found":h,p=e.onClear,g=e.mode,v=e.disabled,y=e.loading,b=e.getInputElement,w=e.getRawInputElement,x=e.open,E=e.defaultOpen,k=e.onDropdownVisibleChange,S=e.activeValue,O=e.onActiveValueChange,A=e.activeDescendantId,$=e.searchValue,M=e.autoClearSearchValue,N=e.onSearch,D=e.onSearchSplit,T=e.tokenSeparators,P=e.allowClear,I=e.prefix,R=e.suffixIcon,H=e.clearIcon,V=e.OptionList,L=e.animation,j=e.transitionName,_=e.dropdownStyle,F=e.dropdownClassName,B=e.dropdownMatchSelectWidth,z=e.dropdownRender,G=e.dropdownAlign,W=e.placement,q=e.builtinPlacements,U=e.getPopupContainer,Y=e.showAction,ie=Y===void 0?[]:Y,K=e.onFocus,re=e.onBlur,oe=e.onKeyUp,ne=e.onKeyDown,ae=e.onMouseDown,de=tn(e,qK),ge=H2(g),Se=(a!==void 0?a:ge)||g==="combobox",ye=Q({},de);YK.forEach(function(ot){delete ye[ot]}),c==null||c.forEach(function(ot){delete ye[ot]});var be=C.useState(!1),ce=te(be,2),he=ce[0],Te=ce[1];C.useEffect(function(){Te(JC())},[]);var se=C.useRef(null),Pe=C.useRef(null),De=C.useRef(null),He=C.useRef(null),ue=C.useRef(null),ve=C.useRef(!1),xe=eK(),fe=te(xe,3),pe=fe[0],ke=fe[1],Ve=fe[2];C.useImperativeHandle(t,function(){var ot,Mt;return{focus:(ot=He.current)===null||ot===void 0?void 0:ot.focus,blur:(Mt=He.current)===null||Mt===void 0?void 0:Mt.blur,scrollTo:function(Zt){var Ue;return(Ue=ue.current)===null||Ue===void 0?void 0:Ue.scrollTo(Zt)},nativeElement:se.current||Pe.current}});var Ee=C.useMemo(function(){var ot;if(g!=="combobox")return $;var Mt=(ot=u[0])===null||ot===void 0?void 0:ot.value;return typeof Mt=="string"||typeof Mt=="number"?String(Mt):""},[$,g,u]),yt=g==="combobox"&&typeof b=="function"&&b()||null,Dt=typeof w=="function"&&w(),Pt=Ed(Pe,Dt==null||(n=Dt.props)===null||n===void 0?void 0:n.ref),Ut=C.useState(!1),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1];mn(function(){qe(!0)},[]);var lt=yr(!1,{defaultValue:E,value:x}),je=te(lt,2),Rt=je[0],zt=je[1],dt=Xe?Rt:!1,Ct=!m&&f;(v||Ct&&dt&&g==="combobox")&&(dt=!1);var jt=Ct?!1:dt,Ie=C.useCallback(function(ot){var Mt=ot!==void 0?ot:!dt;v||(zt(Mt),dt!==Mt&&(k==null||k(Mt)))},[v,dt,zt,k]),Ne=C.useMemo(function(){return(T||[]).some(function(ot){return[`
|
|
286
286
|
`,`\r
|
|
287
|
-
`].includes(ot)})},[T]),Oe=C.useContext(tk)||{},_e=Oe.maxCount,mt=Oe.rawValues,kt=function(ot,Mt,Zt){if(!(ge&&L2(_e)&&(mt==null?void 0:mt.size)>=_e)){var Ue=!0,Ye=ot;O==null||O(null);var ct=GK(ot,T,L2(_e)?_e-mt.size:void 0),It=Zt?null:ct;return g!=="combobox"&&It&&(Ye="",D==null||D(It),Ie(!1),Ue=!1),N&&Ee!==Ye&&N(Ye,{source:Mt?"typing":"effect"}),Ue}},Pt=function(ot){!ot||!ot.trim()||N(ot,{source:"submit"})};C.useEffect(function(){!dt&&!ge&&g!=="combobox"&&kt("",!1,!1)},[dt]),C.useEffect(function(){Rt&&v&&zt(!1),v&&!ve.current&&ke(!1)},[v]);var Xt=aB(),on=te(Xt,2),qt=on[0],wn=on[1],vn=C.useRef(!1),Kt=function(ot){var Mt=qt(),Zt=ot.key,Ue=Zt==="Enter";if(Ue&&(g!=="combobox"&&ot.preventDefault(),dt||Ie(!0)),wn(!!Ee),Zt==="Backspace"&&!Mt&&ge&&!Ee&&u.length){for(var Ye=ze(u),ct=null,It=Ye.length-1;It>=0;It-=1){var Cn=Ye[It];if(!Cn.disabled){Ye.splice(It,1),ct=Cn;break}}ct&&d(Ye,{type:"remove",values:[ct]})}for(var bt=arguments.length,Wt=new Array(bt>1?bt-1:0),Fn=1;Fn<bt;Fn++)Wt[Fn-1]=arguments[Fn];if(dt&&(!Ue||!vn.current)){var ft;Ue&&(vn.current=!0),(ft=ue.current)===null||ft===void 0||ft.onKeyDown.apply(ft,[ot].concat(Wt))}ne==null||ne.apply(void 0,[ot].concat(Wt))},$n=function(ot){for(var Mt=arguments.length,Zt=new Array(Mt>1?Mt-1:0),Ue=1;Ue<Mt;Ue++)Zt[Ue-1]=arguments[Ue];if(dt){var Ye;(Ye=ue.current)===null||Ye===void 0||Ye.onKeyUp.apply(Ye,[ot].concat(Zt))}ot.key==="Enter"&&(vn.current=!1),oe==null||oe.apply(void 0,[ot].concat(Zt))},On=function(ot){var Mt=u.filter(function(Zt){return Zt!==ot});d(Mt,{type:"remove",values:[ot]})},ur=function(){vn.current=!1},We=C.useRef(!1),pt=function(){ke(!0),v||(K&&!We.current&&K.apply(void 0,arguments),ie.includes("focus")&&Ie(!0)),We.current=!0},Ke=function(){ve.current=!0,ke(!1,function(){We.current=!1,ve.current=!1,Ie(!1)}),!v&&(Ee&&(g==="tags"?N(Ee,{source:"submit"}):g==="multiple"&&N("",{source:"blur"})),re&&re.apply(void 0,arguments))},rt=[];C.useEffect(function(){return function(){rt.forEach(function(ot){return clearTimeout(ot)}),rt.splice(0,rt.length)}},[]);var ht=function(ot){var Mt,Zt=ot.target,Ue=(Mt=De.current)===null||Mt===void 0?void 0:Mt.getPopupElement();if(Ue&&Ue.contains(Zt)){var Ye=setTimeout(function(){var bt=rt.indexOf(Ye);if(bt!==-1&&rt.splice(bt,1),Ve(),!he&&!Ue.contains(document.activeElement)){var Wt;(Wt=He.current)===null||Wt===void 0||Wt.focus()}});rt.push(Ye)}for(var ct=arguments.length,It=new Array(ct>1?ct-1:0),Cn=1;Cn<ct;Cn++)It[Cn-1]=arguments[Cn];ae==null||ae.apply(void 0,[ot].concat(It))},an=C.useState({}),dn=te(an,2),Un=dn[1];function dr(){Un({})}var Nn;Dt&&(Nn=function(ot){Ie(ot)}),tK(function(){var ot;return[se.current,(ot=De.current)===null||ot===void 0?void 0:ot.getPopupElement()]},jt,Ie,!!Dt);var Dn=C.useMemo(function(){return Q(Q({},e),{},{notFoundContent:m,open:dt,triggerOpen:jt,id:r,showSearch:Se,multiple:ge,toggleOpen:Ie})},[e,m,jt,dt,r,Se,ge,Ie]),wr=!!R||y,ar;wr&&(ar=C.createElement(Dp,{className:me("".concat(o,"-arrow"),X({},"".concat(o,"-arrow-loading"),y)),customizeIcon:R,customizeIconProps:{loading:y,searchValue:Ee,open:dt,focused:pe,showSearch:Se}}));var J=function(){var ot;p==null||p(),(ot=He.current)===null||ot===void 0||ot.focus(),d([],{type:"clear",values:u}),kt("",!1,!1)},Z=QX(o,J,u,P,H,v,Ee,g),$e=Z.allowClear,Ae=Z.clearIcon,tt=C.createElement(V,{ref:ue}),vt=me(o,i,X(X(X(X(X(X(X(X(X(X({},"".concat(o,"-focused"),pe),"".concat(o,"-multiple"),ge),"".concat(o,"-single"),!ge),"".concat(o,"-allow-clear"),P),"".concat(o,"-show-arrow"),wr),"".concat(o,"-disabled"),v),"".concat(o,"-loading"),y),"".concat(o,"-open"),dt),"".concat(o,"-customize-input"),yt),"".concat(o,"-show-search"),Se)),Ot=C.createElement(WK,{ref:De,disabled:v,prefixCls:o,visible:jt,popupElement:tt,animation:L,transitionName:j,dropdownStyle:_,dropdownClassName:F,direction:l,dropdownMatchSelectWidth:B,dropdownRender:z,dropdownAlign:G,placement:W,builtinPlacements:q,getPopupContainer:U,empty:f,getTriggerDOMNode:function(ot){return Pe.current||ot},onPopupVisibleChange:Nn,onPopupMouseEnter:dr},Dt?C.cloneElement(Dt,{ref:Ft}):C.createElement(AK,Qe({},e,{domRef:Pe,prefixCls:o,inputElement:yt,ref:He,id:r,prefix:I,showSearch:Se,autoClearSearchValue:M,mode:g,activeDescendantId:A,tagRender:s,values:u,open:dt,onToggleOpen:Ie,activeValue:S,searchValue:Ee,onSearch:kt,onSearchSubmit:Pt,onRemove:On,tokenWithEnter:Ne,onInputBlur:ur}))),wt;return Dt?wt=Ot:wt=C.createElement("div",Qe({className:vt},ye,{ref:se,onMouseDown:ht,onKeyDown:Kt,onKeyUp:$n,onFocus:pt,onBlur:Ke}),C.createElement(UK,{visible:pe&&!dt,values:u}),Ot,ar,$e&&Ae),C.createElement(iB.Provider,{value:Dn},wt)}),nk=function(){return null};nk.isSelectOptGroup=!0;var rk=function(){return null};rk.isSelectOption=!0;var pB=C.forwardRef(function(e,t){var n=e.height,r=e.offsetY,o=e.offsetX,i=e.children,a=e.prefixCls,s=e.onInnerResize,l=e.innerProps,c=e.rtl,u=e.extra,d={},f={display:"flex",flexDirection:"column"};return r!==void 0&&(d={height:n,position:"relative",overflow:"hidden"},f=Q(Q({},f),{},X(X(X(X(X({transform:"translateY(".concat(r,"px)")},c?"marginRight":"marginLeft",-o),"position","absolute"),"left",0),"right",0),"top",0))),C.createElement("div",{style:d},C.createElement(ea,{onResize:function(h){var m=h.offsetHeight;m&&s&&s()}},C.createElement("div",Qe({style:f,className:me(X({},"".concat(a,"-holder-inner"),a)),ref:t},l),i,u)))});pB.displayName="Filler";function KK(e){var t=e.children,n=e.setRef,r=C.useCallback(function(o){n(o)},[]);return C.cloneElement(t,{ref:r})}function ZK(e,t,n,r,o,i,a,s){var l=s.getKey;return e.slice(t,n+1).map(function(c,u){var d=t+u,f=a(c,d,{style:{width:r},offsetX:o}),h=l(c);return C.createElement(KK,{key:h,setRef:function(m){return i(c,m)}},f)})}function QK(e,t,n){var r=e.length,o=t.length,i,a;if(r===0&&o===0)return null;r<o?(i=e,a=t):(i=t,a=e);var s={__EMPTY_ITEM__:!0};function l(m){return m!==void 0?n(m):s}for(var c=null,u=Math.abs(r-o)!==1,d=0;d<a.length;d+=1){var f=l(i[d]),h=l(a[d]);if(f!==h){c=d,u=u||f!==l(a[d+1]);break}}return c===null?null:{index:c,multiple:u}}function JK(e,t,n){var r=C.useState(e),o=te(r,2),i=o[0],a=o[1],s=C.useState(null),l=te(s,2),c=l[0],u=l[1];return C.useEffect(function(){var d=QK(i||[],e||[],t);(d==null?void 0:d.index)!==void 0&&u(e[d.index]),a(e)},[e]),[c]}var F6=(typeof navigator>"u"?"undefined":At(navigator))==="object"&&/Firefox/i.test(navigator.userAgent);const gB=(function(e,t,n,r){var o=et(!1),i=et(null);function a(){clearTimeout(i.current),o.current=!0,i.current=setTimeout(function(){o.current=!1},50)}var s=et({top:e,bottom:t,left:n,right:r});return s.current.top=e,s.current.bottom=t,s.current.left=n,s.current.right=r,function(l,c){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,d=l?c<0&&s.current.left||c>0&&s.current.right:c<0&&s.current.top||c>0&&s.current.bottom;return u&&d?(clearTimeout(i.current),o.current=!1):(!d||o.current)&&a(),!o.current&&d}});function eZ(e,t,n,r,o,i,a){var s=et(0),l=et(null),c=et(null),u=et(!1),d=gB(t,n,r,o);function f(y,b){if(en.cancel(l.current),!d(!1,b)){var w=y;if(!w._virtualHandled)w._virtualHandled=!0;else return;s.current+=b,c.current=b,F6||w.preventDefault(),l.current=en(function(){var x=u.current?10:1;a(s.current*x,!1),s.current=0})}}function h(y,b){a(b,!0),F6||y.preventDefault()}var m=et(null),p=et(null);function g(y){if(e){en.cancel(p.current),p.current=en(function(){m.current=null},2);var b=y.deltaX,w=y.deltaY,x=y.shiftKey,E=b,k=w;(m.current==="sx"||!m.current&&x&&w&&!b)&&(E=w,k=0,m.current="sx");var S=Math.abs(E),O=Math.abs(k);m.current===null&&(m.current=i&&S>O?"x":"y"),m.current==="y"?f(y,k):h(y,E)}}function v(y){e&&(u.current=y.detail===c.current)}return[g,v]}function tZ(e,t,n,r){var o=C.useMemo(function(){return[new Map,[]]},[e,n.id,r]),i=te(o,2),a=i[0],s=i[1],l=function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:c,d=a.get(c),f=a.get(u);if(d===void 0||f===void 0)for(var h=e.length,m=s.length;m<h;m+=1){var p,g=e[m],v=t(g);a.set(v,m);var y=(p=n.get(v))!==null&&p!==void 0?p:r;if(s[m]=(s[m-1]||0)+y,v===c&&(d=m),v===u&&(f=m),d!==void 0&&f!==void 0)break}return{top:s[d-1]||0,bottom:s[f]}};return l}var nZ=(function(){function e(){xr(this,e),X(this,"maps",void 0),X(this,"id",0),X(this,"diffRecords",new Map),this.maps=Object.create(null)}return Er(e,[{key:"set",value:function(t,n){this.diffRecords.set(t,this.maps[t]),this.maps[t]=n,this.id+=1}},{key:"get",value:function(t){return this.maps[t]}},{key:"resetRecord",value:function(){this.diffRecords.clear()}},{key:"getRecord",value:function(){return this.diffRecords}}]),e})();function P6(e){var t=parseFloat(e);return isNaN(t)?0:t}function rZ(e,t,n){var r=C.useState(0),o=te(r,2),i=o[0],a=o[1],s=et(new Map),l=et(new nZ),c=et(0);function u(){c.current+=1}function d(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;u();var m=function(){var g=!1;s.current.forEach(function(v,y){if(v&&v.offsetParent){var b=v.offsetHeight,w=getComputedStyle(v),x=w.marginTop,E=w.marginBottom,k=P6(x),S=P6(E),O=b+k+S;l.current.get(y)!==O&&(l.current.set(y,O),g=!0)}}),g&&a(function(v){return v+1})};if(h)m();else{c.current+=1;var p=c.current;Promise.resolve().then(function(){p===c.current&&m()})}}function f(h,m){var p=e(h);s.current.get(p),m?(s.current.set(p,m),d()):s.current.delete(p)}return Et(function(){return u},[]),[f,d,l.current,i]}var I6=14/15;function oZ(e,t,n){var r=et(!1),o=et(0),i=et(0),a=et(null),s=et(null),l,c=function(f){if(r.current){var h=Math.ceil(f.touches[0].pageX),m=Math.ceil(f.touches[0].pageY),p=o.current-h,g=i.current-m,v=Math.abs(p)>Math.abs(g);v?o.current=h:i.current=m;var y=n(v,v?p:g,!1,f);y&&f.preventDefault(),clearInterval(s.current),y&&(s.current=setInterval(function(){v?p*=I6:g*=I6;var b=Math.floor(v?p:g);(!n(v,b,!0)||Math.abs(b)<=.1)&&clearInterval(s.current)},16))}},u=function(){r.current=!1,l()},d=function(f){l(),f.touches.length===1&&!r.current&&(r.current=!0,o.current=Math.ceil(f.touches[0].pageX),i.current=Math.ceil(f.touches[0].pageY),a.current=f.target,a.current.addEventListener("touchmove",c,{passive:!1}),a.current.addEventListener("touchend",u,{passive:!0}))};l=function(){a.current&&(a.current.removeEventListener("touchmove",c),a.current.removeEventListener("touchend",u))},mn(function(){return e&&t.current.addEventListener("touchstart",d,{passive:!0}),function(){var f;(f=t.current)===null||f===void 0||f.removeEventListener("touchstart",d),l(),clearInterval(s.current)}},[e])}function B6(e){return Math.floor(Math.pow(e,.5))}function W2(e,t){var n="touches"in e?e.touches[0]:e;return n[t?"pageX":"pageY"]-window[t?"scrollX":"scrollY"]}function iZ(e,t,n){C.useEffect(function(){var r=t.current;if(e&&r){var o=!1,i,a,s=function(){en.cancel(i)},l=function f(){s(),i=en(function(){n(a),f()})},c=function(){o=!1,s()},u=function(f){if(!(f.target.draggable||f.button!==0)){var h=f;h._virtualHandled||(h._virtualHandled=!0,o=!0)}},d=function(f){if(o){var h=W2(f,!1),m=r.getBoundingClientRect(),p=m.top,g=m.bottom;if(h<=p){var v=p-h;a=-B6(v),l()}else if(h>=g){var y=h-g;a=B6(y),l()}else s()}};return r.addEventListener("mousedown",u),r.ownerDocument.addEventListener("mouseup",c),r.ownerDocument.addEventListener("mousemove",d),r.ownerDocument.addEventListener("dragend",c),function(){r.removeEventListener("mousedown",u),r.ownerDocument.removeEventListener("mouseup",c),r.ownerDocument.removeEventListener("mousemove",d),r.ownerDocument.removeEventListener("dragend",c),s()}}},[e])}var aZ=10;function sZ(e,t,n,r,o,i,a,s){var l=C.useRef(),c=C.useState(null),u=te(c,2),d=u[0],f=u[1];return mn(function(){if(d&&d.times<aZ){if(!e.current){f(function(H){return Q({},H)});return}i();var h=d.targetAlign,m=d.originAlign,p=d.index,g=d.offset,v=e.current.clientHeight,y=!1,b=h,w=null;if(v){for(var x=h||m,E=0,k=0,S=0,O=Math.min(t.length-1,p),A=0;A<=O;A+=1){var $=o(t[A]);k=E;var M=n.get($);S=k+(M===void 0?r:M),E=S}for(var N=x==="top"?g:v-g,D=O;D>=0;D-=1){var T=o(t[D]),P=n.get(T);if(P===void 0){y=!0;break}if(N-=P,N<=0)break}switch(x){case"top":w=k-g;break;case"bottom":w=S-v+g;break;default:{var I=e.current.scrollTop,R=I+v;k<I?b="top":S>R&&(b="bottom")}}w!==null&&a(w),w!==d.lastTop&&(y=!0)}y&&f(Q(Q({},d),{},{times:d.times+1,targetAlign:b,lastTop:w}))}},[d,e.current]),function(h){if(h==null){s();return}if(en.cancel(l.current),typeof h=="number")a(h);else if(h&&At(h)==="object"){var m,p=h.align;"index"in h?m=h.index:m=t.findIndex(function(y){return o(y)===h.key});var g=h.offset,v=g===void 0?0:g;f({times:0,index:m,offset:v,originAlign:p})}}}var R6=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.rtl,o=e.scrollOffset,i=e.scrollRange,a=e.onStartMove,s=e.onStopMove,l=e.onScroll,c=e.horizontal,u=e.spinSize,d=e.containerSize,f=e.style,h=e.thumbStyle,m=e.showScrollBar,p=C.useState(!1),g=te(p,2),v=g[0],y=g[1],b=C.useState(null),w=te(b,2),x=w[0],E=w[1],k=C.useState(null),S=te(k,2),O=S[0],A=S[1],$=!r,M=C.useRef(),N=C.useRef(),D=C.useState(m),T=te(D,2),P=T[0],I=T[1],R=C.useRef(),H=function(){m===!0||m===!1||(clearTimeout(R.current),I(!0),R.current=setTimeout(function(){I(!1)},3e3))},V=i-d||0,L=d-u||0,j=C.useMemo(function(){if(o===0||V===0)return 0;var Y=o/V;return Y*L},[o,V,L]),_=function(Y){Y.stopPropagation(),Y.preventDefault()},F=C.useRef({top:j,dragging:v,pageY:x,startTop:O});F.current={top:j,dragging:v,pageY:x,startTop:O};var B=function(Y){y(!0),E(W2(Y,c)),A(F.current.top),a(),Y.stopPropagation(),Y.preventDefault()};C.useEffect(function(){var Y=function(re){re.preventDefault()},ie=M.current,K=N.current;return ie.addEventListener("touchstart",Y,{passive:!1}),K.addEventListener("touchstart",B,{passive:!1}),function(){ie.removeEventListener("touchstart",Y),K.removeEventListener("touchstart",B)}},[]);var z=C.useRef();z.current=V;var G=C.useRef();G.current=L,C.useEffect(function(){if(v){var Y,ie=function(re){var oe=F.current,ne=oe.dragging,ae=oe.pageY,de=oe.startTop;en.cancel(Y);var ge=M.current.getBoundingClientRect(),Se=d/(c?ge.width:ge.height);if(ne){var ye=(W2(re,c)-ae)*Se,be=de;!$&&c?be-=ye:be+=ye;var ce=z.current,he=G.current,Te=he?be/he:0,se=Math.ceil(Te*ce);se=Math.max(se,0),se=Math.min(se,ce),Y=en(function(){l(se,c)})}},K=function(){y(!1),s()};return window.addEventListener("mousemove",ie,{passive:!0}),window.addEventListener("touchmove",ie,{passive:!0}),window.addEventListener("mouseup",K,{passive:!0}),window.addEventListener("touchend",K,{passive:!0}),function(){window.removeEventListener("mousemove",ie),window.removeEventListener("touchmove",ie),window.removeEventListener("mouseup",K),window.removeEventListener("touchend",K),en.cancel(Y)}}},[v]),C.useEffect(function(){return H(),function(){clearTimeout(R.current)}},[o]),C.useImperativeHandle(t,function(){return{delayHidden:H}});var W="".concat(n,"-scrollbar"),q={position:"absolute",visibility:P?null:"hidden"},U={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(q,{height:8,left:0,right:0,bottom:0}),Object.assign(U,X({height:"100%",width:u},$?"left":"right",j))):(Object.assign(q,X({width:8,top:0,bottom:0},$?"right":"left",0)),Object.assign(U,{width:"100%",height:u,top:j})),C.createElement("div",{ref:M,className:me(W,X(X(X({},"".concat(W,"-horizontal"),c),"".concat(W,"-vertical"),!c),"".concat(W,"-visible"),P)),style:Q(Q({},q),f),onMouseDown:_,onMouseMove:H},C.createElement("div",{ref:N,className:me("".concat(W,"-thumb"),X({},"".concat(W,"-thumb-moving"),v)),style:Q(Q({},U),h),onMouseDown:B}))}),lZ=20;function _6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=e/t*e;return isNaN(n)&&(n=0),n=Math.max(n,lZ),Math.floor(n)}var cZ=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],uZ=[],dZ={overflowY:"auto",overflowAnchor:"none"};function fZ(e,t){var n=e.prefixCls,r=n===void 0?"rc-virtual-list":n,o=e.className,i=e.height,a=e.itemHeight,s=e.fullHeight,l=s===void 0?!0:s,c=e.style,u=e.data,d=e.children,f=e.itemKey,h=e.virtual,m=e.direction,p=e.scrollWidth,g=e.component,v=g===void 0?"div":g,y=e.onScroll,b=e.onVirtualScroll,w=e.onVisibleChange,x=e.innerProps,E=e.extraRender,k=e.styles,S=e.showScrollBar,O=S===void 0?"optional":S,A=tn(e,cZ),$=C.useCallback(function(We){return typeof f=="function"?f(We):We==null?void 0:We[f]},[f]),M=rZ($),N=te(M,4),D=N[0],T=N[1],P=N[2],I=N[3],R=!!(h!==!1&&i&&a),H=C.useMemo(function(){return Object.values(P.maps).reduce(function(We,pt){return We+pt},0)},[P.id,P.maps]),V=R&&u&&(Math.max(a*u.length,H)>i||!!p),L=m==="rtl",j=me(r,X({},"".concat(r,"-rtl"),L),o),_=u||uZ,F=et(),B=et(),z=et(),G=nt(0),W=te(G,2),q=W[0],U=W[1],Y=nt(0),ie=te(Y,2),K=ie[0],re=ie[1],oe=nt(!1),ne=te(oe,2),ae=ne[0],de=ne[1],ge=function(){de(!0)},Se=function(){de(!1)},ye={getKey:$};function be(We){U(function(pt){var Ke;typeof We=="function"?Ke=We(pt):Ke=We;var rt=qe(Ke);return F.current.scrollTop=rt,rt})}var ce=et({start:0,end:_.length}),he=et(),Te=JK(_,$),se=te(Te,1),Pe=se[0];he.current=Pe;var De=C.useMemo(function(){if(!R)return{scrollHeight:void 0,start:0,end:_.length-1,offset:void 0};if(!V){var We;return{scrollHeight:((We=B.current)===null||We===void 0?void 0:We.offsetHeight)||0,start:0,end:_.length-1,offset:void 0}}for(var pt=0,Ke,rt,ht,an=_.length,dn=0;dn<an;dn+=1){var Un=_[dn],dr=$(Un),Nn=P.get(dr),Dn=pt+(Nn===void 0?a:Nn);Dn>=q&&Ke===void 0&&(Ke=dn,rt=pt),Dn>q+i&&ht===void 0&&(ht=dn),pt=Dn}return Ke===void 0&&(Ke=0,rt=0,ht=Math.ceil(i/a)),ht===void 0&&(ht=_.length-1),ht=Math.min(ht+1,_.length-1),{scrollHeight:pt,start:Ke,end:ht,offset:rt}},[V,R,q,_,I,i]),He=De.scrollHeight,ue=De.start,ve=De.end,xe=De.offset;ce.current.start=ue,ce.current.end=ve,C.useLayoutEffect(function(){var We=P.getRecord();if(We.size===1){var pt=Array.from(We.keys())[0],Ke=We.get(pt),rt=_[ue];if(rt&&Ke===void 0){var ht=$(rt);if(ht===pt){var an=P.get(pt),dn=an-a;be(function(Un){return Un+dn})}}}P.resetRecord()},[He]);var fe=C.useState({width:0,height:i}),pe=te(fe,2),ke=pe[0],Ve=pe[1],Ee=function(We){Ve({width:We.offsetWidth,height:We.offsetHeight})},yt=et(),Dt=et(),Ft=C.useMemo(function(){return _6(ke.width,p)},[ke.width,p]),Ut=C.useMemo(function(){return _6(ke.height,He)},[ke.height,He]),Ge=He-i,Xe=et(Ge);Xe.current=Ge;function qe(We){var pt=We;return Number.isNaN(Xe.current)||(pt=Math.min(pt,Xe.current)),pt=Math.max(pt,0),pt}var lt=q<=0,je=q>=Ge,Rt=K<=0,zt=K>=p,dt=gB(lt,je,Rt,zt),Ct=function(){return{x:L?-K:K,y:q}},jt=et(Ct()),Ie=cn(function(We){if(b){var pt=Q(Q({},Ct()),We);(jt.current.x!==pt.x||jt.current.y!==pt.y)&&(b(pt),jt.current=pt)}});function Ne(We,pt){var Ke=We;pt?(LE(function(){re(Ke)}),Ie()):be(Ke)}function Oe(We){var pt=We.currentTarget.scrollTop;pt!==q&&be(pt),y==null||y(We),Ie()}var _e=function(We){var pt=We,Ke=p?p-ke.width:0;return pt=Math.max(pt,0),pt=Math.min(pt,Ke),pt},mt=cn(function(We,pt){pt?(LE(function(){re(function(Ke){var rt=Ke+(L?-We:We);return _e(rt)})}),Ie()):be(function(Ke){var rt=Ke+We;return rt})}),kt=eZ(R,lt,je,Rt,zt,!!p,mt),Pt=te(kt,2),Xt=Pt[0],on=Pt[1];oZ(R,F,function(We,pt,Ke,rt){var ht=rt;return dt(We,pt,Ke)?!1:!ht||!ht._virtualHandled?(ht&&(ht._virtualHandled=!0),Xt({preventDefault:function(){},deltaX:We?pt:0,deltaY:We?0:pt}),!0):!1}),iZ(V,F,function(We){be(function(pt){return pt+We})}),mn(function(){function We(Ke){var rt=lt&&Ke.detail<0,ht=je&&Ke.detail>0;R&&!rt&&!ht&&Ke.preventDefault()}var pt=F.current;return pt.addEventListener("wheel",Xt,{passive:!1}),pt.addEventListener("DOMMouseScroll",on,{passive:!0}),pt.addEventListener("MozMousePixelScroll",We,{passive:!1}),function(){pt.removeEventListener("wheel",Xt),pt.removeEventListener("DOMMouseScroll",on),pt.removeEventListener("MozMousePixelScroll",We)}},[R,lt,je]),mn(function(){if(p){var We=_e(K);re(We),Ie({x:We})}},[ke.width,p]);var qt=function(){var We,pt;(We=yt.current)===null||We===void 0||We.delayHidden(),(pt=Dt.current)===null||pt===void 0||pt.delayHidden()},wn=sZ(F,_,P,a,$,function(){return T(!0)},be,qt);C.useImperativeHandle(t,function(){return{nativeElement:z.current,getScrollInfo:Ct,scrollTo:function(We){function pt(Ke){return Ke&&At(Ke)==="object"&&("left"in Ke||"top"in Ke)}pt(We)?(We.left!==void 0&&re(_e(We.left)),wn(We.top)):wn(We)}}}),mn(function(){if(w){var We=_.slice(ue,ve+1);w(We,_)}},[ue,ve,_]);var vn=tZ(_,$,P,a),Kt=E==null?void 0:E({start:ue,end:ve,virtual:V,offsetX:K,offsetY:xe,rtl:L,getSize:vn}),$n=ZK(_,ue,ve,p,K,D,d,ye),On=null;i&&(On=Q(X({},l?"height":"maxHeight",i),dZ),R&&(On.overflowY="hidden",p&&(On.overflowX="hidden"),ae&&(On.pointerEvents="none")));var ur={};return L&&(ur.dir="rtl"),C.createElement("div",Qe({ref:z,style:Q(Q({},c),{},{position:"relative"}),className:j},ur,A),C.createElement(ea,{onResize:Ee},C.createElement(v,{className:"".concat(r,"-holder"),style:On,ref:F,onScroll:Oe,onMouseEnter:qt},C.createElement(pB,{prefixCls:r,height:He,offsetX:K,offsetY:xe,scrollWidth:p,onInnerResize:T,ref:B,innerProps:x,rtl:L,extra:Kt},$n))),V&&He>i&&C.createElement(R6,{ref:yt,prefixCls:r,scrollOffset:q,scrollRange:He,rtl:L,onScroll:Ne,onStartMove:ge,onStopMove:Se,spinSize:Ut,containerSize:ke.height,style:k==null?void 0:k.verticalScrollBar,thumbStyle:k==null?void 0:k.verticalScrollBarThumb,showScrollBar:O}),V&&p>ke.width&&C.createElement(R6,{ref:Dt,prefixCls:r,scrollOffset:K,scrollRange:p,rtl:L,onScroll:Ne,onStartMove:ge,onStopMove:Se,spinSize:Ft,containerSize:ke.width,horizontal:!0,style:k==null?void 0:k.horizontalScrollBar,thumbStyle:k==null?void 0:k.horizontalScrollBarThumb,showScrollBar:O}))}var mB=C.forwardRef(fZ);mB.displayName="List";function hZ(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var pZ=["disabled","title","children","style","className"];function j6(e){return typeof e=="string"||typeof e=="number"}var gZ=function(e,t){var n=JX(),r=n.prefixCls,o=n.id,i=n.open,a=n.multiple,s=n.mode,l=n.searchValue,c=n.toggleOpen,u=n.notFoundContent,d=n.onPopupScroll,f=C.useContext(tk),h=f.maxCount,m=f.flattenOptions,p=f.onActiveValue,g=f.defaultActiveFirstOption,v=f.onSelect,y=f.menuItemSelectedIcon,b=f.rawValues,w=f.fieldNames,x=f.virtual,E=f.direction,k=f.listHeight,S=f.listItemHeight,O=f.optionRender,A="".concat(r,"-item"),$=up(function(){return m},[i,m],function(U,Y){return Y[0]&&U[1]!==Y[1]}),M=C.useRef(null),N=C.useMemo(function(){return a&&L2(h)&&(b==null?void 0:b.size)>=h},[a,h,b==null?void 0:b.size]),D=function(U){U.preventDefault()},T=function(U){var Y;(Y=M.current)===null||Y===void 0||Y.scrollTo(typeof U=="number"?{index:U}:U)},P=C.useCallback(function(U){return s==="combobox"?!1:b.has(U)},[s,ze(b).toString(),b.size]),I=function(U){for(var Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,ie=$.length,K=0;K<ie;K+=1){var re=(U+K*Y+ie)%ie,oe=$[re]||{},ne=oe.group,ae=oe.data;if(!ne&&!(ae!=null&&ae.disabled)&&(P(ae.value)||!N))return re}return-1},R=C.useState(function(){return I(0)}),H=te(R,2),V=H[0],L=H[1],j=function(U){var Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;L(U);var ie={source:Y?"keyboard":"mouse"},K=$[U];if(!K){p(null,-1,ie);return}p(K.value,U,ie)};Et(function(){j(g!==!1?I(0):-1)},[$.length,l]);var _=C.useCallback(function(U){return s==="combobox"?String(U).toLowerCase()===l.toLowerCase():b.has(U)},[s,l,ze(b).toString(),b.size]);Et(function(){var U=setTimeout(function(){if(!a&&i&&b.size===1){var ie=Array.from(b)[0],K=$.findIndex(function(re){var oe=re.data;return l?String(oe.value).startsWith(l):oe.value===ie});K!==-1&&(j(K),T(K))}});if(i){var Y;(Y=M.current)===null||Y===void 0||Y.scrollTo(void 0)}return function(){return clearTimeout(U)}},[i,l]);var F=function(U){U!==void 0&&v(U,{selected:!b.has(U)}),a||c(!1)};if(C.useImperativeHandle(t,function(){return{onKeyDown:function(U){var Y=U.which,ie=U.ctrlKey;switch(Y){case St.N:case St.P:case St.UP:case St.DOWN:{var K=0;if(Y===St.UP?K=-1:Y===St.DOWN?K=1:hZ()&&ie&&(Y===St.N?K=1:Y===St.P&&(K=-1)),K!==0){var re=I(V+K,K);T(re),j(re,!0)}break}case St.TAB:case St.ENTER:{var oe,ne=$[V];ne&&!(ne!=null&&(oe=ne.data)!==null&&oe!==void 0&&oe.disabled)&&!N?F(ne.value):F(void 0),i&&U.preventDefault();break}case St.ESC:c(!1),i&&U.stopPropagation()}},onKeyUp:function(){},scrollTo:function(U){T(U)}}}),$.length===0)return C.createElement("div",{role:"listbox",id:"".concat(o,"_list"),className:"".concat(A,"-empty"),onMouseDown:D},u);var B=Object.keys(w).map(function(U){return w[U]}),z=function(U){return U.label};function G(U,Y){var ie=U.group;return{role:ie?"presentation":"option",id:"".concat(o,"_list_").concat(Y)}}var W=function(U){var Y=$[U];if(!Y)return null;var ie=Y.data||{},K=ie.value,re=Y.group,oe=Si(ie,!0),ne=z(Y);return Y?C.createElement("div",Qe({"aria-label":typeof ne=="string"&&!re?ne:null},oe,{key:U},G(Y,U),{"aria-selected":_(K)}),K):null},q={role:"listbox",id:"".concat(o,"_list")};return C.createElement(C.Fragment,null,x&&C.createElement("div",Qe({},q,{style:{height:0,width:0,overflow:"hidden"}}),W(V-1),W(V),W(V+1)),C.createElement(mB,{itemKey:"key",ref:M,data:$,height:k,itemHeight:S,fullHeight:!1,onMouseDown:D,onScroll:d,virtual:x,direction:E,innerProps:x?null:q},function(U,Y){var ie=U.group,K=U.groupOption,re=U.data,oe=U.label,ne=U.value,ae=re.key;if(ie){var de,ge=(de=re.title)!==null&&de!==void 0?de:j6(oe)?oe.toString():void 0;return C.createElement("div",{className:me(A,"".concat(A,"-group"),re.className),title:ge},oe!==void 0?oe:ae)}var Se=re.disabled,ye=re.title,be=re.style,ce=re.className,he=tn(re,pZ),Te=ta(he,B),se=P(ne),Pe=Se||!se&&N,De="".concat(A,"-option"),He=me(A,De,ce,X(X(X(X({},"".concat(De,"-grouped"),K),"".concat(De,"-active"),V===Y&&!Pe),"".concat(De,"-disabled"),Pe),"".concat(De,"-selected"),se)),ue=z(U),ve=!y||typeof y=="function"||se,xe=typeof ue=="number"?ue:ue||ne,fe=j6(xe)?xe.toString():void 0;return ye!==void 0&&(fe=ye),C.createElement("div",Qe({},Si(Te),x?{}:G(U,Y),{"aria-selected":_(ne),className:He,title:fe,onMouseMove:function(){V===Y||Pe||j(Y)},onClick:function(){Pe||F(ne)},style:be}),C.createElement("div",{className:"".concat(De,"-content")},typeof O=="function"?O(U,{index:Y}):xe),C.isValidElement(y)||se,ve&&C.createElement(Dp,{className:"".concat(A,"-option-state"),customizeIcon:y,customizeIconProps:{value:ne,disabled:Pe,isSelected:se}},se?"\u2713":null))}))},mZ=C.forwardRef(gZ);const vZ=(function(e,t){var n=C.useRef({values:new Map,options:new Map}),r=C.useMemo(function(){var i=n.current,a=i.values,s=i.options,l=e.map(function(d){if(d.label===void 0){var f;return Q(Q({},d),{},{label:(f=a.get(d.value))===null||f===void 0?void 0:f.label})}return d}),c=new Map,u=new Map;return l.forEach(function(d){c.set(d.value,d),u.set(d.value,t.get(d.value)||s.get(d.value))}),n.current.values=c,n.current.options=u,l},[e,t]),o=C.useCallback(function(i){return t.get(i)||n.current.options.get(i)},[t]);return[r,o]});function ym(e,t){return dB(e).join("").toUpperCase().includes(t)}const yZ=(function(e,t,n,r,o){return C.useMemo(function(){if(!n||r===!1)return e;var i=t.options,a=t.label,s=t.value,l=[],c=typeof r=="function",u=n.toUpperCase(),d=c?r:function(h,m){return o?ym(m[o],u):m[i]?ym(m[a!=="children"?a:"label"],u):ym(m[s],u)},f=c?function(h){return z2(h)}:function(h){return h};return e.forEach(function(h){if(h[i]){var m=d(n,f(h));if(m)l.push(h);else{var p=h[i].filter(function(g){return d(n,f(g))});p.length&&l.push(Q(Q({},h),{},X({},i,p)))}return}d(n,f(h))&&l.push(h)}),l},[e,r,o,n,t])});var L6=0,bZ=$o();function xZ(){var e;return bZ?(e=L6,L6+=1):e="TEST_OR_SSR",e}function EZ(e){var t=C.useState(),n=te(t,2),r=n[0],o=n[1];return C.useEffect(function(){o("rc_select_".concat(xZ()))},[]),e||r}var wZ=["children","value"],CZ=["children"];function kZ(e){var t=e,n=t.key,r=t.props,o=r.children,i=r.value,a=tn(r,wZ);return Q({key:n,value:i!==void 0?i:n,children:o},a)}function vB(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return fc(e).map(function(n,r){if(!C.isValidElement(n)||!n.type)return null;var o=n,i=o.type.isSelectOptGroup,a=o.key,s=o.props,l=s.children,c=tn(s,CZ);return t||!i?kZ(n):Q(Q({key:"__RC_SELECT_GRP__".concat(a===null?r:a,"__"),label:a},c),{},{options:vB(l)})}).filter(function(n){return n})}var SZ=function(e,t,n,r,o){return C.useMemo(function(){var i=e,a=!e;a&&(i=vB(t));var s=new Map,l=new Map,c=function(d,f,h){h&&typeof h=="string"&&d.set(f[h],f)},u=function d(f){for(var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,m=0;m<f.length;m+=1){var p=f[m];!p[n.options]||h?(s.set(p[n.value],p),c(l,p,n.label),c(l,p,r),c(l,p,o)):d(p[n.options],!0)}};return u(i),{options:i,valueOptions:s,labelOptions:l}},[e,t,n,r,o])};function z6(e){var t=C.useRef();t.current=e;var n=C.useCallback(function(){return t.current.apply(t,arguments)},[]);return n}var AZ=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],$Z=["inputValue"];function OZ(e){return!e||At(e)!=="object"}var MZ=C.forwardRef(function(e,t){var n=e.id,r=e.mode,o=e.prefixCls,i=o===void 0?"rc-select":o,a=e.backfill,s=e.fieldNames,l=e.inputValue,c=e.searchValue,u=e.onSearch,d=e.autoClearSearchValue,f=d===void 0?!0:d,h=e.onSelect,m=e.onDeselect,p=e.dropdownMatchSelectWidth,g=p===void 0?!0:p,v=e.filterOption,y=e.filterSort,b=e.optionFilterProp,w=e.optionLabelProp,x=e.options,E=e.optionRender,k=e.children,S=e.defaultActiveFirstOption,O=e.menuItemSelectedIcon,A=e.virtual,$=e.direction,M=e.listHeight,N=M===void 0?200:M,D=e.listItemHeight,T=D===void 0?20:D,P=e.labelRender,I=e.value,R=e.defaultValue,H=e.labelInValue,V=e.onChange,L=e.maxCount,j=tn(e,AZ),_=EZ(n),F=H2(r),B=!!(!x&&k),z=C.useMemo(function(){return v===void 0&&r==="combobox"?!1:v},[v,r]),G=C.useMemo(function(){return hB(s,B)},[JSON.stringify(s),B]),W=yr("",{value:c!==void 0?c:l,postState:function(Ie){return Ie||""}}),q=te(W,2),U=q[0],Y=q[1],ie=SZ(x,k,G,b,w),K=ie.valueOptions,re=ie.labelOptions,oe=ie.options,ne=C.useCallback(function(Ie){var Ne=dB(Ie);return Ne.map(function(Oe){var _e,mt,kt,Pt,Xt;if(OZ(Oe))_e=Oe;else{var on;kt=Oe.key,mt=Oe.label,_e=(on=Oe.value)!==null&&on!==void 0?on:kt}var qt=K.get(_e);if(qt){var wn;mt===void 0&&(mt=qt==null?void 0:qt[w||G.label]),kt===void 0&&(kt=(wn=qt==null?void 0:qt.key)!==null&&wn!==void 0?wn:_e),Pt=qt==null?void 0:qt.disabled,Xt=qt==null?void 0:qt.title}return{label:mt,value:_e,key:kt,disabled:Pt,title:Xt}})},[G,w,K]),ae=yr(R,{value:I}),de=te(ae,2),ge=de[0],Se=de[1],ye=C.useMemo(function(){var Ie,Ne=F&&ge===null?[]:ge,Oe=ne(Ne);return r==="combobox"&&xK((Ie=Oe[0])===null||Ie===void 0?void 0:Ie.value)?[]:Oe},[ge,ne,r,F]),be=vZ(ye,K),ce=te(be,2),he=ce[0],Te=ce[1],se=C.useMemo(function(){if(!r&&he.length===1){var Ie=he[0];if(Ie.value===null&&(Ie.label===null||Ie.label===void 0))return[]}return he.map(function(Ne){var Oe;return Q(Q({},Ne),{},{label:(Oe=typeof P=="function"?P(Ne):Ne.label)!==null&&Oe!==void 0?Oe:Ne.value})})},[r,he,P]),Pe=C.useMemo(function(){return new Set(he.map(function(Ie){return Ie.value}))},[he]);C.useEffect(function(){if(r==="combobox"){var Ie,Ne=(Ie=he[0])===null||Ie===void 0?void 0:Ie.value;Y(bK(Ne)?String(Ne):"")}},[he]);var De=z6(function(Ie,Ne){var Oe=Ne??Ie;return X(X({},G.value,Ie),G.label,Oe)}),He=C.useMemo(function(){if(r!=="tags")return oe;var Ie=ze(oe),Ne=function(Oe){return K.has(Oe)};return ze(he).sort(function(Oe,_e){return Oe.value<_e.value?-1:1}).forEach(function(Oe){var _e=Oe.value;Ne(_e)||Ie.push(De(_e,Oe.label))}),Ie},[De,oe,K,he,r]),ue=yZ(He,G,U,z,b),ve=C.useMemo(function(){return r!=="tags"||!U||ue.some(function(Ie){return Ie[b||"value"]===U})||ue.some(function(Ie){return Ie[G.value]===U})?ue:[De(U)].concat(ze(ue))},[De,b,r,ue,U,G]),xe=function Ie(Ne){var Oe=ze(Ne).sort(function(_e,mt){return y(_e,mt,{searchValue:U})});return Oe.map(function(_e){return Array.isArray(_e.options)?Q(Q({},_e),{},{options:_e.options.length>0?Ie(_e.options):_e.options}):_e})},fe=C.useMemo(function(){return y?xe(ve):ve},[ve,y,U]),pe=C.useMemo(function(){return VK(fe,{fieldNames:G,childrenAsData:B})},[fe,G,B]),ke=function(Ie){var Ne=ne(Ie);if(Se(Ne),V&&(Ne.length!==he.length||Ne.some(function(mt,kt){var Pt;return((Pt=he[kt])===null||Pt===void 0?void 0:Pt.value)!==(mt==null?void 0:mt.value)}))){var Oe=H?Ne:Ne.map(function(mt){return mt.value}),_e=Ne.map(function(mt){return z2(Te(mt.value))});V(F?Oe:Oe[0],F?_e:_e[0])}},Ve=C.useState(null),Ee=te(Ve,2),yt=Ee[0],Dt=Ee[1],Ft=C.useState(0),Ut=te(Ft,2),Ge=Ut[0],Xe=Ut[1],qe=S!==void 0?S:r!=="combobox",lt=C.useCallback(function(Ie,Ne){var Oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},_e=Oe.source,mt=_e===void 0?"keyboard":_e;Xe(Ne),a&&r==="combobox"&&Ie!==null&&mt==="keyboard"&&Dt(String(Ie))},[a,r]),je=function(Ie,Ne,Oe){var _e=function(){var Kt,$n=Te(Ie);return[H?{label:$n==null?void 0:$n[G.label],value:Ie,key:(Kt=$n==null?void 0:$n.key)!==null&&Kt!==void 0?Kt:Ie}:Ie,z2($n)]};if(Ne&&h){var mt=_e(),kt=te(mt,2),Pt=kt[0],Xt=kt[1];h(Pt,Xt)}else if(!Ne&&m&&Oe!=="clear"){var on=_e(),qt=te(on,2),wn=qt[0],vn=qt[1];m(wn,vn)}},Rt=z6(function(Ie,Ne){var Oe,_e=F?Ne.selected:!0;_e?Oe=F?[].concat(ze(he),[Ie]):[Ie]:Oe=he.filter(function(mt){return mt.value!==Ie}),ke(Oe),je(Ie,_e),r==="combobox"?Dt(""):(!H2||f)&&(Y(""),Dt(""))}),zt=function(Ie,Ne){ke(Ie);var Oe=Ne.type,_e=Ne.values;(Oe==="remove"||Oe==="clear")&&_e.forEach(function(mt){je(mt.value,!1,Oe)})},dt=function(Ie,Ne){if(Y(Ie),Dt(null),Ne.source==="submit"){var Oe=(Ie||"").trim();if(Oe){var _e=Array.from(new Set([].concat(ze(Pe),[Oe])));ke(_e),je(Oe,!0),Y("")}return}Ne.source!=="blur"&&(r==="combobox"&&ke(Ie),u==null||u(Ie))},Ct=function(Ie){var Ne=Ie;r!=="tags"&&(Ne=Ie.map(function(_e){var mt=re.get(_e);return mt==null?void 0:mt.value}).filter(function(_e){return _e!==void 0}));var Oe=Array.from(new Set([].concat(ze(Pe),ze(Ne))));ke(Oe),Oe.forEach(function(_e){je(_e,!0)})},jt=C.useMemo(function(){var Ie=A!==!1&&g!==!1;return Q(Q({},ie),{},{flattenOptions:pe,onActiveValue:lt,defaultActiveFirstOption:qe,onSelect:Rt,menuItemSelectedIcon:O,rawValues:Pe,fieldNames:G,virtual:Ie,direction:$,listHeight:N,listItemHeight:T,childrenAsData:B,maxCount:L,optionRender:E})},[L,ie,pe,lt,qe,Rt,O,Pe,G,A,g,$,N,T,B,E]);return C.createElement(tk.Provider,{value:jt},C.createElement(XK,Qe({},j,{id:_,prefixCls:i,ref:t,omitDomProps:$Z,mode:r,displayValues:se,onDisplayValuesChange:zt,direction:$,searchValue:U,onSearch:dt,autoClearSearchValue:f,onSearchSplit:Ct,dropdownMatchSelectWidth:g,OptionList:mZ,emptyOptions:!pe.length,activeValue:yt,activeDescendantId:"".concat(_,"_list_").concat(Ge)})))}),ok=MZ;ok.Option=rk;ok.OptGroup=nk;function ns(e,t,n){return me({[`${e}-status-success`]:t==="success",[`${e}-status-warning`]:t==="warning",[`${e}-status-error`]:t==="error",[`${e}-status-validating`]:t==="validating",[`${e}-has-feedback`]:n})}const pl=(e,t)=>t||e,NZ=()=>{const[,e]=ii(),[t]=dl("Empty"),n=new Sn(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return C.createElement("svg",{style:n,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},C.createElement("title",null,(t==null?void 0:t.description)||"Empty"),C.createElement("g",{fill:"none",fillRule:"evenodd"},C.createElement("g",{transform:"translate(24 31.67)"},C.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),C.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),C.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),C.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),C.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),C.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),C.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},C.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),C.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},DZ=()=>{const[,e]=ii(),[t]=dl("Empty"),{colorFill:n,colorFillTertiary:r,colorFillQuaternary:o,colorBgContainer:i}=e,{borderColor:a,shadowColor:s,contentColor:l}=Gt(()=>({borderColor:new Sn(n).onBackground(i).toHexString(),shadowColor:new Sn(r).onBackground(i).toHexString(),contentColor:new Sn(o).onBackground(i).toHexString()}),[n,r,o,i]);return C.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},C.createElement("title",null,(t==null?void 0:t.description)||"Empty"),C.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},C.createElement("ellipse",{fill:s,cx:"32",cy:"33",rx:"32",ry:"7"}),C.createElement("g",{fillRule:"nonzero",stroke:a},C.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),C.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:l}))))},TZ=e=>{const{componentCls:t,margin:n,marginXS:r,marginXL:o,fontSize:i,lineHeight:a}=e;return{[t]:{marginInline:r,fontSize:i,lineHeight:a,textAlign:"center",[`${t}-image`]:{height:e.emptyImgHeight,marginBottom:r,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${t}-description`]:{color:e.colorTextDescription},[`${t}-footer`]:{marginTop:n},"&-normal":{marginBlock:o,color:e.colorTextDescription,[`${t}-description`]:{color:e.colorTextDescription},[`${t}-image`]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:r,color:e.colorTextDescription,[`${t}-image`]:{height:e.emptyImgHeightSM}}}}},FZ=Pr("Empty",e=>{const{componentCls:t,controlHeightLG:n,calc:r}=e,o=Mn(e,{emptyImgCls:`${t}-img`,emptyImgHeight:r(n).mul(2.5).equal(),emptyImgHeightMD:n,emptyImgHeightSM:r(n).mul(.875).equal()});return TZ(o)});var PZ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const yB=C.createElement(NZ,null),bB=C.createElement(DZ,null),Ds=e=>{var t;const{className:n,rootClassName:r,prefixCls:o,image:i,description:a,children:s,imageStyle:l,style:c,classNames:u,styles:d}=e,f=PZ(e,["className","rootClassName","prefixCls","image","description","children","imageStyle","style","classNames","styles"]),{getPrefixCls:h,direction:m,className:p,style:g,classNames:v,styles:y,image:b}=xa("empty"),w=h("empty",o),[x,E,k]=FZ(w),[S]=dl("Empty"),O=typeof a<"u"?a:S==null?void 0:S.description,A=typeof O=="string"?O:"empty",$=(t=i??b)!==null&&t!==void 0?t:yB;let M=null;return typeof $=="string"?M=C.createElement("img",{draggable:!1,alt:A,src:$}):M=$,x(C.createElement("div",Object.assign({className:me(E,k,w,p,{[`${w}-normal`]:$===bB,[`${w}-rtl`]:m==="rtl"},n,r,v.root,u==null?void 0:u.root),style:Object.assign(Object.assign(Object.assign(Object.assign({},y.root),g),d==null?void 0:d.root),c)},f),C.createElement("div",{className:me(`${w}-image`,v.image,u==null?void 0:u.image),style:Object.assign(Object.assign(Object.assign({},l),y.image),d==null?void 0:d.image)},M),O&&C.createElement("div",{className:me(`${w}-description`,v.description,u==null?void 0:u.description),style:Object.assign(Object.assign({},y.description),d==null?void 0:d.description)},O),s&&C.createElement("div",{className:me(`${w}-footer`,v.footer,u==null?void 0:u.footer),style:Object.assign(Object.assign({},y.footer),d==null?void 0:d.footer)},s)))};Ds.PRESENTED_IMAGE_DEFAULT=yB;Ds.PRESENTED_IMAGE_SIMPLE=bB;const IZ=e=>{const{componentName:t}=e,{getPrefixCls:n}=pr(pn),r=n("empty");switch(t){case"Table":case"List":return we.createElement(Ds,{image:Ds.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return we.createElement(Ds,{image:Ds.PRESENTED_IMAGE_SIMPLE,className:`${r}-small`});case"Table.filter":return null;default:return we.createElement(Ds,null)}},Pc=(e,t,n)=>{var r,o;const{variant:i,[e]:a}=C.useContext(pn),s=C.useContext(oB),l=a==null?void 0:a.variant;let c;typeof t<"u"?c=t:n===!1?c="borderless":c=(o=(r=s??l)!==null&&r!==void 0?r:i)!==null&&o!==void 0?o:"outlined";const u=zV.includes(c);return[c,u]},BZ=e=>{const t={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:e==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},t),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},t),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},t),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},t),{points:["br","tr"],offset:[0,-4]})}};function RZ(e,t){return e||BZ(t)}const H6=e=>{const{optionHeight:t,optionFontSize:n,optionLineHeight:r,optionPadding:o}=e;return{position:"relative",display:"block",minHeight:t,padding:o,color:e.colorText,fontWeight:"normal",fontSize:n,lineHeight:r,boxSizing:"border-box"}},_Z=e=>{const{antCls:t,componentCls:n}=e,r=`${n}-item`,o=`&${t}-slide-up-enter${t}-slide-up-enter-active`,i=`&${t}-slide-up-appear${t}-slide-up-appear-active`,a=`&${t}-slide-up-leave${t}-slide-up-leave-active`,s=`${n}-dropdown-placement-`,l=`${r}-option-selected`;return[{[`${n}-dropdown`]:Object.assign(Object.assign({},br(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,[`
|
|
287
|
+
`].includes(ot)})},[T]),Oe=C.useContext(tk)||{},_e=Oe.maxCount,mt=Oe.rawValues,kt=function(ot,Mt,Zt){if(!(ge&&L2(_e)&&(mt==null?void 0:mt.size)>=_e)){var Ue=!0,Ye=ot;O==null||O(null);var ct=GK(ot,T,L2(_e)?_e-mt.size:void 0),Tt=Zt?null:ct;return g!=="combobox"&&Tt&&(Ye="",D==null||D(Tt),Ie(!1),Ue=!1),N&&Ee!==Ye&&N(Ye,{source:Mt?"typing":"effect"}),Ue}},It=function(ot){!ot||!ot.trim()||N(ot,{source:"submit"})};C.useEffect(function(){!dt&&!ge&&g!=="combobox"&&kt("",!1,!1)},[dt]),C.useEffect(function(){Rt&&v&&zt(!1),v&&!ve.current&&ke(!1)},[v]);var Xt=aB(),on=te(Xt,2),qt=on[0],wn=on[1],vn=C.useRef(!1),Kt=function(ot){var Mt=qt(),Zt=ot.key,Ue=Zt==="Enter";if(Ue&&(g!=="combobox"&&ot.preventDefault(),dt||Ie(!0)),wn(!!Ee),Zt==="Backspace"&&!Mt&&ge&&!Ee&&u.length){for(var Ye=ze(u),ct=null,Tt=Ye.length-1;Tt>=0;Tt-=1){var Cn=Ye[Tt];if(!Cn.disabled){Ye.splice(Tt,1),ct=Cn;break}}ct&&d(Ye,{type:"remove",values:[ct]})}for(var bt=arguments.length,Wt=new Array(bt>1?bt-1:0),Fn=1;Fn<bt;Fn++)Wt[Fn-1]=arguments[Fn];if(dt&&(!Ue||!vn.current)){var ft;Ue&&(vn.current=!0),(ft=ue.current)===null||ft===void 0||ft.onKeyDown.apply(ft,[ot].concat(Wt))}ne==null||ne.apply(void 0,[ot].concat(Wt))},$n=function(ot){for(var Mt=arguments.length,Zt=new Array(Mt>1?Mt-1:0),Ue=1;Ue<Mt;Ue++)Zt[Ue-1]=arguments[Ue];if(dt){var Ye;(Ye=ue.current)===null||Ye===void 0||Ye.onKeyUp.apply(Ye,[ot].concat(Zt))}ot.key==="Enter"&&(vn.current=!1),oe==null||oe.apply(void 0,[ot].concat(Zt))},On=function(ot){var Mt=u.filter(function(Zt){return Zt!==ot});d(Mt,{type:"remove",values:[ot]})},ur=function(){vn.current=!1},We=C.useRef(!1),pt=function(){ke(!0),v||(K&&!We.current&&K.apply(void 0,arguments),ie.includes("focus")&&Ie(!0)),We.current=!0},Ke=function(){ve.current=!0,ke(!1,function(){We.current=!1,ve.current=!1,Ie(!1)}),!v&&(Ee&&(g==="tags"?N(Ee,{source:"submit"}):g==="multiple"&&N("",{source:"blur"})),re&&re.apply(void 0,arguments))},rt=[];C.useEffect(function(){return function(){rt.forEach(function(ot){return clearTimeout(ot)}),rt.splice(0,rt.length)}},[]);var ht=function(ot){var Mt,Zt=ot.target,Ue=(Mt=De.current)===null||Mt===void 0?void 0:Mt.getPopupElement();if(Ue&&Ue.contains(Zt)){var Ye=setTimeout(function(){var bt=rt.indexOf(Ye);if(bt!==-1&&rt.splice(bt,1),Ve(),!he&&!Ue.contains(document.activeElement)){var Wt;(Wt=He.current)===null||Wt===void 0||Wt.focus()}});rt.push(Ye)}for(var ct=arguments.length,Tt=new Array(ct>1?ct-1:0),Cn=1;Cn<ct;Cn++)Tt[Cn-1]=arguments[Cn];ae==null||ae.apply(void 0,[ot].concat(Tt))},an=C.useState({}),dn=te(an,2),Un=dn[1];function dr(){Un({})}var Nn;Dt&&(Nn=function(ot){Ie(ot)}),tK(function(){var ot;return[se.current,(ot=De.current)===null||ot===void 0?void 0:ot.getPopupElement()]},jt,Ie,!!Dt);var Dn=C.useMemo(function(){return Q(Q({},e),{},{notFoundContent:m,open:dt,triggerOpen:jt,id:r,showSearch:Se,multiple:ge,toggleOpen:Ie})},[e,m,jt,dt,r,Se,ge,Ie]),wr=!!R||y,ar;wr&&(ar=C.createElement(Dp,{className:me("".concat(o,"-arrow"),X({},"".concat(o,"-arrow-loading"),y)),customizeIcon:R,customizeIconProps:{loading:y,searchValue:Ee,open:dt,focused:pe,showSearch:Se}}));var J=function(){var ot;p==null||p(),(ot=He.current)===null||ot===void 0||ot.focus(),d([],{type:"clear",values:u}),kt("",!1,!1)},Z=QX(o,J,u,P,H,v,Ee,g),$e=Z.allowClear,Ae=Z.clearIcon,tt=C.createElement(V,{ref:ue}),vt=me(o,i,X(X(X(X(X(X(X(X(X(X({},"".concat(o,"-focused"),pe),"".concat(o,"-multiple"),ge),"".concat(o,"-single"),!ge),"".concat(o,"-allow-clear"),P),"".concat(o,"-show-arrow"),wr),"".concat(o,"-disabled"),v),"".concat(o,"-loading"),y),"".concat(o,"-open"),dt),"".concat(o,"-customize-input"),yt),"".concat(o,"-show-search"),Se)),Ot=C.createElement(WK,{ref:De,disabled:v,prefixCls:o,visible:jt,popupElement:tt,animation:L,transitionName:j,dropdownStyle:_,dropdownClassName:F,direction:l,dropdownMatchSelectWidth:B,dropdownRender:z,dropdownAlign:G,placement:W,builtinPlacements:q,getPopupContainer:U,empty:f,getTriggerDOMNode:function(ot){return Pe.current||ot},onPopupVisibleChange:Nn,onPopupMouseEnter:dr},Dt?C.cloneElement(Dt,{ref:Pt}):C.createElement(AK,Qe({},e,{domRef:Pe,prefixCls:o,inputElement:yt,ref:He,id:r,prefix:I,showSearch:Se,autoClearSearchValue:M,mode:g,activeDescendantId:A,tagRender:s,values:u,open:dt,onToggleOpen:Ie,activeValue:S,searchValue:Ee,onSearch:kt,onSearchSubmit:It,onRemove:On,tokenWithEnter:Ne,onInputBlur:ur}))),wt;return Dt?wt=Ot:wt=C.createElement("div",Qe({className:vt},ye,{ref:se,onMouseDown:ht,onKeyDown:Kt,onKeyUp:$n,onFocus:pt,onBlur:Ke}),C.createElement(UK,{visible:pe&&!dt,values:u}),Ot,ar,$e&&Ae),C.createElement(iB.Provider,{value:Dn},wt)}),nk=function(){return null};nk.isSelectOptGroup=!0;var rk=function(){return null};rk.isSelectOption=!0;var pB=C.forwardRef(function(e,t){var n=e.height,r=e.offsetY,o=e.offsetX,i=e.children,a=e.prefixCls,s=e.onInnerResize,l=e.innerProps,c=e.rtl,u=e.extra,d={},f={display:"flex",flexDirection:"column"};return r!==void 0&&(d={height:n,position:"relative",overflow:"hidden"},f=Q(Q({},f),{},X(X(X(X(X({transform:"translateY(".concat(r,"px)")},c?"marginRight":"marginLeft",-o),"position","absolute"),"left",0),"right",0),"top",0))),C.createElement("div",{style:d},C.createElement(ea,{onResize:function(h){var m=h.offsetHeight;m&&s&&s()}},C.createElement("div",Qe({style:f,className:me(X({},"".concat(a,"-holder-inner"),a)),ref:t},l),i,u)))});pB.displayName="Filler";function KK(e){var t=e.children,n=e.setRef,r=C.useCallback(function(o){n(o)},[]);return C.cloneElement(t,{ref:r})}function ZK(e,t,n,r,o,i,a,s){var l=s.getKey;return e.slice(t,n+1).map(function(c,u){var d=t+u,f=a(c,d,{style:{width:r},offsetX:o}),h=l(c);return C.createElement(KK,{key:h,setRef:function(m){return i(c,m)}},f)})}function QK(e,t,n){var r=e.length,o=t.length,i,a;if(r===0&&o===0)return null;r<o?(i=e,a=t):(i=t,a=e);var s={__EMPTY_ITEM__:!0};function l(m){return m!==void 0?n(m):s}for(var c=null,u=Math.abs(r-o)!==1,d=0;d<a.length;d+=1){var f=l(i[d]),h=l(a[d]);if(f!==h){c=d,u=u||f!==l(a[d+1]);break}}return c===null?null:{index:c,multiple:u}}function JK(e,t,n){var r=C.useState(e),o=te(r,2),i=o[0],a=o[1],s=C.useState(null),l=te(s,2),c=l[0],u=l[1];return C.useEffect(function(){var d=QK(i||[],e||[],t);(d==null?void 0:d.index)!==void 0&&u(e[d.index]),a(e)},[e]),[c]}var F6=(typeof navigator>"u"?"undefined":At(navigator))==="object"&&/Firefox/i.test(navigator.userAgent);const gB=(function(e,t,n,r){var o=et(!1),i=et(null);function a(){clearTimeout(i.current),o.current=!0,i.current=setTimeout(function(){o.current=!1},50)}var s=et({top:e,bottom:t,left:n,right:r});return s.current.top=e,s.current.bottom=t,s.current.left=n,s.current.right=r,function(l,c){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,d=l?c<0&&s.current.left||c>0&&s.current.right:c<0&&s.current.top||c>0&&s.current.bottom;return u&&d?(clearTimeout(i.current),o.current=!1):(!d||o.current)&&a(),!o.current&&d}});function eZ(e,t,n,r,o,i,a){var s=et(0),l=et(null),c=et(null),u=et(!1),d=gB(t,n,r,o);function f(y,b){if(en.cancel(l.current),!d(!1,b)){var w=y;if(!w._virtualHandled)w._virtualHandled=!0;else return;s.current+=b,c.current=b,F6||w.preventDefault(),l.current=en(function(){var x=u.current?10:1;a(s.current*x,!1),s.current=0})}}function h(y,b){a(b,!0),F6||y.preventDefault()}var m=et(null),p=et(null);function g(y){if(e){en.cancel(p.current),p.current=en(function(){m.current=null},2);var b=y.deltaX,w=y.deltaY,x=y.shiftKey,E=b,k=w;(m.current==="sx"||!m.current&&x&&w&&!b)&&(E=w,k=0,m.current="sx");var S=Math.abs(E),O=Math.abs(k);m.current===null&&(m.current=i&&S>O?"x":"y"),m.current==="y"?f(y,k):h(y,E)}}function v(y){e&&(u.current=y.detail===c.current)}return[g,v]}function tZ(e,t,n,r){var o=C.useMemo(function(){return[new Map,[]]},[e,n.id,r]),i=te(o,2),a=i[0],s=i[1],l=function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:c,d=a.get(c),f=a.get(u);if(d===void 0||f===void 0)for(var h=e.length,m=s.length;m<h;m+=1){var p,g=e[m],v=t(g);a.set(v,m);var y=(p=n.get(v))!==null&&p!==void 0?p:r;if(s[m]=(s[m-1]||0)+y,v===c&&(d=m),v===u&&(f=m),d!==void 0&&f!==void 0)break}return{top:s[d-1]||0,bottom:s[f]}};return l}var nZ=(function(){function e(){xr(this,e),X(this,"maps",void 0),X(this,"id",0),X(this,"diffRecords",new Map),this.maps=Object.create(null)}return Er(e,[{key:"set",value:function(t,n){this.diffRecords.set(t,this.maps[t]),this.maps[t]=n,this.id+=1}},{key:"get",value:function(t){return this.maps[t]}},{key:"resetRecord",value:function(){this.diffRecords.clear()}},{key:"getRecord",value:function(){return this.diffRecords}}]),e})();function P6(e){var t=parseFloat(e);return isNaN(t)?0:t}function rZ(e,t,n){var r=C.useState(0),o=te(r,2),i=o[0],a=o[1],s=et(new Map),l=et(new nZ),c=et(0);function u(){c.current+=1}function d(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;u();var m=function(){var g=!1;s.current.forEach(function(v,y){if(v&&v.offsetParent){var b=v.offsetHeight,w=getComputedStyle(v),x=w.marginTop,E=w.marginBottom,k=P6(x),S=P6(E),O=b+k+S;l.current.get(y)!==O&&(l.current.set(y,O),g=!0)}}),g&&a(function(v){return v+1})};if(h)m();else{c.current+=1;var p=c.current;Promise.resolve().then(function(){p===c.current&&m()})}}function f(h,m){var p=e(h);s.current.get(p),m?(s.current.set(p,m),d()):s.current.delete(p)}return Et(function(){return u},[]),[f,d,l.current,i]}var I6=14/15;function oZ(e,t,n){var r=et(!1),o=et(0),i=et(0),a=et(null),s=et(null),l,c=function(f){if(r.current){var h=Math.ceil(f.touches[0].pageX),m=Math.ceil(f.touches[0].pageY),p=o.current-h,g=i.current-m,v=Math.abs(p)>Math.abs(g);v?o.current=h:i.current=m;var y=n(v,v?p:g,!1,f);y&&f.preventDefault(),clearInterval(s.current),y&&(s.current=setInterval(function(){v?p*=I6:g*=I6;var b=Math.floor(v?p:g);(!n(v,b,!0)||Math.abs(b)<=.1)&&clearInterval(s.current)},16))}},u=function(){r.current=!1,l()},d=function(f){l(),f.touches.length===1&&!r.current&&(r.current=!0,o.current=Math.ceil(f.touches[0].pageX),i.current=Math.ceil(f.touches[0].pageY),a.current=f.target,a.current.addEventListener("touchmove",c,{passive:!1}),a.current.addEventListener("touchend",u,{passive:!0}))};l=function(){a.current&&(a.current.removeEventListener("touchmove",c),a.current.removeEventListener("touchend",u))},mn(function(){return e&&t.current.addEventListener("touchstart",d,{passive:!0}),function(){var f;(f=t.current)===null||f===void 0||f.removeEventListener("touchstart",d),l(),clearInterval(s.current)}},[e])}function B6(e){return Math.floor(Math.pow(e,.5))}function W2(e,t){var n="touches"in e?e.touches[0]:e;return n[t?"pageX":"pageY"]-window[t?"scrollX":"scrollY"]}function iZ(e,t,n){C.useEffect(function(){var r=t.current;if(e&&r){var o=!1,i,a,s=function(){en.cancel(i)},l=function f(){s(),i=en(function(){n(a),f()})},c=function(){o=!1,s()},u=function(f){if(!(f.target.draggable||f.button!==0)){var h=f;h._virtualHandled||(h._virtualHandled=!0,o=!0)}},d=function(f){if(o){var h=W2(f,!1),m=r.getBoundingClientRect(),p=m.top,g=m.bottom;if(h<=p){var v=p-h;a=-B6(v),l()}else if(h>=g){var y=h-g;a=B6(y),l()}else s()}};return r.addEventListener("mousedown",u),r.ownerDocument.addEventListener("mouseup",c),r.ownerDocument.addEventListener("mousemove",d),r.ownerDocument.addEventListener("dragend",c),function(){r.removeEventListener("mousedown",u),r.ownerDocument.removeEventListener("mouseup",c),r.ownerDocument.removeEventListener("mousemove",d),r.ownerDocument.removeEventListener("dragend",c),s()}}},[e])}var aZ=10;function sZ(e,t,n,r,o,i,a,s){var l=C.useRef(),c=C.useState(null),u=te(c,2),d=u[0],f=u[1];return mn(function(){if(d&&d.times<aZ){if(!e.current){f(function(H){return Q({},H)});return}i();var h=d.targetAlign,m=d.originAlign,p=d.index,g=d.offset,v=e.current.clientHeight,y=!1,b=h,w=null;if(v){for(var x=h||m,E=0,k=0,S=0,O=Math.min(t.length-1,p),A=0;A<=O;A+=1){var $=o(t[A]);k=E;var M=n.get($);S=k+(M===void 0?r:M),E=S}for(var N=x==="top"?g:v-g,D=O;D>=0;D-=1){var T=o(t[D]),P=n.get(T);if(P===void 0){y=!0;break}if(N-=P,N<=0)break}switch(x){case"top":w=k-g;break;case"bottom":w=S-v+g;break;default:{var I=e.current.scrollTop,R=I+v;k<I?b="top":S>R&&(b="bottom")}}w!==null&&a(w),w!==d.lastTop&&(y=!0)}y&&f(Q(Q({},d),{},{times:d.times+1,targetAlign:b,lastTop:w}))}},[d,e.current]),function(h){if(h==null){s();return}if(en.cancel(l.current),typeof h=="number")a(h);else if(h&&At(h)==="object"){var m,p=h.align;"index"in h?m=h.index:m=t.findIndex(function(y){return o(y)===h.key});var g=h.offset,v=g===void 0?0:g;f({times:0,index:m,offset:v,originAlign:p})}}}var R6=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.rtl,o=e.scrollOffset,i=e.scrollRange,a=e.onStartMove,s=e.onStopMove,l=e.onScroll,c=e.horizontal,u=e.spinSize,d=e.containerSize,f=e.style,h=e.thumbStyle,m=e.showScrollBar,p=C.useState(!1),g=te(p,2),v=g[0],y=g[1],b=C.useState(null),w=te(b,2),x=w[0],E=w[1],k=C.useState(null),S=te(k,2),O=S[0],A=S[1],$=!r,M=C.useRef(),N=C.useRef(),D=C.useState(m),T=te(D,2),P=T[0],I=T[1],R=C.useRef(),H=function(){m===!0||m===!1||(clearTimeout(R.current),I(!0),R.current=setTimeout(function(){I(!1)},3e3))},V=i-d||0,L=d-u||0,j=C.useMemo(function(){if(o===0||V===0)return 0;var Y=o/V;return Y*L},[o,V,L]),_=function(Y){Y.stopPropagation(),Y.preventDefault()},F=C.useRef({top:j,dragging:v,pageY:x,startTop:O});F.current={top:j,dragging:v,pageY:x,startTop:O};var B=function(Y){y(!0),E(W2(Y,c)),A(F.current.top),a(),Y.stopPropagation(),Y.preventDefault()};C.useEffect(function(){var Y=function(re){re.preventDefault()},ie=M.current,K=N.current;return ie.addEventListener("touchstart",Y,{passive:!1}),K.addEventListener("touchstart",B,{passive:!1}),function(){ie.removeEventListener("touchstart",Y),K.removeEventListener("touchstart",B)}},[]);var z=C.useRef();z.current=V;var G=C.useRef();G.current=L,C.useEffect(function(){if(v){var Y,ie=function(re){var oe=F.current,ne=oe.dragging,ae=oe.pageY,de=oe.startTop;en.cancel(Y);var ge=M.current.getBoundingClientRect(),Se=d/(c?ge.width:ge.height);if(ne){var ye=(W2(re,c)-ae)*Se,be=de;!$&&c?be-=ye:be+=ye;var ce=z.current,he=G.current,Te=he?be/he:0,se=Math.ceil(Te*ce);se=Math.max(se,0),se=Math.min(se,ce),Y=en(function(){l(se,c)})}},K=function(){y(!1),s()};return window.addEventListener("mousemove",ie,{passive:!0}),window.addEventListener("touchmove",ie,{passive:!0}),window.addEventListener("mouseup",K,{passive:!0}),window.addEventListener("touchend",K,{passive:!0}),function(){window.removeEventListener("mousemove",ie),window.removeEventListener("touchmove",ie),window.removeEventListener("mouseup",K),window.removeEventListener("touchend",K),en.cancel(Y)}}},[v]),C.useEffect(function(){return H(),function(){clearTimeout(R.current)}},[o]),C.useImperativeHandle(t,function(){return{delayHidden:H}});var W="".concat(n,"-scrollbar"),q={position:"absolute",visibility:P?null:"hidden"},U={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(q,{height:8,left:0,right:0,bottom:0}),Object.assign(U,X({height:"100%",width:u},$?"left":"right",j))):(Object.assign(q,X({width:8,top:0,bottom:0},$?"right":"left",0)),Object.assign(U,{width:"100%",height:u,top:j})),C.createElement("div",{ref:M,className:me(W,X(X(X({},"".concat(W,"-horizontal"),c),"".concat(W,"-vertical"),!c),"".concat(W,"-visible"),P)),style:Q(Q({},q),f),onMouseDown:_,onMouseMove:H},C.createElement("div",{ref:N,className:me("".concat(W,"-thumb"),X({},"".concat(W,"-thumb-moving"),v)),style:Q(Q({},U),h),onMouseDown:B}))}),lZ=20;function _6(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=e/t*e;return isNaN(n)&&(n=0),n=Math.max(n,lZ),Math.floor(n)}var cZ=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],uZ=[],dZ={overflowY:"auto",overflowAnchor:"none"};function fZ(e,t){var n=e.prefixCls,r=n===void 0?"rc-virtual-list":n,o=e.className,i=e.height,a=e.itemHeight,s=e.fullHeight,l=s===void 0?!0:s,c=e.style,u=e.data,d=e.children,f=e.itemKey,h=e.virtual,m=e.direction,p=e.scrollWidth,g=e.component,v=g===void 0?"div":g,y=e.onScroll,b=e.onVirtualScroll,w=e.onVisibleChange,x=e.innerProps,E=e.extraRender,k=e.styles,S=e.showScrollBar,O=S===void 0?"optional":S,A=tn(e,cZ),$=C.useCallback(function(We){return typeof f=="function"?f(We):We==null?void 0:We[f]},[f]),M=rZ($),N=te(M,4),D=N[0],T=N[1],P=N[2],I=N[3],R=!!(h!==!1&&i&&a),H=C.useMemo(function(){return Object.values(P.maps).reduce(function(We,pt){return We+pt},0)},[P.id,P.maps]),V=R&&u&&(Math.max(a*u.length,H)>i||!!p),L=m==="rtl",j=me(r,X({},"".concat(r,"-rtl"),L),o),_=u||uZ,F=et(),B=et(),z=et(),G=nt(0),W=te(G,2),q=W[0],U=W[1],Y=nt(0),ie=te(Y,2),K=ie[0],re=ie[1],oe=nt(!1),ne=te(oe,2),ae=ne[0],de=ne[1],ge=function(){de(!0)},Se=function(){de(!1)},ye={getKey:$};function be(We){U(function(pt){var Ke;typeof We=="function"?Ke=We(pt):Ke=We;var rt=qe(Ke);return F.current.scrollTop=rt,rt})}var ce=et({start:0,end:_.length}),he=et(),Te=JK(_,$),se=te(Te,1),Pe=se[0];he.current=Pe;var De=C.useMemo(function(){if(!R)return{scrollHeight:void 0,start:0,end:_.length-1,offset:void 0};if(!V){var We;return{scrollHeight:((We=B.current)===null||We===void 0?void 0:We.offsetHeight)||0,start:0,end:_.length-1,offset:void 0}}for(var pt=0,Ke,rt,ht,an=_.length,dn=0;dn<an;dn+=1){var Un=_[dn],dr=$(Un),Nn=P.get(dr),Dn=pt+(Nn===void 0?a:Nn);Dn>=q&&Ke===void 0&&(Ke=dn,rt=pt),Dn>q+i&&ht===void 0&&(ht=dn),pt=Dn}return Ke===void 0&&(Ke=0,rt=0,ht=Math.ceil(i/a)),ht===void 0&&(ht=_.length-1),ht=Math.min(ht+1,_.length-1),{scrollHeight:pt,start:Ke,end:ht,offset:rt}},[V,R,q,_,I,i]),He=De.scrollHeight,ue=De.start,ve=De.end,xe=De.offset;ce.current.start=ue,ce.current.end=ve,C.useLayoutEffect(function(){var We=P.getRecord();if(We.size===1){var pt=Array.from(We.keys())[0],Ke=We.get(pt),rt=_[ue];if(rt&&Ke===void 0){var ht=$(rt);if(ht===pt){var an=P.get(pt),dn=an-a;be(function(Un){return Un+dn})}}}P.resetRecord()},[He]);var fe=C.useState({width:0,height:i}),pe=te(fe,2),ke=pe[0],Ve=pe[1],Ee=function(We){Ve({width:We.offsetWidth,height:We.offsetHeight})},yt=et(),Dt=et(),Pt=C.useMemo(function(){return _6(ke.width,p)},[ke.width,p]),Ut=C.useMemo(function(){return _6(ke.height,He)},[ke.height,He]),Ge=He-i,Xe=et(Ge);Xe.current=Ge;function qe(We){var pt=We;return Number.isNaN(Xe.current)||(pt=Math.min(pt,Xe.current)),pt=Math.max(pt,0),pt}var lt=q<=0,je=q>=Ge,Rt=K<=0,zt=K>=p,dt=gB(lt,je,Rt,zt),Ct=function(){return{x:L?-K:K,y:q}},jt=et(Ct()),Ie=cn(function(We){if(b){var pt=Q(Q({},Ct()),We);(jt.current.x!==pt.x||jt.current.y!==pt.y)&&(b(pt),jt.current=pt)}});function Ne(We,pt){var Ke=We;pt?(LE(function(){re(Ke)}),Ie()):be(Ke)}function Oe(We){var pt=We.currentTarget.scrollTop;pt!==q&&be(pt),y==null||y(We),Ie()}var _e=function(We){var pt=We,Ke=p?p-ke.width:0;return pt=Math.max(pt,0),pt=Math.min(pt,Ke),pt},mt=cn(function(We,pt){pt?(LE(function(){re(function(Ke){var rt=Ke+(L?-We:We);return _e(rt)})}),Ie()):be(function(Ke){var rt=Ke+We;return rt})}),kt=eZ(R,lt,je,Rt,zt,!!p,mt),It=te(kt,2),Xt=It[0],on=It[1];oZ(R,F,function(We,pt,Ke,rt){var ht=rt;return dt(We,pt,Ke)?!1:!ht||!ht._virtualHandled?(ht&&(ht._virtualHandled=!0),Xt({preventDefault:function(){},deltaX:We?pt:0,deltaY:We?0:pt}),!0):!1}),iZ(V,F,function(We){be(function(pt){return pt+We})}),mn(function(){function We(Ke){var rt=lt&&Ke.detail<0,ht=je&&Ke.detail>0;R&&!rt&&!ht&&Ke.preventDefault()}var pt=F.current;return pt.addEventListener("wheel",Xt,{passive:!1}),pt.addEventListener("DOMMouseScroll",on,{passive:!0}),pt.addEventListener("MozMousePixelScroll",We,{passive:!1}),function(){pt.removeEventListener("wheel",Xt),pt.removeEventListener("DOMMouseScroll",on),pt.removeEventListener("MozMousePixelScroll",We)}},[R,lt,je]),mn(function(){if(p){var We=_e(K);re(We),Ie({x:We})}},[ke.width,p]);var qt=function(){var We,pt;(We=yt.current)===null||We===void 0||We.delayHidden(),(pt=Dt.current)===null||pt===void 0||pt.delayHidden()},wn=sZ(F,_,P,a,$,function(){return T(!0)},be,qt);C.useImperativeHandle(t,function(){return{nativeElement:z.current,getScrollInfo:Ct,scrollTo:function(We){function pt(Ke){return Ke&&At(Ke)==="object"&&("left"in Ke||"top"in Ke)}pt(We)?(We.left!==void 0&&re(_e(We.left)),wn(We.top)):wn(We)}}}),mn(function(){if(w){var We=_.slice(ue,ve+1);w(We,_)}},[ue,ve,_]);var vn=tZ(_,$,P,a),Kt=E==null?void 0:E({start:ue,end:ve,virtual:V,offsetX:K,offsetY:xe,rtl:L,getSize:vn}),$n=ZK(_,ue,ve,p,K,D,d,ye),On=null;i&&(On=Q(X({},l?"height":"maxHeight",i),dZ),R&&(On.overflowY="hidden",p&&(On.overflowX="hidden"),ae&&(On.pointerEvents="none")));var ur={};return L&&(ur.dir="rtl"),C.createElement("div",Qe({ref:z,style:Q(Q({},c),{},{position:"relative"}),className:j},ur,A),C.createElement(ea,{onResize:Ee},C.createElement(v,{className:"".concat(r,"-holder"),style:On,ref:F,onScroll:Oe,onMouseEnter:qt},C.createElement(pB,{prefixCls:r,height:He,offsetX:K,offsetY:xe,scrollWidth:p,onInnerResize:T,ref:B,innerProps:x,rtl:L,extra:Kt},$n))),V&&He>i&&C.createElement(R6,{ref:yt,prefixCls:r,scrollOffset:q,scrollRange:He,rtl:L,onScroll:Ne,onStartMove:ge,onStopMove:Se,spinSize:Ut,containerSize:ke.height,style:k==null?void 0:k.verticalScrollBar,thumbStyle:k==null?void 0:k.verticalScrollBarThumb,showScrollBar:O}),V&&p>ke.width&&C.createElement(R6,{ref:Dt,prefixCls:r,scrollOffset:K,scrollRange:p,rtl:L,onScroll:Ne,onStartMove:ge,onStopMove:Se,spinSize:Pt,containerSize:ke.width,horizontal:!0,style:k==null?void 0:k.horizontalScrollBar,thumbStyle:k==null?void 0:k.horizontalScrollBarThumb,showScrollBar:O}))}var mB=C.forwardRef(fZ);mB.displayName="List";function hZ(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var pZ=["disabled","title","children","style","className"];function j6(e){return typeof e=="string"||typeof e=="number"}var gZ=function(e,t){var n=JX(),r=n.prefixCls,o=n.id,i=n.open,a=n.multiple,s=n.mode,l=n.searchValue,c=n.toggleOpen,u=n.notFoundContent,d=n.onPopupScroll,f=C.useContext(tk),h=f.maxCount,m=f.flattenOptions,p=f.onActiveValue,g=f.defaultActiveFirstOption,v=f.onSelect,y=f.menuItemSelectedIcon,b=f.rawValues,w=f.fieldNames,x=f.virtual,E=f.direction,k=f.listHeight,S=f.listItemHeight,O=f.optionRender,A="".concat(r,"-item"),$=up(function(){return m},[i,m],function(U,Y){return Y[0]&&U[1]!==Y[1]}),M=C.useRef(null),N=C.useMemo(function(){return a&&L2(h)&&(b==null?void 0:b.size)>=h},[a,h,b==null?void 0:b.size]),D=function(U){U.preventDefault()},T=function(U){var Y;(Y=M.current)===null||Y===void 0||Y.scrollTo(typeof U=="number"?{index:U}:U)},P=C.useCallback(function(U){return s==="combobox"?!1:b.has(U)},[s,ze(b).toString(),b.size]),I=function(U){for(var Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,ie=$.length,K=0;K<ie;K+=1){var re=(U+K*Y+ie)%ie,oe=$[re]||{},ne=oe.group,ae=oe.data;if(!ne&&!(ae!=null&&ae.disabled)&&(P(ae.value)||!N))return re}return-1},R=C.useState(function(){return I(0)}),H=te(R,2),V=H[0],L=H[1],j=function(U){var Y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;L(U);var ie={source:Y?"keyboard":"mouse"},K=$[U];if(!K){p(null,-1,ie);return}p(K.value,U,ie)};Et(function(){j(g!==!1?I(0):-1)},[$.length,l]);var _=C.useCallback(function(U){return s==="combobox"?String(U).toLowerCase()===l.toLowerCase():b.has(U)},[s,l,ze(b).toString(),b.size]);Et(function(){var U=setTimeout(function(){if(!a&&i&&b.size===1){var ie=Array.from(b)[0],K=$.findIndex(function(re){var oe=re.data;return l?String(oe.value).startsWith(l):oe.value===ie});K!==-1&&(j(K),T(K))}});if(i){var Y;(Y=M.current)===null||Y===void 0||Y.scrollTo(void 0)}return function(){return clearTimeout(U)}},[i,l]);var F=function(U){U!==void 0&&v(U,{selected:!b.has(U)}),a||c(!1)};if(C.useImperativeHandle(t,function(){return{onKeyDown:function(U){var Y=U.which,ie=U.ctrlKey;switch(Y){case St.N:case St.P:case St.UP:case St.DOWN:{var K=0;if(Y===St.UP?K=-1:Y===St.DOWN?K=1:hZ()&&ie&&(Y===St.N?K=1:Y===St.P&&(K=-1)),K!==0){var re=I(V+K,K);T(re),j(re,!0)}break}case St.TAB:case St.ENTER:{var oe,ne=$[V];ne&&!(ne!=null&&(oe=ne.data)!==null&&oe!==void 0&&oe.disabled)&&!N?F(ne.value):F(void 0),i&&U.preventDefault();break}case St.ESC:c(!1),i&&U.stopPropagation()}},onKeyUp:function(){},scrollTo:function(U){T(U)}}}),$.length===0)return C.createElement("div",{role:"listbox",id:"".concat(o,"_list"),className:"".concat(A,"-empty"),onMouseDown:D},u);var B=Object.keys(w).map(function(U){return w[U]}),z=function(U){return U.label};function G(U,Y){var ie=U.group;return{role:ie?"presentation":"option",id:"".concat(o,"_list_").concat(Y)}}var W=function(U){var Y=$[U];if(!Y)return null;var ie=Y.data||{},K=ie.value,re=Y.group,oe=Si(ie,!0),ne=z(Y);return Y?C.createElement("div",Qe({"aria-label":typeof ne=="string"&&!re?ne:null},oe,{key:U},G(Y,U),{"aria-selected":_(K)}),K):null},q={role:"listbox",id:"".concat(o,"_list")};return C.createElement(C.Fragment,null,x&&C.createElement("div",Qe({},q,{style:{height:0,width:0,overflow:"hidden"}}),W(V-1),W(V),W(V+1)),C.createElement(mB,{itemKey:"key",ref:M,data:$,height:k,itemHeight:S,fullHeight:!1,onMouseDown:D,onScroll:d,virtual:x,direction:E,innerProps:x?null:q},function(U,Y){var ie=U.group,K=U.groupOption,re=U.data,oe=U.label,ne=U.value,ae=re.key;if(ie){var de,ge=(de=re.title)!==null&&de!==void 0?de:j6(oe)?oe.toString():void 0;return C.createElement("div",{className:me(A,"".concat(A,"-group"),re.className),title:ge},oe!==void 0?oe:ae)}var Se=re.disabled,ye=re.title,be=re.style,ce=re.className,he=tn(re,pZ),Te=ta(he,B),se=P(ne),Pe=Se||!se&&N,De="".concat(A,"-option"),He=me(A,De,ce,X(X(X(X({},"".concat(De,"-grouped"),K),"".concat(De,"-active"),V===Y&&!Pe),"".concat(De,"-disabled"),Pe),"".concat(De,"-selected"),se)),ue=z(U),ve=!y||typeof y=="function"||se,xe=typeof ue=="number"?ue:ue||ne,fe=j6(xe)?xe.toString():void 0;return ye!==void 0&&(fe=ye),C.createElement("div",Qe({},Si(Te),x?{}:G(U,Y),{"aria-selected":_(ne),className:He,title:fe,onMouseMove:function(){V===Y||Pe||j(Y)},onClick:function(){Pe||F(ne)},style:be}),C.createElement("div",{className:"".concat(De,"-content")},typeof O=="function"?O(U,{index:Y}):xe),C.isValidElement(y)||se,ve&&C.createElement(Dp,{className:"".concat(A,"-option-state"),customizeIcon:y,customizeIconProps:{value:ne,disabled:Pe,isSelected:se}},se?"\u2713":null))}))},mZ=C.forwardRef(gZ);const vZ=(function(e,t){var n=C.useRef({values:new Map,options:new Map}),r=C.useMemo(function(){var i=n.current,a=i.values,s=i.options,l=e.map(function(d){if(d.label===void 0){var f;return Q(Q({},d),{},{label:(f=a.get(d.value))===null||f===void 0?void 0:f.label})}return d}),c=new Map,u=new Map;return l.forEach(function(d){c.set(d.value,d),u.set(d.value,t.get(d.value)||s.get(d.value))}),n.current.values=c,n.current.options=u,l},[e,t]),o=C.useCallback(function(i){return t.get(i)||n.current.options.get(i)},[t]);return[r,o]});function ym(e,t){return dB(e).join("").toUpperCase().includes(t)}const yZ=(function(e,t,n,r,o){return C.useMemo(function(){if(!n||r===!1)return e;var i=t.options,a=t.label,s=t.value,l=[],c=typeof r=="function",u=n.toUpperCase(),d=c?r:function(h,m){return o?ym(m[o],u):m[i]?ym(m[a!=="children"?a:"label"],u):ym(m[s],u)},f=c?function(h){return z2(h)}:function(h){return h};return e.forEach(function(h){if(h[i]){var m=d(n,f(h));if(m)l.push(h);else{var p=h[i].filter(function(g){return d(n,f(g))});p.length&&l.push(Q(Q({},h),{},X({},i,p)))}return}d(n,f(h))&&l.push(h)}),l},[e,r,o,n,t])});var L6=0,bZ=$o();function xZ(){var e;return bZ?(e=L6,L6+=1):e="TEST_OR_SSR",e}function EZ(e){var t=C.useState(),n=te(t,2),r=n[0],o=n[1];return C.useEffect(function(){o("rc_select_".concat(xZ()))},[]),e||r}var wZ=["children","value"],CZ=["children"];function kZ(e){var t=e,n=t.key,r=t.props,o=r.children,i=r.value,a=tn(r,wZ);return Q({key:n,value:i!==void 0?i:n,children:o},a)}function vB(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return fc(e).map(function(n,r){if(!C.isValidElement(n)||!n.type)return null;var o=n,i=o.type.isSelectOptGroup,a=o.key,s=o.props,l=s.children,c=tn(s,CZ);return t||!i?kZ(n):Q(Q({key:"__RC_SELECT_GRP__".concat(a===null?r:a,"__"),label:a},c),{},{options:vB(l)})}).filter(function(n){return n})}var SZ=function(e,t,n,r,o){return C.useMemo(function(){var i=e,a=!e;a&&(i=vB(t));var s=new Map,l=new Map,c=function(d,f,h){h&&typeof h=="string"&&d.set(f[h],f)},u=function d(f){for(var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,m=0;m<f.length;m+=1){var p=f[m];!p[n.options]||h?(s.set(p[n.value],p),c(l,p,n.label),c(l,p,r),c(l,p,o)):d(p[n.options],!0)}};return u(i),{options:i,valueOptions:s,labelOptions:l}},[e,t,n,r,o])};function z6(e){var t=C.useRef();t.current=e;var n=C.useCallback(function(){return t.current.apply(t,arguments)},[]);return n}var AZ=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],$Z=["inputValue"];function OZ(e){return!e||At(e)!=="object"}var MZ=C.forwardRef(function(e,t){var n=e.id,r=e.mode,o=e.prefixCls,i=o===void 0?"rc-select":o,a=e.backfill,s=e.fieldNames,l=e.inputValue,c=e.searchValue,u=e.onSearch,d=e.autoClearSearchValue,f=d===void 0?!0:d,h=e.onSelect,m=e.onDeselect,p=e.dropdownMatchSelectWidth,g=p===void 0?!0:p,v=e.filterOption,y=e.filterSort,b=e.optionFilterProp,w=e.optionLabelProp,x=e.options,E=e.optionRender,k=e.children,S=e.defaultActiveFirstOption,O=e.menuItemSelectedIcon,A=e.virtual,$=e.direction,M=e.listHeight,N=M===void 0?200:M,D=e.listItemHeight,T=D===void 0?20:D,P=e.labelRender,I=e.value,R=e.defaultValue,H=e.labelInValue,V=e.onChange,L=e.maxCount,j=tn(e,AZ),_=EZ(n),F=H2(r),B=!!(!x&&k),z=C.useMemo(function(){return v===void 0&&r==="combobox"?!1:v},[v,r]),G=C.useMemo(function(){return hB(s,B)},[JSON.stringify(s),B]),W=yr("",{value:c!==void 0?c:l,postState:function(Ie){return Ie||""}}),q=te(W,2),U=q[0],Y=q[1],ie=SZ(x,k,G,b,w),K=ie.valueOptions,re=ie.labelOptions,oe=ie.options,ne=C.useCallback(function(Ie){var Ne=dB(Ie);return Ne.map(function(Oe){var _e,mt,kt,It,Xt;if(OZ(Oe))_e=Oe;else{var on;kt=Oe.key,mt=Oe.label,_e=(on=Oe.value)!==null&&on!==void 0?on:kt}var qt=K.get(_e);if(qt){var wn;mt===void 0&&(mt=qt==null?void 0:qt[w||G.label]),kt===void 0&&(kt=(wn=qt==null?void 0:qt.key)!==null&&wn!==void 0?wn:_e),It=qt==null?void 0:qt.disabled,Xt=qt==null?void 0:qt.title}return{label:mt,value:_e,key:kt,disabled:It,title:Xt}})},[G,w,K]),ae=yr(R,{value:I}),de=te(ae,2),ge=de[0],Se=de[1],ye=C.useMemo(function(){var Ie,Ne=F&&ge===null?[]:ge,Oe=ne(Ne);return r==="combobox"&&xK((Ie=Oe[0])===null||Ie===void 0?void 0:Ie.value)?[]:Oe},[ge,ne,r,F]),be=vZ(ye,K),ce=te(be,2),he=ce[0],Te=ce[1],se=C.useMemo(function(){if(!r&&he.length===1){var Ie=he[0];if(Ie.value===null&&(Ie.label===null||Ie.label===void 0))return[]}return he.map(function(Ne){var Oe;return Q(Q({},Ne),{},{label:(Oe=typeof P=="function"?P(Ne):Ne.label)!==null&&Oe!==void 0?Oe:Ne.value})})},[r,he,P]),Pe=C.useMemo(function(){return new Set(he.map(function(Ie){return Ie.value}))},[he]);C.useEffect(function(){if(r==="combobox"){var Ie,Ne=(Ie=he[0])===null||Ie===void 0?void 0:Ie.value;Y(bK(Ne)?String(Ne):"")}},[he]);var De=z6(function(Ie,Ne){var Oe=Ne??Ie;return X(X({},G.value,Ie),G.label,Oe)}),He=C.useMemo(function(){if(r!=="tags")return oe;var Ie=ze(oe),Ne=function(Oe){return K.has(Oe)};return ze(he).sort(function(Oe,_e){return Oe.value<_e.value?-1:1}).forEach(function(Oe){var _e=Oe.value;Ne(_e)||Ie.push(De(_e,Oe.label))}),Ie},[De,oe,K,he,r]),ue=yZ(He,G,U,z,b),ve=C.useMemo(function(){return r!=="tags"||!U||ue.some(function(Ie){return Ie[b||"value"]===U})||ue.some(function(Ie){return Ie[G.value]===U})?ue:[De(U)].concat(ze(ue))},[De,b,r,ue,U,G]),xe=function Ie(Ne){var Oe=ze(Ne).sort(function(_e,mt){return y(_e,mt,{searchValue:U})});return Oe.map(function(_e){return Array.isArray(_e.options)?Q(Q({},_e),{},{options:_e.options.length>0?Ie(_e.options):_e.options}):_e})},fe=C.useMemo(function(){return y?xe(ve):ve},[ve,y,U]),pe=C.useMemo(function(){return VK(fe,{fieldNames:G,childrenAsData:B})},[fe,G,B]),ke=function(Ie){var Ne=ne(Ie);if(Se(Ne),V&&(Ne.length!==he.length||Ne.some(function(mt,kt){var It;return((It=he[kt])===null||It===void 0?void 0:It.value)!==(mt==null?void 0:mt.value)}))){var Oe=H?Ne:Ne.map(function(mt){return mt.value}),_e=Ne.map(function(mt){return z2(Te(mt.value))});V(F?Oe:Oe[0],F?_e:_e[0])}},Ve=C.useState(null),Ee=te(Ve,2),yt=Ee[0],Dt=Ee[1],Pt=C.useState(0),Ut=te(Pt,2),Ge=Ut[0],Xe=Ut[1],qe=S!==void 0?S:r!=="combobox",lt=C.useCallback(function(Ie,Ne){var Oe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},_e=Oe.source,mt=_e===void 0?"keyboard":_e;Xe(Ne),a&&r==="combobox"&&Ie!==null&&mt==="keyboard"&&Dt(String(Ie))},[a,r]),je=function(Ie,Ne,Oe){var _e=function(){var Kt,$n=Te(Ie);return[H?{label:$n==null?void 0:$n[G.label],value:Ie,key:(Kt=$n==null?void 0:$n.key)!==null&&Kt!==void 0?Kt:Ie}:Ie,z2($n)]};if(Ne&&h){var mt=_e(),kt=te(mt,2),It=kt[0],Xt=kt[1];h(It,Xt)}else if(!Ne&&m&&Oe!=="clear"){var on=_e(),qt=te(on,2),wn=qt[0],vn=qt[1];m(wn,vn)}},Rt=z6(function(Ie,Ne){var Oe,_e=F?Ne.selected:!0;_e?Oe=F?[].concat(ze(he),[Ie]):[Ie]:Oe=he.filter(function(mt){return mt.value!==Ie}),ke(Oe),je(Ie,_e),r==="combobox"?Dt(""):(!H2||f)&&(Y(""),Dt(""))}),zt=function(Ie,Ne){ke(Ie);var Oe=Ne.type,_e=Ne.values;(Oe==="remove"||Oe==="clear")&&_e.forEach(function(mt){je(mt.value,!1,Oe)})},dt=function(Ie,Ne){if(Y(Ie),Dt(null),Ne.source==="submit"){var Oe=(Ie||"").trim();if(Oe){var _e=Array.from(new Set([].concat(ze(Pe),[Oe])));ke(_e),je(Oe,!0),Y("")}return}Ne.source!=="blur"&&(r==="combobox"&&ke(Ie),u==null||u(Ie))},Ct=function(Ie){var Ne=Ie;r!=="tags"&&(Ne=Ie.map(function(_e){var mt=re.get(_e);return mt==null?void 0:mt.value}).filter(function(_e){return _e!==void 0}));var Oe=Array.from(new Set([].concat(ze(Pe),ze(Ne))));ke(Oe),Oe.forEach(function(_e){je(_e,!0)})},jt=C.useMemo(function(){var Ie=A!==!1&&g!==!1;return Q(Q({},ie),{},{flattenOptions:pe,onActiveValue:lt,defaultActiveFirstOption:qe,onSelect:Rt,menuItemSelectedIcon:O,rawValues:Pe,fieldNames:G,virtual:Ie,direction:$,listHeight:N,listItemHeight:T,childrenAsData:B,maxCount:L,optionRender:E})},[L,ie,pe,lt,qe,Rt,O,Pe,G,A,g,$,N,T,B,E]);return C.createElement(tk.Provider,{value:jt},C.createElement(XK,Qe({},j,{id:_,prefixCls:i,ref:t,omitDomProps:$Z,mode:r,displayValues:se,onDisplayValuesChange:zt,direction:$,searchValue:U,onSearch:dt,autoClearSearchValue:f,onSearchSplit:Ct,dropdownMatchSelectWidth:g,OptionList:mZ,emptyOptions:!pe.length,activeValue:yt,activeDescendantId:"".concat(_,"_list_").concat(Ge)})))}),ok=MZ;ok.Option=rk;ok.OptGroup=nk;function ns(e,t,n){return me({[`${e}-status-success`]:t==="success",[`${e}-status-warning`]:t==="warning",[`${e}-status-error`]:t==="error",[`${e}-status-validating`]:t==="validating",[`${e}-has-feedback`]:n})}const pl=(e,t)=>t||e,NZ=()=>{const[,e]=ii(),[t]=dl("Empty"),n=new Sn(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return C.createElement("svg",{style:n,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},C.createElement("title",null,(t==null?void 0:t.description)||"Empty"),C.createElement("g",{fill:"none",fillRule:"evenodd"},C.createElement("g",{transform:"translate(24 31.67)"},C.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),C.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),C.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),C.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),C.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),C.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),C.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},C.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),C.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},DZ=()=>{const[,e]=ii(),[t]=dl("Empty"),{colorFill:n,colorFillTertiary:r,colorFillQuaternary:o,colorBgContainer:i}=e,{borderColor:a,shadowColor:s,contentColor:l}=Gt(()=>({borderColor:new Sn(n).onBackground(i).toHexString(),shadowColor:new Sn(r).onBackground(i).toHexString(),contentColor:new Sn(o).onBackground(i).toHexString()}),[n,r,o,i]);return C.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},C.createElement("title",null,(t==null?void 0:t.description)||"Empty"),C.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},C.createElement("ellipse",{fill:s,cx:"32",cy:"33",rx:"32",ry:"7"}),C.createElement("g",{fillRule:"nonzero",stroke:a},C.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),C.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:l}))))},TZ=e=>{const{componentCls:t,margin:n,marginXS:r,marginXL:o,fontSize:i,lineHeight:a}=e;return{[t]:{marginInline:r,fontSize:i,lineHeight:a,textAlign:"center",[`${t}-image`]:{height:e.emptyImgHeight,marginBottom:r,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${t}-description`]:{color:e.colorTextDescription},[`${t}-footer`]:{marginTop:n},"&-normal":{marginBlock:o,color:e.colorTextDescription,[`${t}-description`]:{color:e.colorTextDescription},[`${t}-image`]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:r,color:e.colorTextDescription,[`${t}-image`]:{height:e.emptyImgHeightSM}}}}},FZ=Pr("Empty",e=>{const{componentCls:t,controlHeightLG:n,calc:r}=e,o=Mn(e,{emptyImgCls:`${t}-img`,emptyImgHeight:r(n).mul(2.5).equal(),emptyImgHeightMD:n,emptyImgHeightSM:r(n).mul(.875).equal()});return TZ(o)});var PZ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const yB=C.createElement(NZ,null),bB=C.createElement(DZ,null),Ds=e=>{var t;const{className:n,rootClassName:r,prefixCls:o,image:i,description:a,children:s,imageStyle:l,style:c,classNames:u,styles:d}=e,f=PZ(e,["className","rootClassName","prefixCls","image","description","children","imageStyle","style","classNames","styles"]),{getPrefixCls:h,direction:m,className:p,style:g,classNames:v,styles:y,image:b}=xa("empty"),w=h("empty",o),[x,E,k]=FZ(w),[S]=dl("Empty"),O=typeof a<"u"?a:S==null?void 0:S.description,A=typeof O=="string"?O:"empty",$=(t=i??b)!==null&&t!==void 0?t:yB;let M=null;return typeof $=="string"?M=C.createElement("img",{draggable:!1,alt:A,src:$}):M=$,x(C.createElement("div",Object.assign({className:me(E,k,w,p,{[`${w}-normal`]:$===bB,[`${w}-rtl`]:m==="rtl"},n,r,v.root,u==null?void 0:u.root),style:Object.assign(Object.assign(Object.assign(Object.assign({},y.root),g),d==null?void 0:d.root),c)},f),C.createElement("div",{className:me(`${w}-image`,v.image,u==null?void 0:u.image),style:Object.assign(Object.assign(Object.assign({},l),y.image),d==null?void 0:d.image)},M),O&&C.createElement("div",{className:me(`${w}-description`,v.description,u==null?void 0:u.description),style:Object.assign(Object.assign({},y.description),d==null?void 0:d.description)},O),s&&C.createElement("div",{className:me(`${w}-footer`,v.footer,u==null?void 0:u.footer),style:Object.assign(Object.assign({},y.footer),d==null?void 0:d.footer)},s)))};Ds.PRESENTED_IMAGE_DEFAULT=yB;Ds.PRESENTED_IMAGE_SIMPLE=bB;const IZ=e=>{const{componentName:t}=e,{getPrefixCls:n}=pr(pn),r=n("empty");switch(t){case"Table":case"List":return we.createElement(Ds,{image:Ds.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return we.createElement(Ds,{image:Ds.PRESENTED_IMAGE_SIMPLE,className:`${r}-small`});case"Table.filter":return null;default:return we.createElement(Ds,null)}},Pc=(e,t,n)=>{var r,o;const{variant:i,[e]:a}=C.useContext(pn),s=C.useContext(oB),l=a==null?void 0:a.variant;let c;typeof t<"u"?c=t:n===!1?c="borderless":c=(o=(r=s??l)!==null&&r!==void 0?r:i)!==null&&o!==void 0?o:"outlined";const u=zV.includes(c);return[c,u]},BZ=e=>{const t={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:e==="scroll"?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},t),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},t),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},t),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},t),{points:["br","tr"],offset:[0,-4]})}};function RZ(e,t){return e||BZ(t)}const H6=e=>{const{optionHeight:t,optionFontSize:n,optionLineHeight:r,optionPadding:o}=e;return{position:"relative",display:"block",minHeight:t,padding:o,color:e.colorText,fontWeight:"normal",fontSize:n,lineHeight:r,boxSizing:"border-box"}},_Z=e=>{const{antCls:t,componentCls:n}=e,r=`${n}-item`,o=`&${t}-slide-up-enter${t}-slide-up-enter-active`,i=`&${t}-slide-up-appear${t}-slide-up-appear-active`,a=`&${t}-slide-up-leave${t}-slide-up-leave-active`,s=`${n}-dropdown-placement-`,l=`${r}-option-selected`;return[{[`${n}-dropdown`]:Object.assign(Object.assign({},br(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,[`
|
|
288
288
|
${o}${s}bottomLeft,
|
|
289
289
|
${i}${s}bottomLeft
|
|
290
290
|
`]:{animationName:zC},[`
|
|
@@ -310,7 +310,7 @@ html body {
|
|
|
310
310
|
`]:{paddingInlineEnd:e.showArrowPaddingInlineEnd},[`&${n}-open ${n}-selection-item`]:{color:e.colorTextPlaceholder},[`&:not(${n}-customize-input)`]:{[`${n}-selector`]:{width:"100%",height:"100%",alignItems:"center",padding:`0 ${Ce(r)}`,[`${n}-selection-search-input`]:{height:i,fontSize:e.fontSize},"&:after":{lineHeight:Ce(i)}}},[`&${n}-customize-input`]:{[`${n}-selector`]:{"&:after":{display:"none"},[`${n}-selection-search`]:{position:"static",width:"100%"},[`${n}-selection-placeholder`]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:`0 ${Ce(r)}`,"&:after":{display:"none"}}}}}}}function HZ(e){const{componentCls:t}=e,n=e.calc(e.controlPaddingHorizontalSM).sub(e.lineWidth).equal();return[xm(e),xm(Mn(e,{controlHeight:e.controlHeightSM,borderRadius:e.borderRadiusSM}),"sm"),{[`${t}-single${t}-sm`]:{[`&:not(${t}-customize-input)`]:{[`${t}-selector`]:{padding:`0 ${Ce(n)}`},[`&${t}-show-arrow ${t}-selection-search`]:{insetInlineEnd:e.calc(n).add(e.calc(e.fontSize).mul(1.5)).equal()},[`
|
|
311
311
|
&${t}-show-arrow ${t}-selection-item,
|
|
312
312
|
&${t}-show-arrow ${t}-selection-placeholder
|
|
313
|
-
`]:{paddingInlineEnd:e.calc(e.fontSize).mul(1.5).equal()}}}},xm(Mn(e,{controlHeight:e.singleItemHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG}),"lg")]}const WZ=e=>{const{fontSize:t,lineHeight:n,lineWidth:r,controlHeight:o,controlHeightSM:i,controlHeightLG:a,paddingXXS:s,controlPaddingHorizontal:l,zIndexPopupBase:c,colorText:u,fontWeightStrong:d,controlItemBgActive:f,controlItemBgHover:h,colorBgContainer:m,colorFillSecondary:p,colorBgContainerDisabled:g,colorTextDisabled:v,colorPrimaryHover:y,colorPrimary:b,controlOutline:w}=e,x=s*2,E=r*2,k=Math.min(o-x,o-E),S=Math.min(i-x,i-E),O=Math.min(a-x,a-E);return{INTERNAL_FIXED_ITEM_MARGIN:Math.floor(s/2),zIndexPopup:c+50,optionSelectedColor:u,optionSelectedFontWeight:d,optionSelectedBg:f,optionActiveBg:h,optionPadding:`${(o-t*n)/2}px ${l}px`,optionFontSize:t,optionLineHeight:n,optionHeight:o,selectorBg:m,clearBg:m,singleItemHeightLG:a,multipleItemBg:p,multipleItemBorderColor:"transparent",multipleItemHeight:k,multipleItemHeightSM:S,multipleItemHeightLG:O,multipleSelectorBgDisabled:g,multipleItemColorDisabled:v,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(e.fontSize*1.25),hoverBorderColor:y,activeBorderColor:b,activeOutlineColor:w,selectAffixPadding:s}},wB=(e,t)=>{const{componentCls:n,antCls:r,controlOutlineWidth:o}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{border:`${Ce(e.lineWidth)} ${e.lineType} ${t.borderColor}`,background:e.selectorBg},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{borderColor:t.hoverBorderHover},[`${n}-focused& ${n}-selector`]:{borderColor:t.activeBorderColor,boxShadow:`0 0 0 ${Ce(o)} ${t.activeOutlineColor}`,outline:0},[`${n}-prefix`]:{color:t.color}}}},W6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},wB(e,t))}),VZ=e=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},wB(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeOutlineColor:e.activeOutlineColor,color:e.colorText})),W6(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,activeOutlineColor:e.colorErrorOutline,color:e.colorError})),W6(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,activeOutlineColor:e.colorWarningOutline,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),CB=(e,t)=>{const{componentCls:n,antCls:r}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{background:t.bg,border:`${Ce(e.lineWidth)} ${e.lineType} transparent`,color:t.color},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{background:t.hoverBg},[`${n}-focused& ${n}-selector`]:{background:e.selectorBg,borderColor:t.activeBorderColor,outline:0}}}},V6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},CB(e,t))}),GZ=e=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},CB(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor,color:e.colorText})),V6(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,color:e.colorError})),V6(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{borderColor:e.colorBorder,background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.colorBgContainer,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorSplit}`}})}),UZ=e=>({"&-borderless":{[`${e.componentCls}-selector`]:{background:"transparent",border:`${Ce(e.lineWidth)} ${e.lineType} transparent`},[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`},[`&${e.componentCls}-status-error`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorError}},[`&${e.componentCls}-status-warning`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorWarning}}}}),kB=(e,t)=>{const{componentCls:n,antCls:r}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{borderWidth:`0 0 ${Ce(e.lineWidth)} 0`,borderStyle:`none none ${e.lineType} none`,borderColor:t.borderColor,background:e.selectorBg,borderRadius:0},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{borderColor:t.hoverBorderHover},[`${n}-focused& ${n}-selector`]:{borderColor:t.activeBorderColor,outline:0},[`${n}-prefix`]:{color:t.color}}}},G6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},kB(e,t))}),qZ=e=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign({},kB(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,color:e.colorText})),G6(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,color:e.colorError})),G6(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),YZ=e=>({[e.componentCls]:Object.assign(Object.assign(Object.assign(Object.assign({},VZ(e)),GZ(e)),UZ(e)),qZ(e))}),XZ=e=>{const{componentCls:t}=e;return{position:"relative",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,input:{cursor:"pointer"},[`${t}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},[`${t}-disabled&`]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},KZ=e=>{const{componentCls:t}=e;return{[`${t}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},ZZ=e=>{const{antCls:t,componentCls:n,inputPaddingHorizontalBase:r,iconCls:o}=e,i={[`${n}-clear`]:{opacity:1,background:e.colorBgBase,borderRadius:"50%"}};return{[n]:Object.assign(Object.assign({},br(e)),{position:"relative",display:"inline-flex",cursor:"pointer",[`&:not(${n}-customize-input) ${n}-selector`]:Object.assign(Object.assign({},XZ(e)),KZ(e)),[`${n}-selection-item`]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},c0),{[`> ${t}-typography`]:{display:"inline"}}),[`${n}-selection-placeholder`]:Object.assign(Object.assign({},c0),{flex:1,color:e.colorTextPlaceholder,pointerEvents:"none"}),[`${n}-arrow`]:Object.assign(Object.assign({},kd()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:`opacity ${e.motionDurationSlow} ease`,[o]:{verticalAlign:"top",transition:`transform ${e.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${n}-suffix)`]:{pointerEvents:"auto"}},[`${n}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${n}-selection-wrap`]:{display:"flex",width:"100%",position:"relative",minWidth:0,"&:after":{content:'"\\a0"',width:0,overflow:"hidden"}},[`${n}-prefix`]:{flex:"none",marginInlineEnd:e.selectAffixPadding},[`${n}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,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 ${e.motionDurationMid} ease, opacity ${e.motionDurationSlow} ease`,textRendering:"auto",transform:"translateZ(0)","&:before":{display:"block"},"&:hover":{color:e.colorIcon}},"@media(hover:none)":i,"&:hover":i}),[`${n}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${n}-has-feedback`]:{[`${n}-clear`]:{insetInlineEnd:e.calc(r).add(e.fontSize).add(e.paddingXS).equal()}}}}}},QZ=e=>{const{componentCls:t}=e;return[{[t]:{[`&${t}-in-form-item`]:{width:"100%"}}},ZZ(e),HZ(e),zZ(e),_Z(e),{[`${t}-rtl`]:{direction:"rtl"}},$d(e,{borderElCls:`${t}-selector`,focusElCls:`${t}-focused`})]},JZ=Pr("Select",(e,{rootPrefixCls:t})=>{const n=Mn(e,{rootPrefixCls:t,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[QZ(n),YZ(n)]},WZ,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}});var eQ={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"},tQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:eQ}))},nQ=C.forwardRef(tQ),rQ={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"},oQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:rQ}))},SB=C.forwardRef(oQ),iQ={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"},aQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:iQ}))},AB=C.forwardRef(aQ);function $B({suffixIcon:e,clearIcon:t,menuItemSelectedIcon:n,removeIcon:r,loading:o,multiple:i,hasFeedback:a,prefixCls:s,showSuffixIcon:l,feedbackIcon:c,showArrow:u,componentName:d}){const f=t??C.createElement(bp,null),h=v=>e===null&&!a&&!u?null:C.createElement(C.Fragment,null,l!==!1&&v,a&&c);let m=null;if(e!==void 0)m=h(e);else if(o)m=h(C.createElement(Sd,{spin:!0}));else{const v=`${s}-suffix`;m=({open:y,showSearch:b})=>h(y&&b?C.createElement(AB,{className:v}):C.createElement(SB,{className:v}))}let p=null;n!==void 0?p=n:i?p=C.createElement(nQ,null):p=null;let g=null;return r!==void 0?g=r:g=C.createElement(BC,null),{clearIcon:f,suffixIcon:m,itemIcon:p,removeIcon:g}}function sQ(e){return we.useMemo(()=>{if(e)return(...t)=>we.createElement(ts,{space:!0},e.apply(void 0,t))},[e])}function lQ(e,t){return t!==void 0?t:e!==null}var cQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const OB="SECRET_COMBOBOX_MODE_DO_NOT_USE",uQ=(e,t)=>{var n,r,o,i,a;const{prefixCls:s,bordered:l,className:c,rootClassName:u,getPopupContainer:d,popupClassName:f,dropdownClassName:h,listHeight:m=256,placement:p,listItemHeight:g,size:v,disabled:y,notFoundContent:b,status:w,builtinPlacements:x,dropdownMatchSelectWidth:E,popupMatchSelectWidth:k,direction:S,style:O,allowClear:A,variant:$,dropdownStyle:M,transitionName:N,tagRender:D,maxCount:T,prefix:P,dropdownRender:I,popupRender:R,onDropdownVisibleChange:H,onOpenChange:V,styles:L,classNames:j}=e,_=cQ(e,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount","prefix","dropdownRender","popupRender","onDropdownVisibleChange","onOpenChange","styles","classNames"]),{getPopupContainer:F,getPrefixCls:B,renderEmpty:z,direction:G,virtual:W,popupMatchSelectWidth:q,popupOverflow:U}=C.useContext(pn),{showSearch:Y,style:ie,styles:K,className:re,classNames:oe}=xa("select"),[,ne]=ii(),ae=g??(ne==null?void 0:ne.controlHeight),de=B("select",s),ge=B(),Se=S??G,{compactSize:ye,compactItemClassnames:be}=ps(de,Se),[ce,he]=Pc("select",$,l),Te=Ro(de),[se,Pe,De]=JZ(de,Te),He=C.useMemo(()=>{const{mode:_e}=e;if(_e!=="combobox")return _e===OB?"combobox":_e},[e.mode]),ue=He==="multiple"||He==="tags",ve=lQ(e.suffixIcon,e.showArrow),xe=(n=k??E)!==null&&n!==void 0?n:q,fe=((r=L==null?void 0:L.popup)===null||r===void 0?void 0:r.root)||((o=K.popup)===null||o===void 0?void 0:o.root)||M,pe=sQ(R||I),ke=V||H,{status:Ve,hasFeedback:Ee,isFormItemInput:yt,feedbackIcon:Dt}=C.useContext(Yr),Ft=pl(Ve,w);let Ut;b!==void 0?Ut=b:He==="combobox"?Ut=null:Ut=(z==null?void 0:z("Select"))||C.createElement(IZ,{componentName:"Select"});const{suffixIcon:Ge,itemIcon:Xe,removeIcon:qe,clearIcon:lt}=$B(Object.assign(Object.assign({},_),{multiple:ue,hasFeedback:Ee,feedbackIcon:Dt,showSuffixIcon:ve,prefixCls:de,componentName:"Select"})),je=A===!0?{clearIcon:lt}:A,Rt=ta(_,["suffixIcon","itemIcon"]),zt=me(((i=j==null?void 0:j.popup)===null||i===void 0?void 0:i.root)||((a=oe==null?void 0:oe.popup)===null||a===void 0?void 0:a.root)||f||h,{[`${de}-dropdown-${Se}`]:Se==="rtl"},u,oe.root,j==null?void 0:j.root,De,Te,Pe),dt=ai(_e=>{var mt;return(mt=v??ye)!==null&&mt!==void 0?mt:_e}),Ct=C.useContext(vo),jt=y??Ct,Ie=me({[`${de}-lg`]:dt==="large",[`${de}-sm`]:dt==="small",[`${de}-rtl`]:Se==="rtl",[`${de}-${ce}`]:he,[`${de}-in-form-item`]:yt},ns(de,Ft,Ee),be,re,c,oe.root,j==null?void 0:j.root,u,De,Te,Pe),Ne=C.useMemo(()=>p!==void 0?p:Se==="rtl"?"bottomRight":"bottomLeft",[p,Se]),[Oe]=xp("SelectLike",fe==null?void 0:fe.zIndex);return se(C.createElement(ok,Object.assign({ref:t,virtual:W,showSearch:Y},Rt,{style:Object.assign(Object.assign(Object.assign(Object.assign({},K.root),L==null?void 0:L.root),ie),O),dropdownMatchSelectWidth:xe,transitionName:LI(ge,"slide-up",N),builtinPlacements:RZ(x,U),listHeight:m,listItemHeight:ae,mode:He,prefixCls:de,placement:Ne,direction:Se,prefix:P,suffixIcon:Ge,menuItemSelectedIcon:Xe,removeIcon:qe,allowClear:je,notFoundContent:Ut,className:Ie,getPopupContainer:d||F,dropdownClassName:zt,disabled:jt,dropdownStyle:Object.assign(Object.assign({},fe),{zIndex:Oe}),maxCount:ue?T:void 0,tagRender:ue?D:void 0,dropdownRender:pe,onDropdownVisibleChange:ke})))},gl=C.forwardRef(uQ),dQ=QC(gl,"dropdownAlign");gl.SECRET_COMBOBOX_MODE_DO_NOT_USE=OB;gl.Option=rk;gl.OptGroup=nk;gl._InternalPanelDoNotUseOrYouWillBeFired=dQ;const fQ=(e,t)=>{typeof(e==null?void 0:e.addEventListener)<"u"?e.addEventListener("change",t):typeof(e==null?void 0:e.addListener)<"u"&&e.addListener(t)},hQ=(e,t)=>{typeof(e==null?void 0:e.removeEventListener)<"u"?e.removeEventListener("change",t):typeof(e==null?void 0:e.removeListener)<"u"&&e.removeListener(t)},rd=["xxl","xl","lg","md","sm","xs"],pQ=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)`}),gQ=e=>{const t=e,n=[].concat(rd).reverse();return n.forEach((r,o)=>{const i=r.toUpperCase(),a=`screen${i}Min`,s=`screen${i}`;if(!(t[a]<=t[s]))throw new Error(`${a}<=${s} fails : !(${t[a]}<=${t[s]})`);if(o<n.length-1){const l=`screen${i}Max`;if(!(t[s]<=t[l]))throw new Error(`${s}<=${l} fails : !(${t[s]}<=${t[l]})`);const c=`screen${n[o+1].toUpperCase()}Min`;if(!(t[l]<=t[c]))throw new Error(`${l}<=${c} fails : !(${t[l]}<=${t[c]})`)}}),e},mQ=()=>{const[,e]=ii(),t=pQ(gQ(e));return we.useMemo(()=>{const n=new Map;let r=-1,o={};return{responsiveMap:t,matchHandlers:{},dispatch(i){return o=i,n.forEach(a=>a(o)),n.size>=1},subscribe(i){return n.size||this.register(),r+=1,n.set(r,i),i(o),r},unsubscribe(i){n.delete(i),n.size||this.unregister()},register(){Object.entries(t).forEach(([i,a])=>{const s=({matches:c})=>{this.dispatch(Object.assign(Object.assign({},o),{[i]:c}))},l=window.matchMedia(a);fQ(l,s),this.matchHandlers[a]={mql:l,listener:s},s(l)})},unregister(){Object.values(t).forEach(i=>{const a=this.matchHandlers[i];hQ(a==null?void 0:a.mql,a==null?void 0:a.listener)}),n.clear()}}},[t])};function vQ(e=!0,t={}){const n=et(t),[,r]=RU(),o=mQ();return mn(()=>{const i=o.subscribe(a=>{n.current=a,e&&r()});return()=>o.unsubscribe(i)},[]),n.current}function MB(e){var t=e.children,n=e.prefixCls,r=e.id,o=e.overlayInnerStyle,i=e.bodyClassName,a=e.className,s=e.style;return C.createElement("div",{className:me("".concat(n,"-content"),a),style:s},C.createElement("div",{className:me("".concat(n,"-inner"),i),id:r,role:"tooltip",style:o},typeof t=="function"?t():t))}var Fl={shiftX:64,adjustY:1},Pl={adjustX:1,shiftY:!0},zo=[0,0],yQ={left:{points:["cr","cl"],overflow:Pl,offset:[-4,0],targetOffset:zo},right:{points:["cl","cr"],overflow:Pl,offset:[4,0],targetOffset:zo},top:{points:["bc","tc"],overflow:Fl,offset:[0,-4],targetOffset:zo},bottom:{points:["tc","bc"],overflow:Fl,offset:[0,4],targetOffset:zo},topLeft:{points:["bl","tl"],overflow:Fl,offset:[0,-4],targetOffset:zo},leftTop:{points:["tr","tl"],overflow:Pl,offset:[-4,0],targetOffset:zo},topRight:{points:["br","tr"],overflow:Fl,offset:[0,-4],targetOffset:zo},rightTop:{points:["tl","tr"],overflow:Pl,offset:[4,0],targetOffset:zo},bottomRight:{points:["tr","br"],overflow:Fl,offset:[0,4],targetOffset:zo},rightBottom:{points:["bl","br"],overflow:Pl,offset:[4,0],targetOffset:zo},bottomLeft:{points:["tl","bl"],overflow:Fl,offset:[0,4],targetOffset:zo},leftBottom:{points:["br","bl"],overflow:Pl,offset:[-4,0],targetOffset:zo}},bQ=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow","classNames","styles"],xQ=function(e,t){var n=e.overlayClassName,r=e.trigger,o=r===void 0?["hover"]:r,i=e.mouseEnterDelay,a=i===void 0?0:i,s=e.mouseLeaveDelay,l=s===void 0?.1:s,c=e.overlayStyle,u=e.prefixCls,d=u===void 0?"rc-tooltip":u,f=e.children,h=e.onVisibleChange,m=e.afterVisibleChange,p=e.transitionName,g=e.animation,v=e.motion,y=e.placement,b=y===void 0?"right":y,w=e.align,x=w===void 0?{}:w,E=e.destroyTooltipOnHide,k=E===void 0?!1:E,S=e.defaultVisible,O=e.getTooltipContainer,A=e.overlayInnerStyle,$=e.overlay,M=e.id,N=e.showArrow,D=N===void 0?!0:N,T=e.classNames,P=e.styles,I=tn(e,bQ),R=qC(M),H=et(null);Oc(t,function(){return H.current});var V=Q({},I);"visible"in e&&(V.popupVisible=e.visible);var L=function(){return C.createElement(MB,{key:"content",prefixCls:d,id:R,bodyClassName:T==null?void 0:T.body,overlayInnerStyle:Q(Q({},A),P==null?void 0:P.body)},$)},j=function(){var _=C.Children.only(f),F=(_==null?void 0:_.props)||{},B=Q(Q({},F),{},{"aria-describedby":$?R:null});return C.cloneElement(f,B)};return C.createElement(ek,Qe({popupClassName:me(n,T==null?void 0:T.root),prefixCls:d,popup:L,action:o,builtinPlacements:yQ,popupPlacement:b,ref:H,popupAlign:x,getPopupContainer:O,onPopupVisibleChange:h,afterPopupVisibleChange:m,popupTransitionName:p,popupAnimation:g,popupMotion:v,defaultPopupVisible:S,autoDestroy:k,mouseLeaveDelay:l,popupStyle:Q(Q({},c),P==null?void 0:P.root),mouseEnterDelay:a,arrow:D},V),j())};const EQ=Oi(xQ);function NB(e){const{sizePopupArrow:t,borderRadiusXS:n,borderRadiusOuter:r}=e,o=t/2,i=0,a=o,s=r*1/Math.sqrt(2),l=o-r*(1-1/Math.sqrt(2)),c=o-n*(1/Math.sqrt(2)),u=r*(Math.sqrt(2)-1)+n*(1/Math.sqrt(2)),d=2*o-c,f=u,h=2*o-s,m=l,p=2*o-i,g=a,v=o*Math.sqrt(2)+r*(Math.sqrt(2)-2),y=r*(Math.sqrt(2)-1),b=`polygon(${y}px 100%, 50% ${y}px, ${2*o-y}px 100%, ${y}px 100%)`,w=`path('M ${i} ${a} A ${r} ${r} 0 0 0 ${s} ${l} L ${c} ${u} A ${n} ${n} 0 0 1 ${d} ${f} L ${h} ${m} A ${r} ${r} 0 0 0 ${p} ${g} Z')`;return{arrowShadowWidth:v,arrowPath:w,arrowPolygon:b}}const DB=(e,t,n)=>{const{sizePopupArrow:r,arrowPolygon:o,arrowPath:i,arrowShadowWidth:a,borderRadiusXS:s,calc:l}=e;return{pointerEvents:"none",width:r,height:r,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:r,height:l(r).div(2).equal(),background:t,clipPath:{_multi_value_:!0,value:[o,i]},content:'""'},"&::after":{content:'""',position:"absolute",width:a,height:a,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${Ce(s)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:n,zIndex:0,background:"transparent"}}},TB=8;function FB(e){const{contentRadius:t,limitVerticalRadius:n}=e,r=t>12?t+2:12;return{arrowOffsetHorizontal:r,arrowOffsetVertical:n?TB:r}}function rf(e,t){return e?t:{}}function wQ(e,t,n){const{componentCls:r,boxShadowPopoverArrow:o,arrowOffsetVertical:i,arrowOffsetHorizontal:a}=e,{arrowDistance:s=0,arrowPlacement:l={left:!0,right:!0,top:!0,bottom:!0}}={};return{[r]:Object.assign(Object.assign(Object.assign(Object.assign({[`${r}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},DB(e,t,o)),{"&:before":{background:t}})]},rf(!!l.top,{[[`&-placement-top > ${r}-arrow`,`&-placement-topLeft > ${r}-arrow`,`&-placement-topRight > ${r}-arrow`].join(",")]:{bottom:s,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},"&-placement-topLeft":{"--arrow-offset-horizontal":a,[`> ${r}-arrow`]:{left:{_skip_check_:!0,value:a}}},"&-placement-topRight":{"--arrow-offset-horizontal":`calc(100% - ${Ce(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:!0,value:a}}}})),rf(!!l.bottom,{[[`&-placement-bottom > ${r}-arrow`,`&-placement-bottomLeft > ${r}-arrow`,`&-placement-bottomRight > ${r}-arrow`].join(",")]:{top:s,transform:"translateY(-100%)"},[`&-placement-bottom > ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},"&-placement-bottomLeft":{"--arrow-offset-horizontal":a,[`> ${r}-arrow`]:{left:{_skip_check_:!0,value:a}}},"&-placement-bottomRight":{"--arrow-offset-horizontal":`calc(100% - ${Ce(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:!0,value:a}}}})),rf(!!l.left,{[[`&-placement-left > ${r}-arrow`,`&-placement-leftTop > ${r}-arrow`,`&-placement-leftBottom > ${r}-arrow`].join(",")]:{right:{_skip_check_:!0,value:s},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${r}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${r}-arrow`]:{top:i},[`&-placement-leftBottom > ${r}-arrow`]:{bottom:i}})),rf(!!l.right,{[[`&-placement-right > ${r}-arrow`,`&-placement-rightTop > ${r}-arrow`,`&-placement-rightBottom > ${r}-arrow`].join(",")]:{left:{_skip_check_:!0,value:s},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${r}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${r}-arrow`]:{top:i},[`&-placement-rightBottom > ${r}-arrow`]:{bottom:i}}))}}function CQ(e,t,n,r){if(r===!1)return{adjustX:!1,adjustY:!1};const o=r&&typeof r=="object"?r:{},i={};switch(e){case"top":case"bottom":i.shiftX=t.arrowOffsetHorizontal*2+n,i.shiftY=!0,i.adjustY=!0;break;case"left":case"right":i.shiftY=t.arrowOffsetVertical*2+n,i.shiftX=!0,i.adjustX=!0;break}const a=Object.assign(Object.assign({},i),o);return a.shiftX||(a.adjustX=!0),a.shiftY||(a.adjustY=!0),a}const U6={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"]}},kQ={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"]}},SQ=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function AQ(e){const{arrowWidth:t,autoAdjustOverflow:n,arrowPointAtCenter:r,offset:o,borderRadius:i}=e,a=t/2,s={},l=FB({contentRadius:i,limitVerticalRadius:!0});return Object.keys(U6).forEach(c=>{const u=r&&kQ[c]||U6[c],d=Object.assign(Object.assign({},u),{offset:[0,0],dynamicInset:!0});switch(s[c]=d,SQ.has(c)&&(d.autoArrow=!1),c){case"top":case"topLeft":case"topRight":d.offset[1]=-a-o;break;case"bottom":case"bottomLeft":case"bottomRight":d.offset[1]=a+o;break;case"left":case"leftTop":case"leftBottom":d.offset[0]=-a-o;break;case"right":case"rightTop":case"rightBottom":d.offset[0]=a+o;break}if(r)switch(c){case"topLeft":case"bottomLeft":d.offset[0]=-l.arrowOffsetHorizontal-a;break;case"topRight":case"bottomRight":d.offset[0]=l.arrowOffsetHorizontal+a;break;case"leftTop":case"rightTop":d.offset[1]=-l.arrowOffsetHorizontal*2+a;break;case"leftBottom":case"rightBottom":d.offset[1]=l.arrowOffsetHorizontal*2-a;break}d.overflow=CQ(c,l,t,n),d.htmlRegion="visibleFirst"}),s}const $Q=e=>{const{calc:t,componentCls:n,tooltipMaxWidth:r,tooltipColor:o,tooltipBg:i,tooltipBorderRadius:a,zIndexPopup:s,controlHeight:l,boxShadowSecondary:c,paddingSM:u,paddingXS:d,arrowOffsetHorizontal:f,sizePopupArrow:h}=e,m=t(a).add(h).add(f).equal(),p=t(a).mul(2).add(h).equal();return[{[n]:Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{position:"absolute",zIndex:s,display:"block",width:"max-content",maxWidth:r,visibility:"visible","--valid-offset-x":"var(--arrow-offset-horizontal, var(--arrow-x))",transformOrigin:["var(--valid-offset-x, 50%)","var(--arrow-y, 50%)"].join(" "),"&-hidden":{display:"none"},"--antd-arrow-background-color":i,[`${n}-inner`]:{minWidth:p,minHeight:l,padding:`${Ce(e.calc(u).div(2).equal())} ${Ce(d)}`,color:`var(--ant-tooltip-color, ${o})`,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:i,borderRadius:a,boxShadow:c,boxSizing:"border-box"},[["&-placement-topLeft","&-placement-topRight","&-placement-bottomLeft","&-placement-bottomRight"].join(",")]:{minWidth:m},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${n}-inner`]:{borderRadius:e.min(a,TB)}},[`${n}-content`]:{position:"relative"}}),yp(e,(g,{darkColor:v})=>({[`&${n}-${g}`]:{[`${n}-inner`]:{backgroundColor:v},[`${n}-arrow`]:{"--antd-arrow-background-color":v}}}))),{"&-rtl":{direction:"rtl"}})},wQ(e,"var(--antd-arrow-background-color)"),{[`${n}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},OQ=e=>Object.assign(Object.assign({zIndexPopup:e.zIndexPopupBase+70},FB({contentRadius:e.borderRadius,limitVerticalRadius:!0})),NB(Mn(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)}))),PB=(e,t=!0)=>Pr("Tooltip",n=>{const{borderRadius:r,colorTextLightSolid:o,colorBgSpotlight:i}=n,a=Mn(n,{tooltipMaxWidth:250,tooltipColor:o,tooltipBorderRadius:r,tooltipBg:i});return[$Q(a),uY(n,"zoom-big-fast")]},OQ,{resetStyle:!1,injectStyle:t})(e),MQ=Js.map(e=>`${e}-inverse`),NQ=["success","processing","error","default","warning"];function Tp(e,t=!0){return t?[].concat(ze(MQ),ze(Js)).includes(e):Js.includes(e)}function DQ(e){return NQ.includes(e)}function IB(e,t){const n=Tp(t),r=me({[`${e}-${t}`]:t&&n}),o={},i={},a=dY(t).toRgb(),s=(.299*a.r+.587*a.g+.114*a.b)/255<.5?"#FFF":"#000";return t&&!n&&(o.background=t,o["--ant-tooltip-color"]=s,i["--antd-arrow-background-color"]=t),{className:r,overlayStyle:o,arrowStyle:i}}const TQ=e=>{const{prefixCls:t,className:n,placement:r="top",title:o,color:i,overlayInnerStyle:a}=e,{getPrefixCls:s}=C.useContext(pn),l=s("tooltip",t),[c,u,d]=PB(l),f=IB(l,i),h=f.arrowStyle,m=Object.assign(Object.assign({},a),f.overlayStyle),p=me(u,d,l,`${l}-pure`,`${l}-placement-${r}`,n,f.className);return c(C.createElement("div",{className:p,style:h},C.createElement("div",{className:`${l}-arrow`}),C.createElement(MB,Object.assign({},e,{className:u,prefixCls:l,overlayInnerStyle:m}),o)))};var FQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const PQ=C.forwardRef((e,t)=>{var n,r;const{prefixCls:o,openClassName:i,getTooltipContainer:a,color:s,overlayInnerStyle:l,children:c,afterOpenChange:u,afterVisibleChange:d,destroyTooltipOnHide:f,destroyOnHidden:h,arrow:m=!0,title:p,overlay:g,builtinPlacements:v,arrowPointAtCenter:y=!1,autoAdjustOverflow:b=!0,getPopupContainer:w,placement:x="top",mouseEnterDelay:E=.1,mouseLeaveDelay:k=.1,overlayStyle:S,rootClassName:O,overlayClassName:A,styles:$,classNames:M}=e,N=FQ(e,["prefixCls","openClassName","getTooltipContainer","color","overlayInnerStyle","children","afterOpenChange","afterVisibleChange","destroyTooltipOnHide","destroyOnHidden","arrow","title","overlay","builtinPlacements","arrowPointAtCenter","autoAdjustOverflow","motion","getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName","overlayClassName","styles","classNames"]),D=!!m,[,T]=ii(),{getPopupContainer:P,getPrefixCls:I,direction:R,className:H,style:V,classNames:L,styles:j}=xa("tooltip"),_=gp(),F=C.useRef(null),B=()=>{var ue;(ue=F.current)===null||ue===void 0||ue.forceAlign()};C.useImperativeHandle(t,()=>{var ue,ve;return{forceAlign:B,forcePopupAlign:()=>{_.deprecated(!1,"forcePopupAlign","forceAlign"),B()},nativeElement:(ue=F.current)===null||ue===void 0?void 0:ue.nativeElement,popupElement:(ve=F.current)===null||ve===void 0?void 0:ve.popupElement}});const[z,G]=yr(!1,{value:(n=e.open)!==null&&n!==void 0?n:e.visible,defaultValue:(r=e.defaultOpen)!==null&&r!==void 0?r:e.defaultVisible}),W=!p&&!g&&p!==0,q=ue=>{var ve,xe;G(W?!1:ue),W||((ve=e.onOpenChange)===null||ve===void 0||ve.call(e,ue),(xe=e.onVisibleChange)===null||xe===void 0||xe.call(e,ue))},U=C.useMemo(()=>{var ue,ve;let xe=y;return typeof m=="object"&&(xe=(ve=(ue=m.pointAtCenter)!==null&&ue!==void 0?ue:m.arrowPointAtCenter)!==null&&ve!==void 0?ve:y),v||AQ({arrowPointAtCenter:xe,autoAdjustOverflow:b,arrowWidth:D?T.sizePopupArrow:0,borderRadius:T.borderRadius,offset:T.marginXXS})},[y,m,v,T]),Y=C.useMemo(()=>p===0?p:g||p||"",[g,p]),ie=C.createElement(ts,{space:!0},typeof Y=="function"?Y():Y),K=I("tooltip",o),re=I(),oe=e["data-popover-inject"];let ne=z;!("open"in e)&&!("visible"in e)&&W&&(ne=!1);const ae=C.isValidElement(c)&&!$I(c)?c:C.createElement("span",null,c),de=ae.props,ge=!de.className||typeof de.className=="string"?me(de.className,i||`${K}-open`):de.className,[Se,ye,be]=PB(K,!oe),ce=IB(K,s),he=ce.arrowStyle,Te=me(A,{[`${K}-rtl`]:R==="rtl"},ce.className,O,ye,be,H,L.root,M==null?void 0:M.root),se=me(L.body,M==null?void 0:M.body),[Pe,De]=xp("Tooltip",N.zIndex),He=C.createElement(EQ,Object.assign({},N,{zIndex:Pe,showArrow:D,placement:x,mouseEnterDelay:E,mouseLeaveDelay:k,prefixCls:K,classNames:{root:Te,body:se},styles:{root:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},he),j.root),V),S),$==null?void 0:$.root),body:Object.assign(Object.assign(Object.assign(Object.assign({},j.body),l),$==null?void 0:$.body),ce.overlayStyle)},getTooltipContainer:w||a||P,ref:F,builtinPlacements:U,overlay:ie,visible:ne,onVisibleChange:q,afterVisibleChange:u??d,arrowContent:C.createElement("span",{className:`${K}-arrow-content`}),motion:{motionName:LI(re,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:h??!!f}),ne?es(ae,{className:ge}):ae);return Se(C.createElement(TI.Provider,{value:De},He))}),Nd=PQ;Nd._InternalPanelDoNotUseOrYouWillBeFired=TQ;const IQ=new xn("antStatusProcessing",{"0%":{transform:"scale(0.8)",opacity:.5},"100%":{transform:"scale(2.4)",opacity:0}}),BQ=new xn("antZoomBadgeIn",{"0%":{transform:"scale(0) translate(50%, -50%)",opacity:0},"100%":{transform:"scale(1) translate(50%, -50%)"}}),RQ=new xn("antZoomBadgeOut",{"0%":{transform:"scale(1) translate(50%, -50%)"},"100%":{transform:"scale(0) translate(50%, -50%)",opacity:0}}),_Q=new xn("antNoWrapperZoomBadgeIn",{"0%":{transform:"scale(0)",opacity:0},"100%":{transform:"scale(1)"}}),jQ=new xn("antNoWrapperZoomBadgeOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0)",opacity:0}}),LQ=new xn("antBadgeLoadingCircle",{"0%":{transformOrigin:"50%"},"100%":{transform:"translate(50%, -50%) rotate(360deg)",transformOrigin:"50%"}}),zQ=e=>{const{componentCls:t,iconCls:n,antCls:r,badgeShadowSize:o,textFontSize:i,textFontSizeSM:a,statusSize:s,dotSize:l,textFontWeight:c,indicatorHeight:u,indicatorHeightSM:d,marginXS:f,calc:h}=e,m=`${r}-scroll-number`,p=yp(e,(g,{darkColor:v})=>({[`&${t} ${t}-color-${g}`]:{background:v,[`&:not(${t}-count)`]:{color:v},"a:hover &":{background:v}}}));return{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},br(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:i,lineHeight:Ce(u),whiteSpace:"nowrap",textAlign:"center",background:e.badgeColor,borderRadius:h(u).div(2).equal(),boxShadow:`0 0 0 ${Ce(o)} ${e.badgeShadowColor}`,transition:`background ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:d,height:d,fontSize:a,lineHeight:Ce(d),borderRadius:h(d).div(2).equal()},[`${t}-multiple-words`]:{padding:`0 ${Ce(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 ${Ce(o)} ${e.badgeShadowColor}`},[`${t}-count, ${t}-dot, ${m}-custom-component`]:{position:"absolute",top:0,insetInlineEnd:0,transform:"translate(50%, -50%)",transformOrigin:"100% 0%",[`&${n}-spin`]:{animationName:LQ,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear"}},[`&${t}-status`]:{lineHeight:"inherit",verticalAlign:"baseline",[`${t}-status-dot`]:{position:"relative",top:-1,display:"inline-block",width:s,height:s,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:o,borderStyle:"solid",borderColor:"inherit",borderRadius:"50%",animationName:IQ,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:f,color:e.colorText,fontSize:e.fontSize}}}),p),{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:BQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`${t}-zoom-leave`]:{animationName:RQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:_Q,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:jQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:"middle"},[`${m}-custom-component, ${t}-count`]:{transform:"none"},[`${m}-custom-component, ${m}`]:{position:"relative",top:"auto",display:"block",transformOrigin:"50% 50%"}},[m]:{overflow:"hidden",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack}`,[`${m}-only`]:{position:"relative",display:"inline-block",height:u,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden",[`> p${m}-only-unit`]:{height:u,margin:0,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden"}},[`${m}-symbol`]:{verticalAlign:"top"}},"&-rtl":{direction:"rtl",[`${t}-count, ${t}-dot, ${m}-custom-component`]:{transform:"translate(-50%, -50%)"}}})}},BB=e=>{const{fontHeight:t,lineWidth:n,marginXS:r,colorBorderBg:o}=e,i=t,a=n,s=e.colorTextLightSolid,l=e.colorError,c=e.colorErrorHover;return Mn(e,{badgeFontHeight:i,badgeShadowSize:a,badgeTextColor:s,badgeColor:l,badgeColorHover:c,badgeShadowColor:o,badgeProcessingDuration:"1.2s",badgeRibbonOffset:r,badgeRibbonCornerTransform:"scaleY(0.75)",badgeRibbonCornerFilter:"brightness(75%)"})},RB=e=>{const{fontSize:t,lineHeight:n,fontSizeSM:r,lineWidth:o}=e;return{indicatorZIndex:"auto",indicatorHeight:Math.round(t*n)-2*o,indicatorHeightSM:t,dotSize:r/2,textFontSize:r,textFontSizeSM:r,textFontWeight:"normal",statusSize:r/2}},HQ=Pr("Badge",e=>{const t=BB(e);return zQ(t)},RB),WQ=e=>{const{antCls:t,badgeFontHeight:n,marginXS:r,badgeRibbonOffset:o,calc:i}=e,a=`${t}-ribbon`,s=`${t}-ribbon-wrapper`,l=yp(e,(c,{darkColor:u})=>({[`&${a}-color-${c}`]:{background:u,color:u}}));return{[s]:{position:"relative"},[a]:Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{position:"absolute",top:r,padding:`0 ${Ce(e.paddingXS)}`,color:e.colorPrimary,lineHeight:Ce(n),whiteSpace:"nowrap",backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${a}-text`]:{color:e.badgeTextColor},[`${a}-corner`]:{position:"absolute",top:"100%",width:o,height:o,color:"currentcolor",border:`${Ce(i(o).div(2).equal())} solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:"top",filter:e.badgeRibbonCornerFilter}}),l),{[`&${a}-placement-end`]:{insetInlineEnd:i(o).mul(-1).equal(),borderEndEndRadius:0,[`${a}-corner`]:{insetInlineEnd:0,borderInlineEndColor:"transparent",borderBlockEndColor:"transparent"}},[`&${a}-placement-start`]:{insetInlineStart:i(o).mul(-1).equal(),borderEndStartRadius:0,[`${a}-corner`]:{insetInlineStart:0,borderBlockEndColor:"transparent",borderInlineStartColor:"transparent"}},"&-rtl":{direction:"rtl"}})}},VQ=Pr(["Badge","Ribbon"],e=>{const t=BB(e);return WQ(t)},RB),GQ=e=>{const{className:t,prefixCls:n,style:r,color:o,children:i,text:a,placement:s="end",rootClassName:l}=e,{getPrefixCls:c,direction:u}=C.useContext(pn),d=c("ribbon",n),f=`${d}-wrapper`,[h,m,p]=VQ(d,f),g=Tp(o,!1),v=me(d,`${d}-placement-${s}`,{[`${d}-rtl`]:u==="rtl",[`${d}-color-${o}`]:g},t),y={},b={};return o&&!g&&(y.background=o,b.color=o),h(C.createElement("div",{className:me(f,l,m,p)},i,C.createElement("div",{className:me(v,m),style:Object.assign(Object.assign({},y),r)},C.createElement("span",{className:`${d}-text`},a),C.createElement("div",{className:`${d}-corner`,style:b}))))},q6=e=>{const{prefixCls:t,value:n,current:r,offset:o=0}=e;let i;return o&&(i={position:"absolute",top:`${o}00%`,left:0}),C.createElement("span",{style:i,className:me(`${t}-only-unit`,{current:r})},n)};function UQ(e,t,n){let r=e,o=0;for(;(r+10)%10!==t;)r+=n,o+=n;return o}const qQ=e=>{const{prefixCls:t,count:n,value:r}=e,o=Number(r),i=Math.abs(n),[a,s]=C.useState(o),[l,c]=C.useState(i),u=()=>{s(o),c(i)};C.useEffect(()=>{const h=setTimeout(u,1e3);return()=>clearTimeout(h)},[o]);let d,f;if(a===o||Number.isNaN(o)||Number.isNaN(a))d=[C.createElement(q6,Object.assign({},e,{key:o,current:!0}))],f={transition:"none"};else{d=[];const h=o+10,m=[];for(let v=o;v<=h;v+=1)m.push(v);const p=l<i?1:-1,g=m.findIndex(v=>v%10===a);d=(p<0?m.slice(0,g+1):m.slice(g)).map((v,y)=>{const b=v%10;return C.createElement(q6,Object.assign({},e,{key:v,value:b,offset:p<0?y-g:y,current:y===g}))}),f={transform:`translateY(${-UQ(a,o,p)}00%)`}}return C.createElement("span",{className:`${t}-only`,style:f,onTransitionEnd:u},d)};var YQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const XQ=C.forwardRef((e,t)=>{const{prefixCls:n,count:r,className:o,motionClassName:i,style:a,title:s,show:l,component:c="sup",children:u}=e,d=YQ(e,["prefixCls","count","className","motionClassName","style","title","show","component","children"]),{getPrefixCls:f}=C.useContext(pn),h=f("scroll-number",n),m=Object.assign(Object.assign({},d),{"data-show":l,style:a,className:me(h,o,i),title:s});let p=r;if(r&&Number(r)%1===0){const g=String(r).split("");p=C.createElement("bdi",null,g.map((v,y)=>C.createElement(qQ,{prefixCls:h,count:Number(r),value:v,key:g.length-y})))}return a!=null&&a.borderColor&&(m.style=Object.assign(Object.assign({},a),{boxShadow:`0 0 0 1px ${a.borderColor} inset`})),u?es(u,g=>({className:me(`${h}-custom-component`,g==null?void 0:g.className,i)})):C.createElement(c,Object.assign({},m,{ref:t}),p)});var KQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const ZQ=C.forwardRef((e,t)=>{var n,r,o,i,a;const{prefixCls:s,scrollNumberPrefixCls:l,children:c,status:u,text:d,color:f,count:h=null,overflowCount:m=99,dot:p=!1,size:g="default",title:v,offset:y,style:b,className:w,rootClassName:x,classNames:E,styles:k,showZero:S=!1}=e,O=KQ(e,["prefixCls","scrollNumberPrefixCls","children","status","text","color","count","overflowCount","dot","size","title","offset","style","className","rootClassName","classNames","styles","showZero"]),{getPrefixCls:A,direction:$,badge:M}=C.useContext(pn),N=A("badge",s),[D,T,P]=HQ(N),I=h>m?`${m}+`:h,R=I==="0"||I===0||d==="0"||d===0,H=h===null||R&&!S,V=(u!=null||f!=null)&&H,L=u!=null||!R,j=p&&!R,_=j?"":I,F=Gt(()=>((_==null||_==="")&&(d==null||d==="")||R&&!S)&&!j,[_,R,S,j,d]),B=et(h);F||(B.current=h);const z=B.current,G=et(_);F||(G.current=_);const W=G.current,q=et(j);F||(q.current=j);const U=Gt(()=>{if(!y)return Object.assign(Object.assign({},M==null?void 0:M.style),b);const ge={marginTop:y[1]};return $==="rtl"?ge.left=Number.parseInt(y[0],10):ge.right=-Number.parseInt(y[0],10),Object.assign(Object.assign(Object.assign({},ge),M==null?void 0:M.style),b)},[$,y,b,M==null?void 0:M.style]),Y=v??(typeof z=="string"||typeof z=="number"?z:void 0),ie=!F&&(d===0?S:!!d&&d!==!0),K=ie?C.createElement("span",{className:`${N}-status-text`},d):null,re=!z||typeof z!="object"?void 0:es(z,ge=>({style:Object.assign(Object.assign({},U),ge.style)})),oe=Tp(f,!1),ne=me(E==null?void 0:E.indicator,(n=M==null?void 0:M.classNames)===null||n===void 0?void 0:n.indicator,{[`${N}-status-dot`]:V,[`${N}-status-${u}`]:!!u,[`${N}-color-${f}`]:oe}),ae={};f&&!oe&&(ae.color=f,ae.background=f);const de=me(N,{[`${N}-status`]:V,[`${N}-not-a-wrapper`]:!c,[`${N}-rtl`]:$==="rtl"},w,x,M==null?void 0:M.className,(r=M==null?void 0:M.classNames)===null||r===void 0?void 0:r.root,E==null?void 0:E.root,T,P);if(!c&&V&&(d||L||!H)){const ge=U.color;return D(C.createElement("span",Object.assign({},O,{className:de,style:Object.assign(Object.assign(Object.assign({},k==null?void 0:k.root),(o=M==null?void 0:M.styles)===null||o===void 0?void 0:o.root),U)}),C.createElement("span",{className:ne,style:Object.assign(Object.assign(Object.assign({},k==null?void 0:k.indicator),(i=M==null?void 0:M.styles)===null||i===void 0?void 0:i.indicator),ae)}),ie&&C.createElement("span",{style:{color:ge},className:`${N}-status-text`},d)))}return D(C.createElement("span",Object.assign({ref:t},O,{className:de,style:Object.assign(Object.assign({},(a=M==null?void 0:M.styles)===null||a===void 0?void 0:a.root),k==null?void 0:k.root)}),c,C.createElement(fl,{visible:!F,motionName:`${N}-zoom`,motionAppear:!1,motionDeadline:1e3},({className:ge})=>{var Se,ye;const be=A("scroll-number",l),ce=q.current,he=me(E==null?void 0:E.indicator,(Se=M==null?void 0:M.classNames)===null||Se===void 0?void 0:Se.indicator,{[`${N}-dot`]:ce,[`${N}-count`]:!ce,[`${N}-count-sm`]:g==="small",[`${N}-multiple-words`]:!ce&&W&&W.toString().length>1,[`${N}-status-${u}`]:!!u,[`${N}-color-${f}`]:oe});let Te=Object.assign(Object.assign(Object.assign({},k==null?void 0:k.indicator),(ye=M==null?void 0:M.styles)===null||ye===void 0?void 0:ye.indicator),U);return f&&!oe&&(Te=Te||{},Te.background=f),C.createElement(XQ,{prefixCls:be,show:!F,motionClassName:ge,className:he,count:W,title:Y,style:Te,key:"scrollNumber"},re)}),K))}),_B=ZQ;_B.Ribbon=GQ;var V2={exports:{}},QQ=V2.exports,Y6;function JQ(){return Y6||(Y6=1,(function(e,t){(function(n,r){e.exports=r()})(QQ,(function(){var n=1e3,r=6e4,o=36e5,i="millisecond",a="second",s="minute",l="hour",c="day",u="week",d="month",f="quarter",h="year",m="date",p="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,v=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(D){var T=["th","st","nd","rd"],P=D%100;return"["+D+(T[(P-20)%10]||T[P]||T[0])+"]"}},b=function(D,T,P){var I=String(D);return!I||I.length>=T?D:""+Array(T+1-I.length).join(P)+D},w={s:b,z:function(D){var T=-D.utcOffset(),P=Math.abs(T),I=Math.floor(P/60),R=P%60;return(T<=0?"+":"-")+b(I,2,"0")+":"+b(R,2,"0")},m:function D(T,P){if(T.date()<P.date())return-D(P,T);var I=12*(P.year()-T.year())+(P.month()-T.month()),R=T.clone().add(I,d),H=P-R<0,V=T.clone().add(I+(H?-1:1),d);return+(-(I+(P-R)/(H?R-V:V-R))||0)},a:function(D){return D<0?Math.ceil(D)||0:Math.floor(D)},p:function(D){return{M:d,y:h,w:u,d:c,D:m,h:l,m:s,s:a,ms:i,Q:f}[D]||String(D||"").toLowerCase().replace(/s$/,"")},u:function(D){return D===void 0}},x="en",E={};E[x]=y;var k="$isDayjsObject",S=function(D){return D instanceof M||!(!D||!D[k])},O=function D(T,P,I){var R;if(!T)return x;if(typeof T=="string"){var H=T.toLowerCase();E[H]&&(R=H),P&&(E[H]=P,R=H);var V=T.split("-");if(!R&&V.length>1)return D(V[0])}else{var L=T.name;E[L]=T,R=L}return!I&&R&&(x=R),R||!I&&x},A=function(D,T){if(S(D))return D.clone();var P=typeof T=="object"?T:{};return P.date=D,P.args=arguments,new M(P)},$=w;$.l=O,$.i=S,$.w=function(D,T){return A(D,{locale:T.$L,utc:T.$u,x:T.$x,$offset:T.$offset})};var M=(function(){function D(P){this.$L=O(P.locale,null,!0),this.parse(P),this.$x=this.$x||P.x||{},this[k]=!0}var T=D.prototype;return T.parse=function(P){this.$d=(function(I){var R=I.date,H=I.utc;if(R===null)return new Date(NaN);if($.u(R))return new Date;if(R instanceof Date)return new Date(R);if(typeof R=="string"&&!/Z$/i.test(R)){var V=R.match(g);if(V){var L=V[2]-1||0,j=(V[7]||"0").substring(0,3);return H?new Date(Date.UTC(V[1],L,V[3]||1,V[4]||0,V[5]||0,V[6]||0,j)):new Date(V[1],L,V[3]||1,V[4]||0,V[5]||0,V[6]||0,j)}}return new Date(R)})(P),this.init()},T.init=function(){var P=this.$d;this.$y=P.getFullYear(),this.$M=P.getMonth(),this.$D=P.getDate(),this.$W=P.getDay(),this.$H=P.getHours(),this.$m=P.getMinutes(),this.$s=P.getSeconds(),this.$ms=P.getMilliseconds()},T.$utils=function(){return $},T.isValid=function(){return this.$d.toString()!==p},T.isSame=function(P,I){var R=A(P);return this.startOf(I)<=R&&R<=this.endOf(I)},T.isAfter=function(P,I){return A(P)<this.startOf(I)},T.isBefore=function(P,I){return this.endOf(I)<A(P)},T.$g=function(P,I,R){return $.u(P)?this[I]:this.set(R,P)},T.unix=function(){return Math.floor(this.valueOf()/1e3)},T.valueOf=function(){return this.$d.getTime()},T.startOf=function(P,I){var R=this,H=!!$.u(I)||I,V=$.p(P),L=function(q,U){var Y=$.w(R.$u?Date.UTC(R.$y,U,q):new Date(R.$y,U,q),R);return H?Y:Y.endOf(c)},j=function(q,U){return $.w(R.toDate()[q].apply(R.toDate("s"),(H?[0,0,0,0]:[23,59,59,999]).slice(U)),R)},_=this.$W,F=this.$M,B=this.$D,z="set"+(this.$u?"UTC":"");switch(V){case h:return H?L(1,0):L(31,11);case d:return H?L(1,F):L(0,F+1);case u:var G=this.$locale().weekStart||0,W=(_<G?_+7:_)-G;return L(H?B-W:B+(6-W),F);case c:case m:return j(z+"Hours",0);case l:return j(z+"Minutes",1);case s:return j(z+"Seconds",2);case a:return j(z+"Milliseconds",3);default:return this.clone()}},T.endOf=function(P){return this.startOf(P,!1)},T.$set=function(P,I){var R,H=$.p(P),V="set"+(this.$u?"UTC":""),L=(R={},R[c]=V+"Date",R[m]=V+"Date",R[d]=V+"Month",R[h]=V+"FullYear",R[l]=V+"Hours",R[s]=V+"Minutes",R[a]=V+"Seconds",R[i]=V+"Milliseconds",R)[H],j=H===c?this.$D+(I-this.$W):I;if(H===d||H===h){var _=this.clone().set(m,1);_.$d[L](j),_.init(),this.$d=_.set(m,Math.min(this.$D,_.daysInMonth())).$d}else L&&this.$d[L](j);return this.init(),this},T.set=function(P,I){return this.clone().$set(P,I)},T.get=function(P){return this[$.p(P)]()},T.add=function(P,I){var R,H=this;P=Number(P);var V=$.p(I),L=function(F){var B=A(H);return $.w(B.date(B.date()+Math.round(F*P)),H)};if(V===d)return this.set(d,this.$M+P);if(V===h)return this.set(h,this.$y+P);if(V===c)return L(1);if(V===u)return L(7);var j=(R={},R[s]=r,R[l]=o,R[a]=n,R)[V]||1,_=this.$d.getTime()+P*j;return $.w(_,this)},T.subtract=function(P,I){return this.add(-1*P,I)},T.format=function(P){var I=this,R=this.$locale();if(!this.isValid())return R.invalidDate||p;var H=P||"YYYY-MM-DDTHH:mm:ssZ",V=$.z(this),L=this.$H,j=this.$m,_=this.$M,F=R.weekdays,B=R.months,z=R.meridiem,G=function(U,Y,ie,K){return U&&(U[Y]||U(I,H))||ie[Y].slice(0,K)},W=function(U){return $.s(L%12||12,U,"0")},q=z||function(U,Y,ie){var K=U<12?"AM":"PM";return ie?K.toLowerCase():K};return H.replace(v,(function(U,Y){return Y||(function(ie){switch(ie){case"YY":return String(I.$y).slice(-2);case"YYYY":return $.s(I.$y,4,"0");case"M":return _+1;case"MM":return $.s(_+1,2,"0");case"MMM":return G(R.monthsShort,_,B,3);case"MMMM":return G(B,_);case"D":return I.$D;case"DD":return $.s(I.$D,2,"0");case"d":return String(I.$W);case"dd":return G(R.weekdaysMin,I.$W,F,2);case"ddd":return G(R.weekdaysShort,I.$W,F,3);case"dddd":return F[I.$W];case"H":return String(L);case"HH":return $.s(L,2,"0");case"h":return W(1);case"hh":return W(2);case"a":return q(L,j,!0);case"A":return q(L,j,!1);case"m":return String(j);case"mm":return $.s(j,2,"0");case"s":return String(I.$s);case"ss":return $.s(I.$s,2,"0");case"SSS":return $.s(I.$ms,3,"0");case"Z":return V}return null})(U)||V.replace(":","")}))},T.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},T.diff=function(P,I,R){var H,V=this,L=$.p(I),j=A(P),_=(j.utcOffset()-this.utcOffset())*r,F=this-j,B=function(){return $.m(V,j)};switch(L){case h:H=B()/12;break;case d:H=B();break;case f:H=B()/3;break;case u:H=(F-_)/6048e5;break;case c:H=(F-_)/864e5;break;case l:H=F/o;break;case s:H=F/r;break;case a:H=F/n;break;default:H=F}return R?H:$.a(H)},T.daysInMonth=function(){return this.endOf(d).$D},T.$locale=function(){return E[this.$L]},T.locale=function(P,I){if(!P)return this.$L;var R=this.clone(),H=O(P,I,!0);return H&&(R.$L=H),R},T.clone=function(){return $.w(this.$d,this)},T.toDate=function(){return new Date(this.valueOf())},T.toJSON=function(){return this.isValid()?this.toISOString():null},T.toISOString=function(){return this.$d.toISOString()},T.toString=function(){return this.$d.toUTCString()},D})(),N=M.prototype;return A.prototype=N,[["$ms",i],["$s",a],["$m",s],["$H",l],["$W",c],["$M",d],["$y",h],["$D",m]].forEach((function(D){N[D[1]]=function(T){return this.$g(T,D[0],D[1])}})),A.extend=function(D,T){return D.$i||(D(T,M,A),D.$i=!0),A},A.locale=O,A.isDayjs=S,A.unix=function(D){return A(1e3*D)},A.en=E[x],A.Ls=E,A.p={},A}))})(V2)),V2.exports}var eJ=JQ();const oo=ba(eJ);var G2={exports:{}},tJ=G2.exports,X6;function nJ(){return X6||(X6=1,(function(e,t){(function(n,r){e.exports=r()})(tJ,(function(){return function(n,r){r.prototype.weekday=function(o){var i=this.$locale().weekStart||0,a=this.$W,s=(a<i?a+7:a)-i;return this.$utils().u(o)?s:this.subtract(s,"day").add(o,"day")}}}))})(G2)),G2.exports}var rJ=nJ();const oJ=ba(rJ);var U2={exports:{}},iJ=U2.exports,K6;function aJ(){return K6||(K6=1,(function(e,t){(function(n,r){e.exports=r()})(iJ,(function(){return function(n,r,o){var i=r.prototype,a=function(d){return d&&(d.indexOf?d:d.s)},s=function(d,f,h,m,p){var g=d.name?d:d.$locale(),v=a(g[f]),y=a(g[h]),b=v||y.map((function(x){return x.slice(0,m)}));if(!p)return b;var w=g.weekStart;return b.map((function(x,E){return b[(E+(w||0))%7]}))},l=function(){return o.Ls[o.locale()]},c=function(d,f){return d.formats[f]||(function(h){return h.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(m,p,g){return p||g.slice(1)}))})(d.formats[f.toUpperCase()])},u=function(){var d=this;return{months:function(f){return f?f.format("MMMM"):s(d,"months")},monthsShort:function(f){return f?f.format("MMM"):s(d,"monthsShort","months",3)},firstDayOfWeek:function(){return d.$locale().weekStart||0},weekdays:function(f){return f?f.format("dddd"):s(d,"weekdays")},weekdaysMin:function(f){return f?f.format("dd"):s(d,"weekdaysMin","weekdays",2)},weekdaysShort:function(f){return f?f.format("ddd"):s(d,"weekdaysShort","weekdays",3)},longDateFormat:function(f){return c(d.$locale(),f)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};i.localeData=function(){return u.bind(this)()},o.localeData=function(){var d=l();return{firstDayOfWeek:function(){return d.weekStart||0},weekdays:function(){return o.weekdays()},weekdaysShort:function(){return o.weekdaysShort()},weekdaysMin:function(){return o.weekdaysMin()},months:function(){return o.months()},monthsShort:function(){return o.monthsShort()},longDateFormat:function(f){return c(d,f)},meridiem:d.meridiem,ordinal:d.ordinal}},o.months=function(){return s(l(),"months")},o.monthsShort=function(){return s(l(),"monthsShort","months",3)},o.weekdays=function(d){return s(l(),"weekdays",null,null,d)},o.weekdaysShort=function(d){return s(l(),"weekdaysShort","weekdays",3,d)},o.weekdaysMin=function(d){return s(l(),"weekdaysMin","weekdays",2,d)}}}))})(U2)),U2.exports}var sJ=aJ();const lJ=ba(sJ);var q2={exports:{}},cJ=q2.exports,Z6;function uJ(){return Z6||(Z6=1,(function(e,t){(function(n,r){e.exports=r()})(cJ,(function(){var n="week",r="year";return function(o,i,a){var s=i.prototype;s.week=function(l){if(l===void 0&&(l=null),l!==null)return this.add(7*(l-this.week()),"day");var c=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var u=a(this).startOf(r).add(1,r).date(c),d=a(this).endOf(n);if(u.isBefore(d))return 1}var f=a(this).startOf(r).date(c).startOf(n).subtract(1,"millisecond"),h=this.diff(f,n,!0);return h<0?a(this).startOf("week").week():Math.ceil(h)},s.weeks=function(l){return l===void 0&&(l=null),this.week(l)}}}))})(q2)),q2.exports}var dJ=uJ();const fJ=ba(dJ);var Y2={exports:{}},hJ=Y2.exports,Q6;function pJ(){return Q6||(Q6=1,(function(e,t){(function(n,r){e.exports=r()})(hJ,(function(){return function(n,r){r.prototype.weekYear=function(){var o=this.month(),i=this.week(),a=this.year();return i===1&&o===11?a+1:o===0&&i>=52?a-1:a}}}))})(Y2)),Y2.exports}var gJ=pJ();const mJ=ba(gJ);var X2={exports:{}},vJ=X2.exports,J6;function yJ(){return J6||(J6=1,(function(e,t){(function(n,r){e.exports=r()})(vJ,(function(){return function(n,r){var o=r.prototype,i=o.format;o.format=function(a){var s=this,l=this.$locale();if(!this.isValid())return i.bind(this)(a);var c=this.$utils(),u=(a||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(d){switch(d){case"Q":return Math.ceil((s.$M+1)/3);case"Do":return l.ordinal(s.$D);case"gggg":return s.weekYear();case"GGGG":return s.isoWeekYear();case"wo":return l.ordinal(s.week(),"W");case"w":case"ww":return c.s(s.week(),d==="w"?1:2,"0");case"W":case"WW":return c.s(s.isoWeek(),d==="W"?1:2,"0");case"k":case"kk":return c.s(String(s.$H===0?24:s.$H),d==="k"?1:2,"0");case"X":return Math.floor(s.$d.getTime()/1e3);case"x":return s.$d.getTime();case"z":return"["+s.offsetName()+"]";case"zzz":return"["+s.offsetName("long")+"]";default:return d}}));return i.bind(this)(u)}}}))})(X2)),X2.exports}var bJ=yJ();const xJ=ba(bJ);var K2={exports:{}},EJ=K2.exports,eA;function wJ(){return eA||(eA=1,(function(e,t){(function(n,r){e.exports=r()})(EJ,(function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,o=/\d/,i=/\d\d/,a=/\d\d?/,s=/\d*[^-_:/,()\s\d]+/,l={},c=function(g){return(g=+g)+(g>68?1900:2e3)},u=function(g){return function(v){this[g]=+v}},d=[/[+-]\d\d:?(\d\d)?|Z/,function(g){(this.zone||(this.zone={})).offset=(function(v){if(!v||v==="Z")return 0;var y=v.match(/([+-]|\d\d)/g),b=60*y[1]+(+y[2]||0);return b===0?0:y[0]==="+"?-b:b})(g)}],f=function(g){var v=l[g];return v&&(v.indexOf?v:v.s.concat(v.f))},h=function(g,v){var y,b=l.meridiem;if(b){for(var w=1;w<=24;w+=1)if(g.indexOf(b(w,0,v))>-1){y=w>12;break}}else y=g===(v?"pm":"PM");return y},m={A:[s,function(g){this.afternoon=h(g,!1)}],a:[s,function(g){this.afternoon=h(g,!0)}],Q:[o,function(g){this.month=3*(g-1)+1}],S:[o,function(g){this.milliseconds=100*+g}],SS:[i,function(g){this.milliseconds=10*+g}],SSS:[/\d{3}/,function(g){this.milliseconds=+g}],s:[a,u("seconds")],ss:[a,u("seconds")],m:[a,u("minutes")],mm:[a,u("minutes")],H:[a,u("hours")],h:[a,u("hours")],HH:[a,u("hours")],hh:[a,u("hours")],D:[a,u("day")],DD:[i,u("day")],Do:[s,function(g){var v=l.ordinal,y=g.match(/\d+/);if(this.day=y[0],v)for(var b=1;b<=31;b+=1)v(b).replace(/\[|\]/g,"")===g&&(this.day=b)}],w:[a,u("week")],ww:[i,u("week")],M:[a,u("month")],MM:[i,u("month")],MMM:[s,function(g){var v=f("months"),y=(f("monthsShort")||v.map((function(b){return b.slice(0,3)}))).indexOf(g)+1;if(y<1)throw new Error;this.month=y%12||y}],MMMM:[s,function(g){var v=f("months").indexOf(g)+1;if(v<1)throw new Error;this.month=v%12||v}],Y:[/[+-]?\d+/,u("year")],YY:[i,function(g){this.year=c(g)}],YYYY:[/\d{4}/,u("year")],Z:d,ZZ:d};function p(g){var v,y;v=g,y=l&&l.formats;for(var b=(g=v.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(A,$,M){var N=M&&M.toUpperCase();return $||y[M]||n[M]||y[N].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(D,T,P){return T||P.slice(1)}))}))).match(r),w=b.length,x=0;x<w;x+=1){var E=b[x],k=m[E],S=k&&k[0],O=k&&k[1];b[x]=O?{regex:S,parser:O}:E.replace(/^\[|\]$/g,"")}return function(A){for(var $={},M=0,N=0;M<w;M+=1){var D=b[M];if(typeof D=="string")N+=D.length;else{var T=D.regex,P=D.parser,I=A.slice(N),R=T.exec(I)[0];P.call($,R),A=A.replace(R,"")}}return(function(H){var V=H.afternoon;if(V!==void 0){var L=H.hours;V?L<12&&(H.hours+=12):L===12&&(H.hours=0),delete H.afternoon}})($),$}}return function(g,v,y){y.p.customParseFormat=!0,g&&g.parseTwoDigitYear&&(c=g.parseTwoDigitYear);var b=v.prototype,w=b.parse;b.parse=function(x){var E=x.date,k=x.utc,S=x.args;this.$u=k;var O=S[1];if(typeof O=="string"){var A=S[2]===!0,$=S[3]===!0,M=A||$,N=S[2];$&&(N=S[2]),l=this.$locale(),!A&&N&&(l=y.Ls[N]),this.$d=(function(I,R,H,V){try{if(["x","X"].indexOf(R)>-1)return new Date((R==="X"?1e3:1)*I);var L=p(R)(I),j=L.year,_=L.month,F=L.day,B=L.hours,z=L.minutes,G=L.seconds,W=L.milliseconds,q=L.zone,U=L.week,Y=new Date,ie=F||(j||_?1:Y.getDate()),K=j||Y.getFullYear(),re=0;j&&!_||(re=_>0?_-1:Y.getMonth());var oe,ne=B||0,ae=z||0,de=G||0,ge=W||0;return q?new Date(Date.UTC(K,re,ie,ne,ae,de,ge+60*q.offset*1e3)):H?new Date(Date.UTC(K,re,ie,ne,ae,de,ge)):(oe=new Date(K,re,ie,ne,ae,de,ge),U&&(oe=V(oe).week(U).toDate()),oe)}catch{return new Date("")}})(E,O,k,y),this.init(),N&&N!==!0&&(this.$L=this.locale(N).$L),M&&E!=this.format(O)&&(this.$d=new Date("")),l={}}else if(O instanceof Array)for(var D=O.length,T=1;T<=D;T+=1){S[1]=O[T-1];var P=y.apply(this,S);if(P.isValid()){this.$d=P.$d,this.$L=P.$L,this.init();break}T===D&&(this.$d=new Date(""))}else w.call(this,x)}}}))})(K2)),K2.exports}var CJ=wJ();const kJ=ba(CJ);oo.extend(kJ);oo.extend(xJ);oo.extend(oJ);oo.extend(lJ);oo.extend(fJ);oo.extend(mJ);oo.extend(function(e,t){var n=t.prototype,r=n.format;n.format=function(o){var i=(o||"").replace("Wo","wo");return r.bind(this)(i)}});var SJ={bn_BD:"bn-bd",by_BY:"be",en_GB:"en-gb",en_US:"en",fr_BE:"fr",fr_CA:"fr-ca",hy_AM:"hy-am",kmr_IQ:"ku",nl_BE:"nl-be",pt_BR:"pt-br",zh_CN:"zh-cn",zh_HK:"zh-hk",zh_TW:"zh-tw"},Cs=function(e){var t=SJ[e];return t||e.split("_")[0]},AJ={getNow:function(){var e=oo();return typeof e.tz=="function"?e.tz():e},getFixedDate:function(e){return oo(e,["YYYY-M-DD","YYYY-MM-DD"])},getEndDate:function(e){return e.endOf("month")},getWeekDay:function(e){var t=e.locale("en");return t.weekday()+t.localeData().firstDayOfWeek()},getYear:function(e){return e.year()},getMonth:function(e){return e.month()},getDate:function(e){return e.date()},getHour:function(e){return e.hour()},getMinute:function(e){return e.minute()},getSecond:function(e){return e.second()},getMillisecond:function(e){return e.millisecond()},addYear:function(e,t){return e.add(t,"year")},addMonth:function(e,t){return e.add(t,"month")},addDate:function(e,t){return e.add(t,"day")},setYear:function(e,t){return e.year(t)},setMonth:function(e,t){return e.month(t)},setDate:function(e,t){return e.date(t)},setHour:function(e,t){return e.hour(t)},setMinute:function(e,t){return e.minute(t)},setSecond:function(e,t){return e.second(t)},setMillisecond:function(e,t){return e.millisecond(t)},isAfter:function(e,t){return e.isAfter(t)},isValidate:function(e){return e.isValid()},locale:{getWeekFirstDay:function(e){return oo().locale(Cs(e)).localeData().firstDayOfWeek()},getWeekFirstDate:function(e,t){return t.locale(Cs(e)).weekday(0)},getWeek:function(e,t){return t.locale(Cs(e)).week()},getShortWeekDays:function(e){return oo().locale(Cs(e)).localeData().weekdaysMin()},getShortMonths:function(e){return oo().locale(Cs(e)).localeData().monthsShort()},format:function(e,t,n){return t.locale(Cs(e)).format(n)},parse:function(e,t,n){for(var r=Cs(e),o=0;o<n.length;o+=1){var i=n[o],a=t;if(i.includes("wo")||i.includes("Wo")){for(var s=a.split("-")[0],l=a.split("-")[1],c=oo(s,"YYYY").startOf("year").locale(r),u=0;u<=52;u+=1){var d=c.add(u,"week");if(d.format("Wo")===l)return d}return null}var f=oo(a,i,!0).locale(r);if(f.isValid())return f}return null}}};function $J(e,t){return e!==void 0?e:t?"bottomRight":"bottomLeft"}var Mi=C.createContext(null),OJ={bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:0,adjustY:1}},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:0,adjustY:1}}};function jB(e){var t=e.popupElement,n=e.popupStyle,r=e.popupClassName,o=e.popupAlign,i=e.transitionName,a=e.getPopupContainer,s=e.children,l=e.range,c=e.placement,u=e.builtinPlacements,d=u===void 0?OJ:u,f=e.direction,h=e.visible,m=e.onClose,p=C.useContext(Mi),g=p.prefixCls,v="".concat(g,"-dropdown"),y=$J(c,f==="rtl");return C.createElement(ek,{showAction:[],hideAction:["click"],popupPlacement:y,builtinPlacements:d,prefixCls:v,popupTransitionName:i,popup:t,popupAlign:o,popupVisible:h,popupClassName:me(r,X(X({},"".concat(v,"-range"),l),"".concat(v,"-rtl"),f==="rtl")),popupStyle:n,stretch:"minWidth",getPopupContainer:a,onPopupVisibleChange:function(b){b||m()}},s)}function ik(e,t){for(var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0",r=String(e);r.length<t;)r="".concat(n).concat(r);return r}function ml(e){return e==null?[]:Array.isArray(e)?e:[e]}function Pu(e,t,n){var r=ze(e);return r[t]=n,r}function Fp(e,t){var n={},r=t||Object.keys(e);return r.forEach(function(o){e[o]!==void 0&&(n[o]=e[o])}),n}function LB(e,t,n){if(n)return n;switch(e){case"time":return t.fieldTimeFormat;case"datetime":return t.fieldDateTimeFormat;case"month":return t.fieldMonthFormat;case"year":return t.fieldYearFormat;case"quarter":return t.fieldQuarterFormat;case"week":return t.fieldWeekFormat;default:return t.fieldDateFormat}}function zB(e,t,n){var r=n!==void 0?n:t[t.length-1],o=t.find(function(i){return e[i]});return r!==o?e[o]:void 0}function HB(e){return Fp(e,["placement","builtinPlacements","popupAlign","getPopupContainer","transitionName","direction"])}function ak(e,t,n,r){var o=C.useMemo(function(){return e||function(a,s){var l=a;return t&&s.type==="date"?t(l,s.today):n&&s.type==="month"?n(l,s.locale):s.originNode}},[e,n,t]),i=C.useCallback(function(a,s){return o(a,Q(Q({},s),{},{range:r}))},[o,r]);return i}function WB(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=C.useState([!1,!1]),o=te(r,2),i=o[0],a=o[1],s=function(c,u){a(function(d){return Pu(d,u,c)})},l=C.useMemo(function(){return i.map(function(c,u){if(c)return!0;var d=e[u];return d?!!(!n[u]&&!d||d&&t(d,{activeIndex:u})):!1})},[e,i,t,n]);return[l,s]}function VB(e,t,n,r,o){var i="",a=[];return e&&a.push(o?"hh":"HH"),t&&a.push("mm"),n&&a.push("ss"),i=a.join(":"),r&&(i+=".SSS"),o&&(i+=" A"),i}function MJ(e,t,n,r,o,i){var a=e.fieldDateTimeFormat,s=e.fieldDateFormat,l=e.fieldTimeFormat,c=e.fieldMonthFormat,u=e.fieldYearFormat,d=e.fieldWeekFormat,f=e.fieldQuarterFormat,h=e.yearFormat,m=e.cellYearFormat,p=e.cellQuarterFormat,g=e.dayFormat,v=e.cellDateFormat,y=VB(t,n,r,o,i);return Q(Q({},e),{},{fieldDateTimeFormat:a||"YYYY-MM-DD ".concat(y),fieldDateFormat:s||"YYYY-MM-DD",fieldTimeFormat:l||y,fieldMonthFormat:c||"YYYY-MM",fieldYearFormat:u||"YYYY",fieldWeekFormat:d||"gggg-wo",fieldQuarterFormat:f||"YYYY-[Q]Q",yearFormat:h||"YYYY",cellYearFormat:m||"YYYY",cellQuarterFormat:p||"[Q]Q",cellDateFormat:v||g||"D"})}function GB(e,t){var n=t.showHour,r=t.showMinute,o=t.showSecond,i=t.showMillisecond,a=t.use12Hours;return we.useMemo(function(){return MJ(e,n,r,o,i,a)},[e,n,r,o,i,a])}function nu(e,t,n){return n??t.some(function(r){return e.includes(r)})}var NJ=["showNow","showHour","showMinute","showSecond","showMillisecond","use12Hours","hourStep","minuteStep","secondStep","millisecondStep","hideDisabledOptions","defaultValue","disabledHours","disabledMinutes","disabledSeconds","disabledMilliseconds","disabledTime","changeOnScroll","defaultOpenValue"];function DJ(e){var t=Fp(e,NJ),n=e.format,r=e.picker,o=null;return n&&(o=n,Array.isArray(o)&&(o=o[0]),o=At(o)==="object"?o.format:o),r==="time"&&(t.format=o),[t,o]}function TJ(e){return e&&typeof e=="string"}function UB(e,t,n,r){return[e,t,n,r].some(function(o){return o!==void 0})}function qB(e,t,n,r,o){var i=t,a=n,s=r;if(!e&&!i&&!a&&!s&&!o)i=!0,a=!0,s=!0;else if(e){var l,c,u,d=[i,a,s].some(function(m){return m===!1}),f=[i,a,s].some(function(m){return m===!0}),h=d?!0:!f;i=(l=i)!==null&&l!==void 0?l:h,a=(c=a)!==null&&c!==void 0?c:h,s=(u=s)!==null&&u!==void 0?u:h}return[i,a,s,o]}function YB(e){var t=e.showTime,n=DJ(e),r=te(n,2),o=r[0],i=r[1],a=t&&At(t)==="object"?t:{},s=Q(Q({defaultOpenValue:a.defaultOpenValue||a.defaultValue},o),a),l=s.showMillisecond,c=s.showHour,u=s.showMinute,d=s.showSecond,f=UB(c,u,d,l),h=qB(f,c,u,d,l),m=te(h,3);return c=m[0],u=m[1],d=m[2],[s,Q(Q({},s),{},{showHour:c,showMinute:u,showSecond:d,showMillisecond:l}),s.format,i]}function XB(e,t,n,r,o){var i=e==="time";if(e==="datetime"||i){for(var a=r,s=LB(e,o,null),l=s,c=[t,n],u=0;u<c.length;u+=1){var d=ml(c[u])[0];if(TJ(d)){l=d;break}}var f=a.showHour,h=a.showMinute,m=a.showSecond,p=a.showMillisecond,g=a.use12Hours,v=nu(l,["a","A","LT","LLL","LTS"],g),y=UB(f,h,m,p);y||(f=nu(l,["H","h","k","LT","LLL"]),h=nu(l,["m","LT","LLL"]),m=nu(l,["s","LTS"]),p=nu(l,["SSS"]));var b=qB(y,f,h,m,p),w=te(b,3);f=w[0],h=w[1],m=w[2];var x=t||VB(f,h,m,p,v);return Q(Q({},a),{},{format:x,showHour:f,showMinute:h,showSecond:m,showMillisecond:p,use12Hours:v})}return null}function FJ(e,t,n){if(t===!1)return null;var r=t&&At(t)==="object"?t:{};return r.clearIcon||n||C.createElement("span",{className:"".concat(e,"-clear-btn")})}var Em=7;function gs(e,t,n){return!e&&!t||e===t?!0:!e||!t?!1:n()}function Z2(e,t,n){return gs(t,n,function(){var r=Math.floor(e.getYear(t)/10),o=Math.floor(e.getYear(n)/10);return r===o})}function tl(e,t,n){return gs(t,n,function(){return e.getYear(t)===e.getYear(n)})}function tA(e,t){var n=Math.floor(e.getMonth(t)/3);return n+1}function PJ(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&tA(e,t)===tA(e,n)})}function sk(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&e.getMonth(t)===e.getMonth(n)})}function lk(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&sk(e,t,n)&&e.getDate(t)===e.getDate(n)})}function KB(e,t,n){return gs(t,n,function(){return e.getHour(t)===e.getHour(n)&&e.getMinute(t)===e.getMinute(n)&&e.getSecond(t)===e.getSecond(n)})}function ZB(e,t,n){return gs(t,n,function(){return lk(e,t,n)&&KB(e,t,n)&&e.getMillisecond(t)===e.getMillisecond(n)})}function wu(e,t,n,r){return gs(n,r,function(){var o=e.locale.getWeekFirstDate(t,n),i=e.locale.getWeekFirstDate(t,r);return tl(e,o,i)&&e.locale.getWeek(t,n)===e.locale.getWeek(t,r)})}function lo(e,t,n,r,o){switch(o){case"date":return lk(e,n,r);case"week":return wu(e,t.locale,n,r);case"month":return sk(e,n,r);case"quarter":return PJ(e,n,r);case"year":return tl(e,n,r);case"decade":return Z2(e,n,r);case"time":return KB(e,n,r);default:return ZB(e,n,r)}}function Pp(e,t,n,r){return!t||!n||!r?!1:e.isAfter(r,t)&&e.isAfter(n,r)}function of(e,t,n,r,o){return lo(e,t,n,r,o)?!0:e.isAfter(n,r)}function IJ(e,t,n){var r=t.locale.getWeekFirstDay(e),o=t.setDate(n,1),i=t.getWeekDay(o),a=t.addDate(o,r-i);return t.getMonth(a)===t.getMonth(n)&&t.getDate(a)>1&&(a=t.addDate(a,-7)),a}function _r(e,t){var n=t.generateConfig,r=t.locale,o=t.format;return e?typeof o=="function"?o(e):n.locale.format(r.locale,e,o):""}function m0(e,t,n){var r=t,o=["getHour","getMinute","getSecond","getMillisecond"],i=["setHour","setMinute","setSecond","setMillisecond"];return i.forEach(function(a,s){n?r=e[a](r,e[o[s]](n)):r=e[a](r,0)}),r}function BJ(e,t,n,r,o){var i=cn(function(a,s){return!!(n&&n(a,s)||r&&e.isAfter(r,a)&&!lo(e,t,r,a,s.type)||o&&e.isAfter(a,o)&&!lo(e,t,o,a,s.type))});return i}function RJ(e,t,n){return C.useMemo(function(){var r=LB(e,t,n),o=ml(r),i=o[0],a=At(i)==="object"&&i.type==="mask"?i.format:null;return[o.map(function(s){return typeof s=="string"||typeof s=="function"?s:s.format}),a]},[e,t,n])}function _J(e,t,n){return typeof e[0]=="function"||n?!0:t}function jJ(e,t,n,r){var o=cn(function(i,a){var s=Q({type:t},a);if(delete s.activeIndex,!e.isValidate(i)||n&&n(i,s))return!0;if((t==="date"||t==="time")&&r){var l,c=a&&a.activeIndex===1?"end":"start",u=((l=r.disabledTime)===null||l===void 0?void 0:l.call(r,i,c,{from:s.from}))||{},d=u.disabledHours,f=u.disabledMinutes,h=u.disabledSeconds,m=u.disabledMilliseconds,p=r.disabledHours,g=r.disabledMinutes,v=r.disabledSeconds,y=d||p,b=f||g,w=h||v,x=e.getHour(i),E=e.getMinute(i),k=e.getSecond(i),S=e.getMillisecond(i);if(y&&y().includes(x)||b&&b(x).includes(E)||w&&w(x,E).includes(k)||m&&m(x,E,k).includes(S))return!0}return!1});return o}function af(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=C.useMemo(function(){var r=e&&ml(e);return t&&r&&(r[1]=r[1]||r[0]),r},[e,t]);return n}function QB(e,t){var n=e.generateConfig,r=e.locale,o=e.picker,i=o===void 0?"date":o,a=e.prefixCls,s=a===void 0?"rc-picker":a,l=e.styles,c=l===void 0?{}:l,u=e.classNames,d=u===void 0?{}:u,f=e.order,h=f===void 0?!0:f,m=e.components,p=m===void 0?{}:m,g=e.inputRender,v=e.allowClear,y=e.clearIcon,b=e.needConfirm,w=e.multiple,x=e.format,E=e.inputReadOnly,k=e.disabledDate,S=e.minDate,O=e.maxDate,A=e.showTime,$=e.value,M=e.defaultValue,N=e.pickerValue,D=e.defaultPickerValue,T=af($),P=af(M),I=af(N),R=af(D),H=i==="date"&&A?"datetime":i,V=H==="time"||H==="datetime",L=V||w,j=b??V,_=YB(e),F=te(_,4),B=F[0],z=F[1],G=F[2],W=F[3],q=GB(r,z),U=C.useMemo(function(){return XB(H,G,W,B,q)},[H,G,W,B,q]),Y=C.useMemo(function(){return Q(Q({},e),{},{prefixCls:s,locale:q,picker:i,styles:c,classNames:d,order:h,components:Q({input:g},p),clearIcon:FJ(s,v,y),showTime:U,value:T,defaultValue:P,pickerValue:I,defaultPickerValue:R},t==null?void 0:t())},[e]),ie=RJ(H,q,x),K=te(ie,2),re=K[0],oe=K[1],ne=_J(re,E,w),ae=BJ(n,r,k,S,O),de=jJ(n,i,ae,U),ge=C.useMemo(function(){return Q(Q({},Y),{},{needConfirm:j,inputReadOnly:ne,disabledDate:ae})},[Y,j,ne,ae]);return[ge,H,L,re,oe,de]}function LJ(e,t,n){var r=yr(t,{value:e}),o=te(r,2),i=o[0],a=o[1],s=we.useRef(e),l=we.useRef(),c=function(){en.cancel(l.current)},u=cn(function(){a(s.current),n&&i!==s.current&&n(s.current)}),d=cn(function(f,h){c(),s.current=f,f||h?u():l.current=en(u)});return we.useEffect(function(){return c},[]),[i,d]}function JB(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=arguments.length>3?arguments[3]:void 0,o=n.every(function(u){return u})?!1:e,i=LJ(o,t||!1,r),a=te(i,2),s=a[0],l=a[1];function c(u){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(!d.inherit||s)&&l(u,d.force)}return[s,c]}function eR(e){var t=C.useRef();return C.useImperativeHandle(e,function(){var n;return{nativeElement:(n=t.current)===null||n===void 0?void 0:n.nativeElement,focus:function(r){var o;(o=t.current)===null||o===void 0||o.focus(r)},blur:function(){var r;(r=t.current)===null||r===void 0||r.blur()}}}),t}function tR(e,t){return C.useMemo(function(){return e||(t?(qr(!1,"`ranges` is deprecated. Please use `presets` instead."),Object.entries(t).map(function(n){var r=te(n,2),o=r[0],i=r[1];return{label:o,value:i}})):[])},[e,t])}function ck(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,r=C.useRef(t);r.current=t,nc(function(){if(e)r.current(e);else{var o=en(function(){r.current(e)},n);return function(){en.cancel(o)}}},[e])}function nR(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,r=C.useState(0),o=te(r,2),i=o[0],a=o[1],s=C.useState(!1),l=te(s,2),c=l[0],u=l[1],d=C.useRef([]),f=C.useRef(null),h=C.useRef(null),m=function(b){f.current=b},p=function(b){return f.current===b},g=function(b){u(b)},v=function(b){return b&&(h.current=b),h.current},y=function(b){var w=d.current,x=new Set(w.filter(function(k){return b[k]||t[k]})),E=w[w.length-1]===0?1:0;return x.size>=2||e[E]?null:E};return ck(c||n,function(){c||(d.current=[],m(null))}),C.useEffect(function(){c&&d.current.push(i)},[c,i]),[c,g,v,i,a,y,d.current,m,p]}function zJ(e,t,n,r,o,i){var a=n[n.length-1],s=function(l,c){var u=te(e,2),d=u[0],f=u[1],h=Q(Q({},c),{},{from:zB(e,n)});return a===1&&t[0]&&d&&!lo(r,o,d,l,h.type)&&r.isAfter(d,l)||a===0&&t[1]&&f&&!lo(r,o,f,l,h.type)&&r.isAfter(l,f)?!0:i==null?void 0:i(l,h)};return s}function Cu(e,t,n,r){switch(t){case"date":case"week":return e.addMonth(n,r);case"month":case"quarter":return e.addYear(n,r);case"year":return e.addYear(n,r*10);case"decade":return e.addYear(n,r*100);default:return n}}var wm=[];function rR(e,t,n,r,o,i,a,s){var l=arguments.length>8&&arguments[8]!==void 0?arguments[8]:wm,c=arguments.length>9&&arguments[9]!==void 0?arguments[9]:wm,u=arguments.length>10&&arguments[10]!==void 0?arguments[10]:wm,d=arguments.length>11?arguments[11]:void 0,f=arguments.length>12?arguments[12]:void 0,h=arguments.length>13?arguments[13]:void 0,m=a==="time",p=i||0,g=function(P){var I=e.getNow();return m&&(I=m0(e,I)),l[P]||n[P]||I},v=te(c,2),y=v[0],b=v[1],w=yr(function(){return g(0)},{value:y}),x=te(w,2),E=x[0],k=x[1],S=yr(function(){return g(1)},{value:b}),O=te(S,2),A=O[0],$=O[1],M=C.useMemo(function(){var P=[E,A][p];return m?P:m0(e,P,u[p])},[m,E,A,p,e,u]),N=function(P){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"panel",R=[k,$][p];R(P);var H=[E,A];H[p]=P,d&&(!lo(e,t,E,H[0],a)||!lo(e,t,A,H[1],a))&&d(H,{source:I,range:p===1?"end":"start",mode:r})},D=function(P,I){if(s){var R={date:"month",week:"month",month:"year",quarter:"year"},H=R[a];if(H&&!lo(e,t,P,I,H))return Cu(e,a,I,-1);if(a==="year"&&P){var V=Math.floor(e.getYear(P)/10),L=Math.floor(e.getYear(I)/10);if(V!==L)return Cu(e,a,I,-1)}}return I},T=C.useRef(null);return mn(function(){if(o&&!l[p]){var P=m?null:e.getNow();if(T.current!==null&&T.current!==p?P=[E,A][p^1]:n[p]?P=p===0?n[0]:D(n[0],n[1]):n[p^1]&&(P=n[p^1]),P){f&&e.isAfter(f,P)&&(P=f);var I=s?Cu(e,a,P,1):P;h&&e.isAfter(I,h)&&(P=s?Cu(e,a,h,-1):h),N(P,"reset")}}},[o,p,n[p]]),C.useEffect(function(){o?T.current=p:T.current=null},[o,p]),mn(function(){o&&l&&l[p]&&N(l[p],"reset")},[o,p]),[M,N]}function oR(e,t){var n=C.useRef(e),r=C.useState({}),o=te(r,2),i=o[1],a=function(l){return l&&t!==void 0?t:n.current},s=function(l){n.current=l,i({})};return[a,s,a(!0)]}var HJ=[];function iR(e,t,n){var r=function(i){return i.map(function(a){return _r(a,{generateConfig:e,locale:t,format:n[0]})})},o=function(i,a){for(var s=Math.max(i.length,a.length),l=-1,c=0;c<s;c+=1){var u=i[c]||null,d=a[c]||null;if(u!==d&&!ZB(e,u,d)){l=c;break}}return[l<0,l!==0]};return[r,o]}function aR(e,t){return ze(e).sort(function(n,r){return t.isAfter(n,r)?1:-1})}function WJ(e){var t=oR(e),n=te(t,2),r=n[0],o=n[1],i=cn(function(){o(e)});return C.useEffect(function(){i()},[e]),[r,o]}function sR(e,t,n,r,o,i,a,s,l){var c=yr(i,{value:a}),u=te(c,2),d=u[0],f=u[1],h=d||HJ,m=WJ(h),p=te(m,2),g=p[0],v=p[1],y=iR(e,t,n),b=te(y,2),w=b[0],x=b[1],E=cn(function(S){var O=ze(S);if(r)for(var A=0;A<2;A+=1)O[A]=O[A]||null;else o&&(O=aR(O.filter(function(P){return P}),e));var $=x(g(),O),M=te($,2),N=M[0],D=M[1];if(!N&&(v(O),s)){var T=w(O);s(O,T,{range:D?"end":"start"})}}),k=function(){l&&l(g())};return[h,f,g,E,k]}function lR(e,t,n,r,o,i,a,s,l,c){var u=e.generateConfig,d=e.locale,f=e.picker,h=e.onChange,m=e.allowEmpty,p=e.order,g=i.some(function(N){return N})?!1:p,v=iR(u,d,a),y=te(v,2),b=y[0],w=y[1],x=oR(t),E=te(x,2),k=E[0],S=E[1],O=cn(function(){S(t)});C.useEffect(function(){O()},[t]);var A=cn(function(N){var D=N===null,T=ze(N||k());if(D)for(var P=Math.max(i.length,T.length),I=0;I<P;I+=1)i[I]||(T[I]=null);g&&T[0]&&T[1]&&(T=aR(T,u)),o(T);var R=T,H=te(R,2),V=H[0],L=H[1],j=!V,_=!L,F=m?(!j||m[0])&&(!_||m[1]):!0,B=!p||j||_||lo(u,d,V,L,f)||u.isAfter(L,V),z=(i[0]||!V||!c(V,{activeIndex:0}))&&(i[1]||!L||!c(L,{from:V,activeIndex:1})),G=D||F&&B&&z;if(G){n(T);var W=w(T,t),q=te(W,1),U=q[0];h&&!U&&h(D&&T.every(function(Y){return!Y})?null:T,b(T))}return G}),$=cn(function(N,D){var T=Pu(k(),N,r()[N]);S(T),D&&A()}),M=!s&&!l;return ck(!M,function(){M&&(A(),o(t),O())},2),[$,A]}function cR(e,t,n,r,o){return t!=="date"&&t!=="time"?!1:n!==void 0?n:r!==void 0?r:!o&&(e==="date"||e==="time")}function VJ(e,t,n,r,o,i){var a=e;function s(d,f,h){var m=i[d](a),p=h.find(function(b){return b.value===m});if(!p||p.disabled){var g=h.filter(function(b){return!b.disabled}),v=ze(g).reverse(),y=v.find(function(b){return b.value<=m})||g[0];y&&(m=y.value,a=i[f](a,m))}return m}var l=s("getHour","setHour",t()),c=s("getMinute","setMinute",n(l)),u=s("getSecond","setSecond",r(l,c));return s("getMillisecond","setMillisecond",o(l,c,u)),a}function sf(){return[]}function lf(e,t){for(var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:2,a=[],s=n>=1?n|0:1,l=e;l<=t;l+=s){var c=o.includes(l);(!c||!r)&&a.push({label:ik(l,i),value:l,disabled:c})}return a}function uk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=t||{},o=r.use12Hours,i=r.hourStep,a=i===void 0?1:i,s=r.minuteStep,l=s===void 0?1:s,c=r.secondStep,u=c===void 0?1:c,d=r.millisecondStep,f=d===void 0?100:d,h=r.hideDisabledOptions,m=r.disabledTime,p=r.disabledHours,g=r.disabledMinutes,v=r.disabledSeconds,y=C.useMemo(function(){return n||e.getNow()},[n,e]),b=C.useCallback(function(R){var H=(m==null?void 0:m(R))||{};return[H.disabledHours||p||sf,H.disabledMinutes||g||sf,H.disabledSeconds||v||sf,H.disabledMilliseconds||sf]},[m,p,g,v]),w=C.useMemo(function(){return b(y)},[y,b]),x=te(w,4),E=x[0],k=x[1],S=x[2],O=x[3],A=C.useCallback(function(R,H,V,L){var j=lf(0,23,a,h,R()),_=o?j.map(function(G){return Q(Q({},G),{},{label:ik(G.value%12||12,2)})}):j,F=function(G){return lf(0,59,l,h,H(G))},B=function(G,W){return lf(0,59,u,h,V(G,W))},z=function(G,W,q){return lf(0,999,f,h,L(G,W,q),3)};return[_,F,B,z]},[h,a,o,f,l,u]),$=C.useMemo(function(){return A(E,k,S,O)},[A,E,k,S,O]),M=te($,4),N=M[0],D=M[1],T=M[2],P=M[3],I=function(R,H){var V=function(){return N},L=D,j=T,_=P;if(H){var F=b(H),B=te(F,4),z=B[0],G=B[1],W=B[2],q=B[3],U=A(z,G,W,q),Y=te(U,4),ie=Y[0],K=Y[1],re=Y[2],oe=Y[3];V=function(){return ie},L=K,j=re,_=oe}var ne=VJ(R,V,L,j,_,e);return ne};return[I,N,D,T,P]}function GJ(e){var t=e.mode,n=e.internalMode,r=e.renderExtraFooter,o=e.showNow,i=e.showTime,a=e.onSubmit,s=e.onNow,l=e.invalid,c=e.needConfirm,u=e.generateConfig,d=e.disabledDate,f=C.useContext(Mi),h=f.prefixCls,m=f.locale,p=f.button,g=p===void 0?"button":p,v=u.getNow(),y=uk(u,i,v),b=te(y,1),w=b[0],x=r==null?void 0:r(t),E=d(v,{type:t}),k=function(){if(!E){var N=w(v);s(N)}},S="".concat(h,"-now"),O="".concat(S,"-btn"),A=o&&C.createElement("li",{className:S},C.createElement("a",{className:me(O,E&&"".concat(O,"-disabled")),"aria-disabled":E,onClick:k},n==="date"?m.today:m.now)),$=c&&C.createElement("li",{className:"".concat(h,"-ok")},C.createElement(g,{disabled:l,onClick:a},m.ok)),M=(A||$)&&C.createElement("ul",{className:"".concat(h,"-ranges")},A,$);return!x&&!M?null:C.createElement("div",{className:"".concat(h,"-footer")},x&&C.createElement("div",{className:"".concat(h,"-footer-extra")},x),M)}function uR(e,t,n){function r(o,i){var a=o.findIndex(function(l){return lo(e,t,l,i,n)});if(a===-1)return[].concat(ze(o),[i]);var s=ze(o);return s.splice(a,1),s}return r}var vl=C.createContext(null);function Ip(){return C.useContext(vl)}function Ic(e,t){var n=e.prefixCls,r=e.generateConfig,o=e.locale,i=e.disabledDate,a=e.minDate,s=e.maxDate,l=e.cellRender,c=e.hoverValue,u=e.hoverRangeValue,d=e.onHover,f=e.values,h=e.pickerValue,m=e.onSelect,p=e.prevIcon,g=e.nextIcon,v=e.superPrevIcon,y=e.superNextIcon,b=r.getNow(),w={now:b,values:f,pickerValue:h,prefixCls:n,disabledDate:i,minDate:a,maxDate:s,cellRender:l,hoverValue:c,hoverRangeValue:u,onHover:d,locale:o,generateConfig:r,onSelect:m,panelType:t,prevIcon:p,nextIcon:g,superPrevIcon:v,superNextIcon:y};return[w,b]}var Ya=C.createContext({});function Dd(e){for(var t=e.rowNum,n=e.colNum,r=e.baseDate,o=e.getCellDate,i=e.prefixColumn,a=e.rowClassName,s=e.titleFormat,l=e.getCellText,c=e.getCellClassName,u=e.headerCells,d=e.cellSelection,f=d===void 0?!0:d,h=e.disabledDate,m=Ip(),p=m.prefixCls,g=m.panelType,v=m.now,y=m.disabledDate,b=m.cellRender,w=m.onHover,x=m.hoverValue,E=m.hoverRangeValue,k=m.generateConfig,S=m.values,O=m.locale,A=m.onSelect,$=h||y,M="".concat(p,"-cell"),N=C.useContext(Ya),D=N.onCellDblClick,T=function(j){return S.some(function(_){return _&&lo(k,O,j,_,g)})},P=[],I=0;I<t;I+=1){for(var R=[],H=void 0,V=function(){var j=I*n+L,_=o(r,j),F=$==null?void 0:$(_,{type:g});L===0&&(H=_,i&&R.push(i(H)));var B=!1,z=!1,G=!1;if(f&&E){var W=te(E,2),q=W[0],U=W[1];B=Pp(k,q,U,_),z=lo(k,O,_,q,g),G=lo(k,O,_,U,g)}var Y=s?_r(_,{locale:O,format:s,generateConfig:k}):void 0,ie=C.createElement("div",{className:"".concat(M,"-inner")},l(_));R.push(C.createElement("td",{key:L,title:Y,className:me(M,Q(X(X(X(X(X(X({},"".concat(M,"-disabled"),F),"".concat(M,"-hover"),(x||[]).some(function(K){return lo(k,O,_,K,g)})),"".concat(M,"-in-range"),B&&!z&&!G),"".concat(M,"-range-start"),z),"".concat(M,"-range-end"),G),"".concat(p,"-cell-selected"),!E&&g!=="week"&&T(_)),c(_))),onClick:function(){F||A(_)},onDoubleClick:function(){!F&&D&&D()},onMouseEnter:function(){F||(w==null||w(_))},onMouseLeave:function(){F||(w==null||w(null))}},b?b(_,{prefixCls:p,originNode:ie,today:v,type:g,locale:O}):ie))},L=0;L<n;L+=1)V();P.push(C.createElement("tr",{key:I,className:a==null?void 0:a(H)},R))}return C.createElement("div",{className:"".concat(p,"-body")},C.createElement("table",{className:"".concat(p,"-content")},u&&C.createElement("thead",null,C.createElement("tr",null,u)),C.createElement("tbody",null,P)))}var cf={visibility:"hidden"};function Bc(e){var t=e.offset,n=e.superOffset,r=e.onChange,o=e.getStart,i=e.getEnd,a=e.children,s=Ip(),l=s.prefixCls,c=s.prevIcon,u=c===void 0?"\u2039":c,d=s.nextIcon,f=d===void 0?"\u203A":d,h=s.superPrevIcon,m=h===void 0?"\xAB":h,p=s.superNextIcon,g=p===void 0?"\xBB":p,v=s.minDate,y=s.maxDate,b=s.generateConfig,w=s.locale,x=s.pickerValue,E=s.panelType,k="".concat(l,"-header"),S=C.useContext(Ya),O=S.hidePrev,A=S.hideNext,$=S.hideHeader,M=C.useMemo(function(){if(!v||!t||!i)return!1;var j=i(t(-1,x));return!of(b,w,j,v,E)},[v,t,x,i,b,w,E]),N=C.useMemo(function(){if(!v||!n||!i)return!1;var j=i(n(-1,x));return!of(b,w,j,v,E)},[v,n,x,i,b,w,E]),D=C.useMemo(function(){if(!y||!t||!o)return!1;var j=o(t(1,x));return!of(b,w,y,j,E)},[y,t,x,o,b,w,E]),T=C.useMemo(function(){if(!y||!n||!o)return!1;var j=o(n(1,x));return!of(b,w,y,j,E)},[y,n,x,o,b,w,E]),P=function(j){t&&r(t(j,x))},I=function(j){n&&r(n(j,x))};if($)return null;var R="".concat(k,"-prev-btn"),H="".concat(k,"-next-btn"),V="".concat(k,"-super-prev-btn"),L="".concat(k,"-super-next-btn");return C.createElement("div",{className:k},n&&C.createElement("button",{type:"button","aria-label":w.previousYear,onClick:function(){return I(-1)},tabIndex:-1,className:me(V,N&&"".concat(V,"-disabled")),disabled:N,style:O?cf:{}},m),t&&C.createElement("button",{type:"button","aria-label":w.previousMonth,onClick:function(){return P(-1)},tabIndex:-1,className:me(R,M&&"".concat(R,"-disabled")),disabled:M,style:O?cf:{}},u),C.createElement("div",{className:"".concat(k,"-view")},a),t&&C.createElement("button",{type:"button","aria-label":w.nextMonth,onClick:function(){return P(1)},tabIndex:-1,className:me(H,D&&"".concat(H,"-disabled")),disabled:D,style:A?cf:{}},f),n&&C.createElement("button",{type:"button","aria-label":w.nextYear,onClick:function(){return I(1)},tabIndex:-1,className:me(L,T&&"".concat(L,"-disabled")),disabled:T,style:A?cf:{}},g))}function Bp(e){var t=e.prefixCls,n=e.panelName,r=n===void 0?"date":n,o=e.locale,i=e.generateConfig,a=e.pickerValue,s=e.onPickerValueChange,l=e.onModeChange,c=e.mode,u=c===void 0?"date":c,d=e.disabledDate,f=e.onSelect,h=e.onHover,m=e.showWeek,p="".concat(t,"-").concat(r,"-panel"),g="".concat(t,"-cell"),v=u==="week",y=Ic(e,u),b=te(y,2),w=b[0],x=b[1],E=i.locale.getWeekFirstDay(o.locale),k=i.setDate(a,1),S=IJ(o.locale,i,k),O=i.getMonth(a),A=m===void 0?v:m,$=A?function(j){var _=d==null?void 0:d(j,{type:"week"});return C.createElement("td",{key:"week",className:me(g,"".concat(g,"-week"),X({},"".concat(g,"-disabled"),_)),onClick:function(){_||f(j)},onMouseEnter:function(){_||(h==null||h(j))},onMouseLeave:function(){_||(h==null||h(null))}},C.createElement("div",{className:"".concat(g,"-inner")},i.locale.getWeek(o.locale,j)))}:null,M=[],N=o.shortWeekDays||(i.locale.getShortWeekDays?i.locale.getShortWeekDays(o.locale):[]);$&&M.push(C.createElement("th",{key:"empty"},C.createElement("span",{style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},o.week)));for(var D=0;D<Em;D+=1)M.push(C.createElement("th",{key:D},N[(D+E)%Em]));var T=function(j,_){return i.addDate(j,_)},P=function(j){return _r(j,{locale:o,format:o.cellDateFormat,generateConfig:i})},I=function(j){var _=X(X({},"".concat(t,"-cell-in-view"),sk(i,j,a)),"".concat(t,"-cell-today"),lk(i,j,x));return _},R=o.shortMonths||(i.locale.getShortMonths?i.locale.getShortMonths(o.locale):[]),H=C.createElement("button",{type:"button","aria-label":o.yearSelect,key:"year",onClick:function(){l("year",a)},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(a,{locale:o,format:o.yearFormat,generateConfig:i})),V=C.createElement("button",{type:"button","aria-label":o.monthSelect,key:"month",onClick:function(){l("month",a)},tabIndex:-1,className:"".concat(t,"-month-btn")},o.monthFormat?_r(a,{locale:o,format:o.monthFormat,generateConfig:i}):R[O]),L=o.monthBeforeYear?[V,H]:[H,V];return C.createElement(vl.Provider,{value:w},C.createElement("div",{className:me(p,m&&"".concat(p,"-show-week"))},C.createElement(Bc,{offset:function(j){return i.addMonth(a,j)},superOffset:function(j){return i.addYear(a,j)},onChange:s,getStart:function(j){return i.setDate(j,1)},getEnd:function(j){var _=i.setDate(j,1);return _=i.addMonth(_,1),i.addDate(_,-1)}},L),C.createElement(Dd,Qe({titleFormat:o.fieldDateFormat},e,{colNum:Em,rowNum:6,baseDate:S,headerCells:M,getCellDate:T,getCellText:P,getCellClassName:I,prefixColumn:$,cellSelection:!v}))))}var UJ=1/3;function qJ(e,t){var n=C.useRef(!1),r=C.useRef(null),o=C.useRef(null),i=function(){return n.current},a=function(){en.cancel(r.current),n.current=!1},s=C.useRef(),l=function(){var u=e.current;if(o.current=null,s.current=0,u){var d=u.querySelector('[data-value="'.concat(t,'"]')),f=u.querySelector("li"),h=function m(){a(),n.current=!0,s.current+=1;var p=u.scrollTop,g=f.offsetTop,v=d.offsetTop,y=v-g;if(v===0&&d!==f||!wp(u)){s.current<=5&&(r.current=en(m));return}var b=p+(y-p)*UJ,w=Math.abs(y-b);if(o.current!==null&&o.current<w){a();return}if(o.current=w,w<=1){u.scrollTop=y,a();return}u.scrollTop=b,r.current=en(m)};d&&f&&h()}},c=cn(l);return[c,a,i]}var YJ=300;function XJ(e){return e.map(function(t){var n=t.value,r=t.label,o=t.disabled;return[n,r,o].join(",")}).join(";")}function ru(e){var t=e.units,n=e.value,r=e.optionalValue,o=e.type,i=e.onChange,a=e.onHover,s=e.onDblClick,l=e.changeOnScroll,c=Ip(),u=c.prefixCls,d=c.cellRender,f=c.now,h=c.locale,m="".concat(u,"-time-panel"),p="".concat(u,"-time-panel-cell"),g=C.useRef(null),v=C.useRef(),y=function(){clearTimeout(v.current)},b=qJ(g,n??r),w=te(b,3),x=w[0],E=w[1],k=w[2];mn(function(){return x(),y(),function(){E(),y()}},[n,r,XJ(t)]);var S=function(A){y();var $=A.target;!k()&&l&&(v.current=setTimeout(function(){var M=g.current,N=M.querySelector("li").offsetTop,D=Array.from(M.querySelectorAll("li")),T=D.map(function(V){return V.offsetTop-N}),P=T.map(function(V,L){return t[L].disabled?Number.MAX_SAFE_INTEGER:Math.abs(V-$.scrollTop)}),I=Math.min.apply(Math,ze(P)),R=P.findIndex(function(V){return V===I}),H=t[R];H&&!H.disabled&&i(H.value)},YJ))},O="".concat(m,"-column");return C.createElement("ul",{className:O,ref:g,"data-type":o,onScroll:S},t.map(function(A){var $=A.label,M=A.value,N=A.disabled,D=C.createElement("div",{className:"".concat(p,"-inner")},$);return C.createElement("li",{key:M,className:me(p,X(X({},"".concat(p,"-selected"),n===M),"".concat(p,"-disabled"),N)),onClick:function(){N||i(M)},onDoubleClick:function(){!N&&s&&s()},onMouseEnter:function(){a(M)},onMouseLeave:function(){a(null)},"data-value":M},d?d(M,{prefixCls:u,originNode:D,today:f,type:"time",subType:o,locale:h}):D)}))}function Na(e){return e<12}function KJ(e){var t=e.showHour,n=e.showMinute,r=e.showSecond,o=e.showMillisecond,i=e.use12Hours,a=e.changeOnScroll,s=Ip(),l=s.prefixCls,c=s.values,u=s.generateConfig,d=s.locale,f=s.onSelect,h=s.onHover,m=h===void 0?function(){}:h,p=s.pickerValue,g=(c==null?void 0:c[0])||null,v=C.useContext(Ya),y=v.onCellDblClick,b=uk(u,e,g),w=te(b,5),x=w[0],E=w[1],k=w[2],S=w[3],O=w[4],A=function(Ee){var yt=g&&u[Ee](g),Dt=p&&u[Ee](p);return[yt,Dt]},$=A("getHour"),M=te($,2),N=M[0],D=M[1],T=A("getMinute"),P=te(T,2),I=P[0],R=P[1],H=A("getSecond"),V=te(H,2),L=V[0],j=V[1],_=A("getMillisecond"),F=te(_,2),B=F[0],z=F[1],G=N===null?null:Na(N)?"am":"pm",W=C.useMemo(function(){return i?Na(N)?E.filter(function(Ee){return Na(Ee.value)}):E.filter(function(Ee){return!Na(Ee.value)}):E},[N,E,i]),q=function(Ee,yt){var Dt,Ft=Ee.filter(function(Ut){return!Ut.disabled});return yt??(Ft==null||(Dt=Ft[0])===null||Dt===void 0?void 0:Dt.value)},U=q(E,N),Y=C.useMemo(function(){return k(U)},[k,U]),ie=q(Y,I),K=C.useMemo(function(){return S(U,ie)},[S,U,ie]),re=q(K,L),oe=C.useMemo(function(){return O(U,ie,re)},[O,U,ie,re]),ne=q(oe,B),ae=C.useMemo(function(){if(!i)return[];var Ee=u.getNow(),yt=u.setHour(Ee,6),Dt=u.setHour(Ee,18),Ft=function(Ut,Ge){var Xe=d.cellMeridiemFormat;return Xe?_r(Ut,{generateConfig:u,locale:d,format:Xe}):Ge};return[{label:Ft(yt,"AM"),value:"am",disabled:E.every(function(Ut){return Ut.disabled||!Na(Ut.value)})},{label:Ft(Dt,"PM"),value:"pm",disabled:E.every(function(Ut){return Ut.disabled||Na(Ut.value)})}]},[E,i,u,d]),de=function(Ee){var yt=x(Ee);f(yt)},ge=C.useMemo(function(){var Ee=g||p||u.getNow(),yt=function(Dt){return Dt!=null};return yt(N)?(Ee=u.setHour(Ee,N),Ee=u.setMinute(Ee,I),Ee=u.setSecond(Ee,L),Ee=u.setMillisecond(Ee,B)):yt(D)?(Ee=u.setHour(Ee,D),Ee=u.setMinute(Ee,R),Ee=u.setSecond(Ee,j),Ee=u.setMillisecond(Ee,z)):yt(U)&&(Ee=u.setHour(Ee,U),Ee=u.setMinute(Ee,ie),Ee=u.setSecond(Ee,re),Ee=u.setMillisecond(Ee,ne)),Ee},[g,p,N,I,L,B,U,ie,re,ne,D,R,j,z,u]),Se=function(Ee,yt){return Ee===null?null:u[yt](ge,Ee)},ye=function(Ee){return Se(Ee,"setHour")},be=function(Ee){return Se(Ee,"setMinute")},ce=function(Ee){return Se(Ee,"setSecond")},he=function(Ee){return Se(Ee,"setMillisecond")},Te=function(Ee){return Ee===null?null:Ee==="am"&&!Na(N)?u.setHour(ge,N-12):Ee==="pm"&&Na(N)?u.setHour(ge,N+12):ge},se=function(Ee){de(ye(Ee))},Pe=function(Ee){de(be(Ee))},De=function(Ee){de(ce(Ee))},He=function(Ee){de(he(Ee))},ue=function(Ee){de(Te(Ee))},ve=function(Ee){m(ye(Ee))},xe=function(Ee){m(be(Ee))},fe=function(Ee){m(ce(Ee))},pe=function(Ee){m(he(Ee))},ke=function(Ee){m(Te(Ee))},Ve={onDblClick:y,changeOnScroll:a};return C.createElement("div",{className:"".concat(l,"-content")},t&&C.createElement(ru,Qe({units:W,value:N,optionalValue:D,type:"hour",onChange:se,onHover:ve},Ve)),n&&C.createElement(ru,Qe({units:Y,value:I,optionalValue:R,type:"minute",onChange:Pe,onHover:xe},Ve)),r&&C.createElement(ru,Qe({units:K,value:L,optionalValue:j,type:"second",onChange:De,onHover:fe},Ve)),o&&C.createElement(ru,Qe({units:oe,value:B,optionalValue:z,type:"millisecond",onChange:He,onHover:pe},Ve)),i&&C.createElement(ru,Qe({units:ae,value:G,type:"meridiem",onChange:ue,onHover:ke},Ve)))}function dR(e){var t=e.prefixCls,n=e.value,r=e.locale,o=e.generateConfig,i=e.showTime,a=i||{},s=a.format,l="".concat(t,"-time-panel"),c=Ic(e,"time"),u=te(c,1),d=u[0];return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:me(l)},C.createElement(Bc,null,n?_r(n,{locale:r,format:s,generateConfig:o}):"\xA0"),C.createElement(KJ,i)))}function ZJ(e){var t=e.prefixCls,n=e.generateConfig,r=e.showTime,o=e.onSelect,i=e.value,a=e.pickerValue,s=e.onHover,l="".concat(t,"-datetime-panel"),c=uk(n,r),u=te(c,1),d=u[0],f=function(p){return i?m0(n,p,i):m0(n,p,a)},h=function(p){s==null||s(p&&f(p))},m=function(p){var g=f(p);o(d(g,g))};return C.createElement("div",{className:l},C.createElement(Bp,Qe({},e,{onSelect:m,onHover:h})),C.createElement(dR,e))}function QJ(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s="".concat(t,"-decade-panel"),l=Ic(e,"decade"),c=te(l,1),u=c[0],d=function(x){var E=Math.floor(r.getYear(x)/100)*100;return r.setYear(x,E)},f=function(x){var E=d(x);return r.addYear(E,99)},h=d(o),m=f(o),p=r.addYear(h,-10),g=function(x,E){return r.addYear(x,E*10)},v=function(x){var E=n.cellYearFormat,k=_r(x,{locale:n,format:E,generateConfig:r}),S=_r(r.addYear(x,9),{locale:n,format:E,generateConfig:r});return"".concat(k,"-").concat(S)},y=function(x){return X({},"".concat(t,"-cell-in-view"),Z2(r,x,h)||Z2(r,x,m)||Pp(r,h,m,x))},b=i?function(x,E){var k=r.setDate(x,1),S=r.setMonth(k,0),O=r.setYear(S,Math.floor(r.getYear(S)/10)*10),A=r.addYear(O,10),$=r.addDate(A,-1);return i(O,E)&&i($,E)}:null,w="".concat(_r(h,{locale:n,format:n.yearFormat,generateConfig:r}),"-").concat(_r(m,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:u},C.createElement("div",{className:s},C.createElement(Bc,{superOffset:function(x){return r.addYear(o,x*100)},onChange:a,getStart:d,getEnd:f},w),C.createElement(Dd,Qe({},e,{disabledDate:b,colNum:3,rowNum:4,baseDate:p,getCellDate:g,getCellText:v,getCellClassName:y}))))}function JJ(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s=e.onModeChange,l="".concat(t,"-month-panel"),c=Ic(e,"month"),u=te(c,1),d=u[0],f=r.setMonth(o,0),h=n.shortMonths||(r.locale.getShortMonths?r.locale.getShortMonths(n.locale):[]),m=function(b,w){return r.addMonth(b,w)},p=function(b){var w=r.getMonth(b);return n.monthFormat?_r(b,{locale:n,format:n.monthFormat,generateConfig:r}):h[w]},g=function(){return X({},"".concat(t,"-cell-in-view"),!0)},v=i?function(b,w){var x=r.setDate(b,1),E=r.setMonth(x,r.getMonth(x)+1),k=r.addDate(E,-1);return i(x,w)&&i(k,w)}:null,y=C.createElement("button",{type:"button",key:"year","aria-label":n.yearSelect,onClick:function(){s("year")},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(o,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:l},C.createElement(Bc,{superOffset:function(b){return r.addYear(o,b)},onChange:a,getStart:function(b){return r.setMonth(b,0)},getEnd:function(b){return r.setMonth(b,11)}},y),C.createElement(Dd,Qe({},e,{disabledDate:v,titleFormat:n.fieldMonthFormat,colNum:3,rowNum:4,baseDate:f,getCellDate:m,getCellText:p,getCellClassName:g}))))}function e7(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.onPickerValueChange,a=e.onModeChange,s="".concat(t,"-quarter-panel"),l=Ic(e,"quarter"),c=te(l,1),u=c[0],d=r.setMonth(o,0),f=function(g,v){return r.addMonth(g,v*3)},h=function(g){return _r(g,{locale:n,format:n.cellQuarterFormat,generateConfig:r})},m=function(){return X({},"".concat(t,"-cell-in-view"),!0)},p=C.createElement("button",{type:"button",key:"year","aria-label":n.yearSelect,onClick:function(){a("year")},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(o,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:u},C.createElement("div",{className:s},C.createElement(Bc,{superOffset:function(g){return r.addYear(o,g)},onChange:i,getStart:function(g){return r.setMonth(g,0)},getEnd:function(g){return r.setMonth(g,11)}},p),C.createElement(Dd,Qe({},e,{titleFormat:n.fieldQuarterFormat,colNum:4,rowNum:1,baseDate:d,getCellDate:f,getCellText:h,getCellClassName:m}))))}function t7(e){var t=e.prefixCls,n=e.generateConfig,r=e.locale,o=e.value,i=e.hoverValue,a=e.hoverRangeValue,s=r.locale,l="".concat(t,"-week-panel-row"),c=function(u){var d={};if(a){var f=te(a,2),h=f[0],m=f[1],p=wu(n,s,h,u),g=wu(n,s,m,u);d["".concat(l,"-range-start")]=p,d["".concat(l,"-range-end")]=g,d["".concat(l,"-range-hover")]=!p&&!g&&Pp(n,h,m,u)}return i&&(d["".concat(l,"-hover")]=i.some(function(v){return wu(n,s,u,v)})),me(l,X({},"".concat(l,"-selected"),!a&&wu(n,s,o,u)),d)};return C.createElement(Bp,Qe({},e,{mode:"week",panelName:"week",rowClassName:c}))}function n7(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s=e.onModeChange,l="".concat(t,"-year-panel"),c=Ic(e,"year"),u=te(c,1),d=u[0],f=function(E){var k=Math.floor(r.getYear(E)/10)*10;return r.setYear(E,k)},h=function(E){var k=f(E);return r.addYear(k,9)},m=f(o),p=h(o),g=r.addYear(m,-1),v=function(E,k){return r.addYear(E,k)},y=function(E){return _r(E,{locale:n,format:n.cellYearFormat,generateConfig:r})},b=function(E){return X({},"".concat(t,"-cell-in-view"),tl(r,E,m)||tl(r,E,p)||Pp(r,m,p,E))},w=i?function(E,k){var S=r.setMonth(E,0),O=r.setDate(S,1),A=r.addYear(O,1),$=r.addDate(A,-1);return i(O,k)&&i($,k)}:null,x=C.createElement("button",{type:"button",key:"decade","aria-label":n.decadeSelect,onClick:function(){s("decade")},tabIndex:-1,className:"".concat(t,"-decade-btn")},_r(m,{locale:n,format:n.yearFormat,generateConfig:r}),"-",_r(p,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:l},C.createElement(Bc,{superOffset:function(E){return r.addYear(o,E*10)},onChange:a,getStart:f,getEnd:h},x),C.createElement(Dd,Qe({},e,{disabledDate:w,titleFormat:n.fieldYearFormat,colNum:3,rowNum:4,baseDate:g,getCellDate:v,getCellText:y,getCellClassName:b}))))}var r7={date:Bp,datetime:ZJ,week:t7,month:JJ,quarter:e7,year:n7,decade:QJ,time:dR};function o7(e,t){var n,r=e.locale,o=e.generateConfig,i=e.direction,a=e.prefixCls,s=e.tabIndex,l=s===void 0?0:s,c=e.multiple,u=e.defaultValue,d=e.value,f=e.onChange,h=e.onSelect,m=e.defaultPickerValue,p=e.pickerValue,g=e.onPickerValueChange,v=e.mode,y=e.onPanelChange,b=e.picker,w=b===void 0?"date":b,x=e.showTime,E=e.hoverValue,k=e.hoverRangeValue,S=e.cellRender,O=e.dateRender,A=e.monthCellRender,$=e.components,M=$===void 0?{}:$,N=e.hideHeader,D=((n=C.useContext(Mi))===null||n===void 0?void 0:n.prefixCls)||a||"rc-picker",T=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:T.current}});var P=YB(e),I=te(P,4),R=I[0],H=I[1],V=I[2],L=I[3],j=GB(r,H),_=w==="date"&&x?"datetime":w,F=C.useMemo(function(){return XB(_,V,L,R,j)},[_,V,L,R,j]),B=o.getNow(),z=yr(w,{value:v,postState:function(pe){return pe||"date"}}),G=te(z,2),W=G[0],q=G[1],U=W==="date"&&F?"datetime":W,Y=uR(o,r,_),ie=yr(u,{value:d}),K=te(ie,2),re=K[0],oe=K[1],ne=C.useMemo(function(){var pe=ml(re).filter(function(ke){return ke});return c?pe:pe.slice(0,1)},[re,c]),ae=cn(function(pe){oe(pe),f&&(pe===null||ne.length!==pe.length||ne.some(function(ke,Ve){return!lo(o,r,ke,pe[Ve],_)}))&&(f==null||f(c?pe:pe[0]))}),de=cn(function(pe){if(h==null||h(pe),W===w){var ke=c?Y(ne,pe):[pe];ae(ke)}}),ge=yr(m||ne[0]||B,{value:p}),Se=te(ge,2),ye=Se[0],be=Se[1];C.useEffect(function(){ne[0]&&!p&&be(ne[0])},[ne[0]]);var ce=function(pe,ke){y==null||y(pe||p,ke||W)},he=function(pe){var ke=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;be(pe),g==null||g(pe),ke&&ce(pe)},Te=function(pe,ke){q(pe),ke&&he(ke),ce(ke,pe)},se=function(pe){if(de(pe),he(pe),W!==w){var ke=["decade","year"],Ve=[].concat(ke,["month"]),Ee={quarter:[].concat(ke,["quarter"]),week:[].concat(ze(Ve),["week"]),date:[].concat(ze(Ve),["date"])},yt=Ee[w]||Ve,Dt=yt.indexOf(W),Ft=yt[Dt+1];Ft&&Te(Ft,pe)}},Pe=C.useMemo(function(){var pe,ke;if(Array.isArray(k)){var Ve=te(k,2);pe=Ve[0],ke=Ve[1]}else pe=k;return!pe&&!ke?null:(pe=pe||ke,ke=ke||pe,o.isAfter(pe,ke)?[ke,pe]:[pe,ke])},[k,o]),De=ak(S,O,A),He=M[U]||r7[U]||Bp,ue=C.useContext(Ya),ve=C.useMemo(function(){return Q(Q({},ue),{},{hideHeader:N})},[ue,N]),xe="".concat(D,"-panel"),fe=Fp(e,["showWeek","prevIcon","nextIcon","superPrevIcon","superNextIcon","disabledDate","minDate","maxDate","onHover"]);return C.createElement(Ya.Provider,{value:ve},C.createElement("div",{ref:T,tabIndex:l,className:me(xe,X({},"".concat(xe,"-rtl"),i==="rtl"))},C.createElement(He,Qe({},fe,{showTime:F,prefixCls:D,locale:j,generateConfig:o,onModeChange:Te,pickerValue:ye,onPickerValueChange:function(pe){he(pe,!0)},value:ne[0],onSelect:se,values:ne,cellRender:De,hoverRangeValue:Pe,hoverValue:E}))))}var Cm=C.memo(C.forwardRef(o7));function i7(e){var t=e.picker,n=e.multiplePanel,r=e.pickerValue,o=e.onPickerValueChange,i=e.needConfirm,a=e.onSubmit,s=e.range,l=e.hoverValue,c=C.useContext(Mi),u=c.prefixCls,d=c.generateConfig,f=C.useCallback(function(y,b){return Cu(d,t,y,b)},[d,t]),h=C.useMemo(function(){return f(r,1)},[r,f]),m=function(y){o(f(y,-1))},p={onCellDblClick:function(){i&&a()}},g=t==="time",v=Q(Q({},e),{},{hoverValue:null,hoverRangeValue:null,hideHeader:g});return s?v.hoverRangeValue=l:v.hoverValue=l,n?C.createElement("div",{className:"".concat(u,"-panels")},C.createElement(Ya.Provider,{value:Q(Q({},p),{},{hideNext:!0})},C.createElement(Cm,v)),C.createElement(Ya.Provider,{value:Q(Q({},p),{},{hidePrev:!0})},C.createElement(Cm,Qe({},v,{pickerValue:h,onPickerValueChange:m})))):C.createElement(Ya.Provider,{value:Q({},p)},C.createElement(Cm,v))}function nA(e){return typeof e=="function"?e():e}function a7(e){var t=e.prefixCls,n=e.presets,r=e.onClick,o=e.onHover;return n.length?C.createElement("div",{className:"".concat(t,"-presets")},C.createElement("ul",null,n.map(function(i,a){var s=i.label,l=i.value;return C.createElement("li",{key:a,onClick:function(){r(nA(l))},onMouseEnter:function(){o(nA(l))},onMouseLeave:function(){o(null)}},s)}))):null}function fR(e){var t=e.panelRender,n=e.internalMode,r=e.picker,o=e.showNow,i=e.range,a=e.multiple,s=e.activeInfo,l=s===void 0?[0,0,0]:s,c=e.presets,u=e.onPresetHover,d=e.onPresetSubmit,f=e.onFocus,h=e.onBlur,m=e.onPanelMouseDown,p=e.direction,g=e.value,v=e.onSelect,y=e.isInvalid,b=e.defaultOpenValue,w=e.onOk,x=e.onSubmit,E=C.useContext(Mi),k=E.prefixCls,S="".concat(k,"-panel"),O=p==="rtl",A=C.useRef(null),$=C.useRef(null),M=C.useState(0),N=te(M,2),D=N[0],T=N[1],P=C.useState(0),I=te(P,2),R=I[0],H=I[1],V=C.useState(0),L=te(V,2),j=L[0],_=L[1],F=function(Te){Te.width&&T(Te.width)},B=te(l,3),z=B[0],G=B[1],W=B[2],q=C.useState(0),U=te(q,2),Y=U[0],ie=U[1];C.useEffect(function(){ie(10)},[z]),C.useEffect(function(){if(i&&$.current){var Te,se=((Te=A.current)===null||Te===void 0?void 0:Te.offsetWidth)||0,Pe=$.current.getBoundingClientRect();if(!Pe.height||Pe.right<0){ie(function(ve){return Math.max(0,ve-1)});return}var De=(O?G-se:z)-Pe.left;if(_(De),D&&D<W){var He=O?Pe.right-(G-se+D):z+se-Pe.left-D,ue=Math.max(0,He);H(ue)}else H(0)}},[Y,O,D,z,G,W,i]);function K(Te){return Te.filter(function(se){return se})}var re=C.useMemo(function(){return K(ml(g))},[g]),oe=r==="time"&&!re.length,ne=C.useMemo(function(){return oe?K([b]):re},[oe,re,b]),ae=oe?b:re,de=C.useMemo(function(){return ne.length?ne.some(function(Te){return y(Te)}):!0},[ne,y]),ge=function(){oe&&v(b),w(),x()},Se=C.createElement("div",{className:"".concat(k,"-panel-layout")},C.createElement(a7,{prefixCls:k,presets:c,onClick:d,onHover:u}),C.createElement("div",null,C.createElement(i7,Qe({},e,{value:ae})),C.createElement(GJ,Qe({},e,{showNow:a?!1:o,invalid:de,onSubmit:ge}))));t&&(Se=t(Se));var ye="".concat(S,"-container"),be="marginLeft",ce="marginRight",he=C.createElement("div",{onMouseDown:m,tabIndex:-1,className:me(ye,"".concat(k,"-").concat(n,"-panel-container")),style:X(X({},O?ce:be,R),O?be:ce,"auto"),onFocus:f,onBlur:h},Se);return i&&(he=C.createElement("div",{onMouseDown:m,ref:$,className:me("".concat(k,"-range-wrapper"),"".concat(k,"-").concat(r,"-range-wrapper"))},C.createElement("div",{ref:A,className:"".concat(k,"-range-arrow"),style:{left:j}}),C.createElement(ea,{onResize:F},he))),he}function hR(e,t){var n=e.format,r=e.maskFormat,o=e.generateConfig,i=e.locale,a=e.preserveInvalidOnBlur,s=e.inputReadOnly,l=e.required,c=e["aria-required"],u=e.onSubmit,d=e.onFocus,f=e.onBlur,h=e.onInputChange,m=e.onInvalid,p=e.open,g=e.onOpenChange,v=e.onKeyDown,y=e.onChange,b=e.activeHelp,w=e.name,x=e.autoComplete,E=e.id,k=e.value,S=e.invalid,O=e.placeholder,A=e.disabled,$=e.activeIndex,M=e.allHelp,N=e.picker,D=function(L,j){var _=o.locale.parse(i.locale,L,[j]);return _&&o.isValidate(_)?_:null},T=n[0],P=C.useCallback(function(L){return _r(L,{locale:i,format:T,generateConfig:o})},[i,o,T]),I=C.useMemo(function(){return k.map(P)},[k,P]),R=C.useMemo(function(){var L=N==="time"?8:10,j=typeof T=="function"?T(o.getNow()).length:T.length;return Math.max(L,j)+2},[T,N,o]),H=function(L){for(var j=0;j<n.length;j+=1){var _=n[j];if(typeof _=="string"){var F=D(L,_);if(F)return F}}return!1},V=function(L){function j(B){return L!==void 0?B[L]:B}var _=Si(e,{aria:!0,data:!0}),F=Q(Q({},_),{},{format:r,validateFormat:function(B){return!!H(B)},preserveInvalidOnBlur:a,readOnly:s,required:l,"aria-required":c,name:w,autoComplete:x,size:R,id:j(E),value:j(I)||"",invalid:j(S),placeholder:j(O),active:$===L,helped:M||b&&$===L,disabled:j(A),onFocus:function(B){d(B,L)},onBlur:function(B){f(B,L)},onSubmit:u,onChange:function(B){h();var z=H(B);if(z){m(!1,L),y(z,L);return}m(!!B,L)},onHelp:function(){g(!0,{index:L})},onKeyDown:function(B){var z=!1;if(v==null||v(B,function(){z=!0}),!B.defaultPrevented&&!z)switch(B.key){case"Escape":g(!1,{index:L});break;case"Enter":p||g(!0);break}}},t==null?void 0:t({valueTexts:I}));return Object.keys(F).forEach(function(B){F[B]===void 0&&delete F[B]}),F};return[V,P]}var s7=["onMouseEnter","onMouseLeave"];function pR(e){return C.useMemo(function(){return Fp(e,s7)},[e])}var l7=["icon","type"],c7=["onClear"];function Rp(e){var t=e.icon,n=e.type,r=tn(e,l7),o=C.useContext(Mi),i=o.prefixCls;return t?C.createElement("span",Qe({className:"".concat(i,"-").concat(n)},r),t):null}function Q2(e){var t=e.onClear,n=tn(e,c7);return C.createElement(Rp,Qe({},n,{type:"clear",role:"button",onMouseDown:function(r){r.preventDefault()},onClick:function(r){r.stopPropagation(),t()}}))}var km=["YYYY","MM","DD","HH","mm","ss","SSS"],rA="\u9867",u7=(function(){function e(t){xr(this,e),X(this,"format",void 0),X(this,"maskFormat",void 0),X(this,"cells",void 0),X(this,"maskCells",void 0),this.format=t;var n=km.map(function(s){return"(".concat(s,")")}).join("|"),r=new RegExp(n,"g");this.maskFormat=t.replace(r,function(s){return rA.repeat(s.length)});var o=new RegExp("(".concat(km.join("|"),")")),i=(t.split(o)||[]).filter(function(s){return s}),a=0;this.cells=i.map(function(s){var l=km.includes(s),c=a,u=a+s.length;return a=u,{text:s,mask:l,start:c,end:u}}),this.maskCells=this.cells.filter(function(s){return s.mask})}return Er(e,[{key:"getSelection",value:function(t){var n=this.maskCells[t]||{},r=n.start,o=n.end;return[r||0,o||0]}},{key:"match",value:function(t){for(var n=0;n<this.maskFormat.length;n+=1){var r=this.maskFormat[n],o=t[n];if(!o||r!==rA&&r!==o)return!1}return!0}},{key:"size",value:function(){return this.maskCells.length}},{key:"getMaskCellIndex",value:function(t){for(var n=Number.MAX_SAFE_INTEGER,r=0,o=0;o<this.maskCells.length;o+=1){var i=this.maskCells[o],a=i.start,s=i.end;if(t>=a&&t<=s)return o;var l=Math.min(Math.abs(t-a),Math.abs(t-s));l<n&&(n=l,r=o)}return r}}]),e})();function d7(e){var t={YYYY:[0,9999,new Date().getFullYear()],MM:[1,12],DD:[1,31],HH:[0,23],mm:[0,59],ss:[0,59],SSS:[0,999]};return t[e]}var f7=["active","showActiveCls","suffixIcon","format","validateFormat","onChange","onInput","helped","onHelp","onSubmit","onKeyDown","preserveInvalidOnBlur","invalid","clearIcon"],J2=C.forwardRef(function(e,t){var n=e.active,r=e.showActiveCls,o=r===void 0?!0:r,i=e.suffixIcon,a=e.format,s=e.validateFormat,l=e.onChange,c=e.helped,u=e.onHelp,d=e.onSubmit,f=e.onKeyDown,h=e.preserveInvalidOnBlur,m=h===void 0?!1:h,p=e.invalid,g=e.clearIcon,v=tn(e,f7),y=e.value,b=e.onFocus,w=e.onBlur,x=e.onMouseUp,E=C.useContext(Mi),k=E.prefixCls,S=E.input,O=S===void 0?"input":S,A="".concat(k,"-input"),$=C.useState(!1),M=te($,2),N=M[0],D=M[1],T=C.useState(y),P=te(T,2),I=P[0],R=P[1],H=C.useState(""),V=te(H,2),L=V[0],j=V[1],_=C.useState(null),F=te(_,2),B=F[0],z=F[1],G=C.useState(null),W=te(G,2),q=W[0],U=W[1],Y=I||"";C.useEffect(function(){R(y)},[y]);var ie=C.useRef(),K=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:ie.current,inputElement:K.current,focus:function(fe){K.current.focus(fe)},blur:function(){K.current.blur()}}});var re=C.useMemo(function(){return new u7(a||"")},[a]),oe=C.useMemo(function(){return c?[0,0]:re.getSelection(B)},[re,B,c]),ne=te(oe,2),ae=ne[0],de=ne[1],ge=function(fe){fe&&fe!==a&&fe!==y&&u()},Se=cn(function(fe){s(fe)&&l(fe),R(fe),ge(fe)}),ye=function(fe){if(!a){var pe=fe.target.value;ge(pe),R(pe),l(pe)}},be=function(fe){var pe=fe.clipboardData.getData("text");s(pe)&&Se(pe)},ce=C.useRef(!1),he=function(){ce.current=!0},Te=function(fe){var pe=fe.target,ke=pe.selectionStart,Ve=re.getMaskCellIndex(ke);z(Ve),U({}),x==null||x(fe),ce.current=!1},se=function(fe){D(!0),z(0),j(""),b(fe)},Pe=function(fe){w(fe)},De=function(fe){D(!1),Pe(fe)};ck(n,function(){!n&&!m&&R(y)});var He=function(fe){fe.key==="Enter"&&s(Y)&&d(),f==null||f(fe)},ue=function(fe){He(fe);var pe=fe.key,ke=null,Ve=null,Ee=de-ae,yt=a.slice(ae,de),Dt=function(Ge){z(function(Xe){var qe=Xe+Ge;return qe=Math.max(qe,0),qe=Math.min(qe,re.size()-1),qe})},Ft=function(Ge){var Xe=d7(yt),qe=te(Xe,3),lt=qe[0],je=qe[1],Rt=qe[2],zt=Y.slice(ae,de),dt=Number(zt);if(isNaN(dt))return String(Rt||(Ge>0?lt:je));var Ct=dt+Ge,jt=je-lt+1;return String(lt+(jt+Ct-lt)%jt)};switch(pe){case"Backspace":case"Delete":ke="",Ve=yt;break;case"ArrowLeft":ke="",Dt(-1);break;case"ArrowRight":ke="",Dt(1);break;case"ArrowUp":ke="",Ve=Ft(1);break;case"ArrowDown":ke="",Ve=Ft(-1);break;default:isNaN(Number(pe))||(ke=L+pe,Ve=ke);break}if(ke!==null&&(j(ke),ke.length>=Ee&&(Dt(1),j(""))),Ve!==null){var Ut=Y.slice(0,ae)+ik(Ve,Ee)+Y.slice(de);Se(Ut.slice(0,a.length))}U({})},ve=C.useRef();mn(function(){if(!(!N||!a||ce.current)){if(!re.match(Y)){Se(a);return}return K.current.setSelectionRange(ae,de),ve.current=en(function(){K.current.setSelectionRange(ae,de)}),function(){en.cancel(ve.current)}}},[re,a,N,Y,B,ae,de,q,Se]);var xe=a?{onFocus:se,onBlur:De,onKeyDown:ue,onMouseDown:he,onMouseUp:Te,onPaste:be}:{};return C.createElement("div",{ref:ie,className:me(A,X(X({},"".concat(A,"-active"),n&&o),"".concat(A,"-placeholder"),c))},C.createElement(O,Qe({ref:K,"aria-invalid":p,autoComplete:"off"},v,{onKeyDown:He,onBlur:Pe},xe,{value:Y,onChange:ye})),C.createElement(Rp,{type:"suffix",icon:i}),g)}),h7=["id","prefix","clearIcon","suffixIcon","separator","activeIndex","activeHelp","allHelp","focused","onFocus","onBlur","onKeyDown","locale","generateConfig","placeholder","className","style","onClick","onClear","value","onChange","onSubmit","onInputChange","format","maskFormat","preserveInvalidOnBlur","onInvalid","disabled","invalid","inputReadOnly","direction","onOpenChange","onActiveInfo","placement","onMouseDown","required","aria-required","autoFocus","tabIndex"],p7=["index"];function g7(e,t){var n=e.id,r=e.prefix,o=e.clearIcon,i=e.suffixIcon,a=e.separator,s=a===void 0?"~":a,l=e.activeIndex,c=e.focused,u=e.placeholder,d=e.className,f=e.style,h=e.onClick,m=e.onClear,p=e.value,g=e.disabled,v=e.invalid,y=e.direction,b=e.onActiveInfo,w=e.onMouseDown,x=e.autoFocus,E=e.tabIndex,k=tn(e,h7),S=y==="rtl",O=C.useContext(Mi),A=O.prefixCls,$=C.useMemo(function(){if(typeof n=="string")return[n];var q=n||{};return[q.start,q.end]},[n]),M=C.useRef(),N=C.useRef(),D=C.useRef(),T=function(q){var U;return(U=[N,D][q])===null||U===void 0?void 0:U.current};C.useImperativeHandle(t,function(){return{nativeElement:M.current,focus:function(q){if(At(q)==="object"){var U,Y=q||{},ie=Y.index,K=ie===void 0?0:ie,re=tn(Y,p7);(U=T(K))===null||U===void 0||U.focus(re)}else{var oe;(oe=T(q??0))===null||oe===void 0||oe.focus()}},blur:function(){var q,U;(q=T(0))===null||q===void 0||q.blur(),(U=T(1))===null||U===void 0||U.blur()}}});var P=pR(k),I=C.useMemo(function(){return Array.isArray(u)?u:[u,u]},[u]),R=hR(Q(Q({},e),{},{id:$,placeholder:I})),H=te(R,1),V=H[0],L=C.useState({position:"absolute",width:0}),j=te(L,2),_=j[0],F=j[1],B=cn(function(){var q=T(l);if(q){var U=q.nativeElement.getBoundingClientRect(),Y=M.current.getBoundingClientRect(),ie=U.left-Y.left;F(function(K){return Q(Q({},K),{},{width:U.width,left:ie})}),b([U.left,U.right,Y.width])}});C.useEffect(function(){B()},[l]);var z=o&&(p[0]&&!g[0]||p[1]&&!g[1]),G=x&&!g[0],W=x&&!G&&!g[1];return C.createElement(ea,{onResize:B},C.createElement("div",Qe({},P,{className:me(A,"".concat(A,"-range"),X(X(X(X({},"".concat(A,"-focused"),c),"".concat(A,"-disabled"),g.every(function(q){return q})),"".concat(A,"-invalid"),v.some(function(q){return q})),"".concat(A,"-rtl"),S),d),style:f,ref:M,onClick:h,onMouseDown:function(q){var U=q.target;U!==N.current.inputElement&&U!==D.current.inputElement&&q.preventDefault(),w==null||w(q)}}),r&&C.createElement("div",{className:"".concat(A,"-prefix")},r),C.createElement(J2,Qe({ref:N},V(0),{autoFocus:G,tabIndex:E,"date-range":"start"})),C.createElement("div",{className:"".concat(A,"-range-separator")},s),C.createElement(J2,Qe({ref:D},V(1),{autoFocus:W,tabIndex:E,"date-range":"end"})),C.createElement("div",{className:"".concat(A,"-active-bar"),style:_}),C.createElement(Rp,{type:"suffix",icon:i}),z&&C.createElement(Q2,{icon:o,onClear:m})))}var m7=C.forwardRef(g7);function oA(e,t){var n=e??t;return Array.isArray(n)?n:[n,n]}function uf(e){return e===1?"end":"start"}function v7(e,t){var n=QB(e,function(){var ft=e.disabled,Tt=e.allowEmpty,Bn=oA(ft,!1),zn=oA(Tt,!1);return{disabled:Bn,allowEmpty:zn}}),r=te(n,6),o=r[0],i=r[1],a=r[2],s=r[3],l=r[4],c=r[5],u=o.prefixCls,d=o.styles,f=o.classNames,h=o.defaultValue,m=o.value,p=o.needConfirm,g=o.onKeyDown,v=o.disabled,y=o.allowEmpty,b=o.disabledDate,w=o.minDate,x=o.maxDate,E=o.defaultOpen,k=o.open,S=o.onOpenChange,O=o.locale,A=o.generateConfig,$=o.picker,M=o.showNow,N=o.showToday,D=o.showTime,T=o.mode,P=o.onPanelChange,I=o.onCalendarChange,R=o.onOk,H=o.defaultPickerValue,V=o.pickerValue,L=o.onPickerValueChange,j=o.inputReadOnly,_=o.suffixIcon,F=o.onFocus,B=o.onBlur,z=o.presets,G=o.ranges,W=o.components,q=o.cellRender,U=o.dateRender,Y=o.monthCellRender,ie=o.onClick,K=eR(t),re=JB(k,E,v,S),oe=te(re,2),ne=oe[0],ae=oe[1],de=function(ft,Tt){(v.some(function(Bn){return!Bn})||!ft)&&ae(ft,Tt)},ge=sR(A,O,s,!0,!1,h,m,I,R),Se=te(ge,5),ye=Se[0],be=Se[1],ce=Se[2],he=Se[3],Te=Se[4],se=ce(),Pe=nR(v,y,ne),De=te(Pe,9),He=De[0],ue=De[1],ve=De[2],xe=De[3],fe=De[4],pe=De[5],ke=De[6],Ve=De[7],Ee=De[8],yt=function(ft,Tt){ue(!0),F==null||F(ft,{range:uf(Tt??xe)})},Dt=function(ft,Tt){ue(!1),B==null||B(ft,{range:uf(Tt??xe)})},Ft=C.useMemo(function(){if(!D)return null;var ft=D.disabledTime,Tt=ft?function(Bn){var zn=uf(xe),gr=zB(se,ke,xe);return ft(Bn,zn,{from:gr})}:void 0;return Q(Q({},D),{},{disabledTime:Tt})},[D,xe,se,ke]),Ut=yr([$,$],{value:T}),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1],lt=Xe[xe]||$,je=lt==="date"&&Ft?"datetime":lt,Rt=je===$&&je!=="time",zt=cR($,lt,M,N,!0),dt=lR(o,ye,be,ce,he,v,s,He,ne,c),Ct=te(dt,2),jt=Ct[0],Ie=Ct[1],Ne=zJ(se,v,ke,A,O,b),Oe=WB(se,c,y),_e=te(Oe,2),mt=_e[0],kt=_e[1],Pt=rR(A,O,se,Xe,ne,xe,i,Rt,H,V,Ft==null?void 0:Ft.defaultOpenValue,L,w,x),Xt=te(Pt,2),on=Xt[0],qt=Xt[1],wn=cn(function(ft,Tt,Bn){var zn=Pu(Xe,xe,Tt);if((zn[0]!==Xe[0]||zn[1]!==Xe[1])&&qe(zn),P&&Bn!==!1){var gr=ze(se);ft&&(gr[xe]=ft),P(gr,zn)}}),vn=function(ft,Tt){return Pu(se,Tt,ft)},Kt=function(ft,Tt){var Bn=se;ft&&(Bn=vn(ft,xe)),Ve(xe);var zn=pe(Bn);he(Bn),jt(xe,zn===null),zn===null?de(!1,{force:!0}):Tt||K.current.focus({index:zn})},$n=function(ft){var Tt,Bn=ft.target.getRootNode();if(!K.current.nativeElement.contains((Tt=Bn.activeElement)!==null&&Tt!==void 0?Tt:document.activeElement)){var zn=v.findIndex(function(gr){return!gr});zn>=0&&K.current.focus({index:zn})}de(!0),ie==null||ie(ft)},On=function(){Ie(null),de(!1,{force:!0})},ur=C.useState(null),We=te(ur,2),pt=We[0],Ke=We[1],rt=C.useState(null),ht=te(rt,2),an=ht[0],dn=ht[1],Un=C.useMemo(function(){return an||se},[se,an]);C.useEffect(function(){ne||dn(null)},[ne]);var dr=C.useState([0,0,0]),Nn=te(dr,2),Dn=Nn[0],wr=Nn[1],ar=tR(z,G),J=function(ft){dn(ft),Ke("preset")},Z=function(ft){var Tt=Ie(ft);Tt&&de(!1,{force:!0})},$e=function(ft){Kt(ft)},Ae=function(ft){dn(ft?vn(ft,xe):null),Ke("cell")},tt=function(ft){de(!0),yt(ft)},vt=function(){ve("panel")},Ot=function(ft){var Tt=Pu(se,xe,ft);he(Tt),!p&&!a&&i===je&&Kt(ft)},wt=function(){de(!1)},ot=ak(q,U,Y,uf(xe)),Mt=se[xe]||null,Zt=cn(function(ft){return c(ft,{activeIndex:xe})}),Ue=C.useMemo(function(){var ft=Si(o,!1),Tt=ta(o,[].concat(ze(Object.keys(ft)),["onChange","onCalendarChange","style","className","onPanelChange","disabledTime"]));return Tt},[o]),Ye=C.createElement(fR,Qe({},Ue,{showNow:zt,showTime:Ft,range:!0,multiplePanel:Rt,activeInfo:Dn,disabledDate:Ne,onFocus:tt,onBlur:Dt,onPanelMouseDown:vt,picker:$,mode:lt,internalMode:je,onPanelChange:wn,format:l,value:Mt,isInvalid:Zt,onChange:null,onSelect:Ot,pickerValue:on,defaultOpenValue:ml(D==null?void 0:D.defaultOpenValue)[xe],onPickerValueChange:qt,hoverValue:Un,onHover:Ae,needConfirm:p,onSubmit:Kt,onOk:Te,presets:ar,onPresetHover:J,onPresetSubmit:Z,onNow:$e,cellRender:ot})),ct=function(ft,Tt){var Bn=vn(ft,Tt);he(Bn)},It=function(){ve("input")},Cn=function(ft,Tt){var Bn=ke.length,zn=ke[Bn-1];if(Bn&&zn!==Tt&&p&&!y[zn]&&!Ee(zn)&&se[zn]){K.current.focus({index:zn});return}ve("input"),de(!0,{inherit:!0}),xe!==Tt&&ne&&!p&&a&&Kt(null,!0),fe(Tt),yt(ft,Tt)},bt=function(ft,Tt){if(de(!1),!p&&ve()==="input"){var Bn=pe(se);jt(xe,Bn===null)}Dt(ft,Tt)},Wt=function(ft,Tt){ft.key==="Tab"&&Kt(null,!0),g==null||g(ft,Tt)},Fn=C.useMemo(function(){return{prefixCls:u,locale:O,generateConfig:A,button:W.button,input:W.input}},[u,O,A,W.button,W.input]);return mn(function(){ne&&xe!==void 0&&wn(null,$,!1)},[ne,xe,$]),mn(function(){var ft=ve();!ne&&ft==="input"&&(de(!1),Kt(null,!0)),!ne&&a&&!p&&ft==="panel"&&(de(!0),Kt())},[ne]),C.createElement(Mi.Provider,{value:Fn},C.createElement(jB,Qe({},HB(o),{popupElement:Ye,popupStyle:d.popup,popupClassName:f.popup,visible:ne,onClose:wt,range:!0}),C.createElement(m7,Qe({},o,{ref:K,suffixIcon:_,activeIndex:He||ne?xe:null,activeHelp:!!an,allHelp:!!an&&pt==="preset",focused:He,onFocus:Cn,onBlur:bt,onKeyDown:Wt,onSubmit:Kt,value:Un,maskFormat:l,onChange:ct,onInputChange:It,format:s,inputReadOnly:j,disabled:v,open:ne,onOpenChange:de,onClick:$n,onClear:On,invalid:mt,onInvalid:kt,onActiveInfo:wr}))))}var y7=C.forwardRef(v7);function b7(e){var t=e.prefixCls,n=e.value,r=e.onRemove,o=e.removeIcon,i=o===void 0?"\xD7":o,a=e.formatDate,s=e.disabled,l=e.maxTagCount,c=e.placeholder,u="".concat(t,"-selector"),d="".concat(t,"-selection"),f="".concat(d,"-overflow");function h(g,v){return C.createElement("span",{className:me("".concat(d,"-item")),title:typeof g=="string"?g:null},C.createElement("span",{className:"".concat(d,"-item-content")},g),!s&&v&&C.createElement("span",{onMouseDown:function(y){y.preventDefault()},onClick:v,className:"".concat(d,"-item-remove")},i))}function m(g){var v=a(g),y=function(b){b&&b.stopPropagation(),r(g)};return h(v,y)}function p(g){var v="+ ".concat(g.length," ...");return h(v)}return C.createElement("div",{className:u},C.createElement(Fc,{prefixCls:f,data:n,renderItem:m,renderRest:p,itemKey:function(g){return a(g)},maxCount:l}),!n.length&&C.createElement("span",{className:"".concat(t,"-selection-placeholder")},c))}var x7=["id","open","prefix","clearIcon","suffixIcon","activeHelp","allHelp","focused","onFocus","onBlur","onKeyDown","locale","generateConfig","placeholder","className","style","onClick","onClear","internalPicker","value","onChange","onSubmit","onInputChange","multiple","maxTagCount","format","maskFormat","preserveInvalidOnBlur","onInvalid","disabled","invalid","inputReadOnly","direction","onOpenChange","onMouseDown","required","aria-required","autoFocus","tabIndex","removeIcon"];function E7(e,t){var n=e.open,r=e.prefix,o=e.clearIcon,i=e.suffixIcon,a=e.focused,s=e.locale,l=e.generateConfig,c=e.placeholder,u=e.className,d=e.style,f=e.onClick,h=e.onClear,m=e.internalPicker,p=e.value,g=e.onChange,v=e.onSubmit,y=e.multiple,b=e.maxTagCount,w=e.disabled,x=e.invalid,E=e.direction,k=e.onMouseDown,S=e.autoFocus,O=e.tabIndex,A=e.removeIcon,$=tn(e,x7),M=E==="rtl",N=C.useContext(Mi),D=N.prefixCls,T=C.useRef(),P=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:T.current,focus:function(z){var G;(G=P.current)===null||G===void 0||G.focus(z)},blur:function(){var z;(z=P.current)===null||z===void 0||z.blur()}}});var I=pR($),R=function(z){g([z])},H=function(z){var G=p.filter(function(W){return W&&!lo(l,s,W,z,m)});g(G),n||v()},V=hR(Q(Q({},e),{},{onChange:R}),function(z){var G=z.valueTexts;return{value:G[0]||"",active:a}}),L=te(V,2),j=L[0],_=L[1],F=!!(o&&p.length&&!w),B=y?C.createElement(C.Fragment,null,C.createElement(b7,{prefixCls:D,value:p,onRemove:H,formatDate:_,maxTagCount:b,disabled:w,removeIcon:A,placeholder:c}),C.createElement("input",{className:"".concat(D,"-multiple-input"),value:p.map(_).join(","),ref:P,readOnly:!0,autoFocus:S,tabIndex:O}),C.createElement(Rp,{type:"suffix",icon:i}),F&&C.createElement(Q2,{icon:o,onClear:h})):C.createElement(J2,Qe({ref:P},j(),{autoFocus:S,tabIndex:O,suffixIcon:i,clearIcon:F&&C.createElement(Q2,{icon:o,onClear:h}),showActiveCls:!1}));return C.createElement("div",Qe({},I,{className:me(D,X(X(X(X(X({},"".concat(D,"-multiple"),y),"".concat(D,"-focused"),a),"".concat(D,"-disabled"),w),"".concat(D,"-invalid"),x),"".concat(D,"-rtl"),M),u),style:d,ref:T,onClick:f,onMouseDown:function(z){var G,W=z.target;W!==((G=P.current)===null||G===void 0?void 0:G.inputElement)&&z.preventDefault(),k==null||k(z)}}),r&&C.createElement("div",{className:"".concat(D,"-prefix")},r),B)}var w7=C.forwardRef(E7);function C7(e,t){var n=QB(e),r=te(n,6),o=r[0],i=r[1],a=r[2],s=r[3],l=r[4],c=r[5],u=o,d=u.prefixCls,f=u.styles,h=u.classNames,m=u.order,p=u.defaultValue,g=u.value,v=u.needConfirm,y=u.onChange,b=u.onKeyDown,w=u.disabled,x=u.disabledDate,E=u.minDate,k=u.maxDate,S=u.defaultOpen,O=u.open,A=u.onOpenChange,$=u.locale,M=u.generateConfig,N=u.picker,D=u.showNow,T=u.showToday,P=u.showTime,I=u.mode,R=u.onPanelChange,H=u.onCalendarChange,V=u.onOk,L=u.multiple,j=u.defaultPickerValue,_=u.pickerValue,F=u.onPickerValueChange,B=u.inputReadOnly,z=u.suffixIcon,G=u.removeIcon,W=u.onFocus,q=u.onBlur,U=u.presets,Y=u.components,ie=u.cellRender,K=u.dateRender,re=u.monthCellRender,oe=u.onClick,ne=eR(t);function ae(Ue){return Ue===null?null:L?Ue:Ue[0]}var de=uR(M,$,i),ge=JB(O,S,[w],A),Se=te(ge,2),ye=Se[0],be=Se[1],ce=function(Ue,Ye,ct){if(H){var It=Q({},ct);delete It.range,H(ae(Ue),ae(Ye),It)}},he=function(Ue){V==null||V(ae(Ue))},Te=sR(M,$,s,!1,m,p,g,ce,he),se=te(Te,5),Pe=se[0],De=se[1],He=se[2],ue=se[3],ve=se[4],xe=He(),fe=nR([w]),pe=te(fe,4),ke=pe[0],Ve=pe[1],Ee=pe[2],yt=pe[3],Dt=function(Ue){Ve(!0),W==null||W(Ue,{})},Ft=function(Ue){Ve(!1),q==null||q(Ue,{})},Ut=yr(N,{value:I}),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1],lt=Xe==="date"&&P?"datetime":Xe,je=cR(N,Xe,D,T),Rt=y&&function(Ue,Ye){y(ae(Ue),ae(Ye))},zt=lR(Q(Q({},o),{},{onChange:Rt}),Pe,De,He,ue,[],s,ke,ye,c),dt=te(zt,2),Ct=dt[1],jt=WB(xe,c),Ie=te(jt,2),Ne=Ie[0],Oe=Ie[1],_e=C.useMemo(function(){return Ne.some(function(Ue){return Ue})},[Ne]),mt=function(Ue,Ye){if(F){var ct=Q(Q({},Ye),{},{mode:Ye.mode[0]});delete ct.range,F(Ue[0],ct)}},kt=rR(M,$,xe,[Xe],ye,yt,i,!1,j,_,ml(P==null?void 0:P.defaultOpenValue),mt,E,k),Pt=te(kt,2),Xt=Pt[0],on=Pt[1],qt=cn(function(Ue,Ye,ct){if(qe(Ye),R&&ct!==!1){var It=Ue||xe[xe.length-1];R(It,Ye)}}),wn=function(){Ct(He()),be(!1,{force:!0})},vn=function(Ue){!w&&!ne.current.nativeElement.contains(document.activeElement)&&ne.current.focus(),be(!0),oe==null||oe(Ue)},Kt=function(){Ct(null),be(!1,{force:!0})},$n=C.useState(null),On=te($n,2),ur=On[0],We=On[1],pt=C.useState(null),Ke=te(pt,2),rt=Ke[0],ht=Ke[1],an=C.useMemo(function(){var Ue=[rt].concat(ze(xe)).filter(function(Ye){return Ye});return L?Ue:Ue.slice(0,1)},[xe,rt,L]),dn=C.useMemo(function(){return!L&&rt?[rt]:xe.filter(function(Ue){return Ue})},[xe,rt,L]);C.useEffect(function(){ye||ht(null)},[ye]);var Un=tR(U),dr=function(Ue){ht(Ue),We("preset")},Nn=function(Ue){var Ye=L?de(He(),Ue):[Ue],ct=Ct(Ye);ct&&!L&&be(!1,{force:!0})},Dn=function(Ue){Nn(Ue)},wr=function(Ue){ht(Ue),We("cell")},ar=function(Ue){be(!0),Dt(Ue)},J=function(Ue){if(Ee("panel"),!(L&<!==N)){var Ye=L?de(He(),Ue):[Ue];ue(Ye),!v&&!a&&i===lt&&wn()}},Z=function(){be(!1)},$e=ak(ie,K,re),Ae=C.useMemo(function(){var Ue=Si(o,!1),Ye=ta(o,[].concat(ze(Object.keys(Ue)),["onChange","onCalendarChange","style","className","onPanelChange"]));return Q(Q({},Ye),{},{multiple:o.multiple})},[o]),tt=C.createElement(fR,Qe({},Ae,{showNow:je,showTime:P,disabledDate:x,onFocus:ar,onBlur:Ft,picker:N,mode:Xe,internalMode:lt,onPanelChange:qt,format:l,value:xe,isInvalid:c,onChange:null,onSelect:J,pickerValue:Xt,defaultOpenValue:P==null?void 0:P.defaultOpenValue,onPickerValueChange:on,hoverValue:an,onHover:wr,needConfirm:v,onSubmit:wn,onOk:ve,presets:Un,onPresetHover:dr,onPresetSubmit:Nn,onNow:Dn,cellRender:$e})),vt=function(Ue){ue(Ue)},Ot=function(){Ee("input")},wt=function(Ue){Ee("input"),be(!0,{inherit:!0}),Dt(Ue)},ot=function(Ue){be(!1),Ft(Ue)},Mt=function(Ue,Ye){Ue.key==="Tab"&&wn(),b==null||b(Ue,Ye)},Zt=C.useMemo(function(){return{prefixCls:d,locale:$,generateConfig:M,button:Y.button,input:Y.input}},[d,$,M,Y.button,Y.input]);return mn(function(){ye&&yt!==void 0&&qt(null,N,!1)},[ye,yt,N]),mn(function(){var Ue=Ee();!ye&&Ue==="input"&&(be(!1),wn()),!ye&&a&&!v&&Ue==="panel"&&wn()},[ye]),C.createElement(Mi.Provider,{value:Zt},C.createElement(jB,Qe({},HB(o),{popupElement:tt,popupStyle:f.popup,popupClassName:h.popup,visible:ye,onClose:Z}),C.createElement(w7,Qe({},o,{ref:ne,suffixIcon:z,removeIcon:G,activeHelp:!!rt,allHelp:!!rt&&ur==="preset",focused:ke,onFocus:wt,onBlur:ot,onKeyDown:Mt,onSubmit:wn,value:dn,maskFormat:l,onChange:vt,onInputChange:Ot,internalPicker:i,format:s,inputReadOnly:B,disabled:w,open:ye,onOpenChange:be,onClick:vn,onClear:Kt,invalid:_e,onInvalid:function(Ue){Oe(Ue,0)}}))))}var k7=C.forwardRef(C7);const gR=C.createContext(null),S7=gR.Provider,mR=C.createContext(null),A7=mR.Provider;var $7=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],O7=Oi(function(e,t){var n=e.prefixCls,r=n===void 0?"rc-checkbox":n,o=e.className,i=e.style,a=e.checked,s=e.disabled,l=e.defaultChecked,c=l===void 0?!1:l,u=e.type,d=u===void 0?"checkbox":u,f=e.title,h=e.onChange,m=tn(e,$7),p=et(null),g=et(null),v=yr(c,{value:a}),y=te(v,2),b=y[0],w=y[1];Oc(t,function(){return{focus:function(k){var S;(S=p.current)===null||S===void 0||S.focus(k)},blur:function(){var k;(k=p.current)===null||k===void 0||k.blur()},input:p.current,nativeElement:g.current}});var x=me(r,o,X(X({},"".concat(r,"-checked"),b),"".concat(r,"-disabled"),s)),E=function(k){s||("checked"in e||w(k.target.checked),h==null||h({target:Q(Q({},e),{},{type:d,checked:k.target.checked}),stopPropagation:function(){k.stopPropagation()},preventDefault:function(){k.preventDefault()},nativeEvent:k.nativeEvent}))};return C.createElement("span",{className:x,title:f,style:i,ref:g},C.createElement("input",Qe({},m,{className:"".concat(r,"-input"),ref:p,onChange:E,disabled:s,checked:!!b,type:d})),C.createElement("span",{className:"".concat(r,"-inner")}))});function M7(e){const t=we.useRef(null),n=()=>{en.cancel(t.current),t.current=null};return[()=>{n(),t.current=en(()=>{t.current=null})},r=>{t.current&&(r.stopPropagation(),n()),e==null||e(r)}]}const N7=e=>{const{componentCls:t,antCls:n}=e,r=`${t}-group`;return{[r]:Object.assign(Object.assign({},br(e)),{display:"inline-block",fontSize:0,[`&${r}-rtl`]:{direction:"rtl"},[`&${r}-block`]:{display:"flex"},[`${n}-badge ${n}-badge-count`]:{zIndex:1},[`> ${n}-badge:not(:first-child) > ${n}-button-wrapper`]:{borderInlineStart:"none"}})}},D7=e=>{const{componentCls:t,wrapperMarginInlineEnd:n,colorPrimary:r,radioSize:o,motionDurationSlow:i,motionDurationMid:a,motionEaseInOutCirc:s,colorBgContainer:l,colorBorder:c,lineWidth:u,colorBgContainerDisabled:d,colorTextDisabled:f,paddingXS:h,dotColorDisabled:m,lineType:p,radioColor:g,radioBgColor:v,calc:y}=e,b=`${t}-inner`,w=y(o).sub(y(4).mul(2)),x=y(1).mul(o).equal({unit:!0});return{[`${t}-wrapper`]:Object.assign(Object.assign({},br(e)),{display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:n,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}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${Ce(u)} ${p} ${r}`,borderRadius:"50%",visibility:"hidden",opacity:0,content:'""'},[t]:Object.assign(Object.assign({},br(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center",borderRadius:"50%"}),[`${t}-wrapper:hover &,
|
|
313
|
+
`]:{paddingInlineEnd:e.calc(e.fontSize).mul(1.5).equal()}}}},xm(Mn(e,{controlHeight:e.singleItemHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG}),"lg")]}const WZ=e=>{const{fontSize:t,lineHeight:n,lineWidth:r,controlHeight:o,controlHeightSM:i,controlHeightLG:a,paddingXXS:s,controlPaddingHorizontal:l,zIndexPopupBase:c,colorText:u,fontWeightStrong:d,controlItemBgActive:f,controlItemBgHover:h,colorBgContainer:m,colorFillSecondary:p,colorBgContainerDisabled:g,colorTextDisabled:v,colorPrimaryHover:y,colorPrimary:b,controlOutline:w}=e,x=s*2,E=r*2,k=Math.min(o-x,o-E),S=Math.min(i-x,i-E),O=Math.min(a-x,a-E);return{INTERNAL_FIXED_ITEM_MARGIN:Math.floor(s/2),zIndexPopup:c+50,optionSelectedColor:u,optionSelectedFontWeight:d,optionSelectedBg:f,optionActiveBg:h,optionPadding:`${(o-t*n)/2}px ${l}px`,optionFontSize:t,optionLineHeight:n,optionHeight:o,selectorBg:m,clearBg:m,singleItemHeightLG:a,multipleItemBg:p,multipleItemBorderColor:"transparent",multipleItemHeight:k,multipleItemHeightSM:S,multipleItemHeightLG:O,multipleSelectorBgDisabled:g,multipleItemColorDisabled:v,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(e.fontSize*1.25),hoverBorderColor:y,activeBorderColor:b,activeOutlineColor:w,selectAffixPadding:s}},wB=(e,t)=>{const{componentCls:n,antCls:r,controlOutlineWidth:o}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{border:`${Ce(e.lineWidth)} ${e.lineType} ${t.borderColor}`,background:e.selectorBg},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{borderColor:t.hoverBorderHover},[`${n}-focused& ${n}-selector`]:{borderColor:t.activeBorderColor,boxShadow:`0 0 0 ${Ce(o)} ${t.activeOutlineColor}`,outline:0},[`${n}-prefix`]:{color:t.color}}}},W6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},wB(e,t))}),VZ=e=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},wB(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeOutlineColor:e.activeOutlineColor,color:e.colorText})),W6(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,activeOutlineColor:e.colorErrorOutline,color:e.colorError})),W6(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,activeOutlineColor:e.colorWarningOutline,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),CB=(e,t)=>{const{componentCls:n,antCls:r}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{background:t.bg,border:`${Ce(e.lineWidth)} ${e.lineType} transparent`,color:t.color},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{background:t.hoverBg},[`${n}-focused& ${n}-selector`]:{background:e.selectorBg,borderColor:t.activeBorderColor,outline:0}}}},V6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},CB(e,t))}),GZ=e=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},CB(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor,color:e.colorText})),V6(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,color:e.colorError})),V6(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{borderColor:e.colorBorder,background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.colorBgContainer,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorSplit}`}})}),UZ=e=>({"&-borderless":{[`${e.componentCls}-selector`]:{background:"transparent",border:`${Ce(e.lineWidth)} ${e.lineType} transparent`},[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`},[`&${e.componentCls}-status-error`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorError}},[`&${e.componentCls}-status-warning`]:{[`${e.componentCls}-prefix, ${e.componentCls}-selection-item`]:{color:e.colorWarning}}}}),kB=(e,t)=>{const{componentCls:n,antCls:r}=e;return{[`&:not(${n}-customize-input) ${n}-selector`]:{borderWidth:`0 0 ${Ce(e.lineWidth)} 0`,borderStyle:`none none ${e.lineType} none`,borderColor:t.borderColor,background:e.selectorBg,borderRadius:0},[`&:not(${n}-disabled):not(${n}-customize-input):not(${r}-pagination-size-changer)`]:{[`&:hover ${n}-selector`]:{borderColor:t.hoverBorderHover},[`${n}-focused& ${n}-selector`]:{borderColor:t.activeBorderColor,outline:0},[`${n}-prefix`]:{color:t.color}}}},G6=(e,t)=>({[`&${e.componentCls}-status-${t.status}`]:Object.assign({},kB(e,t))}),qZ=e=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign({},kB(e,{borderColor:e.colorBorder,hoverBorderHover:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,color:e.colorText})),G6(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,color:e.colorError})),G6(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{[`&${e.componentCls}-disabled`]:{[`&:not(${e.componentCls}-customize-input) ${e.componentCls}-selector`]:{color:e.colorTextDisabled}},[`&${e.componentCls}-multiple ${e.componentCls}-selection-item`]:{background:e.multipleItemBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.multipleItemBorderColor}`}})}),YZ=e=>({[e.componentCls]:Object.assign(Object.assign(Object.assign(Object.assign({},VZ(e)),GZ(e)),UZ(e)),qZ(e))}),XZ=e=>{const{componentCls:t}=e;return{position:"relative",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,input:{cursor:"pointer"},[`${t}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},[`${t}-disabled&`]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},KZ=e=>{const{componentCls:t}=e;return{[`${t}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},ZZ=e=>{const{antCls:t,componentCls:n,inputPaddingHorizontalBase:r,iconCls:o}=e,i={[`${n}-clear`]:{opacity:1,background:e.colorBgBase,borderRadius:"50%"}};return{[n]:Object.assign(Object.assign({},br(e)),{position:"relative",display:"inline-flex",cursor:"pointer",[`&:not(${n}-customize-input) ${n}-selector`]:Object.assign(Object.assign({},XZ(e)),KZ(e)),[`${n}-selection-item`]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},c0),{[`> ${t}-typography`]:{display:"inline"}}),[`${n}-selection-placeholder`]:Object.assign(Object.assign({},c0),{flex:1,color:e.colorTextPlaceholder,pointerEvents:"none"}),[`${n}-arrow`]:Object.assign(Object.assign({},kd()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:`opacity ${e.motionDurationSlow} ease`,[o]:{verticalAlign:"top",transition:`transform ${e.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${n}-suffix)`]:{pointerEvents:"auto"}},[`${n}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${n}-selection-wrap`]:{display:"flex",width:"100%",position:"relative",minWidth:0,"&:after":{content:'"\\a0"',width:0,overflow:"hidden"}},[`${n}-prefix`]:{flex:"none",marginInlineEnd:e.selectAffixPadding},[`${n}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,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 ${e.motionDurationMid} ease, opacity ${e.motionDurationSlow} ease`,textRendering:"auto",transform:"translateZ(0)","&:before":{display:"block"},"&:hover":{color:e.colorIcon}},"@media(hover:none)":i,"&:hover":i}),[`${n}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${n}-has-feedback`]:{[`${n}-clear`]:{insetInlineEnd:e.calc(r).add(e.fontSize).add(e.paddingXS).equal()}}}}}},QZ=e=>{const{componentCls:t}=e;return[{[t]:{[`&${t}-in-form-item`]:{width:"100%"}}},ZZ(e),HZ(e),zZ(e),_Z(e),{[`${t}-rtl`]:{direction:"rtl"}},$d(e,{borderElCls:`${t}-selector`,focusElCls:`${t}-focused`})]},JZ=Pr("Select",(e,{rootPrefixCls:t})=>{const n=Mn(e,{rootPrefixCls:t,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[QZ(n),YZ(n)]},WZ,{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}});var eQ={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"},tQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:eQ}))},nQ=C.forwardRef(tQ),rQ={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"},oQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:rQ}))},SB=C.forwardRef(oQ),iQ={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"},aQ=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:iQ}))},AB=C.forwardRef(aQ);function $B({suffixIcon:e,clearIcon:t,menuItemSelectedIcon:n,removeIcon:r,loading:o,multiple:i,hasFeedback:a,prefixCls:s,showSuffixIcon:l,feedbackIcon:c,showArrow:u,componentName:d}){const f=t??C.createElement(bp,null),h=v=>e===null&&!a&&!u?null:C.createElement(C.Fragment,null,l!==!1&&v,a&&c);let m=null;if(e!==void 0)m=h(e);else if(o)m=h(C.createElement(Sd,{spin:!0}));else{const v=`${s}-suffix`;m=({open:y,showSearch:b})=>h(y&&b?C.createElement(AB,{className:v}):C.createElement(SB,{className:v}))}let p=null;n!==void 0?p=n:i?p=C.createElement(nQ,null):p=null;let g=null;return r!==void 0?g=r:g=C.createElement(BC,null),{clearIcon:f,suffixIcon:m,itemIcon:p,removeIcon:g}}function sQ(e){return we.useMemo(()=>{if(e)return(...t)=>we.createElement(ts,{space:!0},e.apply(void 0,t))},[e])}function lQ(e,t){return t!==void 0?t:e!==null}var cQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const OB="SECRET_COMBOBOX_MODE_DO_NOT_USE",uQ=(e,t)=>{var n,r,o,i,a;const{prefixCls:s,bordered:l,className:c,rootClassName:u,getPopupContainer:d,popupClassName:f,dropdownClassName:h,listHeight:m=256,placement:p,listItemHeight:g,size:v,disabled:y,notFoundContent:b,status:w,builtinPlacements:x,dropdownMatchSelectWidth:E,popupMatchSelectWidth:k,direction:S,style:O,allowClear:A,variant:$,dropdownStyle:M,transitionName:N,tagRender:D,maxCount:T,prefix:P,dropdownRender:I,popupRender:R,onDropdownVisibleChange:H,onOpenChange:V,styles:L,classNames:j}=e,_=cQ(e,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount","prefix","dropdownRender","popupRender","onDropdownVisibleChange","onOpenChange","styles","classNames"]),{getPopupContainer:F,getPrefixCls:B,renderEmpty:z,direction:G,virtual:W,popupMatchSelectWidth:q,popupOverflow:U}=C.useContext(pn),{showSearch:Y,style:ie,styles:K,className:re,classNames:oe}=xa("select"),[,ne]=ii(),ae=g??(ne==null?void 0:ne.controlHeight),de=B("select",s),ge=B(),Se=S??G,{compactSize:ye,compactItemClassnames:be}=ps(de,Se),[ce,he]=Pc("select",$,l),Te=Ro(de),[se,Pe,De]=JZ(de,Te),He=C.useMemo(()=>{const{mode:_e}=e;if(_e!=="combobox")return _e===OB?"combobox":_e},[e.mode]),ue=He==="multiple"||He==="tags",ve=lQ(e.suffixIcon,e.showArrow),xe=(n=k??E)!==null&&n!==void 0?n:q,fe=((r=L==null?void 0:L.popup)===null||r===void 0?void 0:r.root)||((o=K.popup)===null||o===void 0?void 0:o.root)||M,pe=sQ(R||I),ke=V||H,{status:Ve,hasFeedback:Ee,isFormItemInput:yt,feedbackIcon:Dt}=C.useContext(Yr),Pt=pl(Ve,w);let Ut;b!==void 0?Ut=b:He==="combobox"?Ut=null:Ut=(z==null?void 0:z("Select"))||C.createElement(IZ,{componentName:"Select"});const{suffixIcon:Ge,itemIcon:Xe,removeIcon:qe,clearIcon:lt}=$B(Object.assign(Object.assign({},_),{multiple:ue,hasFeedback:Ee,feedbackIcon:Dt,showSuffixIcon:ve,prefixCls:de,componentName:"Select"})),je=A===!0?{clearIcon:lt}:A,Rt=ta(_,["suffixIcon","itemIcon"]),zt=me(((i=j==null?void 0:j.popup)===null||i===void 0?void 0:i.root)||((a=oe==null?void 0:oe.popup)===null||a===void 0?void 0:a.root)||f||h,{[`${de}-dropdown-${Se}`]:Se==="rtl"},u,oe.root,j==null?void 0:j.root,De,Te,Pe),dt=ai(_e=>{var mt;return(mt=v??ye)!==null&&mt!==void 0?mt:_e}),Ct=C.useContext(vo),jt=y??Ct,Ie=me({[`${de}-lg`]:dt==="large",[`${de}-sm`]:dt==="small",[`${de}-rtl`]:Se==="rtl",[`${de}-${ce}`]:he,[`${de}-in-form-item`]:yt},ns(de,Pt,Ee),be,re,c,oe.root,j==null?void 0:j.root,u,De,Te,Pe),Ne=C.useMemo(()=>p!==void 0?p:Se==="rtl"?"bottomRight":"bottomLeft",[p,Se]),[Oe]=xp("SelectLike",fe==null?void 0:fe.zIndex);return se(C.createElement(ok,Object.assign({ref:t,virtual:W,showSearch:Y},Rt,{style:Object.assign(Object.assign(Object.assign(Object.assign({},K.root),L==null?void 0:L.root),ie),O),dropdownMatchSelectWidth:xe,transitionName:LI(ge,"slide-up",N),builtinPlacements:RZ(x,U),listHeight:m,listItemHeight:ae,mode:He,prefixCls:de,placement:Ne,direction:Se,prefix:P,suffixIcon:Ge,menuItemSelectedIcon:Xe,removeIcon:qe,allowClear:je,notFoundContent:Ut,className:Ie,getPopupContainer:d||F,dropdownClassName:zt,disabled:jt,dropdownStyle:Object.assign(Object.assign({},fe),{zIndex:Oe}),maxCount:ue?T:void 0,tagRender:ue?D:void 0,dropdownRender:pe,onDropdownVisibleChange:ke})))},gl=C.forwardRef(uQ),dQ=QC(gl,"dropdownAlign");gl.SECRET_COMBOBOX_MODE_DO_NOT_USE=OB;gl.Option=rk;gl.OptGroup=nk;gl._InternalPanelDoNotUseOrYouWillBeFired=dQ;const fQ=(e,t)=>{typeof(e==null?void 0:e.addEventListener)<"u"?e.addEventListener("change",t):typeof(e==null?void 0:e.addListener)<"u"&&e.addListener(t)},hQ=(e,t)=>{typeof(e==null?void 0:e.removeEventListener)<"u"?e.removeEventListener("change",t):typeof(e==null?void 0:e.removeListener)<"u"&&e.removeListener(t)},rd=["xxl","xl","lg","md","sm","xs"],pQ=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)`}),gQ=e=>{const t=e,n=[].concat(rd).reverse();return n.forEach((r,o)=>{const i=r.toUpperCase(),a=`screen${i}Min`,s=`screen${i}`;if(!(t[a]<=t[s]))throw new Error(`${a}<=${s} fails : !(${t[a]}<=${t[s]})`);if(o<n.length-1){const l=`screen${i}Max`;if(!(t[s]<=t[l]))throw new Error(`${s}<=${l} fails : !(${t[s]}<=${t[l]})`);const c=`screen${n[o+1].toUpperCase()}Min`;if(!(t[l]<=t[c]))throw new Error(`${l}<=${c} fails : !(${t[l]}<=${t[c]})`)}}),e},mQ=()=>{const[,e]=ii(),t=pQ(gQ(e));return we.useMemo(()=>{const n=new Map;let r=-1,o={};return{responsiveMap:t,matchHandlers:{},dispatch(i){return o=i,n.forEach(a=>a(o)),n.size>=1},subscribe(i){return n.size||this.register(),r+=1,n.set(r,i),i(o),r},unsubscribe(i){n.delete(i),n.size||this.unregister()},register(){Object.entries(t).forEach(([i,a])=>{const s=({matches:c})=>{this.dispatch(Object.assign(Object.assign({},o),{[i]:c}))},l=window.matchMedia(a);fQ(l,s),this.matchHandlers[a]={mql:l,listener:s},s(l)})},unregister(){Object.values(t).forEach(i=>{const a=this.matchHandlers[i];hQ(a==null?void 0:a.mql,a==null?void 0:a.listener)}),n.clear()}}},[t])};function vQ(e=!0,t={}){const n=et(t),[,r]=RU(),o=mQ();return mn(()=>{const i=o.subscribe(a=>{n.current=a,e&&r()});return()=>o.unsubscribe(i)},[]),n.current}function MB(e){var t=e.children,n=e.prefixCls,r=e.id,o=e.overlayInnerStyle,i=e.bodyClassName,a=e.className,s=e.style;return C.createElement("div",{className:me("".concat(n,"-content"),a),style:s},C.createElement("div",{className:me("".concat(n,"-inner"),i),id:r,role:"tooltip",style:o},typeof t=="function"?t():t))}var Fl={shiftX:64,adjustY:1},Pl={adjustX:1,shiftY:!0},zo=[0,0],yQ={left:{points:["cr","cl"],overflow:Pl,offset:[-4,0],targetOffset:zo},right:{points:["cl","cr"],overflow:Pl,offset:[4,0],targetOffset:zo},top:{points:["bc","tc"],overflow:Fl,offset:[0,-4],targetOffset:zo},bottom:{points:["tc","bc"],overflow:Fl,offset:[0,4],targetOffset:zo},topLeft:{points:["bl","tl"],overflow:Fl,offset:[0,-4],targetOffset:zo},leftTop:{points:["tr","tl"],overflow:Pl,offset:[-4,0],targetOffset:zo},topRight:{points:["br","tr"],overflow:Fl,offset:[0,-4],targetOffset:zo},rightTop:{points:["tl","tr"],overflow:Pl,offset:[4,0],targetOffset:zo},bottomRight:{points:["tr","br"],overflow:Fl,offset:[0,4],targetOffset:zo},rightBottom:{points:["bl","br"],overflow:Pl,offset:[4,0],targetOffset:zo},bottomLeft:{points:["tl","bl"],overflow:Fl,offset:[0,4],targetOffset:zo},leftBottom:{points:["br","bl"],overflow:Pl,offset:[-4,0],targetOffset:zo}},bQ=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow","classNames","styles"],xQ=function(e,t){var n=e.overlayClassName,r=e.trigger,o=r===void 0?["hover"]:r,i=e.mouseEnterDelay,a=i===void 0?0:i,s=e.mouseLeaveDelay,l=s===void 0?.1:s,c=e.overlayStyle,u=e.prefixCls,d=u===void 0?"rc-tooltip":u,f=e.children,h=e.onVisibleChange,m=e.afterVisibleChange,p=e.transitionName,g=e.animation,v=e.motion,y=e.placement,b=y===void 0?"right":y,w=e.align,x=w===void 0?{}:w,E=e.destroyTooltipOnHide,k=E===void 0?!1:E,S=e.defaultVisible,O=e.getTooltipContainer,A=e.overlayInnerStyle,$=e.overlay,M=e.id,N=e.showArrow,D=N===void 0?!0:N,T=e.classNames,P=e.styles,I=tn(e,bQ),R=qC(M),H=et(null);Oc(t,function(){return H.current});var V=Q({},I);"visible"in e&&(V.popupVisible=e.visible);var L=function(){return C.createElement(MB,{key:"content",prefixCls:d,id:R,bodyClassName:T==null?void 0:T.body,overlayInnerStyle:Q(Q({},A),P==null?void 0:P.body)},$)},j=function(){var _=C.Children.only(f),F=(_==null?void 0:_.props)||{},B=Q(Q({},F),{},{"aria-describedby":$?R:null});return C.cloneElement(f,B)};return C.createElement(ek,Qe({popupClassName:me(n,T==null?void 0:T.root),prefixCls:d,popup:L,action:o,builtinPlacements:yQ,popupPlacement:b,ref:H,popupAlign:x,getPopupContainer:O,onPopupVisibleChange:h,afterPopupVisibleChange:m,popupTransitionName:p,popupAnimation:g,popupMotion:v,defaultPopupVisible:S,autoDestroy:k,mouseLeaveDelay:l,popupStyle:Q(Q({},c),P==null?void 0:P.root),mouseEnterDelay:a,arrow:D},V),j())};const EQ=Oi(xQ);function NB(e){const{sizePopupArrow:t,borderRadiusXS:n,borderRadiusOuter:r}=e,o=t/2,i=0,a=o,s=r*1/Math.sqrt(2),l=o-r*(1-1/Math.sqrt(2)),c=o-n*(1/Math.sqrt(2)),u=r*(Math.sqrt(2)-1)+n*(1/Math.sqrt(2)),d=2*o-c,f=u,h=2*o-s,m=l,p=2*o-i,g=a,v=o*Math.sqrt(2)+r*(Math.sqrt(2)-2),y=r*(Math.sqrt(2)-1),b=`polygon(${y}px 100%, 50% ${y}px, ${2*o-y}px 100%, ${y}px 100%)`,w=`path('M ${i} ${a} A ${r} ${r} 0 0 0 ${s} ${l} L ${c} ${u} A ${n} ${n} 0 0 1 ${d} ${f} L ${h} ${m} A ${r} ${r} 0 0 0 ${p} ${g} Z')`;return{arrowShadowWidth:v,arrowPath:w,arrowPolygon:b}}const DB=(e,t,n)=>{const{sizePopupArrow:r,arrowPolygon:o,arrowPath:i,arrowShadowWidth:a,borderRadiusXS:s,calc:l}=e;return{pointerEvents:"none",width:r,height:r,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:r,height:l(r).div(2).equal(),background:t,clipPath:{_multi_value_:!0,value:[o,i]},content:'""'},"&::after":{content:'""',position:"absolute",width:a,height:a,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${Ce(s)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:n,zIndex:0,background:"transparent"}}},TB=8;function FB(e){const{contentRadius:t,limitVerticalRadius:n}=e,r=t>12?t+2:12;return{arrowOffsetHorizontal:r,arrowOffsetVertical:n?TB:r}}function rf(e,t){return e?t:{}}function wQ(e,t,n){const{componentCls:r,boxShadowPopoverArrow:o,arrowOffsetVertical:i,arrowOffsetHorizontal:a}=e,{arrowDistance:s=0,arrowPlacement:l={left:!0,right:!0,top:!0,bottom:!0}}={};return{[r]:Object.assign(Object.assign(Object.assign(Object.assign({[`${r}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},DB(e,t,o)),{"&:before":{background:t}})]},rf(!!l.top,{[[`&-placement-top > ${r}-arrow`,`&-placement-topLeft > ${r}-arrow`,`&-placement-topRight > ${r}-arrow`].join(",")]:{bottom:s,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},"&-placement-topLeft":{"--arrow-offset-horizontal":a,[`> ${r}-arrow`]:{left:{_skip_check_:!0,value:a}}},"&-placement-topRight":{"--arrow-offset-horizontal":`calc(100% - ${Ce(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:!0,value:a}}}})),rf(!!l.bottom,{[[`&-placement-bottom > ${r}-arrow`,`&-placement-bottomLeft > ${r}-arrow`,`&-placement-bottomRight > ${r}-arrow`].join(",")]:{top:s,transform:"translateY(-100%)"},[`&-placement-bottom > ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},"&-placement-bottomLeft":{"--arrow-offset-horizontal":a,[`> ${r}-arrow`]:{left:{_skip_check_:!0,value:a}}},"&-placement-bottomRight":{"--arrow-offset-horizontal":`calc(100% - ${Ce(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:!0,value:a}}}})),rf(!!l.left,{[[`&-placement-left > ${r}-arrow`,`&-placement-leftTop > ${r}-arrow`,`&-placement-leftBottom > ${r}-arrow`].join(",")]:{right:{_skip_check_:!0,value:s},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${r}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${r}-arrow`]:{top:i},[`&-placement-leftBottom > ${r}-arrow`]:{bottom:i}})),rf(!!l.right,{[[`&-placement-right > ${r}-arrow`,`&-placement-rightTop > ${r}-arrow`,`&-placement-rightBottom > ${r}-arrow`].join(",")]:{left:{_skip_check_:!0,value:s},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${r}-arrow`]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${r}-arrow`]:{top:i},[`&-placement-rightBottom > ${r}-arrow`]:{bottom:i}}))}}function CQ(e,t,n,r){if(r===!1)return{adjustX:!1,adjustY:!1};const o=r&&typeof r=="object"?r:{},i={};switch(e){case"top":case"bottom":i.shiftX=t.arrowOffsetHorizontal*2+n,i.shiftY=!0,i.adjustY=!0;break;case"left":case"right":i.shiftY=t.arrowOffsetVertical*2+n,i.shiftX=!0,i.adjustX=!0;break}const a=Object.assign(Object.assign({},i),o);return a.shiftX||(a.adjustX=!0),a.shiftY||(a.adjustY=!0),a}const U6={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"]}},kQ={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"]}},SQ=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function AQ(e){const{arrowWidth:t,autoAdjustOverflow:n,arrowPointAtCenter:r,offset:o,borderRadius:i}=e,a=t/2,s={},l=FB({contentRadius:i,limitVerticalRadius:!0});return Object.keys(U6).forEach(c=>{const u=r&&kQ[c]||U6[c],d=Object.assign(Object.assign({},u),{offset:[0,0],dynamicInset:!0});switch(s[c]=d,SQ.has(c)&&(d.autoArrow=!1),c){case"top":case"topLeft":case"topRight":d.offset[1]=-a-o;break;case"bottom":case"bottomLeft":case"bottomRight":d.offset[1]=a+o;break;case"left":case"leftTop":case"leftBottom":d.offset[0]=-a-o;break;case"right":case"rightTop":case"rightBottom":d.offset[0]=a+o;break}if(r)switch(c){case"topLeft":case"bottomLeft":d.offset[0]=-l.arrowOffsetHorizontal-a;break;case"topRight":case"bottomRight":d.offset[0]=l.arrowOffsetHorizontal+a;break;case"leftTop":case"rightTop":d.offset[1]=-l.arrowOffsetHorizontal*2+a;break;case"leftBottom":case"rightBottom":d.offset[1]=l.arrowOffsetHorizontal*2-a;break}d.overflow=CQ(c,l,t,n),d.htmlRegion="visibleFirst"}),s}const $Q=e=>{const{calc:t,componentCls:n,tooltipMaxWidth:r,tooltipColor:o,tooltipBg:i,tooltipBorderRadius:a,zIndexPopup:s,controlHeight:l,boxShadowSecondary:c,paddingSM:u,paddingXS:d,arrowOffsetHorizontal:f,sizePopupArrow:h}=e,m=t(a).add(h).add(f).equal(),p=t(a).mul(2).add(h).equal();return[{[n]:Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{position:"absolute",zIndex:s,display:"block",width:"max-content",maxWidth:r,visibility:"visible","--valid-offset-x":"var(--arrow-offset-horizontal, var(--arrow-x))",transformOrigin:["var(--valid-offset-x, 50%)","var(--arrow-y, 50%)"].join(" "),"&-hidden":{display:"none"},"--antd-arrow-background-color":i,[`${n}-inner`]:{minWidth:p,minHeight:l,padding:`${Ce(e.calc(u).div(2).equal())} ${Ce(d)}`,color:`var(--ant-tooltip-color, ${o})`,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:i,borderRadius:a,boxShadow:c,boxSizing:"border-box"},[["&-placement-topLeft","&-placement-topRight","&-placement-bottomLeft","&-placement-bottomRight"].join(",")]:{minWidth:m},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${n}-inner`]:{borderRadius:e.min(a,TB)}},[`${n}-content`]:{position:"relative"}}),yp(e,(g,{darkColor:v})=>({[`&${n}-${g}`]:{[`${n}-inner`]:{backgroundColor:v},[`${n}-arrow`]:{"--antd-arrow-background-color":v}}}))),{"&-rtl":{direction:"rtl"}})},wQ(e,"var(--antd-arrow-background-color)"),{[`${n}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},OQ=e=>Object.assign(Object.assign({zIndexPopup:e.zIndexPopupBase+70},FB({contentRadius:e.borderRadius,limitVerticalRadius:!0})),NB(Mn(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)}))),PB=(e,t=!0)=>Pr("Tooltip",n=>{const{borderRadius:r,colorTextLightSolid:o,colorBgSpotlight:i}=n,a=Mn(n,{tooltipMaxWidth:250,tooltipColor:o,tooltipBorderRadius:r,tooltipBg:i});return[$Q(a),uY(n,"zoom-big-fast")]},OQ,{resetStyle:!1,injectStyle:t})(e),MQ=Js.map(e=>`${e}-inverse`),NQ=["success","processing","error","default","warning"];function Tp(e,t=!0){return t?[].concat(ze(MQ),ze(Js)).includes(e):Js.includes(e)}function DQ(e){return NQ.includes(e)}function IB(e,t){const n=Tp(t),r=me({[`${e}-${t}`]:t&&n}),o={},i={},a=dY(t).toRgb(),s=(.299*a.r+.587*a.g+.114*a.b)/255<.5?"#FFF":"#000";return t&&!n&&(o.background=t,o["--ant-tooltip-color"]=s,i["--antd-arrow-background-color"]=t),{className:r,overlayStyle:o,arrowStyle:i}}const TQ=e=>{const{prefixCls:t,className:n,placement:r="top",title:o,color:i,overlayInnerStyle:a}=e,{getPrefixCls:s}=C.useContext(pn),l=s("tooltip",t),[c,u,d]=PB(l),f=IB(l,i),h=f.arrowStyle,m=Object.assign(Object.assign({},a),f.overlayStyle),p=me(u,d,l,`${l}-pure`,`${l}-placement-${r}`,n,f.className);return c(C.createElement("div",{className:p,style:h},C.createElement("div",{className:`${l}-arrow`}),C.createElement(MB,Object.assign({},e,{className:u,prefixCls:l,overlayInnerStyle:m}),o)))};var FQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const PQ=C.forwardRef((e,t)=>{var n,r;const{prefixCls:o,openClassName:i,getTooltipContainer:a,color:s,overlayInnerStyle:l,children:c,afterOpenChange:u,afterVisibleChange:d,destroyTooltipOnHide:f,destroyOnHidden:h,arrow:m=!0,title:p,overlay:g,builtinPlacements:v,arrowPointAtCenter:y=!1,autoAdjustOverflow:b=!0,getPopupContainer:w,placement:x="top",mouseEnterDelay:E=.1,mouseLeaveDelay:k=.1,overlayStyle:S,rootClassName:O,overlayClassName:A,styles:$,classNames:M}=e,N=FQ(e,["prefixCls","openClassName","getTooltipContainer","color","overlayInnerStyle","children","afterOpenChange","afterVisibleChange","destroyTooltipOnHide","destroyOnHidden","arrow","title","overlay","builtinPlacements","arrowPointAtCenter","autoAdjustOverflow","motion","getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName","overlayClassName","styles","classNames"]),D=!!m,[,T]=ii(),{getPopupContainer:P,getPrefixCls:I,direction:R,className:H,style:V,classNames:L,styles:j}=xa("tooltip"),_=gp(),F=C.useRef(null),B=()=>{var ue;(ue=F.current)===null||ue===void 0||ue.forceAlign()};C.useImperativeHandle(t,()=>{var ue,ve;return{forceAlign:B,forcePopupAlign:()=>{_.deprecated(!1,"forcePopupAlign","forceAlign"),B()},nativeElement:(ue=F.current)===null||ue===void 0?void 0:ue.nativeElement,popupElement:(ve=F.current)===null||ve===void 0?void 0:ve.popupElement}});const[z,G]=yr(!1,{value:(n=e.open)!==null&&n!==void 0?n:e.visible,defaultValue:(r=e.defaultOpen)!==null&&r!==void 0?r:e.defaultVisible}),W=!p&&!g&&p!==0,q=ue=>{var ve,xe;G(W?!1:ue),W||((ve=e.onOpenChange)===null||ve===void 0||ve.call(e,ue),(xe=e.onVisibleChange)===null||xe===void 0||xe.call(e,ue))},U=C.useMemo(()=>{var ue,ve;let xe=y;return typeof m=="object"&&(xe=(ve=(ue=m.pointAtCenter)!==null&&ue!==void 0?ue:m.arrowPointAtCenter)!==null&&ve!==void 0?ve:y),v||AQ({arrowPointAtCenter:xe,autoAdjustOverflow:b,arrowWidth:D?T.sizePopupArrow:0,borderRadius:T.borderRadius,offset:T.marginXXS})},[y,m,v,T]),Y=C.useMemo(()=>p===0?p:g||p||"",[g,p]),ie=C.createElement(ts,{space:!0},typeof Y=="function"?Y():Y),K=I("tooltip",o),re=I(),oe=e["data-popover-inject"];let ne=z;!("open"in e)&&!("visible"in e)&&W&&(ne=!1);const ae=C.isValidElement(c)&&!$I(c)?c:C.createElement("span",null,c),de=ae.props,ge=!de.className||typeof de.className=="string"?me(de.className,i||`${K}-open`):de.className,[Se,ye,be]=PB(K,!oe),ce=IB(K,s),he=ce.arrowStyle,Te=me(A,{[`${K}-rtl`]:R==="rtl"},ce.className,O,ye,be,H,L.root,M==null?void 0:M.root),se=me(L.body,M==null?void 0:M.body),[Pe,De]=xp("Tooltip",N.zIndex),He=C.createElement(EQ,Object.assign({},N,{zIndex:Pe,showArrow:D,placement:x,mouseEnterDelay:E,mouseLeaveDelay:k,prefixCls:K,classNames:{root:Te,body:se},styles:{root:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},he),j.root),V),S),$==null?void 0:$.root),body:Object.assign(Object.assign(Object.assign(Object.assign({},j.body),l),$==null?void 0:$.body),ce.overlayStyle)},getTooltipContainer:w||a||P,ref:F,builtinPlacements:U,overlay:ie,visible:ne,onVisibleChange:q,afterVisibleChange:u??d,arrowContent:C.createElement("span",{className:`${K}-arrow-content`}),motion:{motionName:LI(re,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:h??!!f}),ne?es(ae,{className:ge}):ae);return Se(C.createElement(TI.Provider,{value:De},He))}),Nd=PQ;Nd._InternalPanelDoNotUseOrYouWillBeFired=TQ;const IQ=new xn("antStatusProcessing",{"0%":{transform:"scale(0.8)",opacity:.5},"100%":{transform:"scale(2.4)",opacity:0}}),BQ=new xn("antZoomBadgeIn",{"0%":{transform:"scale(0) translate(50%, -50%)",opacity:0},"100%":{transform:"scale(1) translate(50%, -50%)"}}),RQ=new xn("antZoomBadgeOut",{"0%":{transform:"scale(1) translate(50%, -50%)"},"100%":{transform:"scale(0) translate(50%, -50%)",opacity:0}}),_Q=new xn("antNoWrapperZoomBadgeIn",{"0%":{transform:"scale(0)",opacity:0},"100%":{transform:"scale(1)"}}),jQ=new xn("antNoWrapperZoomBadgeOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0)",opacity:0}}),LQ=new xn("antBadgeLoadingCircle",{"0%":{transformOrigin:"50%"},"100%":{transform:"translate(50%, -50%) rotate(360deg)",transformOrigin:"50%"}}),zQ=e=>{const{componentCls:t,iconCls:n,antCls:r,badgeShadowSize:o,textFontSize:i,textFontSizeSM:a,statusSize:s,dotSize:l,textFontWeight:c,indicatorHeight:u,indicatorHeightSM:d,marginXS:f,calc:h}=e,m=`${r}-scroll-number`,p=yp(e,(g,{darkColor:v})=>({[`&${t} ${t}-color-${g}`]:{background:v,[`&:not(${t}-count)`]:{color:v},"a:hover &":{background:v}}}));return{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},br(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:i,lineHeight:Ce(u),whiteSpace:"nowrap",textAlign:"center",background:e.badgeColor,borderRadius:h(u).div(2).equal(),boxShadow:`0 0 0 ${Ce(o)} ${e.badgeShadowColor}`,transition:`background ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:d,height:d,fontSize:a,lineHeight:Ce(d),borderRadius:h(d).div(2).equal()},[`${t}-multiple-words`]:{padding:`0 ${Ce(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 ${Ce(o)} ${e.badgeShadowColor}`},[`${t}-count, ${t}-dot, ${m}-custom-component`]:{position:"absolute",top:0,insetInlineEnd:0,transform:"translate(50%, -50%)",transformOrigin:"100% 0%",[`&${n}-spin`]:{animationName:LQ,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear"}},[`&${t}-status`]:{lineHeight:"inherit",verticalAlign:"baseline",[`${t}-status-dot`]:{position:"relative",top:-1,display:"inline-block",width:s,height:s,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:o,borderStyle:"solid",borderColor:"inherit",borderRadius:"50%",animationName:IQ,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:f,color:e.colorText,fontSize:e.fontSize}}}),p),{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:BQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`${t}-zoom-leave`]:{animationName:RQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:_Q,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:jQ,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:"middle"},[`${m}-custom-component, ${t}-count`]:{transform:"none"},[`${m}-custom-component, ${m}`]:{position:"relative",top:"auto",display:"block",transformOrigin:"50% 50%"}},[m]:{overflow:"hidden",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack}`,[`${m}-only`]:{position:"relative",display:"inline-block",height:u,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden",[`> p${m}-only-unit`]:{height:u,margin:0,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden"}},[`${m}-symbol`]:{verticalAlign:"top"}},"&-rtl":{direction:"rtl",[`${t}-count, ${t}-dot, ${m}-custom-component`]:{transform:"translate(-50%, -50%)"}}})}},BB=e=>{const{fontHeight:t,lineWidth:n,marginXS:r,colorBorderBg:o}=e,i=t,a=n,s=e.colorTextLightSolid,l=e.colorError,c=e.colorErrorHover;return Mn(e,{badgeFontHeight:i,badgeShadowSize:a,badgeTextColor:s,badgeColor:l,badgeColorHover:c,badgeShadowColor:o,badgeProcessingDuration:"1.2s",badgeRibbonOffset:r,badgeRibbonCornerTransform:"scaleY(0.75)",badgeRibbonCornerFilter:"brightness(75%)"})},RB=e=>{const{fontSize:t,lineHeight:n,fontSizeSM:r,lineWidth:o}=e;return{indicatorZIndex:"auto",indicatorHeight:Math.round(t*n)-2*o,indicatorHeightSM:t,dotSize:r/2,textFontSize:r,textFontSizeSM:r,textFontWeight:"normal",statusSize:r/2}},HQ=Pr("Badge",e=>{const t=BB(e);return zQ(t)},RB),WQ=e=>{const{antCls:t,badgeFontHeight:n,marginXS:r,badgeRibbonOffset:o,calc:i}=e,a=`${t}-ribbon`,s=`${t}-ribbon-wrapper`,l=yp(e,(c,{darkColor:u})=>({[`&${a}-color-${c}`]:{background:u,color:u}}));return{[s]:{position:"relative"},[a]:Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{position:"absolute",top:r,padding:`0 ${Ce(e.paddingXS)}`,color:e.colorPrimary,lineHeight:Ce(n),whiteSpace:"nowrap",backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${a}-text`]:{color:e.badgeTextColor},[`${a}-corner`]:{position:"absolute",top:"100%",width:o,height:o,color:"currentcolor",border:`${Ce(i(o).div(2).equal())} solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:"top",filter:e.badgeRibbonCornerFilter}}),l),{[`&${a}-placement-end`]:{insetInlineEnd:i(o).mul(-1).equal(),borderEndEndRadius:0,[`${a}-corner`]:{insetInlineEnd:0,borderInlineEndColor:"transparent",borderBlockEndColor:"transparent"}},[`&${a}-placement-start`]:{insetInlineStart:i(o).mul(-1).equal(),borderEndStartRadius:0,[`${a}-corner`]:{insetInlineStart:0,borderBlockEndColor:"transparent",borderInlineStartColor:"transparent"}},"&-rtl":{direction:"rtl"}})}},VQ=Pr(["Badge","Ribbon"],e=>{const t=BB(e);return WQ(t)},RB),GQ=e=>{const{className:t,prefixCls:n,style:r,color:o,children:i,text:a,placement:s="end",rootClassName:l}=e,{getPrefixCls:c,direction:u}=C.useContext(pn),d=c("ribbon",n),f=`${d}-wrapper`,[h,m,p]=VQ(d,f),g=Tp(o,!1),v=me(d,`${d}-placement-${s}`,{[`${d}-rtl`]:u==="rtl",[`${d}-color-${o}`]:g},t),y={},b={};return o&&!g&&(y.background=o,b.color=o),h(C.createElement("div",{className:me(f,l,m,p)},i,C.createElement("div",{className:me(v,m),style:Object.assign(Object.assign({},y),r)},C.createElement("span",{className:`${d}-text`},a),C.createElement("div",{className:`${d}-corner`,style:b}))))},q6=e=>{const{prefixCls:t,value:n,current:r,offset:o=0}=e;let i;return o&&(i={position:"absolute",top:`${o}00%`,left:0}),C.createElement("span",{style:i,className:me(`${t}-only-unit`,{current:r})},n)};function UQ(e,t,n){let r=e,o=0;for(;(r+10)%10!==t;)r+=n,o+=n;return o}const qQ=e=>{const{prefixCls:t,count:n,value:r}=e,o=Number(r),i=Math.abs(n),[a,s]=C.useState(o),[l,c]=C.useState(i),u=()=>{s(o),c(i)};C.useEffect(()=>{const h=setTimeout(u,1e3);return()=>clearTimeout(h)},[o]);let d,f;if(a===o||Number.isNaN(o)||Number.isNaN(a))d=[C.createElement(q6,Object.assign({},e,{key:o,current:!0}))],f={transition:"none"};else{d=[];const h=o+10,m=[];for(let v=o;v<=h;v+=1)m.push(v);const p=l<i?1:-1,g=m.findIndex(v=>v%10===a);d=(p<0?m.slice(0,g+1):m.slice(g)).map((v,y)=>{const b=v%10;return C.createElement(q6,Object.assign({},e,{key:v,value:b,offset:p<0?y-g:y,current:y===g}))}),f={transform:`translateY(${-UQ(a,o,p)}00%)`}}return C.createElement("span",{className:`${t}-only`,style:f,onTransitionEnd:u},d)};var YQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const XQ=C.forwardRef((e,t)=>{const{prefixCls:n,count:r,className:o,motionClassName:i,style:a,title:s,show:l,component:c="sup",children:u}=e,d=YQ(e,["prefixCls","count","className","motionClassName","style","title","show","component","children"]),{getPrefixCls:f}=C.useContext(pn),h=f("scroll-number",n),m=Object.assign(Object.assign({},d),{"data-show":l,style:a,className:me(h,o,i),title:s});let p=r;if(r&&Number(r)%1===0){const g=String(r).split("");p=C.createElement("bdi",null,g.map((v,y)=>C.createElement(qQ,{prefixCls:h,count:Number(r),value:v,key:g.length-y})))}return a!=null&&a.borderColor&&(m.style=Object.assign(Object.assign({},a),{boxShadow:`0 0 0 1px ${a.borderColor} inset`})),u?es(u,g=>({className:me(`${h}-custom-component`,g==null?void 0:g.className,i)})):C.createElement(c,Object.assign({},m,{ref:t}),p)});var KQ=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const ZQ=C.forwardRef((e,t)=>{var n,r,o,i,a;const{prefixCls:s,scrollNumberPrefixCls:l,children:c,status:u,text:d,color:f,count:h=null,overflowCount:m=99,dot:p=!1,size:g="default",title:v,offset:y,style:b,className:w,rootClassName:x,classNames:E,styles:k,showZero:S=!1}=e,O=KQ(e,["prefixCls","scrollNumberPrefixCls","children","status","text","color","count","overflowCount","dot","size","title","offset","style","className","rootClassName","classNames","styles","showZero"]),{getPrefixCls:A,direction:$,badge:M}=C.useContext(pn),N=A("badge",s),[D,T,P]=HQ(N),I=h>m?`${m}+`:h,R=I==="0"||I===0||d==="0"||d===0,H=h===null||R&&!S,V=(u!=null||f!=null)&&H,L=u!=null||!R,j=p&&!R,_=j?"":I,F=Gt(()=>((_==null||_==="")&&(d==null||d==="")||R&&!S)&&!j,[_,R,S,j,d]),B=et(h);F||(B.current=h);const z=B.current,G=et(_);F||(G.current=_);const W=G.current,q=et(j);F||(q.current=j);const U=Gt(()=>{if(!y)return Object.assign(Object.assign({},M==null?void 0:M.style),b);const ge={marginTop:y[1]};return $==="rtl"?ge.left=Number.parseInt(y[0],10):ge.right=-Number.parseInt(y[0],10),Object.assign(Object.assign(Object.assign({},ge),M==null?void 0:M.style),b)},[$,y,b,M==null?void 0:M.style]),Y=v??(typeof z=="string"||typeof z=="number"?z:void 0),ie=!F&&(d===0?S:!!d&&d!==!0),K=ie?C.createElement("span",{className:`${N}-status-text`},d):null,re=!z||typeof z!="object"?void 0:es(z,ge=>({style:Object.assign(Object.assign({},U),ge.style)})),oe=Tp(f,!1),ne=me(E==null?void 0:E.indicator,(n=M==null?void 0:M.classNames)===null||n===void 0?void 0:n.indicator,{[`${N}-status-dot`]:V,[`${N}-status-${u}`]:!!u,[`${N}-color-${f}`]:oe}),ae={};f&&!oe&&(ae.color=f,ae.background=f);const de=me(N,{[`${N}-status`]:V,[`${N}-not-a-wrapper`]:!c,[`${N}-rtl`]:$==="rtl"},w,x,M==null?void 0:M.className,(r=M==null?void 0:M.classNames)===null||r===void 0?void 0:r.root,E==null?void 0:E.root,T,P);if(!c&&V&&(d||L||!H)){const ge=U.color;return D(C.createElement("span",Object.assign({},O,{className:de,style:Object.assign(Object.assign(Object.assign({},k==null?void 0:k.root),(o=M==null?void 0:M.styles)===null||o===void 0?void 0:o.root),U)}),C.createElement("span",{className:ne,style:Object.assign(Object.assign(Object.assign({},k==null?void 0:k.indicator),(i=M==null?void 0:M.styles)===null||i===void 0?void 0:i.indicator),ae)}),ie&&C.createElement("span",{style:{color:ge},className:`${N}-status-text`},d)))}return D(C.createElement("span",Object.assign({ref:t},O,{className:de,style:Object.assign(Object.assign({},(a=M==null?void 0:M.styles)===null||a===void 0?void 0:a.root),k==null?void 0:k.root)}),c,C.createElement(fl,{visible:!F,motionName:`${N}-zoom`,motionAppear:!1,motionDeadline:1e3},({className:ge})=>{var Se,ye;const be=A("scroll-number",l),ce=q.current,he=me(E==null?void 0:E.indicator,(Se=M==null?void 0:M.classNames)===null||Se===void 0?void 0:Se.indicator,{[`${N}-dot`]:ce,[`${N}-count`]:!ce,[`${N}-count-sm`]:g==="small",[`${N}-multiple-words`]:!ce&&W&&W.toString().length>1,[`${N}-status-${u}`]:!!u,[`${N}-color-${f}`]:oe});let Te=Object.assign(Object.assign(Object.assign({},k==null?void 0:k.indicator),(ye=M==null?void 0:M.styles)===null||ye===void 0?void 0:ye.indicator),U);return f&&!oe&&(Te=Te||{},Te.background=f),C.createElement(XQ,{prefixCls:be,show:!F,motionClassName:ge,className:he,count:W,title:Y,style:Te,key:"scrollNumber"},re)}),K))}),_B=ZQ;_B.Ribbon=GQ;var V2={exports:{}},QQ=V2.exports,Y6;function JQ(){return Y6||(Y6=1,(function(e,t){(function(n,r){e.exports=r()})(QQ,(function(){var n=1e3,r=6e4,o=36e5,i="millisecond",a="second",s="minute",l="hour",c="day",u="week",d="month",f="quarter",h="year",m="date",p="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,v=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(D){var T=["th","st","nd","rd"],P=D%100;return"["+D+(T[(P-20)%10]||T[P]||T[0])+"]"}},b=function(D,T,P){var I=String(D);return!I||I.length>=T?D:""+Array(T+1-I.length).join(P)+D},w={s:b,z:function(D){var T=-D.utcOffset(),P=Math.abs(T),I=Math.floor(P/60),R=P%60;return(T<=0?"+":"-")+b(I,2,"0")+":"+b(R,2,"0")},m:function D(T,P){if(T.date()<P.date())return-D(P,T);var I=12*(P.year()-T.year())+(P.month()-T.month()),R=T.clone().add(I,d),H=P-R<0,V=T.clone().add(I+(H?-1:1),d);return+(-(I+(P-R)/(H?R-V:V-R))||0)},a:function(D){return D<0?Math.ceil(D)||0:Math.floor(D)},p:function(D){return{M:d,y:h,w:u,d:c,D:m,h:l,m:s,s:a,ms:i,Q:f}[D]||String(D||"").toLowerCase().replace(/s$/,"")},u:function(D){return D===void 0}},x="en",E={};E[x]=y;var k="$isDayjsObject",S=function(D){return D instanceof M||!(!D||!D[k])},O=function D(T,P,I){var R;if(!T)return x;if(typeof T=="string"){var H=T.toLowerCase();E[H]&&(R=H),P&&(E[H]=P,R=H);var V=T.split("-");if(!R&&V.length>1)return D(V[0])}else{var L=T.name;E[L]=T,R=L}return!I&&R&&(x=R),R||!I&&x},A=function(D,T){if(S(D))return D.clone();var P=typeof T=="object"?T:{};return P.date=D,P.args=arguments,new M(P)},$=w;$.l=O,$.i=S,$.w=function(D,T){return A(D,{locale:T.$L,utc:T.$u,x:T.$x,$offset:T.$offset})};var M=(function(){function D(P){this.$L=O(P.locale,null,!0),this.parse(P),this.$x=this.$x||P.x||{},this[k]=!0}var T=D.prototype;return T.parse=function(P){this.$d=(function(I){var R=I.date,H=I.utc;if(R===null)return new Date(NaN);if($.u(R))return new Date;if(R instanceof Date)return new Date(R);if(typeof R=="string"&&!/Z$/i.test(R)){var V=R.match(g);if(V){var L=V[2]-1||0,j=(V[7]||"0").substring(0,3);return H?new Date(Date.UTC(V[1],L,V[3]||1,V[4]||0,V[5]||0,V[6]||0,j)):new Date(V[1],L,V[3]||1,V[4]||0,V[5]||0,V[6]||0,j)}}return new Date(R)})(P),this.init()},T.init=function(){var P=this.$d;this.$y=P.getFullYear(),this.$M=P.getMonth(),this.$D=P.getDate(),this.$W=P.getDay(),this.$H=P.getHours(),this.$m=P.getMinutes(),this.$s=P.getSeconds(),this.$ms=P.getMilliseconds()},T.$utils=function(){return $},T.isValid=function(){return this.$d.toString()!==p},T.isSame=function(P,I){var R=A(P);return this.startOf(I)<=R&&R<=this.endOf(I)},T.isAfter=function(P,I){return A(P)<this.startOf(I)},T.isBefore=function(P,I){return this.endOf(I)<A(P)},T.$g=function(P,I,R){return $.u(P)?this[I]:this.set(R,P)},T.unix=function(){return Math.floor(this.valueOf()/1e3)},T.valueOf=function(){return this.$d.getTime()},T.startOf=function(P,I){var R=this,H=!!$.u(I)||I,V=$.p(P),L=function(q,U){var Y=$.w(R.$u?Date.UTC(R.$y,U,q):new Date(R.$y,U,q),R);return H?Y:Y.endOf(c)},j=function(q,U){return $.w(R.toDate()[q].apply(R.toDate("s"),(H?[0,0,0,0]:[23,59,59,999]).slice(U)),R)},_=this.$W,F=this.$M,B=this.$D,z="set"+(this.$u?"UTC":"");switch(V){case h:return H?L(1,0):L(31,11);case d:return H?L(1,F):L(0,F+1);case u:var G=this.$locale().weekStart||0,W=(_<G?_+7:_)-G;return L(H?B-W:B+(6-W),F);case c:case m:return j(z+"Hours",0);case l:return j(z+"Minutes",1);case s:return j(z+"Seconds",2);case a:return j(z+"Milliseconds",3);default:return this.clone()}},T.endOf=function(P){return this.startOf(P,!1)},T.$set=function(P,I){var R,H=$.p(P),V="set"+(this.$u?"UTC":""),L=(R={},R[c]=V+"Date",R[m]=V+"Date",R[d]=V+"Month",R[h]=V+"FullYear",R[l]=V+"Hours",R[s]=V+"Minutes",R[a]=V+"Seconds",R[i]=V+"Milliseconds",R)[H],j=H===c?this.$D+(I-this.$W):I;if(H===d||H===h){var _=this.clone().set(m,1);_.$d[L](j),_.init(),this.$d=_.set(m,Math.min(this.$D,_.daysInMonth())).$d}else L&&this.$d[L](j);return this.init(),this},T.set=function(P,I){return this.clone().$set(P,I)},T.get=function(P){return this[$.p(P)]()},T.add=function(P,I){var R,H=this;P=Number(P);var V=$.p(I),L=function(F){var B=A(H);return $.w(B.date(B.date()+Math.round(F*P)),H)};if(V===d)return this.set(d,this.$M+P);if(V===h)return this.set(h,this.$y+P);if(V===c)return L(1);if(V===u)return L(7);var j=(R={},R[s]=r,R[l]=o,R[a]=n,R)[V]||1,_=this.$d.getTime()+P*j;return $.w(_,this)},T.subtract=function(P,I){return this.add(-1*P,I)},T.format=function(P){var I=this,R=this.$locale();if(!this.isValid())return R.invalidDate||p;var H=P||"YYYY-MM-DDTHH:mm:ssZ",V=$.z(this),L=this.$H,j=this.$m,_=this.$M,F=R.weekdays,B=R.months,z=R.meridiem,G=function(U,Y,ie,K){return U&&(U[Y]||U(I,H))||ie[Y].slice(0,K)},W=function(U){return $.s(L%12||12,U,"0")},q=z||function(U,Y,ie){var K=U<12?"AM":"PM";return ie?K.toLowerCase():K};return H.replace(v,(function(U,Y){return Y||(function(ie){switch(ie){case"YY":return String(I.$y).slice(-2);case"YYYY":return $.s(I.$y,4,"0");case"M":return _+1;case"MM":return $.s(_+1,2,"0");case"MMM":return G(R.monthsShort,_,B,3);case"MMMM":return G(B,_);case"D":return I.$D;case"DD":return $.s(I.$D,2,"0");case"d":return String(I.$W);case"dd":return G(R.weekdaysMin,I.$W,F,2);case"ddd":return G(R.weekdaysShort,I.$W,F,3);case"dddd":return F[I.$W];case"H":return String(L);case"HH":return $.s(L,2,"0");case"h":return W(1);case"hh":return W(2);case"a":return q(L,j,!0);case"A":return q(L,j,!1);case"m":return String(j);case"mm":return $.s(j,2,"0");case"s":return String(I.$s);case"ss":return $.s(I.$s,2,"0");case"SSS":return $.s(I.$ms,3,"0");case"Z":return V}return null})(U)||V.replace(":","")}))},T.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},T.diff=function(P,I,R){var H,V=this,L=$.p(I),j=A(P),_=(j.utcOffset()-this.utcOffset())*r,F=this-j,B=function(){return $.m(V,j)};switch(L){case h:H=B()/12;break;case d:H=B();break;case f:H=B()/3;break;case u:H=(F-_)/6048e5;break;case c:H=(F-_)/864e5;break;case l:H=F/o;break;case s:H=F/r;break;case a:H=F/n;break;default:H=F}return R?H:$.a(H)},T.daysInMonth=function(){return this.endOf(d).$D},T.$locale=function(){return E[this.$L]},T.locale=function(P,I){if(!P)return this.$L;var R=this.clone(),H=O(P,I,!0);return H&&(R.$L=H),R},T.clone=function(){return $.w(this.$d,this)},T.toDate=function(){return new Date(this.valueOf())},T.toJSON=function(){return this.isValid()?this.toISOString():null},T.toISOString=function(){return this.$d.toISOString()},T.toString=function(){return this.$d.toUTCString()},D})(),N=M.prototype;return A.prototype=N,[["$ms",i],["$s",a],["$m",s],["$H",l],["$W",c],["$M",d],["$y",h],["$D",m]].forEach((function(D){N[D[1]]=function(T){return this.$g(T,D[0],D[1])}})),A.extend=function(D,T){return D.$i||(D(T,M,A),D.$i=!0),A},A.locale=O,A.isDayjs=S,A.unix=function(D){return A(1e3*D)},A.en=E[x],A.Ls=E,A.p={},A}))})(V2)),V2.exports}var eJ=JQ();const oo=ba(eJ);var G2={exports:{}},tJ=G2.exports,X6;function nJ(){return X6||(X6=1,(function(e,t){(function(n,r){e.exports=r()})(tJ,(function(){return function(n,r){r.prototype.weekday=function(o){var i=this.$locale().weekStart||0,a=this.$W,s=(a<i?a+7:a)-i;return this.$utils().u(o)?s:this.subtract(s,"day").add(o,"day")}}}))})(G2)),G2.exports}var rJ=nJ();const oJ=ba(rJ);var U2={exports:{}},iJ=U2.exports,K6;function aJ(){return K6||(K6=1,(function(e,t){(function(n,r){e.exports=r()})(iJ,(function(){return function(n,r,o){var i=r.prototype,a=function(d){return d&&(d.indexOf?d:d.s)},s=function(d,f,h,m,p){var g=d.name?d:d.$locale(),v=a(g[f]),y=a(g[h]),b=v||y.map((function(x){return x.slice(0,m)}));if(!p)return b;var w=g.weekStart;return b.map((function(x,E){return b[(E+(w||0))%7]}))},l=function(){return o.Ls[o.locale()]},c=function(d,f){return d.formats[f]||(function(h){return h.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(m,p,g){return p||g.slice(1)}))})(d.formats[f.toUpperCase()])},u=function(){var d=this;return{months:function(f){return f?f.format("MMMM"):s(d,"months")},monthsShort:function(f){return f?f.format("MMM"):s(d,"monthsShort","months",3)},firstDayOfWeek:function(){return d.$locale().weekStart||0},weekdays:function(f){return f?f.format("dddd"):s(d,"weekdays")},weekdaysMin:function(f){return f?f.format("dd"):s(d,"weekdaysMin","weekdays",2)},weekdaysShort:function(f){return f?f.format("ddd"):s(d,"weekdaysShort","weekdays",3)},longDateFormat:function(f){return c(d.$locale(),f)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};i.localeData=function(){return u.bind(this)()},o.localeData=function(){var d=l();return{firstDayOfWeek:function(){return d.weekStart||0},weekdays:function(){return o.weekdays()},weekdaysShort:function(){return o.weekdaysShort()},weekdaysMin:function(){return o.weekdaysMin()},months:function(){return o.months()},monthsShort:function(){return o.monthsShort()},longDateFormat:function(f){return c(d,f)},meridiem:d.meridiem,ordinal:d.ordinal}},o.months=function(){return s(l(),"months")},o.monthsShort=function(){return s(l(),"monthsShort","months",3)},o.weekdays=function(d){return s(l(),"weekdays",null,null,d)},o.weekdaysShort=function(d){return s(l(),"weekdaysShort","weekdays",3,d)},o.weekdaysMin=function(d){return s(l(),"weekdaysMin","weekdays",2,d)}}}))})(U2)),U2.exports}var sJ=aJ();const lJ=ba(sJ);var q2={exports:{}},cJ=q2.exports,Z6;function uJ(){return Z6||(Z6=1,(function(e,t){(function(n,r){e.exports=r()})(cJ,(function(){var n="week",r="year";return function(o,i,a){var s=i.prototype;s.week=function(l){if(l===void 0&&(l=null),l!==null)return this.add(7*(l-this.week()),"day");var c=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var u=a(this).startOf(r).add(1,r).date(c),d=a(this).endOf(n);if(u.isBefore(d))return 1}var f=a(this).startOf(r).date(c).startOf(n).subtract(1,"millisecond"),h=this.diff(f,n,!0);return h<0?a(this).startOf("week").week():Math.ceil(h)},s.weeks=function(l){return l===void 0&&(l=null),this.week(l)}}}))})(q2)),q2.exports}var dJ=uJ();const fJ=ba(dJ);var Y2={exports:{}},hJ=Y2.exports,Q6;function pJ(){return Q6||(Q6=1,(function(e,t){(function(n,r){e.exports=r()})(hJ,(function(){return function(n,r){r.prototype.weekYear=function(){var o=this.month(),i=this.week(),a=this.year();return i===1&&o===11?a+1:o===0&&i>=52?a-1:a}}}))})(Y2)),Y2.exports}var gJ=pJ();const mJ=ba(gJ);var X2={exports:{}},vJ=X2.exports,J6;function yJ(){return J6||(J6=1,(function(e,t){(function(n,r){e.exports=r()})(vJ,(function(){return function(n,r){var o=r.prototype,i=o.format;o.format=function(a){var s=this,l=this.$locale();if(!this.isValid())return i.bind(this)(a);var c=this.$utils(),u=(a||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(d){switch(d){case"Q":return Math.ceil((s.$M+1)/3);case"Do":return l.ordinal(s.$D);case"gggg":return s.weekYear();case"GGGG":return s.isoWeekYear();case"wo":return l.ordinal(s.week(),"W");case"w":case"ww":return c.s(s.week(),d==="w"?1:2,"0");case"W":case"WW":return c.s(s.isoWeek(),d==="W"?1:2,"0");case"k":case"kk":return c.s(String(s.$H===0?24:s.$H),d==="k"?1:2,"0");case"X":return Math.floor(s.$d.getTime()/1e3);case"x":return s.$d.getTime();case"z":return"["+s.offsetName()+"]";case"zzz":return"["+s.offsetName("long")+"]";default:return d}}));return i.bind(this)(u)}}}))})(X2)),X2.exports}var bJ=yJ();const xJ=ba(bJ);var K2={exports:{}},EJ=K2.exports,eA;function wJ(){return eA||(eA=1,(function(e,t){(function(n,r){e.exports=r()})(EJ,(function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,o=/\d/,i=/\d\d/,a=/\d\d?/,s=/\d*[^-_:/,()\s\d]+/,l={},c=function(g){return(g=+g)+(g>68?1900:2e3)},u=function(g){return function(v){this[g]=+v}},d=[/[+-]\d\d:?(\d\d)?|Z/,function(g){(this.zone||(this.zone={})).offset=(function(v){if(!v||v==="Z")return 0;var y=v.match(/([+-]|\d\d)/g),b=60*y[1]+(+y[2]||0);return b===0?0:y[0]==="+"?-b:b})(g)}],f=function(g){var v=l[g];return v&&(v.indexOf?v:v.s.concat(v.f))},h=function(g,v){var y,b=l.meridiem;if(b){for(var w=1;w<=24;w+=1)if(g.indexOf(b(w,0,v))>-1){y=w>12;break}}else y=g===(v?"pm":"PM");return y},m={A:[s,function(g){this.afternoon=h(g,!1)}],a:[s,function(g){this.afternoon=h(g,!0)}],Q:[o,function(g){this.month=3*(g-1)+1}],S:[o,function(g){this.milliseconds=100*+g}],SS:[i,function(g){this.milliseconds=10*+g}],SSS:[/\d{3}/,function(g){this.milliseconds=+g}],s:[a,u("seconds")],ss:[a,u("seconds")],m:[a,u("minutes")],mm:[a,u("minutes")],H:[a,u("hours")],h:[a,u("hours")],HH:[a,u("hours")],hh:[a,u("hours")],D:[a,u("day")],DD:[i,u("day")],Do:[s,function(g){var v=l.ordinal,y=g.match(/\d+/);if(this.day=y[0],v)for(var b=1;b<=31;b+=1)v(b).replace(/\[|\]/g,"")===g&&(this.day=b)}],w:[a,u("week")],ww:[i,u("week")],M:[a,u("month")],MM:[i,u("month")],MMM:[s,function(g){var v=f("months"),y=(f("monthsShort")||v.map((function(b){return b.slice(0,3)}))).indexOf(g)+1;if(y<1)throw new Error;this.month=y%12||y}],MMMM:[s,function(g){var v=f("months").indexOf(g)+1;if(v<1)throw new Error;this.month=v%12||v}],Y:[/[+-]?\d+/,u("year")],YY:[i,function(g){this.year=c(g)}],YYYY:[/\d{4}/,u("year")],Z:d,ZZ:d};function p(g){var v,y;v=g,y=l&&l.formats;for(var b=(g=v.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(A,$,M){var N=M&&M.toUpperCase();return $||y[M]||n[M]||y[N].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(D,T,P){return T||P.slice(1)}))}))).match(r),w=b.length,x=0;x<w;x+=1){var E=b[x],k=m[E],S=k&&k[0],O=k&&k[1];b[x]=O?{regex:S,parser:O}:E.replace(/^\[|\]$/g,"")}return function(A){for(var $={},M=0,N=0;M<w;M+=1){var D=b[M];if(typeof D=="string")N+=D.length;else{var T=D.regex,P=D.parser,I=A.slice(N),R=T.exec(I)[0];P.call($,R),A=A.replace(R,"")}}return(function(H){var V=H.afternoon;if(V!==void 0){var L=H.hours;V?L<12&&(H.hours+=12):L===12&&(H.hours=0),delete H.afternoon}})($),$}}return function(g,v,y){y.p.customParseFormat=!0,g&&g.parseTwoDigitYear&&(c=g.parseTwoDigitYear);var b=v.prototype,w=b.parse;b.parse=function(x){var E=x.date,k=x.utc,S=x.args;this.$u=k;var O=S[1];if(typeof O=="string"){var A=S[2]===!0,$=S[3]===!0,M=A||$,N=S[2];$&&(N=S[2]),l=this.$locale(),!A&&N&&(l=y.Ls[N]),this.$d=(function(I,R,H,V){try{if(["x","X"].indexOf(R)>-1)return new Date((R==="X"?1e3:1)*I);var L=p(R)(I),j=L.year,_=L.month,F=L.day,B=L.hours,z=L.minutes,G=L.seconds,W=L.milliseconds,q=L.zone,U=L.week,Y=new Date,ie=F||(j||_?1:Y.getDate()),K=j||Y.getFullYear(),re=0;j&&!_||(re=_>0?_-1:Y.getMonth());var oe,ne=B||0,ae=z||0,de=G||0,ge=W||0;return q?new Date(Date.UTC(K,re,ie,ne,ae,de,ge+60*q.offset*1e3)):H?new Date(Date.UTC(K,re,ie,ne,ae,de,ge)):(oe=new Date(K,re,ie,ne,ae,de,ge),U&&(oe=V(oe).week(U).toDate()),oe)}catch{return new Date("")}})(E,O,k,y),this.init(),N&&N!==!0&&(this.$L=this.locale(N).$L),M&&E!=this.format(O)&&(this.$d=new Date("")),l={}}else if(O instanceof Array)for(var D=O.length,T=1;T<=D;T+=1){S[1]=O[T-1];var P=y.apply(this,S);if(P.isValid()){this.$d=P.$d,this.$L=P.$L,this.init();break}T===D&&(this.$d=new Date(""))}else w.call(this,x)}}}))})(K2)),K2.exports}var CJ=wJ();const kJ=ba(CJ);oo.extend(kJ);oo.extend(xJ);oo.extend(oJ);oo.extend(lJ);oo.extend(fJ);oo.extend(mJ);oo.extend(function(e,t){var n=t.prototype,r=n.format;n.format=function(o){var i=(o||"").replace("Wo","wo");return r.bind(this)(i)}});var SJ={bn_BD:"bn-bd",by_BY:"be",en_GB:"en-gb",en_US:"en",fr_BE:"fr",fr_CA:"fr-ca",hy_AM:"hy-am",kmr_IQ:"ku",nl_BE:"nl-be",pt_BR:"pt-br",zh_CN:"zh-cn",zh_HK:"zh-hk",zh_TW:"zh-tw"},Cs=function(e){var t=SJ[e];return t||e.split("_")[0]},AJ={getNow:function(){var e=oo();return typeof e.tz=="function"?e.tz():e},getFixedDate:function(e){return oo(e,["YYYY-M-DD","YYYY-MM-DD"])},getEndDate:function(e){return e.endOf("month")},getWeekDay:function(e){var t=e.locale("en");return t.weekday()+t.localeData().firstDayOfWeek()},getYear:function(e){return e.year()},getMonth:function(e){return e.month()},getDate:function(e){return e.date()},getHour:function(e){return e.hour()},getMinute:function(e){return e.minute()},getSecond:function(e){return e.second()},getMillisecond:function(e){return e.millisecond()},addYear:function(e,t){return e.add(t,"year")},addMonth:function(e,t){return e.add(t,"month")},addDate:function(e,t){return e.add(t,"day")},setYear:function(e,t){return e.year(t)},setMonth:function(e,t){return e.month(t)},setDate:function(e,t){return e.date(t)},setHour:function(e,t){return e.hour(t)},setMinute:function(e,t){return e.minute(t)},setSecond:function(e,t){return e.second(t)},setMillisecond:function(e,t){return e.millisecond(t)},isAfter:function(e,t){return e.isAfter(t)},isValidate:function(e){return e.isValid()},locale:{getWeekFirstDay:function(e){return oo().locale(Cs(e)).localeData().firstDayOfWeek()},getWeekFirstDate:function(e,t){return t.locale(Cs(e)).weekday(0)},getWeek:function(e,t){return t.locale(Cs(e)).week()},getShortWeekDays:function(e){return oo().locale(Cs(e)).localeData().weekdaysMin()},getShortMonths:function(e){return oo().locale(Cs(e)).localeData().monthsShort()},format:function(e,t,n){return t.locale(Cs(e)).format(n)},parse:function(e,t,n){for(var r=Cs(e),o=0;o<n.length;o+=1){var i=n[o],a=t;if(i.includes("wo")||i.includes("Wo")){for(var s=a.split("-")[0],l=a.split("-")[1],c=oo(s,"YYYY").startOf("year").locale(r),u=0;u<=52;u+=1){var d=c.add(u,"week");if(d.format("Wo")===l)return d}return null}var f=oo(a,i,!0).locale(r);if(f.isValid())return f}return null}}};function $J(e,t){return e!==void 0?e:t?"bottomRight":"bottomLeft"}var Mi=C.createContext(null),OJ={bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:0,adjustY:1}},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:0,adjustY:1}}};function jB(e){var t=e.popupElement,n=e.popupStyle,r=e.popupClassName,o=e.popupAlign,i=e.transitionName,a=e.getPopupContainer,s=e.children,l=e.range,c=e.placement,u=e.builtinPlacements,d=u===void 0?OJ:u,f=e.direction,h=e.visible,m=e.onClose,p=C.useContext(Mi),g=p.prefixCls,v="".concat(g,"-dropdown"),y=$J(c,f==="rtl");return C.createElement(ek,{showAction:[],hideAction:["click"],popupPlacement:y,builtinPlacements:d,prefixCls:v,popupTransitionName:i,popup:t,popupAlign:o,popupVisible:h,popupClassName:me(r,X(X({},"".concat(v,"-range"),l),"".concat(v,"-rtl"),f==="rtl")),popupStyle:n,stretch:"minWidth",getPopupContainer:a,onPopupVisibleChange:function(b){b||m()}},s)}function ik(e,t){for(var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0",r=String(e);r.length<t;)r="".concat(n).concat(r);return r}function ml(e){return e==null?[]:Array.isArray(e)?e:[e]}function Pu(e,t,n){var r=ze(e);return r[t]=n,r}function Fp(e,t){var n={},r=t||Object.keys(e);return r.forEach(function(o){e[o]!==void 0&&(n[o]=e[o])}),n}function LB(e,t,n){if(n)return n;switch(e){case"time":return t.fieldTimeFormat;case"datetime":return t.fieldDateTimeFormat;case"month":return t.fieldMonthFormat;case"year":return t.fieldYearFormat;case"quarter":return t.fieldQuarterFormat;case"week":return t.fieldWeekFormat;default:return t.fieldDateFormat}}function zB(e,t,n){var r=n!==void 0?n:t[t.length-1],o=t.find(function(i){return e[i]});return r!==o?e[o]:void 0}function HB(e){return Fp(e,["placement","builtinPlacements","popupAlign","getPopupContainer","transitionName","direction"])}function ak(e,t,n,r){var o=C.useMemo(function(){return e||function(a,s){var l=a;return t&&s.type==="date"?t(l,s.today):n&&s.type==="month"?n(l,s.locale):s.originNode}},[e,n,t]),i=C.useCallback(function(a,s){return o(a,Q(Q({},s),{},{range:r}))},[o,r]);return i}function WB(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=C.useState([!1,!1]),o=te(r,2),i=o[0],a=o[1],s=function(c,u){a(function(d){return Pu(d,u,c)})},l=C.useMemo(function(){return i.map(function(c,u){if(c)return!0;var d=e[u];return d?!!(!n[u]&&!d||d&&t(d,{activeIndex:u})):!1})},[e,i,t,n]);return[l,s]}function VB(e,t,n,r,o){var i="",a=[];return e&&a.push(o?"hh":"HH"),t&&a.push("mm"),n&&a.push("ss"),i=a.join(":"),r&&(i+=".SSS"),o&&(i+=" A"),i}function MJ(e,t,n,r,o,i){var a=e.fieldDateTimeFormat,s=e.fieldDateFormat,l=e.fieldTimeFormat,c=e.fieldMonthFormat,u=e.fieldYearFormat,d=e.fieldWeekFormat,f=e.fieldQuarterFormat,h=e.yearFormat,m=e.cellYearFormat,p=e.cellQuarterFormat,g=e.dayFormat,v=e.cellDateFormat,y=VB(t,n,r,o,i);return Q(Q({},e),{},{fieldDateTimeFormat:a||"YYYY-MM-DD ".concat(y),fieldDateFormat:s||"YYYY-MM-DD",fieldTimeFormat:l||y,fieldMonthFormat:c||"YYYY-MM",fieldYearFormat:u||"YYYY",fieldWeekFormat:d||"gggg-wo",fieldQuarterFormat:f||"YYYY-[Q]Q",yearFormat:h||"YYYY",cellYearFormat:m||"YYYY",cellQuarterFormat:p||"[Q]Q",cellDateFormat:v||g||"D"})}function GB(e,t){var n=t.showHour,r=t.showMinute,o=t.showSecond,i=t.showMillisecond,a=t.use12Hours;return we.useMemo(function(){return MJ(e,n,r,o,i,a)},[e,n,r,o,i,a])}function nu(e,t,n){return n??t.some(function(r){return e.includes(r)})}var NJ=["showNow","showHour","showMinute","showSecond","showMillisecond","use12Hours","hourStep","minuteStep","secondStep","millisecondStep","hideDisabledOptions","defaultValue","disabledHours","disabledMinutes","disabledSeconds","disabledMilliseconds","disabledTime","changeOnScroll","defaultOpenValue"];function DJ(e){var t=Fp(e,NJ),n=e.format,r=e.picker,o=null;return n&&(o=n,Array.isArray(o)&&(o=o[0]),o=At(o)==="object"?o.format:o),r==="time"&&(t.format=o),[t,o]}function TJ(e){return e&&typeof e=="string"}function UB(e,t,n,r){return[e,t,n,r].some(function(o){return o!==void 0})}function qB(e,t,n,r,o){var i=t,a=n,s=r;if(!e&&!i&&!a&&!s&&!o)i=!0,a=!0,s=!0;else if(e){var l,c,u,d=[i,a,s].some(function(m){return m===!1}),f=[i,a,s].some(function(m){return m===!0}),h=d?!0:!f;i=(l=i)!==null&&l!==void 0?l:h,a=(c=a)!==null&&c!==void 0?c:h,s=(u=s)!==null&&u!==void 0?u:h}return[i,a,s,o]}function YB(e){var t=e.showTime,n=DJ(e),r=te(n,2),o=r[0],i=r[1],a=t&&At(t)==="object"?t:{},s=Q(Q({defaultOpenValue:a.defaultOpenValue||a.defaultValue},o),a),l=s.showMillisecond,c=s.showHour,u=s.showMinute,d=s.showSecond,f=UB(c,u,d,l),h=qB(f,c,u,d,l),m=te(h,3);return c=m[0],u=m[1],d=m[2],[s,Q(Q({},s),{},{showHour:c,showMinute:u,showSecond:d,showMillisecond:l}),s.format,i]}function XB(e,t,n,r,o){var i=e==="time";if(e==="datetime"||i){for(var a=r,s=LB(e,o,null),l=s,c=[t,n],u=0;u<c.length;u+=1){var d=ml(c[u])[0];if(TJ(d)){l=d;break}}var f=a.showHour,h=a.showMinute,m=a.showSecond,p=a.showMillisecond,g=a.use12Hours,v=nu(l,["a","A","LT","LLL","LTS"],g),y=UB(f,h,m,p);y||(f=nu(l,["H","h","k","LT","LLL"]),h=nu(l,["m","LT","LLL"]),m=nu(l,["s","LTS"]),p=nu(l,["SSS"]));var b=qB(y,f,h,m,p),w=te(b,3);f=w[0],h=w[1],m=w[2];var x=t||VB(f,h,m,p,v);return Q(Q({},a),{},{format:x,showHour:f,showMinute:h,showSecond:m,showMillisecond:p,use12Hours:v})}return null}function FJ(e,t,n){if(t===!1)return null;var r=t&&At(t)==="object"?t:{};return r.clearIcon||n||C.createElement("span",{className:"".concat(e,"-clear-btn")})}var Em=7;function gs(e,t,n){return!e&&!t||e===t?!0:!e||!t?!1:n()}function Z2(e,t,n){return gs(t,n,function(){var r=Math.floor(e.getYear(t)/10),o=Math.floor(e.getYear(n)/10);return r===o})}function tl(e,t,n){return gs(t,n,function(){return e.getYear(t)===e.getYear(n)})}function tA(e,t){var n=Math.floor(e.getMonth(t)/3);return n+1}function PJ(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&tA(e,t)===tA(e,n)})}function sk(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&e.getMonth(t)===e.getMonth(n)})}function lk(e,t,n){return gs(t,n,function(){return tl(e,t,n)&&sk(e,t,n)&&e.getDate(t)===e.getDate(n)})}function KB(e,t,n){return gs(t,n,function(){return e.getHour(t)===e.getHour(n)&&e.getMinute(t)===e.getMinute(n)&&e.getSecond(t)===e.getSecond(n)})}function ZB(e,t,n){return gs(t,n,function(){return lk(e,t,n)&&KB(e,t,n)&&e.getMillisecond(t)===e.getMillisecond(n)})}function wu(e,t,n,r){return gs(n,r,function(){var o=e.locale.getWeekFirstDate(t,n),i=e.locale.getWeekFirstDate(t,r);return tl(e,o,i)&&e.locale.getWeek(t,n)===e.locale.getWeek(t,r)})}function lo(e,t,n,r,o){switch(o){case"date":return lk(e,n,r);case"week":return wu(e,t.locale,n,r);case"month":return sk(e,n,r);case"quarter":return PJ(e,n,r);case"year":return tl(e,n,r);case"decade":return Z2(e,n,r);case"time":return KB(e,n,r);default:return ZB(e,n,r)}}function Pp(e,t,n,r){return!t||!n||!r?!1:e.isAfter(r,t)&&e.isAfter(n,r)}function of(e,t,n,r,o){return lo(e,t,n,r,o)?!0:e.isAfter(n,r)}function IJ(e,t,n){var r=t.locale.getWeekFirstDay(e),o=t.setDate(n,1),i=t.getWeekDay(o),a=t.addDate(o,r-i);return t.getMonth(a)===t.getMonth(n)&&t.getDate(a)>1&&(a=t.addDate(a,-7)),a}function _r(e,t){var n=t.generateConfig,r=t.locale,o=t.format;return e?typeof o=="function"?o(e):n.locale.format(r.locale,e,o):""}function m0(e,t,n){var r=t,o=["getHour","getMinute","getSecond","getMillisecond"],i=["setHour","setMinute","setSecond","setMillisecond"];return i.forEach(function(a,s){n?r=e[a](r,e[o[s]](n)):r=e[a](r,0)}),r}function BJ(e,t,n,r,o){var i=cn(function(a,s){return!!(n&&n(a,s)||r&&e.isAfter(r,a)&&!lo(e,t,r,a,s.type)||o&&e.isAfter(a,o)&&!lo(e,t,o,a,s.type))});return i}function RJ(e,t,n){return C.useMemo(function(){var r=LB(e,t,n),o=ml(r),i=o[0],a=At(i)==="object"&&i.type==="mask"?i.format:null;return[o.map(function(s){return typeof s=="string"||typeof s=="function"?s:s.format}),a]},[e,t,n])}function _J(e,t,n){return typeof e[0]=="function"||n?!0:t}function jJ(e,t,n,r){var o=cn(function(i,a){var s=Q({type:t},a);if(delete s.activeIndex,!e.isValidate(i)||n&&n(i,s))return!0;if((t==="date"||t==="time")&&r){var l,c=a&&a.activeIndex===1?"end":"start",u=((l=r.disabledTime)===null||l===void 0?void 0:l.call(r,i,c,{from:s.from}))||{},d=u.disabledHours,f=u.disabledMinutes,h=u.disabledSeconds,m=u.disabledMilliseconds,p=r.disabledHours,g=r.disabledMinutes,v=r.disabledSeconds,y=d||p,b=f||g,w=h||v,x=e.getHour(i),E=e.getMinute(i),k=e.getSecond(i),S=e.getMillisecond(i);if(y&&y().includes(x)||b&&b(x).includes(E)||w&&w(x,E).includes(k)||m&&m(x,E,k).includes(S))return!0}return!1});return o}function af(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=C.useMemo(function(){var r=e&&ml(e);return t&&r&&(r[1]=r[1]||r[0]),r},[e,t]);return n}function QB(e,t){var n=e.generateConfig,r=e.locale,o=e.picker,i=o===void 0?"date":o,a=e.prefixCls,s=a===void 0?"rc-picker":a,l=e.styles,c=l===void 0?{}:l,u=e.classNames,d=u===void 0?{}:u,f=e.order,h=f===void 0?!0:f,m=e.components,p=m===void 0?{}:m,g=e.inputRender,v=e.allowClear,y=e.clearIcon,b=e.needConfirm,w=e.multiple,x=e.format,E=e.inputReadOnly,k=e.disabledDate,S=e.minDate,O=e.maxDate,A=e.showTime,$=e.value,M=e.defaultValue,N=e.pickerValue,D=e.defaultPickerValue,T=af($),P=af(M),I=af(N),R=af(D),H=i==="date"&&A?"datetime":i,V=H==="time"||H==="datetime",L=V||w,j=b??V,_=YB(e),F=te(_,4),B=F[0],z=F[1],G=F[2],W=F[3],q=GB(r,z),U=C.useMemo(function(){return XB(H,G,W,B,q)},[H,G,W,B,q]),Y=C.useMemo(function(){return Q(Q({},e),{},{prefixCls:s,locale:q,picker:i,styles:c,classNames:d,order:h,components:Q({input:g},p),clearIcon:FJ(s,v,y),showTime:U,value:T,defaultValue:P,pickerValue:I,defaultPickerValue:R},t==null?void 0:t())},[e]),ie=RJ(H,q,x),K=te(ie,2),re=K[0],oe=K[1],ne=_J(re,E,w),ae=BJ(n,r,k,S,O),de=jJ(n,i,ae,U),ge=C.useMemo(function(){return Q(Q({},Y),{},{needConfirm:j,inputReadOnly:ne,disabledDate:ae})},[Y,j,ne,ae]);return[ge,H,L,re,oe,de]}function LJ(e,t,n){var r=yr(t,{value:e}),o=te(r,2),i=o[0],a=o[1],s=we.useRef(e),l=we.useRef(),c=function(){en.cancel(l.current)},u=cn(function(){a(s.current),n&&i!==s.current&&n(s.current)}),d=cn(function(f,h){c(),s.current=f,f||h?u():l.current=en(u)});return we.useEffect(function(){return c},[]),[i,d]}function JB(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=arguments.length>3?arguments[3]:void 0,o=n.every(function(u){return u})?!1:e,i=LJ(o,t||!1,r),a=te(i,2),s=a[0],l=a[1];function c(u){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(!d.inherit||s)&&l(u,d.force)}return[s,c]}function eR(e){var t=C.useRef();return C.useImperativeHandle(e,function(){var n;return{nativeElement:(n=t.current)===null||n===void 0?void 0:n.nativeElement,focus:function(r){var o;(o=t.current)===null||o===void 0||o.focus(r)},blur:function(){var r;(r=t.current)===null||r===void 0||r.blur()}}}),t}function tR(e,t){return C.useMemo(function(){return e||(t?(qr(!1,"`ranges` is deprecated. Please use `presets` instead."),Object.entries(t).map(function(n){var r=te(n,2),o=r[0],i=r[1];return{label:o,value:i}})):[])},[e,t])}function ck(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,r=C.useRef(t);r.current=t,nc(function(){if(e)r.current(e);else{var o=en(function(){r.current(e)},n);return function(){en.cancel(o)}}},[e])}function nR(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,r=C.useState(0),o=te(r,2),i=o[0],a=o[1],s=C.useState(!1),l=te(s,2),c=l[0],u=l[1],d=C.useRef([]),f=C.useRef(null),h=C.useRef(null),m=function(b){f.current=b},p=function(b){return f.current===b},g=function(b){u(b)},v=function(b){return b&&(h.current=b),h.current},y=function(b){var w=d.current,x=new Set(w.filter(function(k){return b[k]||t[k]})),E=w[w.length-1]===0?1:0;return x.size>=2||e[E]?null:E};return ck(c||n,function(){c||(d.current=[],m(null))}),C.useEffect(function(){c&&d.current.push(i)},[c,i]),[c,g,v,i,a,y,d.current,m,p]}function zJ(e,t,n,r,o,i){var a=n[n.length-1],s=function(l,c){var u=te(e,2),d=u[0],f=u[1],h=Q(Q({},c),{},{from:zB(e,n)});return a===1&&t[0]&&d&&!lo(r,o,d,l,h.type)&&r.isAfter(d,l)||a===0&&t[1]&&f&&!lo(r,o,f,l,h.type)&&r.isAfter(l,f)?!0:i==null?void 0:i(l,h)};return s}function Cu(e,t,n,r){switch(t){case"date":case"week":return e.addMonth(n,r);case"month":case"quarter":return e.addYear(n,r);case"year":return e.addYear(n,r*10);case"decade":return e.addYear(n,r*100);default:return n}}var wm=[];function rR(e,t,n,r,o,i,a,s){var l=arguments.length>8&&arguments[8]!==void 0?arguments[8]:wm,c=arguments.length>9&&arguments[9]!==void 0?arguments[9]:wm,u=arguments.length>10&&arguments[10]!==void 0?arguments[10]:wm,d=arguments.length>11?arguments[11]:void 0,f=arguments.length>12?arguments[12]:void 0,h=arguments.length>13?arguments[13]:void 0,m=a==="time",p=i||0,g=function(P){var I=e.getNow();return m&&(I=m0(e,I)),l[P]||n[P]||I},v=te(c,2),y=v[0],b=v[1],w=yr(function(){return g(0)},{value:y}),x=te(w,2),E=x[0],k=x[1],S=yr(function(){return g(1)},{value:b}),O=te(S,2),A=O[0],$=O[1],M=C.useMemo(function(){var P=[E,A][p];return m?P:m0(e,P,u[p])},[m,E,A,p,e,u]),N=function(P){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"panel",R=[k,$][p];R(P);var H=[E,A];H[p]=P,d&&(!lo(e,t,E,H[0],a)||!lo(e,t,A,H[1],a))&&d(H,{source:I,range:p===1?"end":"start",mode:r})},D=function(P,I){if(s){var R={date:"month",week:"month",month:"year",quarter:"year"},H=R[a];if(H&&!lo(e,t,P,I,H))return Cu(e,a,I,-1);if(a==="year"&&P){var V=Math.floor(e.getYear(P)/10),L=Math.floor(e.getYear(I)/10);if(V!==L)return Cu(e,a,I,-1)}}return I},T=C.useRef(null);return mn(function(){if(o&&!l[p]){var P=m?null:e.getNow();if(T.current!==null&&T.current!==p?P=[E,A][p^1]:n[p]?P=p===0?n[0]:D(n[0],n[1]):n[p^1]&&(P=n[p^1]),P){f&&e.isAfter(f,P)&&(P=f);var I=s?Cu(e,a,P,1):P;h&&e.isAfter(I,h)&&(P=s?Cu(e,a,h,-1):h),N(P,"reset")}}},[o,p,n[p]]),C.useEffect(function(){o?T.current=p:T.current=null},[o,p]),mn(function(){o&&l&&l[p]&&N(l[p],"reset")},[o,p]),[M,N]}function oR(e,t){var n=C.useRef(e),r=C.useState({}),o=te(r,2),i=o[1],a=function(l){return l&&t!==void 0?t:n.current},s=function(l){n.current=l,i({})};return[a,s,a(!0)]}var HJ=[];function iR(e,t,n){var r=function(i){return i.map(function(a){return _r(a,{generateConfig:e,locale:t,format:n[0]})})},o=function(i,a){for(var s=Math.max(i.length,a.length),l=-1,c=0;c<s;c+=1){var u=i[c]||null,d=a[c]||null;if(u!==d&&!ZB(e,u,d)){l=c;break}}return[l<0,l!==0]};return[r,o]}function aR(e,t){return ze(e).sort(function(n,r){return t.isAfter(n,r)?1:-1})}function WJ(e){var t=oR(e),n=te(t,2),r=n[0],o=n[1],i=cn(function(){o(e)});return C.useEffect(function(){i()},[e]),[r,o]}function sR(e,t,n,r,o,i,a,s,l){var c=yr(i,{value:a}),u=te(c,2),d=u[0],f=u[1],h=d||HJ,m=WJ(h),p=te(m,2),g=p[0],v=p[1],y=iR(e,t,n),b=te(y,2),w=b[0],x=b[1],E=cn(function(S){var O=ze(S);if(r)for(var A=0;A<2;A+=1)O[A]=O[A]||null;else o&&(O=aR(O.filter(function(P){return P}),e));var $=x(g(),O),M=te($,2),N=M[0],D=M[1];if(!N&&(v(O),s)){var T=w(O);s(O,T,{range:D?"end":"start"})}}),k=function(){l&&l(g())};return[h,f,g,E,k]}function lR(e,t,n,r,o,i,a,s,l,c){var u=e.generateConfig,d=e.locale,f=e.picker,h=e.onChange,m=e.allowEmpty,p=e.order,g=i.some(function(N){return N})?!1:p,v=iR(u,d,a),y=te(v,2),b=y[0],w=y[1],x=oR(t),E=te(x,2),k=E[0],S=E[1],O=cn(function(){S(t)});C.useEffect(function(){O()},[t]);var A=cn(function(N){var D=N===null,T=ze(N||k());if(D)for(var P=Math.max(i.length,T.length),I=0;I<P;I+=1)i[I]||(T[I]=null);g&&T[0]&&T[1]&&(T=aR(T,u)),o(T);var R=T,H=te(R,2),V=H[0],L=H[1],j=!V,_=!L,F=m?(!j||m[0])&&(!_||m[1]):!0,B=!p||j||_||lo(u,d,V,L,f)||u.isAfter(L,V),z=(i[0]||!V||!c(V,{activeIndex:0}))&&(i[1]||!L||!c(L,{from:V,activeIndex:1})),G=D||F&&B&&z;if(G){n(T);var W=w(T,t),q=te(W,1),U=q[0];h&&!U&&h(D&&T.every(function(Y){return!Y})?null:T,b(T))}return G}),$=cn(function(N,D){var T=Pu(k(),N,r()[N]);S(T),D&&A()}),M=!s&&!l;return ck(!M,function(){M&&(A(),o(t),O())},2),[$,A]}function cR(e,t,n,r,o){return t!=="date"&&t!=="time"?!1:n!==void 0?n:r!==void 0?r:!o&&(e==="date"||e==="time")}function VJ(e,t,n,r,o,i){var a=e;function s(d,f,h){var m=i[d](a),p=h.find(function(b){return b.value===m});if(!p||p.disabled){var g=h.filter(function(b){return!b.disabled}),v=ze(g).reverse(),y=v.find(function(b){return b.value<=m})||g[0];y&&(m=y.value,a=i[f](a,m))}return m}var l=s("getHour","setHour",t()),c=s("getMinute","setMinute",n(l)),u=s("getSecond","setSecond",r(l,c));return s("getMillisecond","setMillisecond",o(l,c,u)),a}function sf(){return[]}function lf(e,t){for(var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],i=arguments.length>5&&arguments[5]!==void 0?arguments[5]:2,a=[],s=n>=1?n|0:1,l=e;l<=t;l+=s){var c=o.includes(l);(!c||!r)&&a.push({label:ik(l,i),value:l,disabled:c})}return a}function uk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=t||{},o=r.use12Hours,i=r.hourStep,a=i===void 0?1:i,s=r.minuteStep,l=s===void 0?1:s,c=r.secondStep,u=c===void 0?1:c,d=r.millisecondStep,f=d===void 0?100:d,h=r.hideDisabledOptions,m=r.disabledTime,p=r.disabledHours,g=r.disabledMinutes,v=r.disabledSeconds,y=C.useMemo(function(){return n||e.getNow()},[n,e]),b=C.useCallback(function(R){var H=(m==null?void 0:m(R))||{};return[H.disabledHours||p||sf,H.disabledMinutes||g||sf,H.disabledSeconds||v||sf,H.disabledMilliseconds||sf]},[m,p,g,v]),w=C.useMemo(function(){return b(y)},[y,b]),x=te(w,4),E=x[0],k=x[1],S=x[2],O=x[3],A=C.useCallback(function(R,H,V,L){var j=lf(0,23,a,h,R()),_=o?j.map(function(G){return Q(Q({},G),{},{label:ik(G.value%12||12,2)})}):j,F=function(G){return lf(0,59,l,h,H(G))},B=function(G,W){return lf(0,59,u,h,V(G,W))},z=function(G,W,q){return lf(0,999,f,h,L(G,W,q),3)};return[_,F,B,z]},[h,a,o,f,l,u]),$=C.useMemo(function(){return A(E,k,S,O)},[A,E,k,S,O]),M=te($,4),N=M[0],D=M[1],T=M[2],P=M[3],I=function(R,H){var V=function(){return N},L=D,j=T,_=P;if(H){var F=b(H),B=te(F,4),z=B[0],G=B[1],W=B[2],q=B[3],U=A(z,G,W,q),Y=te(U,4),ie=Y[0],K=Y[1],re=Y[2],oe=Y[3];V=function(){return ie},L=K,j=re,_=oe}var ne=VJ(R,V,L,j,_,e);return ne};return[I,N,D,T,P]}function GJ(e){var t=e.mode,n=e.internalMode,r=e.renderExtraFooter,o=e.showNow,i=e.showTime,a=e.onSubmit,s=e.onNow,l=e.invalid,c=e.needConfirm,u=e.generateConfig,d=e.disabledDate,f=C.useContext(Mi),h=f.prefixCls,m=f.locale,p=f.button,g=p===void 0?"button":p,v=u.getNow(),y=uk(u,i,v),b=te(y,1),w=b[0],x=r==null?void 0:r(t),E=d(v,{type:t}),k=function(){if(!E){var N=w(v);s(N)}},S="".concat(h,"-now"),O="".concat(S,"-btn"),A=o&&C.createElement("li",{className:S},C.createElement("a",{className:me(O,E&&"".concat(O,"-disabled")),"aria-disabled":E,onClick:k},n==="date"?m.today:m.now)),$=c&&C.createElement("li",{className:"".concat(h,"-ok")},C.createElement(g,{disabled:l,onClick:a},m.ok)),M=(A||$)&&C.createElement("ul",{className:"".concat(h,"-ranges")},A,$);return!x&&!M?null:C.createElement("div",{className:"".concat(h,"-footer")},x&&C.createElement("div",{className:"".concat(h,"-footer-extra")},x),M)}function uR(e,t,n){function r(o,i){var a=o.findIndex(function(l){return lo(e,t,l,i,n)});if(a===-1)return[].concat(ze(o),[i]);var s=ze(o);return s.splice(a,1),s}return r}var vl=C.createContext(null);function Ip(){return C.useContext(vl)}function Ic(e,t){var n=e.prefixCls,r=e.generateConfig,o=e.locale,i=e.disabledDate,a=e.minDate,s=e.maxDate,l=e.cellRender,c=e.hoverValue,u=e.hoverRangeValue,d=e.onHover,f=e.values,h=e.pickerValue,m=e.onSelect,p=e.prevIcon,g=e.nextIcon,v=e.superPrevIcon,y=e.superNextIcon,b=r.getNow(),w={now:b,values:f,pickerValue:h,prefixCls:n,disabledDate:i,minDate:a,maxDate:s,cellRender:l,hoverValue:c,hoverRangeValue:u,onHover:d,locale:o,generateConfig:r,onSelect:m,panelType:t,prevIcon:p,nextIcon:g,superPrevIcon:v,superNextIcon:y};return[w,b]}var Ya=C.createContext({});function Dd(e){for(var t=e.rowNum,n=e.colNum,r=e.baseDate,o=e.getCellDate,i=e.prefixColumn,a=e.rowClassName,s=e.titleFormat,l=e.getCellText,c=e.getCellClassName,u=e.headerCells,d=e.cellSelection,f=d===void 0?!0:d,h=e.disabledDate,m=Ip(),p=m.prefixCls,g=m.panelType,v=m.now,y=m.disabledDate,b=m.cellRender,w=m.onHover,x=m.hoverValue,E=m.hoverRangeValue,k=m.generateConfig,S=m.values,O=m.locale,A=m.onSelect,$=h||y,M="".concat(p,"-cell"),N=C.useContext(Ya),D=N.onCellDblClick,T=function(j){return S.some(function(_){return _&&lo(k,O,j,_,g)})},P=[],I=0;I<t;I+=1){for(var R=[],H=void 0,V=function(){var j=I*n+L,_=o(r,j),F=$==null?void 0:$(_,{type:g});L===0&&(H=_,i&&R.push(i(H)));var B=!1,z=!1,G=!1;if(f&&E){var W=te(E,2),q=W[0],U=W[1];B=Pp(k,q,U,_),z=lo(k,O,_,q,g),G=lo(k,O,_,U,g)}var Y=s?_r(_,{locale:O,format:s,generateConfig:k}):void 0,ie=C.createElement("div",{className:"".concat(M,"-inner")},l(_));R.push(C.createElement("td",{key:L,title:Y,className:me(M,Q(X(X(X(X(X(X({},"".concat(M,"-disabled"),F),"".concat(M,"-hover"),(x||[]).some(function(K){return lo(k,O,_,K,g)})),"".concat(M,"-in-range"),B&&!z&&!G),"".concat(M,"-range-start"),z),"".concat(M,"-range-end"),G),"".concat(p,"-cell-selected"),!E&&g!=="week"&&T(_)),c(_))),onClick:function(){F||A(_)},onDoubleClick:function(){!F&&D&&D()},onMouseEnter:function(){F||(w==null||w(_))},onMouseLeave:function(){F||(w==null||w(null))}},b?b(_,{prefixCls:p,originNode:ie,today:v,type:g,locale:O}):ie))},L=0;L<n;L+=1)V();P.push(C.createElement("tr",{key:I,className:a==null?void 0:a(H)},R))}return C.createElement("div",{className:"".concat(p,"-body")},C.createElement("table",{className:"".concat(p,"-content")},u&&C.createElement("thead",null,C.createElement("tr",null,u)),C.createElement("tbody",null,P)))}var cf={visibility:"hidden"};function Bc(e){var t=e.offset,n=e.superOffset,r=e.onChange,o=e.getStart,i=e.getEnd,a=e.children,s=Ip(),l=s.prefixCls,c=s.prevIcon,u=c===void 0?"\u2039":c,d=s.nextIcon,f=d===void 0?"\u203A":d,h=s.superPrevIcon,m=h===void 0?"\xAB":h,p=s.superNextIcon,g=p===void 0?"\xBB":p,v=s.minDate,y=s.maxDate,b=s.generateConfig,w=s.locale,x=s.pickerValue,E=s.panelType,k="".concat(l,"-header"),S=C.useContext(Ya),O=S.hidePrev,A=S.hideNext,$=S.hideHeader,M=C.useMemo(function(){if(!v||!t||!i)return!1;var j=i(t(-1,x));return!of(b,w,j,v,E)},[v,t,x,i,b,w,E]),N=C.useMemo(function(){if(!v||!n||!i)return!1;var j=i(n(-1,x));return!of(b,w,j,v,E)},[v,n,x,i,b,w,E]),D=C.useMemo(function(){if(!y||!t||!o)return!1;var j=o(t(1,x));return!of(b,w,y,j,E)},[y,t,x,o,b,w,E]),T=C.useMemo(function(){if(!y||!n||!o)return!1;var j=o(n(1,x));return!of(b,w,y,j,E)},[y,n,x,o,b,w,E]),P=function(j){t&&r(t(j,x))},I=function(j){n&&r(n(j,x))};if($)return null;var R="".concat(k,"-prev-btn"),H="".concat(k,"-next-btn"),V="".concat(k,"-super-prev-btn"),L="".concat(k,"-super-next-btn");return C.createElement("div",{className:k},n&&C.createElement("button",{type:"button","aria-label":w.previousYear,onClick:function(){return I(-1)},tabIndex:-1,className:me(V,N&&"".concat(V,"-disabled")),disabled:N,style:O?cf:{}},m),t&&C.createElement("button",{type:"button","aria-label":w.previousMonth,onClick:function(){return P(-1)},tabIndex:-1,className:me(R,M&&"".concat(R,"-disabled")),disabled:M,style:O?cf:{}},u),C.createElement("div",{className:"".concat(k,"-view")},a),t&&C.createElement("button",{type:"button","aria-label":w.nextMonth,onClick:function(){return P(1)},tabIndex:-1,className:me(H,D&&"".concat(H,"-disabled")),disabled:D,style:A?cf:{}},f),n&&C.createElement("button",{type:"button","aria-label":w.nextYear,onClick:function(){return I(1)},tabIndex:-1,className:me(L,T&&"".concat(L,"-disabled")),disabled:T,style:A?cf:{}},g))}function Bp(e){var t=e.prefixCls,n=e.panelName,r=n===void 0?"date":n,o=e.locale,i=e.generateConfig,a=e.pickerValue,s=e.onPickerValueChange,l=e.onModeChange,c=e.mode,u=c===void 0?"date":c,d=e.disabledDate,f=e.onSelect,h=e.onHover,m=e.showWeek,p="".concat(t,"-").concat(r,"-panel"),g="".concat(t,"-cell"),v=u==="week",y=Ic(e,u),b=te(y,2),w=b[0],x=b[1],E=i.locale.getWeekFirstDay(o.locale),k=i.setDate(a,1),S=IJ(o.locale,i,k),O=i.getMonth(a),A=m===void 0?v:m,$=A?function(j){var _=d==null?void 0:d(j,{type:"week"});return C.createElement("td",{key:"week",className:me(g,"".concat(g,"-week"),X({},"".concat(g,"-disabled"),_)),onClick:function(){_||f(j)},onMouseEnter:function(){_||(h==null||h(j))},onMouseLeave:function(){_||(h==null||h(null))}},C.createElement("div",{className:"".concat(g,"-inner")},i.locale.getWeek(o.locale,j)))}:null,M=[],N=o.shortWeekDays||(i.locale.getShortWeekDays?i.locale.getShortWeekDays(o.locale):[]);$&&M.push(C.createElement("th",{key:"empty"},C.createElement("span",{style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},o.week)));for(var D=0;D<Em;D+=1)M.push(C.createElement("th",{key:D},N[(D+E)%Em]));var T=function(j,_){return i.addDate(j,_)},P=function(j){return _r(j,{locale:o,format:o.cellDateFormat,generateConfig:i})},I=function(j){var _=X(X({},"".concat(t,"-cell-in-view"),sk(i,j,a)),"".concat(t,"-cell-today"),lk(i,j,x));return _},R=o.shortMonths||(i.locale.getShortMonths?i.locale.getShortMonths(o.locale):[]),H=C.createElement("button",{type:"button","aria-label":o.yearSelect,key:"year",onClick:function(){l("year",a)},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(a,{locale:o,format:o.yearFormat,generateConfig:i})),V=C.createElement("button",{type:"button","aria-label":o.monthSelect,key:"month",onClick:function(){l("month",a)},tabIndex:-1,className:"".concat(t,"-month-btn")},o.monthFormat?_r(a,{locale:o,format:o.monthFormat,generateConfig:i}):R[O]),L=o.monthBeforeYear?[V,H]:[H,V];return C.createElement(vl.Provider,{value:w},C.createElement("div",{className:me(p,m&&"".concat(p,"-show-week"))},C.createElement(Bc,{offset:function(j){return i.addMonth(a,j)},superOffset:function(j){return i.addYear(a,j)},onChange:s,getStart:function(j){return i.setDate(j,1)},getEnd:function(j){var _=i.setDate(j,1);return _=i.addMonth(_,1),i.addDate(_,-1)}},L),C.createElement(Dd,Qe({titleFormat:o.fieldDateFormat},e,{colNum:Em,rowNum:6,baseDate:S,headerCells:M,getCellDate:T,getCellText:P,getCellClassName:I,prefixColumn:$,cellSelection:!v}))))}var UJ=1/3;function qJ(e,t){var n=C.useRef(!1),r=C.useRef(null),o=C.useRef(null),i=function(){return n.current},a=function(){en.cancel(r.current),n.current=!1},s=C.useRef(),l=function(){var u=e.current;if(o.current=null,s.current=0,u){var d=u.querySelector('[data-value="'.concat(t,'"]')),f=u.querySelector("li"),h=function m(){a(),n.current=!0,s.current+=1;var p=u.scrollTop,g=f.offsetTop,v=d.offsetTop,y=v-g;if(v===0&&d!==f||!wp(u)){s.current<=5&&(r.current=en(m));return}var b=p+(y-p)*UJ,w=Math.abs(y-b);if(o.current!==null&&o.current<w){a();return}if(o.current=w,w<=1){u.scrollTop=y,a();return}u.scrollTop=b,r.current=en(m)};d&&f&&h()}},c=cn(l);return[c,a,i]}var YJ=300;function XJ(e){return e.map(function(t){var n=t.value,r=t.label,o=t.disabled;return[n,r,o].join(",")}).join(";")}function ru(e){var t=e.units,n=e.value,r=e.optionalValue,o=e.type,i=e.onChange,a=e.onHover,s=e.onDblClick,l=e.changeOnScroll,c=Ip(),u=c.prefixCls,d=c.cellRender,f=c.now,h=c.locale,m="".concat(u,"-time-panel"),p="".concat(u,"-time-panel-cell"),g=C.useRef(null),v=C.useRef(),y=function(){clearTimeout(v.current)},b=qJ(g,n??r),w=te(b,3),x=w[0],E=w[1],k=w[2];mn(function(){return x(),y(),function(){E(),y()}},[n,r,XJ(t)]);var S=function(A){y();var $=A.target;!k()&&l&&(v.current=setTimeout(function(){var M=g.current,N=M.querySelector("li").offsetTop,D=Array.from(M.querySelectorAll("li")),T=D.map(function(V){return V.offsetTop-N}),P=T.map(function(V,L){return t[L].disabled?Number.MAX_SAFE_INTEGER:Math.abs(V-$.scrollTop)}),I=Math.min.apply(Math,ze(P)),R=P.findIndex(function(V){return V===I}),H=t[R];H&&!H.disabled&&i(H.value)},YJ))},O="".concat(m,"-column");return C.createElement("ul",{className:O,ref:g,"data-type":o,onScroll:S},t.map(function(A){var $=A.label,M=A.value,N=A.disabled,D=C.createElement("div",{className:"".concat(p,"-inner")},$);return C.createElement("li",{key:M,className:me(p,X(X({},"".concat(p,"-selected"),n===M),"".concat(p,"-disabled"),N)),onClick:function(){N||i(M)},onDoubleClick:function(){!N&&s&&s()},onMouseEnter:function(){a(M)},onMouseLeave:function(){a(null)},"data-value":M},d?d(M,{prefixCls:u,originNode:D,today:f,type:"time",subType:o,locale:h}):D)}))}function Na(e){return e<12}function KJ(e){var t=e.showHour,n=e.showMinute,r=e.showSecond,o=e.showMillisecond,i=e.use12Hours,a=e.changeOnScroll,s=Ip(),l=s.prefixCls,c=s.values,u=s.generateConfig,d=s.locale,f=s.onSelect,h=s.onHover,m=h===void 0?function(){}:h,p=s.pickerValue,g=(c==null?void 0:c[0])||null,v=C.useContext(Ya),y=v.onCellDblClick,b=uk(u,e,g),w=te(b,5),x=w[0],E=w[1],k=w[2],S=w[3],O=w[4],A=function(Ee){var yt=g&&u[Ee](g),Dt=p&&u[Ee](p);return[yt,Dt]},$=A("getHour"),M=te($,2),N=M[0],D=M[1],T=A("getMinute"),P=te(T,2),I=P[0],R=P[1],H=A("getSecond"),V=te(H,2),L=V[0],j=V[1],_=A("getMillisecond"),F=te(_,2),B=F[0],z=F[1],G=N===null?null:Na(N)?"am":"pm",W=C.useMemo(function(){return i?Na(N)?E.filter(function(Ee){return Na(Ee.value)}):E.filter(function(Ee){return!Na(Ee.value)}):E},[N,E,i]),q=function(Ee,yt){var Dt,Pt=Ee.filter(function(Ut){return!Ut.disabled});return yt??(Pt==null||(Dt=Pt[0])===null||Dt===void 0?void 0:Dt.value)},U=q(E,N),Y=C.useMemo(function(){return k(U)},[k,U]),ie=q(Y,I),K=C.useMemo(function(){return S(U,ie)},[S,U,ie]),re=q(K,L),oe=C.useMemo(function(){return O(U,ie,re)},[O,U,ie,re]),ne=q(oe,B),ae=C.useMemo(function(){if(!i)return[];var Ee=u.getNow(),yt=u.setHour(Ee,6),Dt=u.setHour(Ee,18),Pt=function(Ut,Ge){var Xe=d.cellMeridiemFormat;return Xe?_r(Ut,{generateConfig:u,locale:d,format:Xe}):Ge};return[{label:Pt(yt,"AM"),value:"am",disabled:E.every(function(Ut){return Ut.disabled||!Na(Ut.value)})},{label:Pt(Dt,"PM"),value:"pm",disabled:E.every(function(Ut){return Ut.disabled||Na(Ut.value)})}]},[E,i,u,d]),de=function(Ee){var yt=x(Ee);f(yt)},ge=C.useMemo(function(){var Ee=g||p||u.getNow(),yt=function(Dt){return Dt!=null};return yt(N)?(Ee=u.setHour(Ee,N),Ee=u.setMinute(Ee,I),Ee=u.setSecond(Ee,L),Ee=u.setMillisecond(Ee,B)):yt(D)?(Ee=u.setHour(Ee,D),Ee=u.setMinute(Ee,R),Ee=u.setSecond(Ee,j),Ee=u.setMillisecond(Ee,z)):yt(U)&&(Ee=u.setHour(Ee,U),Ee=u.setMinute(Ee,ie),Ee=u.setSecond(Ee,re),Ee=u.setMillisecond(Ee,ne)),Ee},[g,p,N,I,L,B,U,ie,re,ne,D,R,j,z,u]),Se=function(Ee,yt){return Ee===null?null:u[yt](ge,Ee)},ye=function(Ee){return Se(Ee,"setHour")},be=function(Ee){return Se(Ee,"setMinute")},ce=function(Ee){return Se(Ee,"setSecond")},he=function(Ee){return Se(Ee,"setMillisecond")},Te=function(Ee){return Ee===null?null:Ee==="am"&&!Na(N)?u.setHour(ge,N-12):Ee==="pm"&&Na(N)?u.setHour(ge,N+12):ge},se=function(Ee){de(ye(Ee))},Pe=function(Ee){de(be(Ee))},De=function(Ee){de(ce(Ee))},He=function(Ee){de(he(Ee))},ue=function(Ee){de(Te(Ee))},ve=function(Ee){m(ye(Ee))},xe=function(Ee){m(be(Ee))},fe=function(Ee){m(ce(Ee))},pe=function(Ee){m(he(Ee))},ke=function(Ee){m(Te(Ee))},Ve={onDblClick:y,changeOnScroll:a};return C.createElement("div",{className:"".concat(l,"-content")},t&&C.createElement(ru,Qe({units:W,value:N,optionalValue:D,type:"hour",onChange:se,onHover:ve},Ve)),n&&C.createElement(ru,Qe({units:Y,value:I,optionalValue:R,type:"minute",onChange:Pe,onHover:xe},Ve)),r&&C.createElement(ru,Qe({units:K,value:L,optionalValue:j,type:"second",onChange:De,onHover:fe},Ve)),o&&C.createElement(ru,Qe({units:oe,value:B,optionalValue:z,type:"millisecond",onChange:He,onHover:pe},Ve)),i&&C.createElement(ru,Qe({units:ae,value:G,type:"meridiem",onChange:ue,onHover:ke},Ve)))}function dR(e){var t=e.prefixCls,n=e.value,r=e.locale,o=e.generateConfig,i=e.showTime,a=i||{},s=a.format,l="".concat(t,"-time-panel"),c=Ic(e,"time"),u=te(c,1),d=u[0];return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:me(l)},C.createElement(Bc,null,n?_r(n,{locale:r,format:s,generateConfig:o}):"\xA0"),C.createElement(KJ,i)))}function ZJ(e){var t=e.prefixCls,n=e.generateConfig,r=e.showTime,o=e.onSelect,i=e.value,a=e.pickerValue,s=e.onHover,l="".concat(t,"-datetime-panel"),c=uk(n,r),u=te(c,1),d=u[0],f=function(p){return i?m0(n,p,i):m0(n,p,a)},h=function(p){s==null||s(p&&f(p))},m=function(p){var g=f(p);o(d(g,g))};return C.createElement("div",{className:l},C.createElement(Bp,Qe({},e,{onSelect:m,onHover:h})),C.createElement(dR,e))}function QJ(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s="".concat(t,"-decade-panel"),l=Ic(e,"decade"),c=te(l,1),u=c[0],d=function(x){var E=Math.floor(r.getYear(x)/100)*100;return r.setYear(x,E)},f=function(x){var E=d(x);return r.addYear(E,99)},h=d(o),m=f(o),p=r.addYear(h,-10),g=function(x,E){return r.addYear(x,E*10)},v=function(x){var E=n.cellYearFormat,k=_r(x,{locale:n,format:E,generateConfig:r}),S=_r(r.addYear(x,9),{locale:n,format:E,generateConfig:r});return"".concat(k,"-").concat(S)},y=function(x){return X({},"".concat(t,"-cell-in-view"),Z2(r,x,h)||Z2(r,x,m)||Pp(r,h,m,x))},b=i?function(x,E){var k=r.setDate(x,1),S=r.setMonth(k,0),O=r.setYear(S,Math.floor(r.getYear(S)/10)*10),A=r.addYear(O,10),$=r.addDate(A,-1);return i(O,E)&&i($,E)}:null,w="".concat(_r(h,{locale:n,format:n.yearFormat,generateConfig:r}),"-").concat(_r(m,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:u},C.createElement("div",{className:s},C.createElement(Bc,{superOffset:function(x){return r.addYear(o,x*100)},onChange:a,getStart:d,getEnd:f},w),C.createElement(Dd,Qe({},e,{disabledDate:b,colNum:3,rowNum:4,baseDate:p,getCellDate:g,getCellText:v,getCellClassName:y}))))}function JJ(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s=e.onModeChange,l="".concat(t,"-month-panel"),c=Ic(e,"month"),u=te(c,1),d=u[0],f=r.setMonth(o,0),h=n.shortMonths||(r.locale.getShortMonths?r.locale.getShortMonths(n.locale):[]),m=function(b,w){return r.addMonth(b,w)},p=function(b){var w=r.getMonth(b);return n.monthFormat?_r(b,{locale:n,format:n.monthFormat,generateConfig:r}):h[w]},g=function(){return X({},"".concat(t,"-cell-in-view"),!0)},v=i?function(b,w){var x=r.setDate(b,1),E=r.setMonth(x,r.getMonth(x)+1),k=r.addDate(E,-1);return i(x,w)&&i(k,w)}:null,y=C.createElement("button",{type:"button",key:"year","aria-label":n.yearSelect,onClick:function(){s("year")},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(o,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:l},C.createElement(Bc,{superOffset:function(b){return r.addYear(o,b)},onChange:a,getStart:function(b){return r.setMonth(b,0)},getEnd:function(b){return r.setMonth(b,11)}},y),C.createElement(Dd,Qe({},e,{disabledDate:v,titleFormat:n.fieldMonthFormat,colNum:3,rowNum:4,baseDate:f,getCellDate:m,getCellText:p,getCellClassName:g}))))}function e7(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.onPickerValueChange,a=e.onModeChange,s="".concat(t,"-quarter-panel"),l=Ic(e,"quarter"),c=te(l,1),u=c[0],d=r.setMonth(o,0),f=function(g,v){return r.addMonth(g,v*3)},h=function(g){return _r(g,{locale:n,format:n.cellQuarterFormat,generateConfig:r})},m=function(){return X({},"".concat(t,"-cell-in-view"),!0)},p=C.createElement("button",{type:"button",key:"year","aria-label":n.yearSelect,onClick:function(){a("year")},tabIndex:-1,className:"".concat(t,"-year-btn")},_r(o,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:u},C.createElement("div",{className:s},C.createElement(Bc,{superOffset:function(g){return r.addYear(o,g)},onChange:i,getStart:function(g){return r.setMonth(g,0)},getEnd:function(g){return r.setMonth(g,11)}},p),C.createElement(Dd,Qe({},e,{titleFormat:n.fieldQuarterFormat,colNum:4,rowNum:1,baseDate:d,getCellDate:f,getCellText:h,getCellClassName:m}))))}function t7(e){var t=e.prefixCls,n=e.generateConfig,r=e.locale,o=e.value,i=e.hoverValue,a=e.hoverRangeValue,s=r.locale,l="".concat(t,"-week-panel-row"),c=function(u){var d={};if(a){var f=te(a,2),h=f[0],m=f[1],p=wu(n,s,h,u),g=wu(n,s,m,u);d["".concat(l,"-range-start")]=p,d["".concat(l,"-range-end")]=g,d["".concat(l,"-range-hover")]=!p&&!g&&Pp(n,h,m,u)}return i&&(d["".concat(l,"-hover")]=i.some(function(v){return wu(n,s,u,v)})),me(l,X({},"".concat(l,"-selected"),!a&&wu(n,s,o,u)),d)};return C.createElement(Bp,Qe({},e,{mode:"week",panelName:"week",rowClassName:c}))}function n7(e){var t=e.prefixCls,n=e.locale,r=e.generateConfig,o=e.pickerValue,i=e.disabledDate,a=e.onPickerValueChange,s=e.onModeChange,l="".concat(t,"-year-panel"),c=Ic(e,"year"),u=te(c,1),d=u[0],f=function(E){var k=Math.floor(r.getYear(E)/10)*10;return r.setYear(E,k)},h=function(E){var k=f(E);return r.addYear(k,9)},m=f(o),p=h(o),g=r.addYear(m,-1),v=function(E,k){return r.addYear(E,k)},y=function(E){return _r(E,{locale:n,format:n.cellYearFormat,generateConfig:r})},b=function(E){return X({},"".concat(t,"-cell-in-view"),tl(r,E,m)||tl(r,E,p)||Pp(r,m,p,E))},w=i?function(E,k){var S=r.setMonth(E,0),O=r.setDate(S,1),A=r.addYear(O,1),$=r.addDate(A,-1);return i(O,k)&&i($,k)}:null,x=C.createElement("button",{type:"button",key:"decade","aria-label":n.decadeSelect,onClick:function(){s("decade")},tabIndex:-1,className:"".concat(t,"-decade-btn")},_r(m,{locale:n,format:n.yearFormat,generateConfig:r}),"-",_r(p,{locale:n,format:n.yearFormat,generateConfig:r}));return C.createElement(vl.Provider,{value:d},C.createElement("div",{className:l},C.createElement(Bc,{superOffset:function(E){return r.addYear(o,E*10)},onChange:a,getStart:f,getEnd:h},x),C.createElement(Dd,Qe({},e,{disabledDate:w,titleFormat:n.fieldYearFormat,colNum:3,rowNum:4,baseDate:g,getCellDate:v,getCellText:y,getCellClassName:b}))))}var r7={date:Bp,datetime:ZJ,week:t7,month:JJ,quarter:e7,year:n7,decade:QJ,time:dR};function o7(e,t){var n,r=e.locale,o=e.generateConfig,i=e.direction,a=e.prefixCls,s=e.tabIndex,l=s===void 0?0:s,c=e.multiple,u=e.defaultValue,d=e.value,f=e.onChange,h=e.onSelect,m=e.defaultPickerValue,p=e.pickerValue,g=e.onPickerValueChange,v=e.mode,y=e.onPanelChange,b=e.picker,w=b===void 0?"date":b,x=e.showTime,E=e.hoverValue,k=e.hoverRangeValue,S=e.cellRender,O=e.dateRender,A=e.monthCellRender,$=e.components,M=$===void 0?{}:$,N=e.hideHeader,D=((n=C.useContext(Mi))===null||n===void 0?void 0:n.prefixCls)||a||"rc-picker",T=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:T.current}});var P=YB(e),I=te(P,4),R=I[0],H=I[1],V=I[2],L=I[3],j=GB(r,H),_=w==="date"&&x?"datetime":w,F=C.useMemo(function(){return XB(_,V,L,R,j)},[_,V,L,R,j]),B=o.getNow(),z=yr(w,{value:v,postState:function(pe){return pe||"date"}}),G=te(z,2),W=G[0],q=G[1],U=W==="date"&&F?"datetime":W,Y=uR(o,r,_),ie=yr(u,{value:d}),K=te(ie,2),re=K[0],oe=K[1],ne=C.useMemo(function(){var pe=ml(re).filter(function(ke){return ke});return c?pe:pe.slice(0,1)},[re,c]),ae=cn(function(pe){oe(pe),f&&(pe===null||ne.length!==pe.length||ne.some(function(ke,Ve){return!lo(o,r,ke,pe[Ve],_)}))&&(f==null||f(c?pe:pe[0]))}),de=cn(function(pe){if(h==null||h(pe),W===w){var ke=c?Y(ne,pe):[pe];ae(ke)}}),ge=yr(m||ne[0]||B,{value:p}),Se=te(ge,2),ye=Se[0],be=Se[1];C.useEffect(function(){ne[0]&&!p&&be(ne[0])},[ne[0]]);var ce=function(pe,ke){y==null||y(pe||p,ke||W)},he=function(pe){var ke=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;be(pe),g==null||g(pe),ke&&ce(pe)},Te=function(pe,ke){q(pe),ke&&he(ke),ce(ke,pe)},se=function(pe){if(de(pe),he(pe),W!==w){var ke=["decade","year"],Ve=[].concat(ke,["month"]),Ee={quarter:[].concat(ke,["quarter"]),week:[].concat(ze(Ve),["week"]),date:[].concat(ze(Ve),["date"])},yt=Ee[w]||Ve,Dt=yt.indexOf(W),Pt=yt[Dt+1];Pt&&Te(Pt,pe)}},Pe=C.useMemo(function(){var pe,ke;if(Array.isArray(k)){var Ve=te(k,2);pe=Ve[0],ke=Ve[1]}else pe=k;return!pe&&!ke?null:(pe=pe||ke,ke=ke||pe,o.isAfter(pe,ke)?[ke,pe]:[pe,ke])},[k,o]),De=ak(S,O,A),He=M[U]||r7[U]||Bp,ue=C.useContext(Ya),ve=C.useMemo(function(){return Q(Q({},ue),{},{hideHeader:N})},[ue,N]),xe="".concat(D,"-panel"),fe=Fp(e,["showWeek","prevIcon","nextIcon","superPrevIcon","superNextIcon","disabledDate","minDate","maxDate","onHover"]);return C.createElement(Ya.Provider,{value:ve},C.createElement("div",{ref:T,tabIndex:l,className:me(xe,X({},"".concat(xe,"-rtl"),i==="rtl"))},C.createElement(He,Qe({},fe,{showTime:F,prefixCls:D,locale:j,generateConfig:o,onModeChange:Te,pickerValue:ye,onPickerValueChange:function(pe){he(pe,!0)},value:ne[0],onSelect:se,values:ne,cellRender:De,hoverRangeValue:Pe,hoverValue:E}))))}var Cm=C.memo(C.forwardRef(o7));function i7(e){var t=e.picker,n=e.multiplePanel,r=e.pickerValue,o=e.onPickerValueChange,i=e.needConfirm,a=e.onSubmit,s=e.range,l=e.hoverValue,c=C.useContext(Mi),u=c.prefixCls,d=c.generateConfig,f=C.useCallback(function(y,b){return Cu(d,t,y,b)},[d,t]),h=C.useMemo(function(){return f(r,1)},[r,f]),m=function(y){o(f(y,-1))},p={onCellDblClick:function(){i&&a()}},g=t==="time",v=Q(Q({},e),{},{hoverValue:null,hoverRangeValue:null,hideHeader:g});return s?v.hoverRangeValue=l:v.hoverValue=l,n?C.createElement("div",{className:"".concat(u,"-panels")},C.createElement(Ya.Provider,{value:Q(Q({},p),{},{hideNext:!0})},C.createElement(Cm,v)),C.createElement(Ya.Provider,{value:Q(Q({},p),{},{hidePrev:!0})},C.createElement(Cm,Qe({},v,{pickerValue:h,onPickerValueChange:m})))):C.createElement(Ya.Provider,{value:Q({},p)},C.createElement(Cm,v))}function nA(e){return typeof e=="function"?e():e}function a7(e){var t=e.prefixCls,n=e.presets,r=e.onClick,o=e.onHover;return n.length?C.createElement("div",{className:"".concat(t,"-presets")},C.createElement("ul",null,n.map(function(i,a){var s=i.label,l=i.value;return C.createElement("li",{key:a,onClick:function(){r(nA(l))},onMouseEnter:function(){o(nA(l))},onMouseLeave:function(){o(null)}},s)}))):null}function fR(e){var t=e.panelRender,n=e.internalMode,r=e.picker,o=e.showNow,i=e.range,a=e.multiple,s=e.activeInfo,l=s===void 0?[0,0,0]:s,c=e.presets,u=e.onPresetHover,d=e.onPresetSubmit,f=e.onFocus,h=e.onBlur,m=e.onPanelMouseDown,p=e.direction,g=e.value,v=e.onSelect,y=e.isInvalid,b=e.defaultOpenValue,w=e.onOk,x=e.onSubmit,E=C.useContext(Mi),k=E.prefixCls,S="".concat(k,"-panel"),O=p==="rtl",A=C.useRef(null),$=C.useRef(null),M=C.useState(0),N=te(M,2),D=N[0],T=N[1],P=C.useState(0),I=te(P,2),R=I[0],H=I[1],V=C.useState(0),L=te(V,2),j=L[0],_=L[1],F=function(Te){Te.width&&T(Te.width)},B=te(l,3),z=B[0],G=B[1],W=B[2],q=C.useState(0),U=te(q,2),Y=U[0],ie=U[1];C.useEffect(function(){ie(10)},[z]),C.useEffect(function(){if(i&&$.current){var Te,se=((Te=A.current)===null||Te===void 0?void 0:Te.offsetWidth)||0,Pe=$.current.getBoundingClientRect();if(!Pe.height||Pe.right<0){ie(function(ve){return Math.max(0,ve-1)});return}var De=(O?G-se:z)-Pe.left;if(_(De),D&&D<W){var He=O?Pe.right-(G-se+D):z+se-Pe.left-D,ue=Math.max(0,He);H(ue)}else H(0)}},[Y,O,D,z,G,W,i]);function K(Te){return Te.filter(function(se){return se})}var re=C.useMemo(function(){return K(ml(g))},[g]),oe=r==="time"&&!re.length,ne=C.useMemo(function(){return oe?K([b]):re},[oe,re,b]),ae=oe?b:re,de=C.useMemo(function(){return ne.length?ne.some(function(Te){return y(Te)}):!0},[ne,y]),ge=function(){oe&&v(b),w(),x()},Se=C.createElement("div",{className:"".concat(k,"-panel-layout")},C.createElement(a7,{prefixCls:k,presets:c,onClick:d,onHover:u}),C.createElement("div",null,C.createElement(i7,Qe({},e,{value:ae})),C.createElement(GJ,Qe({},e,{showNow:a?!1:o,invalid:de,onSubmit:ge}))));t&&(Se=t(Se));var ye="".concat(S,"-container"),be="marginLeft",ce="marginRight",he=C.createElement("div",{onMouseDown:m,tabIndex:-1,className:me(ye,"".concat(k,"-").concat(n,"-panel-container")),style:X(X({},O?ce:be,R),O?be:ce,"auto"),onFocus:f,onBlur:h},Se);return i&&(he=C.createElement("div",{onMouseDown:m,ref:$,className:me("".concat(k,"-range-wrapper"),"".concat(k,"-").concat(r,"-range-wrapper"))},C.createElement("div",{ref:A,className:"".concat(k,"-range-arrow"),style:{left:j}}),C.createElement(ea,{onResize:F},he))),he}function hR(e,t){var n=e.format,r=e.maskFormat,o=e.generateConfig,i=e.locale,a=e.preserveInvalidOnBlur,s=e.inputReadOnly,l=e.required,c=e["aria-required"],u=e.onSubmit,d=e.onFocus,f=e.onBlur,h=e.onInputChange,m=e.onInvalid,p=e.open,g=e.onOpenChange,v=e.onKeyDown,y=e.onChange,b=e.activeHelp,w=e.name,x=e.autoComplete,E=e.id,k=e.value,S=e.invalid,O=e.placeholder,A=e.disabled,$=e.activeIndex,M=e.allHelp,N=e.picker,D=function(L,j){var _=o.locale.parse(i.locale,L,[j]);return _&&o.isValidate(_)?_:null},T=n[0],P=C.useCallback(function(L){return _r(L,{locale:i,format:T,generateConfig:o})},[i,o,T]),I=C.useMemo(function(){return k.map(P)},[k,P]),R=C.useMemo(function(){var L=N==="time"?8:10,j=typeof T=="function"?T(o.getNow()).length:T.length;return Math.max(L,j)+2},[T,N,o]),H=function(L){for(var j=0;j<n.length;j+=1){var _=n[j];if(typeof _=="string"){var F=D(L,_);if(F)return F}}return!1},V=function(L){function j(B){return L!==void 0?B[L]:B}var _=Si(e,{aria:!0,data:!0}),F=Q(Q({},_),{},{format:r,validateFormat:function(B){return!!H(B)},preserveInvalidOnBlur:a,readOnly:s,required:l,"aria-required":c,name:w,autoComplete:x,size:R,id:j(E),value:j(I)||"",invalid:j(S),placeholder:j(O),active:$===L,helped:M||b&&$===L,disabled:j(A),onFocus:function(B){d(B,L)},onBlur:function(B){f(B,L)},onSubmit:u,onChange:function(B){h();var z=H(B);if(z){m(!1,L),y(z,L);return}m(!!B,L)},onHelp:function(){g(!0,{index:L})},onKeyDown:function(B){var z=!1;if(v==null||v(B,function(){z=!0}),!B.defaultPrevented&&!z)switch(B.key){case"Escape":g(!1,{index:L});break;case"Enter":p||g(!0);break}}},t==null?void 0:t({valueTexts:I}));return Object.keys(F).forEach(function(B){F[B]===void 0&&delete F[B]}),F};return[V,P]}var s7=["onMouseEnter","onMouseLeave"];function pR(e){return C.useMemo(function(){return Fp(e,s7)},[e])}var l7=["icon","type"],c7=["onClear"];function Rp(e){var t=e.icon,n=e.type,r=tn(e,l7),o=C.useContext(Mi),i=o.prefixCls;return t?C.createElement("span",Qe({className:"".concat(i,"-").concat(n)},r),t):null}function Q2(e){var t=e.onClear,n=tn(e,c7);return C.createElement(Rp,Qe({},n,{type:"clear",role:"button",onMouseDown:function(r){r.preventDefault()},onClick:function(r){r.stopPropagation(),t()}}))}var km=["YYYY","MM","DD","HH","mm","ss","SSS"],rA="\u9867",u7=(function(){function e(t){xr(this,e),X(this,"format",void 0),X(this,"maskFormat",void 0),X(this,"cells",void 0),X(this,"maskCells",void 0),this.format=t;var n=km.map(function(s){return"(".concat(s,")")}).join("|"),r=new RegExp(n,"g");this.maskFormat=t.replace(r,function(s){return rA.repeat(s.length)});var o=new RegExp("(".concat(km.join("|"),")")),i=(t.split(o)||[]).filter(function(s){return s}),a=0;this.cells=i.map(function(s){var l=km.includes(s),c=a,u=a+s.length;return a=u,{text:s,mask:l,start:c,end:u}}),this.maskCells=this.cells.filter(function(s){return s.mask})}return Er(e,[{key:"getSelection",value:function(t){var n=this.maskCells[t]||{},r=n.start,o=n.end;return[r||0,o||0]}},{key:"match",value:function(t){for(var n=0;n<this.maskFormat.length;n+=1){var r=this.maskFormat[n],o=t[n];if(!o||r!==rA&&r!==o)return!1}return!0}},{key:"size",value:function(){return this.maskCells.length}},{key:"getMaskCellIndex",value:function(t){for(var n=Number.MAX_SAFE_INTEGER,r=0,o=0;o<this.maskCells.length;o+=1){var i=this.maskCells[o],a=i.start,s=i.end;if(t>=a&&t<=s)return o;var l=Math.min(Math.abs(t-a),Math.abs(t-s));l<n&&(n=l,r=o)}return r}}]),e})();function d7(e){var t={YYYY:[0,9999,new Date().getFullYear()],MM:[1,12],DD:[1,31],HH:[0,23],mm:[0,59],ss:[0,59],SSS:[0,999]};return t[e]}var f7=["active","showActiveCls","suffixIcon","format","validateFormat","onChange","onInput","helped","onHelp","onSubmit","onKeyDown","preserveInvalidOnBlur","invalid","clearIcon"],J2=C.forwardRef(function(e,t){var n=e.active,r=e.showActiveCls,o=r===void 0?!0:r,i=e.suffixIcon,a=e.format,s=e.validateFormat,l=e.onChange,c=e.helped,u=e.onHelp,d=e.onSubmit,f=e.onKeyDown,h=e.preserveInvalidOnBlur,m=h===void 0?!1:h,p=e.invalid,g=e.clearIcon,v=tn(e,f7),y=e.value,b=e.onFocus,w=e.onBlur,x=e.onMouseUp,E=C.useContext(Mi),k=E.prefixCls,S=E.input,O=S===void 0?"input":S,A="".concat(k,"-input"),$=C.useState(!1),M=te($,2),N=M[0],D=M[1],T=C.useState(y),P=te(T,2),I=P[0],R=P[1],H=C.useState(""),V=te(H,2),L=V[0],j=V[1],_=C.useState(null),F=te(_,2),B=F[0],z=F[1],G=C.useState(null),W=te(G,2),q=W[0],U=W[1],Y=I||"";C.useEffect(function(){R(y)},[y]);var ie=C.useRef(),K=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:ie.current,inputElement:K.current,focus:function(fe){K.current.focus(fe)},blur:function(){K.current.blur()}}});var re=C.useMemo(function(){return new u7(a||"")},[a]),oe=C.useMemo(function(){return c?[0,0]:re.getSelection(B)},[re,B,c]),ne=te(oe,2),ae=ne[0],de=ne[1],ge=function(fe){fe&&fe!==a&&fe!==y&&u()},Se=cn(function(fe){s(fe)&&l(fe),R(fe),ge(fe)}),ye=function(fe){if(!a){var pe=fe.target.value;ge(pe),R(pe),l(pe)}},be=function(fe){var pe=fe.clipboardData.getData("text");s(pe)&&Se(pe)},ce=C.useRef(!1),he=function(){ce.current=!0},Te=function(fe){var pe=fe.target,ke=pe.selectionStart,Ve=re.getMaskCellIndex(ke);z(Ve),U({}),x==null||x(fe),ce.current=!1},se=function(fe){D(!0),z(0),j(""),b(fe)},Pe=function(fe){w(fe)},De=function(fe){D(!1),Pe(fe)};ck(n,function(){!n&&!m&&R(y)});var He=function(fe){fe.key==="Enter"&&s(Y)&&d(),f==null||f(fe)},ue=function(fe){He(fe);var pe=fe.key,ke=null,Ve=null,Ee=de-ae,yt=a.slice(ae,de),Dt=function(Ge){z(function(Xe){var qe=Xe+Ge;return qe=Math.max(qe,0),qe=Math.min(qe,re.size()-1),qe})},Pt=function(Ge){var Xe=d7(yt),qe=te(Xe,3),lt=qe[0],je=qe[1],Rt=qe[2],zt=Y.slice(ae,de),dt=Number(zt);if(isNaN(dt))return String(Rt||(Ge>0?lt:je));var Ct=dt+Ge,jt=je-lt+1;return String(lt+(jt+Ct-lt)%jt)};switch(pe){case"Backspace":case"Delete":ke="",Ve=yt;break;case"ArrowLeft":ke="",Dt(-1);break;case"ArrowRight":ke="",Dt(1);break;case"ArrowUp":ke="",Ve=Pt(1);break;case"ArrowDown":ke="",Ve=Pt(-1);break;default:isNaN(Number(pe))||(ke=L+pe,Ve=ke);break}if(ke!==null&&(j(ke),ke.length>=Ee&&(Dt(1),j(""))),Ve!==null){var Ut=Y.slice(0,ae)+ik(Ve,Ee)+Y.slice(de);Se(Ut.slice(0,a.length))}U({})},ve=C.useRef();mn(function(){if(!(!N||!a||ce.current)){if(!re.match(Y)){Se(a);return}return K.current.setSelectionRange(ae,de),ve.current=en(function(){K.current.setSelectionRange(ae,de)}),function(){en.cancel(ve.current)}}},[re,a,N,Y,B,ae,de,q,Se]);var xe=a?{onFocus:se,onBlur:De,onKeyDown:ue,onMouseDown:he,onMouseUp:Te,onPaste:be}:{};return C.createElement("div",{ref:ie,className:me(A,X(X({},"".concat(A,"-active"),n&&o),"".concat(A,"-placeholder"),c))},C.createElement(O,Qe({ref:K,"aria-invalid":p,autoComplete:"off"},v,{onKeyDown:He,onBlur:Pe},xe,{value:Y,onChange:ye})),C.createElement(Rp,{type:"suffix",icon:i}),g)}),h7=["id","prefix","clearIcon","suffixIcon","separator","activeIndex","activeHelp","allHelp","focused","onFocus","onBlur","onKeyDown","locale","generateConfig","placeholder","className","style","onClick","onClear","value","onChange","onSubmit","onInputChange","format","maskFormat","preserveInvalidOnBlur","onInvalid","disabled","invalid","inputReadOnly","direction","onOpenChange","onActiveInfo","placement","onMouseDown","required","aria-required","autoFocus","tabIndex"],p7=["index"];function g7(e,t){var n=e.id,r=e.prefix,o=e.clearIcon,i=e.suffixIcon,a=e.separator,s=a===void 0?"~":a,l=e.activeIndex,c=e.focused,u=e.placeholder,d=e.className,f=e.style,h=e.onClick,m=e.onClear,p=e.value,g=e.disabled,v=e.invalid,y=e.direction,b=e.onActiveInfo,w=e.onMouseDown,x=e.autoFocus,E=e.tabIndex,k=tn(e,h7),S=y==="rtl",O=C.useContext(Mi),A=O.prefixCls,$=C.useMemo(function(){if(typeof n=="string")return[n];var q=n||{};return[q.start,q.end]},[n]),M=C.useRef(),N=C.useRef(),D=C.useRef(),T=function(q){var U;return(U=[N,D][q])===null||U===void 0?void 0:U.current};C.useImperativeHandle(t,function(){return{nativeElement:M.current,focus:function(q){if(At(q)==="object"){var U,Y=q||{},ie=Y.index,K=ie===void 0?0:ie,re=tn(Y,p7);(U=T(K))===null||U===void 0||U.focus(re)}else{var oe;(oe=T(q??0))===null||oe===void 0||oe.focus()}},blur:function(){var q,U;(q=T(0))===null||q===void 0||q.blur(),(U=T(1))===null||U===void 0||U.blur()}}});var P=pR(k),I=C.useMemo(function(){return Array.isArray(u)?u:[u,u]},[u]),R=hR(Q(Q({},e),{},{id:$,placeholder:I})),H=te(R,1),V=H[0],L=C.useState({position:"absolute",width:0}),j=te(L,2),_=j[0],F=j[1],B=cn(function(){var q=T(l);if(q){var U=q.nativeElement.getBoundingClientRect(),Y=M.current.getBoundingClientRect(),ie=U.left-Y.left;F(function(K){return Q(Q({},K),{},{width:U.width,left:ie})}),b([U.left,U.right,Y.width])}});C.useEffect(function(){B()},[l]);var z=o&&(p[0]&&!g[0]||p[1]&&!g[1]),G=x&&!g[0],W=x&&!G&&!g[1];return C.createElement(ea,{onResize:B},C.createElement("div",Qe({},P,{className:me(A,"".concat(A,"-range"),X(X(X(X({},"".concat(A,"-focused"),c),"".concat(A,"-disabled"),g.every(function(q){return q})),"".concat(A,"-invalid"),v.some(function(q){return q})),"".concat(A,"-rtl"),S),d),style:f,ref:M,onClick:h,onMouseDown:function(q){var U=q.target;U!==N.current.inputElement&&U!==D.current.inputElement&&q.preventDefault(),w==null||w(q)}}),r&&C.createElement("div",{className:"".concat(A,"-prefix")},r),C.createElement(J2,Qe({ref:N},V(0),{autoFocus:G,tabIndex:E,"date-range":"start"})),C.createElement("div",{className:"".concat(A,"-range-separator")},s),C.createElement(J2,Qe({ref:D},V(1),{autoFocus:W,tabIndex:E,"date-range":"end"})),C.createElement("div",{className:"".concat(A,"-active-bar"),style:_}),C.createElement(Rp,{type:"suffix",icon:i}),z&&C.createElement(Q2,{icon:o,onClear:m})))}var m7=C.forwardRef(g7);function oA(e,t){var n=e??t;return Array.isArray(n)?n:[n,n]}function uf(e){return e===1?"end":"start"}function v7(e,t){var n=QB(e,function(){var ft=e.disabled,Ft=e.allowEmpty,Bn=oA(ft,!1),zn=oA(Ft,!1);return{disabled:Bn,allowEmpty:zn}}),r=te(n,6),o=r[0],i=r[1],a=r[2],s=r[3],l=r[4],c=r[5],u=o.prefixCls,d=o.styles,f=o.classNames,h=o.defaultValue,m=o.value,p=o.needConfirm,g=o.onKeyDown,v=o.disabled,y=o.allowEmpty,b=o.disabledDate,w=o.minDate,x=o.maxDate,E=o.defaultOpen,k=o.open,S=o.onOpenChange,O=o.locale,A=o.generateConfig,$=o.picker,M=o.showNow,N=o.showToday,D=o.showTime,T=o.mode,P=o.onPanelChange,I=o.onCalendarChange,R=o.onOk,H=o.defaultPickerValue,V=o.pickerValue,L=o.onPickerValueChange,j=o.inputReadOnly,_=o.suffixIcon,F=o.onFocus,B=o.onBlur,z=o.presets,G=o.ranges,W=o.components,q=o.cellRender,U=o.dateRender,Y=o.monthCellRender,ie=o.onClick,K=eR(t),re=JB(k,E,v,S),oe=te(re,2),ne=oe[0],ae=oe[1],de=function(ft,Ft){(v.some(function(Bn){return!Bn})||!ft)&&ae(ft,Ft)},ge=sR(A,O,s,!0,!1,h,m,I,R),Se=te(ge,5),ye=Se[0],be=Se[1],ce=Se[2],he=Se[3],Te=Se[4],se=ce(),Pe=nR(v,y,ne),De=te(Pe,9),He=De[0],ue=De[1],ve=De[2],xe=De[3],fe=De[4],pe=De[5],ke=De[6],Ve=De[7],Ee=De[8],yt=function(ft,Ft){ue(!0),F==null||F(ft,{range:uf(Ft??xe)})},Dt=function(ft,Ft){ue(!1),B==null||B(ft,{range:uf(Ft??xe)})},Pt=C.useMemo(function(){if(!D)return null;var ft=D.disabledTime,Ft=ft?function(Bn){var zn=uf(xe),gr=zB(se,ke,xe);return ft(Bn,zn,{from:gr})}:void 0;return Q(Q({},D),{},{disabledTime:Ft})},[D,xe,se,ke]),Ut=yr([$,$],{value:T}),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1],lt=Xe[xe]||$,je=lt==="date"&&Pt?"datetime":lt,Rt=je===$&&je!=="time",zt=cR($,lt,M,N,!0),dt=lR(o,ye,be,ce,he,v,s,He,ne,c),Ct=te(dt,2),jt=Ct[0],Ie=Ct[1],Ne=zJ(se,v,ke,A,O,b),Oe=WB(se,c,y),_e=te(Oe,2),mt=_e[0],kt=_e[1],It=rR(A,O,se,Xe,ne,xe,i,Rt,H,V,Pt==null?void 0:Pt.defaultOpenValue,L,w,x),Xt=te(It,2),on=Xt[0],qt=Xt[1],wn=cn(function(ft,Ft,Bn){var zn=Pu(Xe,xe,Ft);if((zn[0]!==Xe[0]||zn[1]!==Xe[1])&&qe(zn),P&&Bn!==!1){var gr=ze(se);ft&&(gr[xe]=ft),P(gr,zn)}}),vn=function(ft,Ft){return Pu(se,Ft,ft)},Kt=function(ft,Ft){var Bn=se;ft&&(Bn=vn(ft,xe)),Ve(xe);var zn=pe(Bn);he(Bn),jt(xe,zn===null),zn===null?de(!1,{force:!0}):Ft||K.current.focus({index:zn})},$n=function(ft){var Ft,Bn=ft.target.getRootNode();if(!K.current.nativeElement.contains((Ft=Bn.activeElement)!==null&&Ft!==void 0?Ft:document.activeElement)){var zn=v.findIndex(function(gr){return!gr});zn>=0&&K.current.focus({index:zn})}de(!0),ie==null||ie(ft)},On=function(){Ie(null),de(!1,{force:!0})},ur=C.useState(null),We=te(ur,2),pt=We[0],Ke=We[1],rt=C.useState(null),ht=te(rt,2),an=ht[0],dn=ht[1],Un=C.useMemo(function(){return an||se},[se,an]);C.useEffect(function(){ne||dn(null)},[ne]);var dr=C.useState([0,0,0]),Nn=te(dr,2),Dn=Nn[0],wr=Nn[1],ar=tR(z,G),J=function(ft){dn(ft),Ke("preset")},Z=function(ft){var Ft=Ie(ft);Ft&&de(!1,{force:!0})},$e=function(ft){Kt(ft)},Ae=function(ft){dn(ft?vn(ft,xe):null),Ke("cell")},tt=function(ft){de(!0),yt(ft)},vt=function(){ve("panel")},Ot=function(ft){var Ft=Pu(se,xe,ft);he(Ft),!p&&!a&&i===je&&Kt(ft)},wt=function(){de(!1)},ot=ak(q,U,Y,uf(xe)),Mt=se[xe]||null,Zt=cn(function(ft){return c(ft,{activeIndex:xe})}),Ue=C.useMemo(function(){var ft=Si(o,!1),Ft=ta(o,[].concat(ze(Object.keys(ft)),["onChange","onCalendarChange","style","className","onPanelChange","disabledTime"]));return Ft},[o]),Ye=C.createElement(fR,Qe({},Ue,{showNow:zt,showTime:Pt,range:!0,multiplePanel:Rt,activeInfo:Dn,disabledDate:Ne,onFocus:tt,onBlur:Dt,onPanelMouseDown:vt,picker:$,mode:lt,internalMode:je,onPanelChange:wn,format:l,value:Mt,isInvalid:Zt,onChange:null,onSelect:Ot,pickerValue:on,defaultOpenValue:ml(D==null?void 0:D.defaultOpenValue)[xe],onPickerValueChange:qt,hoverValue:Un,onHover:Ae,needConfirm:p,onSubmit:Kt,onOk:Te,presets:ar,onPresetHover:J,onPresetSubmit:Z,onNow:$e,cellRender:ot})),ct=function(ft,Ft){var Bn=vn(ft,Ft);he(Bn)},Tt=function(){ve("input")},Cn=function(ft,Ft){var Bn=ke.length,zn=ke[Bn-1];if(Bn&&zn!==Ft&&p&&!y[zn]&&!Ee(zn)&&se[zn]){K.current.focus({index:zn});return}ve("input"),de(!0,{inherit:!0}),xe!==Ft&&ne&&!p&&a&&Kt(null,!0),fe(Ft),yt(ft,Ft)},bt=function(ft,Ft){if(de(!1),!p&&ve()==="input"){var Bn=pe(se);jt(xe,Bn===null)}Dt(ft,Ft)},Wt=function(ft,Ft){ft.key==="Tab"&&Kt(null,!0),g==null||g(ft,Ft)},Fn=C.useMemo(function(){return{prefixCls:u,locale:O,generateConfig:A,button:W.button,input:W.input}},[u,O,A,W.button,W.input]);return mn(function(){ne&&xe!==void 0&&wn(null,$,!1)},[ne,xe,$]),mn(function(){var ft=ve();!ne&&ft==="input"&&(de(!1),Kt(null,!0)),!ne&&a&&!p&&ft==="panel"&&(de(!0),Kt())},[ne]),C.createElement(Mi.Provider,{value:Fn},C.createElement(jB,Qe({},HB(o),{popupElement:Ye,popupStyle:d.popup,popupClassName:f.popup,visible:ne,onClose:wt,range:!0}),C.createElement(m7,Qe({},o,{ref:K,suffixIcon:_,activeIndex:He||ne?xe:null,activeHelp:!!an,allHelp:!!an&&pt==="preset",focused:He,onFocus:Cn,onBlur:bt,onKeyDown:Wt,onSubmit:Kt,value:Un,maskFormat:l,onChange:ct,onInputChange:Tt,format:s,inputReadOnly:j,disabled:v,open:ne,onOpenChange:de,onClick:$n,onClear:On,invalid:mt,onInvalid:kt,onActiveInfo:wr}))))}var y7=C.forwardRef(v7);function b7(e){var t=e.prefixCls,n=e.value,r=e.onRemove,o=e.removeIcon,i=o===void 0?"\xD7":o,a=e.formatDate,s=e.disabled,l=e.maxTagCount,c=e.placeholder,u="".concat(t,"-selector"),d="".concat(t,"-selection"),f="".concat(d,"-overflow");function h(g,v){return C.createElement("span",{className:me("".concat(d,"-item")),title:typeof g=="string"?g:null},C.createElement("span",{className:"".concat(d,"-item-content")},g),!s&&v&&C.createElement("span",{onMouseDown:function(y){y.preventDefault()},onClick:v,className:"".concat(d,"-item-remove")},i))}function m(g){var v=a(g),y=function(b){b&&b.stopPropagation(),r(g)};return h(v,y)}function p(g){var v="+ ".concat(g.length," ...");return h(v)}return C.createElement("div",{className:u},C.createElement(Fc,{prefixCls:f,data:n,renderItem:m,renderRest:p,itemKey:function(g){return a(g)},maxCount:l}),!n.length&&C.createElement("span",{className:"".concat(t,"-selection-placeholder")},c))}var x7=["id","open","prefix","clearIcon","suffixIcon","activeHelp","allHelp","focused","onFocus","onBlur","onKeyDown","locale","generateConfig","placeholder","className","style","onClick","onClear","internalPicker","value","onChange","onSubmit","onInputChange","multiple","maxTagCount","format","maskFormat","preserveInvalidOnBlur","onInvalid","disabled","invalid","inputReadOnly","direction","onOpenChange","onMouseDown","required","aria-required","autoFocus","tabIndex","removeIcon"];function E7(e,t){var n=e.open,r=e.prefix,o=e.clearIcon,i=e.suffixIcon,a=e.focused,s=e.locale,l=e.generateConfig,c=e.placeholder,u=e.className,d=e.style,f=e.onClick,h=e.onClear,m=e.internalPicker,p=e.value,g=e.onChange,v=e.onSubmit,y=e.multiple,b=e.maxTagCount,w=e.disabled,x=e.invalid,E=e.direction,k=e.onMouseDown,S=e.autoFocus,O=e.tabIndex,A=e.removeIcon,$=tn(e,x7),M=E==="rtl",N=C.useContext(Mi),D=N.prefixCls,T=C.useRef(),P=C.useRef();C.useImperativeHandle(t,function(){return{nativeElement:T.current,focus:function(z){var G;(G=P.current)===null||G===void 0||G.focus(z)},blur:function(){var z;(z=P.current)===null||z===void 0||z.blur()}}});var I=pR($),R=function(z){g([z])},H=function(z){var G=p.filter(function(W){return W&&!lo(l,s,W,z,m)});g(G),n||v()},V=hR(Q(Q({},e),{},{onChange:R}),function(z){var G=z.valueTexts;return{value:G[0]||"",active:a}}),L=te(V,2),j=L[0],_=L[1],F=!!(o&&p.length&&!w),B=y?C.createElement(C.Fragment,null,C.createElement(b7,{prefixCls:D,value:p,onRemove:H,formatDate:_,maxTagCount:b,disabled:w,removeIcon:A,placeholder:c}),C.createElement("input",{className:"".concat(D,"-multiple-input"),value:p.map(_).join(","),ref:P,readOnly:!0,autoFocus:S,tabIndex:O}),C.createElement(Rp,{type:"suffix",icon:i}),F&&C.createElement(Q2,{icon:o,onClear:h})):C.createElement(J2,Qe({ref:P},j(),{autoFocus:S,tabIndex:O,suffixIcon:i,clearIcon:F&&C.createElement(Q2,{icon:o,onClear:h}),showActiveCls:!1}));return C.createElement("div",Qe({},I,{className:me(D,X(X(X(X(X({},"".concat(D,"-multiple"),y),"".concat(D,"-focused"),a),"".concat(D,"-disabled"),w),"".concat(D,"-invalid"),x),"".concat(D,"-rtl"),M),u),style:d,ref:T,onClick:f,onMouseDown:function(z){var G,W=z.target;W!==((G=P.current)===null||G===void 0?void 0:G.inputElement)&&z.preventDefault(),k==null||k(z)}}),r&&C.createElement("div",{className:"".concat(D,"-prefix")},r),B)}var w7=C.forwardRef(E7);function C7(e,t){var n=QB(e),r=te(n,6),o=r[0],i=r[1],a=r[2],s=r[3],l=r[4],c=r[5],u=o,d=u.prefixCls,f=u.styles,h=u.classNames,m=u.order,p=u.defaultValue,g=u.value,v=u.needConfirm,y=u.onChange,b=u.onKeyDown,w=u.disabled,x=u.disabledDate,E=u.minDate,k=u.maxDate,S=u.defaultOpen,O=u.open,A=u.onOpenChange,$=u.locale,M=u.generateConfig,N=u.picker,D=u.showNow,T=u.showToday,P=u.showTime,I=u.mode,R=u.onPanelChange,H=u.onCalendarChange,V=u.onOk,L=u.multiple,j=u.defaultPickerValue,_=u.pickerValue,F=u.onPickerValueChange,B=u.inputReadOnly,z=u.suffixIcon,G=u.removeIcon,W=u.onFocus,q=u.onBlur,U=u.presets,Y=u.components,ie=u.cellRender,K=u.dateRender,re=u.monthCellRender,oe=u.onClick,ne=eR(t);function ae(Ue){return Ue===null?null:L?Ue:Ue[0]}var de=uR(M,$,i),ge=JB(O,S,[w],A),Se=te(ge,2),ye=Se[0],be=Se[1],ce=function(Ue,Ye,ct){if(H){var Tt=Q({},ct);delete Tt.range,H(ae(Ue),ae(Ye),Tt)}},he=function(Ue){V==null||V(ae(Ue))},Te=sR(M,$,s,!1,m,p,g,ce,he),se=te(Te,5),Pe=se[0],De=se[1],He=se[2],ue=se[3],ve=se[4],xe=He(),fe=nR([w]),pe=te(fe,4),ke=pe[0],Ve=pe[1],Ee=pe[2],yt=pe[3],Dt=function(Ue){Ve(!0),W==null||W(Ue,{})},Pt=function(Ue){Ve(!1),q==null||q(Ue,{})},Ut=yr(N,{value:I}),Ge=te(Ut,2),Xe=Ge[0],qe=Ge[1],lt=Xe==="date"&&P?"datetime":Xe,je=cR(N,Xe,D,T),Rt=y&&function(Ue,Ye){y(ae(Ue),ae(Ye))},zt=lR(Q(Q({},o),{},{onChange:Rt}),Pe,De,He,ue,[],s,ke,ye,c),dt=te(zt,2),Ct=dt[1],jt=WB(xe,c),Ie=te(jt,2),Ne=Ie[0],Oe=Ie[1],_e=C.useMemo(function(){return Ne.some(function(Ue){return Ue})},[Ne]),mt=function(Ue,Ye){if(F){var ct=Q(Q({},Ye),{},{mode:Ye.mode[0]});delete ct.range,F(Ue[0],ct)}},kt=rR(M,$,xe,[Xe],ye,yt,i,!1,j,_,ml(P==null?void 0:P.defaultOpenValue),mt,E,k),It=te(kt,2),Xt=It[0],on=It[1],qt=cn(function(Ue,Ye,ct){if(qe(Ye),R&&ct!==!1){var Tt=Ue||xe[xe.length-1];R(Tt,Ye)}}),wn=function(){Ct(He()),be(!1,{force:!0})},vn=function(Ue){!w&&!ne.current.nativeElement.contains(document.activeElement)&&ne.current.focus(),be(!0),oe==null||oe(Ue)},Kt=function(){Ct(null),be(!1,{force:!0})},$n=C.useState(null),On=te($n,2),ur=On[0],We=On[1],pt=C.useState(null),Ke=te(pt,2),rt=Ke[0],ht=Ke[1],an=C.useMemo(function(){var Ue=[rt].concat(ze(xe)).filter(function(Ye){return Ye});return L?Ue:Ue.slice(0,1)},[xe,rt,L]),dn=C.useMemo(function(){return!L&&rt?[rt]:xe.filter(function(Ue){return Ue})},[xe,rt,L]);C.useEffect(function(){ye||ht(null)},[ye]);var Un=tR(U),dr=function(Ue){ht(Ue),We("preset")},Nn=function(Ue){var Ye=L?de(He(),Ue):[Ue],ct=Ct(Ye);ct&&!L&&be(!1,{force:!0})},Dn=function(Ue){Nn(Ue)},wr=function(Ue){ht(Ue),We("cell")},ar=function(Ue){be(!0),Dt(Ue)},J=function(Ue){if(Ee("panel"),!(L&<!==N)){var Ye=L?de(He(),Ue):[Ue];ue(Ye),!v&&!a&&i===lt&&wn()}},Z=function(){be(!1)},$e=ak(ie,K,re),Ae=C.useMemo(function(){var Ue=Si(o,!1),Ye=ta(o,[].concat(ze(Object.keys(Ue)),["onChange","onCalendarChange","style","className","onPanelChange"]));return Q(Q({},Ye),{},{multiple:o.multiple})},[o]),tt=C.createElement(fR,Qe({},Ae,{showNow:je,showTime:P,disabledDate:x,onFocus:ar,onBlur:Pt,picker:N,mode:Xe,internalMode:lt,onPanelChange:qt,format:l,value:xe,isInvalid:c,onChange:null,onSelect:J,pickerValue:Xt,defaultOpenValue:P==null?void 0:P.defaultOpenValue,onPickerValueChange:on,hoverValue:an,onHover:wr,needConfirm:v,onSubmit:wn,onOk:ve,presets:Un,onPresetHover:dr,onPresetSubmit:Nn,onNow:Dn,cellRender:$e})),vt=function(Ue){ue(Ue)},Ot=function(){Ee("input")},wt=function(Ue){Ee("input"),be(!0,{inherit:!0}),Dt(Ue)},ot=function(Ue){be(!1),Pt(Ue)},Mt=function(Ue,Ye){Ue.key==="Tab"&&wn(),b==null||b(Ue,Ye)},Zt=C.useMemo(function(){return{prefixCls:d,locale:$,generateConfig:M,button:Y.button,input:Y.input}},[d,$,M,Y.button,Y.input]);return mn(function(){ye&&yt!==void 0&&qt(null,N,!1)},[ye,yt,N]),mn(function(){var Ue=Ee();!ye&&Ue==="input"&&(be(!1),wn()),!ye&&a&&!v&&Ue==="panel"&&wn()},[ye]),C.createElement(Mi.Provider,{value:Zt},C.createElement(jB,Qe({},HB(o),{popupElement:tt,popupStyle:f.popup,popupClassName:h.popup,visible:ye,onClose:Z}),C.createElement(w7,Qe({},o,{ref:ne,suffixIcon:z,removeIcon:G,activeHelp:!!rt,allHelp:!!rt&&ur==="preset",focused:ke,onFocus:wt,onBlur:ot,onKeyDown:Mt,onSubmit:wn,value:dn,maskFormat:l,onChange:vt,onInputChange:Ot,internalPicker:i,format:s,inputReadOnly:B,disabled:w,open:ye,onOpenChange:be,onClick:vn,onClear:Kt,invalid:_e,onInvalid:function(Ue){Oe(Ue,0)}}))))}var k7=C.forwardRef(C7);const gR=C.createContext(null),S7=gR.Provider,mR=C.createContext(null),A7=mR.Provider;var $7=["prefixCls","className","style","checked","disabled","defaultChecked","type","title","onChange"],O7=Oi(function(e,t){var n=e.prefixCls,r=n===void 0?"rc-checkbox":n,o=e.className,i=e.style,a=e.checked,s=e.disabled,l=e.defaultChecked,c=l===void 0?!1:l,u=e.type,d=u===void 0?"checkbox":u,f=e.title,h=e.onChange,m=tn(e,$7),p=et(null),g=et(null),v=yr(c,{value:a}),y=te(v,2),b=y[0],w=y[1];Oc(t,function(){return{focus:function(k){var S;(S=p.current)===null||S===void 0||S.focus(k)},blur:function(){var k;(k=p.current)===null||k===void 0||k.blur()},input:p.current,nativeElement:g.current}});var x=me(r,o,X(X({},"".concat(r,"-checked"),b),"".concat(r,"-disabled"),s)),E=function(k){s||("checked"in e||w(k.target.checked),h==null||h({target:Q(Q({},e),{},{type:d,checked:k.target.checked}),stopPropagation:function(){k.stopPropagation()},preventDefault:function(){k.preventDefault()},nativeEvent:k.nativeEvent}))};return C.createElement("span",{className:x,title:f,style:i,ref:g},C.createElement("input",Qe({},m,{className:"".concat(r,"-input"),ref:p,onChange:E,disabled:s,checked:!!b,type:d})),C.createElement("span",{className:"".concat(r,"-inner")}))});function M7(e){const t=we.useRef(null),n=()=>{en.cancel(t.current),t.current=null};return[()=>{n(),t.current=en(()=>{t.current=null})},r=>{t.current&&(r.stopPropagation(),n()),e==null||e(r)}]}const N7=e=>{const{componentCls:t,antCls:n}=e,r=`${t}-group`;return{[r]:Object.assign(Object.assign({},br(e)),{display:"inline-block",fontSize:0,[`&${r}-rtl`]:{direction:"rtl"},[`&${r}-block`]:{display:"flex"},[`${n}-badge ${n}-badge-count`]:{zIndex:1},[`> ${n}-badge:not(:first-child) > ${n}-button-wrapper`]:{borderInlineStart:"none"}})}},D7=e=>{const{componentCls:t,wrapperMarginInlineEnd:n,colorPrimary:r,radioSize:o,motionDurationSlow:i,motionDurationMid:a,motionEaseInOutCirc:s,colorBgContainer:l,colorBorder:c,lineWidth:u,colorBgContainerDisabled:d,colorTextDisabled:f,paddingXS:h,dotColorDisabled:m,lineType:p,radioColor:g,radioBgColor:v,calc:y}=e,b=`${t}-inner`,w=y(o).sub(y(4).mul(2)),x=y(1).mul(o).equal({unit:!0});return{[`${t}-wrapper`]:Object.assign(Object.assign({},br(e)),{display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:n,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}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${Ce(u)} ${p} ${r}`,borderRadius:"50%",visibility:"hidden",opacity:0,content:'""'},[t]:Object.assign(Object.assign({},br(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center",borderRadius:"50%"}),[`${t}-wrapper:hover &,
|
|
314
314
|
&:hover ${b}`]:{borderColor:r},[`${t}-input:focus-visible + ${b}`]:FC(e),[`${t}:hover::after, ${t}-wrapper:hover &::after`]:{visibility:"visible"},[`${t}-inner`]:{"&::after":{boxSizing:"border-box",position:"absolute",insetBlockStart:"50%",insetInlineStart:"50%",display:"block",width:x,height:x,marginBlockStart:y(1).mul(o).div(-2).equal({unit:!0}),marginInlineStart:y(1).mul(o).div(-2).equal({unit:!0}),backgroundColor:g,borderBlockStart:0,borderInlineStart:0,borderRadius:x,transform:"scale(0)",opacity:0,transition:`all ${i} ${s}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:x,height:x,backgroundColor:l,borderColor:c,borderStyle:"solid",borderWidth:u,borderRadius:"50%",transition:`all ${a}`},[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0},[`${t}-checked`]:{[b]:{borderColor:r,backgroundColor:v,"&::after":{transform:`scale(${e.calc(e.dotSize).div(o).equal()})`,opacity:1,transition:`all ${i} ${s}`}}},[`${t}-disabled`]:{cursor:"not-allowed",[b]:{backgroundColor:d,borderColor:c,cursor:"not-allowed","&::after":{backgroundColor:m}},[`${t}-input`]:{cursor:"not-allowed"},[`${t}-disabled + span`]:{color:f,cursor:"not-allowed"},[`&${t}-checked`]:{[b]:{"&::after":{transform:`scale(${y(w).div(o).equal()})`}}}},[`span${t} + *`]:{paddingInlineStart:h,paddingInlineEnd:h}})}},T7=e=>{const{buttonColor:t,controlHeight:n,componentCls:r,lineWidth:o,lineType:i,colorBorder:a,motionDurationMid:s,buttonPaddingInline:l,fontSize:c,buttonBg:u,fontSizeLG:d,controlHeightLG:f,controlHeightSM:h,paddingXS:m,borderRadius:p,borderRadiusSM:g,borderRadiusLG:v,buttonCheckedBg:y,buttonSolidCheckedColor:b,colorTextDisabled:w,colorBgContainerDisabled:x,buttonCheckedBgDisabled:E,buttonCheckedColorDisabled:k,colorPrimary:S,colorPrimaryHover:O,colorPrimaryActive:A,buttonSolidCheckedBg:$,buttonSolidCheckedHoverBg:M,buttonSolidCheckedActiveBg:N,calc:D}=e;return{[`${r}-button-wrapper`]:{position:"relative",display:"inline-block",height:n,margin:0,paddingInline:l,paddingBlock:0,color:t,fontSize:c,lineHeight:Ce(D(n).sub(D(o).mul(2)).equal()),background:u,border:`${Ce(o)} ${i} ${a}`,borderBlockStartWidth:D(o).add(.02).equal(),borderInlineEndWidth:o,cursor:"pointer",transition:[`color ${s}`,`background ${s}`,`box-shadow ${s}`].join(","),a:{color:t},[`> ${r}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:last-child)":{marginInlineEnd:D(o).mul(-1).equal()},"&:first-child":{borderInlineStart:`${Ce(o)} ${i} ${a}`,borderStartStartRadius:p,borderEndStartRadius:p},"&:last-child":{borderStartEndRadius:p,borderEndEndRadius:p},"&:first-child:last-child":{borderRadius:p},[`${r}-group-large &`]:{height:f,fontSize:d,lineHeight:Ce(D(f).sub(D(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:v,borderEndStartRadius:v},"&:last-child":{borderStartEndRadius:v,borderEndEndRadius:v}},[`${r}-group-small &`]:{height:h,paddingInline:D(m).sub(o).equal(),paddingBlock:0,lineHeight:Ce(D(h).sub(D(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:g,borderEndStartRadius:g},"&:last-child":{borderStartEndRadius:g,borderEndEndRadius:g}},"&:hover":{position:"relative",color:S},"&:has(:focus-visible)":FC(e),[`${r}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${r}-button-wrapper-disabled)`]:{zIndex:1,color:S,background:y,borderColor:S,"&::before":{backgroundColor:S},"&:first-child":{borderColor:S},"&:hover":{color:O,borderColor:O,"&::before":{backgroundColor:O}},"&:active":{color:A,borderColor:A,"&::before":{backgroundColor:A}}},[`${r}-group-solid &-checked:not(${r}-button-wrapper-disabled)`]:{color:b,background:$,borderColor:$,"&:hover":{color:b,background:M,borderColor:M},"&:active":{color:b,background:N,borderColor:N}},"&-disabled":{color:w,backgroundColor:x,borderColor:a,cursor:"not-allowed","&:first-child, &:hover":{color:w,backgroundColor:x,borderColor:a}},[`&-disabled${r}-button-wrapper-checked`]:{color:k,backgroundColor:E,borderColor:a,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},F7=e=>{const{wireframe:t,padding:n,marginXS:r,lineWidth:o,fontSizeLG:i,colorText:a,colorBgContainer:s,colorTextDisabled:l,controlItemBgActiveDisabled:c,colorTextLightSolid:u,colorPrimary:d,colorPrimaryHover:f,colorPrimaryActive:h,colorWhite:m}=e,p=4,g=i,v=t?g-p*2:g-(p+o)*2;return{radioSize:g,dotSize:v,dotColorDisabled:l,buttonSolidCheckedColor:u,buttonSolidCheckedBg:d,buttonSolidCheckedHoverBg:f,buttonSolidCheckedActiveBg:h,buttonBg:s,buttonCheckedBg:s,buttonColor:a,buttonCheckedBgDisabled:c,buttonCheckedColorDisabled:l,buttonPaddingInline:n-o,wrapperMarginInlineEnd:r,radioColor:t?d:m,radioBgColor:t?s:d}},vR=Pr("Radio",e=>{const{controlOutline:t,controlOutlineWidth:n}=e,r=`0 0 0 ${Ce(n)} ${t}`,o=Mn(e,{radioFocusShadow:r,radioButtonFocusShadow:r});return[N7(o),D7(o),T7(o)]},F7,{unitless:{radioSize:!0,dotSize:!0}});var P7=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const I7=(e,t)=>{var n,r;const o=C.useContext(gR),i=C.useContext(mR),{getPrefixCls:a,direction:s,radio:l}=C.useContext(pn),c=C.useRef(null),u=oi(t,c),{isFormItemInput:d}=C.useContext(Yr),f=P=>{var I,R;(I=e.onChange)===null||I===void 0||I.call(e,P),(R=o==null?void 0:o.onChange)===null||R===void 0||R.call(o,P)},{prefixCls:h,className:m,rootClassName:p,children:g,style:v,title:y}=e,b=P7(e,["prefixCls","className","rootClassName","children","style","title"]),w=a("radio",h),x=((o==null?void 0:o.optionType)||i)==="button",E=x?`${w}-button`:w,k=Ro(w),[S,O,A]=vR(w,k),$=Object.assign({},b),M=C.useContext(vo);o&&($.name=o.name,$.onChange=f,$.checked=e.value===o.value,$.disabled=(n=$.disabled)!==null&&n!==void 0?n:o.disabled),$.disabled=(r=$.disabled)!==null&&r!==void 0?r:M;const N=me(`${E}-wrapper`,{[`${E}-wrapper-checked`]:$.checked,[`${E}-wrapper-disabled`]:$.disabled,[`${E}-wrapper-rtl`]:s==="rtl",[`${E}-wrapper-in-form-item`]:d,[`${E}-wrapper-block`]:!!(o!=null&&o.block)},l==null?void 0:l.className,m,p,O,A,k),[D,T]=M7($.onClick);return S(C.createElement(Cp,{component:"Radio",disabled:$.disabled},C.createElement("label",{className:N,style:Object.assign(Object.assign({},l==null?void 0:l.style),v),onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:y,onClick:D},C.createElement(O7,Object.assign({},$,{className:me($.className,{[jC]:!x}),type:"radio",prefixCls:E,ref:u,onClick:T})),g!==void 0?C.createElement("span",{className:`${E}-label`},g):null)))},v0=C.forwardRef(I7),B7=["parentNode"],R7="form_item";function Iu(e){return e===void 0||e===!1?[]:Array.isArray(e)?e:[e]}function yR(e,t){if(!e.length)return;const n=e.join("_");return t?`${t}_${n}`:B7.includes(n)?`${R7}_${n}`:n}function bR(e,t,n,r,o,i){let a=r;return i!==void 0?a=i:n.validating?a="validating":e.length?a="error":t.length?a="warning":(n.touched||o&&n.validated)&&(a="success"),a}var _7=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function ew(e){return Iu(e).join("_")}function iA(e,t){const n=t.getFieldInstance(e),r=hP(n);if(r)return r;const o=yR(Iu(e),t.__INTERNAL__.name);if(o)return document.getElementById(o)}function xR(e){const[t]=KC(),n=C.useRef({}),r=C.useMemo(()=>e??Object.assign(Object.assign({},t),{__INTERNAL__:{itemRef:o=>i=>{const a=ew(o);i?n.current[a]=i:delete n.current[a]}},scrollToField:(o,i={})=>{const{focus:a}=i,s=_7(i,["focus"]),l=iA(o,r);l&&(CU(l,Object.assign({scrollMode:"if-needed",block:"nearest"},s)),a&&r.focusField(o))},focusField:o=>{var i,a;const s=r.getFieldInstance(o);typeof(s==null?void 0:s.focus)=="function"?s.focus():(a=(i=iA(o,r))===null||i===void 0?void 0:i.focus)===null||a===void 0||a.call(i)},getFieldInstance:o=>{const i=ew(o);return n.current[i]}}),[e,t]);return[r]}const j7=C.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=C.useContext(pn),{name:o}=C.useContext(Yr),i=qC(ew(o)),{prefixCls:a,className:s,rootClassName:l,options:c,buttonStyle:u="outline",disabled:d,children:f,size:h,style:m,id:p,optionType:g,name:v=i,defaultValue:y,value:b,block:w=!1,onChange:x,onMouseEnter:E,onMouseLeave:k,onFocus:S,onBlur:O}=e,[A,$]=yr(y,{value:b}),M=C.useCallback(_=>{const F=A,B=_.target.value;"value"in e||$(B),B!==F&&(x==null||x(_))},[A,$,x]),N=n("radio",a),D=`${N}-group`,T=Ro(N),[P,I,R]=vR(N,T);let H=f;c&&c.length>0&&(H=c.map(_=>typeof _=="string"||typeof _=="number"?C.createElement(v0,{key:_.toString(),prefixCls:N,disabled:d,value:_,checked:A===_},_):C.createElement(v0,{key:`radio-group-value-options-${_.value}`,prefixCls:N,disabled:_.disabled||d,value:_.value,checked:A===_.value,title:_.title,style:_.style,className:_.className,id:_.id,required:_.required},_.label)));const V=ai(h),L=me(D,`${D}-${u}`,{[`${D}-${V}`]:V,[`${D}-rtl`]:r==="rtl",[`${D}-block`]:w},s,l,I,R,T),j=C.useMemo(()=>({onChange:M,value:A,disabled:d,name:v,optionType:g,block:w}),[M,A,d,v,g,w]);return P(C.createElement("div",Object.assign({},Si(e,{aria:!0,data:!0}),{className:L,style:m,onMouseEnter:E,onMouseLeave:k,onFocus:S,onBlur:O,id:p,ref:t}),C.createElement(S7,{value:j},H)))}),L7=C.memo(j7);var z7=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const H7=(e,t)=>{const{getPrefixCls:n}=C.useContext(pn),{prefixCls:r}=e,o=z7(e,["prefixCls"]),i=n("radio",r);return C.createElement(A7,{value:"button"},C.createElement(v0,Object.assign({prefixCls:i},o,{type:"radio",ref:t})))},W7=C.forwardRef(H7),_p=v0;_p.Button=W7;_p.Group=L7;_p.__ANT_RADIO=!0;function Rc(e){return Mn(e,{inputAffixPadding:e.paddingXXS})}const _c=e=>{const{controlHeight:t,fontSize:n,lineHeight:r,lineWidth:o,controlHeightSM:i,controlHeightLG:a,fontSizeLG:s,lineHeightLG:l,paddingSM:c,controlPaddingHorizontalSM:u,controlPaddingHorizontal:d,colorFillAlter:f,colorPrimaryHover:h,colorPrimary:m,controlOutlineWidth:p,controlOutline:g,colorErrorOutline:v,colorWarningOutline:y,colorBgContainer:b,inputFontSize:w,inputFontSizeLG:x,inputFontSizeSM:E}=e,k=w||n,S=E||k,O=x||s,A=Math.round((t-k*r)/2*10)/10-o,$=Math.round((i-S*r)/2*10)/10-o,M=Math.ceil((a-O*l)/2*10)/10-o;return{paddingBlock:Math.max(A,0),paddingBlockSM:Math.max($,0),paddingBlockLG:Math.max(M,0),paddingInline:c-o,paddingInlineSM:u-o,paddingInlineLG:d-o,addonBg:f,activeBorderColor:m,hoverBorderColor:h,activeShadow:`0 0 0 ${p}px ${g}`,errorActiveShadow:`0 0 0 ${p}px ${v}`,warningActiveShadow:`0 0 0 ${p}px ${y}`,hoverBg:b,activeBg:b,inputFontSize:k,inputFontSizeLG:O,inputFontSizeSM:S}},V7=e=>({borderColor:e.hoverBorderColor,backgroundColor:e.hoverBg}),dk=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])":Object.assign({},V7(Mn(e,{hoverBorderColor:e.colorBorder,hoverBg:e.colorBgContainerDisabled})))}),ER=(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}}),aA=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},ER(e,t)),{[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}}),[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:t.borderColor}}),fk=(e,t)=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},ER(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow})),{[`&${e.componentCls}-disabled, &[disabled]`]:Object.assign({},dk(e))}),aA(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError})),aA(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning})),t)}),sA=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{borderColor:t.addonBorderColor,color:t.addonColor}}}),wR=e=>({"&-outlined":Object.assign(Object.assign(Object.assign({[`${e.componentCls}-group`]:{"&-addon":{background:e.addonBg,border:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}}},sA(e,{status:"error",addonBorderColor:e.colorError,addonColor:e.colorErrorText})),sA(e,{status:"warning",addonBorderColor:e.colorWarning,addonColor:e.colorWarningText})),{[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group-addon`]:Object.assign({},dk(e))}})}),hk=(e,t)=>{const{componentCls:n}=e;return{"&-borderless":Object.assign({background:"transparent",border:"none","&:focus, &:focus-within":{outline:"none"},[`&${n}-disabled, &[disabled]`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${n}-status-error`]:{"&, & input, & textarea":{color:e.colorError}},[`&${n}-status-warning`]:{"&, & input, & textarea":{color:e.colorWarning}}},t)}},CR=(e,t)=>{var n;return{background:t.bg,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:"transparent","input&, & input, textarea&, & textarea":{color:(n=t==null?void 0:t.inputColor)!==null&&n!==void 0?n:"unset"},"&:hover":{background:t.hoverBg},"&:focus, &:focus-within":{outline:0,borderColor:t.activeBorderColor,backgroundColor:e.activeBg}}},lA=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},CR(e,t)),{[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}})}),pk=(e,t)=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},CR(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor})),{[`&${e.componentCls}-disabled, &[disabled]`]:Object.assign({},dk(e))}),lA(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,inputColor:e.colorErrorText,affixColor:e.colorError})),lA(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,inputColor:e.colorWarningText,affixColor:e.colorWarning})),t)}),cA=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{background:t.addonBg,color:t.addonColor}}}),kR=e=>({"&-filled":Object.assign(Object.assign(Object.assign({[`${e.componentCls}-group-addon`]:{background:e.colorFillTertiary,"&:last-child":{position:"static"}}},cA(e,{status:"error",addonBg:e.colorErrorBg,addonColor:e.colorErrorText})),cA(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:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:last-child":{borderInlineEnd:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${Ce(e.lineWidth)} ${e.lineType} ${e.colorBorder}`}}}})}),SR=(e,t)=>({background:e.colorBgContainer,borderWidth:`${Ce(e.lineWidth)} 0`,borderStyle:`${e.lineType} none`,borderColor:`transparent transparent ${t.borderColor} transparent`,borderRadius:0,"&:hover":{borderColor:`transparent transparent ${t.borderColor} transparent`,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:`transparent transparent ${t.activeBorderColor} transparent`,outline:0,backgroundColor:e.activeBg}}),uA=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:Object.assign(Object.assign({},SR(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`}}),gk=(e,t)=>({"&-underlined":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},SR(e,{borderColor:e.colorBorder,activeBorderColor:e.activeBorderColor})),{[`&${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"}}),uA(e,{status:"error",borderColor:e.colorError,activeBorderColor:e.colorError,affixColor:e.colorError})),uA(e,{status:"warning",borderColor:e.colorWarning,activeBorderColor:e.colorWarning,affixColor:e.colorWarning})),t)}),mk=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),AR=e=>{const{paddingBlockLG:t,lineHeightLG:n,borderRadiusLG:r,paddingInlineLG:o}=e;return{padding:`${Ce(t)} ${Ce(o)}`,fontSize:e.inputFontSizeLG,lineHeight:n,borderRadius:r}},$R=e=>({padding:`${Ce(e.paddingBlockSM)} ${Ce(e.paddingInlineSM)}`,fontSize:e.inputFontSizeSM,borderRadius:e.borderRadiusSM}),jp=e=>Object.assign(Object.assign({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:`${Ce(e.paddingBlock)} ${Ce(e.paddingInline)}`,color:e.colorText,fontSize:e.inputFontSize,lineHeight:e.lineHeight,borderRadius:e.borderRadius,transition:`all ${e.motionDurationMid}`},mk(e.colorTextPlaceholder)),{"&-lg":Object.assign({},AR(e)),"&-sm":Object.assign({},$R(e)),"&-rtl, &-textarea-rtl":{direction:"rtl"}}),OR=e=>{const{componentCls:t,antCls:n}=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`]:Object.assign({},AR(e)),[`&-sm ${t}, &-sm > ${t}-group-addon`]:Object.assign({},$R(e)),[`&-lg ${n}-select-single ${n}-select-selector`]:{height:e.controlHeightLG},[`&-sm ${n}-select-single ${n}-select-selector`]:{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 ${Ce(e.paddingInline)}`,color:e.colorText,fontWeight:"normal",fontSize:e.inputFontSize,textAlign:"center",borderRadius:e.borderRadius,transition:`all ${e.motionDurationSlow}`,lineHeight:1,[`${n}-select`]:{margin:`${Ce(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${Ce(e.calc(e.paddingInline).mul(-1).equal())}`,[`&${n}-select-single:not(${n}-select-customize-input):not(${n}-pagination-size-changer)`]:{[`${n}-select-selector`]:{backgroundColor:"inherit",border:`${Ce(e.lineWidth)} ${e.lineType} transparent`,boxShadow:"none"}}},[`${n}-cascader-picker`]:{margin:`-9px ${Ce(e.calc(e.paddingInline).mul(-1).equal())}`,backgroundColor:"transparent",[`${n}-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}-search-with-button &`]:{zIndex:0}}},[`> ${t}:first-child, ${t}-group-addon:first-child`]:{borderStartEndRadius:0,borderEndEndRadius:0,[`${n}-select ${n}-select-selector`]:{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,[`${n}-select ${n}-select-selector`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`${t}-affix-wrapper`]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0,[`${t}-search &`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius}},[`&:not(:first-child), ${t}-search &:not(:first-child)`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&${t}-group-compact`]:Object.assign(Object.assign({display:"block"},uG()),{[`${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},[`
|
|
315
315
|
& > ${t}-affix-wrapper,
|
|
316
316
|
& > ${t}-number-affix-wrapper,
|
|
@@ -345,7 +345,7 @@ html body {
|
|
|
345
345
|
&${r}-slide-up-appear${r}-slide-up-appear-active${n}-dropdown-placement-bottomLeft,
|
|
346
346
|
&${r}-slide-up-appear${r}-slide-up-appear-active${n}-dropdown-placement-bottomRight`]:{animationName:zC},[`&${r}-slide-up-leave ${n}-panel-container`]:{pointerEvents:"none"},[`&${r}-slide-up-leave${r}-slide-up-leave-active${n}-dropdown-placement-topLeft,
|
|
347
347
|
&${r}-slide-up-leave${r}-slide-up-leave-active${n}-dropdown-placement-topRight`]:{animationName:VC},[`&${r}-slide-up-leave${r}-slide-up-leave-active${n}-dropdown-placement-bottomLeft,
|
|
348
|
-
&${r}-slide-up-leave${r}-slide-up-leave-active${n}-dropdown-placement-bottomRight`]:{animationName:HC},[`${n}-panel > ${n}-time-panel`]:{paddingTop:A},[`${n}-range-wrapper`]:{display:"flex",position:"relative"},[`${n}-range-arrow`]:Object.assign(Object.assign({position:"absolute",zIndex:1,display:"none",paddingInline:e.calc(o).mul(1.5).equal(),boxSizing:"content-box",transition:`all ${S} ease-out`},DB(e,M,V)),{"&:before":{insetInlineStart:e.calc(o).mul(1.5).equal()}}),[`${n}-panel-container`]:{overflow:"hidden",verticalAlign:"top",background:M,borderRadius:N,boxShadow:D,transition:`margin ${S}`,display:"inline-block",pointerEvents:"auto",[`${n}-panel-layout`]:{display:"flex",flexWrap:"nowrap",alignItems:"stretch"},[`${n}-presets`]:{display:"flex",flexDirection:"column",minWidth:R,maxWidth:H,ul:{height:0,flex:"auto",listStyle:"none",overflow:"auto",margin:0,padding:b,borderInlineEnd:`${Ce(i)} ${a} ${P}`,li:Object.assign(Object.assign({},c0),{borderRadius:T,paddingInline:b,paddingBlock:e.calc(v).sub(L).div(2).equal(),cursor:"pointer",transition:`all ${S}`,"+ li":{marginTop:w},"&:hover":{background:I}})}},[`${n}-panels`]:{display:"inline-flex",flexWrap:"nowrap","&:last-child":{[`${n}-panel`]:{borderWidth:0}}},[`${n}-panel`]:{verticalAlign:"top",background:"transparent",borderRadius:0,borderWidth:0,[`${n}-content, table`]:{textAlign:"center"},"&-focused":{borderColor:s}}}}),"&-dropdown-range":{padding:`${Ce(e.calc($).mul(2).div(3).equal())} 0`,"&-hidden":{display:"none"}},"&-rtl":{direction:"rtl",[`${n}-separator`]:{transform:"scale(-1, 1)"},[`${n}-footer`]:{"&-extra":{direction:"rtl"}}}})},p0(e,"slide-up"),p0(e,"slide-down"),h0(e,"move-up"),h0(e,"move-down")]},DR=Pr("DatePicker",e=>{const t=Mn(Rc(e),tee(e),{inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[eee(t),aee(t),oee(t),iee(t),Z7(t),$d(e,{focusElCls:`${e.componentCls}-focused`})]},ree),TR=us({});var see=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function dA(e){return e==="auto"?"1 1 auto":typeof e=="number"?`${e} ${e} auto`:/^\d+(\.\d+)?(px|em|rem|%)$/.test(e)?`0 0 ${e}`:e}const lee=["xs","sm","md","lg","xl","xxl"],y0=C.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=C.useContext(pn),{gutter:o,wrap:i}=C.useContext(TR),{prefixCls:a,span:s,order:l,offset:c,push:u,pull:d,className:f,children:h,flex:m,style:p}=e,g=see(e,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),v=n("col",a),[y,b,w]=XX(v),x={};let E={};lee.forEach(O=>{let A={};const $=e[O];typeof $=="number"?A.span=$:typeof $=="object"&&(A=$||{}),delete g[O],E=Object.assign(Object.assign({},E),{[`${v}-${O}-${A.span}`]:A.span!==void 0,[`${v}-${O}-order-${A.order}`]:A.order||A.order===0,[`${v}-${O}-offset-${A.offset}`]:A.offset||A.offset===0,[`${v}-${O}-push-${A.push}`]:A.push||A.push===0,[`${v}-${O}-pull-${A.pull}`]:A.pull||A.pull===0,[`${v}-rtl`]:r==="rtl"}),A.flex&&(E[`${v}-${O}-flex`]=!0,x[`--${v}-${O}-flex`]=dA(A.flex))});const k=me(v,{[`${v}-${s}`]:s!==void 0,[`${v}-order-${l}`]:l,[`${v}-offset-${c}`]:c,[`${v}-push-${u}`]:u,[`${v}-pull-${d}`]:d},f,E,b,w),S={};if(o!=null&&o[0]){const O=typeof o[0]=="number"?`${o[0]/2}px`:`calc(${o[0]} / 2)`;S.paddingLeft=O,S.paddingRight=O}return m&&(S.flex=dA(m),i===!1&&!S.minWidth&&(S.minWidth=0)),y(C.createElement("div",Object.assign({},g,{style:Object.assign(Object.assign(Object.assign({},S),p),x),className:k,ref:t}),h))});function cee(e,t){const n=[void 0,void 0],r=Array.isArray(e)?e:[e,void 0],o=t||{xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0};return r.forEach((i,a)=>{if(typeof i=="object"&&i!==null)for(let s=0;s<rd.length;s++){const l=rd[s];if(o[l]&&i[l]!==void 0){n[a]=i[l];break}}else n[a]=i}),n}var uee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function fA(e,t){const[n,r]=C.useState(typeof e=="string"?e:""),o=()=>{if(typeof e=="string"&&r(e),typeof e=="object")for(let i=0;i<rd.length;i++){const a=rd[i];if(!t||!t[a])continue;const s=e[a];if(s!==void 0){r(s);return}}};return C.useEffect(()=>{o()},[JSON.stringify(e),t]),n}const FR=C.forwardRef((e,t)=>{const{prefixCls:n,justify:r,align:o,className:i,style:a,children:s,gutter:l=0,wrap:c}=e,u=uee(e,["prefixCls","justify","align","className","style","children","gutter","wrap"]),{getPrefixCls:d,direction:f}=C.useContext(pn),h=vQ(!0,null),m=fA(o,h),p=fA(r,h),g=d("row",n),[v,y,b]=qX(g),w=cee(l,h),x=me(g,{[`${g}-no-wrap`]:c===!1,[`${g}-${p}`]:p,[`${g}-${m}`]:m,[`${g}-rtl`]:f==="rtl"},i,y,b),E={};if(w!=null&&w[0]){const A=typeof w[0]=="number"?`${w[0]/-2}px`:`calc(${w[0]} / -2)`;E.marginLeft=A,E.marginRight=A}const[k,S]=w;E.rowGap=S;const O=C.useMemo(()=>({gutter:[k,S],wrap:c}),[k,S,c]);return v(C.createElement(TR.Provider,{value:O},C.createElement("div",Object.assign({},u,{className:x,style:Object.assign(Object.assign({},E),a),ref:t}),s)))});var dee={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"},fee=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:dee}))},hee=C.forwardRef(fee);function tw(){return typeof BigInt=="function"}function PR(e){return!e&&e!==0&&!Number.isNaN(e)||!String(e).trim()}function Us(e){var t=e.trim(),n=t.startsWith("-");n&&(t=t.slice(1)),t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),t.startsWith(".")&&(t="0".concat(t));var r=t||"0",o=r.split("."),i=o[0]||"0",a=o[1]||"0";i==="0"&&a==="0"&&(n=!1);var s=n?"-":"";return{negative:n,negativeStr:s,trimStr:r,integerStr:i,decimalStr:a,fullStr:"".concat(s).concat(r)}}function vk(e){var t=String(e);return!Number.isNaN(Number(t))&&t.includes("e")}function _s(e){var t=String(e);if(vk(e)){var n=Number(t.slice(t.indexOf("e-")+2)),r=t.match(/\.(\d+)/);return r!=null&&r[1]&&(n+=r[1].length),n}return t.includes(".")&&yk(t)?t.length-t.indexOf(".")-1:0}function Lp(e){var t=String(e);if(vk(e)){if(e>Number.MAX_SAFE_INTEGER)return String(tw()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(e<Number.MIN_SAFE_INTEGER)return String(tw()?BigInt(e).toString():Number.MIN_SAFE_INTEGER);t=e.toFixed(_s(t))}return Us(t).fullStr}function yk(e){return typeof e=="number"?!Number.isNaN(e):e?/^\s*-?\d+(\.\d+)?\s*$/.test(e)||/^\s*-?\d+\.\s*$/.test(e)||/^\s*-?\.\d+\s*$/.test(e):!1}var pee=(function(){function e(t){if(xr(this,e),X(this,"origin",""),X(this,"negative",void 0),X(this,"integer",void 0),X(this,"decimal",void 0),X(this,"decimalLen",void 0),X(this,"empty",void 0),X(this,"nan",void 0),PR(t)){this.empty=!0;return}if(this.origin=String(t),t==="-"||Number.isNaN(t)){this.nan=!0;return}var n=t;if(vk(n)&&(n=Number(n)),n=typeof n=="string"?n:Lp(n),yk(n)){var r=Us(n);this.negative=r.negative;var o=r.trimStr.split(".");this.integer=BigInt(o[0]);var i=o[1]||"0";this.decimal=BigInt(i),this.decimalLen=i.length}else this.nan=!0}return Er(e,[{key:"getMark",value:function(){return this.negative?"-":""}},{key:"getIntegerStr",value:function(){return this.integer.toString()}},{key:"getDecimalStr",value:function(){return this.decimal.toString().padStart(this.decimalLen,"0")}},{key:"alignDecimal",value:function(t){var n="".concat(this.getMark()).concat(this.getIntegerStr()).concat(this.getDecimalStr().padEnd(t,"0"));return BigInt(n)}},{key:"negate",value:function(){var t=new e(this.toString());return t.negative=!t.negative,t}},{key:"cal",value:function(t,n,r){var o=Math.max(this.getDecimalStr().length,t.getDecimalStr().length),i=this.alignDecimal(o),a=t.alignDecimal(o),s=n(i,a).toString(),l=r(o),c=Us(s),u=c.negativeStr,d=c.trimStr,f="".concat(u).concat(d.padStart(l+1,"0"));return new e("".concat(f.slice(0,-l),".").concat(f.slice(-l)))}},{key:"add",value:function(t){if(this.isInvalidate())return new e(t);var n=new e(t);return n.isInvalidate()?this:this.cal(n,function(r,o){return r+o},function(r){return r})}},{key:"multi",value:function(t){var n=new e(t);return this.isInvalidate()||n.isInvalidate()?new e(NaN):this.cal(n,function(r,o){return r*o},function(r){return r*2})}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return this.nan}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(t){return this.toString()===(t==null?void 0:t.toString())}},{key:"lessEquals",value:function(t){return this.add(t.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t?this.isInvalidate()?"":Us("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e})(),gee=(function(){function e(t){if(xr(this,e),X(this,"origin",""),X(this,"number",void 0),X(this,"empty",void 0),PR(t)){this.empty=!0;return}this.origin=String(t),this.number=Number(t)}return Er(e,[{key:"negate",value:function(){return new e(-this.toNumber())}},{key:"add",value:function(t){if(this.isInvalidate())return new e(t);var n=Number(t);if(Number.isNaN(n))return this;var r=this.number+n;if(r>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(r<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var o=Math.max(_s(this.number),_s(n));return new e(r.toFixed(o))}},{key:"multi",value:function(t){var n=Number(t);if(this.isInvalidate()||Number.isNaN(n))return new e(NaN);var r=this.number*n;if(r>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(r<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var o=Math.max(_s(this.number),_s(n));return new e(r.toFixed(o))}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return Number.isNaN(this.number)}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(t){return this.toNumber()===(t==null?void 0:t.toNumber())}},{key:"lessEquals",value:function(t){return this.add(t.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.number}},{key:"toString",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t?this.isInvalidate()?"":Lp(this.number):this.origin}}]),e})();function gi(e){return tw()?new pee(e):new gee(e)}function ch(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(e==="")return"";var o=Us(e),i=o.negativeStr,a=o.integerStr,s=o.decimalStr,l="".concat(t).concat(s),c="".concat(i).concat(a);if(n>=0){var u=Number(s[n]);if(u>=5&&!r){var d=gi(e).add("".concat(i,"0.").concat("0".repeat(n)).concat(10-u));return ch(d.toString(),t,n,r)}return n===0?c:"".concat(c).concat(t).concat(s.padEnd(n,"0").slice(0,n))}return l===".0"?c:"".concat(c).concat(l)}function mee(e){return!!(e.addonBefore||e.addonAfter)}function vee(e){return!!(e.prefix||e.suffix||e.allowClear)}function hA(e,t,n){var r=t.cloneNode(!0),o=Object.create(e,{target:{value:r},currentTarget:{value:r}});return r.value=n,typeof t.selectionStart=="number"&&typeof t.selectionEnd=="number"&&(r.selectionStart=t.selectionStart,r.selectionEnd=t.selectionEnd),r.setSelectionRange=function(){t.setSelectionRange.apply(t,arguments)},o}function b0(e,t,n,r){if(n){var o=t;if(t.type==="click"){o=hA(t,e,""),n(o);return}if(e.type!=="file"&&r!==void 0){o=hA(t,e,r),n(o);return}n(o)}}function bk(e,t){if(e){e.focus(t);var n=t||{},r=n.cursor;if(r){var o=e.value.length;switch(r){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(o,o);break;default:e.setSelectionRange(0,o)}}}}var xk=we.forwardRef(function(e,t){var n,r,o,i=e.inputElement,a=e.children,s=e.prefixCls,l=e.prefix,c=e.suffix,u=e.addonBefore,d=e.addonAfter,f=e.className,h=e.style,m=e.disabled,p=e.readOnly,g=e.focused,v=e.triggerFocus,y=e.allowClear,b=e.value,w=e.handleReset,x=e.hidden,E=e.classes,k=e.classNames,S=e.dataAttrs,O=e.styles,A=e.components,$=e.onClear,M=a??i,N=(A==null?void 0:A.affixWrapper)||"span",D=(A==null?void 0:A.groupWrapper)||"span",T=(A==null?void 0:A.wrapper)||"span",P=(A==null?void 0:A.groupAddon)||"span",I=et(null),R=function(re){var oe;(oe=I.current)!==null&&oe!==void 0&&oe.contains(re.target)&&(v==null||v())},H=vee(e),V=OF(M,{value:b,className:me((n=M.props)===null||n===void 0?void 0:n.className,!H&&(k==null?void 0:k.variant))||null}),L=et(null);if(we.useImperativeHandle(t,function(){return{nativeElement:L.current||I.current}}),H){var j=null;if(y){var _=!m&&!p&&b,F="".concat(s,"-clear-icon"),B=At(y)==="object"&&y!==null&&y!==void 0&&y.clearIcon?y.clearIcon:"\u2716";j=we.createElement("button",{type:"button",tabIndex:-1,onClick:function(re){w==null||w(re),$==null||$()},onMouseDown:function(re){return re.preventDefault()},className:me(F,X(X({},"".concat(F,"-hidden"),!_),"".concat(F,"-has-suffix"),!!c))},B)}var z="".concat(s,"-affix-wrapper"),G=me(z,X(X(X(X(X({},"".concat(s,"-disabled"),m),"".concat(z,"-disabled"),m),"".concat(z,"-focused"),g),"".concat(z,"-readonly"),p),"".concat(z,"-input-with-clear-btn"),c&&y&&b),E==null?void 0:E.affixWrapper,k==null?void 0:k.affixWrapper,k==null?void 0:k.variant),W=(c||y)&&we.createElement("span",{className:me("".concat(s,"-suffix"),k==null?void 0:k.suffix),style:O==null?void 0:O.suffix},j,c);V=we.createElement(N,Qe({className:G,style:O==null?void 0:O.affixWrapper,onClick:R},S==null?void 0:S.affixWrapper,{ref:I}),l&&we.createElement("span",{className:me("".concat(s,"-prefix"),k==null?void 0:k.prefix),style:O==null?void 0:O.prefix},l),V,W)}if(mee(e)){var q="".concat(s,"-group"),U="".concat(q,"-addon"),Y="".concat(q,"-wrapper"),ie=me("".concat(s,"-wrapper"),q,E==null?void 0:E.wrapper,k==null?void 0:k.wrapper),K=me(Y,X({},"".concat(Y,"-disabled"),m),E==null?void 0:E.group,k==null?void 0:k.groupWrapper);V=we.createElement(D,{className:K,ref:L},we.createElement(T,{className:ie},u&&we.createElement(P,{className:U},u),V,d&&we.createElement(P,{className:U},d)))}return we.cloneElement(V,{className:me((r=V.props)===null||r===void 0?void 0:r.className,f)||null,style:Q(Q({},(o=V.props)===null||o===void 0?void 0:o.style),h),hidden:x})}),yee=["show"];function IR(e,t){return C.useMemo(function(){var n={};t&&(n.show=At(t)==="object"&&t.formatter?t.formatter:!!t),n=Q(Q({},n),e);var r=n,o=r.show,i=tn(r,yee);return Q(Q({},i),{},{show:!!o,showFormatter:typeof o=="function"?o:void 0,strategy:i.strategy||function(a){return a.length}})},[e,t])}var bee=["autoComplete","onChange","onFocus","onBlur","onPressEnter","onKeyDown","onKeyUp","prefixCls","disabled","htmlSize","className","maxLength","suffix","showCount","count","type","classes","classNames","styles","onCompositionStart","onCompositionEnd"],xee=Oi(function(e,t){var n=e.autoComplete,r=e.onChange,o=e.onFocus,i=e.onBlur,a=e.onPressEnter,s=e.onKeyDown,l=e.onKeyUp,c=e.prefixCls,u=c===void 0?"rc-input":c,d=e.disabled,f=e.htmlSize,h=e.className,m=e.maxLength,p=e.suffix,g=e.showCount,v=e.count,y=e.type,b=y===void 0?"text":y,w=e.classes,x=e.classNames,E=e.styles,k=e.onCompositionStart,S=e.onCompositionEnd,O=tn(e,bee),A=nt(!1),$=te(A,2),M=$[0],N=$[1],D=et(!1),T=et(!1),P=et(null),I=et(null),R=function(ce){P.current&&bk(P.current,ce)},H=yr(e.defaultValue,{value:e.value}),V=te(H,2),L=V[0],j=V[1],_=L==null?"":String(L),F=nt(null),B=te(F,2),z=B[0],G=B[1],W=IR(v,g),q=W.max||m,U=W.strategy(_),Y=!!q&&U>q;Oc(t,function(){var ce;return{focus:R,blur:function(){var he;(he=P.current)===null||he===void 0||he.blur()},setSelectionRange:function(he,Te,se){var Pe;(Pe=P.current)===null||Pe===void 0||Pe.setSelectionRange(he,Te,se)},select:function(){var he;(he=P.current)===null||he===void 0||he.select()},input:P.current,nativeElement:((ce=I.current)===null||ce===void 0?void 0:ce.nativeElement)||P.current}}),Et(function(){T.current&&(T.current=!1),N(function(ce){return ce&&d?!1:ce})},[d]);var ie=function(ce,he,Te){var se=he;if(!D.current&&W.exceedFormatter&&W.max&&W.strategy(he)>W.max){if(se=W.exceedFormatter(he,{max:W.max}),he!==se){var Pe,De;G([((Pe=P.current)===null||Pe===void 0?void 0:Pe.selectionStart)||0,((De=P.current)===null||De===void 0?void 0:De.selectionEnd)||0])}}else if(Te.source==="compositionEnd")return;j(se),P.current&&b0(P.current,ce,r,se)};Et(function(){if(z){var ce;(ce=P.current)===null||ce===void 0||ce.setSelectionRange.apply(ce,ze(z))}},[z]);var K=function(ce){ie(ce,ce.target.value,{source:"change"})},re=function(ce){D.current=!1,ie(ce,ce.currentTarget.value,{source:"compositionEnd"}),S==null||S(ce)},oe=function(ce){a&&ce.key==="Enter"&&!T.current&&(T.current=!0,a(ce)),s==null||s(ce)},ne=function(ce){ce.key==="Enter"&&(T.current=!1),l==null||l(ce)},ae=function(ce){N(!0),o==null||o(ce)},de=function(ce){T.current&&(T.current=!1),N(!1),i==null||i(ce)},ge=function(ce){j(""),R(),P.current&&b0(P.current,ce,r)},Se=Y&&"".concat(u,"-out-of-range"),ye=function(){var ce=ta(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames","onClear"]);return we.createElement("input",Qe({autoComplete:n},ce,{onChange:K,onFocus:ae,onBlur:de,onKeyDown:oe,onKeyUp:ne,className:me(u,X({},"".concat(u,"-disabled"),d),x==null?void 0:x.input),style:E==null?void 0:E.input,ref:P,size:f,type:b,onCompositionStart:function(he){D.current=!0,k==null||k(he)},onCompositionEnd:re}))},be=function(){var ce=Number(q)>0;if(p||W.show){var he=W.showFormatter?W.showFormatter({value:_,count:U,maxLength:q}):"".concat(U).concat(ce?" / ".concat(q):"");return we.createElement(we.Fragment,null,W.show&&we.createElement("span",{className:me("".concat(u,"-show-count-suffix"),X({},"".concat(u,"-show-count-has-suffix"),!!p),x==null?void 0:x.count),style:Q({},E==null?void 0:E.count)},he),p)}return null};return we.createElement(xk,Qe({},O,{prefixCls:u,className:me(h,Se),handleReset:ge,value:_,focused:M,triggerFocus:R,suffix:be(),disabled:d,classes:w,classNames:x,styles:E,ref:I}),ye())});function Eee(e,t){return typeof Proxy<"u"&&e?new Proxy(e,{get:function(n,r){if(t[r])return t[r];var o=n[r];return typeof o=="function"?o.bind(n):o}}):e}function wee(e,t){var n=et(null);function r(){try{var i=e.selectionStart,a=e.selectionEnd,s=e.value,l=s.substring(0,i),c=s.substring(a);n.current={start:i,end:a,value:s,beforeTxt:l,afterTxt:c}}catch{}}function o(){if(e&&n.current&&t)try{var i=e.value,a=n.current,s=a.beforeTxt,l=a.afterTxt,c=a.start,u=i.length;if(i.startsWith(s))u=s.length;else if(i.endsWith(l))u=i.length-n.current.afterTxt.length;else{var d=s[c-1],f=i.indexOf(d,c-1);f!==-1&&(u=f+1)}e.setSelectionRange(u,u)}catch(h){qr(!1,"Something warning of cursor restore. Please fire issue about this: ".concat(h.message))}}return[r,o]}var Cee=function(){var e=nt(!1),t=te(e,2),n=t[0],r=t[1];return mn(function(){r(JC())},[]),n},kee=200,See=600;function Aee(e){var t=e.prefixCls,n=e.upNode,r=e.downNode,o=e.upDisabled,i=e.downDisabled,a=e.onStep,s=C.useRef(),l=C.useRef([]),c=C.useRef();c.current=a;var u=function(){clearTimeout(s.current)},d=function(y,b){y.preventDefault(),u(),c.current(b);function w(){c.current(b),s.current=setTimeout(w,kee)}s.current=setTimeout(w,See)};C.useEffect(function(){return function(){u(),l.current.forEach(function(y){return en.cancel(y)})}},[]);var f=Cee();if(f)return null;var h="".concat(t,"-handler"),m=me(h,"".concat(h,"-up"),X({},"".concat(h,"-up-disabled"),o)),p=me(h,"".concat(h,"-down"),X({},"".concat(h,"-down-disabled"),i)),g=function(){return l.current.push(en(u))},v={unselectable:"on",role:"button",onMouseUp:g,onMouseLeave:g};return C.createElement("div",{className:"".concat(h,"-wrap")},C.createElement("span",Qe({},v,{onMouseDown:function(y){d(y,!0)},"aria-label":"Increase Value","aria-disabled":o,className:m}),n||C.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-up-inner")})),C.createElement("span",Qe({},v,{onMouseDown:function(y){d(y,!1)},"aria-label":"Decrease Value","aria-disabled":i,className:p}),r||C.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-down-inner")})))}function pA(e){var t=typeof e=="number"?Lp(e):Us(e).fullStr,n=t.includes(".");return n?Us(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}const $ee=(function(){var e=et(0),t=function(){en.cancel(e.current)};return Et(function(){return t},[]),function(n){t(),e.current=en(function(){n()})}});var Oee=["prefixCls","className","style","min","max","step","defaultValue","value","disabled","readOnly","upHandler","downHandler","keyboard","changeOnWheel","controls","classNames","stringMode","parser","formatter","precision","decimalSeparator","onChange","onInput","onPressEnter","onStep","changeOnBlur","domRef"],Mee=["disabled","style","prefixCls","value","prefix","suffix","addonBefore","addonAfter","className","classNames"],gA=function(e,t){return e||t.isEmpty()?t.toString():t.toNumber()},mA=function(e){var t=gi(e);return t.isInvalidate()?null:t},Nee=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.className,o=e.style,i=e.min,a=e.max,s=e.step,l=s===void 0?1:s,c=e.defaultValue,u=e.value,d=e.disabled,f=e.readOnly,h=e.upHandler,m=e.downHandler,p=e.keyboard,g=e.changeOnWheel,v=g===void 0?!1:g,y=e.controls,b=y===void 0?!0:y,w=e.stringMode,x=e.parser,E=e.formatter,k=e.precision,S=e.decimalSeparator,O=e.onChange,A=e.onInput,$=e.onPressEnter,M=e.onStep,N=e.changeOnBlur,D=N===void 0?!0:N,T=e.domRef,P=tn(e,Oee),I="".concat(n,"-input"),R=C.useRef(null),H=C.useState(!1),V=te(H,2),L=V[0],j=V[1],_=C.useRef(!1),F=C.useRef(!1),B=C.useRef(!1),z=C.useState(function(){return gi(u??c)}),G=te(z,2),W=G[0],q=G[1];function U(Ge){u===void 0&&q(Ge)}var Y=C.useCallback(function(Ge,Xe){if(!Xe)return k>=0?k:Math.max(_s(Ge),_s(l))},[k,l]),ie=C.useCallback(function(Ge){var Xe=String(Ge);if(x)return x(Xe);var qe=Xe;return S&&(qe=qe.replace(S,".")),qe.replace(/[^\w.-]+/g,"")},[x,S]),K=C.useRef(""),re=C.useCallback(function(Ge,Xe){if(E)return E(Ge,{userTyping:Xe,input:String(K.current)});var qe=typeof Ge=="number"?Lp(Ge):Ge;if(!Xe){var lt=Y(qe,Xe);if(yk(qe)&&(S||lt>=0)){var je=S||".";qe=ch(qe,je,lt)}}return qe},[E,Y,S]),oe=C.useState(function(){var Ge=c??u;return W.isInvalidate()&&["string","number"].includes(At(Ge))?Number.isNaN(Ge)?"":Ge:re(W.toString(),!1)}),ne=te(oe,2),ae=ne[0],de=ne[1];K.current=ae;function ge(Ge,Xe){de(re(Ge.isInvalidate()?Ge.toString(!1):Ge.toString(!Xe),Xe))}var Se=C.useMemo(function(){return mA(a)},[a,k]),ye=C.useMemo(function(){return mA(i)},[i,k]),be=C.useMemo(function(){return!Se||!W||W.isInvalidate()?!1:Se.lessEquals(W)},[Se,W]),ce=C.useMemo(function(){return!ye||!W||W.isInvalidate()?!1:W.lessEquals(ye)},[ye,W]),he=wee(R.current,L),Te=te(he,2),se=Te[0],Pe=Te[1],De=function(Ge){return Se&&!Ge.lessEquals(Se)?Se:ye&&!ye.lessEquals(Ge)?ye:null},He=function(Ge){return!De(Ge)},ue=function(Ge,Xe){var qe=Ge,lt=He(qe)||qe.isEmpty();if(!qe.isEmpty()&&!Xe&&(qe=De(qe)||qe,lt=!0),!f&&!d&<){var je=qe.toString(),Rt=Y(je,Xe);return Rt>=0&&(qe=gi(ch(je,".",Rt)),He(qe)||(qe=gi(ch(je,".",Rt,!0)))),qe.equals(W)||(U(qe),O==null||O(qe.isEmpty()?null:gA(w,qe)),u===void 0&&ge(qe,Xe)),qe}return W},ve=$ee(),xe=function Ge(Xe){if(se(),K.current=Xe,de(Xe),!F.current){var qe=ie(Xe),lt=gi(qe);lt.isNaN()||ue(lt,!0)}A==null||A(Xe),ve(function(){var je=Xe;x||(je=Xe.replace(/。/g,".")),je!==Xe&&Ge(je)})},fe=function(){F.current=!0},pe=function(){F.current=!1,xe(R.current.value)},ke=function(Ge){xe(Ge.target.value)},Ve=function(Ge){var Xe;if(!(Ge&&be||!Ge&&ce)){_.current=!1;var qe=gi(B.current?pA(l):l);Ge||(qe=qe.negate());var lt=(W||gi(0)).add(qe.toString()),je=ue(lt,!1);M==null||M(gA(w,je),{offset:B.current?pA(l):l,type:Ge?"up":"down"}),(Xe=R.current)===null||Xe===void 0||Xe.focus()}},Ee=function(Ge){var Xe=gi(ie(ae)),qe;Xe.isNaN()?qe=ue(W,Ge):qe=ue(Xe,Ge),u!==void 0?ge(W,!1):qe.isNaN()||ge(qe,!1)},yt=function(){_.current=!0},Dt=function(Ge){var Xe=Ge.key,qe=Ge.shiftKey;_.current=!0,B.current=qe,Xe==="Enter"&&(F.current||(_.current=!1),Ee(!1),$==null||$(Ge)),p!==!1&&!F.current&&["Up","ArrowUp","Down","ArrowDown"].includes(Xe)&&(Ve(Xe==="Up"||Xe==="ArrowUp"),Ge.preventDefault())},Ft=function(){_.current=!1,B.current=!1};C.useEffect(function(){if(v&&L){var Ge=function(qe){Ve(qe.deltaY<0),qe.preventDefault()},Xe=R.current;if(Xe)return Xe.addEventListener("wheel",Ge,{passive:!1}),function(){return Xe.removeEventListener("wheel",Ge)}}});var Ut=function(){D&&Ee(!1),j(!1),_.current=!1};return nc(function(){W.isInvalidate()||ge(W,!1)},[k,E]),nc(function(){var Ge=gi(u);q(Ge);var Xe=gi(ie(ae));(!Ge.equals(Xe)||!_.current||E)&&ge(Ge,_.current)},[u]),nc(function(){E&&Pe()},[ae]),C.createElement("div",{ref:T,className:me(n,r,X(X(X(X(X({},"".concat(n,"-focused"),L),"".concat(n,"-disabled"),d),"".concat(n,"-readonly"),f),"".concat(n,"-not-a-number"),W.isNaN()),"".concat(n,"-out-of-range"),!W.isInvalidate()&&!He(W))),style:o,onFocus:function(){j(!0)},onBlur:Ut,onKeyDown:Dt,onKeyUp:Ft,onCompositionStart:fe,onCompositionEnd:pe,onBeforeInput:yt},b&&C.createElement(Aee,{prefixCls:n,upNode:h,downNode:m,upDisabled:be,downDisabled:ce,onStep:Ve}),C.createElement("div",{className:"".concat(I,"-wrap")},C.createElement("input",Qe({autoComplete:"off",role:"spinbutton","aria-valuemin":i,"aria-valuemax":a,"aria-valuenow":W.isInvalidate()?null:W.toString(),step:l},P,{ref:oi(R,t),className:I,value:ae,onChange:ke,disabled:d,readOnly:f}))))}),Dee=C.forwardRef(function(e,t){var n=e.disabled,r=e.style,o=e.prefixCls,i=o===void 0?"rc-input-number":o,a=e.value,s=e.prefix,l=e.suffix,c=e.addonBefore,u=e.addonAfter,d=e.className,f=e.classNames,h=tn(e,Mee),m=C.useRef(null),p=C.useRef(null),g=C.useRef(null),v=function(y){g.current&&bk(g.current,y)};return C.useImperativeHandle(t,function(){return Eee(g.current,{focus:v,nativeElement:m.current.nativeElement||p.current})}),C.createElement(xk,{className:d,triggerFocus:v,prefixCls:i,value:a,disabled:n,style:r,prefix:s,suffix:l,addonAfter:u,addonBefore:c,classNames:f,components:{affixWrapper:"div",groupWrapper:"div",wrapper:"div",groupAddon:"div"},ref:m},C.createElement(Nee,Qe({prefixCls:i,disabled:n,ref:g,domRef:p,className:f==null?void 0:f.input},h)))});const Tee=e=>{var t;const n=(t=e.handleVisible)!==null&&t!==void 0?t:"auto",r=e.controlHeightSM-e.lineWidth*2;return Object.assign(Object.assign({},_c(e)),{controlWidth:90,handleWidth:r,handleFontSize:e.fontSize/2,handleVisible:n,handleActiveBg:e.colorFillAlter,handleBg:e.colorBgContainer,filledHandleBg:new Sn(e.colorFillSecondary).onBackground(e.colorBgContainer).toHexString(),handleHoverColor:e.colorPrimary,handleBorderColor:e.colorBorder,handleOpacity:n===!0?1:0,handleVisibleWidth:n===!0?r:0})},vA=({componentCls:e,borderRadiusSM:t,borderRadiusLG:n},r)=>{const o=r==="lg"?n:t;return{[`&-${r}`]:{[`${e}-handler-wrap`]:{borderStartEndRadius:o,borderEndEndRadius:o},[`${e}-handler-up`]:{borderStartEndRadius:o},[`${e}-handler-down`]:{borderEndEndRadius:o}}}},Fee=e=>{const{componentCls:t,lineWidth:n,lineType:r,borderRadius:o,inputFontSizeSM:i,inputFontSizeLG:a,controlHeightLG:s,controlHeightSM:l,colorError:c,paddingInlineSM:u,paddingBlockSM:d,paddingBlockLG:f,paddingInlineLG:h,colorIcon:m,motionDurationMid:p,handleHoverColor:g,handleOpacity:v,paddingInline:y,paddingBlock:b,handleBg:w,handleActiveBg:x,colorTextDisabled:E,borderRadiusSM:k,borderRadiusLG:S,controlWidth:O,handleBorderColor:A,filledHandleBg:$,lineHeightLG:M,calc:N}=e;return[{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),jp(e)),{display:"inline-block",width:O,margin:0,padding:0,borderRadius:o}),fk(e,{[`${t}-handler-wrap`]:{background:w,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}}})),pk(e,{[`${t}-handler-wrap`]:{background:$,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}},"&:focus-within":{[`${t}-handler-wrap`]:{background:w}}})),gk(e,{[`${t}-handler-wrap`]:{background:w,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}}})),hk(e)),{"&-rtl":{direction:"rtl",[`${t}-input`]:{direction:"rtl"}},"&-lg":{padding:0,fontSize:a,lineHeight:M,borderRadius:S,[`input${t}-input`]:{height:N(s).sub(N(n).mul(2)).equal(),padding:`${Ce(f)} ${Ce(h)}`}},"&-sm":{padding:0,fontSize:i,borderRadius:k,[`input${t}-input`]:{height:N(l).sub(N(n).mul(2)).equal(),padding:`${Ce(d)} ${Ce(u)}`}},"&-out-of-range":{[`${t}-input-wrap`]:{input:{color:c}}},"&-group":Object.assign(Object.assign(Object.assign({},br(e)),OR(e)),{"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",textAlign:"start",verticalAlign:"top",[`${t}-affix-wrapper`]:{width:"100%"},"&-lg":{[`${t}-group-addon`]:{borderRadius:S,fontSize:e.fontSizeLG}},"&-sm":{[`${t}-group-addon`]:{borderRadius:k}}},wR(e)),kR(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}}})}),[`&-disabled ${t}-input`]:{cursor:"not-allowed"},[t]:{"&-input":Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{width:"100%",padding:`${Ce(b)} ${Ce(y)}`,textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:o,outline:0,transition:`all ${p} linear`,appearance:"textfield",fontSize:"inherit"}),mk(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}})},{[t]:Object.assign(Object.assign(Object.assign({[`${t}-handler-wrap`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleVisibleWidth,opacity:v,height:"100%",borderStartStartRadius:0,borderStartEndRadius:o,borderEndEndRadius:o,borderEndStartRadius:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`all ${p}`,overflow:"hidden",[`${t}-handler`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",[`
|
|
348
|
+
&${r}-slide-up-leave${r}-slide-up-leave-active${n}-dropdown-placement-bottomRight`]:{animationName:HC},[`${n}-panel > ${n}-time-panel`]:{paddingTop:A},[`${n}-range-wrapper`]:{display:"flex",position:"relative"},[`${n}-range-arrow`]:Object.assign(Object.assign({position:"absolute",zIndex:1,display:"none",paddingInline:e.calc(o).mul(1.5).equal(),boxSizing:"content-box",transition:`all ${S} ease-out`},DB(e,M,V)),{"&:before":{insetInlineStart:e.calc(o).mul(1.5).equal()}}),[`${n}-panel-container`]:{overflow:"hidden",verticalAlign:"top",background:M,borderRadius:N,boxShadow:D,transition:`margin ${S}`,display:"inline-block",pointerEvents:"auto",[`${n}-panel-layout`]:{display:"flex",flexWrap:"nowrap",alignItems:"stretch"},[`${n}-presets`]:{display:"flex",flexDirection:"column",minWidth:R,maxWidth:H,ul:{height:0,flex:"auto",listStyle:"none",overflow:"auto",margin:0,padding:b,borderInlineEnd:`${Ce(i)} ${a} ${P}`,li:Object.assign(Object.assign({},c0),{borderRadius:T,paddingInline:b,paddingBlock:e.calc(v).sub(L).div(2).equal(),cursor:"pointer",transition:`all ${S}`,"+ li":{marginTop:w},"&:hover":{background:I}})}},[`${n}-panels`]:{display:"inline-flex",flexWrap:"nowrap","&:last-child":{[`${n}-panel`]:{borderWidth:0}}},[`${n}-panel`]:{verticalAlign:"top",background:"transparent",borderRadius:0,borderWidth:0,[`${n}-content, table`]:{textAlign:"center"},"&-focused":{borderColor:s}}}}),"&-dropdown-range":{padding:`${Ce(e.calc($).mul(2).div(3).equal())} 0`,"&-hidden":{display:"none"}},"&-rtl":{direction:"rtl",[`${n}-separator`]:{transform:"scale(-1, 1)"},[`${n}-footer`]:{"&-extra":{direction:"rtl"}}}})},p0(e,"slide-up"),p0(e,"slide-down"),h0(e,"move-up"),h0(e,"move-down")]},DR=Pr("DatePicker",e=>{const t=Mn(Rc(e),tee(e),{inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[eee(t),aee(t),oee(t),iee(t),Z7(t),$d(e,{focusElCls:`${e.componentCls}-focused`})]},ree),TR=us({});var see=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function dA(e){return e==="auto"?"1 1 auto":typeof e=="number"?`${e} ${e} auto`:/^\d+(\.\d+)?(px|em|rem|%)$/.test(e)?`0 0 ${e}`:e}const lee=["xs","sm","md","lg","xl","xxl"],y0=C.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=C.useContext(pn),{gutter:o,wrap:i}=C.useContext(TR),{prefixCls:a,span:s,order:l,offset:c,push:u,pull:d,className:f,children:h,flex:m,style:p}=e,g=see(e,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),v=n("col",a),[y,b,w]=XX(v),x={};let E={};lee.forEach(O=>{let A={};const $=e[O];typeof $=="number"?A.span=$:typeof $=="object"&&(A=$||{}),delete g[O],E=Object.assign(Object.assign({},E),{[`${v}-${O}-${A.span}`]:A.span!==void 0,[`${v}-${O}-order-${A.order}`]:A.order||A.order===0,[`${v}-${O}-offset-${A.offset}`]:A.offset||A.offset===0,[`${v}-${O}-push-${A.push}`]:A.push||A.push===0,[`${v}-${O}-pull-${A.pull}`]:A.pull||A.pull===0,[`${v}-rtl`]:r==="rtl"}),A.flex&&(E[`${v}-${O}-flex`]=!0,x[`--${v}-${O}-flex`]=dA(A.flex))});const k=me(v,{[`${v}-${s}`]:s!==void 0,[`${v}-order-${l}`]:l,[`${v}-offset-${c}`]:c,[`${v}-push-${u}`]:u,[`${v}-pull-${d}`]:d},f,E,b,w),S={};if(o!=null&&o[0]){const O=typeof o[0]=="number"?`${o[0]/2}px`:`calc(${o[0]} / 2)`;S.paddingLeft=O,S.paddingRight=O}return m&&(S.flex=dA(m),i===!1&&!S.minWidth&&(S.minWidth=0)),y(C.createElement("div",Object.assign({},g,{style:Object.assign(Object.assign(Object.assign({},S),p),x),className:k,ref:t}),h))});function cee(e,t){const n=[void 0,void 0],r=Array.isArray(e)?e:[e,void 0],o=t||{xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0};return r.forEach((i,a)=>{if(typeof i=="object"&&i!==null)for(let s=0;s<rd.length;s++){const l=rd[s];if(o[l]&&i[l]!==void 0){n[a]=i[l];break}}else n[a]=i}),n}var uee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function fA(e,t){const[n,r]=C.useState(typeof e=="string"?e:""),o=()=>{if(typeof e=="string"&&r(e),typeof e=="object")for(let i=0;i<rd.length;i++){const a=rd[i];if(!t||!t[a])continue;const s=e[a];if(s!==void 0){r(s);return}}};return C.useEffect(()=>{o()},[JSON.stringify(e),t]),n}const FR=C.forwardRef((e,t)=>{const{prefixCls:n,justify:r,align:o,className:i,style:a,children:s,gutter:l=0,wrap:c}=e,u=uee(e,["prefixCls","justify","align","className","style","children","gutter","wrap"]),{getPrefixCls:d,direction:f}=C.useContext(pn),h=vQ(!0,null),m=fA(o,h),p=fA(r,h),g=d("row",n),[v,y,b]=qX(g),w=cee(l,h),x=me(g,{[`${g}-no-wrap`]:c===!1,[`${g}-${p}`]:p,[`${g}-${m}`]:m,[`${g}-rtl`]:f==="rtl"},i,y,b),E={};if(w!=null&&w[0]){const A=typeof w[0]=="number"?`${w[0]/-2}px`:`calc(${w[0]} / -2)`;E.marginLeft=A,E.marginRight=A}const[k,S]=w;E.rowGap=S;const O=C.useMemo(()=>({gutter:[k,S],wrap:c}),[k,S,c]);return v(C.createElement(TR.Provider,{value:O},C.createElement("div",Object.assign({},u,{className:x,style:Object.assign(Object.assign({},E),a),ref:t}),s)))});var dee={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"},fee=function(e,t){return C.createElement(zr,Qe({},e,{ref:t,icon:dee}))},hee=C.forwardRef(fee);function tw(){return typeof BigInt=="function"}function PR(e){return!e&&e!==0&&!Number.isNaN(e)||!String(e).trim()}function Us(e){var t=e.trim(),n=t.startsWith("-");n&&(t=t.slice(1)),t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),t.startsWith(".")&&(t="0".concat(t));var r=t||"0",o=r.split("."),i=o[0]||"0",a=o[1]||"0";i==="0"&&a==="0"&&(n=!1);var s=n?"-":"";return{negative:n,negativeStr:s,trimStr:r,integerStr:i,decimalStr:a,fullStr:"".concat(s).concat(r)}}function vk(e){var t=String(e);return!Number.isNaN(Number(t))&&t.includes("e")}function _s(e){var t=String(e);if(vk(e)){var n=Number(t.slice(t.indexOf("e-")+2)),r=t.match(/\.(\d+)/);return r!=null&&r[1]&&(n+=r[1].length),n}return t.includes(".")&&yk(t)?t.length-t.indexOf(".")-1:0}function Lp(e){var t=String(e);if(vk(e)){if(e>Number.MAX_SAFE_INTEGER)return String(tw()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(e<Number.MIN_SAFE_INTEGER)return String(tw()?BigInt(e).toString():Number.MIN_SAFE_INTEGER);t=e.toFixed(_s(t))}return Us(t).fullStr}function yk(e){return typeof e=="number"?!Number.isNaN(e):e?/^\s*-?\d+(\.\d+)?\s*$/.test(e)||/^\s*-?\d+\.\s*$/.test(e)||/^\s*-?\.\d+\s*$/.test(e):!1}var pee=(function(){function e(t){if(xr(this,e),X(this,"origin",""),X(this,"negative",void 0),X(this,"integer",void 0),X(this,"decimal",void 0),X(this,"decimalLen",void 0),X(this,"empty",void 0),X(this,"nan",void 0),PR(t)){this.empty=!0;return}if(this.origin=String(t),t==="-"||Number.isNaN(t)){this.nan=!0;return}var n=t;if(vk(n)&&(n=Number(n)),n=typeof n=="string"?n:Lp(n),yk(n)){var r=Us(n);this.negative=r.negative;var o=r.trimStr.split(".");this.integer=BigInt(o[0]);var i=o[1]||"0";this.decimal=BigInt(i),this.decimalLen=i.length}else this.nan=!0}return Er(e,[{key:"getMark",value:function(){return this.negative?"-":""}},{key:"getIntegerStr",value:function(){return this.integer.toString()}},{key:"getDecimalStr",value:function(){return this.decimal.toString().padStart(this.decimalLen,"0")}},{key:"alignDecimal",value:function(t){var n="".concat(this.getMark()).concat(this.getIntegerStr()).concat(this.getDecimalStr().padEnd(t,"0"));return BigInt(n)}},{key:"negate",value:function(){var t=new e(this.toString());return t.negative=!t.negative,t}},{key:"cal",value:function(t,n,r){var o=Math.max(this.getDecimalStr().length,t.getDecimalStr().length),i=this.alignDecimal(o),a=t.alignDecimal(o),s=n(i,a).toString(),l=r(o),c=Us(s),u=c.negativeStr,d=c.trimStr,f="".concat(u).concat(d.padStart(l+1,"0"));return new e("".concat(f.slice(0,-l),".").concat(f.slice(-l)))}},{key:"add",value:function(t){if(this.isInvalidate())return new e(t);var n=new e(t);return n.isInvalidate()?this:this.cal(n,function(r,o){return r+o},function(r){return r})}},{key:"multi",value:function(t){var n=new e(t);return this.isInvalidate()||n.isInvalidate()?new e(NaN):this.cal(n,function(r,o){return r*o},function(r){return r*2})}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return this.nan}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(t){return this.toString()===(t==null?void 0:t.toString())}},{key:"lessEquals",value:function(t){return this.add(t.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t?this.isInvalidate()?"":Us("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e})(),gee=(function(){function e(t){if(xr(this,e),X(this,"origin",""),X(this,"number",void 0),X(this,"empty",void 0),PR(t)){this.empty=!0;return}this.origin=String(t),this.number=Number(t)}return Er(e,[{key:"negate",value:function(){return new e(-this.toNumber())}},{key:"add",value:function(t){if(this.isInvalidate())return new e(t);var n=Number(t);if(Number.isNaN(n))return this;var r=this.number+n;if(r>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(r<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var o=Math.max(_s(this.number),_s(n));return new e(r.toFixed(o))}},{key:"multi",value:function(t){var n=Number(t);if(this.isInvalidate()||Number.isNaN(n))return new e(NaN);var r=this.number*n;if(r>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(r<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var o=Math.max(_s(this.number),_s(n));return new e(r.toFixed(o))}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return Number.isNaN(this.number)}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(t){return this.toNumber()===(t==null?void 0:t.toNumber())}},{key:"lessEquals",value:function(t){return this.add(t.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.number}},{key:"toString",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t?this.isInvalidate()?"":Lp(this.number):this.origin}}]),e})();function gi(e){return tw()?new pee(e):new gee(e)}function ch(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(e==="")return"";var o=Us(e),i=o.negativeStr,a=o.integerStr,s=o.decimalStr,l="".concat(t).concat(s),c="".concat(i).concat(a);if(n>=0){var u=Number(s[n]);if(u>=5&&!r){var d=gi(e).add("".concat(i,"0.").concat("0".repeat(n)).concat(10-u));return ch(d.toString(),t,n,r)}return n===0?c:"".concat(c).concat(t).concat(s.padEnd(n,"0").slice(0,n))}return l===".0"?c:"".concat(c).concat(l)}function mee(e){return!!(e.addonBefore||e.addonAfter)}function vee(e){return!!(e.prefix||e.suffix||e.allowClear)}function hA(e,t,n){var r=t.cloneNode(!0),o=Object.create(e,{target:{value:r},currentTarget:{value:r}});return r.value=n,typeof t.selectionStart=="number"&&typeof t.selectionEnd=="number"&&(r.selectionStart=t.selectionStart,r.selectionEnd=t.selectionEnd),r.setSelectionRange=function(){t.setSelectionRange.apply(t,arguments)},o}function b0(e,t,n,r){if(n){var o=t;if(t.type==="click"){o=hA(t,e,""),n(o);return}if(e.type!=="file"&&r!==void 0){o=hA(t,e,r),n(o);return}n(o)}}function bk(e,t){if(e){e.focus(t);var n=t||{},r=n.cursor;if(r){var o=e.value.length;switch(r){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(o,o);break;default:e.setSelectionRange(0,o)}}}}var xk=we.forwardRef(function(e,t){var n,r,o,i=e.inputElement,a=e.children,s=e.prefixCls,l=e.prefix,c=e.suffix,u=e.addonBefore,d=e.addonAfter,f=e.className,h=e.style,m=e.disabled,p=e.readOnly,g=e.focused,v=e.triggerFocus,y=e.allowClear,b=e.value,w=e.handleReset,x=e.hidden,E=e.classes,k=e.classNames,S=e.dataAttrs,O=e.styles,A=e.components,$=e.onClear,M=a??i,N=(A==null?void 0:A.affixWrapper)||"span",D=(A==null?void 0:A.groupWrapper)||"span",T=(A==null?void 0:A.wrapper)||"span",P=(A==null?void 0:A.groupAddon)||"span",I=et(null),R=function(re){var oe;(oe=I.current)!==null&&oe!==void 0&&oe.contains(re.target)&&(v==null||v())},H=vee(e),V=OF(M,{value:b,className:me((n=M.props)===null||n===void 0?void 0:n.className,!H&&(k==null?void 0:k.variant))||null}),L=et(null);if(we.useImperativeHandle(t,function(){return{nativeElement:L.current||I.current}}),H){var j=null;if(y){var _=!m&&!p&&b,F="".concat(s,"-clear-icon"),B=At(y)==="object"&&y!==null&&y!==void 0&&y.clearIcon?y.clearIcon:"\u2716";j=we.createElement("button",{type:"button",tabIndex:-1,onClick:function(re){w==null||w(re),$==null||$()},onMouseDown:function(re){return re.preventDefault()},className:me(F,X(X({},"".concat(F,"-hidden"),!_),"".concat(F,"-has-suffix"),!!c))},B)}var z="".concat(s,"-affix-wrapper"),G=me(z,X(X(X(X(X({},"".concat(s,"-disabled"),m),"".concat(z,"-disabled"),m),"".concat(z,"-focused"),g),"".concat(z,"-readonly"),p),"".concat(z,"-input-with-clear-btn"),c&&y&&b),E==null?void 0:E.affixWrapper,k==null?void 0:k.affixWrapper,k==null?void 0:k.variant),W=(c||y)&&we.createElement("span",{className:me("".concat(s,"-suffix"),k==null?void 0:k.suffix),style:O==null?void 0:O.suffix},j,c);V=we.createElement(N,Qe({className:G,style:O==null?void 0:O.affixWrapper,onClick:R},S==null?void 0:S.affixWrapper,{ref:I}),l&&we.createElement("span",{className:me("".concat(s,"-prefix"),k==null?void 0:k.prefix),style:O==null?void 0:O.prefix},l),V,W)}if(mee(e)){var q="".concat(s,"-group"),U="".concat(q,"-addon"),Y="".concat(q,"-wrapper"),ie=me("".concat(s,"-wrapper"),q,E==null?void 0:E.wrapper,k==null?void 0:k.wrapper),K=me(Y,X({},"".concat(Y,"-disabled"),m),E==null?void 0:E.group,k==null?void 0:k.groupWrapper);V=we.createElement(D,{className:K,ref:L},we.createElement(T,{className:ie},u&&we.createElement(P,{className:U},u),V,d&&we.createElement(P,{className:U},d)))}return we.cloneElement(V,{className:me((r=V.props)===null||r===void 0?void 0:r.className,f)||null,style:Q(Q({},(o=V.props)===null||o===void 0?void 0:o.style),h),hidden:x})}),yee=["show"];function IR(e,t){return C.useMemo(function(){var n={};t&&(n.show=At(t)==="object"&&t.formatter?t.formatter:!!t),n=Q(Q({},n),e);var r=n,o=r.show,i=tn(r,yee);return Q(Q({},i),{},{show:!!o,showFormatter:typeof o=="function"?o:void 0,strategy:i.strategy||function(a){return a.length}})},[e,t])}var bee=["autoComplete","onChange","onFocus","onBlur","onPressEnter","onKeyDown","onKeyUp","prefixCls","disabled","htmlSize","className","maxLength","suffix","showCount","count","type","classes","classNames","styles","onCompositionStart","onCompositionEnd"],xee=Oi(function(e,t){var n=e.autoComplete,r=e.onChange,o=e.onFocus,i=e.onBlur,a=e.onPressEnter,s=e.onKeyDown,l=e.onKeyUp,c=e.prefixCls,u=c===void 0?"rc-input":c,d=e.disabled,f=e.htmlSize,h=e.className,m=e.maxLength,p=e.suffix,g=e.showCount,v=e.count,y=e.type,b=y===void 0?"text":y,w=e.classes,x=e.classNames,E=e.styles,k=e.onCompositionStart,S=e.onCompositionEnd,O=tn(e,bee),A=nt(!1),$=te(A,2),M=$[0],N=$[1],D=et(!1),T=et(!1),P=et(null),I=et(null),R=function(ce){P.current&&bk(P.current,ce)},H=yr(e.defaultValue,{value:e.value}),V=te(H,2),L=V[0],j=V[1],_=L==null?"":String(L),F=nt(null),B=te(F,2),z=B[0],G=B[1],W=IR(v,g),q=W.max||m,U=W.strategy(_),Y=!!q&&U>q;Oc(t,function(){var ce;return{focus:R,blur:function(){var he;(he=P.current)===null||he===void 0||he.blur()},setSelectionRange:function(he,Te,se){var Pe;(Pe=P.current)===null||Pe===void 0||Pe.setSelectionRange(he,Te,se)},select:function(){var he;(he=P.current)===null||he===void 0||he.select()},input:P.current,nativeElement:((ce=I.current)===null||ce===void 0?void 0:ce.nativeElement)||P.current}}),Et(function(){T.current&&(T.current=!1),N(function(ce){return ce&&d?!1:ce})},[d]);var ie=function(ce,he,Te){var se=he;if(!D.current&&W.exceedFormatter&&W.max&&W.strategy(he)>W.max){if(se=W.exceedFormatter(he,{max:W.max}),he!==se){var Pe,De;G([((Pe=P.current)===null||Pe===void 0?void 0:Pe.selectionStart)||0,((De=P.current)===null||De===void 0?void 0:De.selectionEnd)||0])}}else if(Te.source==="compositionEnd")return;j(se),P.current&&b0(P.current,ce,r,se)};Et(function(){if(z){var ce;(ce=P.current)===null||ce===void 0||ce.setSelectionRange.apply(ce,ze(z))}},[z]);var K=function(ce){ie(ce,ce.target.value,{source:"change"})},re=function(ce){D.current=!1,ie(ce,ce.currentTarget.value,{source:"compositionEnd"}),S==null||S(ce)},oe=function(ce){a&&ce.key==="Enter"&&!T.current&&(T.current=!0,a(ce)),s==null||s(ce)},ne=function(ce){ce.key==="Enter"&&(T.current=!1),l==null||l(ce)},ae=function(ce){N(!0),o==null||o(ce)},de=function(ce){T.current&&(T.current=!1),N(!1),i==null||i(ce)},ge=function(ce){j(""),R(),P.current&&b0(P.current,ce,r)},Se=Y&&"".concat(u,"-out-of-range"),ye=function(){var ce=ta(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames","onClear"]);return we.createElement("input",Qe({autoComplete:n},ce,{onChange:K,onFocus:ae,onBlur:de,onKeyDown:oe,onKeyUp:ne,className:me(u,X({},"".concat(u,"-disabled"),d),x==null?void 0:x.input),style:E==null?void 0:E.input,ref:P,size:f,type:b,onCompositionStart:function(he){D.current=!0,k==null||k(he)},onCompositionEnd:re}))},be=function(){var ce=Number(q)>0;if(p||W.show){var he=W.showFormatter?W.showFormatter({value:_,count:U,maxLength:q}):"".concat(U).concat(ce?" / ".concat(q):"");return we.createElement(we.Fragment,null,W.show&&we.createElement("span",{className:me("".concat(u,"-show-count-suffix"),X({},"".concat(u,"-show-count-has-suffix"),!!p),x==null?void 0:x.count),style:Q({},E==null?void 0:E.count)},he),p)}return null};return we.createElement(xk,Qe({},O,{prefixCls:u,className:me(h,Se),handleReset:ge,value:_,focused:M,triggerFocus:R,suffix:be(),disabled:d,classes:w,classNames:x,styles:E,ref:I}),ye())});function Eee(e,t){return typeof Proxy<"u"&&e?new Proxy(e,{get:function(n,r){if(t[r])return t[r];var o=n[r];return typeof o=="function"?o.bind(n):o}}):e}function wee(e,t){var n=et(null);function r(){try{var i=e.selectionStart,a=e.selectionEnd,s=e.value,l=s.substring(0,i),c=s.substring(a);n.current={start:i,end:a,value:s,beforeTxt:l,afterTxt:c}}catch{}}function o(){if(e&&n.current&&t)try{var i=e.value,a=n.current,s=a.beforeTxt,l=a.afterTxt,c=a.start,u=i.length;if(i.startsWith(s))u=s.length;else if(i.endsWith(l))u=i.length-n.current.afterTxt.length;else{var d=s[c-1],f=i.indexOf(d,c-1);f!==-1&&(u=f+1)}e.setSelectionRange(u,u)}catch(h){qr(!1,"Something warning of cursor restore. Please fire issue about this: ".concat(h.message))}}return[r,o]}var Cee=function(){var e=nt(!1),t=te(e,2),n=t[0],r=t[1];return mn(function(){r(JC())},[]),n},kee=200,See=600;function Aee(e){var t=e.prefixCls,n=e.upNode,r=e.downNode,o=e.upDisabled,i=e.downDisabled,a=e.onStep,s=C.useRef(),l=C.useRef([]),c=C.useRef();c.current=a;var u=function(){clearTimeout(s.current)},d=function(y,b){y.preventDefault(),u(),c.current(b);function w(){c.current(b),s.current=setTimeout(w,kee)}s.current=setTimeout(w,See)};C.useEffect(function(){return function(){u(),l.current.forEach(function(y){return en.cancel(y)})}},[]);var f=Cee();if(f)return null;var h="".concat(t,"-handler"),m=me(h,"".concat(h,"-up"),X({},"".concat(h,"-up-disabled"),o)),p=me(h,"".concat(h,"-down"),X({},"".concat(h,"-down-disabled"),i)),g=function(){return l.current.push(en(u))},v={unselectable:"on",role:"button",onMouseUp:g,onMouseLeave:g};return C.createElement("div",{className:"".concat(h,"-wrap")},C.createElement("span",Qe({},v,{onMouseDown:function(y){d(y,!0)},"aria-label":"Increase Value","aria-disabled":o,className:m}),n||C.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-up-inner")})),C.createElement("span",Qe({},v,{onMouseDown:function(y){d(y,!1)},"aria-label":"Decrease Value","aria-disabled":i,className:p}),r||C.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-down-inner")})))}function pA(e){var t=typeof e=="number"?Lp(e):Us(e).fullStr,n=t.includes(".");return n?Us(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}const $ee=(function(){var e=et(0),t=function(){en.cancel(e.current)};return Et(function(){return t},[]),function(n){t(),e.current=en(function(){n()})}});var Oee=["prefixCls","className","style","min","max","step","defaultValue","value","disabled","readOnly","upHandler","downHandler","keyboard","changeOnWheel","controls","classNames","stringMode","parser","formatter","precision","decimalSeparator","onChange","onInput","onPressEnter","onStep","changeOnBlur","domRef"],Mee=["disabled","style","prefixCls","value","prefix","suffix","addonBefore","addonAfter","className","classNames"],gA=function(e,t){return e||t.isEmpty()?t.toString():t.toNumber()},mA=function(e){var t=gi(e);return t.isInvalidate()?null:t},Nee=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.className,o=e.style,i=e.min,a=e.max,s=e.step,l=s===void 0?1:s,c=e.defaultValue,u=e.value,d=e.disabled,f=e.readOnly,h=e.upHandler,m=e.downHandler,p=e.keyboard,g=e.changeOnWheel,v=g===void 0?!1:g,y=e.controls,b=y===void 0?!0:y,w=e.stringMode,x=e.parser,E=e.formatter,k=e.precision,S=e.decimalSeparator,O=e.onChange,A=e.onInput,$=e.onPressEnter,M=e.onStep,N=e.changeOnBlur,D=N===void 0?!0:N,T=e.domRef,P=tn(e,Oee),I="".concat(n,"-input"),R=C.useRef(null),H=C.useState(!1),V=te(H,2),L=V[0],j=V[1],_=C.useRef(!1),F=C.useRef(!1),B=C.useRef(!1),z=C.useState(function(){return gi(u??c)}),G=te(z,2),W=G[0],q=G[1];function U(Ge){u===void 0&&q(Ge)}var Y=C.useCallback(function(Ge,Xe){if(!Xe)return k>=0?k:Math.max(_s(Ge),_s(l))},[k,l]),ie=C.useCallback(function(Ge){var Xe=String(Ge);if(x)return x(Xe);var qe=Xe;return S&&(qe=qe.replace(S,".")),qe.replace(/[^\w.-]+/g,"")},[x,S]),K=C.useRef(""),re=C.useCallback(function(Ge,Xe){if(E)return E(Ge,{userTyping:Xe,input:String(K.current)});var qe=typeof Ge=="number"?Lp(Ge):Ge;if(!Xe){var lt=Y(qe,Xe);if(yk(qe)&&(S||lt>=0)){var je=S||".";qe=ch(qe,je,lt)}}return qe},[E,Y,S]),oe=C.useState(function(){var Ge=c??u;return W.isInvalidate()&&["string","number"].includes(At(Ge))?Number.isNaN(Ge)?"":Ge:re(W.toString(),!1)}),ne=te(oe,2),ae=ne[0],de=ne[1];K.current=ae;function ge(Ge,Xe){de(re(Ge.isInvalidate()?Ge.toString(!1):Ge.toString(!Xe),Xe))}var Se=C.useMemo(function(){return mA(a)},[a,k]),ye=C.useMemo(function(){return mA(i)},[i,k]),be=C.useMemo(function(){return!Se||!W||W.isInvalidate()?!1:Se.lessEquals(W)},[Se,W]),ce=C.useMemo(function(){return!ye||!W||W.isInvalidate()?!1:W.lessEquals(ye)},[ye,W]),he=wee(R.current,L),Te=te(he,2),se=Te[0],Pe=Te[1],De=function(Ge){return Se&&!Ge.lessEquals(Se)?Se:ye&&!ye.lessEquals(Ge)?ye:null},He=function(Ge){return!De(Ge)},ue=function(Ge,Xe){var qe=Ge,lt=He(qe)||qe.isEmpty();if(!qe.isEmpty()&&!Xe&&(qe=De(qe)||qe,lt=!0),!f&&!d&<){var je=qe.toString(),Rt=Y(je,Xe);return Rt>=0&&(qe=gi(ch(je,".",Rt)),He(qe)||(qe=gi(ch(je,".",Rt,!0)))),qe.equals(W)||(U(qe),O==null||O(qe.isEmpty()?null:gA(w,qe)),u===void 0&&ge(qe,Xe)),qe}return W},ve=$ee(),xe=function Ge(Xe){if(se(),K.current=Xe,de(Xe),!F.current){var qe=ie(Xe),lt=gi(qe);lt.isNaN()||ue(lt,!0)}A==null||A(Xe),ve(function(){var je=Xe;x||(je=Xe.replace(/。/g,".")),je!==Xe&&Ge(je)})},fe=function(){F.current=!0},pe=function(){F.current=!1,xe(R.current.value)},ke=function(Ge){xe(Ge.target.value)},Ve=function(Ge){var Xe;if(!(Ge&&be||!Ge&&ce)){_.current=!1;var qe=gi(B.current?pA(l):l);Ge||(qe=qe.negate());var lt=(W||gi(0)).add(qe.toString()),je=ue(lt,!1);M==null||M(gA(w,je),{offset:B.current?pA(l):l,type:Ge?"up":"down"}),(Xe=R.current)===null||Xe===void 0||Xe.focus()}},Ee=function(Ge){var Xe=gi(ie(ae)),qe;Xe.isNaN()?qe=ue(W,Ge):qe=ue(Xe,Ge),u!==void 0?ge(W,!1):qe.isNaN()||ge(qe,!1)},yt=function(){_.current=!0},Dt=function(Ge){var Xe=Ge.key,qe=Ge.shiftKey;_.current=!0,B.current=qe,Xe==="Enter"&&(F.current||(_.current=!1),Ee(!1),$==null||$(Ge)),p!==!1&&!F.current&&["Up","ArrowUp","Down","ArrowDown"].includes(Xe)&&(Ve(Xe==="Up"||Xe==="ArrowUp"),Ge.preventDefault())},Pt=function(){_.current=!1,B.current=!1};C.useEffect(function(){if(v&&L){var Ge=function(qe){Ve(qe.deltaY<0),qe.preventDefault()},Xe=R.current;if(Xe)return Xe.addEventListener("wheel",Ge,{passive:!1}),function(){return Xe.removeEventListener("wheel",Ge)}}});var Ut=function(){D&&Ee(!1),j(!1),_.current=!1};return nc(function(){W.isInvalidate()||ge(W,!1)},[k,E]),nc(function(){var Ge=gi(u);q(Ge);var Xe=gi(ie(ae));(!Ge.equals(Xe)||!_.current||E)&&ge(Ge,_.current)},[u]),nc(function(){E&&Pe()},[ae]),C.createElement("div",{ref:T,className:me(n,r,X(X(X(X(X({},"".concat(n,"-focused"),L),"".concat(n,"-disabled"),d),"".concat(n,"-readonly"),f),"".concat(n,"-not-a-number"),W.isNaN()),"".concat(n,"-out-of-range"),!W.isInvalidate()&&!He(W))),style:o,onFocus:function(){j(!0)},onBlur:Ut,onKeyDown:Dt,onKeyUp:Pt,onCompositionStart:fe,onCompositionEnd:pe,onBeforeInput:yt},b&&C.createElement(Aee,{prefixCls:n,upNode:h,downNode:m,upDisabled:be,downDisabled:ce,onStep:Ve}),C.createElement("div",{className:"".concat(I,"-wrap")},C.createElement("input",Qe({autoComplete:"off",role:"spinbutton","aria-valuemin":i,"aria-valuemax":a,"aria-valuenow":W.isInvalidate()?null:W.toString(),step:l},P,{ref:oi(R,t),className:I,value:ae,onChange:ke,disabled:d,readOnly:f}))))}),Dee=C.forwardRef(function(e,t){var n=e.disabled,r=e.style,o=e.prefixCls,i=o===void 0?"rc-input-number":o,a=e.value,s=e.prefix,l=e.suffix,c=e.addonBefore,u=e.addonAfter,d=e.className,f=e.classNames,h=tn(e,Mee),m=C.useRef(null),p=C.useRef(null),g=C.useRef(null),v=function(y){g.current&&bk(g.current,y)};return C.useImperativeHandle(t,function(){return Eee(g.current,{focus:v,nativeElement:m.current.nativeElement||p.current})}),C.createElement(xk,{className:d,triggerFocus:v,prefixCls:i,value:a,disabled:n,style:r,prefix:s,suffix:l,addonAfter:u,addonBefore:c,classNames:f,components:{affixWrapper:"div",groupWrapper:"div",wrapper:"div",groupAddon:"div"},ref:m},C.createElement(Nee,Qe({prefixCls:i,disabled:n,ref:g,domRef:p,className:f==null?void 0:f.input},h)))});const Tee=e=>{var t;const n=(t=e.handleVisible)!==null&&t!==void 0?t:"auto",r=e.controlHeightSM-e.lineWidth*2;return Object.assign(Object.assign({},_c(e)),{controlWidth:90,handleWidth:r,handleFontSize:e.fontSize/2,handleVisible:n,handleActiveBg:e.colorFillAlter,handleBg:e.colorBgContainer,filledHandleBg:new Sn(e.colorFillSecondary).onBackground(e.colorBgContainer).toHexString(),handleHoverColor:e.colorPrimary,handleBorderColor:e.colorBorder,handleOpacity:n===!0?1:0,handleVisibleWidth:n===!0?r:0})},vA=({componentCls:e,borderRadiusSM:t,borderRadiusLG:n},r)=>{const o=r==="lg"?n:t;return{[`&-${r}`]:{[`${e}-handler-wrap`]:{borderStartEndRadius:o,borderEndEndRadius:o},[`${e}-handler-up`]:{borderStartEndRadius:o},[`${e}-handler-down`]:{borderEndEndRadius:o}}}},Fee=e=>{const{componentCls:t,lineWidth:n,lineType:r,borderRadius:o,inputFontSizeSM:i,inputFontSizeLG:a,controlHeightLG:s,controlHeightSM:l,colorError:c,paddingInlineSM:u,paddingBlockSM:d,paddingBlockLG:f,paddingInlineLG:h,colorIcon:m,motionDurationMid:p,handleHoverColor:g,handleOpacity:v,paddingInline:y,paddingBlock:b,handleBg:w,handleActiveBg:x,colorTextDisabled:E,borderRadiusSM:k,borderRadiusLG:S,controlWidth:O,handleBorderColor:A,filledHandleBg:$,lineHeightLG:M,calc:N}=e;return[{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),jp(e)),{display:"inline-block",width:O,margin:0,padding:0,borderRadius:o}),fk(e,{[`${t}-handler-wrap`]:{background:w,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}}})),pk(e,{[`${t}-handler-wrap`]:{background:$,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}},"&:focus-within":{[`${t}-handler-wrap`]:{background:w}}})),gk(e,{[`${t}-handler-wrap`]:{background:w,[`${t}-handler-down`]:{borderBlockStart:`${Ce(n)} ${r} ${A}`}}})),hk(e)),{"&-rtl":{direction:"rtl",[`${t}-input`]:{direction:"rtl"}},"&-lg":{padding:0,fontSize:a,lineHeight:M,borderRadius:S,[`input${t}-input`]:{height:N(s).sub(N(n).mul(2)).equal(),padding:`${Ce(f)} ${Ce(h)}`}},"&-sm":{padding:0,fontSize:i,borderRadius:k,[`input${t}-input`]:{height:N(l).sub(N(n).mul(2)).equal(),padding:`${Ce(d)} ${Ce(u)}`}},"&-out-of-range":{[`${t}-input-wrap`]:{input:{color:c}}},"&-group":Object.assign(Object.assign(Object.assign({},br(e)),OR(e)),{"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",textAlign:"start",verticalAlign:"top",[`${t}-affix-wrapper`]:{width:"100%"},"&-lg":{[`${t}-group-addon`]:{borderRadius:S,fontSize:e.fontSizeLG}},"&-sm":{[`${t}-group-addon`]:{borderRadius:k}}},wR(e)),kR(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}}})}),[`&-disabled ${t}-input`]:{cursor:"not-allowed"},[t]:{"&-input":Object.assign(Object.assign(Object.assign(Object.assign({},br(e)),{width:"100%",padding:`${Ce(b)} ${Ce(y)}`,textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:o,outline:0,transition:`all ${p} linear`,appearance:"textfield",fontSize:"inherit"}),mk(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}})},{[t]:Object.assign(Object.assign(Object.assign({[`${t}-handler-wrap`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleVisibleWidth,opacity:v,height:"100%",borderStartStartRadius:0,borderStartEndRadius:o,borderEndEndRadius:o,borderEndStartRadius:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`all ${p}`,overflow:"hidden",[`${t}-handler`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",[`
|
|
349
349
|
${t}-handler-up-inner,
|
|
350
350
|
${t}-handler-down-inner
|
|
351
351
|
`]:{marginInlineEnd:0,fontSize:e.handleFontSize}}},[`${t}-handler`]:{height:"50%",overflow:"hidden",color:m,fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",borderInlineStart:`${Ce(n)} ${r} ${A}`,transition:`all ${p} linear`,"&:active":{background:x},"&:hover":{height:"60%",[`
|
|
@@ -357,7 +357,7 @@ html body {
|
|
|
357
357
|
`]:{cursor:"not-allowed"},[`
|
|
358
358
|
${t}-handler-up-disabled:hover &-handler-up-inner,
|
|
359
359
|
${t}-handler-down-disabled:hover &-handler-down-inner
|
|
360
|
-
`]:{color:E}})}]},Pee=e=>{const{componentCls:t,paddingBlock:n,paddingInline:r,inputAffixPadding:o,controlWidth:i,borderRadiusLG:a,borderRadiusSM:s,paddingInlineLG:l,paddingInlineSM:c,paddingBlockLG:u,paddingBlockSM:d,motionDurationMid:f}=e;return{[`${t}-affix-wrapper`]:Object.assign(Object.assign({[`input${t}-input`]:{padding:`${Ce(n)} 0`}},jp(e)),{position:"relative",display:"inline-flex",alignItems:"center",width:i,padding:0,paddingInlineStart:r,"&-lg":{borderRadius:a,paddingInlineStart:l,[`input${t}-input`]:{padding:`${Ce(u)} 0`}},"&-sm":{borderRadius:s,paddingInlineStart:c,[`input${t}-input`]:{padding:`${Ce(d)} 0`}},[`&:not(${t}-disabled):hover`]:{zIndex:1},"&-focused, &:focus":{zIndex:1},[`&-disabled > ${t}-disabled`]:{background:"transparent"},[`> div${t}`]:{width:"100%",border:"none",outline:"none",[`&${t}-focused`]:{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[`${t}-handler-wrap`]:{zIndex:2},[t]:{position:"static",color:"inherit","&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center",pointerEvents:"none"},"&-prefix":{marginInlineEnd:o},"&-suffix":{insetBlockStart:0,insetInlineEnd:0,height:"100%",marginInlineEnd:r,marginInlineStart:o,transition:`margin ${f}`}},[`&:hover ${t}-handler-wrap, &-focused ${t}-handler-wrap`]:{width:e.handleWidth,opacity:1},[`&:not(${t}-affix-wrapper-without-controls):hover ${t}-suffix`]:{marginInlineEnd:e.calc(e.handleWidth).add(r).equal()}}),[`${t}-underlined`]:{borderRadius:0}}},Iee=Pr("InputNumber",e=>{const t=Mn(e,Rc(e));return[Fee(t),Pee(t),$d(t)]},Tee,{unitless:{handleOpacity:!0},resetFont:!1});var Bee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const BR=C.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=C.useContext(pn),o=C.useRef(null);C.useImperativeHandle(t,()=>o.current);const{className:i,rootClassName:a,size:s,disabled:l,prefixCls:c,addonBefore:u,addonAfter:d,prefix:f,suffix:h,bordered:m,readOnly:p,status:g,controls:v,variant:y}=e,b=Bee(e,["className","rootClassName","size","disabled","prefixCls","addonBefore","addonAfter","prefix","suffix","bordered","readOnly","status","controls","variant"]),w=n("input-number",c),x=Ro(w),[E,k,S]=Iee(w,x),{compactSize:O,compactItemClassnames:A}=ps(w,r);let $=C.createElement(hee,{className:`${w}-handler-up-inner`}),M=C.createElement(SB,{className:`${w}-handler-down-inner`});const N=typeof v=="boolean"?v:void 0;typeof v=="object"&&($=typeof v.upIcon>"u"?$:C.createElement("span",{className:`${w}-handler-up-inner`},v.upIcon),M=typeof v.downIcon>"u"?M:C.createElement("span",{className:`${w}-handler-down-inner`},v.downIcon));const{hasFeedback:D,status:T,isFormItemInput:P,feedbackIcon:I}=C.useContext(Yr),R=pl(T,g),H=ai(W=>{var q;return(q=s??O)!==null&&q!==void 0?q:W}),V=C.useContext(vo),L=l??V,[j,_]=Pc("inputNumber",y,m),F=D&&C.createElement(C.Fragment,null,I),B=me({[`${w}-lg`]:H==="large",[`${w}-sm`]:H==="small",[`${w}-rtl`]:r==="rtl",[`${w}-in-form-item`]:P},k),z=`${w}-group`,G=C.createElement(Dee,Object.assign({ref:o,disabled:L,className:me(S,x,i,a,A),upHandler:$,downHandler:M,prefixCls:w,readOnly:p,controls:N,prefix:f,suffix:F||h,addonBefore:u&&C.createElement(ts,{form:!0,space:!0},u),addonAfter:d&&C.createElement(ts,{form:!0,space:!0},d),classNames:{input:B,variant:me({[`${w}-${j}`]:_},ns(w,R,D)),affixWrapper:me({[`${w}-affix-wrapper-sm`]:H==="small",[`${w}-affix-wrapper-lg`]:H==="large",[`${w}-affix-wrapper-rtl`]:r==="rtl",[`${w}-affix-wrapper-without-controls`]:v===!1||L||p},k),wrapper:me({[`${z}-rtl`]:r==="rtl"},k),groupWrapper:me({[`${w}-group-wrapper-sm`]:H==="small",[`${w}-group-wrapper-lg`]:H==="large",[`${w}-group-wrapper-rtl`]:r==="rtl",[`${w}-group-wrapper-${j}`]:_},ns(`${w}-group-wrapper`,R,D),k)}},b));return E(G)}),nw=BR,Ree=e=>C.createElement(hs,{theme:{components:{InputNumber:{handleVisible:!0}}}},C.createElement(BR,Object.assign({},e)));nw._InternalPanelDoNotUseOrYouWillBeFired=Ree;const RR=e=>{let t;return typeof e=="object"&&(e!=null&&e.clearIcon)?t=e:e&&(t={clearIcon:we.createElement(bp,null)}),t};function _R(e,t){const n=et([]),r=()=>{n.current.push(setTimeout(()=>{var o,i,a,s;!((o=e.current)===null||o===void 0)&&o.input&&((i=e.current)===null||i===void 0?void 0:i.input.getAttribute("type"))==="password"&&!((a=e.current)===null||a===void 0)&&a.input.hasAttribute("value")&&((s=e.current)===null||s===void 0||s.input.removeAttribute("value"))}))};return Et(()=>(t&&r(),()=>n.current.forEach(o=>{o&&clearTimeout(o)})),[]),r}function _ee(e){return!!(e.prefix||e.suffix||e.allowClear||e.showCount)}var jee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const zp=Oi((e,t)=>{const{prefixCls:n,bordered:r=!0,status:o,size:i,disabled:a,onBlur:s,onFocus:l,suffix:c,allowClear:u,addonAfter:d,addonBefore:f,className:h,style:m,styles:p,rootClassName:g,onChange:v,classNames:y,variant:b}=e,w=jee(e,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames","variant"]),{getPrefixCls:x,direction:E,allowClear:k,autoComplete:S,className:O,style:A,classNames:$,styles:M}=xa("input"),N=x("input",n),D=et(null),T=Ro(N),[P,I,R]=MR(N,g),[H]=NR(N,T),{compactSize:V,compactItemClassnames:L}=ps(N,E),j=ai(de=>{var ge;return(ge=i??V)!==null&&ge!==void 0?ge:de}),_=we.useContext(vo),F=a??_,{status:B,hasFeedback:z,feedbackIcon:G}=pr(Yr),W=pl(B,o),q=_ee(e)||!!z;et(q);const U=_R(D,!0),Y=de=>{U(),s==null||s(de)},ie=de=>{U(),l==null||l(de)},K=de=>{U(),v==null||v(de)},re=(z||c)&&we.createElement(we.Fragment,null,c,z&&G),oe=RR(u??k),[ne,ae]=Pc("input",b,r);return P(H(we.createElement(xee,Object.assign({ref:oi(t,D),prefixCls:N,autoComplete:S},w,{disabled:F,onBlur:Y,onFocus:ie,style:Object.assign(Object.assign({},A),m),styles:Object.assign(Object.assign({},M),p),suffix:re,allowClear:oe,className:me(h,g,R,T,L,O),onChange:K,addonBefore:f&&we.createElement(ts,{form:!0,space:!0},f),addonAfter:d&&we.createElement(ts,{form:!0,space:!0},d),classNames:Object.assign(Object.assign(Object.assign({},y),$),{input:me({[`${N}-sm`]:j==="small",[`${N}-lg`]:j==="large",[`${N}-rtl`]:E==="rtl"},y==null?void 0:y.input,$.input,I),variant:me({[`${N}-${ne}`]:ae},ns(N,W)),affixWrapper:me({[`${N}-affix-wrapper-sm`]:j==="small",[`${N}-affix-wrapper-lg`]:j==="large",[`${N}-affix-wrapper-rtl`]:E==="rtl"},I),wrapper:me({[`${N}-group-rtl`]:E==="rtl"},I),groupWrapper:me({[`${N}-group-wrapper-sm`]:j==="small",[`${N}-group-wrapper-lg`]:j==="large",[`${N}-group-wrapper-rtl`]:E==="rtl",[`${N}-group-wrapper-${ne}`]:ae},ns(`${N}-group-wrapper`,W,z),I)})}))))});function rw(e,t,n){return(e-t)/(n-t)}function Ek(e,t,n,r){var o=rw(t,n,r),i={};switch(e){case"rtl":i.right="".concat(o*100,"%"),i.transform="translateX(50%)";break;case"btt":i.bottom="".concat(o*100,"%"),i.transform="translateY(50%)";break;case"ttb":i.top="".concat(o*100,"%"),i.transform="translateY(-50%)";break;default:i.left="".concat(o*100,"%"),i.transform="translateX(-50%)";break}return i}function Ts(e,t){return Array.isArray(e)?e[t]:e}var yl=C.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0,styles:{},classNames:{}}),Lee=C.createContext({}),zee=["prefixCls","value","valueIndex","onStartMove","onDelete","style","render","dragging","draggingDelete","onOffsetChange","onChangeComplete","onFocus","onMouseEnter"],yA=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.value,o=e.valueIndex,i=e.onStartMove,a=e.onDelete,s=e.style,l=e.render,c=e.dragging,u=e.draggingDelete,d=e.onOffsetChange,f=e.onChangeComplete,h=e.onFocus,m=e.onMouseEnter,p=tn(e,zee),g=C.useContext(yl),v=g.min,y=g.max,b=g.direction,w=g.disabled,x=g.keyboard,E=g.range,k=g.tabIndex,S=g.ariaLabelForHandle,O=g.ariaLabelledByForHandle,A=g.ariaRequired,$=g.ariaValueTextFormatterForHandle,M=g.styles,N=g.classNames,D="".concat(n,"-handle"),T=function(F){w||i(F,o)},P=function(F){h==null||h(F,o)},I=function(F){m(F,o)},R=function(F){if(!w&&x){var B=null;switch(F.which||F.keyCode){case St.LEFT:B=b==="ltr"||b==="btt"?-1:1;break;case St.RIGHT:B=b==="ltr"||b==="btt"?1:-1;break;case St.UP:B=b!=="ttb"?1:-1;break;case St.DOWN:B=b!=="ttb"?-1:1;break;case St.HOME:B="min";break;case St.END:B="max";break;case St.PAGE_UP:B=2;break;case St.PAGE_DOWN:B=-2;break;case St.BACKSPACE:case St.DELETE:a==null||a(o);break}B!==null&&(F.preventDefault(),d(B,o))}},H=function(F){switch(F.which||F.keyCode){case St.LEFT:case St.RIGHT:case St.UP:case St.DOWN:case St.HOME:case St.END:case St.PAGE_UP:case St.PAGE_DOWN:f==null||f();break}},V=Ek(b,r,v,y),L={};if(o!==null){var j;L={tabIndex:w?null:Ts(k,o),role:"slider","aria-valuemin":v,"aria-valuemax":y,"aria-valuenow":r,"aria-disabled":w,"aria-label":Ts(S,o),"aria-labelledby":Ts(O,o),"aria-required":Ts(A,o),"aria-valuetext":(j=Ts($,o))===null||j===void 0?void 0:j(r),"aria-orientation":b==="ltr"||b==="rtl"?"horizontal":"vertical",onMouseDown:T,onTouchStart:T,onFocus:P,onMouseEnter:I,onKeyDown:R,onKeyUp:H}}var _=C.createElement("div",Qe({ref:t,className:me(D,X(X(X({},"".concat(D,"-").concat(o+1),o!==null&&E),"".concat(D,"-dragging"),c),"".concat(D,"-dragging-delete"),u),N.handle),style:Q(Q(Q({},V),s),M.handle)},L,p));return l&&(_=l(_,{index:o,prefixCls:n,value:r,dragging:c,draggingDelete:u})),_}),Hee=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","activeHandleRender","draggingIndex","draggingDelete","onFocus"],Wee=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.style,o=e.onStartMove,i=e.onOffsetChange,a=e.values,s=e.handleRender,l=e.activeHandleRender,c=e.draggingIndex,u=e.draggingDelete,d=e.onFocus,f=tn(e,Hee),h=C.useRef({}),m=C.useState(!1),p=te(m,2),g=p[0],v=p[1],y=C.useState(-1),b=te(y,2),w=b[0],x=b[1],E=function(A){x(A),v(!0)},k=function(A,$){E($),d==null||d(A)},S=function(A,$){E($)};C.useImperativeHandle(t,function(){return{focus:function(A){var $;($=h.current[A])===null||$===void 0||$.focus()},hideHelp:function(){LE(function(){v(!1)})}}});var O=Q({prefixCls:n,onStartMove:o,onOffsetChange:i,render:s,onFocus:k,onMouseEnter:S},f);return C.createElement(C.Fragment,null,a.map(function(A,$){var M=c===$;return C.createElement(yA,Qe({ref:function(N){N?h.current[$]=N:delete h.current[$]},dragging:M,draggingDelete:M&&u,style:Ts(r,$),key:$,value:A,valueIndex:$},O))}),l&&g&&C.createElement(yA,Qe({key:"a11y"},O,{value:a[w],valueIndex:null,dragging:c!==-1,draggingDelete:u,render:l,style:{pointerEvents:"none"},tabIndex:null,"aria-hidden":!0})))}),Vee=function(e){var t=e.prefixCls,n=e.style,r=e.children,o=e.value,i=e.onClick,a=C.useContext(yl),s=a.min,l=a.max,c=a.direction,u=a.includedStart,d=a.includedEnd,f=a.included,h="".concat(t,"-text"),m=Ek(c,o,s,l);return C.createElement("span",{className:me(h,X({},"".concat(h,"-active"),f&&u<=o&&o<=d)),style:Q(Q({},m),n),onMouseDown:function(p){p.stopPropagation()},onClick:function(){i(o)}},r)},Gee=function(e){var t=e.prefixCls,n=e.marks,r=e.onClick,o="".concat(t,"-mark");return n.length?C.createElement("div",{className:o},n.map(function(i){var a=i.value,s=i.style,l=i.label;return C.createElement(Vee,{key:a,prefixCls:o,style:s,value:a,onClick:r},l)})):null},Uee=function(e){var t=e.prefixCls,n=e.value,r=e.style,o=e.activeStyle,i=C.useContext(yl),a=i.min,s=i.max,l=i.direction,c=i.included,u=i.includedStart,d=i.includedEnd,f="".concat(t,"-dot"),h=c&&u<=n&&n<=d,m=Q(Q({},Ek(l,n,a,s)),typeof r=="function"?r(n):r);return h&&(m=Q(Q({},m),typeof o=="function"?o(n):o)),C.createElement("span",{className:me(f,X({},"".concat(f,"-active"),h)),style:m})},qee=function(e){var t=e.prefixCls,n=e.marks,r=e.dots,o=e.style,i=e.activeStyle,a=C.useContext(yl),s=a.min,l=a.max,c=a.step,u=C.useMemo(function(){var d=new Set;if(n.forEach(function(h){d.add(h.value)}),r&&c!==null)for(var f=s;f<=l;)d.add(f),f+=c;return Array.from(d)},[s,l,c,r,n]);return C.createElement("div",{className:"".concat(t,"-step")},u.map(function(d){return C.createElement(Uee,{prefixCls:t,key:d,value:d,style:o,activeStyle:i})}))},bA=function(e){var t=e.prefixCls,n=e.style,r=e.start,o=e.end,i=e.index,a=e.onStartMove,s=e.replaceCls,l=C.useContext(yl),c=l.direction,u=l.min,d=l.max,f=l.disabled,h=l.range,m=l.classNames,p="".concat(t,"-track"),g=rw(r,u,d),v=rw(o,u,d),y=function(x){!f&&a&&a(x,-1)},b={};switch(c){case"rtl":b.right="".concat(g*100,"%"),b.width="".concat(v*100-g*100,"%");break;case"btt":b.bottom="".concat(g*100,"%"),b.height="".concat(v*100-g*100,"%");break;case"ttb":b.top="".concat(g*100,"%"),b.height="".concat(v*100-g*100,"%");break;default:b.left="".concat(g*100,"%"),b.width="".concat(v*100-g*100,"%")}var w=s||me(p,X(X({},"".concat(p,"-").concat(i+1),i!==null&&h),"".concat(t,"-track-draggable"),a),m.track);return C.createElement("div",{className:w,style:Q(Q({},b),n),onMouseDown:y,onTouchStart:y})},Yee=function(e){var t=e.prefixCls,n=e.style,r=e.values,o=e.startPoint,i=e.onStartMove,a=C.useContext(yl),s=a.included,l=a.range,c=a.min,u=a.styles,d=a.classNames,f=C.useMemo(function(){if(!l){if(r.length===0)return[];var m=o??c,p=r[0];return[{start:Math.min(m,p),end:Math.max(m,p)}]}for(var g=[],v=0;v<r.length-1;v+=1)g.push({start:r[v],end:r[v+1]});return g},[r,l,o,c]);if(!s)return null;var h=f!=null&&f.length&&(d.tracks||u.tracks)?C.createElement(bA,{index:null,prefixCls:t,start:f[0].start,end:f[f.length-1].end,replaceCls:me(d.tracks,"".concat(t,"-tracks")),style:u.tracks}):null;return C.createElement(C.Fragment,null,h,f.map(function(m,p){var g=m.start,v=m.end;return C.createElement(bA,{index:p,prefixCls:t,style:Q(Q({},Ts(n,p)),u.track),start:g,end:v,key:p,onStartMove:i})}))},Xee=130;function xA(e){var t="targetTouches"in e?e.targetTouches[0]:e;return{pageX:t.pageX,pageY:t.pageY}}function Kee(e,t,n,r,o,i,a,s,l,c,u){var d=C.useState(null),f=te(d,2),h=f[0],m=f[1],p=C.useState(-1),g=te(p,2),v=g[0],y=g[1],b=C.useState(!1),w=te(b,2),x=w[0],E=w[1],k=C.useState(n),S=te(k,2),O=S[0],A=S[1],$=C.useState(n),M=te($,2),N=M[0],D=M[1],T=C.useRef(null),P=C.useRef(null),I=C.useRef(null),R=C.useContext(Lee),H=R.onDragStart,V=R.onDragChange;mn(function(){v===-1&&A(n)},[n,v]),C.useEffect(function(){return function(){document.removeEventListener("mousemove",T.current),document.removeEventListener("mouseup",P.current),I.current&&(I.current.removeEventListener("touchmove",T.current),I.current.removeEventListener("touchend",P.current))}},[]);var L=function(B,z,G){z!==void 0&&m(z),A(B);var W=B;G&&(W=B.filter(function(q,U){return U!==v})),a(W),V&&V({rawValues:B,deleteIndex:G?v:-1,draggingIndex:v,draggingValue:z})},j=cn(function(B,z,G){if(B===-1){var W=N[0],q=N[N.length-1],U=r-W,Y=o-q,ie=z*(o-r);ie=Math.max(ie,U),ie=Math.min(ie,Y);var K=i(W+ie);ie=K-W;var re=N.map(function(de){return de+ie});L(re)}else{var oe=(o-r)*z,ne=ze(O);ne[B]=N[B];var ae=l(ne,oe,B,"dist");L(ae.values,ae.value,G)}}),_=function(B,z,G){B.stopPropagation();var W=G||n,q=W[z];y(z),m(q),D(W),A(W),E(!1);var U=xA(B),Y=U.pageX,ie=U.pageY,K=!1;H&&H({rawValues:W,draggingIndex:z,draggingValue:q});var re=function(ne){ne.preventDefault();var ae=xA(ne),de=ae.pageX,ge=ae.pageY,Se=de-Y,ye=ge-ie,be=e.current.getBoundingClientRect(),ce=be.width,he=be.height,Te,se;switch(t){case"btt":Te=-ye/he,se=Se;break;case"ttb":Te=ye/he,se=Se;break;case"rtl":Te=-Se/ce,se=ye;break;default:Te=Se/ce,se=ye}K=c?Math.abs(se)>Xee&&u<O.length:!1,E(K),j(z,Te,K)},oe=function ne(ae){ae.preventDefault(),document.removeEventListener("mouseup",ne),document.removeEventListener("mousemove",re),I.current&&(I.current.removeEventListener("touchmove",T.current),I.current.removeEventListener("touchend",P.current)),T.current=null,P.current=null,I.current=null,s(K),y(-1),E(!1)};document.addEventListener("mouseup",oe),document.addEventListener("mousemove",re),B.currentTarget.addEventListener("touchend",oe),B.currentTarget.addEventListener("touchmove",re),T.current=re,P.current=oe,I.current=B.currentTarget},F=C.useMemo(function(){var B=ze(n).sort(function(U,Y){return U-Y}),z=ze(O).sort(function(U,Y){return U-Y}),G={};z.forEach(function(U){G[U]=(G[U]||0)+1}),B.forEach(function(U){G[U]=(G[U]||0)-1});var W=c?1:0,q=Object.values(G).reduce(function(U,Y){return U+Math.abs(Y)},0);return q<=W?O:n},[n,O,c]);return[v,h,x,F,_]}function Zee(e,t,n,r,o,i){var a=C.useCallback(function(h){return Math.max(e,Math.min(t,h))},[e,t]),s=C.useCallback(function(h){if(n!==null){var m=e+Math.round((a(h)-e)/n)*n,p=function(y){return(String(y).split(".")[1]||"").length},g=Math.max(p(n),p(t),p(e)),v=Number(m.toFixed(g));return e<=v&&v<=t?v:null}return null},[n,e,t,a]),l=C.useCallback(function(h){var m=a(h),p=r.map(function(y){return y.value});n!==null&&p.push(s(h)),p.push(e,t);var g=p[0],v=t-e;return p.forEach(function(y){var b=Math.abs(m-y);b<=v&&(g=y,v=b)}),g},[e,t,r,n,a,s]),c=function h(m,p,g){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof p=="number"){var y,b=m[g],w=b+p,x=[];r.forEach(function(A){x.push(A.value)}),x.push(e,t),x.push(s(b));var E=p>0?1:-1;v==="unit"?x.push(s(b+E*n)):x.push(s(w)),x=x.filter(function(A){return A!==null}).filter(function(A){return p<0?A<=b:A>=b}),v==="unit"&&(x=x.filter(function(A){return A!==b}));var k=v==="unit"?b:w;y=x[0];var S=Math.abs(y-k);if(x.forEach(function(A){var $=Math.abs(A-k);$<S&&(y=A,S=$)}),y===void 0)return p<0?e:t;if(v==="dist")return y;if(Math.abs(p)>1){var O=ze(m);return O[g]=y,h(O,p-E,g,v)}return y}else{if(p==="min")return e;if(p==="max")return t}},u=function(h,m,p){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",v=h[p],y=c(h,m,p,g);return{value:y,changed:y!==v}},d=function(h){return i===null&&h===0||typeof i=="number"&&h<i},f=function(h,m,p){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",v=h.map(l),y=v[p],b=c(v,m,p,g);if(v[p]=b,o===!1){var w=i||0;p>0&&v[p-1]!==y&&(v[p]=Math.max(v[p],v[p-1]+w)),p<v.length-1&&v[p+1]!==y&&(v[p]=Math.min(v[p],v[p+1]-w))}else if(typeof i=="number"||i===null){for(var x=p+1;x<v.length;x+=1)for(var E=!0;d(v[x]-v[x-1])&&E;){var k=u(v,1,x);v[x]=k.value,E=k.changed}for(var S=p;S>0;S-=1)for(var O=!0;d(v[S]-v[S-1])&&O;){var A=u(v,-1,S-1);v[S-1]=A.value,O=A.changed}for(var $=v.length-1;$>0;$-=1)for(var M=!0;d(v[$]-v[$-1])&&M;){var N=u(v,-1,$-1);v[$-1]=N.value,M=N.changed}for(var D=0;D<v.length-1;D+=1)for(var T=!0;d(v[D+1]-v[D])&&T;){var P=u(v,1,D+1);v[D+1]=P.value,T=P.changed}}return{value:v[p],values:v}};return[l,f]}function Qee(e){return Gt(function(){if(e===!0||!e)return[!!e,!1,!1,0];var t=e.editable,n=e.draggableTrack,r=e.minCount,o=e.maxCount;return[!0,t,!t&&n,r||0,o]},[e])}var Jee=C.forwardRef(function(e,t){var n=e.prefixCls,r=n===void 0?"rc-slider":n,o=e.className,i=e.style,a=e.classNames,s=e.styles,l=e.id,c=e.disabled,u=c===void 0?!1:c,d=e.keyboard,f=d===void 0?!0:d,h=e.autoFocus,m=e.onFocus,p=e.onBlur,g=e.min,v=g===void 0?0:g,y=e.max,b=y===void 0?100:y,w=e.step,x=w===void 0?1:w,E=e.value,k=e.defaultValue,S=e.range,O=e.count,A=e.onChange,$=e.onBeforeChange,M=e.onAfterChange,N=e.onChangeComplete,D=e.allowCross,T=D===void 0?!0:D,P=e.pushable,I=P===void 0?!1:P,R=e.reverse,H=e.vertical,V=e.included,L=V===void 0?!0:V,j=e.startPoint,_=e.trackStyle,F=e.handleStyle,B=e.railStyle,z=e.dotStyle,G=e.activeDotStyle,W=e.marks,q=e.dots,U=e.handleRender,Y=e.activeHandleRender,ie=e.track,K=e.tabIndex,re=K===void 0?0:K,oe=e.ariaLabelForHandle,ne=e.ariaLabelledByForHandle,ae=e.ariaRequired,de=e.ariaValueTextFormatterForHandle,ge=C.useRef(null),Se=C.useRef(null),ye=C.useMemo(function(){return H?R?"ttb":"btt":R?"rtl":"ltr"},[R,H]),be=Qee(S),ce=te(be,5),he=ce[0],Te=ce[1],se=ce[2],Pe=ce[3],De=ce[4],He=C.useMemo(function(){return isFinite(v)?v:0},[v]),ue=C.useMemo(function(){return isFinite(b)?b:100},[b]),ve=C.useMemo(function(){return x!==null&&x<=0?1:x},[x]),xe=C.useMemo(function(){return typeof I=="boolean"?I?ve:!1:I>=0?I:!1},[I,ve]),fe=C.useMemo(function(){return Object.keys(W||{}).map(function(Ke){var rt=W[Ke],ht={value:Number(Ke)};return rt&&At(rt)==="object"&&!C.isValidElement(rt)&&("label"in rt||"style"in rt)?(ht.style=rt.style,ht.label=rt.label):ht.label=rt,ht}).filter(function(Ke){var rt=Ke.label;return rt||typeof rt=="number"}).sort(function(Ke,rt){return Ke.value-rt.value})},[W]),pe=Zee(He,ue,ve,fe,T,xe),ke=te(pe,2),Ve=ke[0],Ee=ke[1],yt=yr(k,{value:E}),Dt=te(yt,2),Ft=Dt[0],Ut=Dt[1],Ge=C.useMemo(function(){var Ke=Ft==null?[]:Array.isArray(Ft)?Ft:[Ft],rt=te(Ke,1),ht=rt[0],an=ht===void 0?He:ht,dn=Ft===null?[]:[an];if(he){if(dn=ze(Ke),O||Ft===void 0){var Un=O>=0?O+1:2;for(dn=dn.slice(0,Un);dn.length<Un;){var dr;dn.push((dr=dn[dn.length-1])!==null&&dr!==void 0?dr:He)}}dn.sort(function(Nn,Dn){return Nn-Dn})}return dn.forEach(function(Nn,Dn){dn[Dn]=Ve(Nn)}),dn},[Ft,he,He,O,Ve]),Xe=function(Ke){return he?Ke:Ke[0]},qe=cn(function(Ke){var rt=ze(Ke).sort(function(ht,an){return ht-an});A&&!a0(rt,Ge,!0)&&A(Xe(rt)),Ut(rt)}),lt=cn(function(Ke){Ke&&ge.current.hideHelp();var rt=Xe(Ge);M==null||M(rt),qr(!M,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N==null||N(rt)}),je=function(Ke){if(!(u||!Te||Ge.length<=Pe)){var rt=ze(Ge);rt.splice(Ke,1),$==null||$(Xe(rt)),qe(rt);var ht=Math.max(0,Ke-1);ge.current.hideHelp(),ge.current.focus(ht)}},Rt=Kee(Se,ye,Ge,He,ue,Ve,qe,lt,Ee,Te,Pe),zt=te(Rt,5),dt=zt[0],Ct=zt[1],jt=zt[2],Ie=zt[3],Ne=zt[4],Oe=function(Ke,rt){if(!u){var ht=ze(Ge),an=0,dn=0,Un=ue-He;Ge.forEach(function(ar,J){var Z=Math.abs(Ke-ar);Z<=Un&&(Un=Z,an=J),ar<Ke&&(dn=J)});var dr=an;Te&&Un!==0&&(!De||Ge.length<De)?(ht.splice(dn+1,0,Ke),dr=dn+1):ht[an]=Ke,he&&!Ge.length&&O===void 0&&ht.push(Ke);var Nn=Xe(ht);if($==null||$(Nn),qe(ht),rt){var Dn,wr;(Dn=document.activeElement)===null||Dn===void 0||(wr=Dn.blur)===null||wr===void 0||wr.call(Dn),ge.current.focus(dr),Ne(rt,dr,ht)}else M==null||M(Nn),qr(!M,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N==null||N(Nn)}},_e=function(Ke){Ke.preventDefault();var rt=Se.current.getBoundingClientRect(),ht=rt.width,an=rt.height,dn=rt.left,Un=rt.top,dr=rt.bottom,Nn=rt.right,Dn=Ke.clientX,wr=Ke.clientY,ar;switch(ye){case"btt":ar=(dr-wr)/an;break;case"ttb":ar=(wr-Un)/an;break;case"rtl":ar=(Nn-Dn)/ht;break;default:ar=(Dn-dn)/ht}var J=He+ar*(ue-He);Oe(Ve(J),Ke)},mt=C.useState(null),kt=te(mt,2),Pt=kt[0],Xt=kt[1],on=function(Ke,rt){if(!u){var ht=Ee(Ge,Ke,rt);$==null||$(Xe(Ge)),qe(ht.values),Xt(ht.value)}};C.useEffect(function(){if(Pt!==null){var Ke=Ge.indexOf(Pt);Ke>=0&&ge.current.focus(Ke)}Xt(null)},[Pt]);var qt=C.useMemo(function(){return se&&ve===null?!1:se},[se,ve]),wn=cn(function(Ke,rt){Ne(Ke,rt),$==null||$(Xe(Ge))}),vn=dt!==-1;C.useEffect(function(){if(!vn){var Ke=Ge.lastIndexOf(Ct);ge.current.focus(Ke)}},[vn]);var Kt=C.useMemo(function(){return ze(Ie).sort(function(Ke,rt){return Ke-rt})},[Ie]),$n=C.useMemo(function(){return he?[Kt[0],Kt[Kt.length-1]]:[He,Kt[0]]},[Kt,he,He]),On=te($n,2),ur=On[0],We=On[1];C.useImperativeHandle(t,function(){return{focus:function(){ge.current.focus(0)},blur:function(){var Ke,rt=document,ht=rt.activeElement;(Ke=Se.current)!==null&&Ke!==void 0&&Ke.contains(ht)&&(ht==null||ht.blur())}}}),C.useEffect(function(){h&&ge.current.focus(0)},[]);var pt=C.useMemo(function(){return{min:He,max:ue,direction:ye,disabled:u,keyboard:f,step:ve,included:L,includedStart:ur,includedEnd:We,range:he,tabIndex:re,ariaLabelForHandle:oe,ariaLabelledByForHandle:ne,ariaRequired:ae,ariaValueTextFormatterForHandle:de,styles:s||{},classNames:a||{}}},[He,ue,ye,u,f,ve,L,ur,We,he,re,oe,ne,ae,de,s,a]);return C.createElement(yl.Provider,{value:pt},C.createElement("div",{ref:Se,className:me(r,o,X(X(X(X({},"".concat(r,"-disabled"),u),"".concat(r,"-vertical"),H),"".concat(r,"-horizontal"),!H),"".concat(r,"-with-marks"),fe.length)),style:i,onMouseDown:_e,id:l},C.createElement("div",{className:me("".concat(r,"-rail"),a==null?void 0:a.rail),style:Q(Q({},B),s==null?void 0:s.rail)}),ie!==!1&&C.createElement(Yee,{prefixCls:r,style:_,values:Ge,startPoint:j,onStartMove:qt?wn:void 0}),C.createElement(qee,{prefixCls:r,marks:fe,dots:q,style:z,activeStyle:G}),C.createElement(Wee,{ref:ge,prefixCls:r,style:F,values:Ie,draggingIndex:dt,draggingDelete:jt,onStartMove:wn,onOffsetChange:on,onFocus:m,onBlur:p,handleRender:U,activeHandleRender:Y,onChangeComplete:lt,onDelete:Te?je:void 0}),C.createElement(Gee,{prefixCls:r,marks:fe,onClick:Oe})))});const ete=us({}),EA=C.forwardRef((e,t)=>{const{open:n,draggingDelete:r,value:o}=e,i=et(null),a=n&&!r,s=et(null);function l(){en.cancel(s.current),s.current=null}function c(){s.current=en(()=>{var u;(u=i.current)===null||u===void 0||u.forceAlign(),s.current=null})}return C.useEffect(()=>(a?c():l(),l),[a,e.title,o]),C.createElement(Nd,Object.assign({ref:oi(i,t)},e,{open:a}))}),tte=e=>{const{componentCls:t,antCls:n,controlSize:r,dotSize:o,marginFull:i,marginPart:a,colorFillContentHover:s,handleColorDisabled:l,calc:c,handleSize:u,handleSizeHover:d,handleActiveColor:f,handleActiveOutlineColor:h,handleLineWidth:m,handleLineWidthHover:p,motionDurationMid:g}=e;return{[t]:Object.assign(Object.assign({},br(e)),{position:"relative",height:r,margin:`${Ce(a)} ${Ce(i)}`,padding:0,cursor:"pointer",touchAction:"none","&-vertical":{margin:`${Ce(i)} ${Ce(a)}`},[`${t}-rail`]:{position:"absolute",backgroundColor:e.railBg,borderRadius:e.borderRadiusXS,transition:`background-color ${g}`},[`${t}-track,${t}-tracks`]:{position:"absolute",transition:`background-color ${g}`},[`${t}-track`]:{backgroundColor:e.trackBg,borderRadius:e.borderRadiusXS},[`${t}-track-draggable`]:{boxSizing:"content-box",backgroundClip:"content-box",border:"solid rgba(0,0,0,0)"},"&:hover":{[`${t}-rail`]:{backgroundColor:e.railHoverBg},[`${t}-track`]:{backgroundColor:e.trackHoverBg},[`${t}-dot`]:{borderColor:s},[`${t}-handle::after`]:{boxShadow:`0 0 0 ${Ce(m)} ${e.colorPrimaryBorderHover}`},[`${t}-dot-active`]:{borderColor:e.dotActiveBorderColor}},[`${t}-handle`]:{position:"absolute",width:u,height:u,outline:"none",userSelect:"none","&-dragging-delete":{opacity:0},"&::before":{content:'""',position:"absolute",insetInlineStart:c(m).mul(-1).equal(),insetBlockStart:c(m).mul(-1).equal(),width:c(u).add(c(m).mul(2)).equal(),height:c(u).add(c(m).mul(2)).equal(),backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:u,height:u,backgroundColor:e.colorBgElevated,boxShadow:`0 0 0 ${Ce(m)} ${e.handleColor}`,outline:"0px solid transparent",borderRadius:"50%",cursor:"pointer",transition:`
|
|
360
|
+
`]:{color:E}})}]},Pee=e=>{const{componentCls:t,paddingBlock:n,paddingInline:r,inputAffixPadding:o,controlWidth:i,borderRadiusLG:a,borderRadiusSM:s,paddingInlineLG:l,paddingInlineSM:c,paddingBlockLG:u,paddingBlockSM:d,motionDurationMid:f}=e;return{[`${t}-affix-wrapper`]:Object.assign(Object.assign({[`input${t}-input`]:{padding:`${Ce(n)} 0`}},jp(e)),{position:"relative",display:"inline-flex",alignItems:"center",width:i,padding:0,paddingInlineStart:r,"&-lg":{borderRadius:a,paddingInlineStart:l,[`input${t}-input`]:{padding:`${Ce(u)} 0`}},"&-sm":{borderRadius:s,paddingInlineStart:c,[`input${t}-input`]:{padding:`${Ce(d)} 0`}},[`&:not(${t}-disabled):hover`]:{zIndex:1},"&-focused, &:focus":{zIndex:1},[`&-disabled > ${t}-disabled`]:{background:"transparent"},[`> div${t}`]:{width:"100%",border:"none",outline:"none",[`&${t}-focused`]:{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[`${t}-handler-wrap`]:{zIndex:2},[t]:{position:"static",color:"inherit","&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center",pointerEvents:"none"},"&-prefix":{marginInlineEnd:o},"&-suffix":{insetBlockStart:0,insetInlineEnd:0,height:"100%",marginInlineEnd:r,marginInlineStart:o,transition:`margin ${f}`}},[`&:hover ${t}-handler-wrap, &-focused ${t}-handler-wrap`]:{width:e.handleWidth,opacity:1},[`&:not(${t}-affix-wrapper-without-controls):hover ${t}-suffix`]:{marginInlineEnd:e.calc(e.handleWidth).add(r).equal()}}),[`${t}-underlined`]:{borderRadius:0}}},Iee=Pr("InputNumber",e=>{const t=Mn(e,Rc(e));return[Fee(t),Pee(t),$d(t)]},Tee,{unitless:{handleOpacity:!0},resetFont:!1});var Bee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const BR=C.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=C.useContext(pn),o=C.useRef(null);C.useImperativeHandle(t,()=>o.current);const{className:i,rootClassName:a,size:s,disabled:l,prefixCls:c,addonBefore:u,addonAfter:d,prefix:f,suffix:h,bordered:m,readOnly:p,status:g,controls:v,variant:y}=e,b=Bee(e,["className","rootClassName","size","disabled","prefixCls","addonBefore","addonAfter","prefix","suffix","bordered","readOnly","status","controls","variant"]),w=n("input-number",c),x=Ro(w),[E,k,S]=Iee(w,x),{compactSize:O,compactItemClassnames:A}=ps(w,r);let $=C.createElement(hee,{className:`${w}-handler-up-inner`}),M=C.createElement(SB,{className:`${w}-handler-down-inner`});const N=typeof v=="boolean"?v:void 0;typeof v=="object"&&($=typeof v.upIcon>"u"?$:C.createElement("span",{className:`${w}-handler-up-inner`},v.upIcon),M=typeof v.downIcon>"u"?M:C.createElement("span",{className:`${w}-handler-down-inner`},v.downIcon));const{hasFeedback:D,status:T,isFormItemInput:P,feedbackIcon:I}=C.useContext(Yr),R=pl(T,g),H=ai(W=>{var q;return(q=s??O)!==null&&q!==void 0?q:W}),V=C.useContext(vo),L=l??V,[j,_]=Pc("inputNumber",y,m),F=D&&C.createElement(C.Fragment,null,I),B=me({[`${w}-lg`]:H==="large",[`${w}-sm`]:H==="small",[`${w}-rtl`]:r==="rtl",[`${w}-in-form-item`]:P},k),z=`${w}-group`,G=C.createElement(Dee,Object.assign({ref:o,disabled:L,className:me(S,x,i,a,A),upHandler:$,downHandler:M,prefixCls:w,readOnly:p,controls:N,prefix:f,suffix:F||h,addonBefore:u&&C.createElement(ts,{form:!0,space:!0},u),addonAfter:d&&C.createElement(ts,{form:!0,space:!0},d),classNames:{input:B,variant:me({[`${w}-${j}`]:_},ns(w,R,D)),affixWrapper:me({[`${w}-affix-wrapper-sm`]:H==="small",[`${w}-affix-wrapper-lg`]:H==="large",[`${w}-affix-wrapper-rtl`]:r==="rtl",[`${w}-affix-wrapper-without-controls`]:v===!1||L||p},k),wrapper:me({[`${z}-rtl`]:r==="rtl"},k),groupWrapper:me({[`${w}-group-wrapper-sm`]:H==="small",[`${w}-group-wrapper-lg`]:H==="large",[`${w}-group-wrapper-rtl`]:r==="rtl",[`${w}-group-wrapper-${j}`]:_},ns(`${w}-group-wrapper`,R,D),k)}},b));return E(G)}),nw=BR,Ree=e=>C.createElement(hs,{theme:{components:{InputNumber:{handleVisible:!0}}}},C.createElement(BR,Object.assign({},e)));nw._InternalPanelDoNotUseOrYouWillBeFired=Ree;const RR=e=>{let t;return typeof e=="object"&&(e!=null&&e.clearIcon)?t=e:e&&(t={clearIcon:we.createElement(bp,null)}),t};function _R(e,t){const n=et([]),r=()=>{n.current.push(setTimeout(()=>{var o,i,a,s;!((o=e.current)===null||o===void 0)&&o.input&&((i=e.current)===null||i===void 0?void 0:i.input.getAttribute("type"))==="password"&&!((a=e.current)===null||a===void 0)&&a.input.hasAttribute("value")&&((s=e.current)===null||s===void 0||s.input.removeAttribute("value"))}))};return Et(()=>(t&&r(),()=>n.current.forEach(o=>{o&&clearTimeout(o)})),[]),r}function _ee(e){return!!(e.prefix||e.suffix||e.allowClear||e.showCount)}var jee=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const zp=Oi((e,t)=>{const{prefixCls:n,bordered:r=!0,status:o,size:i,disabled:a,onBlur:s,onFocus:l,suffix:c,allowClear:u,addonAfter:d,addonBefore:f,className:h,style:m,styles:p,rootClassName:g,onChange:v,classNames:y,variant:b}=e,w=jee(e,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames","variant"]),{getPrefixCls:x,direction:E,allowClear:k,autoComplete:S,className:O,style:A,classNames:$,styles:M}=xa("input"),N=x("input",n),D=et(null),T=Ro(N),[P,I,R]=MR(N,g),[H]=NR(N,T),{compactSize:V,compactItemClassnames:L}=ps(N,E),j=ai(de=>{var ge;return(ge=i??V)!==null&&ge!==void 0?ge:de}),_=we.useContext(vo),F=a??_,{status:B,hasFeedback:z,feedbackIcon:G}=pr(Yr),W=pl(B,o),q=_ee(e)||!!z;et(q);const U=_R(D,!0),Y=de=>{U(),s==null||s(de)},ie=de=>{U(),l==null||l(de)},K=de=>{U(),v==null||v(de)},re=(z||c)&&we.createElement(we.Fragment,null,c,z&&G),oe=RR(u??k),[ne,ae]=Pc("input",b,r);return P(H(we.createElement(xee,Object.assign({ref:oi(t,D),prefixCls:N,autoComplete:S},w,{disabled:F,onBlur:Y,onFocus:ie,style:Object.assign(Object.assign({},A),m),styles:Object.assign(Object.assign({},M),p),suffix:re,allowClear:oe,className:me(h,g,R,T,L,O),onChange:K,addonBefore:f&&we.createElement(ts,{form:!0,space:!0},f),addonAfter:d&&we.createElement(ts,{form:!0,space:!0},d),classNames:Object.assign(Object.assign(Object.assign({},y),$),{input:me({[`${N}-sm`]:j==="small",[`${N}-lg`]:j==="large",[`${N}-rtl`]:E==="rtl"},y==null?void 0:y.input,$.input,I),variant:me({[`${N}-${ne}`]:ae},ns(N,W)),affixWrapper:me({[`${N}-affix-wrapper-sm`]:j==="small",[`${N}-affix-wrapper-lg`]:j==="large",[`${N}-affix-wrapper-rtl`]:E==="rtl"},I),wrapper:me({[`${N}-group-rtl`]:E==="rtl"},I),groupWrapper:me({[`${N}-group-wrapper-sm`]:j==="small",[`${N}-group-wrapper-lg`]:j==="large",[`${N}-group-wrapper-rtl`]:E==="rtl",[`${N}-group-wrapper-${ne}`]:ae},ns(`${N}-group-wrapper`,W,z),I)})}))))});function rw(e,t,n){return(e-t)/(n-t)}function Ek(e,t,n,r){var o=rw(t,n,r),i={};switch(e){case"rtl":i.right="".concat(o*100,"%"),i.transform="translateX(50%)";break;case"btt":i.bottom="".concat(o*100,"%"),i.transform="translateY(50%)";break;case"ttb":i.top="".concat(o*100,"%"),i.transform="translateY(-50%)";break;default:i.left="".concat(o*100,"%"),i.transform="translateX(-50%)";break}return i}function Ts(e,t){return Array.isArray(e)?e[t]:e}var yl=C.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0,styles:{},classNames:{}}),Lee=C.createContext({}),zee=["prefixCls","value","valueIndex","onStartMove","onDelete","style","render","dragging","draggingDelete","onOffsetChange","onChangeComplete","onFocus","onMouseEnter"],yA=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.value,o=e.valueIndex,i=e.onStartMove,a=e.onDelete,s=e.style,l=e.render,c=e.dragging,u=e.draggingDelete,d=e.onOffsetChange,f=e.onChangeComplete,h=e.onFocus,m=e.onMouseEnter,p=tn(e,zee),g=C.useContext(yl),v=g.min,y=g.max,b=g.direction,w=g.disabled,x=g.keyboard,E=g.range,k=g.tabIndex,S=g.ariaLabelForHandle,O=g.ariaLabelledByForHandle,A=g.ariaRequired,$=g.ariaValueTextFormatterForHandle,M=g.styles,N=g.classNames,D="".concat(n,"-handle"),T=function(F){w||i(F,o)},P=function(F){h==null||h(F,o)},I=function(F){m(F,o)},R=function(F){if(!w&&x){var B=null;switch(F.which||F.keyCode){case St.LEFT:B=b==="ltr"||b==="btt"?-1:1;break;case St.RIGHT:B=b==="ltr"||b==="btt"?1:-1;break;case St.UP:B=b!=="ttb"?1:-1;break;case St.DOWN:B=b!=="ttb"?-1:1;break;case St.HOME:B="min";break;case St.END:B="max";break;case St.PAGE_UP:B=2;break;case St.PAGE_DOWN:B=-2;break;case St.BACKSPACE:case St.DELETE:a==null||a(o);break}B!==null&&(F.preventDefault(),d(B,o))}},H=function(F){switch(F.which||F.keyCode){case St.LEFT:case St.RIGHT:case St.UP:case St.DOWN:case St.HOME:case St.END:case St.PAGE_UP:case St.PAGE_DOWN:f==null||f();break}},V=Ek(b,r,v,y),L={};if(o!==null){var j;L={tabIndex:w?null:Ts(k,o),role:"slider","aria-valuemin":v,"aria-valuemax":y,"aria-valuenow":r,"aria-disabled":w,"aria-label":Ts(S,o),"aria-labelledby":Ts(O,o),"aria-required":Ts(A,o),"aria-valuetext":(j=Ts($,o))===null||j===void 0?void 0:j(r),"aria-orientation":b==="ltr"||b==="rtl"?"horizontal":"vertical",onMouseDown:T,onTouchStart:T,onFocus:P,onMouseEnter:I,onKeyDown:R,onKeyUp:H}}var _=C.createElement("div",Qe({ref:t,className:me(D,X(X(X({},"".concat(D,"-").concat(o+1),o!==null&&E),"".concat(D,"-dragging"),c),"".concat(D,"-dragging-delete"),u),N.handle),style:Q(Q(Q({},V),s),M.handle)},L,p));return l&&(_=l(_,{index:o,prefixCls:n,value:r,dragging:c,draggingDelete:u})),_}),Hee=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","activeHandleRender","draggingIndex","draggingDelete","onFocus"],Wee=C.forwardRef(function(e,t){var n=e.prefixCls,r=e.style,o=e.onStartMove,i=e.onOffsetChange,a=e.values,s=e.handleRender,l=e.activeHandleRender,c=e.draggingIndex,u=e.draggingDelete,d=e.onFocus,f=tn(e,Hee),h=C.useRef({}),m=C.useState(!1),p=te(m,2),g=p[0],v=p[1],y=C.useState(-1),b=te(y,2),w=b[0],x=b[1],E=function(A){x(A),v(!0)},k=function(A,$){E($),d==null||d(A)},S=function(A,$){E($)};C.useImperativeHandle(t,function(){return{focus:function(A){var $;($=h.current[A])===null||$===void 0||$.focus()},hideHelp:function(){LE(function(){v(!1)})}}});var O=Q({prefixCls:n,onStartMove:o,onOffsetChange:i,render:s,onFocus:k,onMouseEnter:S},f);return C.createElement(C.Fragment,null,a.map(function(A,$){var M=c===$;return C.createElement(yA,Qe({ref:function(N){N?h.current[$]=N:delete h.current[$]},dragging:M,draggingDelete:M&&u,style:Ts(r,$),key:$,value:A,valueIndex:$},O))}),l&&g&&C.createElement(yA,Qe({key:"a11y"},O,{value:a[w],valueIndex:null,dragging:c!==-1,draggingDelete:u,render:l,style:{pointerEvents:"none"},tabIndex:null,"aria-hidden":!0})))}),Vee=function(e){var t=e.prefixCls,n=e.style,r=e.children,o=e.value,i=e.onClick,a=C.useContext(yl),s=a.min,l=a.max,c=a.direction,u=a.includedStart,d=a.includedEnd,f=a.included,h="".concat(t,"-text"),m=Ek(c,o,s,l);return C.createElement("span",{className:me(h,X({},"".concat(h,"-active"),f&&u<=o&&o<=d)),style:Q(Q({},m),n),onMouseDown:function(p){p.stopPropagation()},onClick:function(){i(o)}},r)},Gee=function(e){var t=e.prefixCls,n=e.marks,r=e.onClick,o="".concat(t,"-mark");return n.length?C.createElement("div",{className:o},n.map(function(i){var a=i.value,s=i.style,l=i.label;return C.createElement(Vee,{key:a,prefixCls:o,style:s,value:a,onClick:r},l)})):null},Uee=function(e){var t=e.prefixCls,n=e.value,r=e.style,o=e.activeStyle,i=C.useContext(yl),a=i.min,s=i.max,l=i.direction,c=i.included,u=i.includedStart,d=i.includedEnd,f="".concat(t,"-dot"),h=c&&u<=n&&n<=d,m=Q(Q({},Ek(l,n,a,s)),typeof r=="function"?r(n):r);return h&&(m=Q(Q({},m),typeof o=="function"?o(n):o)),C.createElement("span",{className:me(f,X({},"".concat(f,"-active"),h)),style:m})},qee=function(e){var t=e.prefixCls,n=e.marks,r=e.dots,o=e.style,i=e.activeStyle,a=C.useContext(yl),s=a.min,l=a.max,c=a.step,u=C.useMemo(function(){var d=new Set;if(n.forEach(function(h){d.add(h.value)}),r&&c!==null)for(var f=s;f<=l;)d.add(f),f+=c;return Array.from(d)},[s,l,c,r,n]);return C.createElement("div",{className:"".concat(t,"-step")},u.map(function(d){return C.createElement(Uee,{prefixCls:t,key:d,value:d,style:o,activeStyle:i})}))},bA=function(e){var t=e.prefixCls,n=e.style,r=e.start,o=e.end,i=e.index,a=e.onStartMove,s=e.replaceCls,l=C.useContext(yl),c=l.direction,u=l.min,d=l.max,f=l.disabled,h=l.range,m=l.classNames,p="".concat(t,"-track"),g=rw(r,u,d),v=rw(o,u,d),y=function(x){!f&&a&&a(x,-1)},b={};switch(c){case"rtl":b.right="".concat(g*100,"%"),b.width="".concat(v*100-g*100,"%");break;case"btt":b.bottom="".concat(g*100,"%"),b.height="".concat(v*100-g*100,"%");break;case"ttb":b.top="".concat(g*100,"%"),b.height="".concat(v*100-g*100,"%");break;default:b.left="".concat(g*100,"%"),b.width="".concat(v*100-g*100,"%")}var w=s||me(p,X(X({},"".concat(p,"-").concat(i+1),i!==null&&h),"".concat(t,"-track-draggable"),a),m.track);return C.createElement("div",{className:w,style:Q(Q({},b),n),onMouseDown:y,onTouchStart:y})},Yee=function(e){var t=e.prefixCls,n=e.style,r=e.values,o=e.startPoint,i=e.onStartMove,a=C.useContext(yl),s=a.included,l=a.range,c=a.min,u=a.styles,d=a.classNames,f=C.useMemo(function(){if(!l){if(r.length===0)return[];var m=o??c,p=r[0];return[{start:Math.min(m,p),end:Math.max(m,p)}]}for(var g=[],v=0;v<r.length-1;v+=1)g.push({start:r[v],end:r[v+1]});return g},[r,l,o,c]);if(!s)return null;var h=f!=null&&f.length&&(d.tracks||u.tracks)?C.createElement(bA,{index:null,prefixCls:t,start:f[0].start,end:f[f.length-1].end,replaceCls:me(d.tracks,"".concat(t,"-tracks")),style:u.tracks}):null;return C.createElement(C.Fragment,null,h,f.map(function(m,p){var g=m.start,v=m.end;return C.createElement(bA,{index:p,prefixCls:t,style:Q(Q({},Ts(n,p)),u.track),start:g,end:v,key:p,onStartMove:i})}))},Xee=130;function xA(e){var t="targetTouches"in e?e.targetTouches[0]:e;return{pageX:t.pageX,pageY:t.pageY}}function Kee(e,t,n,r,o,i,a,s,l,c,u){var d=C.useState(null),f=te(d,2),h=f[0],m=f[1],p=C.useState(-1),g=te(p,2),v=g[0],y=g[1],b=C.useState(!1),w=te(b,2),x=w[0],E=w[1],k=C.useState(n),S=te(k,2),O=S[0],A=S[1],$=C.useState(n),M=te($,2),N=M[0],D=M[1],T=C.useRef(null),P=C.useRef(null),I=C.useRef(null),R=C.useContext(Lee),H=R.onDragStart,V=R.onDragChange;mn(function(){v===-1&&A(n)},[n,v]),C.useEffect(function(){return function(){document.removeEventListener("mousemove",T.current),document.removeEventListener("mouseup",P.current),I.current&&(I.current.removeEventListener("touchmove",T.current),I.current.removeEventListener("touchend",P.current))}},[]);var L=function(B,z,G){z!==void 0&&m(z),A(B);var W=B;G&&(W=B.filter(function(q,U){return U!==v})),a(W),V&&V({rawValues:B,deleteIndex:G?v:-1,draggingIndex:v,draggingValue:z})},j=cn(function(B,z,G){if(B===-1){var W=N[0],q=N[N.length-1],U=r-W,Y=o-q,ie=z*(o-r);ie=Math.max(ie,U),ie=Math.min(ie,Y);var K=i(W+ie);ie=K-W;var re=N.map(function(de){return de+ie});L(re)}else{var oe=(o-r)*z,ne=ze(O);ne[B]=N[B];var ae=l(ne,oe,B,"dist");L(ae.values,ae.value,G)}}),_=function(B,z,G){B.stopPropagation();var W=G||n,q=W[z];y(z),m(q),D(W),A(W),E(!1);var U=xA(B),Y=U.pageX,ie=U.pageY,K=!1;H&&H({rawValues:W,draggingIndex:z,draggingValue:q});var re=function(ne){ne.preventDefault();var ae=xA(ne),de=ae.pageX,ge=ae.pageY,Se=de-Y,ye=ge-ie,be=e.current.getBoundingClientRect(),ce=be.width,he=be.height,Te,se;switch(t){case"btt":Te=-ye/he,se=Se;break;case"ttb":Te=ye/he,se=Se;break;case"rtl":Te=-Se/ce,se=ye;break;default:Te=Se/ce,se=ye}K=c?Math.abs(se)>Xee&&u<O.length:!1,E(K),j(z,Te,K)},oe=function ne(ae){ae.preventDefault(),document.removeEventListener("mouseup",ne),document.removeEventListener("mousemove",re),I.current&&(I.current.removeEventListener("touchmove",T.current),I.current.removeEventListener("touchend",P.current)),T.current=null,P.current=null,I.current=null,s(K),y(-1),E(!1)};document.addEventListener("mouseup",oe),document.addEventListener("mousemove",re),B.currentTarget.addEventListener("touchend",oe),B.currentTarget.addEventListener("touchmove",re),T.current=re,P.current=oe,I.current=B.currentTarget},F=C.useMemo(function(){var B=ze(n).sort(function(U,Y){return U-Y}),z=ze(O).sort(function(U,Y){return U-Y}),G={};z.forEach(function(U){G[U]=(G[U]||0)+1}),B.forEach(function(U){G[U]=(G[U]||0)-1});var W=c?1:0,q=Object.values(G).reduce(function(U,Y){return U+Math.abs(Y)},0);return q<=W?O:n},[n,O,c]);return[v,h,x,F,_]}function Zee(e,t,n,r,o,i){var a=C.useCallback(function(h){return Math.max(e,Math.min(t,h))},[e,t]),s=C.useCallback(function(h){if(n!==null){var m=e+Math.round((a(h)-e)/n)*n,p=function(y){return(String(y).split(".")[1]||"").length},g=Math.max(p(n),p(t),p(e)),v=Number(m.toFixed(g));return e<=v&&v<=t?v:null}return null},[n,e,t,a]),l=C.useCallback(function(h){var m=a(h),p=r.map(function(y){return y.value});n!==null&&p.push(s(h)),p.push(e,t);var g=p[0],v=t-e;return p.forEach(function(y){var b=Math.abs(m-y);b<=v&&(g=y,v=b)}),g},[e,t,r,n,a,s]),c=function h(m,p,g){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof p=="number"){var y,b=m[g],w=b+p,x=[];r.forEach(function(A){x.push(A.value)}),x.push(e,t),x.push(s(b));var E=p>0?1:-1;v==="unit"?x.push(s(b+E*n)):x.push(s(w)),x=x.filter(function(A){return A!==null}).filter(function(A){return p<0?A<=b:A>=b}),v==="unit"&&(x=x.filter(function(A){return A!==b}));var k=v==="unit"?b:w;y=x[0];var S=Math.abs(y-k);if(x.forEach(function(A){var $=Math.abs(A-k);$<S&&(y=A,S=$)}),y===void 0)return p<0?e:t;if(v==="dist")return y;if(Math.abs(p)>1){var O=ze(m);return O[g]=y,h(O,p-E,g,v)}return y}else{if(p==="min")return e;if(p==="max")return t}},u=function(h,m,p){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",v=h[p],y=c(h,m,p,g);return{value:y,changed:y!==v}},d=function(h){return i===null&&h===0||typeof i=="number"&&h<i},f=function(h,m,p){var g=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",v=h.map(l),y=v[p],b=c(v,m,p,g);if(v[p]=b,o===!1){var w=i||0;p>0&&v[p-1]!==y&&(v[p]=Math.max(v[p],v[p-1]+w)),p<v.length-1&&v[p+1]!==y&&(v[p]=Math.min(v[p],v[p+1]-w))}else if(typeof i=="number"||i===null){for(var x=p+1;x<v.length;x+=1)for(var E=!0;d(v[x]-v[x-1])&&E;){var k=u(v,1,x);v[x]=k.value,E=k.changed}for(var S=p;S>0;S-=1)for(var O=!0;d(v[S]-v[S-1])&&O;){var A=u(v,-1,S-1);v[S-1]=A.value,O=A.changed}for(var $=v.length-1;$>0;$-=1)for(var M=!0;d(v[$]-v[$-1])&&M;){var N=u(v,-1,$-1);v[$-1]=N.value,M=N.changed}for(var D=0;D<v.length-1;D+=1)for(var T=!0;d(v[D+1]-v[D])&&T;){var P=u(v,1,D+1);v[D+1]=P.value,T=P.changed}}return{value:v[p],values:v}};return[l,f]}function Qee(e){return Gt(function(){if(e===!0||!e)return[!!e,!1,!1,0];var t=e.editable,n=e.draggableTrack,r=e.minCount,o=e.maxCount;return[!0,t,!t&&n,r||0,o]},[e])}var Jee=C.forwardRef(function(e,t){var n=e.prefixCls,r=n===void 0?"rc-slider":n,o=e.className,i=e.style,a=e.classNames,s=e.styles,l=e.id,c=e.disabled,u=c===void 0?!1:c,d=e.keyboard,f=d===void 0?!0:d,h=e.autoFocus,m=e.onFocus,p=e.onBlur,g=e.min,v=g===void 0?0:g,y=e.max,b=y===void 0?100:y,w=e.step,x=w===void 0?1:w,E=e.value,k=e.defaultValue,S=e.range,O=e.count,A=e.onChange,$=e.onBeforeChange,M=e.onAfterChange,N=e.onChangeComplete,D=e.allowCross,T=D===void 0?!0:D,P=e.pushable,I=P===void 0?!1:P,R=e.reverse,H=e.vertical,V=e.included,L=V===void 0?!0:V,j=e.startPoint,_=e.trackStyle,F=e.handleStyle,B=e.railStyle,z=e.dotStyle,G=e.activeDotStyle,W=e.marks,q=e.dots,U=e.handleRender,Y=e.activeHandleRender,ie=e.track,K=e.tabIndex,re=K===void 0?0:K,oe=e.ariaLabelForHandle,ne=e.ariaLabelledByForHandle,ae=e.ariaRequired,de=e.ariaValueTextFormatterForHandle,ge=C.useRef(null),Se=C.useRef(null),ye=C.useMemo(function(){return H?R?"ttb":"btt":R?"rtl":"ltr"},[R,H]),be=Qee(S),ce=te(be,5),he=ce[0],Te=ce[1],se=ce[2],Pe=ce[3],De=ce[4],He=C.useMemo(function(){return isFinite(v)?v:0},[v]),ue=C.useMemo(function(){return isFinite(b)?b:100},[b]),ve=C.useMemo(function(){return x!==null&&x<=0?1:x},[x]),xe=C.useMemo(function(){return typeof I=="boolean"?I?ve:!1:I>=0?I:!1},[I,ve]),fe=C.useMemo(function(){return Object.keys(W||{}).map(function(Ke){var rt=W[Ke],ht={value:Number(Ke)};return rt&&At(rt)==="object"&&!C.isValidElement(rt)&&("label"in rt||"style"in rt)?(ht.style=rt.style,ht.label=rt.label):ht.label=rt,ht}).filter(function(Ke){var rt=Ke.label;return rt||typeof rt=="number"}).sort(function(Ke,rt){return Ke.value-rt.value})},[W]),pe=Zee(He,ue,ve,fe,T,xe),ke=te(pe,2),Ve=ke[0],Ee=ke[1],yt=yr(k,{value:E}),Dt=te(yt,2),Pt=Dt[0],Ut=Dt[1],Ge=C.useMemo(function(){var Ke=Pt==null?[]:Array.isArray(Pt)?Pt:[Pt],rt=te(Ke,1),ht=rt[0],an=ht===void 0?He:ht,dn=Pt===null?[]:[an];if(he){if(dn=ze(Ke),O||Pt===void 0){var Un=O>=0?O+1:2;for(dn=dn.slice(0,Un);dn.length<Un;){var dr;dn.push((dr=dn[dn.length-1])!==null&&dr!==void 0?dr:He)}}dn.sort(function(Nn,Dn){return Nn-Dn})}return dn.forEach(function(Nn,Dn){dn[Dn]=Ve(Nn)}),dn},[Pt,he,He,O,Ve]),Xe=function(Ke){return he?Ke:Ke[0]},qe=cn(function(Ke){var rt=ze(Ke).sort(function(ht,an){return ht-an});A&&!a0(rt,Ge,!0)&&A(Xe(rt)),Ut(rt)}),lt=cn(function(Ke){Ke&&ge.current.hideHelp();var rt=Xe(Ge);M==null||M(rt),qr(!M,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N==null||N(rt)}),je=function(Ke){if(!(u||!Te||Ge.length<=Pe)){var rt=ze(Ge);rt.splice(Ke,1),$==null||$(Xe(rt)),qe(rt);var ht=Math.max(0,Ke-1);ge.current.hideHelp(),ge.current.focus(ht)}},Rt=Kee(Se,ye,Ge,He,ue,Ve,qe,lt,Ee,Te,Pe),zt=te(Rt,5),dt=zt[0],Ct=zt[1],jt=zt[2],Ie=zt[3],Ne=zt[4],Oe=function(Ke,rt){if(!u){var ht=ze(Ge),an=0,dn=0,Un=ue-He;Ge.forEach(function(ar,J){var Z=Math.abs(Ke-ar);Z<=Un&&(Un=Z,an=J),ar<Ke&&(dn=J)});var dr=an;Te&&Un!==0&&(!De||Ge.length<De)?(ht.splice(dn+1,0,Ke),dr=dn+1):ht[an]=Ke,he&&!Ge.length&&O===void 0&&ht.push(Ke);var Nn=Xe(ht);if($==null||$(Nn),qe(ht),rt){var Dn,wr;(Dn=document.activeElement)===null||Dn===void 0||(wr=Dn.blur)===null||wr===void 0||wr.call(Dn),ge.current.focus(dr),Ne(rt,dr,ht)}else M==null||M(Nn),qr(!M,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N==null||N(Nn)}},_e=function(Ke){Ke.preventDefault();var rt=Se.current.getBoundingClientRect(),ht=rt.width,an=rt.height,dn=rt.left,Un=rt.top,dr=rt.bottom,Nn=rt.right,Dn=Ke.clientX,wr=Ke.clientY,ar;switch(ye){case"btt":ar=(dr-wr)/an;break;case"ttb":ar=(wr-Un)/an;break;case"rtl":ar=(Nn-Dn)/ht;break;default:ar=(Dn-dn)/ht}var J=He+ar*(ue-He);Oe(Ve(J),Ke)},mt=C.useState(null),kt=te(mt,2),It=kt[0],Xt=kt[1],on=function(Ke,rt){if(!u){var ht=Ee(Ge,Ke,rt);$==null||$(Xe(Ge)),qe(ht.values),Xt(ht.value)}};C.useEffect(function(){if(It!==null){var Ke=Ge.indexOf(It);Ke>=0&&ge.current.focus(Ke)}Xt(null)},[It]);var qt=C.useMemo(function(){return se&&ve===null?!1:se},[se,ve]),wn=cn(function(Ke,rt){Ne(Ke,rt),$==null||$(Xe(Ge))}),vn=dt!==-1;C.useEffect(function(){if(!vn){var Ke=Ge.lastIndexOf(Ct);ge.current.focus(Ke)}},[vn]);var Kt=C.useMemo(function(){return ze(Ie).sort(function(Ke,rt){return Ke-rt})},[Ie]),$n=C.useMemo(function(){return he?[Kt[0],Kt[Kt.length-1]]:[He,Kt[0]]},[Kt,he,He]),On=te($n,2),ur=On[0],We=On[1];C.useImperativeHandle(t,function(){return{focus:function(){ge.current.focus(0)},blur:function(){var Ke,rt=document,ht=rt.activeElement;(Ke=Se.current)!==null&&Ke!==void 0&&Ke.contains(ht)&&(ht==null||ht.blur())}}}),C.useEffect(function(){h&&ge.current.focus(0)},[]);var pt=C.useMemo(function(){return{min:He,max:ue,direction:ye,disabled:u,keyboard:f,step:ve,included:L,includedStart:ur,includedEnd:We,range:he,tabIndex:re,ariaLabelForHandle:oe,ariaLabelledByForHandle:ne,ariaRequired:ae,ariaValueTextFormatterForHandle:de,styles:s||{},classNames:a||{}}},[He,ue,ye,u,f,ve,L,ur,We,he,re,oe,ne,ae,de,s,a]);return C.createElement(yl.Provider,{value:pt},C.createElement("div",{ref:Se,className:me(r,o,X(X(X(X({},"".concat(r,"-disabled"),u),"".concat(r,"-vertical"),H),"".concat(r,"-horizontal"),!H),"".concat(r,"-with-marks"),fe.length)),style:i,onMouseDown:_e,id:l},C.createElement("div",{className:me("".concat(r,"-rail"),a==null?void 0:a.rail),style:Q(Q({},B),s==null?void 0:s.rail)}),ie!==!1&&C.createElement(Yee,{prefixCls:r,style:_,values:Ge,startPoint:j,onStartMove:qt?wn:void 0}),C.createElement(qee,{prefixCls:r,marks:fe,dots:q,style:z,activeStyle:G}),C.createElement(Wee,{ref:ge,prefixCls:r,style:F,values:Ie,draggingIndex:dt,draggingDelete:jt,onStartMove:wn,onOffsetChange:on,onFocus:m,onBlur:p,handleRender:U,activeHandleRender:Y,onChangeComplete:lt,onDelete:Te?je:void 0}),C.createElement(Gee,{prefixCls:r,marks:fe,onClick:Oe})))});const ete=us({}),EA=C.forwardRef((e,t)=>{const{open:n,draggingDelete:r,value:o}=e,i=et(null),a=n&&!r,s=et(null);function l(){en.cancel(s.current),s.current=null}function c(){s.current=en(()=>{var u;(u=i.current)===null||u===void 0||u.forceAlign(),s.current=null})}return C.useEffect(()=>(a?c():l(),l),[a,e.title,o]),C.createElement(Nd,Object.assign({ref:oi(i,t)},e,{open:a}))}),tte=e=>{const{componentCls:t,antCls:n,controlSize:r,dotSize:o,marginFull:i,marginPart:a,colorFillContentHover:s,handleColorDisabled:l,calc:c,handleSize:u,handleSizeHover:d,handleActiveColor:f,handleActiveOutlineColor:h,handleLineWidth:m,handleLineWidthHover:p,motionDurationMid:g}=e;return{[t]:Object.assign(Object.assign({},br(e)),{position:"relative",height:r,margin:`${Ce(a)} ${Ce(i)}`,padding:0,cursor:"pointer",touchAction:"none","&-vertical":{margin:`${Ce(i)} ${Ce(a)}`},[`${t}-rail`]:{position:"absolute",backgroundColor:e.railBg,borderRadius:e.borderRadiusXS,transition:`background-color ${g}`},[`${t}-track,${t}-tracks`]:{position:"absolute",transition:`background-color ${g}`},[`${t}-track`]:{backgroundColor:e.trackBg,borderRadius:e.borderRadiusXS},[`${t}-track-draggable`]:{boxSizing:"content-box",backgroundClip:"content-box",border:"solid rgba(0,0,0,0)"},"&:hover":{[`${t}-rail`]:{backgroundColor:e.railHoverBg},[`${t}-track`]:{backgroundColor:e.trackHoverBg},[`${t}-dot`]:{borderColor:s},[`${t}-handle::after`]:{boxShadow:`0 0 0 ${Ce(m)} ${e.colorPrimaryBorderHover}`},[`${t}-dot-active`]:{borderColor:e.dotActiveBorderColor}},[`${t}-handle`]:{position:"absolute",width:u,height:u,outline:"none",userSelect:"none","&-dragging-delete":{opacity:0},"&::before":{content:'""',position:"absolute",insetInlineStart:c(m).mul(-1).equal(),insetBlockStart:c(m).mul(-1).equal(),width:c(u).add(c(m).mul(2)).equal(),height:c(u).add(c(m).mul(2)).equal(),backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:u,height:u,backgroundColor:e.colorBgElevated,boxShadow:`0 0 0 ${Ce(m)} ${e.handleColor}`,outline:"0px solid transparent",borderRadius:"50%",cursor:"pointer",transition:`
|
|
361
361
|
inset-inline-start ${g},
|
|
362
362
|
inset-block-start ${g},
|
|
363
363
|
width ${g},
|
|
@@ -467,7 +467,7 @@ ${v.substring(Y)}`;y(ie),requestAnimationFrame(()=>{q.selectionStart=q.selection
|
|
|
467
467
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
468
468
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
469
469
|
THE SOFTWARE.
|
|
470
|
-
*/function sw(e){if(e.constructor!==Array)throw new TypeError("Expected array.");if(e.length===16)return e;if(e.length===6){var t=Lc();return t[0]=e[0],t[1]=e[1],t[4]=e[2],t[5]=e[3],t[12]=e[4],t[13]=e[5],t}throw new RangeError("Expected array with either 6 or 16 values.")}function Lc(){for(var e=[],t=0;t<16;t++)t%5==0?e.push(1):e.push(0);return e}function uoe(e,t){for(var n=sw(e),r=sw(t),o=[],i=0;i<4;i++)for(var a=[n[i],n[i+4],n[i+8],n[i+12]],s=0;s<4;s++){var l=s*4,c=[r[l],r[l+1],r[l+2],r[l+3]],u=a[0]*c[0]+a[1]*c[1]+a[2]*c[2]+a[3]*c[3];o[i+l]=u}return o}function doe(e){if(typeof e=="string"){var t=e.match(/matrix(3d)?\(([^)]+)\)/);if(t){var n=t[2].split(", ").map(parseFloat);return sw(n)}}return Lc()}function foe(e){var t=Lc();return t[0]=e,t}function hoe(e){var t=Lc();return t[5]=e,t}function poe(e){var t=Lc();return t[12]=e,t}function goe(e){var t=Lc();return t[13]=e,t}var uh=function(e){return typeof e=="number"},n9=function(e){return typeof e=="function"},r9=function(e){return Object.prototype.toString.call(e)==="[object Object]"},ic=function(e){return Array.prototype.slice.apply(e)},o9=function(e){var t=e.reduce(function(n,r){return n[r]=(n[r]||0)+1,n},{});return Object.keys(t).filter(function(n){return t[n]>1})};function Ra(e){return[].slice.call(arguments,1).forEach(function(t){if(t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}),e}var lw,cw=function(e,t,n){return e+(t-e)*n},i9={__proto__:null,isNumber:uh,isFunction:n9,isObject:r9,toArray:ic,getDuplicateValsAsStrings:o9,assign:Ra,tweenProp:cw},Ak="data-flip-id",$k="data-inverse-flip-id",Ok="data-portal-key",moe="data-exit-container",pf={__proto__:null,DATA_FLIP_ID:Ak,DATA_INVERSE_FLIP_ID:$k,DATA_FLIP_CONFIG:"data-flip-config",DATA_PORTAL_KEY:Ok},uw={noWobble:{stiffness:200,damping:26},gentle:{stiffness:120,damping:14},veryGentle:{stiffness:130,damping:17},wobbly:{stiffness:180,damping:12},stiff:{stiffness:260,damping:26}},BA=function(e){return r9(e)?e:Object.keys(uw).indexOf(e)>-1?uw[e]:{}};typeof window<"u"&&(lw=window.requestAnimationFrame);var voe=lw=lw||function(e){window.setTimeout(e,1e3/60)},yoe=Date.now(),boe=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()-yoe};function a9(e,t){var n=e.indexOf(t);n!==-1&&e.splice(n,1)}var xoe=(function(){function e(){}return e.prototype.run=function(){var t=this;voe(function(){t.springSystem.loop(boe())})},e})(),Im=function(){this.position=0,this.velocity=0},Eoe=0,Ho=.001,woe=(function(){function e(n){this._id="s"+Eoe++,this._springSystem=n,this.listeners=[],this._startValue=0,this._currentState=new Im,this._displacementFromRestThreshold=.001,this._endValue=0,this._overshootClampingEnabled=!1,this._previousState=new Im,this._restSpeedThreshold=.001,this._tempState=new Im,this._timeAccumulator=0,this._wasAtRest=!0,this._cachedSpringConfig={}}var t=e.prototype;return t.getId=function(){return this._id},t.destroy=function(){this.listeners=[],this._springSystem.deregisterSpring(this)},t.setSpringConfig=function(n){return this._springConfig=n,this},t.getCurrentValue=function(){return this._currentState.position},t.getDisplacementDistanceForState=function(n){return Math.abs(this._endValue-n.position)},t.setEndValue=function(n){if(n===this._endValue)return this;if(this.prevEndValue=n,this._endValue===n&&this.isAtRest())return this;this._startValue=this.getCurrentValue(),this._endValue=n,this._springSystem.activateSpring(this.getId());for(var r=0,o=this.listeners.length;r<o;r++){var i=this.listeners[r].onSpringEndStateChange;i&&i(this)}return this},t.setVelocity=function(n){return n===this._currentState.velocity||(this._currentState.velocity=n,this._springSystem.activateSpring(this.getId())),this},t.setCurrentValue=function(n){this._startValue=n,this._currentState.position=n;for(var r=0,o=this.listeners.length;r<o;r++){var i=this.listeners[r];i.onSpringUpdate&&i.onSpringUpdate(this)}return this},t.setAtRest=function(){return this._endValue=this._currentState.position,this._tempState.position=this._currentState.position,this._currentState.velocity=0,this},t.setOvershootClampingEnabled=function(n){return this._overshootClampingEnabled=n,this},t.isOvershooting=function(){var n=this._startValue,r=this._endValue;return this._springConfig.tension>0&&(n<r&&this.getCurrentValue()>r||n>r&&this.getCurrentValue()<r)},t.advance=function(n,r){var o=this.isAtRest();if(!o||!this._wasAtRest){var i=r;r>.064&&(i=.064),this._timeAccumulator+=i;for(var a,s,l,c,u,d,f=this._springConfig.tension,h=this._springConfig.friction,m=this._currentState.position,p=this._currentState.velocity,g=this._tempState.position,v=this._tempState.velocity;this._timeAccumulator>=Ho;)this._timeAccumulator-=Ho,this._timeAccumulator<Ho&&(this._previousState.position=m,this._previousState.velocity=p),s=f*(this._endValue-g)-h*p,c=f*(this._endValue-(g=m+(a=p)*Ho*.5))-h*(v=p+s*Ho*.5),d=f*(this._endValue-(g=m+(l=v)*Ho*.5))-h*(v=p+c*Ho*.5),g=m+(u=v)*Ho,m+=1/6*(a+2*(l+u)+(v=p+d*Ho))*Ho,p+=1/6*(s+2*(c+d)+(f*(this._endValue-g)-h*v))*Ho;this._tempState.position=g,this._tempState.velocity=v,this._currentState.position=m,this._currentState.velocity=p,this._timeAccumulator>0&&this._interpolate(this._timeAccumulator/Ho),(this.isAtRest()||this._overshootClampingEnabled&&this.isOvershooting())&&(this._springConfig.tension>0?(this._startValue=this._endValue,this._currentState.position=this._endValue):(this._endValue=this._currentState.position,this._startValue=this._endValue),this.setVelocity(0),o=!0);var y=!1;this._wasAtRest&&(this._wasAtRest=!1,y=!0);var b=!1;o&&(this._wasAtRest=!0,b=!0),this.notifyPositionUpdated(y,b)}},t.notifyPositionUpdated=function(n,r){var o=this;this.listeners.filter(Boolean).forEach(function(i){n&&i.onSpringActivate&&!o._onActivateCalled&&(i.onSpringActivate(o),o._onActivateCalled=!0),i.onSpringUpdate&&i.onSpringUpdate(o),r&&i.onSpringAtRest&&i.onSpringAtRest(o)})},t.systemShouldAdvance=function(){return!this.isAtRest()||!this.wasAtRest()},t.wasAtRest=function(){return this._wasAtRest},t.isAtRest=function(){return Math.abs(this._currentState.velocity)<this._restSpeedThreshold&&(this.getDisplacementDistanceForState(this._currentState)<=this._displacementFromRestThreshold||this._springConfig.tension===0)},t._interpolate=function(n){this._currentState.position=this._currentState.position*n+this._previousState.position*(1-n),this._currentState.velocity=this._currentState.velocity*n+this._previousState.velocity*(1-n)},t.addListener=function(n){return this.listeners.push(n),this},t.addOneTimeListener=function(n){var r=this;return Object.keys(n).forEach(function(o){var i;n[o]=(i=n[o],function(){i.apply(void 0,[].slice.call(arguments)),r.removeListener(n)})}),this.listeners.push(n),this},t.removeListener=function(n){return a9(this.listeners,n),this},e})(),s9=(function(){function e(n){this.looper=n||new xoe,this.looper.springSystem=this,this.listeners=[],this._activeSprings=[],this._idleSpringIndices=[],this._isIdle=!0,this._lastTimeMillis=-1,this._springRegistry={}}var t=e.prototype;return t.createSpring=function(n,r){return this.createSpringWithConfig({tension:n,friction:r})},t.createSpringWithConfig=function(n){var r=new woe(this);return this.registerSpring(r),r.setSpringConfig(n),r},t.getIsIdle=function(){return this._isIdle},t.registerSpring=function(n){this._springRegistry[n.getId()]=n},t.deregisterSpring=function(n){a9(this._activeSprings,n),delete this._springRegistry[n.getId()]},t.advance=function(n,r){for(var o=this;this._idleSpringIndices.length>0;)this._idleSpringIndices.pop();for(this._activeSprings.filter(Boolean).forEach(function(a){a.systemShouldAdvance()?a.advance(n/1e3,r/1e3):o._idleSpringIndices.push(o._activeSprings.indexOf(a))});this._idleSpringIndices.length>0;){var i=this._idleSpringIndices.pop();i>=0&&this._activeSprings.splice(i,1)}},t.loop=function(n){var r;this._lastTimeMillis===-1&&(this._lastTimeMillis=n-1);var o=n-this._lastTimeMillis;this._lastTimeMillis=n;var i=0,a=this.listeners.length;for(i=0;i<a;i++)(r=this.listeners[i]).onBeforeIntegrate&&r.onBeforeIntegrate(this);for(this.advance(n,o),this._activeSprings.length===0&&(this._isIdle=!0,this._lastTimeMillis=-1),i=0;i<a;i++)(r=this.listeners[i]).onAfterIntegrate&&r.onAfterIntegrate(this);this._isIdle||this.looper.run()},t.activateSpring=function(n){var r=this._springRegistry[n];this._activeSprings.indexOf(r)===-1&&this._activeSprings.push(r),this.getIsIdle()&&(this._isIdle=!1,this.looper.run())},e})(),Coe=new s9,l9=function(e){var t=e.springConfig,n=t.overshootClamping,r=e.getOnUpdateFunc,o=e.onAnimationEnd,i=e.onSpringActivate,a=Coe.createSpring(t.stiffness,t.damping);a.setOvershootClampingEnabled(!!n);var s={onSpringActivate:i,onSpringAtRest:function(){a.destroy(),o()},onSpringUpdate:r({spring:a,onAnimationEnd:o})};return a.addListener(s),a},RA=function(e){var t=l9(e);return t.setEndValue(1),t},_A=function(e,t){if(t===void 0&&(t={}),e&&e.length){t.reverse&&e.reverse();var n,r=typeof(n=t.speed)!="number"?1.1:1+Math.min(Math.max(5*n,0),5),o=1/Math.max(Math.min(e.length,100),10),i=e.map(function(a,s){var l=a.getOnUpdateFunc;return a.getOnUpdateFunc=function(c){var u=l(c);return function(d){var f=d.getCurrentValue();(f=f<.01?0:f>.99?1:f)>=o&&i[s+1]&&i[s+1](Math.max(Math.min(f*r,1),0)),u(d)}},a}).map(function(a){var s=l9(a);if(s)return s.setEndValue.bind(s)}).filter(Boolean);i[0]&&i[0](1)}},jA=function(e){return[0,1,4,5,12,13].map(function(t){return e[t]})},LA=function(e){return e.top<window.innerHeight&&e.bottom>0&&e.left<window.innerWidth&&e.right>0};function zA(e){return JSON.parse(e.dataset.flipConfig||"{}")}var c9=function(e,t){var n;return Ra(e,((n={})[t[0]]=t[1],n))},u9=function(e,t){return ic(t?document.querySelectorAll("["+Ok+'="'+t+'"]'):e.querySelectorAll("["+Ak+"]"))},d9=function(e){return e.map(function(t){return[t,t.getBoundingClientRect()]})},koe=function(e){var t=e.cachedOrderedFlipIds,n=t===void 0?[]:t,r=e.inProgressAnimations,o=r===void 0?{}:r,i=e.flippedElementPositionsBeforeUpdate,a=i===void 0?{}:i,s=e.flipCallbacks,l=s===void 0?{}:s,c=e.containerEl,u=e.applyTransformOrigin,d=e.spring,f=e.debug,h=e.portalKey,m=e.staggerConfig,p=m===void 0?{}:m,g=e.decisionData,v=g===void 0?{}:g,y=e.handleEnterUpdateDelete,b=e.onComplete,w=e.onStart;if(!window.matchMedia("(prefers-reduced-motion: reduce)").matches){var x,E=d9(u9((x={element:c,portalKey:h}).element,x.portalKey)).map(function(R){var H=R[0],V=R[1],L=window.getComputedStyle(H);return[H.dataset.flipId,{element:H,rect:V,opacity:parseFloat(L.opacity),transform:L.transform}]}).reduce(c9,{}),k=(function(R){var H=R.containerEl,V=R.portalKey;return V?(function(L){return function(j){return ic(document.querySelectorAll("["+Ok+'="'+L+'"]'+j))}})(V):H?(function(L){var j=Math.random().toFixed(5);return L.dataset.flipperId=j,function(_){return ic(L.querySelectorAll('[data-flipper-id="'+j+'"] '+_))}})(H):function(){return[]}})({containerEl:c,portalKey:h}),S=(function(R){return function(H){return R("["+Ak+'="'+H+'"]')[0]}})(k),O=function(R){return a[R]&&E[R]},A=Object.keys(a).concat(Object.keys(E)).filter(function(R){return!O(R)}),$={flipCallbacks:l,getElement:S,flippedElementPositionsBeforeUpdate:a,flippedElementPositionsAfterUpdate:E,inProgressAnimations:o,decisionData:v},M=(function(R){var H,V=R.unflippedIds,L=R.flipCallbacks,j=R.getElement,_=R.flippedElementPositionsBeforeUpdate,F=R.flippedElementPositionsAfterUpdate,B=R.inProgressAnimations,z=R.decisionData,G=V.filter(function(K){return F[K]}).filter(function(K){return L[K]&&L[K].onAppear}),W=V.filter(function(K){return _[K]&&L[K]&&L[K].onExit}),q=new Promise(function(K){H=K}),U=[],Y=0,ie=W.map(function(K,re){var oe=_[K].domDataForExitAnimations,ne=oe.element,ae=oe.parent,de=oe.childPosition,ge=de.top,Se=de.left,ye=de.width,be=de.height;getComputedStyle(ae).position==="static"&&(ae.style.position="relative"),ne.style.transform="matrix(1, 0, 0, 1, 0, 0)",ne.style.position="absolute",ne.style.top=ge+"px",ne.style.left=Se+"px",ne.style.height=be+"px",ne.style.width=ye+"px";var ce=U.filter(function(Te){return Te[0]===ae})[0];ce||(ce=[ae,document.createDocumentFragment()],U.push(ce)),ce[1].appendChild(ne),Y+=1;var he=function(){try{ae.removeChild(ne)}catch{}finally{(Y-=1)==0&&H()}};return B[K]={stop:he},function(){return L[K].onExit(ne,re,he,z)}});return U.forEach(function(K){K[0].appendChild(K[1])}),ie.length||H(),{hideEnteringElements:function(){G.forEach(function(K){var re=j(K);re&&(re.style.opacity="0")})},animateEnteringElements:function(){G.forEach(function(K,re){var oe=j(K);oe&&L[K].onAppear(oe,re,z)})},animateExitingElements:function(){return ie.forEach(function(K){return K()}),q}}})(Ra({},$,{unflippedIds:A})),N=M.hideEnteringElements,D=M.animateEnteringElements,T=M.animateExitingElements,P=Ra({},$,{containerEl:c,flippedIds:n.filter(O),applyTransformOrigin:u,spring:d,debug:f,staggerConfig:p,scopedSelector:k,onComplete:b});w&&w(c,v);var I=(function(R){var H,V=R.flippedIds,L=R.flipCallbacks,j=R.inProgressAnimations,_=R.flippedElementPositionsBeforeUpdate,F=R.flippedElementPositionsAfterUpdate,B=R.applyTransformOrigin,z=R.spring,G=R.getElement,W=R.debug,q=R.staggerConfig,U=q===void 0?{}:q,Y=R.decisionData,ie=Y===void 0?{}:Y,K=R.onComplete,re=R.containerEl,oe=new Promise(function(se){H=se});if(K&&oe.then(function(){return K(re,ie)}),!V.length)return function(){return H([]),oe};var ne=[],ae=G(V[0]),de=ae?ae.ownerDocument.querySelector("body"):document.querySelector("body");o9(V);var ge=V.map(function(se){var Pe=_[se].rect,De=F[se].rect,He=_[se].opacity,ue=F[se].opacity,ve=De.width<1||De.height<1,xe=F[se].element;if(!LA(Pe)&&!LA(De)||!xe)return!1;var fe,pe,ke,Ve=zA(xe),Ee=(ke=(pe=(fe={flipperSpring:z,flippedSpring:Ve.spring})===void 0?{}:fe).flippedSpring,Ra({},uw.noWobble,BA(pe.flipperSpring),BA(ke))),yt=Ve.stagger===!0?"default":Ve.stagger,Dt={element:xe,id:se,stagger:yt,springConfig:Ee};if(L[se]&&L[se].shouldFlip&&!L[se].shouldFlip(ie.previous,ie.current))return!1;var Ft=Math.abs(Pe.left-De.left)+Math.abs(Pe.top-De.top),Ut=Math.abs(Pe.width-De.width)+Math.abs(Pe.height-De.height),Ge=Math.abs(ue-He);if(Pe.height===0&&De.height===0||Pe.width===0&&De.width===0||Ft<.5&&Ut<.5&&Ge<.01)return!1;var Xe=doe(F[se].transform),qe={matrix:Xe},lt={matrix:[]},je=[Xe];Ve.translate&&(je.push(poe(Pe.left-De.left)),je.push(goe(Pe.top-De.top))),Ve.scale&&(je.push(foe(Math.max(Pe.width,1)/Math.max(De.width,1))),je.push(hoe(Math.max(Pe.height,1)/Math.max(De.height,1)))),Ve.opacity&&(lt.opacity=He,qe.opacity=ue);var Rt=[];if(!L[se]||!L[se].shouldInvert||L[se].shouldInvert(ie.previous,ie.current)){var zt=(function(Oe,_e){return ic(Oe.querySelectorAll("["+$k+'="'+_e+'"]'))})(xe,se);Rt=zt.map(function(Oe){return[Oe,zA(Oe)]})}lt.matrix=jA(je.reduce(uoe)),qe.matrix=jA(qe.matrix);var dt,Ct=(function(Oe){var _e=Oe.element,mt=Oe.invertedChildren,kt=Oe.body;return function(Pt){var Xt=Pt.matrix,on=Pt.opacity,qt=Pt.forceMinVals;if(uh(on)&&(_e.style.opacity=on+""),qt&&(_e.style.minHeight="1px",_e.style.minWidth="1px"),Xt){var wn=(function(vn){return"matrix("+vn.join(", ")+")"})(Xt);_e.style.transform=wn,mt&&(function(vn){var Kt=vn.matrix,$n=vn.body;vn.invertedChildren.forEach(function(On){var ur=On[0],We=On[1];if($n.contains(ur)){var pt=Kt[0],Ke=Kt[3],rt=Kt[5],ht={translateX:0,translateY:0,scaleX:1,scaleY:1},an="";We.translate&&(ht.translateX=-Kt[4]/pt,ht.translateY=-rt/Ke,an+="translate("+ht.translateX+"px, "+ht.translateY+"px)"),We.scale&&(ht.scaleX=1/pt,ht.scaleY=1/Ke,an+=" scale("+ht.scaleX+", "+ht.scaleY+")"),ur.style.transform=an}})})({invertedChildren:mt,matrix:Xt,body:kt})}}})({element:xe,invertedChildren:Rt,body:de});if(L[se]&&L[se].onComplete){var jt=L[se].onComplete;dt=function(){return jt(xe,ie)}}var Ie=uh(lt.opacity)&&uh(qe.opacity)&<.opacity!==qe.opacity,Ne=!1;return Ra({},Dt,{stagger:yt,springConfig:Ee,getOnUpdateFunc:function(Oe){var _e=Oe.spring,mt=Oe.onAnimationEnd;return j[se]={destroy:_e.destroy.bind(_e),onAnimationEnd:mt},function(kt){L[se]&&L[se].onSpringUpdate&&L[se].onSpringUpdate(kt.getCurrentValue()),Ne||(Ne=!0,L[se]&&L[se].onStart&&L[se].onStart(xe,ie));var Pt=kt.getCurrentValue();if(de.contains(xe)){var Xt={matrix:[]};Xt.matrix=lt.matrix.map(function(on,qt){return cw(on,qe.matrix[qt],Pt)}),Ie&&(Xt.opacity=cw(lt.opacity,qe.opacity,Pt)),Ct(Xt)}else kt.destroy()}},initializeFlip:function(){Ct({matrix:lt.matrix,opacity:Ie?lt.opacity:void 0,forceMinVals:ve}),L[se]&&L[se].onStartImmediate&&L[se].onStartImmediate(xe,ie),Ve.transformOrigin?xe.style.transformOrigin=Ve.transformOrigin:B&&(xe.style.transformOrigin="0 0"),Rt.forEach(function(Oe){var _e=Oe[0],mt=Oe[1];mt.transformOrigin?_e.style.transformOrigin=mt.transformOrigin:B&&(_e.style.transformOrigin="0 0")})},onAnimationEnd:function(Oe){delete j[se],n9(dt)&&dt(),xe.style.transform="",Rt.forEach(function(_e){_e[0].style.transform=""}),ve&&xe&&(xe.style.minHeight="",xe.style.minWidth=""),Oe||(ne.push(se),ne.length>=ge.length&&H(ne))},delayUntil:Ve.delayUntil})}).filter(Boolean);if(ge.forEach(function(se){return(0,se.initializeFlip)()}),W)return function(){};var Se=ge.filter(function(se){return se.delayUntil&&(Pe=se.delayUntil,ge.filter(function(De){return De.id===Pe}).length);var Pe}),ye={},be={},ce={};Se.forEach(function(se){se.stagger?(ce[se.stagger]=!0,be[se.delayUntil]?be[se.delayUntil].push(se.stagger):be[se.delayUntil]=[se.stagger]):ye[se.delayUntil]?ye[se.delayUntil].push(se):ye[se.delayUntil]=[se]});var he=ge.filter(function(se){return se.stagger}).reduce(function(se,Pe){return se[Pe.stagger]?se[Pe.stagger].push(Pe):se[Pe.stagger]=[Pe],se},{}),Te=ge.filter(function(se){return Se.indexOf(se)===-1});return Te.forEach(function(se){se.onSpringActivate=function(){ye[se.id]&&ye[se.id].forEach(RA),be[se.id]&&Object.keys(be[se.id].reduce(function(Pe,De){var He;return Ra(Pe,((He={})[De]=!0,He))},{})).forEach(function(Pe){_A(he[Pe],U[Pe])})}}),function(){return ge.length||H([]),Te.filter(function(se){return!se.stagger}).forEach(RA),Object.keys(he).forEach(function(se){ce[se]||_A(he[se],U[se])}),oe}})(P);y?y({hideEnteringElements:N,animateEnteringElements:D,animateExitingElements:T,animateFlippedElements:I}):(N(),T().then(D),I())}},Soe=function(e){var t=e.element,n=e.flipCallbacks,r=n===void 0?{}:n,o=e.inProgressAnimations,i=o===void 0?{}:o,a=u9(t,e.portalKey),s=ic(t.querySelectorAll("["+$k+"]")),l={},c=[],u={};a.filter(function(h){return r&&r[h.dataset.flipId]&&r[h.dataset.flipId].onExit}).forEach(function(h){var m=h.parentNode;if(h.closest){var p=h.closest("["+moe+"]");p&&(m=p)}var g=c.findIndex(function(v){return v[0]===m});g===-1&&(c.push([m,m.getBoundingClientRect()]),g=c.length-1),l[h.dataset.flipId]=c[g][1],u[h.dataset.flipId]=m});var d=d9(a),f=d.map(function(h){var m=h[0],p=h[1],g={};if(r&&r[m.dataset.flipId]&&r[m.dataset.flipId].onExit){var v=l[m.dataset.flipId];Ra(g,{element:m,parent:u[m.dataset.flipId],childPosition:{top:p.top-v.top,left:p.left-v.left,width:p.width,height:p.height}})}return[m.dataset.flipId,{rect:p,opacity:parseFloat(window.getComputedStyle(m).opacity||"1"),domDataForExitAnimations:g}]}).reduce(c9,{});return(function(h,m){Object.keys(h).forEach(function(p){h[p].destroy&&h[p].destroy(),h[p].onAnimationEnd&&h[p].onAnimationEnd(!0),delete h[p]}),m.forEach(function(p){p.style.transform="",p.style.opacity=""})})(i,a.concat(s)),{flippedElementPositions:f,cachedOrderedFlipIds:d.map(function(h){return h[0].dataset.flipId})}};new s9;function E0(){return E0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},E0.apply(this,arguments)}function dw(e,t){return dw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},dw(e,t)}function f9(e,t){if(e==null)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(o[n]=e[n]);return o}var h9=us({}),p9=us("portal"),g9=(function(e){var t,n;function r(){for(var i,a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];return(i=e.call.apply(e,[this].concat(s))||this).inProgressAnimations={},i.flipCallbacks={},i.el=void 0,i}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,dw(t,n);var o=r.prototype;return o.getSnapshotBeforeUpdate=function(i){return i.flipKey!==this.props.flipKey&&this.el?Soe({element:this.el,flipCallbacks:this.flipCallbacks,inProgressAnimations:this.inProgressAnimations,portalKey:this.props.portalKey}):null},o.componentDidUpdate=function(i,a,s){this.props.flipKey!==i.flipKey&&this.el&&koe({flippedElementPositionsBeforeUpdate:s.flippedElementPositions,cachedOrderedFlipIds:s.cachedOrderedFlipIds,containerEl:this.el,inProgressAnimations:this.inProgressAnimations,flipCallbacks:this.flipCallbacks,applyTransformOrigin:this.props.applyTransformOrigin,spring:this.props.spring,debug:this.props.debug,portalKey:this.props.portalKey,staggerConfig:this.props.staggerConfig,handleEnterUpdateDelete:this.props.handleEnterUpdateDelete,decisionData:{previous:i.decisionData,current:this.props.decisionData},onComplete:this.props.onComplete,onStart:this.props.onStart})},o.render=function(){var i=this,a=this.props,s=a.portalKey,l=we.createElement(h9.Provider,{value:this.flipCallbacks},we.createElement(a.element,{className:a.className,ref:function(c){return i.el=c}},this.props.children));return s&&(l=we.createElement(p9.Provider,{value:s},l)),l},r})(Bz);g9.defaultProps={applyTransformOrigin:!0,element:"div"};var Aoe=["children","flipId","inverseFlipId","portalKey"],$oe=["children","flipId","shouldFlip","shouldInvert","onAppear","onStart","onStartImmediate","onComplete","onExit","onSpringUpdate"],HA=function(e){var t,n=e.children,r=e.flipId,o=e.inverseFlipId,i=e.portalKey,a=f9(e,Aoe),s=n,l=(function(u){return typeof u=="function"})(s);if(!l)try{s=AF.only(n)}catch{throw new Error("Each Flipped component must wrap a single child")}a.scale||a.translate||a.opacity||i9.assign(a,{translate:!0,scale:!0,opacity:!0});var c=((t={})[pf.DATA_FLIP_CONFIG]=JSON.stringify(a),t);return r!==void 0?c[pf.DATA_FLIP_ID]=String(r):o&&(c[pf.DATA_INVERSE_FLIP_ID]=String(o)),i!==void 0&&(c[pf.DATA_PORTAL_KEY]=i),l?s(c):OF(s,c)},m9=function(e){var t=e.children,n=e.flipId,r=e.shouldFlip,o=e.shouldInvert,i=e.onAppear,a=e.onStart,s=e.onStartImmediate,l=e.onComplete,c=e.onExit,u=e.onSpringUpdate,d=f9(e,$oe);return t?d.inverseFlipId?we.createElement(HA,E0({},d),t):we.createElement(p9.Consumer,null,function(f){return we.createElement(h9.Consumer,null,function(h){return i9.isObject(h)&&n&&(h[n]={shouldFlip:r,shouldInvert:o,onAppear:i,onStart:a,onStartImmediate:s,onComplete:l,onExit:c,onSpringUpdate:u}),we.createElement(HA,E0({flipId:n},d,{portalKey:f}),t)})}):null};m9.displayName="Flipped";function Ooe(e){const{data:t,activedItem:n,onChange:r,onDelete:o,sortRules:i=[{label:"\u5F53\u5929",dayPeriod:1}],eventsEmit:a,assistantList:s,height:l=400,styles:c={},hasMore:u=!1,loadingMore:d=!1}=e,f=t.map(O=>O.sessionId+"-"+O.gmtModified).join(","),h=Gt(()=>{const O=i.length>0?i:[{label:"\u5F53\u5929",dayPeriod:1}],A=coe(t,O),$=O.every(N=>!A[N.label]||A[N.label].length===0),M=[];return O.forEach(N=>{A[N.label]&&A[N.label].length>0&&(M.push({type:"group",label:N.label}),A[N.label].forEach(D=>M.push({type:"item",data:D})))}),A.other.length>0&&!$&&(M.push({type:"group",label:"\u5176\u4ED6"}),A.other.forEach(N=>M.push({type:"item",data:N}))),$&&A.other.length>0&&A.other.forEach(N=>M.push({type:"item",data:N})),M},[t,i,f]),m=Gt(()=>h.map(O=>O.type==="group"?`g:${O.label}`:`i:${O.data.sessionId}`).join("|"),[h]),p=56,g=14,v=36,y=O=>O===h.length?v:h[O].type==="group"?32:p+g,b=et(null),w=Gt(()=>h.findIndex(O=>{var A;return O.type==="item"&&((A=O.data)==null?void 0:A.sessionId)===n}),[h,n]),x=Gt(()=>h.findIndex(O=>O.type==="item"),[h]),E=et(void 0);Et(()=>{const O=E.current;n!==O&&w>-1&&w===x&&b.current&&b.current.scrollToItem(w,"start"),E.current=n},[n,w,x]);const k=et(0);if(Et(()=>{if(b.current){const O=k.current,A=h.length;if(k.current=A,A!==O){const M=(O>0?Math.abs(A-O)/O:1)>.5||O<10&&A>20;b.current.resetAfterIndex(0,M)}}},[h.length]),Et(()=>{b.current&&b.current.resetAfterIndex(0,!0)},[m]),h.length===0)return ee("div",{className:"text-center text-zinc-400 py-8",children:"\u6682\u65E0\u4F1A\u8BDD"});const S=(c==null?void 0:c.colors)||{};return ee(g9,{flipKey:f,spring:{stiffness:180,damping:18},children:ee(soe,{ref:b,height:l,width:"100%",itemCount:h.length+1,itemSize:y,itemKey:O=>{if(O===h.length)return"footer";const A=h[O];return A.type==="item"?A.data.sessionId:`group-${A.label}`},onItemsRendered:({visibleStopIndex:O})=>{u&&!d&&O>=h.length-1-3&&typeof a=="function"&&a("conversations:load_more")},style:{overflowX:"hidden"},children:({index:O,style:A})=>{if(O===h.length){const M=(c==null?void 0:c.colors)||{};return ee("div",{style:{...A,height:v,lineHeight:`${v}px`,textAlign:"center",fontSize:"10px",color:M.textMuted||"#9ca3af",background:M.groupBg||"white"},children:d?"\u52A0\u8F7D\u4E2D...":u?"":"\u6CA1\u6709\u66F4\u591A\u4E86"})}const $=h[O];return $.type==="group"?ee("div",{style:{...A,background:S.groupBg||"white",zIndex:1},className:"pt-2 pb-1 px-[28px] py-[2px] text-xs text-gray-400",children:$.label}):ee(m9,{flipId:$.data.sessionId,children:ee("div",{style:A,className:"px-[12px] py-[2px]",children:ee(loe,{isActive:n===$.data.sessionId,isDisabled:!1,isNew:$.data.isNew,data:$.data,eventsEmit:a,assistantList:s,styles:c})})},$.data.sessionId)}})})}const Moe=({value:e,eventsEmit:t,setSearch:n,style:r,styles:o={}})=>{const i=o.colors||{},a=o.radius||"12px",s=i.border||"#e5e7eb",l=i.primary||"#2563eb",c=o.headerBg||i.sidebarBg||i.background||"#fff",[u,d]=we.useState(!1),f=we.useRef(null);we.useEffect(()=>{u&&f.current&&f.current.focus()},[u]);const h=()=>{d(!1),n("")};return ut("div",{className:"flex items-center gap-2 px-4 py-3 sticky top-0 z-10 min-w-0",style:{...r,background:c,borderTopLeftRadius:a,borderTopRightRadius:a},children:[ee("button",{className:"border-none flex items-center justify-center",onClick:()=>{d(!1),t&&t("conversation:create")},title:"\u65B0\u5EFA\u4F1A\u8BDD",style:{height:42,borderRadius:"90px",background:l,color:i.buttonText||"#fff",fontWeight:600,boxShadow:o.shadow||"0 2px 8px 0 rgba(0,0,0,0.04)",padding:u?"0 0":"0 14px",minWidth:u?0:180,width:u?0:void 0,opacity:u?0:1,overflow:"hidden",flexShrink:0,transition:"width .22s ease, min-width .22s ease, padding .22s ease, opacity .18s ease",pointerEvents:u?"none":"auto"},children:ut("div",{className:"flex items-center gap-2",children:[ee(rH,{size:18}),ee("span",{className:"text-sm",children:"\u65B0\u5EFA\u5BF9\u8BDD"})]})}),u?ut("div",{className:"flex-1 min-w-0 relative",children:[ee("input",{ref:f,className:"w-full px-3 py-2 pr-10 text-sm transition-all",placeholder:"\u641C\u7D22\u5386\u53F2\u8BB0\u5F55",value:e,onChange:m=>n(m.target.value),onKeyDown:m=>{m.key==="Escape"&&h()},style:{minWidth:0,width:"100%",borderRadius:a,background:i.inputBg||"#f4f4f5",border:`1px solid ${s}`,color:i.text||"#222",outline:"none",paddingRight:40}}),ee("button",{className:"absolute right-3 flex items-center justify-center transition-colors hover:bg-gray-200 rounded-full",style:{width:20,height:20,color:i.text||"#666",flexShrink:0,position:"absolute",right:"12px",top:"9px"},onClick:h,title:"\u5173\u95ED\u641C\u7D22",onMouseDown:m=>m.preventDefault(),children:ee(cC,{size:16})})]}):ee("button",{className:"ml-auto flex items-center justify-center transition-colors hover:bg-gray-50",style:{width:36,height:36,borderRadius:"90px",border:`1px solid ${s}`,color:l,flexShrink:0},onClick:()=>d(!0),title:"\u641C\u7D22",children:ee(zE,{size:18})})]})};function Noe(e){const{data:t,sortRules:n,activedItem:r,eventsEmit:o,assistantList:i,styles:a={},hasMore:s=!1,loadingMore:l=!1}=e,[c,u]=nt(""),d=Gt(()=>c?t.filter(x=>(x.label||"\u672A\u547D\u540D\u4F1A\u8BDD").toLowerCase().includes(c.toLowerCase())):t,[t,c]),f=Gt(()=>[...d].sort((x,E)=>new Date(E.gmtModified).getTime()-new Date(x.gmtModified).getTime()),[d]),h=et(null),[m,p]=nt(400);Et(()=>{function x(){h.current&&p(h.current.clientHeight)}return x(),window.addEventListener("resize",x),()=>window.removeEventListener("resize",x)},[]);const g=(a==null?void 0:a.colors)||{};a!=null&&a.radius;const v=(a==null?void 0:a.shadow)||"0 4px 24px 0 rgba(0,0,0,0.06)",y=g.border||"#e5e7eb",b=g.sidebarBg||g.background||"#EAEEFF",w=g.text||"#222";return ut("div",{className:"h-full flex flex-col overflow-y-hidden",style:{background:b,color:w,boxShadow:v,border:`1px solid ${y}`,...a.container},children:[ee(Moe,{value:c,setSearch:u,eventsEmit:o,style:a.header,styles:a}),ut("div",{className:"flex-1 min-h-0 relative",ref:h,style:a.list,children:[ee(Ooe,{eventsEmit:o,data:f,assistantList:i,activedItem:r,sortRules:n,height:m,styles:a,hasMore:s,loadingMore:l}),ee("div",{className:"pointer-events-none absolute left-0 right-0 top-0 h-3 z-20",style:{background:`linear-gradient(to bottom, ${b}cc, transparent)`}})]})]})}var dh={exports:{}};/*!
|
|
470
|
+
*/function sw(e){if(e.constructor!==Array)throw new TypeError("Expected array.");if(e.length===16)return e;if(e.length===6){var t=Lc();return t[0]=e[0],t[1]=e[1],t[4]=e[2],t[5]=e[3],t[12]=e[4],t[13]=e[5],t}throw new RangeError("Expected array with either 6 or 16 values.")}function Lc(){for(var e=[],t=0;t<16;t++)t%5==0?e.push(1):e.push(0);return e}function uoe(e,t){for(var n=sw(e),r=sw(t),o=[],i=0;i<4;i++)for(var a=[n[i],n[i+4],n[i+8],n[i+12]],s=0;s<4;s++){var l=s*4,c=[r[l],r[l+1],r[l+2],r[l+3]],u=a[0]*c[0]+a[1]*c[1]+a[2]*c[2]+a[3]*c[3];o[i+l]=u}return o}function doe(e){if(typeof e=="string"){var t=e.match(/matrix(3d)?\(([^)]+)\)/);if(t){var n=t[2].split(", ").map(parseFloat);return sw(n)}}return Lc()}function foe(e){var t=Lc();return t[0]=e,t}function hoe(e){var t=Lc();return t[5]=e,t}function poe(e){var t=Lc();return t[12]=e,t}function goe(e){var t=Lc();return t[13]=e,t}var uh=function(e){return typeof e=="number"},n9=function(e){return typeof e=="function"},r9=function(e){return Object.prototype.toString.call(e)==="[object Object]"},ic=function(e){return Array.prototype.slice.apply(e)},o9=function(e){var t=e.reduce(function(n,r){return n[r]=(n[r]||0)+1,n},{});return Object.keys(t).filter(function(n){return t[n]>1})};function Ra(e){return[].slice.call(arguments,1).forEach(function(t){if(t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}),e}var lw,cw=function(e,t,n){return e+(t-e)*n},i9={__proto__:null,isNumber:uh,isFunction:n9,isObject:r9,toArray:ic,getDuplicateValsAsStrings:o9,assign:Ra,tweenProp:cw},Ak="data-flip-id",$k="data-inverse-flip-id",Ok="data-portal-key",moe="data-exit-container",pf={__proto__:null,DATA_FLIP_ID:Ak,DATA_INVERSE_FLIP_ID:$k,DATA_FLIP_CONFIG:"data-flip-config",DATA_PORTAL_KEY:Ok},uw={noWobble:{stiffness:200,damping:26},gentle:{stiffness:120,damping:14},veryGentle:{stiffness:130,damping:17},wobbly:{stiffness:180,damping:12},stiff:{stiffness:260,damping:26}},BA=function(e){return r9(e)?e:Object.keys(uw).indexOf(e)>-1?uw[e]:{}};typeof window<"u"&&(lw=window.requestAnimationFrame);var voe=lw=lw||function(e){window.setTimeout(e,1e3/60)},yoe=Date.now(),boe=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()-yoe};function a9(e,t){var n=e.indexOf(t);n!==-1&&e.splice(n,1)}var xoe=(function(){function e(){}return e.prototype.run=function(){var t=this;voe(function(){t.springSystem.loop(boe())})},e})(),Im=function(){this.position=0,this.velocity=0},Eoe=0,Ho=.001,woe=(function(){function e(n){this._id="s"+Eoe++,this._springSystem=n,this.listeners=[],this._startValue=0,this._currentState=new Im,this._displacementFromRestThreshold=.001,this._endValue=0,this._overshootClampingEnabled=!1,this._previousState=new Im,this._restSpeedThreshold=.001,this._tempState=new Im,this._timeAccumulator=0,this._wasAtRest=!0,this._cachedSpringConfig={}}var t=e.prototype;return t.getId=function(){return this._id},t.destroy=function(){this.listeners=[],this._springSystem.deregisterSpring(this)},t.setSpringConfig=function(n){return this._springConfig=n,this},t.getCurrentValue=function(){return this._currentState.position},t.getDisplacementDistanceForState=function(n){return Math.abs(this._endValue-n.position)},t.setEndValue=function(n){if(n===this._endValue)return this;if(this.prevEndValue=n,this._endValue===n&&this.isAtRest())return this;this._startValue=this.getCurrentValue(),this._endValue=n,this._springSystem.activateSpring(this.getId());for(var r=0,o=this.listeners.length;r<o;r++){var i=this.listeners[r].onSpringEndStateChange;i&&i(this)}return this},t.setVelocity=function(n){return n===this._currentState.velocity||(this._currentState.velocity=n,this._springSystem.activateSpring(this.getId())),this},t.setCurrentValue=function(n){this._startValue=n,this._currentState.position=n;for(var r=0,o=this.listeners.length;r<o;r++){var i=this.listeners[r];i.onSpringUpdate&&i.onSpringUpdate(this)}return this},t.setAtRest=function(){return this._endValue=this._currentState.position,this._tempState.position=this._currentState.position,this._currentState.velocity=0,this},t.setOvershootClampingEnabled=function(n){return this._overshootClampingEnabled=n,this},t.isOvershooting=function(){var n=this._startValue,r=this._endValue;return this._springConfig.tension>0&&(n<r&&this.getCurrentValue()>r||n>r&&this.getCurrentValue()<r)},t.advance=function(n,r){var o=this.isAtRest();if(!o||!this._wasAtRest){var i=r;r>.064&&(i=.064),this._timeAccumulator+=i;for(var a,s,l,c,u,d,f=this._springConfig.tension,h=this._springConfig.friction,m=this._currentState.position,p=this._currentState.velocity,g=this._tempState.position,v=this._tempState.velocity;this._timeAccumulator>=Ho;)this._timeAccumulator-=Ho,this._timeAccumulator<Ho&&(this._previousState.position=m,this._previousState.velocity=p),s=f*(this._endValue-g)-h*p,c=f*(this._endValue-(g=m+(a=p)*Ho*.5))-h*(v=p+s*Ho*.5),d=f*(this._endValue-(g=m+(l=v)*Ho*.5))-h*(v=p+c*Ho*.5),g=m+(u=v)*Ho,m+=1/6*(a+2*(l+u)+(v=p+d*Ho))*Ho,p+=1/6*(s+2*(c+d)+(f*(this._endValue-g)-h*v))*Ho;this._tempState.position=g,this._tempState.velocity=v,this._currentState.position=m,this._currentState.velocity=p,this._timeAccumulator>0&&this._interpolate(this._timeAccumulator/Ho),(this.isAtRest()||this._overshootClampingEnabled&&this.isOvershooting())&&(this._springConfig.tension>0?(this._startValue=this._endValue,this._currentState.position=this._endValue):(this._endValue=this._currentState.position,this._startValue=this._endValue),this.setVelocity(0),o=!0);var y=!1;this._wasAtRest&&(this._wasAtRest=!1,y=!0);var b=!1;o&&(this._wasAtRest=!0,b=!0),this.notifyPositionUpdated(y,b)}},t.notifyPositionUpdated=function(n,r){var o=this;this.listeners.filter(Boolean).forEach(function(i){n&&i.onSpringActivate&&!o._onActivateCalled&&(i.onSpringActivate(o),o._onActivateCalled=!0),i.onSpringUpdate&&i.onSpringUpdate(o),r&&i.onSpringAtRest&&i.onSpringAtRest(o)})},t.systemShouldAdvance=function(){return!this.isAtRest()||!this.wasAtRest()},t.wasAtRest=function(){return this._wasAtRest},t.isAtRest=function(){return Math.abs(this._currentState.velocity)<this._restSpeedThreshold&&(this.getDisplacementDistanceForState(this._currentState)<=this._displacementFromRestThreshold||this._springConfig.tension===0)},t._interpolate=function(n){this._currentState.position=this._currentState.position*n+this._previousState.position*(1-n),this._currentState.velocity=this._currentState.velocity*n+this._previousState.velocity*(1-n)},t.addListener=function(n){return this.listeners.push(n),this},t.addOneTimeListener=function(n){var r=this;return Object.keys(n).forEach(function(o){var i;n[o]=(i=n[o],function(){i.apply(void 0,[].slice.call(arguments)),r.removeListener(n)})}),this.listeners.push(n),this},t.removeListener=function(n){return a9(this.listeners,n),this},e})(),s9=(function(){function e(n){this.looper=n||new xoe,this.looper.springSystem=this,this.listeners=[],this._activeSprings=[],this._idleSpringIndices=[],this._isIdle=!0,this._lastTimeMillis=-1,this._springRegistry={}}var t=e.prototype;return t.createSpring=function(n,r){return this.createSpringWithConfig({tension:n,friction:r})},t.createSpringWithConfig=function(n){var r=new woe(this);return this.registerSpring(r),r.setSpringConfig(n),r},t.getIsIdle=function(){return this._isIdle},t.registerSpring=function(n){this._springRegistry[n.getId()]=n},t.deregisterSpring=function(n){a9(this._activeSprings,n),delete this._springRegistry[n.getId()]},t.advance=function(n,r){for(var o=this;this._idleSpringIndices.length>0;)this._idleSpringIndices.pop();for(this._activeSprings.filter(Boolean).forEach(function(a){a.systemShouldAdvance()?a.advance(n/1e3,r/1e3):o._idleSpringIndices.push(o._activeSprings.indexOf(a))});this._idleSpringIndices.length>0;){var i=this._idleSpringIndices.pop();i>=0&&this._activeSprings.splice(i,1)}},t.loop=function(n){var r;this._lastTimeMillis===-1&&(this._lastTimeMillis=n-1);var o=n-this._lastTimeMillis;this._lastTimeMillis=n;var i=0,a=this.listeners.length;for(i=0;i<a;i++)(r=this.listeners[i]).onBeforeIntegrate&&r.onBeforeIntegrate(this);for(this.advance(n,o),this._activeSprings.length===0&&(this._isIdle=!0,this._lastTimeMillis=-1),i=0;i<a;i++)(r=this.listeners[i]).onAfterIntegrate&&r.onAfterIntegrate(this);this._isIdle||this.looper.run()},t.activateSpring=function(n){var r=this._springRegistry[n];this._activeSprings.indexOf(r)===-1&&this._activeSprings.push(r),this.getIsIdle()&&(this._isIdle=!1,this.looper.run())},e})(),Coe=new s9,l9=function(e){var t=e.springConfig,n=t.overshootClamping,r=e.getOnUpdateFunc,o=e.onAnimationEnd,i=e.onSpringActivate,a=Coe.createSpring(t.stiffness,t.damping);a.setOvershootClampingEnabled(!!n);var s={onSpringActivate:i,onSpringAtRest:function(){a.destroy(),o()},onSpringUpdate:r({spring:a,onAnimationEnd:o})};return a.addListener(s),a},RA=function(e){var t=l9(e);return t.setEndValue(1),t},_A=function(e,t){if(t===void 0&&(t={}),e&&e.length){t.reverse&&e.reverse();var n,r=typeof(n=t.speed)!="number"?1.1:1+Math.min(Math.max(5*n,0),5),o=1/Math.max(Math.min(e.length,100),10),i=e.map(function(a,s){var l=a.getOnUpdateFunc;return a.getOnUpdateFunc=function(c){var u=l(c);return function(d){var f=d.getCurrentValue();(f=f<.01?0:f>.99?1:f)>=o&&i[s+1]&&i[s+1](Math.max(Math.min(f*r,1),0)),u(d)}},a}).map(function(a){var s=l9(a);if(s)return s.setEndValue.bind(s)}).filter(Boolean);i[0]&&i[0](1)}},jA=function(e){return[0,1,4,5,12,13].map(function(t){return e[t]})},LA=function(e){return e.top<window.innerHeight&&e.bottom>0&&e.left<window.innerWidth&&e.right>0};function zA(e){return JSON.parse(e.dataset.flipConfig||"{}")}var c9=function(e,t){var n;return Ra(e,((n={})[t[0]]=t[1],n))},u9=function(e,t){return ic(t?document.querySelectorAll("["+Ok+'="'+t+'"]'):e.querySelectorAll("["+Ak+"]"))},d9=function(e){return e.map(function(t){return[t,t.getBoundingClientRect()]})},koe=function(e){var t=e.cachedOrderedFlipIds,n=t===void 0?[]:t,r=e.inProgressAnimations,o=r===void 0?{}:r,i=e.flippedElementPositionsBeforeUpdate,a=i===void 0?{}:i,s=e.flipCallbacks,l=s===void 0?{}:s,c=e.containerEl,u=e.applyTransformOrigin,d=e.spring,f=e.debug,h=e.portalKey,m=e.staggerConfig,p=m===void 0?{}:m,g=e.decisionData,v=g===void 0?{}:g,y=e.handleEnterUpdateDelete,b=e.onComplete,w=e.onStart;if(!window.matchMedia("(prefers-reduced-motion: reduce)").matches){var x,E=d9(u9((x={element:c,portalKey:h}).element,x.portalKey)).map(function(R){var H=R[0],V=R[1],L=window.getComputedStyle(H);return[H.dataset.flipId,{element:H,rect:V,opacity:parseFloat(L.opacity),transform:L.transform}]}).reduce(c9,{}),k=(function(R){var H=R.containerEl,V=R.portalKey;return V?(function(L){return function(j){return ic(document.querySelectorAll("["+Ok+'="'+L+'"]'+j))}})(V):H?(function(L){var j=Math.random().toFixed(5);return L.dataset.flipperId=j,function(_){return ic(L.querySelectorAll('[data-flipper-id="'+j+'"] '+_))}})(H):function(){return[]}})({containerEl:c,portalKey:h}),S=(function(R){return function(H){return R("["+Ak+'="'+H+'"]')[0]}})(k),O=function(R){return a[R]&&E[R]},A=Object.keys(a).concat(Object.keys(E)).filter(function(R){return!O(R)}),$={flipCallbacks:l,getElement:S,flippedElementPositionsBeforeUpdate:a,flippedElementPositionsAfterUpdate:E,inProgressAnimations:o,decisionData:v},M=(function(R){var H,V=R.unflippedIds,L=R.flipCallbacks,j=R.getElement,_=R.flippedElementPositionsBeforeUpdate,F=R.flippedElementPositionsAfterUpdate,B=R.inProgressAnimations,z=R.decisionData,G=V.filter(function(K){return F[K]}).filter(function(K){return L[K]&&L[K].onAppear}),W=V.filter(function(K){return _[K]&&L[K]&&L[K].onExit}),q=new Promise(function(K){H=K}),U=[],Y=0,ie=W.map(function(K,re){var oe=_[K].domDataForExitAnimations,ne=oe.element,ae=oe.parent,de=oe.childPosition,ge=de.top,Se=de.left,ye=de.width,be=de.height;getComputedStyle(ae).position==="static"&&(ae.style.position="relative"),ne.style.transform="matrix(1, 0, 0, 1, 0, 0)",ne.style.position="absolute",ne.style.top=ge+"px",ne.style.left=Se+"px",ne.style.height=be+"px",ne.style.width=ye+"px";var ce=U.filter(function(Te){return Te[0]===ae})[0];ce||(ce=[ae,document.createDocumentFragment()],U.push(ce)),ce[1].appendChild(ne),Y+=1;var he=function(){try{ae.removeChild(ne)}catch{}finally{(Y-=1)==0&&H()}};return B[K]={stop:he},function(){return L[K].onExit(ne,re,he,z)}});return U.forEach(function(K){K[0].appendChild(K[1])}),ie.length||H(),{hideEnteringElements:function(){G.forEach(function(K){var re=j(K);re&&(re.style.opacity="0")})},animateEnteringElements:function(){G.forEach(function(K,re){var oe=j(K);oe&&L[K].onAppear(oe,re,z)})},animateExitingElements:function(){return ie.forEach(function(K){return K()}),q}}})(Ra({},$,{unflippedIds:A})),N=M.hideEnteringElements,D=M.animateEnteringElements,T=M.animateExitingElements,P=Ra({},$,{containerEl:c,flippedIds:n.filter(O),applyTransformOrigin:u,spring:d,debug:f,staggerConfig:p,scopedSelector:k,onComplete:b});w&&w(c,v);var I=(function(R){var H,V=R.flippedIds,L=R.flipCallbacks,j=R.inProgressAnimations,_=R.flippedElementPositionsBeforeUpdate,F=R.flippedElementPositionsAfterUpdate,B=R.applyTransformOrigin,z=R.spring,G=R.getElement,W=R.debug,q=R.staggerConfig,U=q===void 0?{}:q,Y=R.decisionData,ie=Y===void 0?{}:Y,K=R.onComplete,re=R.containerEl,oe=new Promise(function(se){H=se});if(K&&oe.then(function(){return K(re,ie)}),!V.length)return function(){return H([]),oe};var ne=[],ae=G(V[0]),de=ae?ae.ownerDocument.querySelector("body"):document.querySelector("body");o9(V);var ge=V.map(function(se){var Pe=_[se].rect,De=F[se].rect,He=_[se].opacity,ue=F[se].opacity,ve=De.width<1||De.height<1,xe=F[se].element;if(!LA(Pe)&&!LA(De)||!xe)return!1;var fe,pe,ke,Ve=zA(xe),Ee=(ke=(pe=(fe={flipperSpring:z,flippedSpring:Ve.spring})===void 0?{}:fe).flippedSpring,Ra({},uw.noWobble,BA(pe.flipperSpring),BA(ke))),yt=Ve.stagger===!0?"default":Ve.stagger,Dt={element:xe,id:se,stagger:yt,springConfig:Ee};if(L[se]&&L[se].shouldFlip&&!L[se].shouldFlip(ie.previous,ie.current))return!1;var Pt=Math.abs(Pe.left-De.left)+Math.abs(Pe.top-De.top),Ut=Math.abs(Pe.width-De.width)+Math.abs(Pe.height-De.height),Ge=Math.abs(ue-He);if(Pe.height===0&&De.height===0||Pe.width===0&&De.width===0||Pt<.5&&Ut<.5&&Ge<.01)return!1;var Xe=doe(F[se].transform),qe={matrix:Xe},lt={matrix:[]},je=[Xe];Ve.translate&&(je.push(poe(Pe.left-De.left)),je.push(goe(Pe.top-De.top))),Ve.scale&&(je.push(foe(Math.max(Pe.width,1)/Math.max(De.width,1))),je.push(hoe(Math.max(Pe.height,1)/Math.max(De.height,1)))),Ve.opacity&&(lt.opacity=He,qe.opacity=ue);var Rt=[];if(!L[se]||!L[se].shouldInvert||L[se].shouldInvert(ie.previous,ie.current)){var zt=(function(Oe,_e){return ic(Oe.querySelectorAll("["+$k+'="'+_e+'"]'))})(xe,se);Rt=zt.map(function(Oe){return[Oe,zA(Oe)]})}lt.matrix=jA(je.reduce(uoe)),qe.matrix=jA(qe.matrix);var dt,Ct=(function(Oe){var _e=Oe.element,mt=Oe.invertedChildren,kt=Oe.body;return function(It){var Xt=It.matrix,on=It.opacity,qt=It.forceMinVals;if(uh(on)&&(_e.style.opacity=on+""),qt&&(_e.style.minHeight="1px",_e.style.minWidth="1px"),Xt){var wn=(function(vn){return"matrix("+vn.join(", ")+")"})(Xt);_e.style.transform=wn,mt&&(function(vn){var Kt=vn.matrix,$n=vn.body;vn.invertedChildren.forEach(function(On){var ur=On[0],We=On[1];if($n.contains(ur)){var pt=Kt[0],Ke=Kt[3],rt=Kt[5],ht={translateX:0,translateY:0,scaleX:1,scaleY:1},an="";We.translate&&(ht.translateX=-Kt[4]/pt,ht.translateY=-rt/Ke,an+="translate("+ht.translateX+"px, "+ht.translateY+"px)"),We.scale&&(ht.scaleX=1/pt,ht.scaleY=1/Ke,an+=" scale("+ht.scaleX+", "+ht.scaleY+")"),ur.style.transform=an}})})({invertedChildren:mt,matrix:Xt,body:kt})}}})({element:xe,invertedChildren:Rt,body:de});if(L[se]&&L[se].onComplete){var jt=L[se].onComplete;dt=function(){return jt(xe,ie)}}var Ie=uh(lt.opacity)&&uh(qe.opacity)&<.opacity!==qe.opacity,Ne=!1;return Ra({},Dt,{stagger:yt,springConfig:Ee,getOnUpdateFunc:function(Oe){var _e=Oe.spring,mt=Oe.onAnimationEnd;return j[se]={destroy:_e.destroy.bind(_e),onAnimationEnd:mt},function(kt){L[se]&&L[se].onSpringUpdate&&L[se].onSpringUpdate(kt.getCurrentValue()),Ne||(Ne=!0,L[se]&&L[se].onStart&&L[se].onStart(xe,ie));var It=kt.getCurrentValue();if(de.contains(xe)){var Xt={matrix:[]};Xt.matrix=lt.matrix.map(function(on,qt){return cw(on,qe.matrix[qt],It)}),Ie&&(Xt.opacity=cw(lt.opacity,qe.opacity,It)),Ct(Xt)}else kt.destroy()}},initializeFlip:function(){Ct({matrix:lt.matrix,opacity:Ie?lt.opacity:void 0,forceMinVals:ve}),L[se]&&L[se].onStartImmediate&&L[se].onStartImmediate(xe,ie),Ve.transformOrigin?xe.style.transformOrigin=Ve.transformOrigin:B&&(xe.style.transformOrigin="0 0"),Rt.forEach(function(Oe){var _e=Oe[0],mt=Oe[1];mt.transformOrigin?_e.style.transformOrigin=mt.transformOrigin:B&&(_e.style.transformOrigin="0 0")})},onAnimationEnd:function(Oe){delete j[se],n9(dt)&&dt(),xe.style.transform="",Rt.forEach(function(_e){_e[0].style.transform=""}),ve&&xe&&(xe.style.minHeight="",xe.style.minWidth=""),Oe||(ne.push(se),ne.length>=ge.length&&H(ne))},delayUntil:Ve.delayUntil})}).filter(Boolean);if(ge.forEach(function(se){return(0,se.initializeFlip)()}),W)return function(){};var Se=ge.filter(function(se){return se.delayUntil&&(Pe=se.delayUntil,ge.filter(function(De){return De.id===Pe}).length);var Pe}),ye={},be={},ce={};Se.forEach(function(se){se.stagger?(ce[se.stagger]=!0,be[se.delayUntil]?be[se.delayUntil].push(se.stagger):be[se.delayUntil]=[se.stagger]):ye[se.delayUntil]?ye[se.delayUntil].push(se):ye[se.delayUntil]=[se]});var he=ge.filter(function(se){return se.stagger}).reduce(function(se,Pe){return se[Pe.stagger]?se[Pe.stagger].push(Pe):se[Pe.stagger]=[Pe],se},{}),Te=ge.filter(function(se){return Se.indexOf(se)===-1});return Te.forEach(function(se){se.onSpringActivate=function(){ye[se.id]&&ye[se.id].forEach(RA),be[se.id]&&Object.keys(be[se.id].reduce(function(Pe,De){var He;return Ra(Pe,((He={})[De]=!0,He))},{})).forEach(function(Pe){_A(he[Pe],U[Pe])})}}),function(){return ge.length||H([]),Te.filter(function(se){return!se.stagger}).forEach(RA),Object.keys(he).forEach(function(se){ce[se]||_A(he[se],U[se])}),oe}})(P);y?y({hideEnteringElements:N,animateEnteringElements:D,animateExitingElements:T,animateFlippedElements:I}):(N(),T().then(D),I())}},Soe=function(e){var t=e.element,n=e.flipCallbacks,r=n===void 0?{}:n,o=e.inProgressAnimations,i=o===void 0?{}:o,a=u9(t,e.portalKey),s=ic(t.querySelectorAll("["+$k+"]")),l={},c=[],u={};a.filter(function(h){return r&&r[h.dataset.flipId]&&r[h.dataset.flipId].onExit}).forEach(function(h){var m=h.parentNode;if(h.closest){var p=h.closest("["+moe+"]");p&&(m=p)}var g=c.findIndex(function(v){return v[0]===m});g===-1&&(c.push([m,m.getBoundingClientRect()]),g=c.length-1),l[h.dataset.flipId]=c[g][1],u[h.dataset.flipId]=m});var d=d9(a),f=d.map(function(h){var m=h[0],p=h[1],g={};if(r&&r[m.dataset.flipId]&&r[m.dataset.flipId].onExit){var v=l[m.dataset.flipId];Ra(g,{element:m,parent:u[m.dataset.flipId],childPosition:{top:p.top-v.top,left:p.left-v.left,width:p.width,height:p.height}})}return[m.dataset.flipId,{rect:p,opacity:parseFloat(window.getComputedStyle(m).opacity||"1"),domDataForExitAnimations:g}]}).reduce(c9,{});return(function(h,m){Object.keys(h).forEach(function(p){h[p].destroy&&h[p].destroy(),h[p].onAnimationEnd&&h[p].onAnimationEnd(!0),delete h[p]}),m.forEach(function(p){p.style.transform="",p.style.opacity=""})})(i,a.concat(s)),{flippedElementPositions:f,cachedOrderedFlipIds:d.map(function(h){return h[0].dataset.flipId})}};new s9;function E0(){return E0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},E0.apply(this,arguments)}function dw(e,t){return dw=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},dw(e,t)}function f9(e,t){if(e==null)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(o[n]=e[n]);return o}var h9=us({}),p9=us("portal"),g9=(function(e){var t,n;function r(){for(var i,a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];return(i=e.call.apply(e,[this].concat(s))||this).inProgressAnimations={},i.flipCallbacks={},i.el=void 0,i}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,dw(t,n);var o=r.prototype;return o.getSnapshotBeforeUpdate=function(i){return i.flipKey!==this.props.flipKey&&this.el?Soe({element:this.el,flipCallbacks:this.flipCallbacks,inProgressAnimations:this.inProgressAnimations,portalKey:this.props.portalKey}):null},o.componentDidUpdate=function(i,a,s){this.props.flipKey!==i.flipKey&&this.el&&koe({flippedElementPositionsBeforeUpdate:s.flippedElementPositions,cachedOrderedFlipIds:s.cachedOrderedFlipIds,containerEl:this.el,inProgressAnimations:this.inProgressAnimations,flipCallbacks:this.flipCallbacks,applyTransformOrigin:this.props.applyTransformOrigin,spring:this.props.spring,debug:this.props.debug,portalKey:this.props.portalKey,staggerConfig:this.props.staggerConfig,handleEnterUpdateDelete:this.props.handleEnterUpdateDelete,decisionData:{previous:i.decisionData,current:this.props.decisionData},onComplete:this.props.onComplete,onStart:this.props.onStart})},o.render=function(){var i=this,a=this.props,s=a.portalKey,l=we.createElement(h9.Provider,{value:this.flipCallbacks},we.createElement(a.element,{className:a.className,ref:function(c){return i.el=c}},this.props.children));return s&&(l=we.createElement(p9.Provider,{value:s},l)),l},r})(Bz);g9.defaultProps={applyTransformOrigin:!0,element:"div"};var Aoe=["children","flipId","inverseFlipId","portalKey"],$oe=["children","flipId","shouldFlip","shouldInvert","onAppear","onStart","onStartImmediate","onComplete","onExit","onSpringUpdate"],HA=function(e){var t,n=e.children,r=e.flipId,o=e.inverseFlipId,i=e.portalKey,a=f9(e,Aoe),s=n,l=(function(u){return typeof u=="function"})(s);if(!l)try{s=AF.only(n)}catch{throw new Error("Each Flipped component must wrap a single child")}a.scale||a.translate||a.opacity||i9.assign(a,{translate:!0,scale:!0,opacity:!0});var c=((t={})[pf.DATA_FLIP_CONFIG]=JSON.stringify(a),t);return r!==void 0?c[pf.DATA_FLIP_ID]=String(r):o&&(c[pf.DATA_INVERSE_FLIP_ID]=String(o)),i!==void 0&&(c[pf.DATA_PORTAL_KEY]=i),l?s(c):OF(s,c)},m9=function(e){var t=e.children,n=e.flipId,r=e.shouldFlip,o=e.shouldInvert,i=e.onAppear,a=e.onStart,s=e.onStartImmediate,l=e.onComplete,c=e.onExit,u=e.onSpringUpdate,d=f9(e,$oe);return t?d.inverseFlipId?we.createElement(HA,E0({},d),t):we.createElement(p9.Consumer,null,function(f){return we.createElement(h9.Consumer,null,function(h){return i9.isObject(h)&&n&&(h[n]={shouldFlip:r,shouldInvert:o,onAppear:i,onStart:a,onStartImmediate:s,onComplete:l,onExit:c,onSpringUpdate:u}),we.createElement(HA,E0({flipId:n},d,{portalKey:f}),t)})}):null};m9.displayName="Flipped";function Ooe(e){const{data:t,activedItem:n,onChange:r,onDelete:o,sortRules:i=[{label:"\u5F53\u5929",dayPeriod:1}],eventsEmit:a,assistantList:s,height:l=400,styles:c={},hasMore:u=!1,loadingMore:d=!1}=e,f=t.map(O=>O.sessionId+"-"+O.gmtModified).join(","),h=Gt(()=>{const O=i.length>0?i:[{label:"\u5F53\u5929",dayPeriod:1}],A=coe(t,O),$=O.every(N=>!A[N.label]||A[N.label].length===0),M=[];return O.forEach(N=>{A[N.label]&&A[N.label].length>0&&(M.push({type:"group",label:N.label}),A[N.label].forEach(D=>M.push({type:"item",data:D})))}),A.other.length>0&&!$&&(M.push({type:"group",label:"\u5176\u4ED6"}),A.other.forEach(N=>M.push({type:"item",data:N}))),$&&A.other.length>0&&A.other.forEach(N=>M.push({type:"item",data:N})),M},[t,i,f]),m=Gt(()=>h.map(O=>O.type==="group"?`g:${O.label}`:`i:${O.data.sessionId}`).join("|"),[h]),p=56,g=14,v=36,y=O=>O===h.length?v:h[O].type==="group"?32:p+g,b=et(null),w=Gt(()=>h.findIndex(O=>{var A;return O.type==="item"&&((A=O.data)==null?void 0:A.sessionId)===n}),[h,n]),x=Gt(()=>h.findIndex(O=>O.type==="item"),[h]),E=et(void 0);Et(()=>{const O=E.current;n!==O&&w>-1&&w===x&&b.current&&b.current.scrollToItem(w,"start"),E.current=n},[n,w,x]);const k=et(0);if(Et(()=>{if(b.current){const O=k.current,A=h.length;if(k.current=A,A!==O){const M=(O>0?Math.abs(A-O)/O:1)>.5||O<10&&A>20;b.current.resetAfterIndex(0,M)}}},[h.length]),Et(()=>{b.current&&b.current.resetAfterIndex(0,!0)},[m]),h.length===0)return ee("div",{className:"text-center text-zinc-400 py-8",children:"\u6682\u65E0\u4F1A\u8BDD"});const S=(c==null?void 0:c.colors)||{};return ee(g9,{flipKey:f,spring:{stiffness:180,damping:18},children:ee(soe,{ref:b,height:l,width:"100%",itemCount:h.length+1,itemSize:y,itemKey:O=>{if(O===h.length)return"footer";const A=h[O];return A.type==="item"?A.data.sessionId:`group-${A.label}`},onItemsRendered:({visibleStopIndex:O})=>{u&&!d&&O>=h.length-1-3&&typeof a=="function"&&a("conversations:load_more")},style:{overflowX:"hidden"},children:({index:O,style:A})=>{if(O===h.length){const M=(c==null?void 0:c.colors)||{};return ee("div",{style:{...A,height:v,lineHeight:`${v}px`,textAlign:"center",fontSize:"10px",color:M.textMuted||"#9ca3af",background:M.groupBg||"white"},children:d?"\u52A0\u8F7D\u4E2D...":u?"":"\u6CA1\u6709\u66F4\u591A\u4E86"})}const $=h[O];return $.type==="group"?ee("div",{style:{...A,background:S.groupBg||"white",zIndex:1},className:"pt-2 pb-1 px-[28px] py-[2px] text-xs text-gray-400",children:$.label}):ee(m9,{flipId:$.data.sessionId,children:ee("div",{style:A,className:"px-[12px] py-[2px]",children:ee(loe,{isActive:n===$.data.sessionId,isDisabled:!1,isNew:$.data.isNew,data:$.data,eventsEmit:a,assistantList:s,styles:c})})},$.data.sessionId)}})})}const Moe=({value:e,eventsEmit:t,setSearch:n,style:r,styles:o={}})=>{const i=o.colors||{},a=o.radius||"12px",s=i.border||"#e5e7eb",l=i.primary||"#2563eb",c=o.headerBg||i.sidebarBg||i.background||"#fff",[u,d]=we.useState(!1),f=we.useRef(null);we.useEffect(()=>{u&&f.current&&f.current.focus()},[u]);const h=()=>{d(!1),n("")};return ut("div",{className:"flex items-center gap-2 px-4 py-3 sticky top-0 z-10 min-w-0",style:{...r,background:c,borderTopLeftRadius:a,borderTopRightRadius:a},children:[ee("button",{className:"border-none flex items-center justify-center",onClick:()=>{d(!1),t&&t("conversation:create")},title:"\u65B0\u5EFA\u4F1A\u8BDD",style:{height:42,borderRadius:"90px",background:l,color:i.buttonText||"#fff",fontWeight:600,boxShadow:o.shadow||"0 2px 8px 0 rgba(0,0,0,0.04)",padding:u?"0 0":"0 14px",minWidth:u?0:180,width:u?0:void 0,opacity:u?0:1,overflow:"hidden",flexShrink:0,transition:"width .22s ease, min-width .22s ease, padding .22s ease, opacity .18s ease",pointerEvents:u?"none":"auto"},children:ut("div",{className:"flex items-center gap-2",children:[ee(rH,{size:18}),ee("span",{className:"text-sm",children:"\u65B0\u5EFA\u5BF9\u8BDD"})]})}),u?ut("div",{className:"flex-1 min-w-0 relative",children:[ee("input",{ref:f,className:"w-full px-3 py-2 pr-10 text-sm transition-all",placeholder:"\u641C\u7D22\u5386\u53F2\u8BB0\u5F55",value:e,onChange:m=>n(m.target.value),onKeyDown:m=>{m.key==="Escape"&&h()},style:{minWidth:0,width:"100%",borderRadius:a,background:i.inputBg||"#f4f4f5",border:`1px solid ${s}`,color:i.text||"#222",outline:"none",paddingRight:40}}),ee("button",{className:"absolute right-3 flex items-center justify-center transition-colors hover:bg-gray-200 rounded-full",style:{width:20,height:20,color:i.text||"#666",flexShrink:0,position:"absolute",right:"12px",top:"9px"},onClick:h,title:"\u5173\u95ED\u641C\u7D22",onMouseDown:m=>m.preventDefault(),children:ee(cC,{size:16})})]}):ee("button",{className:"ml-auto flex items-center justify-center transition-colors hover:bg-gray-50",style:{width:36,height:36,borderRadius:"90px",border:`1px solid ${s}`,color:l,flexShrink:0},onClick:()=>d(!0),title:"\u641C\u7D22",children:ee(zE,{size:18})})]})};function Noe(e){const{data:t,sortRules:n,activedItem:r,eventsEmit:o,assistantList:i,styles:a={},hasMore:s=!1,loadingMore:l=!1}=e,[c,u]=nt(""),d=Gt(()=>c?t.filter(x=>(x.label||"\u672A\u547D\u540D\u4F1A\u8BDD").toLowerCase().includes(c.toLowerCase())):t,[t,c]),f=Gt(()=>[...d].sort((x,E)=>new Date(E.gmtModified).getTime()-new Date(x.gmtModified).getTime()),[d]),h=et(null),[m,p]=nt(400);Et(()=>{function x(){h.current&&p(h.current.clientHeight)}return x(),window.addEventListener("resize",x),()=>window.removeEventListener("resize",x)},[]);const g=(a==null?void 0:a.colors)||{};a!=null&&a.radius;const v=(a==null?void 0:a.shadow)||"0 4px 24px 0 rgba(0,0,0,0.06)",y=g.border||"#e5e7eb",b=g.sidebarBg||g.background||"#EAEEFF",w=g.text||"#222";return ut("div",{className:"h-full flex flex-col overflow-y-hidden",style:{background:b,color:w,boxShadow:v,border:`1px solid ${y}`,...a.container},children:[ee(Moe,{value:c,setSearch:u,eventsEmit:o,style:a.header,styles:a}),ut("div",{className:"flex-1 min-h-0 relative",ref:h,style:a.list,children:[ee(Ooe,{eventsEmit:o,data:f,assistantList:i,activedItem:r,sortRules:n,height:m,styles:a,hasMore:s,loadingMore:l}),ee("div",{className:"pointer-events-none absolute left-0 right-0 top-0 h-3 z-20",style:{background:`linear-gradient(to bottom, ${b}cc, transparent)`}})]})]})}var dh={exports:{}};/*!
|
|
471
471
|
* clipboard.js v2.0.11
|
|
472
472
|
* https://clipboardjs.com/
|
|
473
473
|
*
|
|
@@ -790,7 +790,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
790
790
|
<div onwheel="event.stopPropagation();" onmousewheel="event.stopPropagation();" ontouchmove="event.stopPropagation();" style="max-width:310px; max-height:300px; overflow-y:auto; padding:10px 12px;">
|
|
791
791
|
${k}${S}
|
|
792
792
|
</div>
|
|
793
|
-
`}}:!1,...d}),[t,n,o,i,a,s,l,c,d]);if(!p)return fh.jsx("div",{style:{padding:"20px",textAlign:"center"},children:"\u6570\u636E\u8F6C\u6362\u5931\u8D25"});try{return console.log("\u5F00\u59CB\u6E32\u67D3 NodeGraph..."),fh.jsx(Lbe,{data:p,behaviors:{dragCanvas:{direction:"both"},zoomCanvas:!0,dragElement:!0,optimizeViewportTransform:!0},plugins:v,layout:Gt(()=>{if(!u)return{animate:!1,animation:!1};const b={...u};return b.animate=!1,b.animation=!1,b!=null&&b.options&&typeof b.options=="object"&&(b.options={...b.options,animate:!1,animation:!1}),b},[u]),onReady:(b=>{m.current=b,console.log("KnowledgeGraphPreview ready:",b);const w=g;if(w){const x=()=>{var A,$,M;try{if(typeof b.fitView=="function"&&((A=b.fitView)==null||A.call(b,{padding:40})),typeof b.focusItem=="function")b.focusItem(w,!0);else if(typeof b.focusElement=="function")b.focusElement(w,!0);else if(typeof b.centerElement=="function")b.centerElement(w);else{const D=typeof b.getNode=="function"?b.getNode(w):typeof b.findById=="function"?b.findById(w):null,T=(($=D==null?void 0:D.getModel)==null?void 0:$.call(D))??((M=D==null?void 0:D.getData)==null?void 0:M.call(D)),P=T==null?void 0:T.x,I=T==null?void 0:T.y;P!=null&&I!=null&&(typeof b.panTo=="function"?b.panTo(P,I):typeof b.focusViewport=="function"&&b.focusViewport(P,I))}const N=b.getZoom?b.getZoom():1;typeof b.zoomTo=="function"&&N<.9&&b.zoomTo(.9)}catch(N){console.warn("\u5C45\u4E2D\u8282\u70B9\u5931\u8D25:",N)}};setTimeout(x,80);const E=A=>{try{const $=b;if(typeof $.once=="function")$.once(A,()=>setTimeout(x,30));else if(typeof $.on=="function"){const M=()=>{var N;setTimeout(x,30);try{(N=$.off)==null||N.call($,A,M)}catch{}};$.on(A,M)}}catch{}};E("afterlayout"),E("layoutEnd");let k=0;const S=1,O=setInterval(()=>{k+=1,x(),k>=S&&clearInterval(O)},150)}f&&f(b)}),onDestroy:h})}catch(b){return console.error("=== \u6E32\u67D3\u9519\u8BEF ==="),console.error("\u9519\u8BEF\u7C7B\u578B:",(y=b==null?void 0:b.constructor)==null?void 0:y.name),fh.jsxs("div",{style:{padding:"20px",textAlign:"center",color:"red"},children:["\u56FE\u8868\u6E32\u67D3\u5931\u8D25: ",b instanceof Error?b.message:"\u672A\u77E5\u9519\u8BEF"]})}}const Xbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAACqSURBVHgBzZFNDoQgDIX5uQ3hOMDam8gcxS2nmDkEbL0JDDViiJay9SVNatv3RZ+MvUbOud0Ys87u4MZau7dn0e02zrmnILCDm1pbm8nWxBi/WmteW6+UYiml38D8CSH4B4CCjMwgjr1qzcOXUtZax/HIPAT0kBOAmkFiBMg5F6y/S2LD/ptrQQ5osCjgHtjs70jK3OYURM7MM8gVohBiodIGwe7MZWGv0R+Uy3dwBYPzyQAAAABJRU5ErkJggg==",Gg=({title:e,setOpen:t})=>ut("div",{style:{width:"100%",height:"60px",borderBottom:"1px solid #EBEBEB",padding:"20px",display:"flex",justifyContent:"space-between",alignItems:"center",fontSize:"16px",fontWeight:600},children:[ee("div",{children:e}),ee("img",{src:Xbe,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>t(!1)})]});zbe();const Kbe=({curFileInfo:e,onClose:t,token:n})=>{var s;const r={title:"",subtitle:"",backgroundColor:"#f8f9fa",showGrid:!1,showLegend:!1,showTooltip:!1,showFullscreen:!1,showMinimap:!1},[o,i]=nt({nodeList:[],edgeList:[]});Et(()=>{console.log("curFileInfo",e)},[e]);const a=async l=>{if(!(!(l!=null&&l.id)||!(l!=null&&l.cyphers)||!(l!=null&&l.fetchUrl)))try{const{cyphers:c,fetchUrl:u,id:d}=l||{};console.log("getGraphData params",c,u,d);const f=await vr.post(u,{cyphers:c,ontologyId:d},{headers:{Authorization:n}});console.log("getGraphData res",f),i((f==null?void 0:f.data)||{})}catch(c){console.log("error",c)}};return Et(()=>{a(e)},[e]),ut("div",{children:[ee(Gg,{title:e==null?void 0:e.graphName,setOpen:t}),ee("div",{style:{width:"100%",height:"calc(100vh - 60px)"},children:ee(Ybe,{centerNode:{vid:(s=e==null?void 0:e.traceNode)==null?void 0:s.vid},data:o,layout:{type:"force",linkDistance:190},title:r.title,subtitle:r.subtitle,backgroundColor:r.backgroundColor,showGrid:r.showGrid,showLegend:r.showLegend,showTooltip:r.showTooltip,showFullscreen:r.showFullscreen,showMinimap:r.showMinimap,customPlugins:{},onReady:l=>{console.log("KnowledgeGraphPreview ready:",l)}})})]})},IE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAV9SURBVHgBvVZfb1VFEJ/ZPS2l9cpFQypSEEMhUmKiYjQBoxDjm8ZoQuKjTyZ+AV9MrOAH8MlHE99rRKOvPgCSoAkalbQx1mBLLV4vpX9u2t6es7vjzOyevZdg5Y2b7N09c3Zn5jfzm9kDcJ9/uN2LZy6c/RAMfoCASFlKcoKAREb8H0Us/G89RH2v9OHc9gYvnQusDPnHU1Ajaky9jAbjGsQhijPV+6IjaVYdcTuY7QzyaT4ouyijU5k8q5hEC1JaK2KFo/ti6Kg+GWrnoID/+yUDmM9TDUxDG50Ssf5jL+SEtQGq98E9ECZDd6IGjWVUlgxjTlKMxl1nkvG+FMhWejtQ+HgzVM1Vt0n/dNfwRneZ/u6u4HK1Dl1f8ZZwV75Xqk1YDyX8tDan2iJirJVjzkZKv0jrkE7yQ5ONggsBtkJFnXIDV7bWYbnswLovMUQnE4mSKn7eMzAiijKhqAaCRIk06YAyUA2K+GDexUh88HwwkOO5Cg6dcxAghiYRNBOVCorhTXRSttZ5jZkVZmGkGmWDyWHCwAgDk8o5z4YqKitHlavQM/raWEKpFipTwe3OCiXMiD18cVYKZw71GUw8kpA0B4bhUGOUxPhiZwlLX8JDQw/S0V378NbmKsysLmTdzjr6q3UTEqJM2x71YkhrapkzZ87kN6m+YKPqwvMPH8K3Dp7AHWDB+0BvjD2L7xx+GTrdDUFPnsPsXQUyF6yzQMOzASszD8syC7JGKgySlZnlZmpqKuJlgYzABtfLLZi5vQA7i0E4vfcYPNHYiy8+MgEXFq/B9U6LwAckz1kNknLCAUyK1Sgb0rUFMTTAT1FuUR1IISXNX2osHEv4sf0HHGjsgVfGnoIju/ZBm0P5+exl4GRq1IwxylIpZKNpjQyJvYawl03IsyxNMthrj0IOPtKttuDb+Z9huNgBR3ePwdTv38GtzTVSbYxKB0UFBcRw9oWOYphl3RsSZjMxMVFTVLwUpKBM9R72jjRz8o/tPgDkHBsKrBplsHJDMhfGyICCDIfXinFUGePnZ7QxvyhhNtPT01TnUPKh2LksmoPDcOLRCbg0/wtMt+fgpf1PwrHmfkAuF84hyYye1y6gGLIcxQFjhSg5Z2JEUEUyJdIcP3481yCm6jD88Prhkyo/f+0ifPL9F+rUu0+/BlyUXHwVUOl47blgvTLTMqKovGYsZCNMquiEdJpGo5GLRq8tdn589z4YGRyCK3PXoL22RJtlF7+ZvgyvTpyEN4+8AOdnLiKzhkPMEbYVrP45D3UtZyXx4r7j+hWyFZ1OJ3ca7jBSF/Db0hx89esFuL60KCiQ80mfXvkSPvvha2QkYG0BwTA6g4IY2SPlpehlMKJD25sYDdB3pbLJ4urVq7JYYWkzukHabYQ0xIO9AMmTvhMDhlQkiqUU2uUSaalAuhQ8xXaVvj8wrrG/tQGjfG9oeOh9fvGYZaWDpoAGk6a58wHpMjAyMKTMNZaTzmetEWoYcOTpRmsR0VGqvxxZzLdwbpqxt9e3vh0dHS3Ksiz8iLfh8WE7ePRgS4mkpR0PxOqm3AkZZfIbIzyT+mhKXuh94UB6odpgfHwcWq0WFUXh7aD1uMGcCHyefTR8ynBk5ZnvK25rJCGUZ+46rMHJHGU6BK2TNMg5VlBJCcm7gLJX3Z+dnSU26tvtNrOo8J25m1tCdzEkSrjuJI9g2Sgb4YGqUHpqMqQzK48Gs+HsAGGVnJJwQq/NxW+cMcA9p5/bkBBJ7vRa096AiXlBc8j0SV0R8ydAok6ug97HaYyp1LicksF4wJ06dcrBAnhG8REqKlQE0kmUjYy2Ro0+hlU7T5LXSKFGKmdiiIkcnQXoK9nJyUkjow9tP/I8+vboOcqEvPfvX+6cfN20TwR9AAAAAElFTkSuQmCC",Zbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAATKSURBVHgBvVZLbxxFEK7qmXViW7acYA6WIsHBUiRLnCzuBq5cfedXcEHCPC7cOPET4JYfgbghTAQHC4EvCBwrD7/iXXsz092VevXMrGUnOWWk3pme6a6vvqqvqhfgLV9404ePfzz6KgN+GRCRiAY7kICIf4D4k73jObwWSczkb25c+NFPJ1kMidFMahEVzAEE0D3GGSdeQUKucOMXNzDDTt75XAx3xjswoQHXsns9YPF+cC+sZoz43dYQYMAZSN0zCPkrAa9zoAMfMJ1x4AanBynQzZ9xnr6/jLAyboieTBI+Gmd6zPfnU4IpZzPnWWEI3vOG4KIF+ONZIqDeXsnpdQ7Uft/h9SuyJ2aAhgEmLzKDZTjhcdkSJjAjnKc+tDxfnQ9FpTTwxtLpTqA7KA+1e/W+82flZsw5q1ooE6SUMTGBDIbUKRJVkWCBFGuhxNkE5KDlndqGHtCuTKqyHiiTjsjPto1EF+qxc0ps4WLMcbe5lqYuUUoFvEAOANGtcS4lYXBvuablOcBxG6CN7IBr5HgS4Z+jBsq+NAI6fnomZJDUyjC2AD0hQ6i3t7cByiKlx6DM8P67I3xn8TZcvf5+8gL++mVqomBTKXEoc+7k6BS7UFiJlrBbdGoOc8sYdMFqORq3+OisgYOTBp5NIt27M4effnAHHjw8oYcHF+rYySR78SHdXajwwe/HpSbVCQmSMbNUK/6VkEpqrYuQMW2bCOfjKTbz5t/ltMHTs0ugEHhJRRCC5lzZ5IRB3mcoTJ0vWUYH5VoAxTdTH+9imfKIUKVIyMZkYUg8z5ESb1HXlYbRCaSCA0ukdzsglxiUUtF99cbGhs9dxhKCnLggI4TYMtDIosXvQttgqthk0KOCkdDzXihk9juIK4heMKiRE2DzpN7b2/N0lO5QjGQNVakjrhFWCDOnhCmwUUxiGygilI5dsSfUdRgqpWFtXb1ArDc3NzvG/l33iFJTTGzfQirNIMbEcBFzhRorwopozmtOmOVSclA6nYoGrQ/wmwz10tJSJ1s9a3mTGOd0QW4j5JTtK99T02KsghBHSw6DzxGc/fuYbVfFBuTuaPQm0Zck1efn5yUE0tfsOZMykpb2658H8PNv/xNnFBLWmGJEqiRbQZOXYsA0nYImlN+pbrQIgpVEd0CiiWZ3d1dmpzxWuvNUQ2gNgDucMJWMQQ7MHBKIX9xxdfHT4wvi3mddJthhaHVo3LzQurarpwWz/HxhYfELfvtezT+36gCLtypYnh9BbkZwe8TtTfwNNbTIW6pac9Qmov8Ojhg9qk3u++CNxsgNjsDS09FBKx96IN9fXcXTD787q1iCtfoup0XFgkGMWUIb/OBAOyXUZgAp/uyc0LREs4AZleH6+jrs7+/T2toap47dZGWKMpIcSh4cDiVGCpoR8nBqyeuz5Y7PFehThl78vYAK3cJO3WRQPDw8hLuf/DCpgme0dBUJmwfGXA/OUubhyknhM8K+2/CknPjZw5kFTPlLaVB/pnrdaseQErH/pCIiyZuEOBljz1NXj11PNcQg57oDJimsra0tuSfMzbeRu4uWh3YcNp5abrFROlA3RMrcHHjwnxsfvA7IBxcv2rMcqunrIX/c2dkJMpxtr4YrY7DG5P4m/7z9egkURHiCa3UU2QAAAABJRU5ErkJggg==",jT="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAVZSURBVHgBvVbNbhxFEK7qmdm1ndhZm40D5M9STCL5BFiIq+EJuPiAxIGn4IKE+XkAngIE8gPkCDxAIKDIUsBEjmMR23H8u/aud7urqKrumd1FdsIpu+rtmZ7p+urnq68X4BV/8LwHH373/EsC/MIhIjMP7EAGZvkBlkdxTe7hpUhqhr4+98UPvt8jNaRGic0iGlgCUMDkMQ458YIg9OPOfZIMDEWna+leDVfGKzANA86M7uWApfcDcxnVkJE0x3cY0OEQpO0ZSPkLAc9yoAIfiHTIgXOcHiiBbf5U6vRt20Oj1WXePg74T4t4S+bDDkNHqkk0TAzFO+wynPQAft8JDNy3V9b0LAfyNC/J+w3d4wmgKwDHpyRgBHsy2j3GANGI1KmfWrlvjrqSpTzgTSxncgKTg3qRJ69mUvzCXEIiMrYwMYRAGCQAgohUMRKNkRATqdZcmedIoARarplt6APGD7GxrA9EbMPLddzGygvzOMUUxMJJS/Ie76017RULqQQvIQcA9T4XJy/UUJgkEQmQ9wHuTGWYYQ6/PT3ldo+Mc+/fGMHdE8K/dk4hFMC7zw40GGSzMpjblDeACtEtLi6aMxp5ngFMjWUwmkmzS1oFFD555xJ8/PYE3GpkEHoB3rzoUNfeu1qDIA5JBiQzOgROhwZGEO/VMKn3OlizA255eblKgg/Rt4kRByRpvHEpckoju/1aYQ5cHc/spfsbJ3IvZfYeXQSJqUve2zUhOyUaa+yskgX53Nyc9qLUirEj9BwpnKTVmedzr0vqjr1Qn2D2ch2p5+HqRHTiz81TZqkzkBSAAjqnc9V4qf04BjPQri5yhVH1sic90ekGGB/JQOt3bbKAJ7un8HCzDdcna1DPkW9fqdt9q91DATSCOY4pNIT0tUhjGuM3goDr3ryJxkphqGSI2xJlITW81ihgeryA++stuPf3kXn31lSO1yfrsP78NBqjmD9ITBRDmGhuDaExOa2W9pS2ifJk9e5djg0oGQoB9zoeJi8WMDs9aiAPN1q81+pZPj56t2lrvz464tCV2im55JGjaD2TXuRKYbhsjSjrbMcZag2T7KqDIKkKSh68dWUUNnY6sL1zjMc95pWNI5y5fMFMPXh8IMYVQSjhXdyt9KCy5aBUOtMHjDpglM2np6cpiYwxtedFP0Ugp8ZrAtjWWjJ1Az5YO4S5a+Owsn4E1JWwMqcsRO46OHi8JbuzqvOpOhqTSPRbkvPt7W091AFL2ZXHv/yxBY82TwxQmInSIvzDT+vw48/rxsbcwBxjpu3j0bc72tJixLEJgCmA4xgZQ7/xAfOVlRV9dV9QG5omTZAzt8jyIlQU/ZJQtLlNsShGozmStWd7Xorvo8o4V7ZiWbxS6CvZzefn57nVan1W1Mc+zzO8WRN9G6vnMDFWwOSFYHQfqwVQUXApDUWWgdhWAeGNp/ty4c2m6D5g4oMFN3AElpqOScCzZvNOrTsyU4SiXtBEIx97Y+EJKb0xHRJKgJiuUoftgIg/cWi6KcWEUb95GJDQZGN2dhZWV/dpamrf48UmB96U1HvEakfU9xAiE2xBLyiTNwJaflH7OkC/ZHa0IAwQCFJ0vLq6yjMzM2Ft7QibLueDlg+Npre0WUeVwBj1uGSYCGhSLe1tN3RSlOdV+h/HZW+WJz6tra3p7Hd2dJqXDg4qGEYSVHm2A9WxPBD+METttONRn8scIIocV62AfeDyzNVuNcklOaaCAi4sLAgD7nlH3W8oeDt6ZEZVBQ491DURayhnea4SJUP+3KRBMjgNCF2M115P9a+gahIZS0tLTkfFgrju/jsG3ol0/z//vNPnXykvrFYTHUlOAAAAAElFTkSuQmCC",Qbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAACE4AAAhOAFFljFgAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAJ2SURBVHgB7ZndcdNAFIXPKobXQAehAuIK4rzxmygV4FQAVICpgFCB7QoiAgOPUSogVIDowAVg35xdSWMlmURSVtfyjPXNeGal2ZXP2d27e1cCOjo2G1NWQQ6O3kHkhMUn0CPBHEfmZ3SJmgSlNURG0BVv2cEWfrvOqkm5AfvwVSEykdfhhzpNenUqm+9R6ZSri4ThDhY4h2QdFeCLvAm3zY/oc5X2VUZAFRNFCVXsMxqT5U2MaOJTlfatG7BkJvoUvgziiibWwoCFJmbmLOpzKk2XN1EaD2tjIIdzf1i4LF391s5AXToDbVNrH6iKvAxDPnnM4gzGjMzZ6RRK6IxAD++RB2CaiqihY0DwLCvFUE5FdAwY/M1KT6GM1gj8yUqH13ZXBXQMLAqiBf+giNYyWjSwDUV0DASFHMZgwKRsACUaNyAvmN8b7KUXWWJmMHb3FWh+IwswQLp0TpiYHctB+JxGdvEI5zxtfXV1TLZHzHFpfkURPGjewBbSHH6OVOwCHyn4FNYUT1s3/53TK6bRfTyQRg3Iq3CItPdjij2kuDHF796qaE9fC3xjac/GCDxozIATn/c+KMq434xCp/zFeMyV6T+DO6Boe/41Lt2wcXIBD7wNuOC0idv1npzYAOZLgPhG9aFrY1elfGR6rOuBlwEnnsEJuB6dUbQNzgsKP76vHed8jDRP8sZvBHpZcCITb+d2kPbyqvAzEFC8UHyeOnPF4cE8wQrx28gE9uWTmzYM4D6nhtea/hC8RoBz3b70PUGLdIf6tukMtE1noG02682cvA0Fa0b5CBiXKrRD8avNHVT4SulOVAlWTZrdVvpO1tGxyVwB1vCn+6Y+ZDoAAAAASUVORK5CYII=",BE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAfnSURBVHgB7VhdbFxHFT5n5t7d63XWJnYc167Jj5u2wklDGlciVCJsKUKRAuoLFvAQflRQUQNURZWQ4KHNC1KQihp4QFRFiEgIlaiVEBWPlYUoVUvskASHiqaNg62k+bE39np/7r0zczgzd3e9dt24uwkv1R5rfOfOvXfm+86cv1mAtrSlLW1pS1va0paWBaF1afyWap33vvfIfZJKnwLyR0FSb+/WXT76pRmNdNLo1L9STz43CbdRsJnn1NB/puHZg4e+0DHSCY8GKA8ZjB8gfoL8MqGAzXcNA6KsT0cCzyiEY6/NnT3+0JFxBbcouN740w39navfHwPYd8fDD3ao1DHW8P0ImkEb93mdwDATEAKW6SdTkPDfQYNfxief+yfcZgK1MWTwcI6vI7kcj41Dju/Hr4KAnSPuyWO9B75FwvxcAGUIE9AWqJuAyGob+rfvABCYzIrucX0BploBKX8of/DLX8FtIuDurdZrwOdnZ+WNTMGrKIOpSIvaiz/aP/rtnjQ8aywMcOp2jXkwQ0uC//PbA8N3g+ErCh6zz1ctaIkblN/xnvjFC3CbCDjN53I58TuY9gZ3fL770OHDn2AzCKIoEqK8kElfmb47/faZHwsyG4isSjWgIat0VrZ2k4TzefAqRRjYvhVQsg8Iw5QQ1tp0AlHUOn3Af+rZv8EtEKhr39r61NiIfG3icsfxV089PLB16zZjDEIcynjm/BZz4a39VJi7V2uTMloxeLZ9wztBtm+ANO8LGci/OQ5DO+4CKTy3AwI/iIB1bjEpgvAz+NjzJWhCROONAz8G2Mems/j6ogw85bONZhgObwD/LxcCfe3KkCot3qGU9kmxtpViwDE3DiixBsMNeEzwX+SIWMew5IzbobW1yOSM2RtHmUehSakRwPrcJwD+UxjHrn6NJgo8o5TdfwKLby6fVYvXh0jIbggCpCAAzZEGDQM2muzVNsOEtIrBbooxycy0bsQm8JT6OrRIgGrT9+UAN5ZHsNhrUFN9WLP5GFq41o1LC73ZA19JdX3xG9D9yDfhY2PfBbFnP1AUIcUMOo74bcMaoWRSShzVESDhgqnBhgUbCCCoB8JjT+2CFgg0TJdzAX971IvpwO5uZMNMFJfLQItzXapczlpTXnz1Fci/8FMo/PXP0Ln700B9g2xGOgHPO4BsUmw0kCS1xPbJsamF2dVQ0MGRUNwHLRBw051zs4zDhqUIl7o0pilARWhjZ2jCElGxkIGokkoSleJKwUD89jnnvNDZxQRY+yoCo0Jw/lEFRjW0VUNFukkGjYNRaIFAPeNm70mum8Aqk9gSFOuVVRrHOqoseXGlLKxTcuyG0E9Dau8+BiQhunSBuYVsaRWI+RqFJdBW24YSwCaJUFj16Q9qHKl6oQnxap0jrMc/8joTEwCprMJilZBSRkuQYbkcqahY1NFS0YX+roe+xEnrIET5G/Dey7+B8MK7YHkmYZWRBBHk52/A1OQkBEKC+6i6F/WiotqhhkSNJvChCfFW3HFtM8o4CtsA3pg12GFfwFiB1qiEKcdKlSrlio0tMPPib6Fy7u8uZLrY70IOh1HWNCjWOvsCKG420yblkQMuquaz7OANRFwrzkATstKJTyQ309MAGZ+XynDoNMjGLkP0PN4Ub96YuGwRCQ6TIorARh6KYqI46XPwZx+osPnFDnyCrOq8BMs70OgW1WYLDc4bJ6EFAitiQn+HR+VFSVEFSbDyeSgKunsKXpC+xEvkdaFA2tp4rFwC44bWaY0No+zEdgyjuK6XhiyzjnBCE6mz0IR4qwcK2UYyZdBCOwIy5UfYvfG/nhdc/PfPfrLFD8sZDhkubFq7J6NcCQH2deu4ouaZrCN28pWxE9cErxHP7H3p5CloQlaUElPVFZYupqiUnyctORmHoSPgbegs+4P3zIqg46yvy9c5axlnPsq2yPmCbXYn7A4YDqm1KjpJWtWq9WZizDFoUsTqgfFxcIlscNgzMvbU+dNTJYhLzro7hu6c97LZKTJiOg6VotDafcjArekkTdtIxGMCjauHkgVMdfa1izlw1PD8n/Ibj0OTUj+8WN08U61E86OjIpWdk68XRPpSYWHD58a+NrCwWPEkxbLTUKq/cGVkKF46iqQ7XdGfOB9IexawDmuM2wGfE10ak/PMGrqqAnerV3w/tW/Xi2+ehhYJ1PpocwGbEg6OAl4aGPArlzv8q6aUwpLvi7QRNrn53A4O93+1B81Ri2v5JEbuGCltY/CWkO2/f6ll8CLh9vgnXzrV0qlMrh6wh0XeBXj3Xr7ObqHunsh0dvXoXl/EPYRx50YR3dfphfMlf3Kgi64FUuz3kYMsI/FY1Z4DzZWlO5Mlu5Ngfz8B5lZk1z285+XTz0OLctMj5eM5wGwB8OrmHU5Rb92oiKEhTrJlXf/uTuzbzch/zwXbcK1ormnWxvXqSbMhklIyLnASQnxizysTTZ/CGkWuRSDH1z6+/mUaIM87Qfl5WCzOU//SEMHmNM2GkjZRiq6VBJyX+nIm9H6d9uVF/nqbBOx3SQmXCdQmtiW2EfQPrrCOzmyS3//sHybegVuUm/0qUS/waj+nWN9wP01UxXbHq1eo9g9m99zvS72TrWrUKP1x9oNYo7wuJU3w2fiN3ScmmkpUrRBYMU7Vm6dh3SNVXY4sf1r/HtZNAq3JhwX1ocGvkv8L6La0pS1taUtbPjLyPy268QDdSiqgAAAAAElFTkSuQmCC",RE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAVNSURBVHgBvVZLbxxFEK7qmXHWiR1siwNIFnmAhDAIlERw9gFx4J57jty5IIRk5Q8AF/4Cl/wJCyRuFhJInALhsQRC/Iqza292Zrr46tHrjSVzZLS93T3TXY+vvqpuov/54fM+fPTV9A5R9TkWrAoJ6c93sDAJC7GcrhYugiSEytzE5/wAW+8mOvdJWyR5lVyZa+TnlHgTUZEiGGZdJ/Yj//Pe5/lazvJlfa4+kavmhZg34U8Oz+zHc2vdbVg0c42jdy/tH69W/sNDtTuzmsfmhRtv5uogRLvXsUby6XsJu9j2cJmfq1CyzM9ctm0PkY5TGBOj4ljRSYazGxvI+GKRO5D/xbSllfGE5GAkvPuEZPco8/iEaNpDf36eYCp9NCF61hHdf2i6Qrmb5dgXQ3lmQIkhCEIr6lSXidqOZTzpeXQi9GQMoa2bp+jynAs6v7xoH4w4M6/CHTcCPy6cI1OoIq66JbpXuIfSHvzozQDhtg8a+KaiWKSAFFg6n4071jMb3wrxzKCi0B54yEsDptUlKOqFH+6RqLdtJ5yDAFzCED5NO6G9IycTG03tG4cNbEQLoOWsQjW5Sk6otWWmFoFDXHnaRY7RLBRcAtP3LMNd85yfpwwXoRxstjf17du3TZF6gMSko3Gmtmf66XeRHtYbvJJEey4CFKrs1QXQU50iuFywDpQN7TSju+pM9+7dm5miz6TN9NdeT+OTzHDQsyBn/uCGlxmosTjrOMe4qaG0ZrG+0pZinGShJm4qogZ9jb7e2NhIGtweMeuyW5bxN7hgrDDDN9+u6M0rjHgRf/sjEE1aWMx8TsjkKkF1qk4pLMKzSJfyEN8sLQClbjRaaIBeWq3ojSsJZOjk2suJ37nu9eHGqwzPRb7/JXsNgwyEnNQbl5fmCp7XmFksw4A6sDWSwVVAkPjFy4k0z9+/2fDiwlzlx/Pu68R/7DHtPQ32scOoMBHDEK5kPi+NXBJFLojT5JynIAWSXaAgUSkAXa/eE80Xf32Ojom+3u5RgZhWLhF990MLwYkM3yK/GOl5IjPS3Lp1yxfB3sUL+qZQ6HRP1N1ZW75I9OF7iSZwZYoXhSh10jE8wLyxdyCSjgthtC0vL4unhdDJM5GDceZHhz09PMj0z5HQ0+MsJ62wZwOaCU6oPhUdI0cv9om+2cf+EiYPj0MYZJlDR+rhcKigI58yHT/LfDhu6dFhpl8f9zTcy7Q/6vmkjZNAI1RVsLYhkFIwpgnYPZmqBo1f8srpRScALSeHBZPr+/cX1KBDseINxSigLYLYou+0Za+nookPSuLgoJ4zVaAJdNLfRyw1GJZPi8nsQsLlDGX31tJiY4No/2D0yeDi4qfY8AocoEHDtDRIdBmxUrYudlAEIxJIoTLrJpHyQ4vAn487TlkPVgluBLBW4kt6zOxgBmmaneFwYbl+azB4Ya0ZpaVmIV2qF29+9jPY6/nq9ordnwwYVQyNCWyAn5QaZymnucvT7Nzlsl9KHq431/PweNSmapCrBeq7BYSHKiCYgtUeP8kclT9Kda5EEzDqBUc+u54o2XbrsNPDa2+9s7MDQF7L6+uTdnhcy9pot9+Xjtf6ZDGbFYwcSg2p5PPk156gcOTc/NWkpGI5pcLDzc31fnt7G9+Gsm/L1vGhOQQaK3qCGPtIJSc/EoNAqowC3tDjmEfyc7mu2W1PlacHCRZnKFOSoa5Qt7m5idNv2IF2H2Pdb0gCi16FspsyQM7gp1Q6VqZSjeOngrwKErQZgZBiPsb5qnXavvEBytbd4rnRdmtrK2kjv82leJ/Otrk17GyQc2/wZ59/AcalYkfFCITdAAAAAElFTkSuQmCC",NS=e=>e||"",Az=["txt","pdf","jpeg","jpg","png"],Jbe=e=>[""].includes(e),ip=`http://${location.hostname}:9000/`,LT={docx:jT,doc:jT,pdf:Qbe,xls:IE,xlsx:IE,csv:IE,ppt:BE,pptx:BE,pub:BE,txt:Zbe,png:RE,jpg:RE,jpge:RE},exe=e=>LT[e]||LT.txt,sC=()=>"/proxy",DS=e=>{var r;let t=e==null?void 0:e.file_type;const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n)t=n.split(".").slice(-1)[0];else return(e==null?void 0:e.file_source)||"";return Az.includes(t)?n.includes("http")?n:`${ip}${n}`:(e==null?void 0:e.file_source)||""},TS=e=>{var r;if(!e)return"";const{file_name:t}=e;if(t)return t;const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n){const o=n.split("/");return o.length?o[o.length-1]:""}else return""},ap=(e,t)=>{var r;if(!e)return"";const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n){const o=n.split(".");if(!o.length)return"";const i=o[o.length-1],a=(t||"").split(".");if(!a.length)return"";const s=a[a.length-1];switch(i.toLocaleLowerCase()){case"ppt":case"pub":case"pptx":return"pdf_slides";case"xls":case"xlsx":case"csv":case"md":return s==="pdf"?"pdf":"markdown_table";case"png":case"jpg":case"jpeg":return"image";case"html":case"htm":return"html";case"txt":return"text";default:return s==="ppt"||s==="pub"||s==="pptx"?"pdf_slides":"pdf"}}else return""},txe=async({filePath:e,fileName:t,token:n})=>{if(e&&t)try{const r=await vr.post("/proxy/index/knowledgeBase/file/stream",{convertedFilePath:e},{headers:{"Content-Type":"application/json",Authorization:n},responseType:"arraybuffer"});console.log("response",r);const o=new Blob([r.data]),i=window.URL.createObjectURL(o),a=document.createElement("a"),s=document.body;a.href=i,a.download=t,a.style.display="none",s.appendChild(a);const l=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!0});a.dispatchEvent(l),setTimeout(()=>{s.removeChild(a),window.URL.revokeObjectURL(i)},100)}catch(r){console.error("\u4E0B\u8F7D\u6587\u4EF6\u5931\u8D25\uFF1A",r)}else console.error("\u7F3A\u5C11\u6587\u4EF6\u540D\u6216\u6587\u4EF6\u5730\u5740\uFF1A")},$z=(e,t)=>{var n,r,o,i,a,s;try{if((r=(n=t==null?void 0:t.metadata)==null?void 0:n.page_size)!=null&&r.length){let l=((i=t==null?void 0:t.metadata)==null?void 0:i.page_size)||[[0,0]];Array.isArray(l)||(l=JSON.parse(l));const c=((a=l[0])==null?void 0:a[0])||0;return(((s=l[0])==null?void 0:s[1])||0)>c||!e||!c||c<=e?1:+(e/c).toFixed(4)}else{const l=NS(DS(t)),c=ap(t,l);let u=c;const d=(t==null?void 0:t.file_name)||((o=t==null?void 0:t.metadata)==null?void 0:o.source);if(d){const f=d.split(".");u=f==null?void 0:f[f.length-1]}return zT(c)||zT(u)?.6:1}}catch(l){return console.log("error",l),1}},zT=e=>["ppt","pptx","pub"].includes(e.toLocaleLowerCase()),nxe=e=>{if(!e)return"";const t=e.split("/"),n=t.length,r=t[n-3];if(!r)return"";const o=r.split(".");return o[o.length-1]},rxe=e=>{try{if(!e)return"";const t=e.split("/"),n=t.length;return t[n-3]||""}catch{return""}},oxe=({content:e,onClose:t,token:n})=>{const r=a=>{if(!(a!=null&&a.metadata))return;const s=ap(a,""),{page_number:l,page_size:c,position:u,offset:d,chunk_type:f}=a.metadata;if(s==="markdown_table")return d!=null&&d.length?{annotations:[{id:ga(),offsets:d}],initialPage:1}:{};{if(!c||!u)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size\u6216\u8005\u6587\u4EF6\u5750\u6807","color: red"),{};const h=Array.isArray(c)?c:JSON.parse(c);if(!h.length)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size","color: red"),{};const m=Array.isArray(u)?u:JSON.parse(u);return!m.length||!l?(console.log("%c\u7F3A\u5C11\u6587\u4EF6\u5750\u6807\u6216\u8005\u6587\u4EF6\u9875\u6570","color: red"),{}):{annotations:m.map((g,v)=>({id:ga(),pageNumber:l[v],x:+(g[0][0]/h[0][0]).toFixed(4),y:+(g[0][1]/h[0][1]).toFixed(4),width:+((g[1][0]-g[0][0])/h[0][0]).toFixed(4),height:+((g[2][1]-g[0][1])/h[0][1]).toFixed(4),content:"",color:f==="image"?"#60f74f":"#4FC3F7"})),initialPage:l[0]}}},o=Gt(()=>{var a,s;if(console.log("content88888888888",e),e&&n){console.log("content999",e);const{annotations:l,initialPage:c}=r(e),u={...e,metadata:{source:((a=e==null?void 0:e.metadata)==null?void 0:a.source)||e.parse_url||e.url,page_size:(s=e==null?void 0:e.metadata)==null?void 0:s.page_size}},d=NS(DS(u));return{filePath:d,fileName:TS(u),fileType:ap(u,d),totalPages:u.pdfPages||0,token:n,annotations:l,initialPage:c,initialZoom:$z(598,u)}}else return{}},[e]),i=Gt(()=>o.filePath?(console.log("curData",o),ee(BF,{initialZoom:o.initialZoom||100,convertedFilePath:o.filePath,fileName:o.fileName,fileType:o.fileType,initialPage:o.initialPage,totalPages:o.totalPages,authorization:o.token,annotations:o.annotations,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:a=>{switch(a){case"viewer:close":t();break}},tools:{close:!0}})):ee($c,{}),[o]);return ee("div",{style:{fontFamily:"Source Han Sans CN",fontSize:"12px"},className:"h-full w-full",children:i})},Oz=({curFileInfo:e,onClose:t,token:n})=>{const r=Gt(()=>{var i,a,s;if(e&&n){console.log("content999",e);const l={file_source:e.parse_url||e.parsedFilePath||e.url,file_type:e.file_type,metadata:{source:e.filePath||e.url||((i=e==null?void 0:e.metadata)==null?void 0:i.source)||"",page_size:(a=e==null?void 0:e.metadata)==null?void 0:a.page_size},pdfPages:e.pdfPages},c=NS(DS(l));return{filePath:c,fileName:TS(l),fileType:ap(l,c),totalPages:l.pdfPages||0,token:n,initialZoom:$z(((s=document.getElementById("pdfBox"))==null?void 0:s.clientWidth)||0,l)}}else return{}},[e]),o=Gt(()=>(console.log("curData",r),r.filePath?ee(BF,{initialZoom:r.initialZoom||100,convertedFilePath:r.filePath,fileName:r.fileName,fileType:r.fileType,initialPage:1,totalPages:r.totalPages,authorization:r.token,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:i=>{switch(i){case"viewer:close":t();break}},tools:{close:!0}}):ee($c,{})),[r]);return ee("div",{id:"pdfBox",className:"h-full overflow-y-auto",children:o})},ixe=({curFileInfo:e,token:t,onClose:n})=>{const[r,o]=nt(1),[i,a]=nt(10),[s,l]=nt([]),[c,u]=nt([]),[d,f]=nt(0);Et(()=>{var v;const g=((v=e==null?void 0:e.metadata)==null?void 0:v.fetchUrl)||(e==null?void 0:e.fetchUrl);g&&m(g)},[e,r,i]);const h=async({url:g,params:v})=>{var y;try{const b=await vr.get(`${sC()}${g}?${new URLSearchParams(v).toString()}`,{headers:{Authorization:t}}),w=(y=b==null?void 0:b.data)==null?void 0:y.data;if(w){const{columns:x,dataList:E,totalData:k}=w;l(((x==null?void 0:x.slice(1))||[]).map(S=>({title:S.businessName,dataIndex:S.physicalName,key:S.physicalName}))),u(E||[]),f(k||[])}}catch(b){console.log("error",b)}},m=async g=>{h({url:`${g}`,params:{pageNo:r,pageSize:i}})},p=Gt(()=>{const{databaseName:g,businessTableName:v,tableName:y}=e;return`${g} - ${y||v}`},[e]);return ut("div",{children:[ee(Gg,{title:p,setOpen:n}),(s==null?void 0:s.length)>0?ut("div",{children:[ee("div",{className:"p-4 overflow-auto h-[calc(100vh-120px)]",children:ee(nH,{columns:s,dataSource:c,pagination:!1,scroll:{x:"max-content"},rowKey:"id"})}),ee("div",{className:"flex justify-end px-[18px]",children:ee(cH,{current:r,pageSize:i,responsive:!0,simple:!0,total:d,showSizeChanger:!0,showQuickJumper:!0,onChange:(g,v)=>{o(g),a(v||10)},onShowSizeChange:(g,v)=>{o(1),a(v)}})})]}):ee(qz,{})]})},HT=({i:e,item:t,j:n,clickTag:r})=>(console.log("j in tag",n),console.log("i in tag",e),console.log("item in tag",t),ee("div",{style:{minWidth:"16px",height:"16px",backgroundColor:lxe[t.key],margin:"0 4px",color:cxe[t.key],display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"2px",fontSize:"12px",cursor:"pointer"},onClick:()=>r&&r(e,n,t),children:n.index},n.id)),axe=()=>"/proxy",_E=e=>{if(!e||typeof e!="string")return"";const t=e.split("/"),n=t.length;return t[n-1]},sxe=e=>{const t=(e||"").toLowerCase();return["png","jpg","jpeg","gif","bmp","webp","svg","ico"].includes(t)?"rag/pic":t==="pdf"?"rag/pdf":["doc","docx"].includes(t)?"rag/word":["xls","xlsx","xlsm","xlsb","xltx","xltm","xlt","xlam"].includes(t)?"rag/excel":["ppt","pptx"].includes(t)?"rag/ppt":t==="txt"||t==="md"?"rag/txt":t==="csv"?"rag/csv":["zip","rar","7z"].includes(t)?"rag/zip":["odt","ods","odp","odf"].includes(t)?"rag/odf":t==="json"?"rag/json":"rag/file"},Mz=e=>{if(e.loading)return ee(uH,{size:"small",style:{marginRight:"5px",width:"12px",fontSize:"12px"}});if(e.type==="dir")return ee(Kr,{type:"rag/folder",size:16});if(e.type==="file"&&e.fileType){const t=sxe(e.fileType);return ee(Kr,{type:t,size:16})}return ee(Kr,{type:"rag/folder",size:16})},lxe={knowledgeList:"#EAF4FD",searchList:"#E8F7F0",databaseList:"#FFF4E5",graphList:"#E7F8FB"},cxe={knowledgeList:"#2072F0",searchList:"#39B83F",databaseList:"#F48C14",graphList:"#10BBD9"},WT=[{key:"knowledgeList",name:"\u77E5\u8BC6\u5E93\u6587\u6863"},{key:"searchList",name:"\u8054\u7F51\u641C\u7D22",hideBtns:!0},{key:"databaseList",name:"\u6570\u636E\u5E93",hideBtns:!0},{key:"graphList",name:"\u77E5\u8BC6\u56FE\u8C31",hideBtns:!0}],uxe=({type:e,data:t,token:n,eventsEmit:r,is_download:o})=>{const[i,a]=nt(WT),[s,l]=nt("mark"),[c,u]=nt(!1),[d,f]=nt({}),[h,m]=nt("knowledgeList"),[p,g]=nt({knowledgeList:[],searchList:[],databaseList:[],graphList:[]}),v=Gt(()=>{const E=4-i.length,k=Array(E).fill(null).map((O,A)=>({name:"",key:100+A})),S=[...i,...k];return console.log("rrrrrr",S),S},[i]),y=E=>isNaN(E)?"":(+E).toFixed(2),b=(E,k)=>{switch(E){case"knowledgeList":return exe(k);case"searchList":return Eie;case"databaseList":return wie;case"graphList":return xie}},w=(E,k)=>E==="graphList"?k.map(S=>({...S,name:S.graphName})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="knowledgeList"?k.map(S=>({...S,file_type:nxe(S.source)||S.file_type,name:rxe(S.source)||S.file_name,score:S.rrf_score})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="searchList"?k.map(S=>({...S,name:S.file_name})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="databaseList"?k.map(S=>{const O=S.tableName?`${S.databaseName||"\u6570\u636E\u5E93"} - ${S.tableName}`:S.databaseName||S.name||"\u6570\u636E\u5E93";return{...S,name:O,file_name:O,file_type:"database"}}).sort((S,O)=>(O.score||0)-(S.score||0)):k,x=(E,k,S)=>{var O;switch(S.key){case"knowledgeList":const{pdfPages:A,parsedFilePath:$,order_num:M,tags:N}=E||{},D=k.id||M||"Unknown ID",T=(N||[]).find(j=>j.id===D);if(E.type==="video")return console.log("sdgasdgag",{file:{...E,...T}}),r==null?void 0:r("retrive_tag:click",{file:{...E,...T}});if(console.log("click knowledge tag",E,k),!E||!T)return;const{metadata:P}=T,I=P.source.split("/"),R=I[I.length-1]||"",H=R.split("."),V=H.slice(0,-1).join(".")||"Unknown Label",L=H[H.length-1]||"Unknown Type";f({id:D,title:V,file_name:R,file_type:L,file_source:Jbe(L)?`${ip}${P.source}`:$,metadata:P,pdfPages:A}),l("mark"),u(!0);break;case"searchList":console.log("click search tag",E,k);break;case"databaseList":console.log("click database tag",E,k),l("database"),f({...E,metadata:E.metadata||{},fetchUrl:E.fetchUrl||((O=E.metadata)==null?void 0:O.fetchUrl)||""}),u(!0);break;case"graphList":console.log("click graph tag",E,k),l("graphPreview"),f({...E,traceNode:((t==null?void 0:t.traceNode)||[]).find(j=>j.id===k.id)}),u(!0);break}};return Et(()=>{if(e!==Nz.REFERENCELIST||(console.log("data in reference drawer",t),!t))return;const{graphRefs:E,knowledgeRefs:k,webRefs:S,databaseRefs:O}=t;E!=null&&E.length&&(p.graphList=w("graphList",E)),k!=null&&k.length&&(p.knowledgeList=w("knowledgeList",k)),S!=null&&S.length&&(p.searchList=w("searchList",S)),O!=null&&O.length&&(p.databaseList=w("databaseList",O));const A=WT.filter($=>{var M;return(M=p[$.key])==null?void 0:M.length}).sort(($,M)=>{var N,D;return(((N=p[M.key])==null?void 0:N.length)||0)-(((D=p[$.key])==null?void 0:D.length)||0)});a(A),A!=null&&A.length&&m(A[0].key),g({...p})},[t]),ut($c,{children:[ut("div",{className:"listWrap w-full h-full",children:[ee(Gg,{title:"\u77E5\u8BC6\u6EAF\u6E90",setOpen:()=>{const E=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(E)}}),ut("div",{style:{height:"calc(100% - 60px)"},children:[ee("div",{className:"tabs",style:{display:"flex",justifyContent:"space-between",padding:"12px 20px"},children:v.map(E=>ee("div",{className:"tab-item",style:{padding:"5.5px 12px",backgroundColor:E.name?h===E.key?"#4E6EF2":"#F5F6F9":"transparent",cursor:"pointer",borderRadius:"4px",color:h===E.key?"#FFFFFF":"#4E5969",fontSize:"14px",minWidth:"80px",display:"flex",justifyContent:"center"},onClick:()=>{E.name&&m(E.key)},children:E.name},E.key))}),ee("div",{className:"listBox",style:{height:"calc(100% - 66px)",overflowY:"auto",display:"flex",flexDirection:"column",alignItems:"center",willChange:"scroll-position",transform:"translateZ(0)"},children:i.map(E=>{let k=p[E.key]||[];return h!==E.key?null:ee("div",{children:k.map(S=>{var O,A,$,M,N,D;return ut("div",{style:{width:"360px",padding:"4px 8px",borderRadius:"4px",margin:"6px 0",cursor:"pointer"},className:"listItemBox",onClick:()=>{E.key==="searchList"&&window.open(S.link,"_blank")},children:[ut("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ut("div",{style:{width:E.hideBtns?"339px":"288px",fontSize:"14px",color:"#1D2129",fontWeight:"700",display:"flex",alignItems:"center"},children:[ee("img",{src:b(E.key,S.file_type),style:{width:"16px",height:"16px",marginRight:"2px"}}),ee(Zs,{placement:"topLeft",title:((O=S==null?void 0:S.name)==null?void 0:O.length)>17?S.name:"",children:ee("div",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",width:E.hideBtns?"322px":"258px"},onClick:()=>{var T;E.key==="knowledgeList"?r==null||r("knowledge_referenceFile_title:click",{data:{...S,file_type:S.file_type,file_name:S.file_name,metadata:S.metadata,parsedFilePath:S.parsedFilePath}}):E.key==="databaseList"&&(l("database"),f({...S,metadata:S.metadata||{},fetchUrl:S.fetchUrl||((T=S.metadata)==null?void 0:T.fetchUrl)||""}),u(!0))},children:S.name})})]}),ut("div",{style:{width:"52px",justifyContent:"space-between",alignItems:"center",marginRight:"8px",display:E.hideBtns||S.type==="video"?"none":"flex"},children:[ee("img",{src:yie,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>{r==null||r("referenceFile_filechat",{data:{...S,file_type:S.file_type,file_name:S.file_name,metadata:S.metadata,parsedFilePath:S.parsedFilePath}})}}),ee("div",{style:{borderRight:"1px solid #E5E6EB",height:"14px"}}),ee("img",{src:bie,style:{width:"16px",height:"16px",cursor:o?"pointer":"not-allowed"},onClick:()=>{var P,I,R;if(!((P=S==null?void 0:S.tags)!=null&&P.length)&&!((I=S==null?void 0:S.metadata)!=null&&I.source)||!o)return;const T=((R=((S==null?void 0:S.tags)||[])[0])==null?void 0:R.metadata)||(S==null?void 0:S.metadata);txe({filePath:`${ip}${T.source}`,fileName:TS({metadata:T}),token:n})}})]})]}),!!(typeof S.score=="string"||typeof S.score=="number"||(A=S==null?void 0:S.tags)!=null&&A.length&&S.tags.length>0&&S.tags.length<=10)&&ut("div",{style:{display:"flex",justifyContent:"space-between",height:"18px",marginTop:"4px"},children:[(typeof S.score=="string"||typeof S.score=="number")&&ut("div",{style:{backgroundColor:"#F2F2FB",borderRadius:"4px",padding:"2px 3px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px"},children:[ee("span",{style:{color:"#4E5969",marginRight:"6px"},children:"\u5206\u6570:"}),ee("span",{style:{color:"#1D2129"},children:y(S.score)})]}),ee("div",{style:{flex:1,display:"flex",justifyContent:"flex-end"},children:(($=S==null?void 0:S.tags)!=null&&$.length&&S.tags.length>0&&S.tags.length<=10?S.tags:[]).map(T=>ee(HT,{i:S,item:E,j:T,clickTag:x},T.id))})]}),ee("div",{style:{flex:1,display:"flex",justifyContent:"flex-start",marginTop:"4px"},children:((M=S==null?void 0:S.tags)!=null&&M.length&&S.tags.length>10?S.tags:[]).map(T=>ee(HT,{i:S,item:E,j:T,clickTag:x},T.id))}),!!((N=S==null?void 0:S.main_source)!=null&&N.length)&&ut("div",{style:{flex:1,display:"flex",alignItems:"flex-start",marginTop:"4px"},children:[ee("div",{style:{fontSize:"12px",color:"#4E5969",width:"60px"},children:"\u5173\u8054\u6587\u6863:"}),ee(Zs,{placement:"topLeft",title:((D=_E(S.main_source[0]))==null?void 0:D.length)>22?_E(S.main_source[0]):"",children:ee("div",{style:{fontSize:"12px",color:"#4E5969",width:"289px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:_E(S.main_source[0])})})]})]},S.id)})},E.key)})})]})]}),ee(xd,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:ut(RF,{autoFocus:!1,onClose:()=>u(!1),open:c,width:h==="graphList"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,afterOpenChange:E=>{E||f(null)},children:[s==="graphPreview"&&ee(Kbe,{curFileInfo:d,onClose:u,token:n}),s==="mark"&&ee(oxe,{content:d,onClose:u,token:n}),s==="preview"&&ee(Oz,{curFileInfo:d,onClose:u,token:n}),s==="database"&&ee(ixe,{curFileInfo:d,onClose:u,token:n})]})})]})},dxe=({fileData:e,token:t})=>{const[n,r]=nt([]);Et(()=>{var l;const a=e==null?void 0:e.knowledgeBases;if(!(a!=null&&a.length))return;const s=((l=a[0])==null?void 0:l.treeData)||[];s!=null&&s.length&&r(s)},[e]);const o=et(new Map),i=async(a,s)=>{var l,c;if(!o.current.get(a==null?void 0:a.fetchUrl))try{const u=n[s];u.loading=!0;const d=[...n];r(d);const f=await vr.get(`${axe()}/${a.fetchUrl}`,{headers:{Authorization:t}}),h=(c=(l=f==null?void 0:f.data)==null?void 0:l.data)==null?void 0:c.records;if(h){const m=n[s];m.loading=!1,m.children=h;const p=[...n];p[s]=m,r(p),o.current.set(a==null?void 0:a.fetchUrl,!0)}else{const m=n[s];m.loading=!1;const p=[...n];r(p)}}catch{const d=n[s];d.loading=!1;const f=[...n];r(f)}};return ut($c,{children:[ee(Gg,{title:"\u77E5\u8BC6\u5E93\u6587\u6863\u76EE\u5F55",setOpen:()=>{const a=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(a)}}),ee("div",{style:{height:"calc(100% - 60px)",overflowY:"auto",padding:"16px"},children:n.map((a,s)=>{var l;return a.type==="file"?ut("div",{className:"flex",style:{marginTop:"8px"},children:[Mz(a),ee(Zs,{placement:"top",title:((l=a.name)==null?void 0:l.length)>23?a.name:"",children:ee("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",cursor:"default",fontSize:"14px"},children:a.name})})]}):ee(fxe,{item:a,index:s,clickFileItem:i},s)})})]})},fxe=({item:e,index:t,clickFileItem:n})=>{var i;const[r,o]=nt(!1);return ut("div",{style:{marginTop:"8px"},children:[ut("div",{className:"flex cursor-pointer",onClick:()=>{o(!r),!r&&n(e,t)},children:[Mz(e),ee(Zs,{placement:"top",title:((i=e.name)==null?void 0:i.length)>23?e.name:"",children:ut("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"14px"},children:[e.name," (",e.fileCount||0,")"]})})]},t),ee("div",{style:{padding:"2px 0 2px 14px",margin:"8px 0 0 7px",borderLeft:"2px solid #E5E6EB",display:r?"block":"none"},children:(e.children||[]).map((a,s)=>{var l;return ut("div",{className:"flex items-center",children:[ee("div",{style:{width:"4px",height:"4px",borderRadius:"2px",background:"black"}}),ee(Zs,{placement:"top",title:((l=a.name)==null?void 0:l.length)>26?a.name:"",children:ee("div",{style:{paddingLeft:"6px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"12px",width:"336px"},children:a.fileName})})]},s)})})]})};var Nz=(e=>(e.REFERENCELIST="referencelist",e.ALLFILELIST="allFileList",e))(Nz||{});function GEe(e=Ure){return function({token:n,url:r="http://localhost:8888",styles:o,CSRFToken:i,eventsEmit:a,scrollOld:s,...l}){const c=Gt(()=>Yz({theme:lC,mode:"light"},o),[o]),[u,d]=nt(!1),[f,h]=nt(!1),[m,p]=nt(null),[g,v]=nt(!1),[y,b]=nt("mark"),[w,x]=nt({url:"",parse_url:"",file_type:"",file_name:""}),[E,k]=nt([]),[S,O]=nt(1),[A]=nt(16),[$,M]=nt(0),[N,D]=nt(!1),[T,P]=nt([]),[I,R]=nt(void 0),[H,V]=nt([]),[L,j]=nt([]),[_,F]=nt(void 0),[B,z]=nt({display:"ready",sender:"ready",app:"initializing"});function G(J,Z){if(!Z)return J;const $e=Array.isArray(J)?[...J]:{...J};for(const Ae in Z)if(Z[Ae]!==void 0&&Z[Ae]!==null&&Object.prototype.hasOwnProperty.call(Z,Ae))if(Ae==="actions"&&Array.isArray(J[Ae])&&Array.isArray(Z[Ae])){const tt=new Map;J[Ae].forEach(vt=>{vt.name&&tt.set(vt.name,vt)}),Z[Ae].forEach(vt=>{vt.name&&tt.set(vt.name,vt)}),$e[Ae]=Array.from(tt.values())}else typeof J[Ae]=="object"&&J[Ae]!==null&&!Array.isArray(J[Ae])&&typeof Z[Ae]=="object"&&Z[Ae]!==null&&!Array.isArray(Z[Ae])?$e[Ae]=G(J[Ae],Z[Ae]):$e[Ae]=Z[Ae];return $e}const[W,q]=nt(()=>G(MA,l.senderConfig));Et(()=>{if(l.senderConfig){const J=G(MA,l.senderConfig);q(J)}},[l.senderConfig]);const{fileStatuses:U,setFileStatuses:Y,pollFileStatus:ie,handleRemoveFromTemp:K,resetStopFlag:re,setStopFlag:oe,stoppedRef:ne,getTempFileList:ae,setFileManagerData:de,fileManagerData:ge}=iie({url:r,token:n,CSRFToken:i,activeSessionId:I}),[Se,ye]=we.useState(()=>{var Z;if(!L||L.length===0)return;const J=L.find($e=>$e.isDefault);return J?J.id:(Z=L[0])==null?void 0:Z.id});we.useEffect(()=>{if(!L||L.length===0)return;const J=L.some(Z=>Z.id===Se);if(!Se||!J){const Z=L.find($e=>$e.isDefault);ye(Z?Z.id:L[0].id)}},[L]);const[be,ce]=nt({}),he=et(void 0),Te=et(void 0),se=et(void 0),Pe=et(null),De=et(void 0),He=et([]),[ue,ve]=nt([]),[xe,fe]=nt({}),[pe,ke]=nt(!1),[Ve,Ee]=nt([]),[yt,Dt]=nt(!1),{api_startChat_re:Ft,addEmptyMessage:Ut,setLastEmptyMessage:Ge,stopStream:Xe,cancelStreamBySessionId:qe}=nie({baseUrl:r,CSRFToken:i,token:n,setChatData:P,activeSessionId:I,setAppStatus:z,setConversationList:k}),lt=Gt(()=>{const J={};return(L||[]).forEach(Z=>{J[Z.id]=Z}),J},[L]),je=Gt(()=>{const J=T.find($e=>$e.id===I)||{id:I,messages:[]},Z=J.configId?lt[J.configId]:null;return{...J,assistantInfo:Z}},[T,I,lt]),Rt=Gt(()=>{if(je.configId&<){const J=lt[je.configId];return J!=null&&J.configJson?JSON.parse(J.configJson).is_download:!1}else return!1},[je.configId,lt]);Gt(()=>{if((je.configId||_)&<){const J=lt[je.configId];if(J!=null&&J.configJson){const Z=JSON.parse(J.configJson);return console.log("is_enableThinking",je.configId,lt,_),!!Z.thinking}else if(_){const Z=lt[_];if(Z!=null&&Z.configJson)return!!JSON.parse(Z.configJson).thinking}}return!1},[je.configId,lt,_]),Et(()=>{if(he.current&&he.current!==I){const Z=he.current,$e=E.find(vt=>vt.sessionId===Z&&vt.isNew),Ae=T.find(vt=>vt.id===Z&&vt.isNew),tt=Ae&&Ae.messages&&Ae.messages.length>0;$e&&!tt&&(k(vt=>vt.filter(Ot=>Ot.sessionId!==Z)),P(vt=>vt.filter(Ot=>Ot.id!==Z)))}he.current=I;const J=je.messages&&je.messages.length>0?je.messages[je.messages.length-1].recommendQuestion:[];V(J)},[I,E,T,je.messages]);const zt=async J=>{var Z,$e,Ae,tt;if(!N){D(!0);try{const vt=await vr.get(`${r}/qa/dialogue/list?pageNo=${J}&pageSize=${A}&sysType=INT_SESSION`,{headers:{Authorization:n}}),Ot=(($e=(Z=vt==null?void 0:vt.data)==null?void 0:Z.data)==null?void 0:$e.records)||[],wt=((tt=(Ae=vt==null?void 0:vt.data)==null?void 0:Ae.data)==null?void 0:tt.total)||0;M(wt),k(ot=>{const Mt=new Map;return[...ot,...Ot].forEach(Zt=>{Mt.set(Zt.sessionId,Zt)}),Array.from(Mt.values())}),O(J)}catch{}finally{D(!1)}}};Et(()=>{z(J=>({...J,app:"initializing"})),vr.get(`${r}/qa/search/config/helper/list?pageNo=1&pageSize=3000`,{headers:{Authorization:n}}).then(J=>{j(J.data.data||[])}).catch(()=>{}),zt(1).then(()=>{I||Pt(),z(J=>({...J,app:"ready"}))}).catch(()=>{z(J=>({...J,app:"error"}))})},[]),Et(()=>{I&&(z(J=>({...J,display:"loading"})),ae(I),vr.get(`${r}/qa/dialogue/getDialogBySessionId?sessionId=${I}`,{headers:{Authorization:n}}).then(J=>{var Cn;if(!J.data.data){z(bt=>({...bt,display:"ready"}));return}const Z=((Cn=J.data.data)==null?void 0:Cn.queryReplyPairList)||[],$e=Boe(Z),{sessionId:Ae,searchConfigDTO:tt,filePath:vt,configId:Ot,reference:wt,webReference:ot,uploadedFiles:Mt,fileList:Zt,currentFiles:Ue}=J.data.data;if($e.length>0){const bt=$e.length-1-[...$e].reverse().findIndex(Wt=>Wt.istype==="ai");bt>=0&&bt<$e.length&&$e[bt].istype==="ai"&&(wt&&($e[bt].reference=wt),ot&&($e[bt].webReference=ot))}const Ye=Ue||Zt||Mt;if(Ye&&$e.length>0){const bt=[...$e].reverse().findIndex(Wt=>Wt.istype==="user");bt!==-1&&(console.log($e[$e.length-1-bt].currentFiles,"filesData"),$e[$e.length-1-bt].currentFiles=Ye)}E.find(bt=>bt.sessionId===Ae)&&k(bt=>bt.map(Wt=>Wt.sessionId===Ae?{...Wt,searchConfigDTO:tt,filePath:vt,configId:Ot}:Wt));const It={configId:J.data.data.configId,filePath:J.data.data.filePath,searchConfigDTO:J.data.data.searchConfigDTO||{},sessionId:J.data.data.sessionId,label:J.data.data.label,kbId:J.data.data.kbId};P(bt=>{const Wt=bt.filter(ft=>ft.id!==I);return[{id:I,messages:$e,...It},...Wt]}),z(bt=>({...bt,display:"ready"}))}).catch(J=>{console.error("\u83B7\u53D6\u804A\u5929\u6570\u636E\u5931\u8D25:",J),J.response&&J.response.status===404&&Pt(),z(Z=>({...Z,display:"error"}))}))},[I,r,n]),Et(()=>{const J=ge.uploadedFiles.length;q(Z=>{const $e=Array.isArray(Z.actions)?Z.actions:[];return{...Z,actions:$e.map(tt=>tt.name==="history"?{...tt,badgeCount:J}:tt)}})},[ge.uploadedFiles]),Et(()=>{Roe({url:r,token:n},J=>{Ee(J)})},[]),we.useEffect(()=>{U.length&&P(J=>{if(!J[0])return J;const{messages:Z}=J[0];for(let $e=Z.length-1;$e>=0;$e--)if(Z[$e].istype==="user"){const Ae=Z[$e].currentFiles||[];Z[$e].currentFiles=U.map(tt=>{var Ot,wt,ot;const vt=Ae.find(Mt=>Mt.uid===tt.uid);return{name:((Ot=tt.file)==null?void 0:Ot.name)||tt.name,size:((wt=tt.file)==null?void 0:wt.size)||tt.size,type:((ot=tt.file)==null?void 0:ot.type)||tt.type,status:tt.status,uid:tt.uid,url:tt.url||(vt==null?void 0:vt.url)||""}});break}return[...J]})},[U]);let dt=null,Ct=null;const jt=(J,Z,$e,Ae)=>{Ct=ie(J,{onStatusUpdate:Z,onComplete:$e,onFail:Ae})},Ie=(J,Z)=>{P($e=>{const Ae=[...$e];return Ae[0]&&(Ae[0]={...Ae[0],messages:Ae[0].messages.map(tt=>tt.queryId===J?{...tt,feedbackResult:Z}:tt)}),Ae})},Ne=async J=>{var Z,$e;if(J)try{const Ae=(je==null?void 0:je.configId)||((Z=lt==null?void 0:lt[(je==null?void 0:je.configId)||""])==null?void 0:Z.id)||"",tt=await vr.get(`${r}/qa/ai/recommendQuestion?queryId=${J}&configId=${Ae||""}`.replace(/\?&/,"?"),{headers:{Authorization:n}});V((($e=tt.data)==null?void 0:$e.data)||[])}catch{V([])}};function Oe(J){const{content:Z,audioUrl:$e,filePaths:Ae,queryId:tt}=J;if(!I||!tt)return;const vt=(je==null?void 0:je.messages)||[],Ot=vt.findIndex(Ye=>(Ye==null?void 0:Ye.queryId)===tt&&((Ye==null?void 0:Ye.istype)==="ai"||(Ye==null?void 0:Ye.isUser)===!1));let wt;if(Ot>0)for(let Ye=Ot-1;Ye>=0;Ye-=1){const ct=vt[Ye];if((ct==null?void 0:ct.istype)==="user"||(ct==null?void 0:ct.isUser)===!0){wt=ct;break}}const ot=(wt==null?void 0:wt.content)??Z;if(!ot)return;const Mt=(wt==null?void 0:wt.filePaths)??Ae,Zt=(typeof Mt=="string"&&Mt?JSON.parse(Mt):Mt||[]).map(Ye=>Ye.uid),Ue=Date.now();Ge({now:Ue}),z(Ye=>({...Ye,display:"processing",sender:"processing"})),Ot>=0&&vt[Ot]&&P(Ye=>{if(!Ye[0])return Ye;const ct=Ye[0],It=ct.messages||[];if(Ot>=It.length)return Ye;const Cn=It.slice();return Cn[Ot]={...Cn[Ot],content:Cn[Ot].content,reference:"[]",webReference:"[]",graphReference:null,databaseReference:null,status:2,chain:void 0},[{...ct,messages:Cn},...Ye.slice(1)]}),J.clearFn&&J.clearFn(),k(Ye=>Ye.map(ct=>ct.sessionId===I?{...ct,gmtModified:Ue}:ct)),Ft({configId:je.configId,content:ot,fileUids:Zt,lastDate:Ue,name:je.label||"",queryId:tt,sessionId:String(I||""),type:(wt==null?void 0:wt.audioUrl)??$e?"audioUrl":"text",audioUrl:((wt==null?void 0:wt.audioUrl)??$e)||"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Ye=>{Ne(tt)})}async function _e(J,Z){if(!I)return;const $e=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent($e);const Ae=E.find(tt=>tt.sessionId===I);if(Ae&&Ae.isNew){let tt=!1;const vt=_||Ae.configId,Ot=J&&J.content?J.content.slice(0,20):Ae.label||"\u672A\u547D\u540D\u4F1A\u8BDD";if(await new Promise((wt,ot)=>{Loe({url:r,token:n,CSRFToken:i},{label:Ot,sessionId:Ae.sessionId,sysType:"INT_SESSION",configId:vt},Mt=>{Mt&&Mt.data&&Mt.data.sessionId?(k(Zt=>Zt.map(Ue=>Ue.sessionId===Ae.sessionId?{...Ue,isNew:!1,configId:vt,label:Ot}:Ue)),P(Zt=>Zt.map(Ue=>Ue.id===Ae.sessionId?{...Ue,isNew:!1,configId:vt,label:Ot}:Ue)),tt=!0,wt()):(mr.error("\u521B\u5EFA\u4F1A\u8BDD\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5"),ot())})}),!tt)return;mt(I,J,Z,vt);return}mt(I,J,Z)}function mt(J,Z,$e,Ae){const tt="query-"+ga(32),vt=E.find(Ye=>Ye.sessionId===J),Ot=Ae||(vt==null?void 0:vt.configId)||je.configId;console.log("\u52A9\u624B\u914D\u7F6E\u8BE6\u60C5",Ot);const wt=Z.content||Z.text||"",ot=typeof wt=="string"?wt:String(wt),Mt=ot?ot.slice(0,20):"\u672A\u547D\u540D\u4F1A\u8BDD";let Zt;if(Z.files&&Z.files.length>0&&(Zt=Z.files.map(Ye=>({name:Ye.file.name,size:Ye.file.size,type:Ye.file.type,filePath:Ye.filePath||"",convertedFilePath:Ye.convertedFilePath||"",uid:Ye.uid||""}))),console.log("\u672C\u5730\u6587\u4EF6\u4E0A\u4F20",Z.files),Ut({content:ot,queryId:tt,currentFiles:Zt,filePaths:Zt?JSON.stringify(Zt):void 0}),k(Ye=>Ye.map(ct=>ct.sessionId===J&&ct.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&ct.isNew?{...ct,label:Mt,gmtModified:Date.now(),isNew:!1}:ct)),P(Ye=>Ye.map(ct=>ct.id===J&&ct.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&ct.isNew?{...ct,label:Mt,isNew:!1}:ct)),Z.files&&Z.files.length>0){z(bt=>({...bt,sender:"uploading",display:"uploading"})),dt=new AbortController,re();const Ye=Z.files.map(()=>`rc-upload-${Date.now()}-${Math.random().toString(36).slice(2)}`),ct=Z.files.map((bt,Wt)=>({...bt,uid:Ye[Wt],status:"uploading"}));Y(ct);const It=new FormData;Z.files.forEach(bt=>{It.append("files",bt.file)});const Cn=String(J||"");It.append("sessionId",Cn),It.append("uids",Ye.join(",")),vr.post(`${r}/index/knowledgeBase/file/uploadFiles`,It,{headers:{Authorization:n,"Content-Type":"multipart/form-data"},signal:dt.signal}).then(bt=>{var Tt,Bn,zn,gr,ia,di,$a,fi,Oa,ws;if(console.log("\u6587\u4EF6\u4E0A\u4F20\u7684\u6253\u5370\u7ED3\u679C",bt),console.log("\u6587\u4EF6\u4E0A\u4F20\u54CD\u5E94\u8BE6\u60C5:",{status:bt.status,success:(Tt=bt.data)==null?void 0:Tt.success,dataType:Array.isArray((Bn=bt.data)==null?void 0:Bn.data)?"array":typeof((zn=bt.data)==null?void 0:zn.data),dataLength:Array.isArray((gr=bt.data)==null?void 0:gr.data)?bt.data.data.length:"N/A",errorMsg:(ia=bt.data)==null?void 0:ia.errorMsg,errorCode:(di=bt.data)==null?void 0:di.errorCode,fullResponse:bt.data}),ne.current)return;const Wt=($a=bt.data)==null?void 0:$a.data,Fn=((fi=bt.data)==null?void 0:fi.success)===!0,ft=Array.isArray(Wt)&&Wt.length>0;if(Fn&&ft){const eo=Wt,Di=eo.map(Qn=>Qn.uid);Y(Qn=>Qn.map(Je=>{const Nt=Wt.find(Vt=>Vt.uid===Je.uid);return Nt?{...Je,...Nt}:Je})),z(Qn=>({...Qn,sender:"processing",display:"analyzing"})),Y(Qn=>Qn.map(Je=>({...Je,status:"parsing"}))),jt(Di,Qn=>{if(!Qn||!Array.isArray(Qn)){console.warn("pollFileStatus \u56DE\u8C03\u8FD4\u56DE\u7684 serverStatuses \u65E0\u6548:",Qn);return}if(Y(Nt=>Nt.map(Vt=>{const Hn=Qn.find(An=>An&&An.uid===Vt.uid);if(Hn)switch(Hn.fileParseStatus??Hn.status){case 3:return{...Vt,status:"done"};case 4:return{...Vt,status:"error"};case 1:case 2:default:return{...Vt,status:"parsing"}}return Vt})),Array.isArray(Qn)&&Qn.length>0&&Qn.every(Nt=>{if(!Nt)return!1;const Vt=Nt.fileParseStatus??Nt.status;return Vt===3||Vt===4})){Y([]);const Nt=new Map;(Qn||[]).forEach(Vt=>{Nt.set(Vt.id,Vt)}),de(Vt=>({uploadedFiles:gie(Vt.uploadedFiles,eo).map(An=>{var Ti;return{...An,pdfPages:((Ti=Nt.get(An.id))==null?void 0:Ti.pdfPages)||0}})}))}},()=>{$e==null||$e(),z(Je=>({...Je,sender:"processing",display:"processing"})),Y(Je=>Je.map(Nt=>{const Vt=eo.find(Hn=>Hn.uid===Nt.uid);return Vt?{...Nt,...Vt,url:Vt.filePath,filePath:Vt.filePath,name:Vt.fileName||Nt.name,convertedFilePath:Vt.convertedFilePath||Nt.convertedFilePath}:Nt})),P(Je=>{if(!Je[0])return Je;const{messages:Nt}=Je[0];for(let Vt=Nt.length-1;Vt>=0;Vt--)if(Nt[Vt].istype==="user"){const Hn=Nt[Vt].currentFiles||[];Nt[Vt].currentFiles=Hn.map(An=>{const Ti=eo.find(Zc=>Zc.uid===An.uid);return Ti?{...An,...Ti}:An});break}return[...Je]});const Qn=Date.now();Ft({configId:Ot,content:ot,fileUids:Di,lastDate:Qn,name:Mt,queryId:tt,sessionId:String(J||""),type:"text",audioUrl:"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Je=>{Ne(tt)})},Qn=>{z(Je=>({...Je,display:"ready",sender:"ready"})),Y(Je=>Je.map(Nt=>({...Nt,status:"error",message:Qn})))})}else{let eo="\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25";(Oa=bt.data)!=null&&Oa.errorMsg?eo=bt.data.errorMsg:Fn?ft||(Array.isArray(Wt)?Wt.length===0&&(eo="\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u4E3A\u7A7A"):eo=`\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u683C\u5F0F\u9519\u8BEF\uFF0C\u671F\u671B\u6570\u7EC4\uFF0C\u5B9E\u9645\u4E3A ${typeof Wt}`):eo=`\u4E0A\u4F20\u5931\u8D25: success=${(ws=bt.data)==null?void 0:ws.success}`,console.error("\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25\u8BE6\u60C5:",{errorMsg:eo,response:bt.data,isSuccess:Fn,isValidData:ft}),mr.error(eo),z(Di=>({...Di,display:"error",sender:"ready"})),Y(Di=>Di.map(Qn=>({...Qn,status:"error",message:eo})))}}).catch(bt=>{var Wt,Fn;((Wt=bt==null?void 0:bt.response)==null?void 0:Wt.status)===413?(Fn=bt==null?void 0:bt.response)!=null&&Fn.statusText.includes("Request Entity Too Large")&&mr.error("\u6587\u4EF6\u8D85\u8FC7\u6700\u5927\u53EF\u4E0A\u4F20\u9650\u5236"):mr.error("\u7F51\u7EDC\u9519\u8BEF"),z(ft=>({...ft,display:"error",sender:"ready"})),Y(ft=>ft.map(Tt=>({...Tt,status:"error",message:"\u7F51\u7EDC\u9519\u8BEF"})))});return}z(Ye=>({...Ye,display:"processing",sender:"processing"}));const Ue=Date.now();k(Ye=>Ye.map(ct=>ct.sessionId===J?{...ct,gmtModified:Ue}:ct)),$e==null||$e(),Ft({configId:Ot,content:ot,fileUids:[],lastDate:Ue,name:Mt,queryId:tt,sessionId:String(J||""),type:"text",audioUrl:"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Ye=>{Ne(tt)})}function kt(J){J.restult==1?Bm({url:r,token:n,CSRFToken:i},{queryId:J.queryId},()=>{Ie(J.queryId,null)}):VA({url:r,token:n,CSRFToken:i},{restult:1,queryId:J.queryId},()=>{Ie(J.queryId,1)})}function Pt(J){const Z=ga(32),$e={sessionId:Z,label:"\u672A\u547D\u540D\u4F1A\u8BDD",gmtModified:Date.now(),searchConfigDTO:{},filePath:"",configId:"",isNew:!0};k(Ae=>[{...$e,messages:[]},...Ae]),P(Ae=>[{id:Z,messages:[],...$e},...Ae]),R(Z)}function Xt(J){if(J!=null&&J.sessionId&&J.sessionId!==I){I&&qe(I),R(J.sessionId),z($e=>({...$e,sender:"ready"}));const Z=T.find($e=>$e.id===J.sessionId);if(Z&&Z.messages&&Z.messages.length>0){const $e=[...Z.messages].reverse().find(Ae=>Ae.istype==="ai");$e&&$e.recommendQuestion?V($e.recommendQuestion):V([])}else V([])}}const on=async J=>new Promise((Z,$e)=>{joe({url:r,token:n,CSRFToken:i},{sessionId:J},Ae=>{Ae?(mr.success("\u5220\u9664\u6210\u529F!"),Z(Ae)):(mr.error("\u5220\u9664\u5931\u8D25!"),$e(Ae))})}),qt=async()=>{try{return k([]),M(0),await zt(1),[]}catch(J){throw mr.error("\u5237\u65B0\u4F1A\u8BDD\u5217\u8868\u5931\u8D25"),J}},wn=async(J,Z)=>new Promise(($e,Ae)=>{_oe({url:r,token:n,CSRFToken:i},{label:Z,sessionId:J},tt=>{if(tt){const vt=Date.now();k(Ot=>Ot.map(wt=>wt.sessionId===J?{...wt,label:Z,gmtModified:vt}:wt)),P(Ot=>Ot.map(wt=>wt.id===J?{...wt,label:Z}:wt)),mr.success("\u91CD\u547D\u540D\u6210\u529F!"),$e(tt)}else mr.error("\u91CD\u547D\u540D\u5931\u8D25"),Ae(tt)})}),vn=J=>{k(Z=>{const $e=Z.filter(Ae=>Ae.sessionId!==J);return I===J&&($e.length>0?R($e[0].sessionId):Pt()),$e})},Kt=(J,Z)=>{const $e=Date.now();k(Ae=>Ae.map(tt=>tt.sessionId===J?{...tt,label:Z,gmtModified:$e}:tt)),P(Ae=>Ae.map(tt=>tt.id===J?{...tt,label:Z}:tt))},$n=J=>{VA({url:r,token:n,CSRFToken:i},{...J,...xe,restult:0},()=>{Ie(xe.queryId,0)})},On=J=>{const Z=J.new_name,$e=m.data.label;Z&&Z!==$e?m.async_renameConversation(Z).then(()=>{m.fn_renameItemInList(Z),d(!1)}).catch(()=>{}):d(!1)},ur=J=>{m.async_deleteConversation().then(()=>{m.fn_removeItemFromList(),h(!1)}).catch(()=>{})},We=(J,Z)=>{switch(console.log(J,Z),J){case"close_remove":h(!1);break;case"close_rename":d(!1);break;case"ok_rename":On(Z);break;case"ok_remove":ur();break}},pt=async({url:J,params:Z,replacePredataFunction:$e})=>{var Ae,tt;try{const vt=await vr.post(J,Z,{headers:{Authorization:n}}),Ot=(tt=(Ae=vt==null?void 0:vt.data)==null?void 0:Ae.data)==null?void 0:tt.data;Ot&&$e(Ot)}catch(vt){console.log("error",vt)}},Ke=async J=>{var Z;try{const $e=await vr.get(`${sC()}/index/knowledgeBase/file/getFileStatusByUids?uids=${J.data.uids}`,{headers:{Authorization:n}});return console.log("resslkdjgalsg",$e),(Z=$e==null?void 0:$e.data)==null?void 0:Z.data}catch{}},rt=async J=>{var Z;if(Az.includes(J.file_type)){const $e=(Z=J.metadata)!=null&&Z.source?`${ip}${J.metadata.source}`:J.url||J.convertedFilePath||J.filePath;x({...J,parse_url:$e}),b("preview"),v(!0);return}try{const $e=await Ke({data:{uids:J.uid},config:{url:sC(),token:n,enableMock:!1}});if($e!=null&&$e.length){const Ae=$e[0];x({...J,parse_url:Ae.convertedFilePath}),b("preview"),v(!0)}}catch{}},ht=et(!1),an=(J,Z)=>{var $e,Ae,tt,vt,Ot,wt,ot;switch(console.log(`[Event] ${J}`,Z),J){case"TempKnowledgeBase":ht.current=Z;break;case"reference_file:click":if(Z.file_type==="image")return;if(!Z.parse_url){if(!Z.uid)return Z.references?void 0:mr.warning("\u6587\u4EF6\u8FD8\u672A\u89E3\u6790\u5B8C\u6210,\u8BF7\u7A0D\u540E\u9884\u89C8");rt(Z);return}x({...Z,file_type:Z.type,file_name:Z.file}),b("preview"),v(!0);break;case"conversations:load_more":{E.length<$&&!N&&zt(S+1);break}case"retrieve-sql-data:pagingation_click":const{page:Mt,pageSize:Zt,fetchUrl:Ue,source:Ye,replacePredataFunction:ct}=Z;pt({url:`${r}${Ue}`,replacePredataFunction:ct,params:{pageNo:Mt,pageSize:Zt,convertedFilePath:Ye,stream:!1}});break;case"web_referenceFile_title:click":if(!(($e=Z==null?void 0:Z.data)!=null&&$e.link))return console.error("\u6CA1\u6709\u7F51\u9875\u5730\u5740");window.open(Z.data.link,"_blank");break;case"conversation:item_click":Xt(Z);break;case"files:finished_animation_complete":Y([]);break;case"conversation:create":Pt();break;case"conversation:new_assistant_change":F(Z.assistantId);break;case"conversations:rename_icon_clicked":p({data:Z,async_renameConversation:It=>wn(Z.sessionId,It),fn_renameItemInList:It=>Kt(Z.sessionId,It)}),d(!0);break;case"conversations:delete_icon_clicked":p({data:Z,async_deleteConversation:()=>on(Z.sessionId),async_refreshConversationList:qt,fn_removeItemFromList:()=>vn(Z.sessionId)}),h(!0);break;case"sender:send":_e(Z,Z.clearFn);break;case"sender:send_recommandQuestion":{const It=((Z==null?void 0:Z.content)??"").toString();if(!It)break;_e({content:It},()=>{});break}case"chatbox:follow_up_question_click":{const It=((Z==null?void 0:Z.question)??(Z==null?void 0:Z.content)??"").toString();if(!It)break;_e({content:It},()=>{});break}case"sender:stop":oe(),dt&&(dt.abort(),dt=null),Ct&&(Ct(),Ct=null),z(It=>({...It,display:"ready",sender:"ready"})),Y([]),Xe==null||Xe();break;case"sender:clear":(Ae=Z.clearFn)==null||Ae.call(Z);break;case"sender:configChange":Z&&Z.all&&ce(Z.all);break;case"sender:action_upload":Pe.current&&Pe.current.click();break;case"sender:action_history":Dt(!0);break;case"uploaded_file:item_click":break;case"action_copy:click":Z&&Ioe(Z.content,Z.event);break;case"chatbox:copy":{const It=(Z==null?void 0:Z.content)||"";if(!It)break;const Cn=async Wt=>{try{return await navigator.clipboard.writeText(Wt),mr.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F"),!0}catch{return!1}},bt=Wt=>{const Fn=document.createElement("textarea");Fn.value=Wt,Fn.style.position="fixed",Fn.style.opacity="0",document.body.appendChild(Fn),Fn.focus(),Fn.select();try{document.execCommand("copy"),mr.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F")}catch{mr.error("\u590D\u5236\u5931\u8D25")}document.body.removeChild(Fn)};Cn(It).then(Wt=>{Wt||bt(It)});break}case"chatbox:repeat":console.log(Z,"sdkflskdjflksdjfklsdjlfkjsdklfjsdklfjlks"),Oe(Z);break;case"action_thumbsup":kt(Z);break;case"chatbox:like":kt({queryId:Z==null?void 0:Z.queryId,restult:Z==null?void 0:Z.result});break;case"action_thumbsdown":Z.restult===0?Bm({url:r,token:n,CSRFToken:i},{queryId:Z.queryId},()=>{Ie(Z.queryId,null)}):(fe(Z),ke(!0));break;case"chatbox:dislike":(Z==null?void 0:Z.result)===0?Bm({url:r,token:n,CSRFToken:i},{queryId:Z.queryId},()=>{Ie(Z.queryId,null)}):(fe({queryId:Z==null?void 0:Z.queryId}),ke(!0));break;case"action_retrive_tag":a==null||a("action_retrive_tag",Z);break;case"referenceFile_view":a==null||a("referenceFile_view",Z);break;case"referenceFile_question":console.log(Z,"zhezhhzhzh"),rt(Z.data||Z),a==null||a("referenceFile_question",Z);break;case"referenceFile_download":a==null||a("referenceFile_download",Z);break;case"references:click":case"knowledge_base_view_all:click":{const It=()=>J==="references:click"?ee(uxe,{type:"referencelist",data:Z,token:n,eventsEmit:a,is_download:Rt}):ee(dxe,{fileData:Z,token:n}),Cn=new CustomEvent("aichat:right_set_content",{detail:{content:ee(It,{})}});window.dispatchEvent(Cn);const bt=new CustomEvent("aichat:right_set",{detail:{collapsed:!1}});window.dispatchEvent(bt);break}case"retrive_tag:click":a==null||a("retrive_tag:click",Z);break;case"fileManager:change":{typeof(Z==null?void 0:Z.setUploadedFiles)=="function"&&(Te.current=Z.setUploadedFiles,se.current=Z.removeFile,De.current=Z==null?void 0:Z.senderConfig,He.current=Array.isArray(Z==null?void 0:Z.uploadedFiles)?Z.uploadedFiles:[],Array.isArray(Z==null?void 0:Z.uploadedFiles)&&ve(Z.uploadedFiles),console.log("[DEBUG] fileManager:change \u4E8B\u4EF6\u89E6\u53D1\uFF0CsetUploadedFilesRef \u5DF2\u8BBE\u7F6E",{hasSetUploadedFiles:!!Te.current,uploadedFilesCount:((tt=Z==null?void 0:Z.uploadedFiles)==null?void 0:tt.length)||0,pendingFilesCount:((vt=Z==null?void 0:Z.uploadedFiles)==null?void 0:vt.length)||0,hasSenderConfig:!!(Z!=null&&Z.senderConfig),senderConfig:Z==null?void 0:Z.senderConfig,upload_number_limit:(Ot=Z==null?void 0:Z.senderConfig)==null?void 0:Ot.upload_number_limit,upload_size_limit:(wt=Z==null?void 0:Z.senderConfig)==null?void 0:wt.upload_size_limit}));break}case"uploaded_file:removeFromTemp":{console.log("[DEBUG] mergedEventsEmit uploaded_file:removeFromTemp \u4E8B\u4EF6",Z);const It=(ot=Z==null?void 0:Z.file)==null?void 0:ot.uid;if(!It){console.warn("[DEBUG] \u7F3A\u5C11uid\uFF0C\u65E0\u6CD5\u5220\u9664\u4E34\u65F6\u6587\u4EF6",Z);break}const Cn=[...(je==null?void 0:je.messages)||[]].reverse().find(Wt=>Wt.istype==="user"),bt=Cn==null?void 0:Cn.queryId;K(It,bt);break}case"uploaded_file:remove_batch":break;default:a==null||a(J,Z)}},dn=[{key:"conversations",type:"custom",label:"\u5BF9\u8BDD\u5386\u53F2",icon:ee(hH,{size:16}),enabled:!0,component:ee(Noe,{data:E,assistantList:L,activedItem:I||"",hasMore:E.length<$,loadingMore:N,sortRules:[{label:"\u5F53\u5929",dayPeriod:1},{label:"3\u5929",dayPeriod:3},{label:"7\u5929",dayPeriod:7},{label:"30\u5929",dayPeriod:30}],eventsEmit:an,styles:c.theme})}],Un=we.useCallback(()=>ee(qoe,{eventsEmit:an,assistantList:L,styles:c,selectedId:Se,onSelectAssistant:ye,productLogo:l==null?void 0:l.productLogo}),[an,L,c,Se,l==null?void 0:l.productLogo]),Nn={...we.useMemo(()=>({AiChatBox:(J,Z)=>{var Zt,Ue,Ye;const $e=Z===(((Zt=je==null?void 0:je.messages)==null?void 0:Zt.length)||0)-1;let Ae="ready";if($e)if(J.status!==void 0)switch(J.status){case 0:Ae="thinking";break;case 1:Ae="processing";break;case 2:Ae="ready";break;case 3:Ae="error";break;case 4:Ae="thinking";break;default:Ae=B.display}else Ae=B.display;let tt=[];if(Array.isArray(H))tt=H;else if(typeof H=="string")try{tt=JSON.parse(H)||[]}catch{tt=[]}const vt=(()=>{const ct=J==null?void 0:J.reference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),Ot=(()=>{const ct=J==null?void 0:J.webReference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),wt=(()=>{const ct=J==null?void 0:J.graphReference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),ot=J==null?void 0:J.databaseReference,Mt=(()=>{var It,Cn,bt;if(J!=null&&J.chainRespTime||(It=J==null?void 0:J.reply)!=null&&It.chainRespTime)return(J==null?void 0:J.chainRespTime)??((Cn=J==null?void 0:J.reply)==null?void 0:Cn.chainRespTime);const ct=(J==null?void 0:J.chain)||((bt=J==null?void 0:J.reply)==null?void 0:bt.chain);if(Array.isArray(ct)&&ct.length>0){const Wt=ct.reduce((Fn,ft)=>{const Tt=(ft==null?void 0:ft.chainRespTime)??(ft==null?void 0:ft.respTime);return Tt!=null&&Tt>0?Fn+Tt:Fn},0);return Wt>0?Wt:void 0}})();return ee(jS,{...J,token:n,streamUrl:"/proxy/index/knowledgeBase/file/stream",referenceMode:"button",reference:vt,webReference:Ot,graphReference:wt,databaseReference:ot,contentType:"stream",displayStatus:Ae,eventsEmit:an,isLast:$e&&(J==null?void 0:J.istype)==="ai",followUpQuestions:$e&&(J==null?void 0:J.istype)==="ai"?tt:[],defaultAnswer:((Ue=je==null?void 0:je.searchConfigDTO)==null?void 0:Ue.defaultAnswer)||"\u4E0D\u77E5\u9053\u4EC0\u4E48\u539F\u56E0\u6211\u4EEC\u6CA1\u80FD\u67E5\u5230\u4F60\u8981\u7684\u95EE\u9898*-*",is_download:Rt,styles:c,enableThoughtChain:!0,chain:J==null?void 0:J.chain,thoughtChainNodes:J==null?void 0:J.thoughtChainNodes,thoughtChainStatus:J==null?void 0:J.status,enableCot:(J==null?void 0:J.enableCot)??((Ye=J==null?void 0:J.reply)==null?void 0:Ye.enableCot),chainRespTime:Mt},`${(J==null?void 0:J.queryId)||(J==null?void 0:J.id)||Z}-${(J==null?void 0:J.istype)||"unknown"}`)},LogoBox:J=>J&&J.LogoBox===null?null:J&&typeof J.LogoBox=="function"?ee(J.LogoBox,{}):ee("div",{className:"text-2xl w-full text-center font-bold",children:"\u5C0F\u9CB8\u667A\u80FD\u52A9\u624B"}),DisplayLoading:()=>ee(fie,{}),DisplayError:()=>ee(pie,{}),AppError:()=>ee(hie,{msg:"\u5E94\u7528\u521D\u59CB\u5316\u5931\u8D25",subMsg:"\u65E0\u6CD5\u5B8C\u6210\u5E94\u7528\u521D\u59CB\u5316\uFF0C\u8FD9\u53EF\u80FD\u662F\u7531\u4E8E\u7F51\u7EDC\u8FDE\u63A5\u95EE\u9898\u6216\u670D\u52A1\u914D\u7F6E\u9519\u8BEF\u5BFC\u81F4\u7684\u3002\u8BF7\u68C0\u67E5\u60A8\u7684\u7F51\u7EDC\u8FDE\u63A5\u5E76\u91CD\u8BD5\u3002"}),AppLoading:()=>{var J,Z;return ee(die,{title:(J=l==null?void 0:l.appLoadingConfig)==null?void 0:J.title,subtitle:((Z=l==null?void 0:l.appLoadingConfig)==null?void 0:Z.subtitle)||""})},UserChatBox:(J,Z)=>ee(jS,{token:n,streamUrl:"/proxy/index/knowledgeBase/file/stream",...J,referenceMode:"button",contentType:"plainText",isUser:!0,displayStatus:"ready",eventsEmit:an,styles:c,fileManagerData:ge,currentFiles:J==null?void 0:J.currentFiles},`${(J==null?void 0:J.queryId)||(J==null?void 0:J.id)||Z}-user`),WelcomeComponent:Un}),[Un,je,B.display,an,c,Rt,ge]),...l.CustomComponents||{}};Et(()=>{q(J=>{const Z=Array.isArray(J.switchs)?J.switchs.map($e=>$e.name==="reasoning"?{...$e,enabled:!0}:$e):[];return{...J,switchs:Z}})},[]);const Dn=Gt(()=>ge.uploadedFiles||[],[ge]),{FileDisplayTools:wr}=aie({fileManagerData:{uploadedFiles:Dn},styles:c,eventsEmit:an});return ut("div",{style:{height:"100%",minWidth:"1116px",overflow:"hidden"},children:[ee("input",{ref:Pe,type:"file",multiple:!0,accept:"image/*,.pdf,.doc,.docx,.ppt,.pptx,.xls,.xlsx,.txt,.md,.json,.csv,.zip,.rar,.7z",style:{display:"none"},onChange:J=>{const Z=J.target.files;if(Z&&Z.length>0){console.log("[DEBUG] handleFileSelect \u89E6\u53D1",{filesCount:Z.length,hasSetUploadedFilesRef:!!Te.current,hasSenderConfig:!!De.current,dynamicSenderConfig:W,dynamicSenderConfigKeys:W?Object.keys(W):[],senderConfigRef:De.current,senderConfigRefKeys:De.current?Object.keys(De.current):[]});const $e=Array.from(Z);let Ae=De.current;(!Ae||Ae.upload_size_limit===void 0&&Ae.upload_number_limit===void 0&&(!Ae.upload_file_type_limit||Ae.upload_file_type_limit.length===0))&&(Ae=W);const tt=He.current||[];console.log("[DEBUG] \u9A8C\u8BC1\u914D\u7F6E\u68C0\u67E5",{configSource:Ae,upload_number_limit:Ae==null?void 0:Ae.upload_number_limit,upload_size_limit:Ae==null?void 0:Ae.upload_size_limit,existingFilesCount:tt.length,newFilesCount:$e.length});const vt=Ae&&(Ae.upload_size_limit!==void 0||Ae.upload_number_limit!==void 0&&Ae.upload_number_limit>0||Ae.upload_file_type_limit&&Ae.upload_file_type_limit.length>0);if(console.log("[DEBUG] \u914D\u7F6E\u68C0\u67E5\u7ED3\u679C",{hasUploadLimitConfig:vt,upload_number_limit:Ae==null?void 0:Ae.upload_number_limit,upload_size_limit:Ae==null?void 0:Ae.upload_size_limit,upload_file_type_limit:Ae==null?void 0:Ae.upload_file_type_limit}),vt){const Ot={upload_size_limit:Ae.upload_size_limit,upload_number_limit:Ae.upload_number_limit,upload_file_type_limit:Ae.upload_file_type_limit,upload_limit_message:Ae.upload_limit_message};console.log("[DEBUG] \u6267\u884C\u6587\u4EF6\u9A8C\u8BC1",{uploadConfig:Ot,existingFilesCount:tt.length,newFilesCount:$e.length,totalCount:tt.length+$e.length});const wt=iw($e,tt,Ot);if(console.log("[DEBUG] \u9A8C\u8BC1\u7ED3\u679C",{valid:wt.valid,errors:wt.errors,rejectedFilesCount:wt.rejectedFiles.length}),!wt.valid){aw(wt);const ot=$e.filter(Mt=>!wt.rejectedFiles.includes(Mt));if(ot.length===0){Pe.current&&(Pe.current.value="");return}$e.splice(0,$e.length,...ot)}}if(Te.current){const Ot=$e.map(wt=>({file:wt,type:wt.type.startsWith("image/")?"image":"document",status:"pending",name:wt.name}));console.log("[DEBUG] \u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",Ot),Te.current(Ot)}else console.warn("[DEBUG] setUploadedFilesRef \u672A\u8BBE\u7F6E\uFF0C\u5EF6\u8FDF\u91CD\u8BD5"),setTimeout(()=>{if(Te.current){const Ot=$e.map(wt=>({file:wt,type:wt.type.startsWith("image/")?"image":"document",status:"pending",name:wt.name}));console.log("[DEBUG] \u5EF6\u8FDF\u540E\u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",Ot),Te.current(Ot)}else console.error("[DEBUG] \u5EF6\u8FDF\u540E setUploadedFilesRef \u4ECD\u672A\u8BBE\u7F6E")},100)}Pe.current&&(Pe.current.value="")}}),ee(e,{...l,status:B,chatData:je,sidebar:dn,recommandQuestions:[],eventsEmit:an,styles:c,senderConfig:W,fileUploadStatus:U,CustomComponents:Nn,activeSessionId:I,scrollOld:s,rightbarWidth:"400px",chatHeader:{title:(je==null?void 0:je.label)||"\u65B0\u5BF9\u8BDD",tools:wr}}),ee(cie,{open:pe,feedBackList:Ve,setOpen:ke,handleConfirm:$n}),ee(mie,{isModalOpen:u,handleOk:We,handleCancel:()=>We("close_rename"),data:(m==null?void 0:m.data)||{}}),ee(vie,{isModalOpen:f,handleOk:We,handleCancel:()=>We("close_remove"),data:(m==null?void 0:m.data)||{}}),ee(xd,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:ee(RF,{autoFocus:!1,onClose:()=>v(!1),open:g,width:y==="graphPreview"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,children:y==="preview"&&ee(Oz,{curFileInfo:w,onClose:v,token:n})})})]})}}var Eh={exports:{}},wh={exports:{}},hxe=wh.exports,VT;function En(){return VT||(VT=1,(function(e,t){(function(n,r){e.exports=r()})(hxe,function(){var n=n||(function(r,o){var i;if(typeof window<"u"&&window.crypto&&(i=window.crypto),typeof self<"u"&&self.crypto&&(i=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(i=globalThis.crypto),!i&&typeof window<"u"&&window.msCrypto&&(i=window.msCrypto),!i&&typeof qg<"u"&&qg.crypto&&(i=qg.crypto),!i&&typeof sH=="function")try{i=lH}catch{}var a=function(){if(i){if(typeof i.getRandomValues=="function")try{return i.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof i.randomBytes=="function")try{return i.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},s=Object.create||(function(){function y(){}return function(b){var w;return y.prototype=b,w=new y,y.prototype=null,w}})(),l={},c=l.lib={},u=c.Base=(function(){return{extend:function(y){var b=s(this);return y&&b.mixIn(y),(!b.hasOwnProperty("init")||this.init===b.init)&&(b.init=function(){b.$super.init.apply(this,arguments)}),b.init.prototype=b,b.$super=this,b},create:function(){var y=this.extend();return y.init.apply(y,arguments),y},init:function(){},mixIn:function(y){for(var b in y)y.hasOwnProperty(b)&&(this[b]=y[b]);y.hasOwnProperty("toString")&&(this.toString=y.toString)},clone:function(){return this.init.prototype.extend(this)}}})(),d=c.WordArray=u.extend({init:function(y,b){y=this.words=y||[],b!=o?this.sigBytes=b:this.sigBytes=y.length*4},toString:function(y){return(y||h).stringify(this)},concat:function(y){var b=this.words,w=y.words,x=this.sigBytes,E=y.sigBytes;if(this.clamp(),x%4)for(var k=0;k<E;k++){var S=w[k>>>2]>>>24-k%4*8&255;b[x+k>>>2]|=S<<24-(x+k)%4*8}else for(var O=0;O<E;O+=4)b[x+O>>>2]=w[O>>>2];return this.sigBytes+=E,this},clamp:function(){var y=this.words,b=this.sigBytes;y[b>>>2]&=4294967295<<32-b%4*8,y.length=r.ceil(b/4)},clone:function(){var y=u.clone.call(this);return y.words=this.words.slice(0),y},random:function(y){for(var b=[],w=0;w<y;w+=4)b.push(a());return new d.init(b,y)}}),f=l.enc={},h=f.Hex={stringify:function(y){for(var b=y.words,w=y.sigBytes,x=[],E=0;E<w;E++){var k=b[E>>>2]>>>24-E%4*8&255;x.push((k>>>4).toString(16)),x.push((k&15).toString(16))}return x.join("")},parse:function(y){for(var b=y.length,w=[],x=0;x<b;x+=2)w[x>>>3]|=parseInt(y.substr(x,2),16)<<24-x%8*4;return new d.init(w,b/2)}},m=f.Latin1={stringify:function(y){for(var b=y.words,w=y.sigBytes,x=[],E=0;E<w;E++){var k=b[E>>>2]>>>24-E%4*8&255;x.push(String.fromCharCode(k))}return x.join("")},parse:function(y){for(var b=y.length,w=[],x=0;x<b;x++)w[x>>>2]|=(y.charCodeAt(x)&255)<<24-x%4*8;return new d.init(w,b)}},p=f.Utf8={stringify:function(y){try{return decodeURIComponent(escape(m.stringify(y)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(y){return m.parse(unescape(encodeURIComponent(y)))}},g=c.BufferedBlockAlgorithm=u.extend({reset:function(){this._data=new d.init,this._nDataBytes=0},_append:function(y){typeof y=="string"&&(y=p.parse(y)),this._data.concat(y),this._nDataBytes+=y.sigBytes},_process:function(y){var b,w=this._data,x=w.words,E=w.sigBytes,k=this.blockSize,S=k*4,O=E/S;y?O=r.ceil(O):O=r.max((O|0)-this._minBufferSize,0);var A=O*k,$=r.min(A*4,E);if(A){for(var M=0;M<A;M+=k)this._doProcessBlock(x,M);b=x.splice(0,A),w.sigBytes-=$}return new d.init(b,$)},clone:function(){var y=u.clone.call(this);return y._data=this._data.clone(),y},_minBufferSize:0});c.Hasher=g.extend({cfg:u.extend(),init:function(y){this.cfg=this.cfg.extend(y),this.reset()},reset:function(){g.reset.call(this),this._doReset()},update:function(y){return this._append(y),this._process(),this},finalize:function(y){y&&this._append(y);var b=this._doFinalize();return b},blockSize:16,_createHelper:function(y){return function(b,w){return new y.init(w).finalize(b)}},_createHmacHelper:function(y){return function(b,w){return new v.HMAC.init(y,w).finalize(b)}}});var v=l.algo={};return l})(Math);return n})})(wh)),wh.exports}var Ch={exports:{}},pxe=Ch.exports,GT;function Ug(){return GT||(GT=1,(function(e,t){(function(n,r){e.exports=r(En())})(pxe,function(n){return(function(r){var o=n,i=o.lib,a=i.Base,s=i.WordArray,l=o.x64={};l.Word=a.extend({init:function(c,u){this.high=c,this.low=u}}),l.WordArray=a.extend({init:function(c,u){c=this.words=c||[],u!=r?this.sigBytes=u:this.sigBytes=c.length*8},toX32:function(){for(var c=this.words,u=c.length,d=[],f=0;f<u;f++){var h=c[f];d.push(h.high),d.push(h.low)}return s.create(d,this.sigBytes)},clone:function(){for(var c=a.clone.call(this),u=c.words=this.words.slice(0),d=u.length,f=0;f<d;f++)u[f]=u[f].clone();return c}})})(),n})})(Ch)),Ch.exports}var kh={exports:{}},gxe=kh.exports,UT;function mxe(){return UT||(UT=1,(function(e,t){(function(n,r){e.exports=r(En())})(gxe,function(n){return(function(){if(typeof ArrayBuffer=="function"){var r=n,o=r.lib,i=o.WordArray,a=i.init,s=i.init=function(l){if(l instanceof ArrayBuffer&&(l=new Uint8Array(l)),(l instanceof Int8Array||typeof Uint8ClampedArray<"u"&&l instanceof Uint8ClampedArray||l instanceof Int16Array||l instanceof Uint16Array||l instanceof Int32Array||l instanceof Uint32Array||l instanceof Float32Array||l instanceof Float64Array)&&(l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength)),l instanceof Uint8Array){for(var c=l.byteLength,u=[],d=0;d<c;d++)u[d>>>2]|=l[d]<<24-d%4*8;a.call(this,u,c)}else a.apply(this,arguments)};s.prototype=i}})(),n.lib.WordArray})})(kh)),kh.exports}var Sh={exports:{}},vxe=Sh.exports,qT;function yxe(){return qT||(qT=1,(function(e,t){(function(n,r){e.exports=r(En())})(vxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Utf16=a.Utf16BE={stringify:function(l){for(var c=l.words,u=l.sigBytes,d=[],f=0;f<u;f+=2){var h=c[f>>>2]>>>16-f%4*8&65535;d.push(String.fromCharCode(h))}return d.join("")},parse:function(l){for(var c=l.length,u=[],d=0;d<c;d++)u[d>>>1]|=l.charCodeAt(d)<<16-d%2*16;return i.create(u,c*2)}},a.Utf16LE={stringify:function(l){for(var c=l.words,u=l.sigBytes,d=[],f=0;f<u;f+=2){var h=s(c[f>>>2]>>>16-f%4*8&65535);d.push(String.fromCharCode(h))}return d.join("")},parse:function(l){for(var c=l.length,u=[],d=0;d<c;d++)u[d>>>1]|=s(l.charCodeAt(d)<<16-d%2*16);return i.create(u,c*2)}};function s(l){return l<<8&4278255360|l>>>8&16711935}})(),n.enc.Utf16})})(Sh)),Sh.exports}var Ah={exports:{}},bxe=Ah.exports,YT;function Al(){return YT||(YT=1,(function(e,t){(function(n,r){e.exports=r(En())})(bxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Base64={stringify:function(l){var c=l.words,u=l.sigBytes,d=this._map;l.clamp();for(var f=[],h=0;h<u;h+=3)for(var m=c[h>>>2]>>>24-h%4*8&255,p=c[h+1>>>2]>>>24-(h+1)%4*8&255,g=c[h+2>>>2]>>>24-(h+2)%4*8&255,v=m<<16|p<<8|g,y=0;y<4&&h+y*.75<u;y++)f.push(d.charAt(v>>>6*(3-y)&63));var b=d.charAt(64);if(b)for(;f.length%4;)f.push(b);return f.join("")},parse:function(l){var c=l.length,u=this._map,d=this._reverseMap;if(!d){d=this._reverseMap=[];for(var f=0;f<u.length;f++)d[u.charCodeAt(f)]=f}var h=u.charAt(64);if(h){var m=l.indexOf(h);m!==-1&&(c=m)}return s(l,c,d)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function s(l,c,u){for(var d=[],f=0,h=0;h<c;h++)if(h%4){var m=u[l.charCodeAt(h-1)]<<h%4*2,p=u[l.charCodeAt(h)]>>>6-h%4*2,g=m|p;d[f>>>2]|=g<<24-f%4*8,f++}return i.create(d,f)}})(),n.enc.Base64})})(Ah)),Ah.exports}var $h={exports:{}},xxe=$h.exports,XT;function Exe(){return XT||(XT=1,(function(e,t){(function(n,r){e.exports=r(En())})(xxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Base64url={stringify:function(l,c){c===void 0&&(c=!0);var u=l.words,d=l.sigBytes,f=c?this._safe_map:this._map;l.clamp();for(var h=[],m=0;m<d;m+=3)for(var p=u[m>>>2]>>>24-m%4*8&255,g=u[m+1>>>2]>>>24-(m+1)%4*8&255,v=u[m+2>>>2]>>>24-(m+2)%4*8&255,y=p<<16|g<<8|v,b=0;b<4&&m+b*.75<d;b++)h.push(f.charAt(y>>>6*(3-b)&63));var w=f.charAt(64);if(w)for(;h.length%4;)h.push(w);return h.join("")},parse:function(l,c){c===void 0&&(c=!0);var u=l.length,d=c?this._safe_map:this._map,f=this._reverseMap;if(!f){f=this._reverseMap=[];for(var h=0;h<d.length;h++)f[d.charCodeAt(h)]=h}var m=d.charAt(64);if(m){var p=l.indexOf(m);p!==-1&&(u=p)}return s(l,u,f)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function s(l,c,u){for(var d=[],f=0,h=0;h<c;h++)if(h%4){var m=u[l.charCodeAt(h-1)]<<h%4*2,p=u[l.charCodeAt(h)]>>>6-h%4*2,g=m|p;d[f>>>2]|=g<<24-f%4*8,f++}return i.create(d,f)}})(),n.enc.Base64url})})($h)),$h.exports}var Oh={exports:{}},wxe=Oh.exports,KT;function $l(){return KT||(KT=1,(function(e,t){(function(n,r){e.exports=r(En())})(wxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.algo,c=[];(function(){for(var p=0;p<64;p++)c[p]=r.abs(r.sin(p+1))*4294967296|0})();var u=l.MD5=s.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(p,g){for(var v=0;v<16;v++){var y=g+v,b=p[y];p[y]=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360}var w=this._hash.words,x=p[g+0],E=p[g+1],k=p[g+2],S=p[g+3],O=p[g+4],A=p[g+5],$=p[g+6],M=p[g+7],N=p[g+8],D=p[g+9],T=p[g+10],P=p[g+11],I=p[g+12],R=p[g+13],H=p[g+14],V=p[g+15],L=w[0],j=w[1],_=w[2],F=w[3];L=d(L,j,_,F,x,7,c[0]),F=d(F,L,j,_,E,12,c[1]),_=d(_,F,L,j,k,17,c[2]),j=d(j,_,F,L,S,22,c[3]),L=d(L,j,_,F,O,7,c[4]),F=d(F,L,j,_,A,12,c[5]),_=d(_,F,L,j,$,17,c[6]),j=d(j,_,F,L,M,22,c[7]),L=d(L,j,_,F,N,7,c[8]),F=d(F,L,j,_,D,12,c[9]),_=d(_,F,L,j,T,17,c[10]),j=d(j,_,F,L,P,22,c[11]),L=d(L,j,_,F,I,7,c[12]),F=d(F,L,j,_,R,12,c[13]),_=d(_,F,L,j,H,17,c[14]),j=d(j,_,F,L,V,22,c[15]),L=f(L,j,_,F,E,5,c[16]),F=f(F,L,j,_,$,9,c[17]),_=f(_,F,L,j,P,14,c[18]),j=f(j,_,F,L,x,20,c[19]),L=f(L,j,_,F,A,5,c[20]),F=f(F,L,j,_,T,9,c[21]),_=f(_,F,L,j,V,14,c[22]),j=f(j,_,F,L,O,20,c[23]),L=f(L,j,_,F,D,5,c[24]),F=f(F,L,j,_,H,9,c[25]),_=f(_,F,L,j,S,14,c[26]),j=f(j,_,F,L,N,20,c[27]),L=f(L,j,_,F,R,5,c[28]),F=f(F,L,j,_,k,9,c[29]),_=f(_,F,L,j,M,14,c[30]),j=f(j,_,F,L,I,20,c[31]),L=h(L,j,_,F,A,4,c[32]),F=h(F,L,j,_,N,11,c[33]),_=h(_,F,L,j,P,16,c[34]),j=h(j,_,F,L,H,23,c[35]),L=h(L,j,_,F,E,4,c[36]),F=h(F,L,j,_,O,11,c[37]),_=h(_,F,L,j,M,16,c[38]),j=h(j,_,F,L,T,23,c[39]),L=h(L,j,_,F,R,4,c[40]),F=h(F,L,j,_,x,11,c[41]),_=h(_,F,L,j,S,16,c[42]),j=h(j,_,F,L,$,23,c[43]),L=h(L,j,_,F,D,4,c[44]),F=h(F,L,j,_,I,11,c[45]),_=h(_,F,L,j,V,16,c[46]),j=h(j,_,F,L,k,23,c[47]),L=m(L,j,_,F,x,6,c[48]),F=m(F,L,j,_,M,10,c[49]),_=m(_,F,L,j,H,15,c[50]),j=m(j,_,F,L,A,21,c[51]),L=m(L,j,_,F,I,6,c[52]),F=m(F,L,j,_,S,10,c[53]),_=m(_,F,L,j,T,15,c[54]),j=m(j,_,F,L,E,21,c[55]),L=m(L,j,_,F,N,6,c[56]),F=m(F,L,j,_,V,10,c[57]),_=m(_,F,L,j,$,15,c[58]),j=m(j,_,F,L,R,21,c[59]),L=m(L,j,_,F,O,6,c[60]),F=m(F,L,j,_,P,10,c[61]),_=m(_,F,L,j,k,15,c[62]),j=m(j,_,F,L,D,21,c[63]),w[0]=w[0]+L|0,w[1]=w[1]+j|0,w[2]=w[2]+_|0,w[3]=w[3]+F|0},_doFinalize:function(){var p=this._data,g=p.words,v=this._nDataBytes*8,y=p.sigBytes*8;g[y>>>5]|=128<<24-y%32;var b=r.floor(v/4294967296),w=v;g[(y+64>>>9<<4)+15]=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360,g[(y+64>>>9<<4)+14]=(w<<8|w>>>24)&16711935|(w<<24|w>>>8)&4278255360,p.sigBytes=(g.length+1)*4,this._process();for(var x=this._hash,E=x.words,k=0;k<4;k++){var S=E[k];E[k]=(S<<8|S>>>24)&16711935|(S<<24|S>>>8)&4278255360}return x},clone:function(){var p=s.clone.call(this);return p._hash=this._hash.clone(),p}});function d(p,g,v,y,b,w,x){var E=p+(g&v|~g&y)+b+x;return(E<<w|E>>>32-w)+g}function f(p,g,v,y,b,w,x){var E=p+(g&y|v&~y)+b+x;return(E<<w|E>>>32-w)+g}function h(p,g,v,y,b,w,x){var E=p+(g^v^y)+b+x;return(E<<w|E>>>32-w)+g}function m(p,g,v,y,b,w,x){var E=p+(v^(g|~y))+b+x;return(E<<w|E>>>32-w)+g}o.MD5=s._createHelper(u),o.HmacMD5=s._createHmacHelper(u)})(Math),n.MD5})})(Oh)),Oh.exports}var Mh={exports:{}},Cxe=Mh.exports,ZT;function Dz(){return ZT||(ZT=1,(function(e,t){(function(n,r){e.exports=r(En())})(Cxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=o.Hasher,s=r.algo,l=[],c=s.SHA1=a.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(u,d){for(var f=this._hash.words,h=f[0],m=f[1],p=f[2],g=f[3],v=f[4],y=0;y<80;y++){if(y<16)l[y]=u[d+y]|0;else{var b=l[y-3]^l[y-8]^l[y-14]^l[y-16];l[y]=b<<1|b>>>31}var w=(h<<5|h>>>27)+v+l[y];y<20?w+=(m&p|~m&g)+1518500249:y<40?w+=(m^p^g)+1859775393:y<60?w+=(m&p|m&g|p&g)-1894007588:w+=(m^p^g)-899497514,v=g,g=p,p=m<<30|m>>>2,m=h,h=w}f[0]=f[0]+h|0,f[1]=f[1]+m|0,f[2]=f[2]+p|0,f[3]=f[3]+g|0,f[4]=f[4]+v|0},_doFinalize:function(){var u=this._data,d=u.words,f=this._nDataBytes*8,h=u.sigBytes*8;return d[h>>>5]|=128<<24-h%32,d[(h+64>>>9<<4)+14]=Math.floor(f/4294967296),d[(h+64>>>9<<4)+15]=f,u.sigBytes=d.length*4,this._process(),this._hash},clone:function(){var u=a.clone.call(this);return u._hash=this._hash.clone(),u}});r.SHA1=a._createHelper(c),r.HmacSHA1=a._createHmacHelper(c)})(),n.SHA1})})(Mh)),Mh.exports}var Nh={exports:{}},kxe=Nh.exports,QT;function FS(){return QT||(QT=1,(function(e,t){(function(n,r){e.exports=r(En())})(kxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.algo,c=[],u=[];(function(){function h(v){for(var y=r.sqrt(v),b=2;b<=y;b++)if(!(v%b))return!1;return!0}function m(v){return(v-(v|0))*4294967296|0}for(var p=2,g=0;g<64;)h(p)&&(g<8&&(c[g]=m(r.pow(p,1/2))),u[g]=m(r.pow(p,1/3)),g++),p++})();var d=[],f=l.SHA256=s.extend({_doReset:function(){this._hash=new a.init(c.slice(0))},_doProcessBlock:function(h,m){for(var p=this._hash.words,g=p[0],v=p[1],y=p[2],b=p[3],w=p[4],x=p[5],E=p[6],k=p[7],S=0;S<64;S++){if(S<16)d[S]=h[m+S]|0;else{var O=d[S-15],A=(O<<25|O>>>7)^(O<<14|O>>>18)^O>>>3,$=d[S-2],M=($<<15|$>>>17)^($<<13|$>>>19)^$>>>10;d[S]=A+d[S-7]+M+d[S-16]}var N=w&x^~w&E,D=g&v^g&y^v&y,T=(g<<30|g>>>2)^(g<<19|g>>>13)^(g<<10|g>>>22),P=(w<<26|w>>>6)^(w<<21|w>>>11)^(w<<7|w>>>25),I=k+P+N+u[S]+d[S],R=T+D;k=E,E=x,x=w,w=b+I|0,b=y,y=v,v=g,g=I+R|0}p[0]=p[0]+g|0,p[1]=p[1]+v|0,p[2]=p[2]+y|0,p[3]=p[3]+b|0,p[4]=p[4]+w|0,p[5]=p[5]+x|0,p[6]=p[6]+E|0,p[7]=p[7]+k|0},_doFinalize:function(){var h=this._data,m=h.words,p=this._nDataBytes*8,g=h.sigBytes*8;return m[g>>>5]|=128<<24-g%32,m[(g+64>>>9<<4)+14]=r.floor(p/4294967296),m[(g+64>>>9<<4)+15]=p,h.sigBytes=m.length*4,this._process(),this._hash},clone:function(){var h=s.clone.call(this);return h._hash=this._hash.clone(),h}});o.SHA256=s._createHelper(f),o.HmacSHA256=s._createHmacHelper(f)})(Math),n.SHA256})})(Nh)),Nh.exports}var Dh={exports:{}},Sxe=Dh.exports,JT;function Axe(){return JT||(JT=1,(function(e,t){(function(n,r,o){e.exports=r(En(),FS())})(Sxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.algo,s=a.SHA256,l=a.SHA224=s.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var c=s._doFinalize.call(this);return c.sigBytes-=4,c}});r.SHA224=s._createHelper(l),r.HmacSHA224=s._createHmacHelper(l)})(),n.SHA224})})(Dh)),Dh.exports}var Th={exports:{}},$xe=Th.exports,eF;function Tz(){return eF||(eF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug())})($xe,function(n){return(function(){var r=n,o=r.lib,i=o.Hasher,a=r.x64,s=a.Word,l=a.WordArray,c=r.algo;function u(){return s.create.apply(s,arguments)}var d=[u(1116352408,3609767458),u(1899447441,602891725),u(3049323471,3964484399),u(3921009573,2173295548),u(961987163,4081628472),u(1508970993,3053834265),u(2453635748,2937671579),u(2870763221,3664609560),u(3624381080,2734883394),u(310598401,1164996542),u(607225278,1323610764),u(1426881987,3590304994),u(1925078388,4068182383),u(2162078206,991336113),u(2614888103,633803317),u(3248222580,3479774868),u(3835390401,2666613458),u(4022224774,944711139),u(264347078,2341262773),u(604807628,2007800933),u(770255983,1495990901),u(1249150122,1856431235),u(1555081692,3175218132),u(1996064986,2198950837),u(2554220882,3999719339),u(2821834349,766784016),u(2952996808,2566594879),u(3210313671,3203337956),u(3336571891,1034457026),u(3584528711,2466948901),u(113926993,3758326383),u(338241895,168717936),u(666307205,1188179964),u(773529912,1546045734),u(1294757372,1522805485),u(1396182291,2643833823),u(1695183700,2343527390),u(1986661051,1014477480),u(2177026350,1206759142),u(2456956037,344077627),u(2730485921,1290863460),u(2820302411,3158454273),u(3259730800,3505952657),u(3345764771,106217008),u(3516065817,3606008344),u(3600352804,1432725776),u(4094571909,1467031594),u(275423344,851169720),u(430227734,3100823752),u(506948616,1363258195),u(659060556,3750685593),u(883997877,3785050280),u(958139571,3318307427),u(1322822218,3812723403),u(1537002063,2003034995),u(1747873779,3602036899),u(1955562222,1575990012),u(2024104815,1125592928),u(2227730452,2716904306),u(2361852424,442776044),u(2428436474,593698344),u(2756734187,3733110249),u(3204031479,2999351573),u(3329325298,3815920427),u(3391569614,3928383900),u(3515267271,566280711),u(3940187606,3454069534),u(4118630271,4000239992),u(116418474,1914138554),u(174292421,2731055270),u(289380356,3203993006),u(460393269,320620315),u(685471733,587496836),u(852142971,1086792851),u(1017036298,365543100),u(1126000580,2618297676),u(1288033470,3409855158),u(1501505948,4234509866),u(1607167915,987167468),u(1816402316,1246189591)],f=[];(function(){for(var m=0;m<80;m++)f[m]=u()})();var h=c.SHA512=i.extend({_doReset:function(){this._hash=new l.init([new s.init(1779033703,4089235720),new s.init(3144134277,2227873595),new s.init(1013904242,4271175723),new s.init(2773480762,1595750129),new s.init(1359893119,2917565137),new s.init(2600822924,725511199),new s.init(528734635,4215389547),new s.init(1541459225,327033209)])},_doProcessBlock:function(m,p){for(var g=this._hash.words,v=g[0],y=g[1],b=g[2],w=g[3],x=g[4],E=g[5],k=g[6],S=g[7],O=v.high,A=v.low,$=y.high,M=y.low,N=b.high,D=b.low,T=w.high,P=w.low,I=x.high,R=x.low,H=E.high,V=E.low,L=k.high,j=k.low,_=S.high,F=S.low,B=O,z=A,G=$,W=M,q=N,U=D,Y=T,ie=P,K=I,re=R,oe=H,ne=V,ae=L,de=j,ge=_,Se=F,ye=0;ye<80;ye++){var be,ce,he=f[ye];if(ye<16)ce=he.high=m[p+ye*2]|0,be=he.low=m[p+ye*2+1]|0;else{var Te=f[ye-15],se=Te.high,Pe=Te.low,De=(se>>>1|Pe<<31)^(se>>>8|Pe<<24)^se>>>7,He=(Pe>>>1|se<<31)^(Pe>>>8|se<<24)^(Pe>>>7|se<<25),ue=f[ye-2],ve=ue.high,xe=ue.low,fe=(ve>>>19|xe<<13)^(ve<<3|xe>>>29)^ve>>>6,pe=(xe>>>19|ve<<13)^(xe<<3|ve>>>29)^(xe>>>6|ve<<26),ke=f[ye-7],Ve=ke.high,Ee=ke.low,yt=f[ye-16],Dt=yt.high,Ft=yt.low;be=He+Ee,ce=De+Ve+(be>>>0<He>>>0?1:0),be=be+pe,ce=ce+fe+(be>>>0<pe>>>0?1:0),be=be+Ft,ce=ce+Dt+(be>>>0<Ft>>>0?1:0),he.high=ce,he.low=be}var Ut=K&oe^~K&ae,Ge=re&ne^~re&de,Xe=B&G^B&q^G&q,qe=z&W^z&U^W&U,lt=(B>>>28|z<<4)^(B<<30|z>>>2)^(B<<25|z>>>7),je=(z>>>28|B<<4)^(z<<30|B>>>2)^(z<<25|B>>>7),Rt=(K>>>14|re<<18)^(K>>>18|re<<14)^(K<<23|re>>>9),zt=(re>>>14|K<<18)^(re>>>18|K<<14)^(re<<23|K>>>9),dt=d[ye],Ct=dt.high,jt=dt.low,Ie=Se+zt,Ne=ge+Rt+(Ie>>>0<Se>>>0?1:0),Ie=Ie+Ge,Ne=Ne+Ut+(Ie>>>0<Ge>>>0?1:0),Ie=Ie+jt,Ne=Ne+Ct+(Ie>>>0<jt>>>0?1:0),Ie=Ie+be,Ne=Ne+ce+(Ie>>>0<be>>>0?1:0),Oe=je+qe,_e=lt+Xe+(Oe>>>0<je>>>0?1:0);ge=ae,Se=de,ae=oe,de=ne,oe=K,ne=re,re=ie+Ie|0,K=Y+Ne+(re>>>0<ie>>>0?1:0)|0,Y=q,ie=U,q=G,U=W,G=B,W=z,z=Ie+Oe|0,B=Ne+_e+(z>>>0<Ie>>>0?1:0)|0}A=v.low=A+z,v.high=O+B+(A>>>0<z>>>0?1:0),M=y.low=M+W,y.high=$+G+(M>>>0<W>>>0?1:0),D=b.low=D+U,b.high=N+q+(D>>>0<U>>>0?1:0),P=w.low=P+ie,w.high=T+Y+(P>>>0<ie>>>0?1:0),R=x.low=R+re,x.high=I+K+(R>>>0<re>>>0?1:0),V=E.low=V+ne,E.high=H+oe+(V>>>0<ne>>>0?1:0),j=k.low=j+de,k.high=L+ae+(j>>>0<de>>>0?1:0),F=S.low=F+Se,S.high=_+ge+(F>>>0<Se>>>0?1:0)},_doFinalize:function(){var m=this._data,p=m.words,g=this._nDataBytes*8,v=m.sigBytes*8;p[v>>>5]|=128<<24-v%32,p[(v+128>>>10<<5)+30]=Math.floor(g/4294967296),p[(v+128>>>10<<5)+31]=g,m.sigBytes=p.length*4,this._process();var y=this._hash.toX32();return y},clone:function(){var m=i.clone.call(this);return m._hash=this._hash.clone(),m},blockSize:1024/32});r.SHA512=i._createHelper(h),r.HmacSHA512=i._createHmacHelper(h)})(),n.SHA512})})(Th)),Th.exports}var Fh={exports:{}},Oxe=Fh.exports,tF;function Mxe(){return tF||(tF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug(),Tz())})(Oxe,function(n){return(function(){var r=n,o=r.x64,i=o.Word,a=o.WordArray,s=r.algo,l=s.SHA512,c=s.SHA384=l.extend({_doReset:function(){this._hash=new a.init([new i.init(3418070365,3238371032),new i.init(1654270250,914150663),new i.init(2438529370,812702999),new i.init(355462360,4144912697),new i.init(1731405415,4290775857),new i.init(2394180231,1750603025),new i.init(3675008525,1694076839),new i.init(1203062813,3204075428)])},_doFinalize:function(){var u=l._doFinalize.call(this);return u.sigBytes-=16,u}});r.SHA384=l._createHelper(c),r.HmacSHA384=l._createHmacHelper(c)})(),n.SHA384})})(Fh)),Fh.exports}var Ph={exports:{}},Nxe=Ph.exports,nF;function Dxe(){return nF||(nF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug())})(Nxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.x64,c=l.Word,u=o.algo,d=[],f=[],h=[];(function(){for(var g=1,v=0,y=0;y<24;y++){d[g+5*v]=(y+1)*(y+2)/2%64;var b=v%5,w=(2*g+3*v)%5;g=b,v=w}for(var g=0;g<5;g++)for(var v=0;v<5;v++)f[g+5*v]=v+(2*g+3*v)%5*5;for(var x=1,E=0;E<24;E++){for(var k=0,S=0,O=0;O<7;O++){if(x&1){var A=(1<<O)-1;A<32?S^=1<<A:k^=1<<A-32}x&128?x=x<<1^113:x<<=1}h[E]=c.create(k,S)}})();var m=[];(function(){for(var g=0;g<25;g++)m[g]=c.create()})();var p=u.SHA3=s.extend({cfg:s.cfg.extend({outputLength:512}),_doReset:function(){for(var g=this._state=[],v=0;v<25;v++)g[v]=new c.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(g,v){for(var y=this._state,b=this.blockSize/2,w=0;w<b;w++){var x=g[v+2*w],E=g[v+2*w+1];x=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,E=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360;var k=y[w];k.high^=E,k.low^=x}for(var S=0;S<24;S++){for(var O=0;O<5;O++){for(var A=0,$=0,M=0;M<5;M++){var k=y[O+5*M];A^=k.high,$^=k.low}var N=m[O];N.high=A,N.low=$}for(var O=0;O<5;O++)for(var D=m[(O+4)%5],T=m[(O+1)%5],P=T.high,I=T.low,A=D.high^(P<<1|I>>>31),$=D.low^(I<<1|P>>>31),M=0;M<5;M++){var k=y[O+5*M];k.high^=A,k.low^=$}for(var R=1;R<25;R++){var A,$,k=y[R],H=k.high,V=k.low,L=d[R];L<32?(A=H<<L|V>>>32-L,$=V<<L|H>>>32-L):(A=V<<L-32|H>>>64-L,$=H<<L-32|V>>>64-L);var j=m[f[R]];j.high=A,j.low=$}var _=m[0],F=y[0];_.high=F.high,_.low=F.low;for(var O=0;O<5;O++)for(var M=0;M<5;M++){var R=O+5*M,k=y[R],B=m[R],z=m[(O+1)%5+5*M],G=m[(O+2)%5+5*M];k.high=B.high^~z.high&G.high,k.low=B.low^~z.low&G.low}var k=y[0],W=h[S];k.high^=W.high,k.low^=W.low}},_doFinalize:function(){var g=this._data,v=g.words;this._nDataBytes*8;var y=g.sigBytes*8,b=this.blockSize*32;v[y>>>5]|=1<<24-y%32,v[(r.ceil((y+1)/b)*b>>>5)-1]|=128,g.sigBytes=v.length*4,this._process();for(var w=this._state,x=this.cfg.outputLength/8,E=x/8,k=[],S=0;S<E;S++){var O=w[S],A=O.high,$=O.low;A=(A<<8|A>>>24)&16711935|(A<<24|A>>>8)&4278255360,$=($<<8|$>>>24)&16711935|($<<24|$>>>8)&4278255360,k.push($),k.push(A)}return new a.init(k,x)},clone:function(){for(var g=s.clone.call(this),v=g._state=this._state.slice(0),y=0;y<25;y++)v[y]=v[y].clone();return g}});o.SHA3=s._createHelper(p),o.HmacSHA3=s._createHmacHelper(p)})(Math),n.SHA3})})(Ph)),Ph.exports}var Ih={exports:{}},Txe=Ih.exports,rF;function Fxe(){return rF||(rF=1,(function(e,t){(function(n,r){e.exports=r(En())})(Txe,function(n){/** @preserve
|
|
793
|
+
`}}:!1,...d}),[t,n,o,i,a,s,l,c,d]);if(!p)return fh.jsx("div",{style:{padding:"20px",textAlign:"center"},children:"\u6570\u636E\u8F6C\u6362\u5931\u8D25"});try{return console.log("\u5F00\u59CB\u6E32\u67D3 NodeGraph..."),fh.jsx(Lbe,{data:p,behaviors:{dragCanvas:{direction:"both"},zoomCanvas:!0,dragElement:!0,optimizeViewportTransform:!0},plugins:v,layout:Gt(()=>{if(!u)return{animate:!1,animation:!1};const b={...u};return b.animate=!1,b.animation=!1,b!=null&&b.options&&typeof b.options=="object"&&(b.options={...b.options,animate:!1,animation:!1}),b},[u]),onReady:(b=>{m.current=b,console.log("KnowledgeGraphPreview ready:",b);const w=g;if(w){const x=()=>{var A,$,M;try{if(typeof b.fitView=="function"&&((A=b.fitView)==null||A.call(b,{padding:40})),typeof b.focusItem=="function")b.focusItem(w,!0);else if(typeof b.focusElement=="function")b.focusElement(w,!0);else if(typeof b.centerElement=="function")b.centerElement(w);else{const D=typeof b.getNode=="function"?b.getNode(w):typeof b.findById=="function"?b.findById(w):null,T=(($=D==null?void 0:D.getModel)==null?void 0:$.call(D))??((M=D==null?void 0:D.getData)==null?void 0:M.call(D)),P=T==null?void 0:T.x,I=T==null?void 0:T.y;P!=null&&I!=null&&(typeof b.panTo=="function"?b.panTo(P,I):typeof b.focusViewport=="function"&&b.focusViewport(P,I))}const N=b.getZoom?b.getZoom():1;typeof b.zoomTo=="function"&&N<.9&&b.zoomTo(.9)}catch(N){console.warn("\u5C45\u4E2D\u8282\u70B9\u5931\u8D25:",N)}};setTimeout(x,80);const E=A=>{try{const $=b;if(typeof $.once=="function")$.once(A,()=>setTimeout(x,30));else if(typeof $.on=="function"){const M=()=>{var N;setTimeout(x,30);try{(N=$.off)==null||N.call($,A,M)}catch{}};$.on(A,M)}}catch{}};E("afterlayout"),E("layoutEnd");let k=0;const S=1,O=setInterval(()=>{k+=1,x(),k>=S&&clearInterval(O)},150)}f&&f(b)}),onDestroy:h})}catch(b){return console.error("=== \u6E32\u67D3\u9519\u8BEF ==="),console.error("\u9519\u8BEF\u7C7B\u578B:",(y=b==null?void 0:b.constructor)==null?void 0:y.name),fh.jsxs("div",{style:{padding:"20px",textAlign:"center",color:"red"},children:["\u56FE\u8868\u6E32\u67D3\u5931\u8D25: ",b instanceof Error?b.message:"\u672A\u77E5\u9519\u8BEF"]})}}const Xbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAACqSURBVHgBzZFNDoQgDIX5uQ3hOMDam8gcxS2nmDkEbL0JDDViiJay9SVNatv3RZ+MvUbOud0Ys87u4MZau7dn0e02zrmnILCDm1pbm8nWxBi/WmteW6+UYiml38D8CSH4B4CCjMwgjr1qzcOXUtZax/HIPAT0kBOAmkFiBMg5F6y/S2LD/ptrQQ5osCjgHtjs70jK3OYURM7MM8gVohBiodIGwe7MZWGv0R+Uy3dwBYPzyQAAAABJRU5ErkJggg==",Gg=({title:e,setOpen:t})=>ut("div",{style:{width:"100%",height:"60px",borderBottom:"1px solid #EBEBEB",padding:"20px",display:"flex",justifyContent:"space-between",alignItems:"center",fontSize:"16px",fontWeight:600},children:[ee("div",{children:e}),ee("img",{src:Xbe,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>t(!1)})]});zbe();const Kbe=({curFileInfo:e,onClose:t,token:n})=>{var s;const r={title:"",subtitle:"",backgroundColor:"#f8f9fa",showGrid:!1,showLegend:!1,showTooltip:!1,showFullscreen:!1,showMinimap:!1},[o,i]=nt({nodeList:[],edgeList:[]});Et(()=>{console.log("curFileInfo",e)},[e]);const a=async l=>{if(!(!(l!=null&&l.id)||!(l!=null&&l.cyphers)||!(l!=null&&l.fetchUrl)))try{const{cyphers:c,fetchUrl:u,id:d}=l||{};console.log("getGraphData params",c,u,d);const f=await vr.post(u,{cyphers:c,ontologyId:d},{headers:{Authorization:n}});console.log("getGraphData res",f),i((f==null?void 0:f.data)||{})}catch(c){console.log("error",c)}};return Et(()=>{a(e)},[e]),ut("div",{children:[ee(Gg,{title:e==null?void 0:e.graphName,setOpen:t}),ee("div",{style:{width:"100%",height:"calc(100vh - 60px)"},children:ee(Ybe,{centerNode:{vid:(s=e==null?void 0:e.traceNode)==null?void 0:s.vid},data:o,layout:{type:"force",linkDistance:190},title:r.title,subtitle:r.subtitle,backgroundColor:r.backgroundColor,showGrid:r.showGrid,showLegend:r.showLegend,showTooltip:r.showTooltip,showFullscreen:r.showFullscreen,showMinimap:r.showMinimap,customPlugins:{},onReady:l=>{console.log("KnowledgeGraphPreview ready:",l)}})})]})},IE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAV9SURBVHgBvVZfb1VFEJ/ZPS2l9cpFQypSEEMhUmKiYjQBoxDjm8ZoQuKjTyZ+AV9MrOAH8MlHE99rRKOvPgCSoAkalbQx1mBLLV4vpX9u2t6es7vjzOyevZdg5Y2b7N09c3Zn5jfzm9kDcJ9/uN2LZy6c/RAMfoCASFlKcoKAREb8H0Us/G89RH2v9OHc9gYvnQusDPnHU1Ajaky9jAbjGsQhijPV+6IjaVYdcTuY7QzyaT4ouyijU5k8q5hEC1JaK2KFo/ti6Kg+GWrnoID/+yUDmM9TDUxDG50Ssf5jL+SEtQGq98E9ECZDd6IGjWVUlgxjTlKMxl1nkvG+FMhWejtQ+HgzVM1Vt0n/dNfwRneZ/u6u4HK1Dl1f8ZZwV75Xqk1YDyX8tDan2iJirJVjzkZKv0jrkE7yQ5ONggsBtkJFnXIDV7bWYbnswLovMUQnE4mSKn7eMzAiijKhqAaCRIk06YAyUA2K+GDexUh88HwwkOO5Cg6dcxAghiYRNBOVCorhTXRSttZ5jZkVZmGkGmWDyWHCwAgDk8o5z4YqKitHlavQM/raWEKpFipTwe3OCiXMiD18cVYKZw71GUw8kpA0B4bhUGOUxPhiZwlLX8JDQw/S0V378NbmKsysLmTdzjr6q3UTEqJM2x71YkhrapkzZ87kN6m+YKPqwvMPH8K3Dp7AHWDB+0BvjD2L7xx+GTrdDUFPnsPsXQUyF6yzQMOzASszD8syC7JGKgySlZnlZmpqKuJlgYzABtfLLZi5vQA7i0E4vfcYPNHYiy8+MgEXFq/B9U6LwAckz1kNknLCAUyK1Sgb0rUFMTTAT1FuUR1IISXNX2osHEv4sf0HHGjsgVfGnoIju/ZBm0P5+exl4GRq1IwxylIpZKNpjQyJvYawl03IsyxNMthrj0IOPtKttuDb+Z9huNgBR3ePwdTv38GtzTVSbYxKB0UFBcRw9oWOYphl3RsSZjMxMVFTVLwUpKBM9R72jjRz8o/tPgDkHBsKrBplsHJDMhfGyICCDIfXinFUGePnZ7QxvyhhNtPT01TnUPKh2LksmoPDcOLRCbg0/wtMt+fgpf1PwrHmfkAuF84hyYye1y6gGLIcxQFjhSg5Z2JEUEUyJdIcP3481yCm6jD88Prhkyo/f+0ifPL9F+rUu0+/BlyUXHwVUOl47blgvTLTMqKovGYsZCNMquiEdJpGo5GLRq8tdn589z4YGRyCK3PXoL22RJtlF7+ZvgyvTpyEN4+8AOdnLiKzhkPMEbYVrP45D3UtZyXx4r7j+hWyFZ1OJ3ca7jBSF/Db0hx89esFuL60KCiQ80mfXvkSPvvha2QkYG0BwTA6g4IY2SPlpehlMKJD25sYDdB3pbLJ4urVq7JYYWkzukHabYQ0xIO9AMmTvhMDhlQkiqUU2uUSaalAuhQ8xXaVvj8wrrG/tQGjfG9oeOh9fvGYZaWDpoAGk6a58wHpMjAyMKTMNZaTzmetEWoYcOTpRmsR0VGqvxxZzLdwbpqxt9e3vh0dHS3Ksiz8iLfh8WE7ePRgS4mkpR0PxOqm3AkZZfIbIzyT+mhKXuh94UB6odpgfHwcWq0WFUXh7aD1uMGcCHyefTR8ynBk5ZnvK25rJCGUZ+46rMHJHGU6BK2TNMg5VlBJCcm7gLJX3Z+dnSU26tvtNrOo8J25m1tCdzEkSrjuJI9g2Sgb4YGqUHpqMqQzK48Gs+HsAGGVnJJwQq/NxW+cMcA9p5/bkBBJ7vRa096AiXlBc8j0SV0R8ydAok6ug97HaYyp1LicksF4wJ06dcrBAnhG8REqKlQE0kmUjYy2Ro0+hlU7T5LXSKFGKmdiiIkcnQXoK9nJyUkjow9tP/I8+vboOcqEvPfvX+6cfN20TwR9AAAAAElFTkSuQmCC",Zbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAATKSURBVHgBvVZLbxxFEK7qmXViW7acYA6WIsHBUiRLnCzuBq5cfedXcEHCPC7cOPET4JYfgbghTAQHC4EvCBwrD7/iXXsz092VevXMrGUnOWWk3pme6a6vvqqvqhfgLV9404ePfzz6KgN+GRCRiAY7kICIf4D4k73jObwWSczkb25c+NFPJ1kMidFMahEVzAEE0D3GGSdeQUKucOMXNzDDTt75XAx3xjswoQHXsns9YPF+cC+sZoz43dYQYMAZSN0zCPkrAa9zoAMfMJ1x4AanBynQzZ9xnr6/jLAyboieTBI+Gmd6zPfnU4IpZzPnWWEI3vOG4KIF+ONZIqDeXsnpdQ7Uft/h9SuyJ2aAhgEmLzKDZTjhcdkSJjAjnKc+tDxfnQ9FpTTwxtLpTqA7KA+1e/W+82flZsw5q1ooE6SUMTGBDIbUKRJVkWCBFGuhxNkE5KDlndqGHtCuTKqyHiiTjsjPto1EF+qxc0ps4WLMcbe5lqYuUUoFvEAOANGtcS4lYXBvuablOcBxG6CN7IBr5HgS4Z+jBsq+NAI6fnomZJDUyjC2AD0hQ6i3t7cByiKlx6DM8P67I3xn8TZcvf5+8gL++mVqomBTKXEoc+7k6BS7UFiJlrBbdGoOc8sYdMFqORq3+OisgYOTBp5NIt27M4effnAHHjw8oYcHF+rYySR78SHdXajwwe/HpSbVCQmSMbNUK/6VkEpqrYuQMW2bCOfjKTbz5t/ltMHTs0ugEHhJRRCC5lzZ5IRB3mcoTJ0vWUYH5VoAxTdTH+9imfKIUKVIyMZkYUg8z5ESb1HXlYbRCaSCA0ukdzsglxiUUtF99cbGhs9dxhKCnLggI4TYMtDIosXvQttgqthk0KOCkdDzXihk9juIK4heMKiRE2DzpN7b2/N0lO5QjGQNVakjrhFWCDOnhCmwUUxiGygilI5dsSfUdRgqpWFtXb1ArDc3NzvG/l33iFJTTGzfQirNIMbEcBFzhRorwopozmtOmOVSclA6nYoGrQ/wmwz10tJSJ1s9a3mTGOd0QW4j5JTtK99T02KsghBHSw6DzxGc/fuYbVfFBuTuaPQm0Zck1efn5yUE0tfsOZMykpb2658H8PNv/xNnFBLWmGJEqiRbQZOXYsA0nYImlN+pbrQIgpVEd0CiiWZ3d1dmpzxWuvNUQ2gNgDucMJWMQQ7MHBKIX9xxdfHT4wvi3mddJthhaHVo3LzQurarpwWz/HxhYfELfvtezT+36gCLtypYnh9BbkZwe8TtTfwNNbTIW6pac9Qmov8Ojhg9qk3u++CNxsgNjsDS09FBKx96IN9fXcXTD787q1iCtfoup0XFgkGMWUIb/OBAOyXUZgAp/uyc0LREs4AZleH6+jrs7+/T2toap47dZGWKMpIcSh4cDiVGCpoR8nBqyeuz5Y7PFehThl78vYAK3cJO3WRQPDw8hLuf/DCpgme0dBUJmwfGXA/OUubhyknhM8K+2/CknPjZw5kFTPlLaVB/pnrdaseQErH/pCIiyZuEOBljz1NXj11PNcQg57oDJimsra0tuSfMzbeRu4uWh3YcNp5abrFROlA3RMrcHHjwnxsfvA7IBxcv2rMcqunrIX/c2dkJMpxtr4YrY7DG5P4m/7z9egkURHiCa3UU2QAAAABJRU5ErkJggg==",jT="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAVZSURBVHgBvVbNbhxFEK7qmdm1ndhZm40D5M9STCL5BFiIq+EJuPiAxIGn4IKE+XkAngIE8gPkCDxAIKDIUsBEjmMR23H8u/aud7urqKrumd1FdsIpu+rtmZ7p+urnq68X4BV/8LwHH373/EsC/MIhIjMP7EAGZvkBlkdxTe7hpUhqhr4+98UPvt8jNaRGic0iGlgCUMDkMQ458YIg9OPOfZIMDEWna+leDVfGKzANA86M7uWApfcDcxnVkJE0x3cY0OEQpO0ZSPkLAc9yoAIfiHTIgXOcHiiBbf5U6vRt20Oj1WXePg74T4t4S+bDDkNHqkk0TAzFO+wynPQAft8JDNy3V9b0LAfyNC/J+w3d4wmgKwDHpyRgBHsy2j3GANGI1KmfWrlvjrqSpTzgTSxncgKTg3qRJ69mUvzCXEIiMrYwMYRAGCQAgohUMRKNkRATqdZcmedIoARarplt6APGD7GxrA9EbMPLddzGygvzOMUUxMJJS/Ie76017RULqQQvIQcA9T4XJy/UUJgkEQmQ9wHuTGWYYQ6/PT3ldo+Mc+/fGMHdE8K/dk4hFMC7zw40GGSzMpjblDeACtEtLi6aMxp5ngFMjWUwmkmzS1oFFD555xJ8/PYE3GpkEHoB3rzoUNfeu1qDIA5JBiQzOgROhwZGEO/VMKn3OlizA255eblKgg/Rt4kRByRpvHEpckoju/1aYQ5cHc/spfsbJ3IvZfYeXQSJqUve2zUhOyUaa+yskgX53Nyc9qLUirEj9BwpnKTVmedzr0vqjr1Qn2D2ch2p5+HqRHTiz81TZqkzkBSAAjqnc9V4qf04BjPQri5yhVH1sic90ekGGB/JQOt3bbKAJ7un8HCzDdcna1DPkW9fqdt9q91DATSCOY4pNIT0tUhjGuM3goDr3ryJxkphqGSI2xJlITW81ihgeryA++stuPf3kXn31lSO1yfrsP78NBqjmD9ITBRDmGhuDaExOa2W9pS2ifJk9e5djg0oGQoB9zoeJi8WMDs9aiAPN1q81+pZPj56t2lrvz464tCV2im55JGjaD2TXuRKYbhsjSjrbMcZag2T7KqDIKkKSh68dWUUNnY6sL1zjMc95pWNI5y5fMFMPXh8IMYVQSjhXdyt9KCy5aBUOtMHjDpglM2np6cpiYwxtedFP0Ugp8ZrAtjWWjJ1Az5YO4S5a+Owsn4E1JWwMqcsRO46OHi8JbuzqvOpOhqTSPRbkvPt7W091AFL2ZXHv/yxBY82TwxQmInSIvzDT+vw48/rxsbcwBxjpu3j0bc72tJixLEJgCmA4xgZQ7/xAfOVlRV9dV9QG5omTZAzt8jyIlQU/ZJQtLlNsShGozmStWd7Xorvo8o4V7ZiWbxS6CvZzefn57nVan1W1Mc+zzO8WRN9G6vnMDFWwOSFYHQfqwVQUXApDUWWgdhWAeGNp/ty4c2m6D5g4oMFN3AElpqOScCzZvNOrTsyU4SiXtBEIx97Y+EJKb0xHRJKgJiuUoftgIg/cWi6KcWEUb95GJDQZGN2dhZWV/dpamrf48UmB96U1HvEakfU9xAiE2xBLyiTNwJaflH7OkC/ZHa0IAwQCFJ0vLq6yjMzM2Ft7QibLueDlg+Npre0WUeVwBj1uGSYCGhSLe1tN3RSlOdV+h/HZW+WJz6tra3p7Hd2dJqXDg4qGEYSVHm2A9WxPBD+METttONRn8scIIocV62AfeDyzNVuNcklOaaCAi4sLAgD7nlH3W8oeDt6ZEZVBQ491DURayhnea4SJUP+3KRBMjgNCF2M115P9a+gahIZS0tLTkfFgrju/jsG3ol0/z//vNPnXykvrFYTHUlOAAAAAElFTkSuQmCC",Qbe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAACE4AAAhOAFFljFgAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAJ2SURBVHgB7ZndcdNAFIXPKobXQAehAuIK4rzxmygV4FQAVICpgFCB7QoiAgOPUSogVIDowAVg35xdSWMlmURSVtfyjPXNeGal2ZXP2d27e1cCOjo2G1NWQQ6O3kHkhMUn0CPBHEfmZ3SJmgSlNURG0BVv2cEWfrvOqkm5AfvwVSEykdfhhzpNenUqm+9R6ZSri4ThDhY4h2QdFeCLvAm3zY/oc5X2VUZAFRNFCVXsMxqT5U2MaOJTlfatG7BkJvoUvgziiibWwoCFJmbmLOpzKk2XN1EaD2tjIIdzf1i4LF391s5AXToDbVNrH6iKvAxDPnnM4gzGjMzZ6RRK6IxAD++RB2CaiqihY0DwLCvFUE5FdAwY/M1KT6GM1gj8yUqH13ZXBXQMLAqiBf+giNYyWjSwDUV0DASFHMZgwKRsACUaNyAvmN8b7KUXWWJmMHb3FWh+IwswQLp0TpiYHctB+JxGdvEI5zxtfXV1TLZHzHFpfkURPGjewBbSHH6OVOwCHyn4FNYUT1s3/53TK6bRfTyQRg3Iq3CItPdjij2kuDHF796qaE9fC3xjac/GCDxozIATn/c+KMq434xCp/zFeMyV6T+DO6Boe/41Lt2wcXIBD7wNuOC0idv1npzYAOZLgPhG9aFrY1elfGR6rOuBlwEnnsEJuB6dUbQNzgsKP76vHed8jDRP8sZvBHpZcCITb+d2kPbyqvAzEFC8UHyeOnPF4cE8wQrx28gE9uWTmzYM4D6nhtea/hC8RoBz3b70PUGLdIf6tukMtE1noG02682cvA0Fa0b5CBiXKrRD8avNHVT4SulOVAlWTZrdVvpO1tGxyVwB1vCn+6Y+ZDoAAAAASUVORK5CYII=",BE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAfnSURBVHgB7VhdbFxHFT5n5t7d63XWJnYc167Jj5u2wklDGlciVCJsKUKRAuoLFvAQflRQUQNURZWQ4KHNC1KQihp4QFRFiEgIlaiVEBWPlYUoVUvskASHiqaNg62k+bE39np/7r0zczgzd3e9dt24uwkv1R5rfOfOvXfm+86cv1mAtrSlLW1pS1va0paWBaF1afyWap33vvfIfZJKnwLyR0FSb+/WXT76pRmNdNLo1L9STz43CbdRsJnn1NB/puHZg4e+0DHSCY8GKA8ZjB8gfoL8MqGAzXcNA6KsT0cCzyiEY6/NnT3+0JFxBbcouN740w39navfHwPYd8fDD3ao1DHW8P0ImkEb93mdwDATEAKW6SdTkPDfQYNfxief+yfcZgK1MWTwcI6vI7kcj41Dju/Hr4KAnSPuyWO9B75FwvxcAGUIE9AWqJuAyGob+rfvABCYzIrucX0BploBKX8of/DLX8FtIuDurdZrwOdnZ+WNTMGrKIOpSIvaiz/aP/rtnjQ8aywMcOp2jXkwQ0uC//PbA8N3g+ErCh6zz1ctaIkblN/xnvjFC3CbCDjN53I58TuY9gZ3fL770OHDn2AzCKIoEqK8kElfmb47/faZHwsyG4isSjWgIat0VrZ2k4TzefAqRRjYvhVQsg8Iw5QQ1tp0AlHUOn3Af+rZv8EtEKhr39r61NiIfG3icsfxV089PLB16zZjDEIcynjm/BZz4a39VJi7V2uTMloxeLZ9wztBtm+ANO8LGci/OQ5DO+4CKTy3AwI/iIB1bjEpgvAz+NjzJWhCROONAz8G2Mems/j6ogw85bONZhgObwD/LxcCfe3KkCot3qGU9kmxtpViwDE3DiixBsMNeEzwX+SIWMew5IzbobW1yOSM2RtHmUehSakRwPrcJwD+UxjHrn6NJgo8o5TdfwKLby6fVYvXh0jIbggCpCAAzZEGDQM2muzVNsOEtIrBbooxycy0bsQm8JT6OrRIgGrT9+UAN5ZHsNhrUFN9WLP5GFq41o1LC73ZA19JdX3xG9D9yDfhY2PfBbFnP1AUIcUMOo74bcMaoWRSShzVESDhgqnBhgUbCCCoB8JjT+2CFgg0TJdzAX971IvpwO5uZMNMFJfLQItzXapczlpTXnz1Fci/8FMo/PXP0Ln700B9g2xGOgHPO4BsUmw0kCS1xPbJsamF2dVQ0MGRUNwHLRBw051zs4zDhqUIl7o0pilARWhjZ2jCElGxkIGokkoSleJKwUD89jnnvNDZxQRY+yoCo0Jw/lEFRjW0VUNFukkGjYNRaIFAPeNm70mum8Aqk9gSFOuVVRrHOqoseXGlLKxTcuyG0E9Dau8+BiQhunSBuYVsaRWI+RqFJdBW24YSwCaJUFj16Q9qHKl6oQnxap0jrMc/8joTEwCprMJilZBSRkuQYbkcqahY1NFS0YX+roe+xEnrIET5G/Dey7+B8MK7YHkmYZWRBBHk52/A1OQkBEKC+6i6F/WiotqhhkSNJvChCfFW3HFtM8o4CtsA3pg12GFfwFiB1qiEKcdKlSrlio0tMPPib6Fy7u8uZLrY70IOh1HWNCjWOvsCKG420yblkQMuquaz7OANRFwrzkATstKJTyQ309MAGZ+XynDoNMjGLkP0PN4Ub96YuGwRCQ6TIorARh6KYqI46XPwZx+osPnFDnyCrOq8BMs70OgW1WYLDc4bJ6EFAitiQn+HR+VFSVEFSbDyeSgKunsKXpC+xEvkdaFA2tp4rFwC44bWaY0No+zEdgyjuK6XhiyzjnBCE6mz0IR4qwcK2UYyZdBCOwIy5UfYvfG/nhdc/PfPfrLFD8sZDhkubFq7J6NcCQH2deu4ouaZrCN28pWxE9cErxHP7H3p5CloQlaUElPVFZYupqiUnyctORmHoSPgbegs+4P3zIqg46yvy9c5axlnPsq2yPmCbXYn7A4YDqm1KjpJWtWq9WZizDFoUsTqgfFxcIlscNgzMvbU+dNTJYhLzro7hu6c97LZKTJiOg6VotDafcjArekkTdtIxGMCjauHkgVMdfa1izlw1PD8n/Ibj0OTUj+8WN08U61E86OjIpWdk68XRPpSYWHD58a+NrCwWPEkxbLTUKq/cGVkKF46iqQ7XdGfOB9IexawDmuM2wGfE10ak/PMGrqqAnerV3w/tW/Xi2+ehhYJ1PpocwGbEg6OAl4aGPArlzv8q6aUwpLvi7QRNrn53A4O93+1B81Ri2v5JEbuGCltY/CWkO2/f6ll8CLh9vgnXzrV0qlMrh6wh0XeBXj3Xr7ObqHunsh0dvXoXl/EPYRx50YR3dfphfMlf3Kgi64FUuz3kYMsI/FY1Z4DzZWlO5Mlu5Ngfz8B5lZk1z285+XTz0OLctMj5eM5wGwB8OrmHU5Rb92oiKEhTrJlXf/uTuzbzch/zwXbcK1ormnWxvXqSbMhklIyLnASQnxizysTTZ/CGkWuRSDH1z6+/mUaIM87Qfl5WCzOU//SEMHmNM2GkjZRiq6VBJyX+nIm9H6d9uVF/nqbBOx3SQmXCdQmtiW2EfQPrrCOzmyS3//sHybegVuUm/0qUS/waj+nWN9wP01UxXbHq1eo9g9m99zvS72TrWrUKP1x9oNYo7wuJU3w2fiN3ScmmkpUrRBYMU7Vm6dh3SNVXY4sf1r/HtZNAq3JhwX1ocGvkv8L6La0pS1taUtbPjLyPy268QDdSiqgAAAAAElFTkSuQmCC",RE="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAVNSURBVHgBvVZLbxxFEK7qmXHWiR1siwNIFnmAhDAIlERw9gFx4J57jty5IIRk5Q8AF/4Cl/wJCyRuFhJInALhsQRC/Iqza292Zrr46tHrjSVzZLS93T3TXY+vvqpuov/54fM+fPTV9A5R9TkWrAoJ6c93sDAJC7GcrhYugiSEytzE5/wAW+8mOvdJWyR5lVyZa+TnlHgTUZEiGGZdJ/Yj//Pe5/lazvJlfa4+kavmhZg34U8Oz+zHc2vdbVg0c42jdy/tH69W/sNDtTuzmsfmhRtv5uogRLvXsUby6XsJu9j2cJmfq1CyzM9ctm0PkY5TGBOj4ljRSYazGxvI+GKRO5D/xbSllfGE5GAkvPuEZPco8/iEaNpDf36eYCp9NCF61hHdf2i6Qrmb5dgXQ3lmQIkhCEIr6lSXidqOZTzpeXQi9GQMoa2bp+jynAs6v7xoH4w4M6/CHTcCPy6cI1OoIq66JbpXuIfSHvzozQDhtg8a+KaiWKSAFFg6n4071jMb3wrxzKCi0B54yEsDptUlKOqFH+6RqLdtJ5yDAFzCED5NO6G9IycTG03tG4cNbEQLoOWsQjW5Sk6otWWmFoFDXHnaRY7RLBRcAtP3LMNd85yfpwwXoRxstjf17du3TZF6gMSko3Gmtmf66XeRHtYbvJJEey4CFKrs1QXQU50iuFywDpQN7TSju+pM9+7dm5miz6TN9NdeT+OTzHDQsyBn/uCGlxmosTjrOMe4qaG0ZrG+0pZinGShJm4qogZ9jb7e2NhIGtweMeuyW5bxN7hgrDDDN9+u6M0rjHgRf/sjEE1aWMx8TsjkKkF1qk4pLMKzSJfyEN8sLQClbjRaaIBeWq3ojSsJZOjk2suJ37nu9eHGqwzPRb7/JXsNgwyEnNQbl5fmCp7XmFksw4A6sDWSwVVAkPjFy4k0z9+/2fDiwlzlx/Pu68R/7DHtPQ32scOoMBHDEK5kPi+NXBJFLojT5JynIAWSXaAgUSkAXa/eE80Xf32Ojom+3u5RgZhWLhF990MLwYkM3yK/GOl5IjPS3Lp1yxfB3sUL+qZQ6HRP1N1ZW75I9OF7iSZwZYoXhSh10jE8wLyxdyCSjgthtC0vL4unhdDJM5GDceZHhz09PMj0z5HQ0+MsJ62wZwOaCU6oPhUdI0cv9om+2cf+EiYPj0MYZJlDR+rhcKigI58yHT/LfDhu6dFhpl8f9zTcy7Q/6vmkjZNAI1RVsLYhkFIwpgnYPZmqBo1f8srpRScALSeHBZPr+/cX1KBDseINxSigLYLYou+0Za+nookPSuLgoJ4zVaAJdNLfRyw1GJZPi8nsQsLlDGX31tJiY4No/2D0yeDi4qfY8AocoEHDtDRIdBmxUrYudlAEIxJIoTLrJpHyQ4vAn487TlkPVgluBLBW4kt6zOxgBmmaneFwYbl+azB4Ya0ZpaVmIV2qF29+9jPY6/nq9ordnwwYVQyNCWyAn5QaZymnucvT7Nzlsl9KHq431/PweNSmapCrBeq7BYSHKiCYgtUeP8kclT9Kda5EEzDqBUc+u54o2XbrsNPDa2+9s7MDQF7L6+uTdnhcy9pot9+Xjtf6ZDGbFYwcSg2p5PPk156gcOTc/NWkpGI5pcLDzc31fnt7G9+Gsm/L1vGhOQQaK3qCGPtIJSc/EoNAqowC3tDjmEfyc7mu2W1PlacHCRZnKFOSoa5Qt7m5idNv2IF2H2Pdb0gCi16FspsyQM7gp1Q6VqZSjeOngrwKErQZgZBiPsb5qnXavvEBytbd4rnRdmtrK2kjv82leJ/Otrk17GyQc2/wZ59/AcalYkfFCITdAAAAAElFTkSuQmCC",NS=e=>e||"",Az=["txt","pdf","jpeg","jpg","png"],Jbe=e=>[""].includes(e),ip=`http://${location.hostname}:9000/`,LT={docx:jT,doc:jT,pdf:Qbe,xls:IE,xlsx:IE,csv:IE,ppt:BE,pptx:BE,pub:BE,txt:Zbe,png:RE,jpg:RE,jpge:RE},exe=e=>LT[e]||LT.txt,sC=()=>"/proxy",DS=e=>{var r;let t=e==null?void 0:e.file_type;const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n)t=n.split(".").slice(-1)[0];else return(e==null?void 0:e.file_source)||"";return Az.includes(t)?n.includes("http")?n:`${ip}${n}`:(e==null?void 0:e.file_source)||""},TS=e=>{var r;if(!e)return"";const{file_name:t}=e;if(t)return t;const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n){const o=n.split("/");return o.length?o[o.length-1]:""}else return""},ap=(e,t)=>{var r;if(!e)return"";const n=(r=e==null?void 0:e.metadata)==null?void 0:r.source;if(n){const o=n.split(".");if(!o.length)return"";const i=o[o.length-1],a=(t||"").split(".");if(!a.length)return"";const s=a[a.length-1];switch(i.toLocaleLowerCase()){case"ppt":case"pub":case"pptx":return"pdf_slides";case"xls":case"xlsx":case"csv":case"md":return s==="pdf"?"pdf":"markdown_table";case"png":case"jpg":case"jpeg":return"image";case"html":case"htm":return"html";case"txt":return"text";default:return s==="ppt"||s==="pub"||s==="pptx"?"pdf_slides":"pdf"}}else return""},txe=async({filePath:e,fileName:t,token:n})=>{if(e&&t)try{const r=await vr.post("/proxy/index/knowledgeBase/file/stream",{convertedFilePath:e},{headers:{"Content-Type":"application/json",Authorization:n},responseType:"arraybuffer"});console.log("response",r);const o=new Blob([r.data]),i=window.URL.createObjectURL(o),a=document.createElement("a"),s=document.body;a.href=i,a.download=t,a.style.display="none",s.appendChild(a);const l=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!0});a.dispatchEvent(l),setTimeout(()=>{s.removeChild(a),window.URL.revokeObjectURL(i)},100)}catch(r){console.error("\u4E0B\u8F7D\u6587\u4EF6\u5931\u8D25\uFF1A",r)}else console.error("\u7F3A\u5C11\u6587\u4EF6\u540D\u6216\u6587\u4EF6\u5730\u5740\uFF1A")},$z=(e,t)=>{var n,r,o,i,a,s;try{if((r=(n=t==null?void 0:t.metadata)==null?void 0:n.page_size)!=null&&r.length){let l=((i=t==null?void 0:t.metadata)==null?void 0:i.page_size)||[[0,0]];Array.isArray(l)||(l=JSON.parse(l));const c=((a=l[0])==null?void 0:a[0])||0;return(((s=l[0])==null?void 0:s[1])||0)>c||!e||!c||c<=e?1:+(e/c).toFixed(4)}else{const l=NS(DS(t)),c=ap(t,l);let u=c;const d=(t==null?void 0:t.file_name)||((o=t==null?void 0:t.metadata)==null?void 0:o.source);if(d){const f=d.split(".");u=f==null?void 0:f[f.length-1]}return zT(c)||zT(u)?.6:1}}catch(l){return console.log("error",l),1}},zT=e=>["ppt","pptx","pub"].includes(e.toLocaleLowerCase()),nxe=e=>{if(!e)return"";const t=e.split("/"),n=t.length,r=t[n-3];if(!r)return"";const o=r.split(".");return o[o.length-1]},rxe=e=>{try{if(!e)return"";const t=e.split("/"),n=t.length;return t[n-3]||""}catch{return""}},oxe=({content:e,onClose:t,token:n})=>{const r=a=>{if(!(a!=null&&a.metadata))return;const s=ap(a,""),{page_number:l,page_size:c,position:u,offset:d,chunk_type:f}=a.metadata;if(s==="markdown_table")return d!=null&&d.length?{annotations:[{id:ga(),offsets:d}],initialPage:1}:{};{if(!c||!u)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size\u6216\u8005\u6587\u4EF6\u5750\u6807","color: red"),{};const h=Array.isArray(c)?c:JSON.parse(c);if(!h.length)return console.log("%c\u7F3A\u5C11\u6587\u4EF6size","color: red"),{};const m=Array.isArray(u)?u:JSON.parse(u);return!m.length||!l?(console.log("%c\u7F3A\u5C11\u6587\u4EF6\u5750\u6807\u6216\u8005\u6587\u4EF6\u9875\u6570","color: red"),{}):{annotations:m.map((g,v)=>({id:ga(),pageNumber:l[v],x:+(g[0][0]/h[0][0]).toFixed(4),y:+(g[0][1]/h[0][1]).toFixed(4),width:+((g[1][0]-g[0][0])/h[0][0]).toFixed(4),height:+((g[2][1]-g[0][1])/h[0][1]).toFixed(4),content:"",color:f==="image"?"#60f74f":"#4FC3F7"})),initialPage:l[0]}}},o=Gt(()=>{var a,s;if(console.log("content88888888888",e),e&&n){console.log("content999",e);const{annotations:l,initialPage:c}=r(e),u={...e,metadata:{source:((a=e==null?void 0:e.metadata)==null?void 0:a.source)||e.parse_url||e.url,page_size:(s=e==null?void 0:e.metadata)==null?void 0:s.page_size}},d=NS(DS(u));return{filePath:d,fileName:TS(u),fileType:ap(u,d),totalPages:u.pdfPages||0,token:n,annotations:l,initialPage:c,initialZoom:$z(598,u)}}else return{}},[e]),i=Gt(()=>o.filePath?(console.log("curData",o),ee(BF,{initialZoom:o.initialZoom||100,convertedFilePath:o.filePath,fileName:o.fileName,fileType:o.fileType,initialPage:o.initialPage,totalPages:o.totalPages,authorization:o.token,annotations:o.annotations,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:a=>{switch(a){case"viewer:close":t();break}},tools:{close:!0}})):ee($c,{}),[o]);return ee("div",{style:{fontFamily:"Source Han Sans CN",fontSize:"12px"},className:"h-full w-full",children:i})},Oz=({curFileInfo:e,onClose:t,token:n})=>{const r=Gt(()=>{var i,a,s;if(e&&n){console.log("content999",e);const l={file_source:e.parse_url||e.parsedFilePath||e.url,file_type:e.file_type,metadata:{source:e.filePath||e.url||((i=e==null?void 0:e.metadata)==null?void 0:i.source)||"",page_size:(a=e==null?void 0:e.metadata)==null?void 0:a.page_size},pdfPages:e.pdfPages},c=NS(DS(l));return{filePath:c,fileName:TS(l),fileType:ap(l,c),totalPages:l.pdfPages||0,token:n,initialZoom:$z(((s=document.getElementById("pdfBox"))==null?void 0:s.clientWidth)||0,l)}}else return{}},[e]),o=Gt(()=>(console.log("curData",r),r.filePath?ee(BF,{initialZoom:r.initialZoom||100,convertedFilePath:r.filePath,fileName:r.fileName,fileType:r.fileType,initialPage:1,totalPages:r.totalPages,authorization:r.token,streamApiUrl:"/proxy/index/knowledgeBase/file/stream",eventsEmit:i=>{switch(i){case"viewer:close":t();break}},tools:{close:!0}}):ee($c,{})),[r]);return ee("div",{id:"pdfBox",className:"h-full overflow-y-auto",children:o})},ixe=({curFileInfo:e,token:t,onClose:n})=>{const[r,o]=nt(1),[i,a]=nt(10),[s,l]=nt([]),[c,u]=nt([]),[d,f]=nt(0);Et(()=>{var v;const g=((v=e==null?void 0:e.metadata)==null?void 0:v.fetchUrl)||(e==null?void 0:e.fetchUrl);g&&m(g)},[e,r,i]);const h=async({url:g,params:v})=>{var y;try{const b=await vr.get(`${sC()}${g}?${new URLSearchParams(v).toString()}`,{headers:{Authorization:t}}),w=(y=b==null?void 0:b.data)==null?void 0:y.data;if(w){const{columns:x,dataList:E,totalData:k}=w;l(((x==null?void 0:x.slice(1))||[]).map(S=>({title:S.businessName,dataIndex:S.physicalName,key:S.physicalName}))),u(E||[]),f(k||[])}}catch(b){console.log("error",b)}},m=async g=>{h({url:`${g}`,params:{pageNo:r,pageSize:i}})},p=Gt(()=>{const{databaseName:g,businessTableName:v,tableName:y}=e;return`${g} - ${y||v}`},[e]);return ut("div",{children:[ee(Gg,{title:p,setOpen:n}),(s==null?void 0:s.length)>0?ut("div",{children:[ee("div",{className:"p-4 overflow-auto h-[calc(100vh-120px)]",children:ee(nH,{columns:s,dataSource:c,pagination:!1,scroll:{x:"max-content"},rowKey:"id"})}),ee("div",{className:"flex justify-end px-[18px]",children:ee(cH,{current:r,pageSize:i,responsive:!0,simple:!0,total:d,showSizeChanger:!0,showQuickJumper:!0,onChange:(g,v)=>{o(g),a(v||10)},onShowSizeChange:(g,v)=>{o(1),a(v)}})})]}):ee(qz,{})]})},HT=({i:e,item:t,j:n,clickTag:r})=>(console.log("j in tag",n),console.log("i in tag",e),console.log("item in tag",t),ee("div",{style:{minWidth:"16px",height:"16px",backgroundColor:lxe[t.key],margin:"0 4px",color:cxe[t.key],display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"2px",fontSize:"12px",cursor:"pointer"},onClick:()=>r&&r(e,n,t),children:n.index},n.id)),axe=()=>"/proxy",_E=e=>{if(!e||typeof e!="string")return"";const t=e.split("/"),n=t.length;return t[n-1]},sxe=e=>{const t=(e||"").toLowerCase();return["png","jpg","jpeg","gif","bmp","webp","svg","ico"].includes(t)?"rag/pic":t==="pdf"?"rag/pdf":["doc","docx"].includes(t)?"rag/word":["xls","xlsx","xlsm","xlsb","xltx","xltm","xlt","xlam"].includes(t)?"rag/excel":["ppt","pptx"].includes(t)?"rag/ppt":t==="txt"||t==="md"?"rag/txt":t==="csv"?"rag/csv":["zip","rar","7z"].includes(t)?"rag/zip":["odt","ods","odp","odf"].includes(t)?"rag/odf":t==="json"?"rag/json":"rag/file"},Mz=e=>{if(e.loading)return ee(uH,{size:"small",style:{marginRight:"5px",width:"12px",fontSize:"12px"}});if(e.type==="dir")return ee(Kr,{type:"rag/folder",size:16});if(e.type==="file"&&e.fileType){const t=sxe(e.fileType);return ee(Kr,{type:t,size:16})}return ee(Kr,{type:"rag/folder",size:16})},lxe={knowledgeList:"#EAF4FD",searchList:"#E8F7F0",databaseList:"#FFF4E5",graphList:"#E7F8FB"},cxe={knowledgeList:"#2072F0",searchList:"#39B83F",databaseList:"#F48C14",graphList:"#10BBD9"},WT=[{key:"knowledgeList",name:"\u77E5\u8BC6\u5E93\u6587\u6863"},{key:"searchList",name:"\u8054\u7F51\u641C\u7D22",hideBtns:!0},{key:"databaseList",name:"\u6570\u636E\u5E93",hideBtns:!0},{key:"graphList",name:"\u77E5\u8BC6\u56FE\u8C31",hideBtns:!0}],uxe=({type:e,data:t,token:n,eventsEmit:r,is_download:o})=>{const[i,a]=nt(WT),[s,l]=nt("mark"),[c,u]=nt(!1),[d,f]=nt({}),[h,m]=nt("knowledgeList"),[p,g]=nt({knowledgeList:[],searchList:[],databaseList:[],graphList:[]}),v=Gt(()=>{const E=4-i.length,k=Array(E).fill(null).map((O,A)=>({name:"",key:100+A})),S=[...i,...k];return console.log("rrrrrr",S),S},[i]),y=E=>isNaN(E)?"":(+E).toFixed(2),b=(E,k)=>{switch(E){case"knowledgeList":return exe(k);case"searchList":return Eie;case"databaseList":return wie;case"graphList":return xie}},w=(E,k)=>E==="graphList"?k.map(S=>({...S,name:S.graphName})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="knowledgeList"?k.map(S=>({...S,file_type:nxe(S.source)||S.file_type,name:rxe(S.source)||S.file_name,score:S.rrf_score})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="searchList"?k.map(S=>({...S,name:S.file_name})).sort((S,O)=>(O.score||0)-(S.score||0)):E==="databaseList"?k.map(S=>{const O=S.tableName?`${S.databaseName||"\u6570\u636E\u5E93"} - ${S.tableName}`:S.databaseName||S.name||"\u6570\u636E\u5E93";return{...S,name:O,file_name:O,file_type:"database"}}).sort((S,O)=>(O.score||0)-(S.score||0)):k,x=(E,k,S)=>{var O;switch(S.key){case"knowledgeList":const{pdfPages:A,parsedFilePath:$,order_num:M,tags:N}=E||{},D=k.id||M||"Unknown ID",T=(N||[]).find(j=>j.id===D);if(E.type==="video")return console.log("sdgasdgag",{file:{...E,...T}}),r==null?void 0:r("retrive_tag:click",{file:{...E,...T}});if(console.log("click knowledge tag",E,k),!E||!T)return;const{metadata:P}=T,I=P.source.split("/"),R=I[I.length-1]||"",H=R.split("."),V=H.slice(0,-1).join(".")||"Unknown Label",L=H[H.length-1]||"Unknown Type";f({id:D,title:V,file_name:R,file_type:L,file_source:Jbe(L)?`${ip}${P.source}`:$,metadata:P,pdfPages:A}),l("mark"),u(!0);break;case"searchList":console.log("click search tag",E,k);break;case"databaseList":console.log("click database tag",E,k),l("database"),f({...E,metadata:E.metadata||{},fetchUrl:E.fetchUrl||((O=E.metadata)==null?void 0:O.fetchUrl)||""}),u(!0);break;case"graphList":console.log("click graph tag",E,k),l("graphPreview"),f({...E,traceNode:((t==null?void 0:t.traceNode)||[]).find(j=>j.id===k.id)}),u(!0);break}};return Et(()=>{if(e!==Nz.REFERENCELIST||(console.log("data in reference drawer",t),!t))return;const{graphRefs:E,knowledgeRefs:k,webRefs:S,databaseRefs:O}=t;E!=null&&E.length&&(p.graphList=w("graphList",E)),k!=null&&k.length&&(p.knowledgeList=w("knowledgeList",k)),S!=null&&S.length&&(p.searchList=w("searchList",S)),O!=null&&O.length&&(p.databaseList=w("databaseList",O));const A=WT.filter($=>{var M;return(M=p[$.key])==null?void 0:M.length}).sort(($,M)=>{var N,D;return(((N=p[M.key])==null?void 0:N.length)||0)-(((D=p[$.key])==null?void 0:D.length)||0)});a(A),A!=null&&A.length&&m(A[0].key),g({...p})},[t]),ut($c,{children:[ut("div",{className:"listWrap w-full h-full",children:[ee(Gg,{title:"\u77E5\u8BC6\u6EAF\u6E90",setOpen:()=>{const E=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(E)}}),ut("div",{style:{height:"calc(100% - 60px)"},children:[ee("div",{className:"tabs",style:{display:"flex",justifyContent:"space-between",padding:"12px 20px"},children:v.map(E=>ee("div",{className:"tab-item",style:{padding:"5.5px 12px",backgroundColor:E.name?h===E.key?"#4E6EF2":"#F5F6F9":"transparent",cursor:"pointer",borderRadius:"4px",color:h===E.key?"#FFFFFF":"#4E5969",fontSize:"14px",minWidth:"80px",display:"flex",justifyContent:"center"},onClick:()=>{E.name&&m(E.key)},children:E.name},E.key))}),ee("div",{className:"listBox",style:{height:"calc(100% - 66px)",overflowY:"auto",display:"flex",flexDirection:"column",alignItems:"center",willChange:"scroll-position",transform:"translateZ(0)"},children:i.map(E=>{let k=p[E.key]||[];return h!==E.key?null:ee("div",{children:k.map(S=>{var O,A,$,M,N,D;return ut("div",{style:{width:"360px",padding:"4px 8px",borderRadius:"4px",margin:"6px 0",cursor:"pointer"},className:"listItemBox",onClick:()=>{E.key==="searchList"&&window.open(S.link,"_blank")},children:[ut("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ut("div",{style:{width:E.hideBtns?"339px":"288px",fontSize:"14px",color:"#1D2129",fontWeight:"700",display:"flex",alignItems:"center"},children:[ee("img",{src:b(E.key,S.file_type),style:{width:"16px",height:"16px",marginRight:"2px"}}),ee(Zs,{placement:"topLeft",title:((O=S==null?void 0:S.name)==null?void 0:O.length)>17?S.name:"",children:ee("div",{style:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",width:E.hideBtns?"322px":"258px"},onClick:()=>{var T;E.key==="knowledgeList"?r==null||r("knowledge_referenceFile_title:click",{data:{...S,file_type:S.file_type,file_name:S.file_name,metadata:S.metadata,parsedFilePath:S.parsedFilePath}}):E.key==="databaseList"&&(l("database"),f({...S,metadata:S.metadata||{},fetchUrl:S.fetchUrl||((T=S.metadata)==null?void 0:T.fetchUrl)||""}),u(!0))},children:S.name})})]}),ut("div",{style:{width:"52px",justifyContent:"space-between",alignItems:"center",marginRight:"8px",display:E.hideBtns||S.type==="video"?"none":"flex"},children:[ee("img",{src:yie,style:{width:"16px",height:"16px",cursor:"pointer"},onClick:()=>{r==null||r("referenceFile_filechat",{data:{...S,file_type:S.file_type,file_name:S.file_name,metadata:S.metadata,parsedFilePath:S.parsedFilePath}})}}),ee("div",{style:{borderRight:"1px solid #E5E6EB",height:"14px"}}),ee("img",{src:bie,style:{width:"16px",height:"16px",cursor:o?"pointer":"not-allowed"},onClick:()=>{var P,I,R;if(!((P=S==null?void 0:S.tags)!=null&&P.length)&&!((I=S==null?void 0:S.metadata)!=null&&I.source)||!o)return;const T=((R=((S==null?void 0:S.tags)||[])[0])==null?void 0:R.metadata)||(S==null?void 0:S.metadata);txe({filePath:`${ip}${T.source}`,fileName:TS({metadata:T}),token:n})}})]})]}),!!(typeof S.score=="string"||typeof S.score=="number"||(A=S==null?void 0:S.tags)!=null&&A.length&&S.tags.length>0&&S.tags.length<=10)&&ut("div",{style:{display:"flex",justifyContent:"space-between",height:"18px",marginTop:"4px"},children:[(typeof S.score=="string"||typeof S.score=="number")&&ut("div",{style:{backgroundColor:"#F2F2FB",borderRadius:"4px",padding:"2px 3px",display:"flex",justifyContent:"center",alignItems:"center",fontSize:"12px"},children:[ee("span",{style:{color:"#4E5969",marginRight:"6px"},children:"\u5206\u6570:"}),ee("span",{style:{color:"#1D2129"},children:y(S.score)})]}),ee("div",{style:{flex:1,display:"flex",justifyContent:"flex-end"},children:(($=S==null?void 0:S.tags)!=null&&$.length&&S.tags.length>0&&S.tags.length<=10?S.tags:[]).map(T=>ee(HT,{i:S,item:E,j:T,clickTag:x},T.id))})]}),ee("div",{style:{flex:1,display:"flex",justifyContent:"flex-start",marginTop:"4px"},children:((M=S==null?void 0:S.tags)!=null&&M.length&&S.tags.length>10?S.tags:[]).map(T=>ee(HT,{i:S,item:E,j:T,clickTag:x},T.id))}),!!((N=S==null?void 0:S.main_source)!=null&&N.length)&&ut("div",{style:{flex:1,display:"flex",alignItems:"flex-start",marginTop:"4px"},children:[ee("div",{style:{fontSize:"12px",color:"#4E5969",width:"60px"},children:"\u5173\u8054\u6587\u6863:"}),ee(Zs,{placement:"topLeft",title:((D=_E(S.main_source[0]))==null?void 0:D.length)>22?_E(S.main_source[0]):"",children:ee("div",{style:{fontSize:"12px",color:"#4E5969",width:"289px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:_E(S.main_source[0])})})]})]},S.id)})},E.key)})})]})]}),ee(xd,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:ut(RF,{autoFocus:!1,onClose:()=>u(!1),open:c,width:h==="graphList"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,afterOpenChange:E=>{E||f(null)},children:[s==="graphPreview"&&ee(Kbe,{curFileInfo:d,onClose:u,token:n}),s==="mark"&&ee(oxe,{content:d,onClose:u,token:n}),s==="preview"&&ee(Oz,{curFileInfo:d,onClose:u,token:n}),s==="database"&&ee(ixe,{curFileInfo:d,onClose:u,token:n})]})})]})},dxe=({fileData:e,token:t})=>{const[n,r]=nt([]);Et(()=>{var l;const a=e==null?void 0:e.knowledgeBases;if(!(a!=null&&a.length))return;const s=((l=a[0])==null?void 0:l.treeData)||[];s!=null&&s.length&&r(s)},[e]);const o=et(new Map),i=async(a,s)=>{var l,c;if(!o.current.get(a==null?void 0:a.fetchUrl))try{const u=n[s];u.loading=!0;const d=[...n];r(d);const f=await vr.get(`${axe()}/${a.fetchUrl}`,{headers:{Authorization:t}}),h=(c=(l=f==null?void 0:f.data)==null?void 0:l.data)==null?void 0:c.records;if(h){const m=n[s];m.loading=!1,m.children=h;const p=[...n];p[s]=m,r(p),o.current.set(a==null?void 0:a.fetchUrl,!0)}else{const m=n[s];m.loading=!1;const p=[...n];r(p)}}catch{const d=n[s];d.loading=!1;const f=[...n];r(f)}};return ut($c,{children:[ee(Gg,{title:"\u77E5\u8BC6\u5E93\u6587\u6863\u76EE\u5F55",setOpen:()=>{const a=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent(a)}}),ee("div",{style:{height:"calc(100% - 60px)",overflowY:"auto",padding:"16px"},children:n.map((a,s)=>{var l;return a.type==="file"?ut("div",{className:"flex",style:{marginTop:"8px"},children:[Mz(a),ee(Zs,{placement:"top",title:((l=a.name)==null?void 0:l.length)>23?a.name:"",children:ee("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",cursor:"default",fontSize:"14px"},children:a.name})})]}):ee(fxe,{item:a,index:s,clickFileItem:i},s)})})]})},fxe=({item:e,index:t,clickFileItem:n})=>{var i;const[r,o]=nt(!1);return ut("div",{style:{marginTop:"8px"},children:[ut("div",{className:"flex cursor-pointer",onClick:()=>{o(!r),!r&&n(e,t)},children:[Mz(e),ee(Zs,{placement:"top",title:((i=e.name)==null?void 0:i.length)>23?e.name:"",children:ut("div",{style:{paddingLeft:"6px",width:"346px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"14px"},children:[e.name," (",e.fileCount||0,")"]})})]},t),ee("div",{style:{padding:"2px 0 2px 14px",margin:"8px 0 0 7px",borderLeft:"2px solid #E5E6EB",display:r?"block":"none"},children:(e.children||[]).map((a,s)=>{var l;return ut("div",{className:"flex items-center",children:[ee("div",{style:{width:"4px",height:"4px",borderRadius:"2px",background:"black"}}),ee(Zs,{placement:"top",title:((l=a.name)==null?void 0:l.length)>26?a.name:"",children:ee("div",{style:{paddingLeft:"6px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"12px",width:"336px"},children:a.fileName})})]},s)})})]})};var Nz=(e=>(e.REFERENCELIST="referencelist",e.ALLFILELIST="allFileList",e))(Nz||{});function GEe(e=Ure){return function({token:n,url:r="http://localhost:8888",styles:o,CSRFToken:i,eventsEmit:a,scrollOld:s,...l}){const c=Gt(()=>Yz({theme:lC,mode:"light"},o),[o]),[u,d]=nt(!1),[f,h]=nt(!1),[m,p]=nt(null),[g,v]=nt(!1),[y,b]=nt("mark"),[w,x]=nt({url:"",parse_url:"",file_type:"",file_name:""}),[E,k]=nt([]),[S,O]=nt(1),[A]=nt(16),[$,M]=nt(0),[N,D]=nt(!1),[T,P]=nt([]),[I,R]=nt(void 0),[H,V]=nt([]),[L,j]=nt([]),[_,F]=nt(void 0),[B,z]=nt({display:"ready",sender:"ready",app:"initializing"});function G(J,Z){if(!Z)return J;const $e=Array.isArray(J)?[...J]:{...J};for(const Ae in Z)if(Z[Ae]!==void 0&&Z[Ae]!==null&&Object.prototype.hasOwnProperty.call(Z,Ae))if(Ae==="actions"&&Array.isArray(J[Ae])&&Array.isArray(Z[Ae])){const tt=new Map;J[Ae].forEach(vt=>{vt.name&&tt.set(vt.name,vt)}),Z[Ae].forEach(vt=>{vt.name&&tt.set(vt.name,vt)}),$e[Ae]=Array.from(tt.values())}else typeof J[Ae]=="object"&&J[Ae]!==null&&!Array.isArray(J[Ae])&&typeof Z[Ae]=="object"&&Z[Ae]!==null&&!Array.isArray(Z[Ae])?$e[Ae]=G(J[Ae],Z[Ae]):$e[Ae]=Z[Ae];return $e}const[W,q]=nt(()=>G(MA,l.senderConfig));Et(()=>{if(l.senderConfig){const J=G(MA,l.senderConfig);q(J)}},[l.senderConfig]);const{fileStatuses:U,setFileStatuses:Y,pollFileStatus:ie,handleRemoveFromTemp:K,resetStopFlag:re,setStopFlag:oe,stoppedRef:ne,getTempFileList:ae,setFileManagerData:de,fileManagerData:ge}=iie({url:r,token:n,CSRFToken:i,activeSessionId:I}),[Se,ye]=we.useState(()=>{var Z;if(!L||L.length===0)return;const J=L.find($e=>$e.isDefault);return J?J.id:(Z=L[0])==null?void 0:Z.id});we.useEffect(()=>{if(!L||L.length===0)return;const J=L.some(Z=>Z.id===Se);if(!Se||!J){const Z=L.find($e=>$e.isDefault);ye(Z?Z.id:L[0].id)}},[L]);const[be,ce]=nt({}),he=et(void 0),Te=et(void 0),se=et(void 0),Pe=et(null),De=et(void 0),He=et([]),[ue,ve]=nt([]),[xe,fe]=nt({}),[pe,ke]=nt(!1),[Ve,Ee]=nt([]),[yt,Dt]=nt(!1),{api_startChat_re:Pt,addEmptyMessage:Ut,setLastEmptyMessage:Ge,stopStream:Xe,cancelStreamBySessionId:qe}=nie({baseUrl:r,CSRFToken:i,token:n,setChatData:P,activeSessionId:I,setAppStatus:z,setConversationList:k}),lt=Gt(()=>{const J={};return(L||[]).forEach(Z=>{J[Z.id]=Z}),J},[L]),je=Gt(()=>{const J=T.find($e=>$e.id===I)||{id:I,messages:[]},Z=J.configId?lt[J.configId]:null;return{...J,assistantInfo:Z}},[T,I,lt]),Rt=Gt(()=>{if(je.configId&<){const J=lt[je.configId];return J!=null&&J.configJson?JSON.parse(J.configJson).is_download:!1}else return!1},[je.configId,lt]);Gt(()=>{if((je.configId||_)&<){const J=lt[je.configId];if(J!=null&&J.configJson){const Z=JSON.parse(J.configJson);return console.log("is_enableThinking",je.configId,lt,_),!!Z.thinking}else if(_){const Z=lt[_];if(Z!=null&&Z.configJson)return!!JSON.parse(Z.configJson).thinking}}return!1},[je.configId,lt,_]),Et(()=>{if(he.current&&he.current!==I){const Z=he.current,$e=E.find(vt=>vt.sessionId===Z&&vt.isNew),Ae=T.find(vt=>vt.id===Z&&vt.isNew),tt=Ae&&Ae.messages&&Ae.messages.length>0;$e&&!tt&&(k(vt=>vt.filter(Ot=>Ot.sessionId!==Z)),P(vt=>vt.filter(Ot=>Ot.id!==Z)))}he.current=I;const J=je.messages&&je.messages.length>0?je.messages[je.messages.length-1].recommendQuestion:[];V(J)},[I,E,T,je.messages]);const zt=async J=>{var Z,$e,Ae,tt;if(!N){D(!0);try{const vt=await vr.get(`${r}/qa/dialogue/list?pageNo=${J}&pageSize=${A}&sysType=INT_SESSION`,{headers:{Authorization:n}}),Ot=(($e=(Z=vt==null?void 0:vt.data)==null?void 0:Z.data)==null?void 0:$e.records)||[],wt=((tt=(Ae=vt==null?void 0:vt.data)==null?void 0:Ae.data)==null?void 0:tt.total)||0;M(wt),k(ot=>{const Mt=new Map;return[...ot,...Ot].forEach(Zt=>{Mt.set(Zt.sessionId,Zt)}),Array.from(Mt.values())}),O(J)}catch{}finally{D(!1)}}};Et(()=>{z(J=>({...J,app:"initializing"})),vr.get(`${r}/qa/search/config/helper/list?pageNo=1&pageSize=3000`,{headers:{Authorization:n}}).then(J=>{j(J.data.data||[])}).catch(()=>{}),zt(1).then(()=>{I||It(),z(J=>({...J,app:"ready"}))}).catch(()=>{z(J=>({...J,app:"error"}))})},[]),Et(()=>{I&&(z(J=>({...J,display:"loading"})),ae(I),vr.get(`${r}/qa/dialogue/getDialogBySessionId?sessionId=${I}`,{headers:{Authorization:n}}).then(J=>{var Cn;if(!J.data.data){z(bt=>({...bt,display:"ready"}));return}const Z=((Cn=J.data.data)==null?void 0:Cn.queryReplyPairList)||[],$e=Boe(Z),{sessionId:Ae,searchConfigDTO:tt,filePath:vt,configId:Ot,reference:wt,webReference:ot,uploadedFiles:Mt,fileList:Zt,currentFiles:Ue}=J.data.data;if($e.length>0){const bt=$e.length-1-[...$e].reverse().findIndex(Wt=>Wt.istype==="ai");bt>=0&&bt<$e.length&&$e[bt].istype==="ai"&&(wt&&($e[bt].reference=wt),ot&&($e[bt].webReference=ot))}const Ye=Ue||Zt||Mt;if(Ye&&$e.length>0){const bt=[...$e].reverse().findIndex(Wt=>Wt.istype==="user");bt!==-1&&(console.log($e[$e.length-1-bt].currentFiles,"filesData"),$e[$e.length-1-bt].currentFiles=Ye)}E.find(bt=>bt.sessionId===Ae)&&k(bt=>bt.map(Wt=>Wt.sessionId===Ae?{...Wt,searchConfigDTO:tt,filePath:vt,configId:Ot}:Wt));const Tt={configId:J.data.data.configId,filePath:J.data.data.filePath,searchConfigDTO:J.data.data.searchConfigDTO||{},sessionId:J.data.data.sessionId,label:J.data.data.label,kbId:J.data.data.kbId};P(bt=>{const Wt=bt.filter(ft=>ft.id!==I);return[{id:I,messages:$e,...Tt},...Wt]}),z(bt=>({...bt,display:"ready"}))}).catch(J=>{console.error("\u83B7\u53D6\u804A\u5929\u6570\u636E\u5931\u8D25:",J),J.response&&J.response.status===404&&It(),z(Z=>({...Z,display:"error"}))}))},[I,r,n]),Et(()=>{const J=ge.uploadedFiles.length;q(Z=>{const $e=Array.isArray(Z.actions)?Z.actions:[];return{...Z,actions:$e.map(tt=>tt.name==="history"?{...tt,badgeCount:J}:tt)}})},[ge.uploadedFiles]),Et(()=>{Roe({url:r,token:n},J=>{Ee(J)})},[]),we.useEffect(()=>{U.length&&P(J=>{if(!J[0])return J;const{messages:Z}=J[0];for(let $e=Z.length-1;$e>=0;$e--)if(Z[$e].istype==="user"){const Ae=Z[$e].currentFiles||[];Z[$e].currentFiles=U.map(tt=>{var Ot,wt,ot;const vt=Ae.find(Mt=>Mt.uid===tt.uid);return{name:((Ot=tt.file)==null?void 0:Ot.name)||tt.name,size:((wt=tt.file)==null?void 0:wt.size)||tt.size,type:((ot=tt.file)==null?void 0:ot.type)||tt.type,status:tt.status,uid:tt.uid,url:tt.url||(vt==null?void 0:vt.url)||""}});break}return[...J]})},[U]);let dt=null,Ct=null;const jt=(J,Z,$e,Ae)=>{Ct=ie(J,{onStatusUpdate:Z,onComplete:$e,onFail:Ae})},Ie=(J,Z)=>{P($e=>{const Ae=[...$e];return Ae[0]&&(Ae[0]={...Ae[0],messages:Ae[0].messages.map(tt=>tt.queryId===J?{...tt,feedbackResult:Z}:tt)}),Ae})},Ne=async J=>{var Z,$e;if(J)try{const Ae=(je==null?void 0:je.configId)||((Z=lt==null?void 0:lt[(je==null?void 0:je.configId)||""])==null?void 0:Z.id)||"",tt=await vr.get(`${r}/qa/ai/recommendQuestion?queryId=${J}&configId=${Ae||""}`.replace(/\?&/,"?"),{headers:{Authorization:n}});V((($e=tt.data)==null?void 0:$e.data)||[])}catch{V([])}};function Oe(J){const{content:Z,audioUrl:$e,filePaths:Ae,queryId:tt}=J;if(!I||!tt)return;const vt=(je==null?void 0:je.messages)||[],Ot=vt.findIndex(Ye=>(Ye==null?void 0:Ye.queryId)===tt&&((Ye==null?void 0:Ye.istype)==="ai"||(Ye==null?void 0:Ye.isUser)===!1));let wt;if(Ot>0)for(let Ye=Ot-1;Ye>=0;Ye-=1){const ct=vt[Ye];if((ct==null?void 0:ct.istype)==="user"||(ct==null?void 0:ct.isUser)===!0){wt=ct;break}}const ot=(wt==null?void 0:wt.content)??Z;if(!ot)return;const Mt=(wt==null?void 0:wt.filePaths)??Ae,Zt=(typeof Mt=="string"&&Mt?JSON.parse(Mt):Mt||[]).map(Ye=>Ye.uid),Ue=Date.now();Ge({now:Ue}),z(Ye=>({...Ye,display:"processing",sender:"processing"})),Ot>=0&&vt[Ot]&&P(Ye=>{if(!Ye[0])return Ye;const ct=Ye[0],Tt=ct.messages||[];if(Ot>=Tt.length)return Ye;const Cn=Tt.slice();return Cn[Ot]={...Cn[Ot],content:Cn[Ot].content,reference:"[]",webReference:"[]",graphReference:null,databaseReference:null,status:2,chain:void 0},[{...ct,messages:Cn},...Ye.slice(1)]}),J.clearFn&&J.clearFn(),k(Ye=>Ye.map(ct=>ct.sessionId===I?{...ct,gmtModified:Ue}:ct)),Pt({configId:je.configId,content:ot,fileUids:Zt,lastDate:Ue,name:je.label||"",queryId:tt,sessionId:String(I||""),type:(wt==null?void 0:wt.audioUrl)??$e?"audioUrl":"text",audioUrl:((wt==null?void 0:wt.audioUrl)??$e)||"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Ye=>{Ne(tt)})}async function _e(J,Z){if(!I)return;const $e=new CustomEvent("aichat:right_set",{detail:{collapsed:!0}});window.dispatchEvent($e);const Ae=E.find(tt=>tt.sessionId===I);if(Ae&&Ae.isNew){let tt=!1;const vt=_||Ae.configId,Ot=J&&J.content?J.content.slice(0,20):Ae.label||"\u672A\u547D\u540D\u4F1A\u8BDD";if(await new Promise((wt,ot)=>{Loe({url:r,token:n,CSRFToken:i},{label:Ot,sessionId:Ae.sessionId,sysType:"INT_SESSION",configId:vt},Mt=>{Mt&&Mt.data&&Mt.data.sessionId?(k(Zt=>Zt.map(Ue=>Ue.sessionId===Ae.sessionId?{...Ue,isNew:!1,configId:vt,label:Ot}:Ue)),P(Zt=>Zt.map(Ue=>Ue.id===Ae.sessionId?{...Ue,isNew:!1,configId:vt,label:Ot}:Ue)),tt=!0,wt()):(mr.error("\u521B\u5EFA\u4F1A\u8BDD\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5"),ot())})}),!tt)return;mt(I,J,Z,vt);return}mt(I,J,Z)}function mt(J,Z,$e,Ae){const tt="query-"+ga(32),vt=E.find(Ye=>Ye.sessionId===J),Ot=Ae||(vt==null?void 0:vt.configId)||je.configId;console.log("\u52A9\u624B\u914D\u7F6E\u8BE6\u60C5",Ot);const wt=Z.content||Z.text||"",ot=typeof wt=="string"?wt:String(wt),Mt=ot?ot.slice(0,20):"\u672A\u547D\u540D\u4F1A\u8BDD";let Zt;if(Z.files&&Z.files.length>0&&(Zt=Z.files.map(Ye=>({name:Ye.file.name,size:Ye.file.size,type:Ye.file.type,filePath:Ye.filePath||"",convertedFilePath:Ye.convertedFilePath||"",uid:Ye.uid||""}))),console.log("\u672C\u5730\u6587\u4EF6\u4E0A\u4F20",Z.files),Ut({content:ot,queryId:tt,currentFiles:Zt,filePaths:Zt?JSON.stringify(Zt):void 0}),k(Ye=>Ye.map(ct=>ct.sessionId===J&&ct.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&ct.isNew?{...ct,label:Mt,gmtModified:Date.now(),isNew:!1}:ct)),P(Ye=>Ye.map(ct=>ct.id===J&&ct.label==="\u672A\u547D\u540D\u4F1A\u8BDD"&&ct.isNew?{...ct,label:Mt,isNew:!1}:ct)),Z.files&&Z.files.length>0){z(bt=>({...bt,sender:"uploading",display:"uploading"})),dt=new AbortController,re();const Ye=Z.files.map(()=>`rc-upload-${Date.now()}-${Math.random().toString(36).slice(2)}`),ct=Z.files.map((bt,Wt)=>({...bt,uid:Ye[Wt],status:"uploading"}));Y(ct);const Tt=new FormData;Z.files.forEach(bt=>{Tt.append("files",bt.file)});const Cn=String(J||"");Tt.append("sessionId",Cn),Tt.append("uids",Ye.join(",")),vr.post(`${r}/index/knowledgeBase/file/uploadFiles`,Tt,{headers:{Authorization:n,"Content-Type":"multipart/form-data"},signal:dt.signal}).then(bt=>{var Ft,Bn,zn,gr,ia,di,$a,fi,Oa,ws;if(console.log("\u6587\u4EF6\u4E0A\u4F20\u7684\u6253\u5370\u7ED3\u679C",bt),console.log("\u6587\u4EF6\u4E0A\u4F20\u54CD\u5E94\u8BE6\u60C5:",{status:bt.status,success:(Ft=bt.data)==null?void 0:Ft.success,dataType:Array.isArray((Bn=bt.data)==null?void 0:Bn.data)?"array":typeof((zn=bt.data)==null?void 0:zn.data),dataLength:Array.isArray((gr=bt.data)==null?void 0:gr.data)?bt.data.data.length:"N/A",errorMsg:(ia=bt.data)==null?void 0:ia.errorMsg,errorCode:(di=bt.data)==null?void 0:di.errorCode,fullResponse:bt.data}),ne.current)return;const Wt=($a=bt.data)==null?void 0:$a.data,Fn=((fi=bt.data)==null?void 0:fi.success)===!0,ft=Array.isArray(Wt)&&Wt.length>0;if(Fn&&ft){const eo=Wt,Di=eo.map(Qn=>Qn.uid);Y(Qn=>Qn.map(Je=>{const Nt=Wt.find(Vt=>Vt.uid===Je.uid);return Nt?{...Je,...Nt}:Je})),z(Qn=>({...Qn,sender:"processing",display:"analyzing"})),Y(Qn=>Qn.map(Je=>({...Je,status:"parsing"}))),jt(Di,Qn=>{if(!Qn||!Array.isArray(Qn)){console.warn("pollFileStatus \u56DE\u8C03\u8FD4\u56DE\u7684 serverStatuses \u65E0\u6548:",Qn);return}if(Y(Nt=>Nt.map(Vt=>{const Hn=Qn.find(An=>An&&An.uid===Vt.uid);if(Hn)switch(Hn.fileParseStatus??Hn.status){case 3:return{...Vt,status:"done"};case 4:return{...Vt,status:"error"};case 1:case 2:default:return{...Vt,status:"parsing"}}return Vt})),Array.isArray(Qn)&&Qn.length>0&&Qn.every(Nt=>{if(!Nt)return!1;const Vt=Nt.fileParseStatus??Nt.status;return Vt===3||Vt===4})){Y([]);const Nt=new Map;(Qn||[]).forEach(Vt=>{Nt.set(Vt.id,Vt)}),de(Vt=>({uploadedFiles:gie(Vt.uploadedFiles,eo).map(An=>{var Ti;return{...An,pdfPages:((Ti=Nt.get(An.id))==null?void 0:Ti.pdfPages)||0}})}))}},()=>{$e==null||$e(),z(Je=>({...Je,sender:"processing",display:"processing"})),Y(Je=>Je.map(Nt=>{const Vt=eo.find(Hn=>Hn.uid===Nt.uid);return Vt?{...Nt,...Vt,url:Vt.filePath,filePath:Vt.filePath,name:Vt.fileName||Nt.name,convertedFilePath:Vt.convertedFilePath||Nt.convertedFilePath}:Nt})),P(Je=>{if(!Je[0])return Je;const{messages:Nt}=Je[0];for(let Vt=Nt.length-1;Vt>=0;Vt--)if(Nt[Vt].istype==="user"){const Hn=Nt[Vt].currentFiles||[];Nt[Vt].currentFiles=Hn.map(An=>{const Ti=eo.find(Zc=>Zc.uid===An.uid);return Ti?{...An,...Ti}:An});break}return[...Je]});const Qn=Date.now();Pt({configId:Ot,content:ot,fileUids:Di,lastDate:Qn,name:Mt,queryId:tt,sessionId:String(J||""),type:"text",audioUrl:"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Je=>{Ne(tt)})},Qn=>{z(Je=>({...Je,display:"ready",sender:"ready"})),Y(Je=>Je.map(Nt=>({...Nt,status:"error",message:Qn})))})}else{let eo="\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25";(Oa=bt.data)!=null&&Oa.errorMsg?eo=bt.data.errorMsg:Fn?ft||(Array.isArray(Wt)?Wt.length===0&&(eo="\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u4E3A\u7A7A"):eo=`\u4E0A\u4F20\u5931\u8D25: \u8FD4\u56DE\u6570\u636E\u683C\u5F0F\u9519\u8BEF\uFF0C\u671F\u671B\u6570\u7EC4\uFF0C\u5B9E\u9645\u4E3A ${typeof Wt}`):eo=`\u4E0A\u4F20\u5931\u8D25: success=${(ws=bt.data)==null?void 0:ws.success}`,console.error("\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25\u8BE6\u60C5:",{errorMsg:eo,response:bt.data,isSuccess:Fn,isValidData:ft}),mr.error(eo),z(Di=>({...Di,display:"error",sender:"ready"})),Y(Di=>Di.map(Qn=>({...Qn,status:"error",message:eo})))}}).catch(bt=>{var Wt,Fn;((Wt=bt==null?void 0:bt.response)==null?void 0:Wt.status)===413?(Fn=bt==null?void 0:bt.response)!=null&&Fn.statusText.includes("Request Entity Too Large")&&mr.error("\u6587\u4EF6\u8D85\u8FC7\u6700\u5927\u53EF\u4E0A\u4F20\u9650\u5236"):mr.error("\u7F51\u7EDC\u9519\u8BEF"),z(ft=>({...ft,display:"error",sender:"ready"})),Y(ft=>ft.map(Ft=>({...Ft,status:"error",message:"\u7F51\u7EDC\u9519\u8BEF"})))});return}z(Ye=>({...Ye,display:"processing",sender:"processing"}));const Ue=Date.now();k(Ye=>Ye.map(ct=>ct.sessionId===J?{...ct,gmtModified:Ue}:ct)),$e==null||$e(),Pt({configId:Ot,content:ot,fileUids:[],lastDate:Ue,name:Mt,queryId:tt,sessionId:String(J||""),type:"text",audioUrl:"",enableThinking:!!be.reasoning,enableWebsearch:!!be.netSearch,qaChannel:be.qaChannel,tempKnowledgeBaseCheck:ht.current},Ye=>{Ne(tt)})}function kt(J){J.restult==1?Bm({url:r,token:n,CSRFToken:i},{queryId:J.queryId},()=>{Ie(J.queryId,null)}):VA({url:r,token:n,CSRFToken:i},{restult:1,queryId:J.queryId},()=>{Ie(J.queryId,1)})}function It(J){const Z=ga(32),$e={sessionId:Z,label:"\u672A\u547D\u540D\u4F1A\u8BDD",gmtModified:Date.now(),searchConfigDTO:{},filePath:"",configId:"",isNew:!0};k(Ae=>[{...$e,messages:[]},...Ae]),P(Ae=>[{id:Z,messages:[],...$e},...Ae]),R(Z)}function Xt(J){if(J!=null&&J.sessionId&&J.sessionId!==I){I&&qe(I),R(J.sessionId),z($e=>({...$e,sender:"ready"}));const Z=T.find($e=>$e.id===J.sessionId);if(Z&&Z.messages&&Z.messages.length>0){const $e=[...Z.messages].reverse().find(Ae=>Ae.istype==="ai");$e&&$e.recommendQuestion?V($e.recommendQuestion):V([])}else V([])}}const on=async J=>new Promise((Z,$e)=>{joe({url:r,token:n,CSRFToken:i},{sessionId:J},Ae=>{Ae?(mr.success("\u5220\u9664\u6210\u529F!"),Z(Ae)):(mr.error("\u5220\u9664\u5931\u8D25!"),$e(Ae))})}),qt=async()=>{try{return k([]),M(0),await zt(1),[]}catch(J){throw mr.error("\u5237\u65B0\u4F1A\u8BDD\u5217\u8868\u5931\u8D25"),J}},wn=async(J,Z)=>new Promise(($e,Ae)=>{_oe({url:r,token:n,CSRFToken:i},{label:Z,sessionId:J},tt=>{if(tt){const vt=Date.now();k(Ot=>Ot.map(wt=>wt.sessionId===J?{...wt,label:Z,gmtModified:vt}:wt)),P(Ot=>Ot.map(wt=>wt.id===J?{...wt,label:Z}:wt)),mr.success("\u91CD\u547D\u540D\u6210\u529F!"),$e(tt)}else mr.error("\u91CD\u547D\u540D\u5931\u8D25"),Ae(tt)})}),vn=J=>{k(Z=>{const $e=Z.filter(Ae=>Ae.sessionId!==J);return I===J&&($e.length>0?R($e[0].sessionId):It()),$e})},Kt=(J,Z)=>{const $e=Date.now();k(Ae=>Ae.map(tt=>tt.sessionId===J?{...tt,label:Z,gmtModified:$e}:tt)),P(Ae=>Ae.map(tt=>tt.id===J?{...tt,label:Z}:tt))},$n=J=>{VA({url:r,token:n,CSRFToken:i},{...J,...xe,restult:0},()=>{Ie(xe.queryId,0)})},On=J=>{const Z=J.new_name,$e=m.data.label;Z&&Z!==$e?m.async_renameConversation(Z).then(()=>{m.fn_renameItemInList(Z),d(!1)}).catch(()=>{}):d(!1)},ur=J=>{m.async_deleteConversation().then(()=>{m.fn_removeItemFromList(),h(!1)}).catch(()=>{})},We=(J,Z)=>{switch(console.log(J,Z),J){case"close_remove":h(!1);break;case"close_rename":d(!1);break;case"ok_rename":On(Z);break;case"ok_remove":ur();break}},pt=async({url:J,params:Z,replacePredataFunction:$e})=>{var Ae,tt;try{const vt=await vr.post(J,Z,{headers:{Authorization:n}}),Ot=(tt=(Ae=vt==null?void 0:vt.data)==null?void 0:Ae.data)==null?void 0:tt.data;Ot&&$e(Ot)}catch(vt){console.log("error",vt)}},Ke=async J=>{var Z;try{const $e=await vr.get(`${sC()}/index/knowledgeBase/file/getFileStatusByUids?uids=${J.data.uids}`,{headers:{Authorization:n}});return console.log("resslkdjgalsg",$e),(Z=$e==null?void 0:$e.data)==null?void 0:Z.data}catch{}},rt=async J=>{var Z;if(Az.includes(J.file_type)){const $e=(Z=J.metadata)!=null&&Z.source?`${ip}${J.metadata.source}`:J.url||J.convertedFilePath||J.filePath;x({...J,parse_url:$e}),b("preview"),v(!0);return}try{const $e=await Ke({data:{uids:J.uid},config:{url:sC(),token:n,enableMock:!1}});if($e!=null&&$e.length){const Ae=$e[0];x({...J,parse_url:Ae.convertedFilePath}),b("preview"),v(!0)}}catch{}},ht=et(!1),an=(J,Z)=>{var $e,Ae,tt,vt,Ot,wt,ot;switch(console.log(`[Event] ${J}`,Z),J){case"TempKnowledgeBase":ht.current=Z;break;case"reference_file:click":if(Z.file_type==="image")return;if(!Z.parse_url){if(!Z.uid)return Z.references?void 0:mr.warning("\u6587\u4EF6\u8FD8\u672A\u89E3\u6790\u5B8C\u6210,\u8BF7\u7A0D\u540E\u9884\u89C8");rt(Z);return}x({...Z,file_type:Z.type,file_name:Z.file}),b("preview"),v(!0);break;case"conversations:load_more":{E.length<$&&!N&&zt(S+1);break}case"retrieve-sql-data:pagingation_click":const{page:Mt,pageSize:Zt,fetchUrl:Ue,source:Ye,replacePredataFunction:ct}=Z;pt({url:`${r}${Ue}`,replacePredataFunction:ct,params:{pageNo:Mt,pageSize:Zt,convertedFilePath:Ye,stream:!1}});break;case"web_referenceFile_title:click":if(!(($e=Z==null?void 0:Z.data)!=null&&$e.link))return console.error("\u6CA1\u6709\u7F51\u9875\u5730\u5740");window.open(Z.data.link,"_blank");break;case"conversation:item_click":Xt(Z);break;case"files:finished_animation_complete":Y([]);break;case"conversation:create":It();break;case"conversation:new_assistant_change":F(Z.assistantId);break;case"conversations:rename_icon_clicked":p({data:Z,async_renameConversation:Tt=>wn(Z.sessionId,Tt),fn_renameItemInList:Tt=>Kt(Z.sessionId,Tt)}),d(!0);break;case"conversations:delete_icon_clicked":p({data:Z,async_deleteConversation:()=>on(Z.sessionId),async_refreshConversationList:qt,fn_removeItemFromList:()=>vn(Z.sessionId)}),h(!0);break;case"sender:send":_e(Z,Z.clearFn);break;case"sender:send_recommandQuestion":{const Tt=((Z==null?void 0:Z.content)??"").toString();if(!Tt)break;_e({content:Tt},()=>{});break}case"chatbox:follow_up_question_click":{const Tt=((Z==null?void 0:Z.question)??(Z==null?void 0:Z.content)??"").toString();if(!Tt)break;_e({content:Tt},()=>{});break}case"sender:stop":oe(),dt&&(dt.abort(),dt=null),Ct&&(Ct(),Ct=null),z(Tt=>({...Tt,display:"ready",sender:"ready"})),Y([]),Xe==null||Xe();break;case"sender:clear":(Ae=Z.clearFn)==null||Ae.call(Z);break;case"sender:configChange":Z&&Z.all&&ce(Z.all);break;case"sender:action_upload":Pe.current&&Pe.current.click();break;case"sender:action_history":Dt(!0);break;case"uploaded_file:item_click":break;case"action_copy:click":Z&&Ioe(Z.content,Z.event);break;case"chatbox:copy":{let Tt=(Z==null?void 0:Z.content)||"";if(!Tt)break;Tt=Tt.replace(/\[retrive-tag[^\]]*\][\s\S]*?\[\/retrive-tag\]/g,"");const Cn=async Wt=>{try{return await navigator.clipboard.writeText(Wt),mr.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F"),!0}catch{return!1}},bt=Wt=>{const Fn=document.createElement("textarea");Fn.value=Wt,Fn.style.position="fixed",Fn.style.opacity="0",document.body.appendChild(Fn),Fn.focus(),Fn.select();try{document.execCommand("copy"),mr.success("\u5DF2\u590D\u5236\u5230\u526A\u8D34\u677F")}catch{mr.error("\u590D\u5236\u5931\u8D25")}document.body.removeChild(Fn)};Cn(Tt).then(Wt=>{Wt||bt(Tt)});break}case"chatbox:repeat":console.log(Z,"sdkflskdjflksdjfklsdjlfkjsdklfjsdklfjlks"),Oe(Z);break;case"action_thumbsup":kt(Z);break;case"chatbox:like":kt({queryId:Z==null?void 0:Z.queryId,restult:Z==null?void 0:Z.result});break;case"action_thumbsdown":Z.restult===0?Bm({url:r,token:n,CSRFToken:i},{queryId:Z.queryId},()=>{Ie(Z.queryId,null)}):(fe(Z),ke(!0));break;case"chatbox:dislike":(Z==null?void 0:Z.result)===0?Bm({url:r,token:n,CSRFToken:i},{queryId:Z.queryId},()=>{Ie(Z.queryId,null)}):(fe({queryId:Z==null?void 0:Z.queryId}),ke(!0));break;case"action_retrive_tag":a==null||a("action_retrive_tag",Z);break;case"referenceFile_view":a==null||a("referenceFile_view",Z);break;case"referenceFile_question":console.log(Z,"zhezhhzhzh"),rt(Z.data||Z),a==null||a("referenceFile_question",Z);break;case"referenceFile_download":a==null||a("referenceFile_download",Z);break;case"references:click":case"knowledge_base_view_all:click":{const Tt=()=>J==="references:click"?ee(uxe,{type:"referencelist",data:Z,token:n,eventsEmit:a,is_download:Rt}):ee(dxe,{fileData:Z,token:n}),Cn=new CustomEvent("aichat:right_set_content",{detail:{content:ee(Tt,{})}});window.dispatchEvent(Cn);const bt=new CustomEvent("aichat:right_set",{detail:{collapsed:!1}});window.dispatchEvent(bt);break}case"retrive_tag:click":a==null||a("retrive_tag:click",Z);break;case"fileManager:change":{typeof(Z==null?void 0:Z.setUploadedFiles)=="function"&&(Te.current=Z.setUploadedFiles,se.current=Z.removeFile,De.current=Z==null?void 0:Z.senderConfig,He.current=Array.isArray(Z==null?void 0:Z.uploadedFiles)?Z.uploadedFiles:[],Array.isArray(Z==null?void 0:Z.uploadedFiles)&&ve(Z.uploadedFiles),console.log("[DEBUG] fileManager:change \u4E8B\u4EF6\u89E6\u53D1\uFF0CsetUploadedFilesRef \u5DF2\u8BBE\u7F6E",{hasSetUploadedFiles:!!Te.current,uploadedFilesCount:((tt=Z==null?void 0:Z.uploadedFiles)==null?void 0:tt.length)||0,pendingFilesCount:((vt=Z==null?void 0:Z.uploadedFiles)==null?void 0:vt.length)||0,hasSenderConfig:!!(Z!=null&&Z.senderConfig),senderConfig:Z==null?void 0:Z.senderConfig,upload_number_limit:(Ot=Z==null?void 0:Z.senderConfig)==null?void 0:Ot.upload_number_limit,upload_size_limit:(wt=Z==null?void 0:Z.senderConfig)==null?void 0:wt.upload_size_limit}));break}case"uploaded_file:removeFromTemp":{console.log("[DEBUG] mergedEventsEmit uploaded_file:removeFromTemp \u4E8B\u4EF6",Z);const Tt=(ot=Z==null?void 0:Z.file)==null?void 0:ot.uid;if(!Tt){console.warn("[DEBUG] \u7F3A\u5C11uid\uFF0C\u65E0\u6CD5\u5220\u9664\u4E34\u65F6\u6587\u4EF6",Z);break}const Cn=[...(je==null?void 0:je.messages)||[]].reverse().find(Wt=>Wt.istype==="user"),bt=Cn==null?void 0:Cn.queryId;K(Tt,bt);break}case"uploaded_file:remove_batch":break;default:a==null||a(J,Z)}},dn=[{key:"conversations",type:"custom",label:"\u5BF9\u8BDD\u5386\u53F2",icon:ee(hH,{size:16}),enabled:!0,component:ee(Noe,{data:E,assistantList:L,activedItem:I||"",hasMore:E.length<$,loadingMore:N,sortRules:[{label:"\u5F53\u5929",dayPeriod:1},{label:"3\u5929",dayPeriod:3},{label:"7\u5929",dayPeriod:7},{label:"30\u5929",dayPeriod:30}],eventsEmit:an,styles:c.theme})}],Un=we.useCallback(()=>ee(qoe,{eventsEmit:an,assistantList:L,styles:c,selectedId:Se,onSelectAssistant:ye,productLogo:l==null?void 0:l.productLogo}),[an,L,c,Se,l==null?void 0:l.productLogo]),Nn={...we.useMemo(()=>({AiChatBox:(J,Z)=>{var Zt,Ue,Ye;const $e=Z===(((Zt=je==null?void 0:je.messages)==null?void 0:Zt.length)||0)-1;let Ae="ready";if($e)if(J.status!==void 0)switch(J.status){case 0:Ae="thinking";break;case 1:Ae="processing";break;case 2:Ae="ready";break;case 3:Ae="error";break;case 4:Ae="thinking";break;default:Ae=B.display}else Ae=B.display;let tt=[];if(Array.isArray(H))tt=H;else if(typeof H=="string")try{tt=JSON.parse(H)||[]}catch{tt=[]}const vt=(()=>{const ct=J==null?void 0:J.reference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),Ot=(()=>{const ct=J==null?void 0:J.webReference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),wt=(()=>{const ct=J==null?void 0:J.graphReference;if(!ct)return"[]";if(typeof ct=="string")try{return JSON.parse(ct),ct}catch{return"[]"}try{return JSON.stringify(ct)}catch{return"[]"}})(),ot=J==null?void 0:J.databaseReference,Mt=(()=>{var Tt,Cn,bt;if(J!=null&&J.chainRespTime||(Tt=J==null?void 0:J.reply)!=null&&Tt.chainRespTime)return(J==null?void 0:J.chainRespTime)??((Cn=J==null?void 0:J.reply)==null?void 0:Cn.chainRespTime);const ct=(J==null?void 0:J.chain)||((bt=J==null?void 0:J.reply)==null?void 0:bt.chain);if(Array.isArray(ct)&&ct.length>0){const Wt=ct.reduce((Fn,ft)=>{const Ft=(ft==null?void 0:ft.chainRespTime)??(ft==null?void 0:ft.respTime);return Ft!=null&&Ft>0?Fn+Ft:Fn},0);return Wt>0?Wt:void 0}})();return ee(jS,{...J,token:n,streamUrl:"/proxy/index/knowledgeBase/file/stream",referenceMode:"button",reference:vt,webReference:Ot,graphReference:wt,databaseReference:ot,contentType:"stream",displayStatus:Ae,eventsEmit:an,isLast:$e&&(J==null?void 0:J.istype)==="ai",followUpQuestions:$e&&(J==null?void 0:J.istype)==="ai"?tt:[],defaultAnswer:((Ue=je==null?void 0:je.searchConfigDTO)==null?void 0:Ue.defaultAnswer)||"\u4E0D\u77E5\u9053\u4EC0\u4E48\u539F\u56E0\u6211\u4EEC\u6CA1\u80FD\u67E5\u5230\u4F60\u8981\u7684\u95EE\u9898*-*",is_download:Rt,styles:c,enableThoughtChain:!0,chain:J==null?void 0:J.chain,thoughtChainNodes:J==null?void 0:J.thoughtChainNodes,thoughtChainStatus:J==null?void 0:J.status,enableCot:(J==null?void 0:J.enableCot)??((Ye=J==null?void 0:J.reply)==null?void 0:Ye.enableCot),chainRespTime:Mt},`${(J==null?void 0:J.queryId)||(J==null?void 0:J.id)||Z}-${(J==null?void 0:J.istype)||"unknown"}`)},LogoBox:J=>J&&J.LogoBox===null?null:J&&typeof J.LogoBox=="function"?ee(J.LogoBox,{}):ee("div",{className:"text-2xl w-full text-center font-bold",children:"\u5C0F\u9CB8\u667A\u80FD\u52A9\u624B"}),DisplayLoading:()=>ee(fie,{}),DisplayError:()=>ee(pie,{}),AppError:()=>ee(hie,{msg:"\u5E94\u7528\u521D\u59CB\u5316\u5931\u8D25",subMsg:"\u65E0\u6CD5\u5B8C\u6210\u5E94\u7528\u521D\u59CB\u5316\uFF0C\u8FD9\u53EF\u80FD\u662F\u7531\u4E8E\u7F51\u7EDC\u8FDE\u63A5\u95EE\u9898\u6216\u670D\u52A1\u914D\u7F6E\u9519\u8BEF\u5BFC\u81F4\u7684\u3002\u8BF7\u68C0\u67E5\u60A8\u7684\u7F51\u7EDC\u8FDE\u63A5\u5E76\u91CD\u8BD5\u3002"}),AppLoading:()=>{var J,Z;return ee(die,{title:(J=l==null?void 0:l.appLoadingConfig)==null?void 0:J.title,subtitle:((Z=l==null?void 0:l.appLoadingConfig)==null?void 0:Z.subtitle)||""})},UserChatBox:(J,Z)=>ee(jS,{token:n,streamUrl:"/proxy/index/knowledgeBase/file/stream",...J,referenceMode:"button",contentType:"plainText",isUser:!0,displayStatus:"ready",eventsEmit:an,styles:c,fileManagerData:ge,currentFiles:J==null?void 0:J.currentFiles},`${(J==null?void 0:J.queryId)||(J==null?void 0:J.id)||Z}-user`),WelcomeComponent:Un}),[Un,je,B.display,an,c,Rt,ge]),...l.CustomComponents||{}};Et(()=>{q(J=>{const Z=Array.isArray(J.switchs)?J.switchs.map($e=>$e.name==="reasoning"?{...$e,enabled:!0}:$e):[];return{...J,switchs:Z}})},[]);const Dn=Gt(()=>ge.uploadedFiles||[],[ge]),{FileDisplayTools:wr}=aie({fileManagerData:{uploadedFiles:Dn},styles:c,eventsEmit:an});return ut("div",{style:{height:"100%",minWidth:"1116px",overflow:"hidden"},children:[ee("input",{ref:Pe,type:"file",multiple:!0,accept:"image/*,.pdf,.doc,.docx,.ppt,.pptx,.xls,.xlsx,.txt,.md,.json,.csv,.zip,.rar,.7z",style:{display:"none"},onChange:J=>{const Z=J.target.files;if(Z&&Z.length>0){console.log("[DEBUG] handleFileSelect \u89E6\u53D1",{filesCount:Z.length,hasSetUploadedFilesRef:!!Te.current,hasSenderConfig:!!De.current,dynamicSenderConfig:W,dynamicSenderConfigKeys:W?Object.keys(W):[],senderConfigRef:De.current,senderConfigRefKeys:De.current?Object.keys(De.current):[]});const $e=Array.from(Z);let Ae=De.current;(!Ae||Ae.upload_size_limit===void 0&&Ae.upload_number_limit===void 0&&(!Ae.upload_file_type_limit||Ae.upload_file_type_limit.length===0))&&(Ae=W);const tt=He.current||[];console.log("[DEBUG] \u9A8C\u8BC1\u914D\u7F6E\u68C0\u67E5",{configSource:Ae,upload_number_limit:Ae==null?void 0:Ae.upload_number_limit,upload_size_limit:Ae==null?void 0:Ae.upload_size_limit,existingFilesCount:tt.length,newFilesCount:$e.length});const vt=Ae&&(Ae.upload_size_limit!==void 0||Ae.upload_number_limit!==void 0&&Ae.upload_number_limit>0||Ae.upload_file_type_limit&&Ae.upload_file_type_limit.length>0);if(console.log("[DEBUG] \u914D\u7F6E\u68C0\u67E5\u7ED3\u679C",{hasUploadLimitConfig:vt,upload_number_limit:Ae==null?void 0:Ae.upload_number_limit,upload_size_limit:Ae==null?void 0:Ae.upload_size_limit,upload_file_type_limit:Ae==null?void 0:Ae.upload_file_type_limit}),vt){const Ot={upload_size_limit:Ae.upload_size_limit,upload_number_limit:Ae.upload_number_limit,upload_file_type_limit:Ae.upload_file_type_limit,upload_limit_message:Ae.upload_limit_message};console.log("[DEBUG] \u6267\u884C\u6587\u4EF6\u9A8C\u8BC1",{uploadConfig:Ot,existingFilesCount:tt.length,newFilesCount:$e.length,totalCount:tt.length+$e.length});const wt=iw($e,tt,Ot);if(console.log("[DEBUG] \u9A8C\u8BC1\u7ED3\u679C",{valid:wt.valid,errors:wt.errors,rejectedFilesCount:wt.rejectedFiles.length}),!wt.valid){aw(wt);const ot=$e.filter(Mt=>!wt.rejectedFiles.includes(Mt));if(ot.length===0){Pe.current&&(Pe.current.value="");return}$e.splice(0,$e.length,...ot)}}if(Te.current){const Ot=$e.map(wt=>({file:wt,type:wt.type.startsWith("image/")?"image":"document",status:"pending",name:wt.name}));console.log("[DEBUG] \u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",Ot),Te.current(Ot)}else console.warn("[DEBUG] setUploadedFilesRef \u672A\u8BBE\u7F6E\uFF0C\u5EF6\u8FDF\u91CD\u8BD5"),setTimeout(()=>{if(Te.current){const Ot=$e.map(wt=>({file:wt,type:wt.type.startsWith("image/")?"image":"document",status:"pending",name:wt.name}));console.log("[DEBUG] \u5EF6\u8FDF\u540E\u901A\u8FC7 setUploadedFilesRef \u8BBE\u7F6E\u6587\u4EF6",Ot),Te.current(Ot)}else console.error("[DEBUG] \u5EF6\u8FDF\u540E setUploadedFilesRef \u4ECD\u672A\u8BBE\u7F6E")},100)}Pe.current&&(Pe.current.value="")}}),ee(e,{...l,status:B,chatData:je,sidebar:dn,recommandQuestions:[],eventsEmit:an,styles:c,senderConfig:W,fileUploadStatus:U,CustomComponents:Nn,activeSessionId:I,scrollOld:s,rightbarWidth:"400px",chatHeader:{title:(je==null?void 0:je.label)||"\u65B0\u5BF9\u8BDD",tools:wr}}),ee(cie,{open:pe,feedBackList:Ve,setOpen:ke,handleConfirm:$n}),ee(mie,{isModalOpen:u,handleOk:We,handleCancel:()=>We("close_rename"),data:(m==null?void 0:m.data)||{}}),ee(vie,{isModalOpen:f,handleOk:We,handleCancel:()=>We("close_remove"),data:(m==null?void 0:m.data)||{}}),ee(xd,{drawer:{styles:{body:{padding:0},header:{display:"none"}}},children:ee(RF,{autoFocus:!1,onClose:()=>v(!1),open:g,width:y==="graphPreview"?"100%":720,className:"overflow-x-hidden",destroyOnClose:!0,children:y==="preview"&&ee(Oz,{curFileInfo:w,onClose:v,token:n})})})]})}}var Eh={exports:{}},wh={exports:{}},hxe=wh.exports,VT;function En(){return VT||(VT=1,(function(e,t){(function(n,r){e.exports=r()})(hxe,function(){var n=n||(function(r,o){var i;if(typeof window<"u"&&window.crypto&&(i=window.crypto),typeof self<"u"&&self.crypto&&(i=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(i=globalThis.crypto),!i&&typeof window<"u"&&window.msCrypto&&(i=window.msCrypto),!i&&typeof qg<"u"&&qg.crypto&&(i=qg.crypto),!i&&typeof sH=="function")try{i=lH}catch{}var a=function(){if(i){if(typeof i.getRandomValues=="function")try{return i.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof i.randomBytes=="function")try{return i.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},s=Object.create||(function(){function y(){}return function(b){var w;return y.prototype=b,w=new y,y.prototype=null,w}})(),l={},c=l.lib={},u=c.Base=(function(){return{extend:function(y){var b=s(this);return y&&b.mixIn(y),(!b.hasOwnProperty("init")||this.init===b.init)&&(b.init=function(){b.$super.init.apply(this,arguments)}),b.init.prototype=b,b.$super=this,b},create:function(){var y=this.extend();return y.init.apply(y,arguments),y},init:function(){},mixIn:function(y){for(var b in y)y.hasOwnProperty(b)&&(this[b]=y[b]);y.hasOwnProperty("toString")&&(this.toString=y.toString)},clone:function(){return this.init.prototype.extend(this)}}})(),d=c.WordArray=u.extend({init:function(y,b){y=this.words=y||[],b!=o?this.sigBytes=b:this.sigBytes=y.length*4},toString:function(y){return(y||h).stringify(this)},concat:function(y){var b=this.words,w=y.words,x=this.sigBytes,E=y.sigBytes;if(this.clamp(),x%4)for(var k=0;k<E;k++){var S=w[k>>>2]>>>24-k%4*8&255;b[x+k>>>2]|=S<<24-(x+k)%4*8}else for(var O=0;O<E;O+=4)b[x+O>>>2]=w[O>>>2];return this.sigBytes+=E,this},clamp:function(){var y=this.words,b=this.sigBytes;y[b>>>2]&=4294967295<<32-b%4*8,y.length=r.ceil(b/4)},clone:function(){var y=u.clone.call(this);return y.words=this.words.slice(0),y},random:function(y){for(var b=[],w=0;w<y;w+=4)b.push(a());return new d.init(b,y)}}),f=l.enc={},h=f.Hex={stringify:function(y){for(var b=y.words,w=y.sigBytes,x=[],E=0;E<w;E++){var k=b[E>>>2]>>>24-E%4*8&255;x.push((k>>>4).toString(16)),x.push((k&15).toString(16))}return x.join("")},parse:function(y){for(var b=y.length,w=[],x=0;x<b;x+=2)w[x>>>3]|=parseInt(y.substr(x,2),16)<<24-x%8*4;return new d.init(w,b/2)}},m=f.Latin1={stringify:function(y){for(var b=y.words,w=y.sigBytes,x=[],E=0;E<w;E++){var k=b[E>>>2]>>>24-E%4*8&255;x.push(String.fromCharCode(k))}return x.join("")},parse:function(y){for(var b=y.length,w=[],x=0;x<b;x++)w[x>>>2]|=(y.charCodeAt(x)&255)<<24-x%4*8;return new d.init(w,b)}},p=f.Utf8={stringify:function(y){try{return decodeURIComponent(escape(m.stringify(y)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(y){return m.parse(unescape(encodeURIComponent(y)))}},g=c.BufferedBlockAlgorithm=u.extend({reset:function(){this._data=new d.init,this._nDataBytes=0},_append:function(y){typeof y=="string"&&(y=p.parse(y)),this._data.concat(y),this._nDataBytes+=y.sigBytes},_process:function(y){var b,w=this._data,x=w.words,E=w.sigBytes,k=this.blockSize,S=k*4,O=E/S;y?O=r.ceil(O):O=r.max((O|0)-this._minBufferSize,0);var A=O*k,$=r.min(A*4,E);if(A){for(var M=0;M<A;M+=k)this._doProcessBlock(x,M);b=x.splice(0,A),w.sigBytes-=$}return new d.init(b,$)},clone:function(){var y=u.clone.call(this);return y._data=this._data.clone(),y},_minBufferSize:0});c.Hasher=g.extend({cfg:u.extend(),init:function(y){this.cfg=this.cfg.extend(y),this.reset()},reset:function(){g.reset.call(this),this._doReset()},update:function(y){return this._append(y),this._process(),this},finalize:function(y){y&&this._append(y);var b=this._doFinalize();return b},blockSize:16,_createHelper:function(y){return function(b,w){return new y.init(w).finalize(b)}},_createHmacHelper:function(y){return function(b,w){return new v.HMAC.init(y,w).finalize(b)}}});var v=l.algo={};return l})(Math);return n})})(wh)),wh.exports}var Ch={exports:{}},pxe=Ch.exports,GT;function Ug(){return GT||(GT=1,(function(e,t){(function(n,r){e.exports=r(En())})(pxe,function(n){return(function(r){var o=n,i=o.lib,a=i.Base,s=i.WordArray,l=o.x64={};l.Word=a.extend({init:function(c,u){this.high=c,this.low=u}}),l.WordArray=a.extend({init:function(c,u){c=this.words=c||[],u!=r?this.sigBytes=u:this.sigBytes=c.length*8},toX32:function(){for(var c=this.words,u=c.length,d=[],f=0;f<u;f++){var h=c[f];d.push(h.high),d.push(h.low)}return s.create(d,this.sigBytes)},clone:function(){for(var c=a.clone.call(this),u=c.words=this.words.slice(0),d=u.length,f=0;f<d;f++)u[f]=u[f].clone();return c}})})(),n})})(Ch)),Ch.exports}var kh={exports:{}},gxe=kh.exports,UT;function mxe(){return UT||(UT=1,(function(e,t){(function(n,r){e.exports=r(En())})(gxe,function(n){return(function(){if(typeof ArrayBuffer=="function"){var r=n,o=r.lib,i=o.WordArray,a=i.init,s=i.init=function(l){if(l instanceof ArrayBuffer&&(l=new Uint8Array(l)),(l instanceof Int8Array||typeof Uint8ClampedArray<"u"&&l instanceof Uint8ClampedArray||l instanceof Int16Array||l instanceof Uint16Array||l instanceof Int32Array||l instanceof Uint32Array||l instanceof Float32Array||l instanceof Float64Array)&&(l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength)),l instanceof Uint8Array){for(var c=l.byteLength,u=[],d=0;d<c;d++)u[d>>>2]|=l[d]<<24-d%4*8;a.call(this,u,c)}else a.apply(this,arguments)};s.prototype=i}})(),n.lib.WordArray})})(kh)),kh.exports}var Sh={exports:{}},vxe=Sh.exports,qT;function yxe(){return qT||(qT=1,(function(e,t){(function(n,r){e.exports=r(En())})(vxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Utf16=a.Utf16BE={stringify:function(l){for(var c=l.words,u=l.sigBytes,d=[],f=0;f<u;f+=2){var h=c[f>>>2]>>>16-f%4*8&65535;d.push(String.fromCharCode(h))}return d.join("")},parse:function(l){for(var c=l.length,u=[],d=0;d<c;d++)u[d>>>1]|=l.charCodeAt(d)<<16-d%2*16;return i.create(u,c*2)}},a.Utf16LE={stringify:function(l){for(var c=l.words,u=l.sigBytes,d=[],f=0;f<u;f+=2){var h=s(c[f>>>2]>>>16-f%4*8&65535);d.push(String.fromCharCode(h))}return d.join("")},parse:function(l){for(var c=l.length,u=[],d=0;d<c;d++)u[d>>>1]|=s(l.charCodeAt(d)<<16-d%2*16);return i.create(u,c*2)}};function s(l){return l<<8&4278255360|l>>>8&16711935}})(),n.enc.Utf16})})(Sh)),Sh.exports}var Ah={exports:{}},bxe=Ah.exports,YT;function Al(){return YT||(YT=1,(function(e,t){(function(n,r){e.exports=r(En())})(bxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Base64={stringify:function(l){var c=l.words,u=l.sigBytes,d=this._map;l.clamp();for(var f=[],h=0;h<u;h+=3)for(var m=c[h>>>2]>>>24-h%4*8&255,p=c[h+1>>>2]>>>24-(h+1)%4*8&255,g=c[h+2>>>2]>>>24-(h+2)%4*8&255,v=m<<16|p<<8|g,y=0;y<4&&h+y*.75<u;y++)f.push(d.charAt(v>>>6*(3-y)&63));var b=d.charAt(64);if(b)for(;f.length%4;)f.push(b);return f.join("")},parse:function(l){var c=l.length,u=this._map,d=this._reverseMap;if(!d){d=this._reverseMap=[];for(var f=0;f<u.length;f++)d[u.charCodeAt(f)]=f}var h=u.charAt(64);if(h){var m=l.indexOf(h);m!==-1&&(c=m)}return s(l,c,d)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function s(l,c,u){for(var d=[],f=0,h=0;h<c;h++)if(h%4){var m=u[l.charCodeAt(h-1)]<<h%4*2,p=u[l.charCodeAt(h)]>>>6-h%4*2,g=m|p;d[f>>>2]|=g<<24-f%4*8,f++}return i.create(d,f)}})(),n.enc.Base64})})(Ah)),Ah.exports}var $h={exports:{}},xxe=$h.exports,XT;function Exe(){return XT||(XT=1,(function(e,t){(function(n,r){e.exports=r(En())})(xxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.enc;a.Base64url={stringify:function(l,c){c===void 0&&(c=!0);var u=l.words,d=l.sigBytes,f=c?this._safe_map:this._map;l.clamp();for(var h=[],m=0;m<d;m+=3)for(var p=u[m>>>2]>>>24-m%4*8&255,g=u[m+1>>>2]>>>24-(m+1)%4*8&255,v=u[m+2>>>2]>>>24-(m+2)%4*8&255,y=p<<16|g<<8|v,b=0;b<4&&m+b*.75<d;b++)h.push(f.charAt(y>>>6*(3-b)&63));var w=f.charAt(64);if(w)for(;h.length%4;)h.push(w);return h.join("")},parse:function(l,c){c===void 0&&(c=!0);var u=l.length,d=c?this._safe_map:this._map,f=this._reverseMap;if(!f){f=this._reverseMap=[];for(var h=0;h<d.length;h++)f[d.charCodeAt(h)]=h}var m=d.charAt(64);if(m){var p=l.indexOf(m);p!==-1&&(u=p)}return s(l,u,f)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function s(l,c,u){for(var d=[],f=0,h=0;h<c;h++)if(h%4){var m=u[l.charCodeAt(h-1)]<<h%4*2,p=u[l.charCodeAt(h)]>>>6-h%4*2,g=m|p;d[f>>>2]|=g<<24-f%4*8,f++}return i.create(d,f)}})(),n.enc.Base64url})})($h)),$h.exports}var Oh={exports:{}},wxe=Oh.exports,KT;function $l(){return KT||(KT=1,(function(e,t){(function(n,r){e.exports=r(En())})(wxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.algo,c=[];(function(){for(var p=0;p<64;p++)c[p]=r.abs(r.sin(p+1))*4294967296|0})();var u=l.MD5=s.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(p,g){for(var v=0;v<16;v++){var y=g+v,b=p[y];p[y]=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360}var w=this._hash.words,x=p[g+0],E=p[g+1],k=p[g+2],S=p[g+3],O=p[g+4],A=p[g+5],$=p[g+6],M=p[g+7],N=p[g+8],D=p[g+9],T=p[g+10],P=p[g+11],I=p[g+12],R=p[g+13],H=p[g+14],V=p[g+15],L=w[0],j=w[1],_=w[2],F=w[3];L=d(L,j,_,F,x,7,c[0]),F=d(F,L,j,_,E,12,c[1]),_=d(_,F,L,j,k,17,c[2]),j=d(j,_,F,L,S,22,c[3]),L=d(L,j,_,F,O,7,c[4]),F=d(F,L,j,_,A,12,c[5]),_=d(_,F,L,j,$,17,c[6]),j=d(j,_,F,L,M,22,c[7]),L=d(L,j,_,F,N,7,c[8]),F=d(F,L,j,_,D,12,c[9]),_=d(_,F,L,j,T,17,c[10]),j=d(j,_,F,L,P,22,c[11]),L=d(L,j,_,F,I,7,c[12]),F=d(F,L,j,_,R,12,c[13]),_=d(_,F,L,j,H,17,c[14]),j=d(j,_,F,L,V,22,c[15]),L=f(L,j,_,F,E,5,c[16]),F=f(F,L,j,_,$,9,c[17]),_=f(_,F,L,j,P,14,c[18]),j=f(j,_,F,L,x,20,c[19]),L=f(L,j,_,F,A,5,c[20]),F=f(F,L,j,_,T,9,c[21]),_=f(_,F,L,j,V,14,c[22]),j=f(j,_,F,L,O,20,c[23]),L=f(L,j,_,F,D,5,c[24]),F=f(F,L,j,_,H,9,c[25]),_=f(_,F,L,j,S,14,c[26]),j=f(j,_,F,L,N,20,c[27]),L=f(L,j,_,F,R,5,c[28]),F=f(F,L,j,_,k,9,c[29]),_=f(_,F,L,j,M,14,c[30]),j=f(j,_,F,L,I,20,c[31]),L=h(L,j,_,F,A,4,c[32]),F=h(F,L,j,_,N,11,c[33]),_=h(_,F,L,j,P,16,c[34]),j=h(j,_,F,L,H,23,c[35]),L=h(L,j,_,F,E,4,c[36]),F=h(F,L,j,_,O,11,c[37]),_=h(_,F,L,j,M,16,c[38]),j=h(j,_,F,L,T,23,c[39]),L=h(L,j,_,F,R,4,c[40]),F=h(F,L,j,_,x,11,c[41]),_=h(_,F,L,j,S,16,c[42]),j=h(j,_,F,L,$,23,c[43]),L=h(L,j,_,F,D,4,c[44]),F=h(F,L,j,_,I,11,c[45]),_=h(_,F,L,j,V,16,c[46]),j=h(j,_,F,L,k,23,c[47]),L=m(L,j,_,F,x,6,c[48]),F=m(F,L,j,_,M,10,c[49]),_=m(_,F,L,j,H,15,c[50]),j=m(j,_,F,L,A,21,c[51]),L=m(L,j,_,F,I,6,c[52]),F=m(F,L,j,_,S,10,c[53]),_=m(_,F,L,j,T,15,c[54]),j=m(j,_,F,L,E,21,c[55]),L=m(L,j,_,F,N,6,c[56]),F=m(F,L,j,_,V,10,c[57]),_=m(_,F,L,j,$,15,c[58]),j=m(j,_,F,L,R,21,c[59]),L=m(L,j,_,F,O,6,c[60]),F=m(F,L,j,_,P,10,c[61]),_=m(_,F,L,j,k,15,c[62]),j=m(j,_,F,L,D,21,c[63]),w[0]=w[0]+L|0,w[1]=w[1]+j|0,w[2]=w[2]+_|0,w[3]=w[3]+F|0},_doFinalize:function(){var p=this._data,g=p.words,v=this._nDataBytes*8,y=p.sigBytes*8;g[y>>>5]|=128<<24-y%32;var b=r.floor(v/4294967296),w=v;g[(y+64>>>9<<4)+15]=(b<<8|b>>>24)&16711935|(b<<24|b>>>8)&4278255360,g[(y+64>>>9<<4)+14]=(w<<8|w>>>24)&16711935|(w<<24|w>>>8)&4278255360,p.sigBytes=(g.length+1)*4,this._process();for(var x=this._hash,E=x.words,k=0;k<4;k++){var S=E[k];E[k]=(S<<8|S>>>24)&16711935|(S<<24|S>>>8)&4278255360}return x},clone:function(){var p=s.clone.call(this);return p._hash=this._hash.clone(),p}});function d(p,g,v,y,b,w,x){var E=p+(g&v|~g&y)+b+x;return(E<<w|E>>>32-w)+g}function f(p,g,v,y,b,w,x){var E=p+(g&y|v&~y)+b+x;return(E<<w|E>>>32-w)+g}function h(p,g,v,y,b,w,x){var E=p+(g^v^y)+b+x;return(E<<w|E>>>32-w)+g}function m(p,g,v,y,b,w,x){var E=p+(v^(g|~y))+b+x;return(E<<w|E>>>32-w)+g}o.MD5=s._createHelper(u),o.HmacMD5=s._createHmacHelper(u)})(Math),n.MD5})})(Oh)),Oh.exports}var Mh={exports:{}},Cxe=Mh.exports,ZT;function Dz(){return ZT||(ZT=1,(function(e,t){(function(n,r){e.exports=r(En())})(Cxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=o.Hasher,s=r.algo,l=[],c=s.SHA1=a.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(u,d){for(var f=this._hash.words,h=f[0],m=f[1],p=f[2],g=f[3],v=f[4],y=0;y<80;y++){if(y<16)l[y]=u[d+y]|0;else{var b=l[y-3]^l[y-8]^l[y-14]^l[y-16];l[y]=b<<1|b>>>31}var w=(h<<5|h>>>27)+v+l[y];y<20?w+=(m&p|~m&g)+1518500249:y<40?w+=(m^p^g)+1859775393:y<60?w+=(m&p|m&g|p&g)-1894007588:w+=(m^p^g)-899497514,v=g,g=p,p=m<<30|m>>>2,m=h,h=w}f[0]=f[0]+h|0,f[1]=f[1]+m|0,f[2]=f[2]+p|0,f[3]=f[3]+g|0,f[4]=f[4]+v|0},_doFinalize:function(){var u=this._data,d=u.words,f=this._nDataBytes*8,h=u.sigBytes*8;return d[h>>>5]|=128<<24-h%32,d[(h+64>>>9<<4)+14]=Math.floor(f/4294967296),d[(h+64>>>9<<4)+15]=f,u.sigBytes=d.length*4,this._process(),this._hash},clone:function(){var u=a.clone.call(this);return u._hash=this._hash.clone(),u}});r.SHA1=a._createHelper(c),r.HmacSHA1=a._createHmacHelper(c)})(),n.SHA1})})(Mh)),Mh.exports}var Nh={exports:{}},kxe=Nh.exports,QT;function FS(){return QT||(QT=1,(function(e,t){(function(n,r){e.exports=r(En())})(kxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.algo,c=[],u=[];(function(){function h(v){for(var y=r.sqrt(v),b=2;b<=y;b++)if(!(v%b))return!1;return!0}function m(v){return(v-(v|0))*4294967296|0}for(var p=2,g=0;g<64;)h(p)&&(g<8&&(c[g]=m(r.pow(p,1/2))),u[g]=m(r.pow(p,1/3)),g++),p++})();var d=[],f=l.SHA256=s.extend({_doReset:function(){this._hash=new a.init(c.slice(0))},_doProcessBlock:function(h,m){for(var p=this._hash.words,g=p[0],v=p[1],y=p[2],b=p[3],w=p[4],x=p[5],E=p[6],k=p[7],S=0;S<64;S++){if(S<16)d[S]=h[m+S]|0;else{var O=d[S-15],A=(O<<25|O>>>7)^(O<<14|O>>>18)^O>>>3,$=d[S-2],M=($<<15|$>>>17)^($<<13|$>>>19)^$>>>10;d[S]=A+d[S-7]+M+d[S-16]}var N=w&x^~w&E,D=g&v^g&y^v&y,T=(g<<30|g>>>2)^(g<<19|g>>>13)^(g<<10|g>>>22),P=(w<<26|w>>>6)^(w<<21|w>>>11)^(w<<7|w>>>25),I=k+P+N+u[S]+d[S],R=T+D;k=E,E=x,x=w,w=b+I|0,b=y,y=v,v=g,g=I+R|0}p[0]=p[0]+g|0,p[1]=p[1]+v|0,p[2]=p[2]+y|0,p[3]=p[3]+b|0,p[4]=p[4]+w|0,p[5]=p[5]+x|0,p[6]=p[6]+E|0,p[7]=p[7]+k|0},_doFinalize:function(){var h=this._data,m=h.words,p=this._nDataBytes*8,g=h.sigBytes*8;return m[g>>>5]|=128<<24-g%32,m[(g+64>>>9<<4)+14]=r.floor(p/4294967296),m[(g+64>>>9<<4)+15]=p,h.sigBytes=m.length*4,this._process(),this._hash},clone:function(){var h=s.clone.call(this);return h._hash=this._hash.clone(),h}});o.SHA256=s._createHelper(f),o.HmacSHA256=s._createHmacHelper(f)})(Math),n.SHA256})})(Nh)),Nh.exports}var Dh={exports:{}},Sxe=Dh.exports,JT;function Axe(){return JT||(JT=1,(function(e,t){(function(n,r,o){e.exports=r(En(),FS())})(Sxe,function(n){return(function(){var r=n,o=r.lib,i=o.WordArray,a=r.algo,s=a.SHA256,l=a.SHA224=s.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var c=s._doFinalize.call(this);return c.sigBytes-=4,c}});r.SHA224=s._createHelper(l),r.HmacSHA224=s._createHmacHelper(l)})(),n.SHA224})})(Dh)),Dh.exports}var Th={exports:{}},$xe=Th.exports,eF;function Tz(){return eF||(eF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug())})($xe,function(n){return(function(){var r=n,o=r.lib,i=o.Hasher,a=r.x64,s=a.Word,l=a.WordArray,c=r.algo;function u(){return s.create.apply(s,arguments)}var d=[u(1116352408,3609767458),u(1899447441,602891725),u(3049323471,3964484399),u(3921009573,2173295548),u(961987163,4081628472),u(1508970993,3053834265),u(2453635748,2937671579),u(2870763221,3664609560),u(3624381080,2734883394),u(310598401,1164996542),u(607225278,1323610764),u(1426881987,3590304994),u(1925078388,4068182383),u(2162078206,991336113),u(2614888103,633803317),u(3248222580,3479774868),u(3835390401,2666613458),u(4022224774,944711139),u(264347078,2341262773),u(604807628,2007800933),u(770255983,1495990901),u(1249150122,1856431235),u(1555081692,3175218132),u(1996064986,2198950837),u(2554220882,3999719339),u(2821834349,766784016),u(2952996808,2566594879),u(3210313671,3203337956),u(3336571891,1034457026),u(3584528711,2466948901),u(113926993,3758326383),u(338241895,168717936),u(666307205,1188179964),u(773529912,1546045734),u(1294757372,1522805485),u(1396182291,2643833823),u(1695183700,2343527390),u(1986661051,1014477480),u(2177026350,1206759142),u(2456956037,344077627),u(2730485921,1290863460),u(2820302411,3158454273),u(3259730800,3505952657),u(3345764771,106217008),u(3516065817,3606008344),u(3600352804,1432725776),u(4094571909,1467031594),u(275423344,851169720),u(430227734,3100823752),u(506948616,1363258195),u(659060556,3750685593),u(883997877,3785050280),u(958139571,3318307427),u(1322822218,3812723403),u(1537002063,2003034995),u(1747873779,3602036899),u(1955562222,1575990012),u(2024104815,1125592928),u(2227730452,2716904306),u(2361852424,442776044),u(2428436474,593698344),u(2756734187,3733110249),u(3204031479,2999351573),u(3329325298,3815920427),u(3391569614,3928383900),u(3515267271,566280711),u(3940187606,3454069534),u(4118630271,4000239992),u(116418474,1914138554),u(174292421,2731055270),u(289380356,3203993006),u(460393269,320620315),u(685471733,587496836),u(852142971,1086792851),u(1017036298,365543100),u(1126000580,2618297676),u(1288033470,3409855158),u(1501505948,4234509866),u(1607167915,987167468),u(1816402316,1246189591)],f=[];(function(){for(var m=0;m<80;m++)f[m]=u()})();var h=c.SHA512=i.extend({_doReset:function(){this._hash=new l.init([new s.init(1779033703,4089235720),new s.init(3144134277,2227873595),new s.init(1013904242,4271175723),new s.init(2773480762,1595750129),new s.init(1359893119,2917565137),new s.init(2600822924,725511199),new s.init(528734635,4215389547),new s.init(1541459225,327033209)])},_doProcessBlock:function(m,p){for(var g=this._hash.words,v=g[0],y=g[1],b=g[2],w=g[3],x=g[4],E=g[5],k=g[6],S=g[7],O=v.high,A=v.low,$=y.high,M=y.low,N=b.high,D=b.low,T=w.high,P=w.low,I=x.high,R=x.low,H=E.high,V=E.low,L=k.high,j=k.low,_=S.high,F=S.low,B=O,z=A,G=$,W=M,q=N,U=D,Y=T,ie=P,K=I,re=R,oe=H,ne=V,ae=L,de=j,ge=_,Se=F,ye=0;ye<80;ye++){var be,ce,he=f[ye];if(ye<16)ce=he.high=m[p+ye*2]|0,be=he.low=m[p+ye*2+1]|0;else{var Te=f[ye-15],se=Te.high,Pe=Te.low,De=(se>>>1|Pe<<31)^(se>>>8|Pe<<24)^se>>>7,He=(Pe>>>1|se<<31)^(Pe>>>8|se<<24)^(Pe>>>7|se<<25),ue=f[ye-2],ve=ue.high,xe=ue.low,fe=(ve>>>19|xe<<13)^(ve<<3|xe>>>29)^ve>>>6,pe=(xe>>>19|ve<<13)^(xe<<3|ve>>>29)^(xe>>>6|ve<<26),ke=f[ye-7],Ve=ke.high,Ee=ke.low,yt=f[ye-16],Dt=yt.high,Pt=yt.low;be=He+Ee,ce=De+Ve+(be>>>0<He>>>0?1:0),be=be+pe,ce=ce+fe+(be>>>0<pe>>>0?1:0),be=be+Pt,ce=ce+Dt+(be>>>0<Pt>>>0?1:0),he.high=ce,he.low=be}var Ut=K&oe^~K&ae,Ge=re&ne^~re&de,Xe=B&G^B&q^G&q,qe=z&W^z&U^W&U,lt=(B>>>28|z<<4)^(B<<30|z>>>2)^(B<<25|z>>>7),je=(z>>>28|B<<4)^(z<<30|B>>>2)^(z<<25|B>>>7),Rt=(K>>>14|re<<18)^(K>>>18|re<<14)^(K<<23|re>>>9),zt=(re>>>14|K<<18)^(re>>>18|K<<14)^(re<<23|K>>>9),dt=d[ye],Ct=dt.high,jt=dt.low,Ie=Se+zt,Ne=ge+Rt+(Ie>>>0<Se>>>0?1:0),Ie=Ie+Ge,Ne=Ne+Ut+(Ie>>>0<Ge>>>0?1:0),Ie=Ie+jt,Ne=Ne+Ct+(Ie>>>0<jt>>>0?1:0),Ie=Ie+be,Ne=Ne+ce+(Ie>>>0<be>>>0?1:0),Oe=je+qe,_e=lt+Xe+(Oe>>>0<je>>>0?1:0);ge=ae,Se=de,ae=oe,de=ne,oe=K,ne=re,re=ie+Ie|0,K=Y+Ne+(re>>>0<ie>>>0?1:0)|0,Y=q,ie=U,q=G,U=W,G=B,W=z,z=Ie+Oe|0,B=Ne+_e+(z>>>0<Ie>>>0?1:0)|0}A=v.low=A+z,v.high=O+B+(A>>>0<z>>>0?1:0),M=y.low=M+W,y.high=$+G+(M>>>0<W>>>0?1:0),D=b.low=D+U,b.high=N+q+(D>>>0<U>>>0?1:0),P=w.low=P+ie,w.high=T+Y+(P>>>0<ie>>>0?1:0),R=x.low=R+re,x.high=I+K+(R>>>0<re>>>0?1:0),V=E.low=V+ne,E.high=H+oe+(V>>>0<ne>>>0?1:0),j=k.low=j+de,k.high=L+ae+(j>>>0<de>>>0?1:0),F=S.low=F+Se,S.high=_+ge+(F>>>0<Se>>>0?1:0)},_doFinalize:function(){var m=this._data,p=m.words,g=this._nDataBytes*8,v=m.sigBytes*8;p[v>>>5]|=128<<24-v%32,p[(v+128>>>10<<5)+30]=Math.floor(g/4294967296),p[(v+128>>>10<<5)+31]=g,m.sigBytes=p.length*4,this._process();var y=this._hash.toX32();return y},clone:function(){var m=i.clone.call(this);return m._hash=this._hash.clone(),m},blockSize:1024/32});r.SHA512=i._createHelper(h),r.HmacSHA512=i._createHmacHelper(h)})(),n.SHA512})})(Th)),Th.exports}var Fh={exports:{}},Oxe=Fh.exports,tF;function Mxe(){return tF||(tF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug(),Tz())})(Oxe,function(n){return(function(){var r=n,o=r.x64,i=o.Word,a=o.WordArray,s=r.algo,l=s.SHA512,c=s.SHA384=l.extend({_doReset:function(){this._hash=new a.init([new i.init(3418070365,3238371032),new i.init(1654270250,914150663),new i.init(2438529370,812702999),new i.init(355462360,4144912697),new i.init(1731405415,4290775857),new i.init(2394180231,1750603025),new i.init(3675008525,1694076839),new i.init(1203062813,3204075428)])},_doFinalize:function(){var u=l._doFinalize.call(this);return u.sigBytes-=16,u}});r.SHA384=l._createHelper(c),r.HmacSHA384=l._createHmacHelper(c)})(),n.SHA384})})(Fh)),Fh.exports}var Ph={exports:{}},Nxe=Ph.exports,nF;function Dxe(){return nF||(nF=1,(function(e,t){(function(n,r,o){e.exports=r(En(),Ug())})(Nxe,function(n){return(function(r){var o=n,i=o.lib,a=i.WordArray,s=i.Hasher,l=o.x64,c=l.Word,u=o.algo,d=[],f=[],h=[];(function(){for(var g=1,v=0,y=0;y<24;y++){d[g+5*v]=(y+1)*(y+2)/2%64;var b=v%5,w=(2*g+3*v)%5;g=b,v=w}for(var g=0;g<5;g++)for(var v=0;v<5;v++)f[g+5*v]=v+(2*g+3*v)%5*5;for(var x=1,E=0;E<24;E++){for(var k=0,S=0,O=0;O<7;O++){if(x&1){var A=(1<<O)-1;A<32?S^=1<<A:k^=1<<A-32}x&128?x=x<<1^113:x<<=1}h[E]=c.create(k,S)}})();var m=[];(function(){for(var g=0;g<25;g++)m[g]=c.create()})();var p=u.SHA3=s.extend({cfg:s.cfg.extend({outputLength:512}),_doReset:function(){for(var g=this._state=[],v=0;v<25;v++)g[v]=new c.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(g,v){for(var y=this._state,b=this.blockSize/2,w=0;w<b;w++){var x=g[v+2*w],E=g[v+2*w+1];x=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,E=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360;var k=y[w];k.high^=E,k.low^=x}for(var S=0;S<24;S++){for(var O=0;O<5;O++){for(var A=0,$=0,M=0;M<5;M++){var k=y[O+5*M];A^=k.high,$^=k.low}var N=m[O];N.high=A,N.low=$}for(var O=0;O<5;O++)for(var D=m[(O+4)%5],T=m[(O+1)%5],P=T.high,I=T.low,A=D.high^(P<<1|I>>>31),$=D.low^(I<<1|P>>>31),M=0;M<5;M++){var k=y[O+5*M];k.high^=A,k.low^=$}for(var R=1;R<25;R++){var A,$,k=y[R],H=k.high,V=k.low,L=d[R];L<32?(A=H<<L|V>>>32-L,$=V<<L|H>>>32-L):(A=V<<L-32|H>>>64-L,$=H<<L-32|V>>>64-L);var j=m[f[R]];j.high=A,j.low=$}var _=m[0],F=y[0];_.high=F.high,_.low=F.low;for(var O=0;O<5;O++)for(var M=0;M<5;M++){var R=O+5*M,k=y[R],B=m[R],z=m[(O+1)%5+5*M],G=m[(O+2)%5+5*M];k.high=B.high^~z.high&G.high,k.low=B.low^~z.low&G.low}var k=y[0],W=h[S];k.high^=W.high,k.low^=W.low}},_doFinalize:function(){var g=this._data,v=g.words;this._nDataBytes*8;var y=g.sigBytes*8,b=this.blockSize*32;v[y>>>5]|=1<<24-y%32,v[(r.ceil((y+1)/b)*b>>>5)-1]|=128,g.sigBytes=v.length*4,this._process();for(var w=this._state,x=this.cfg.outputLength/8,E=x/8,k=[],S=0;S<E;S++){var O=w[S],A=O.high,$=O.low;A=(A<<8|A>>>24)&16711935|(A<<24|A>>>8)&4278255360,$=($<<8|$>>>24)&16711935|($<<24|$>>>8)&4278255360,k.push($),k.push(A)}return new a.init(k,x)},clone:function(){for(var g=s.clone.call(this),v=g._state=this._state.slice(0),y=0;y<25;y++)v[y]=v[y].clone();return g}});o.SHA3=s._createHelper(p),o.HmacSHA3=s._createHmacHelper(p)})(Math),n.SHA3})})(Ph)),Ph.exports}var Ih={exports:{}},Txe=Ih.exports,rF;function Fxe(){return rF||(rF=1,(function(e,t){(function(n,r){e.exports=r(En())})(Txe,function(n){/** @preserve
|
|
794
794
|
(c) 2012 by Cédric Mesnil. All rights reserved.
|
|
795
795
|
|
|
796
796
|
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
|