// ==UserScript== // @name bilibili-app-recommend // @namespace https://magicdawn.fun // @version 0.10.0 // @author magicdawn // @description 为B站首页添加像App一样的推荐 // @license MIT // @homepageURL https://greasyfork.org/zh-CN/scripts/443530-bilibili-app-recommend // @supportURL https://github.com/magicdawn/bilibili-app-recommend/issues // @match *://www.bilibili.com/ // @match *://www.bilibili.com/?* // @match https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png // @match https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?* // @require https://unpkg.com/axios@0.27.2/dist/axios.min.js // @require https://unpkg.com/axios-userscript-adapter@0.2.0/dist/axiosGmxhrAdapter.min.js // @require https://unpkg.com/react@18.2.0/umd/react.production.min.js // @require https://unpkg.com/react-dom@18.2.0/umd/react-dom.production.min.js // @connect app.bilibili.com // @connect passport.bilibili.com // @connect link.acg.tv // @connect www.mcbbs.net // @grant GM.xmlHttpRequest // @grant GM_deleteValue // @grant GM_getValue // @grant GM_setValue // @downloadURL none // ==/UserScript== (i=>{const e=document.createElement("style");e.dataset.source="vite-plugin-monkey",e.innerText=i,document.head.appendChild(e)})(` .primary-btn:disabled:active,.primary-btn:disabled:hover{cursor:wait;background-color:inherit}.ant-btn{font-size:13px}.ant-btn:disabled{cursor:wait}._modal-mask_qk630_1{position:fixed;left:0;top:0;right:0;bottom:0;background-color:#00000080;z-index:11003;display:flex;align-items:center;justify-content:center}._modal_qk630_1{width:500px;max-height:calc(90vh - 50px);background-color:#fff;border-radius:10px;padding:0 15px 15px;display:flex;flex-direction:column;overflow:hidden}._modal-header_qk630_23{padding-top:10px;padding-bottom:10px;border-bottom:none;display:flex;align-items:center}._modal-body_qk630_30{padding-top:0;flex-grow:1;overflow-y:scroll}._modal-title_qk630_35{font-size:1.5rem;margin-bottom:0;line-height:1.5;display:flex;align-items:center}._btn-close_qk630_42{margin-left:10px}._btn-close_qk630_42 svg{width:10px;height:10px;margin-right:3px;margin-top:-1px}body.dark ._btn-close_qk630_42{color:#eee!important;background-color:#333!important;border-color:transparent!important;height:auto;padding:8px 12px;line-height:16px;font-size:13px}._toast-container_mcbuq_1{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);z-index:999999;padding:12px 24px;font-size:14px;min-width:200px;width:max-content;max-width:450px;background:#ffb243;color:#fff;border-radius:6px;white-space:pre-wrap}._toast-container_mcbuq_1._single-line_mcbuq_17{text-align:center}._modal_1rloz_1{width:500px}._title-desc_1rloz_4{margin-left:5px;font-size:40%}._reason-list_1rloz_8{display:flex;align-items:center;flex-wrap:wrap;justify-content:space-between}._reason_1rloz_8{color:inherit;width:48%;text-align:center;line-height:20px;position:relative;border:1px solid #eee;padding-top:5px;padding-bottom:5px;margin-top:5px;margin-bottom:5px}body.dark ._reason_1rloz_8{border:1px solid #333}._reason_1rloz_8._active_1rloz_29{border-color:#f69;border-radius:4px}._reason-no_1rloz_33{position:absolute;left:6px;width:20px;height:20px;border-radius:50%;top:6px;display:flex;align-items:center;justify-content:center;background-color:#6a5acd;background-color:#f69;color:#fff}._tips-container_1rloz_47{margin-top:20px}._tips_1rloz_47{display:flex;align-items:center}._bili-video-card_e62cr_1{position:relative}._image-wrapper_e62cr_4{border-radius:6px;overflow:hidden}._preview-card-wrapper_e62cr_8{position:absolute;top:0;left:0;right:0;bottom:0;z-index:4;overflow:hidden;border-top-left-radius:inherit;border-top-right-radius:inherit;border-bottom-left-radius:0;border-bottom-right-radius:0}._preview-card-wrapper_e62cr_8 ._preview-card-inner_e62cr_21{width:100%;height:100%}._watch-later_e62cr_25{z-index:5}._badge_e62cr_28{color:#fa6a9d;border-radius:2px;border:1px #fa6a9d solid;line-height:20px;padding:0 10px;transform:scale(.8)}._recommend-reason_e62cr_36{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;display:inline-block;color:var(--Or5);background-color:var(--Or1);border-radius:4px;margin-right:4px;font-size:var(--follow-icon-font-size);line-height:var(--follow-icon-line-height);height:var(--follow-icon-line-height);padding:0 4px;cursor:default}._bangumi-desc_e62cr_51{color:default}._btn-dislike_e62cr_54{display:flex;align-items:center;justify-content:center;position:absolute;top:8px;left:8px;width:28px;height:28px;border-radius:6px;cursor:pointer;background-color:#212121cc;z-index:9;transform:translateZ(0)}._btn-dislike_e62cr_54 ._btn-dislike-icon_e62cr_69{pointer-events:none;user-select:none;width:12px;height:12px;color:#fff}._btn-dislike_e62cr_54 ._btn-dislike-tip_e62cr_76{pointer-events:none;user-select:none;position:absolute;bottom:-6px;left:-5px;transform:translateY(100%);font-size:12px;color:#fff;border-radius:4px;line-height:18px;padding:4px 8px;background-color:#000c;white-space:nowrap}._disliked-wrapper_e62cr_91{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column;border-radius:6px;border:1px solid #eee}body.dark ._disliked-wrapper_e62cr_91{border:1px solid #333}._disliked-wrapper_e62cr_91 ._dislike-content-cover_e62cr_105{border-top-left-radius:6px;border-top-right-radius:6px;padding-top:56.25%;position:relative}._disliked-wrapper_e62cr_91 ._dislike-content-cover_e62cr_105 ._dislike-content-cover-inner_e62cr_111{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center}._disliked-wrapper_e62cr_91 ._dislike-content-cover_e62cr_105 ._dislike-content-cover-inner_e62cr_111 ._dislike-icon_e62cr_122{margin-bottom:5px}._disliked-wrapper_e62cr_91 ._dislike-content-cover_e62cr_105 ._dislike-content-cover-inner_e62cr_111 ._dislike-reason_e62cr_125{font-size:20px;text-align:center}._disliked-wrapper_e62cr_91 ._dislike-content-cover_e62cr_105 ._dislike-content-cover-inner_e62cr_111 ._dislike-desc_e62cr_129{font-size:16px;text-align:center}._disliked-wrapper_e62cr_91 ._dislike-content-action_e62cr_133{flex:1;width:100%;border-top:1px solid #eee;display:flex;align-items:center;justify-content:center}body.dark ._disliked-wrapper_e62cr_91 ._dislike-content-action_e62cr_133{border-top:1px solid #333}._disliked-wrapper_e62cr_91 ._dislike-content-action_e62cr_133 button{font-size:16px;color:inherit;display:flex;align-items:center}._skeleton-active_e62cr_150 .bili-video-card__skeleton--cover,._skeleton-active_e62cr_150 .bili-video-card__skeleton--text,._skeleton-active_e62cr_150 .bili-video-card__skeleton--light{background:linear-gradient(135deg,rgba(0,0,0,.06) 25%,rgba(0,0,0,.15) 37%,rgba(0,0,0,.06) 63%);background-size:400% 100%;animation-name:_ant-skeleton-loading_e62cr_1;animation-duration:1.4s;animation-timing-function:ease;animation-iteration-count:infinite}@keyframes _ant-skeleton-loading_e62cr_1{0%{background-position:100% 50%}to{background-position:0 50%}}._video-grid_14t5i_9{display:grid;position:relative;width:100%;grid-gap:20px 12px}@media (max-width: 1099.9px){._video-grid_14t5i_9{grid-template-columns:repeat(4,1fr)}._video-grid_14t5i_9._limit-two-lines_14t5i_19>*:nth-of-type(1n + 9){display:none!important}}@media (min-width: 1100px) and (max-width: 1700.9px){._video-grid_14t5i_9{grid-template-columns:repeat(5,1fr)}._video-grid_14t5i_9._limit-two-lines_14t5i_19>*:nth-of-type(1n + 11){display:none!important}}@media (min-width: 1701px){._video-grid_14t5i_9{grid-template-columns:repeat(6,1fr)}._video-grid_14t5i_9._limit-two-lines_14t5i_19>*:nth-of-type(1n + 13){display:none!important}}._video-grid_14t5i_9._internal-testing_14t5i_43{grid-gap:20px 20px}@media (max-width: 1399.9px){._video-grid_14t5i_9._internal-testing_14t5i_43{grid-template-columns:repeat(4,1fr)}._video-grid_14t5i_9._internal-testing_14t5i_43._limit-one-line_14t5i_50>*:nth-of-type(1n + 5){display:none!important}._video-grid_14t5i_9._internal-testing_14t5i_43._limit-two-lines_14t5i_19>*:nth-of-type(1n + 9){display:none!important}}@media (min-width: 1400px){._video-grid_14t5i_9._internal-testing_14t5i_43{grid-template-columns:repeat(5,1fr)}._video-grid_14t5i_9._internal-testing_14t5i_43._limit-one-line_14t5i_50>*:nth-of-type(1n + 6){display:none!important}._video-grid_14t5i_9._internal-testing_14t5i_43._limit-two-lines_14t5i_19>*:nth-of-type(1n + 11){display:none!important}}._narrow-mode_14t5i_71{grid-template-columns:repeat(2,1fr)!important}._config-icon_1d50l_1{line-height:1;margin-right:5px;font-size:0}._settings-group_1d50l_6{margin-bottom:10px}._settings-group_1d50l_6 ._settings-group-title_1d50l_9{font-size:2em}._settings-group_1d50l_6 ._settings-group-content_1d50l_12{color:default}._settings-group_1d50l_6 ._settings-group-content_1d50l_12 button:first-child{margin-left:0}._row_1d50l_18{display:flex;align-items:center;flex-wrap:wrap}._row_1d50l_18 .primary-btn:first-child{margin-left:0}._check_1d50l_26{margin-bottom:5px;margin-inline-start:0!important;margin-inline-end:5px!important}._expand-btn_wdzp9_1{padding:0;width:31px;height:31px;border-radius:50%}._expand-btn_wdzp9_1 svg{width:13px;height:13px;transform:rotate(180deg)}._expand-btn_wdzp9_1 svg._expanded_wdzp9_12{transform:rotate(0)}body.dark ._expand-btn_wdzp9_1{color:#eee!important;border-color:transparent!important;background-color:#333!important}body.dark ._expand-btn_wdzp9_1:hover{background-color:#555!important}._modal-mask_juq7d_1._narrow-mode_juq7d_1{background-color:#000000e6}._modal_juq7d_1{width:calc(100vw - 30px);height:calc(100vh - 30px);max-height:unset;padding-right:0}body.dark ._modal_juq7d_1{border:1px solid #ff6699}._modal_juq7d_1._narrow-mode_juq7d_1{width:606px;height:calc(100vh - 10px);border:none}body.dark ._modal_juq7d_1._narrow-mode_juq7d_1{border:none}._modal-header_juq7d_21,._modal-body_juq7d_22{padding-right:15px}body.dark ._btn-refresh_juq7d_25{color:#eee!important;background-color:#333!important;border-color:transparent!important;height:auto;padding:8px 12px;line-height:16px;font-size:13px} `); var NM=Object.defineProperty;var IM=(T,ve,ze)=>ve in T?NM(T,ve,{enumerable:!0,configurable:!0,writable:!0,value:ze}):T[ve]=ze;var Ze=(T,ve,ze)=>(IM(T,typeof ve!="symbol"?ve+"":ve,ze),ze),df=(T,ve,ze)=>{if(!ve.has(T))throw TypeError("Cannot "+ze)};var O=(T,ve,ze)=>(df(T,ve,"read from private field"),ze?ze.call(T):ve.get(T)),ue=(T,ve,ze)=>{if(ve.has(T))throw TypeError("Cannot add the same private member more than once");ve instanceof WeakSet?ve.add(T):ve.set(T,ze)},ee=(T,ve,ze,Wn)=>(df(T,ve,"write to private field"),Wn?Wn.call(T,ze):ve.set(T,ze),ze),Vs=(T,ve,ze,Wn)=>({set _(qi){ee(T,ve,qi,ze)},get _(){return O(T,ve,Wn)}}),Z=(T,ve,ze)=>(df(T,ve,"access private method"),ze);(function(T,ve,ze,Wn){var Po,Qt,It,xr,Jt,ko,tt,er,rt,je,ie,yt,Lt,gt,at,tr,ut,Vr,Ur,rr,_r,hn,_t,Li,hf,Nn,Gr,ji,jt,Is,Dv,In,Mo,Di,Or,vn,$r,bn,zi,gf,Ao,Us,Ro,Gs,Re,Ve,Hi,mf,Ln,Gi;"use strict";function qi(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const h=qi(T),Hv=qi(ve);function Bv(e){if(e.sheet)return e.sheet;for(var t=0;t0?ct(Un,--St):0,Vn--,Ye===10&&(Vn=1,Zi--),Ye}function Pt(){return Ye=St2||Vo(Ye)>3?"":" "}function eb(e,t){for(;--t&&Pt()&&!(Ye<48||Ye>102||Ye>57&&Ye<65||Ye>70&&Ye<97););return Wo(e,Ji()+(t<6&&ur()==32&&Pt()==32))}function Zs(e){for(;Pt();)switch(Ye){case e:return St;case 34:case 39:e!==34&&e!==39&&Zs(Ye);break;case 40:e===41&&Zs(e);break;case 92:Pt();break}return St}function tb(e,t){for(;Pt()&&e+Ye!==47+10;)if(e+Ye===42+42&&ur()===47)break;return"/*"+Wo(t,St-1)+"*"+Xi(e===47?e:Pt())}function rb(e){for(;!Vo(ur());)Pt();return Wo(e,St)}function Cf(e){return Sf(ta("",null,null,null,[""],e=wf(e),0,[0],e))}function ta(e,t,r,n,o,i,a,s,c){for(var l=0,u=0,f=a,d=0,g=0,v=0,m=1,p=1,b=1,w=0,E="",$=o,S=i,y=n,_=E;p;)switch(v=w,w=Pt()){case 40:if(v!=108&&ct(_,f-1)==58){Xs(_+=Ee(ea(w),"&","&\f"),"&\f")!=-1&&(b=-1);break}case 34:case 39:case 91:_+=ea(w);break;case 9:case 10:case 13:case 32:_+=Jv(v);break;case 92:_+=eb(Ji()-1,7);continue;case 47:switch(ur()){case 42:case 47:Yi(nb(tb(Pt(),Ji()),t,r),c);break;default:_+="/"}break;case 123*m:s[l++]=lr(_)*b;case 125*m:case 59:case 0:switch(w){case 0:case 125:p=0;case 59+u:g>0&&lr(_)-f&&Yi(g>32?xf(_+";",n,r,f-1):xf(Ee(_," ","")+";",n,r,f-2),c);break;case 59:_+=";";default:if(Yi(y=Ef(_,t,r,l,u,o,s,E,$=[],S=[],f),i),w===123)if(u===0)ta(_,t,y,y,$,i,f,s,S);else switch(d===99&&ct(_,3)===110?100:d){case 100:case 109:case 115:ta(e,y,y,n&&Yi(Ef(e,y,y,0,0,o,s,E,o,$=[],f),S),o,S,f,s,n?$:S);break;default:ta(_,y,y,y,[""],S,0,s,S)}}l=u=g=0,m=b=1,E=_="",f=a;break;case 58:f=1+lr(_),g=v;default:if(m<1){if(w==123)--m;else if(w==125&&m++==0&&Qv()==125)continue}switch(_+=Xi(w),w*m){case 38:b=u>0?1:(_+="\f",-1);break;case 44:s[l++]=(lr(_)-1)*b,b=1;break;case 64:ur()===45&&(_+=ea(Pt())),d=ur(),u=f=lr(E=_+=rb(Ji())),w++;break;case 45:v===45&&lr(_)==2&&(m=0)}}return i}function Ef(e,t,r,n,o,i,a,s,c,l,u){for(var f=o-1,d=o===0?i:[""],g=Ys(d),v=0,m=0,p=0;v0?d[b]+" "+w:Ee(w,/&\f/g,d[b])))&&(c[p++]=E);return Qi(e,t,r,o===0?qs:s,c,l,u)}function nb(e,t,r){return Qi(e,t,r,pf,Xi(Zv()),Ho(e,2,-2),0)}function xf(e,t,r,n){return Qi(e,t,r,Ks,Ho(e,0,n),Ho(e,n+1,-1),n)}function yn(e,t){for(var r="",n=Ys(e),o=0;o6)switch(ct(e,t+1)){case 109:if(ct(e,t+4)!==45)break;case 102:return Ee(e,/(.+:)(.+)-([^]+)/,"$1"+be+"$2-$3$1"+Ki+(ct(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Xs(e,"stretch")?$f(Ee(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(ct(e,t+1)!==115)break;case 6444:switch(ct(e,lr(e)-3-(~Xs(e,"!important")&&10))){case 107:return Ee(e,":",":"+be)+e;case 101:return Ee(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+be+(ct(e,14)===45?"inline-":"")+"box$3$1"+be+"$2$3$1"+dt+"$2box$3")+e}break;case 5936:switch(ct(e,t+11)){case 114:return be+e+dt+Ee(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return be+e+dt+Ee(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return be+e+dt+Ee(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return be+e+dt+e+e}return e}var db=function(t,r,n,o){if(t.length>-1&&!t.return)switch(t.type){case Ks:t.return=$f(t.value,t.length);break;case vf:return yn([Bo(t,{value:Ee(t.value,"@","@"+be)})],o);case qs:if(t.length)return Yv(t.props,function(i){switch(Xv(i,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return yn([Bo(t,{props:[Ee(i,/:(read-\w+)/,":"+Ki+"$1")]})],o);case"::placeholder":return yn([Bo(t,{props:[Ee(i,/:(plac\w+)/,":"+be+"input-$1")]}),Bo(t,{props:[Ee(i,/:(plac\w+)/,":"+Ki+"$1")]}),Bo(t,{props:[Ee(i,/:(plac\w+)/,dt+"input-$1")]})],o)}return""})}},hb=[db],Pf=function(t){var r=t.key;if(r==="css"){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(m){var p=m.getAttribute("data-emotion");p.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""))})}var o=t.stylisPlugins||hb,i={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+r+' "]'),function(m){for(var p=m.getAttribute("data-emotion").split(" "),b=1;b=4;++n,o-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var $b={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Pb=/[A-Z]|^ms/g,Tb=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Ff=function(t){return t.charCodeAt(1)===45},Nf=function(t){return t!=null&&typeof t!="boolean"},rc=ab(function(e){return Ff(e)?e:e.replace(Pb,"-$&").toLowerCase()}),If=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Tb,function(n,o,i){return fr={name:o,styles:i,next:fr},o})}return $b[t]!==1&&!Ff(t)&&typeof r=="number"&&r!==0?r+"px":r},LM="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function Go(e,t,r){if(r==null)return"";if(r.__emotion_styles!==void 0)return r;switch(typeof r){case"boolean":return"";case"object":{if(r.anim===1)return fr={name:r.name,styles:r.styles,next:fr},r.name;if(r.styles!==void 0){var n=r.next;if(n!==void 0)for(;n!==void 0;)fr={name:n.name,styles:n.styles,next:fr},n=n.next;var o=r.styles+";";return o}return kb(e,t,r)}case"function":{if(e!==void 0){var i=fr,a=r(e);return fr=i,Go(e,t,a)}break}}if(t==null)return r;var s=t[r];return s!==void 0?s:r}function kb(e,t,r){var n="";if(Array.isArray(r))for(var o=0;o0){if(++t>=L0)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function H0(e){return function(){return e}}var B0=function(){try{var e=Sn(Object,"defineProperty");return e({},"",{}),e}catch{}}();const ma=B0;var W0=ma?function(e,t){return ma(e,"toString",{configurable:!0,enumerable:!1,value:H0(t),writable:!0})}:Qf,V0=z0(W0);const U0=V0;function G0(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i-1}var Z0=9007199254740991,Q0=/^(?:0|[1-9]\d*)$/;function cc(e,t){var r=typeof e;return t=t??Z0,!!t&&(r=="number"||r!="symbol"&&Q0.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=oy}function iy(e){return e!=null&&uc(e.length)&&!Jf(e)}var ay=Object.prototype;function sy(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||ay;return e===r}function cy(e,t){for(var r=-1,n=Array(e);++r-1}function S1(e,t){var r=this.__data__,n=pa(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function Ar(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t0&&r(s)?t>1?md(s,t-1,r,n,o):hd(o,s):n||(o[o.length]=s)}return o}function D1(e){var t=e==null?0:e.length;return t?md(e,1):[]}function z1(e){return U0(ny(e,void 0,D1),e+"")}var H1="Expected a function";function B1(e,t){var r;if(typeof t!="function")throw new TypeError(H1);return e=Zf(e),function(){return--e>0&&(r=t.apply(this,arguments)),e<=1&&(t=void 0),r}}function W1(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),r=r>o?o:r,r<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n=n?e:W1(e,t,r)}var U1="\\ud800-\\udfff",G1="\\u0300-\\u036f",q1="\\ufe20-\\ufe2f",K1="\\u20d0-\\u20ff",X1=G1+q1+K1,Y1="\\ufe0e\\ufe0f",Z1="\\u200d",Q1=RegExp("["+Z1+U1+X1+Y1+"]");function vc(e){return Q1.test(e)}function J1(e){return e.split("")}var pd="\\ud800-\\udfff",ew="\\u0300-\\u036f",tw="\\ufe20-\\ufe2f",rw="\\u20d0-\\u20ff",nw=ew+tw+rw,ow="\\ufe0e\\ufe0f",iw="["+pd+"]",bc="["+nw+"]",yc="\\ud83c[\\udffb-\\udfff]",aw="(?:"+bc+"|"+yc+")",vd="[^"+pd+"]",bd="(?:\\ud83c[\\udde6-\\uddff]){2}",yd="[\\ud800-\\udbff][\\udc00-\\udfff]",sw="\\u200d",wd=aw+"?",Sd="["+ow+"]?",cw="(?:"+sw+"(?:"+[vd,bd,yd].join("|")+")"+Sd+wd+")*",lw=Sd+wd+cw,uw="(?:"+[vd+bc+"?",bc,bd,yd,iw].join("|")+")",fw=RegExp(yc+"(?="+yc+")|"+uw+lw,"g");function dw(e){return e.match(fw)||[]}function hw(e){return vc(e)?dw(e):J1(e)}function gw(){this.__data__=new Ar,this.size=0}function mw(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function pw(e){return this.__data__.get(e)}function vw(e){return this.__data__.has(e)}var bw=200;function yw(e,t){var r=this.__data__;if(r instanceof Ar){var n=r.__data__;if(!Qo||n.lengths))return!1;var l=i.get(e),u=i.get(t);if(l&&u)return l==t&&u==e;var f=-1,d=!0,g=r&Bw?new ei:void 0;for(i.set(e,t),i.set(t,e);++f=t||_<0||f&&R>=i}function b(){var y=xc();if(p(y))return w(y);s=setTimeout(b,m(y))}function w(y){return s=void 0,d&&n?g(y):(n=o=void 0,a)}function E(){s!==void 0&&clearTimeout(s),l=0,n=c=o=s=void 0}function $(){return s===void 0?a:w(xc())}function S(){var y=xc(),_=p(y);if(n=arguments,o=this,c=y,_){if(s===void 0)return v(c);if(f)return clearTimeout(s),s=setTimeout(b,t),g(c)}return s===void 0&&(s=setTimeout(b,t)),a}return S.cancel=E,S.flush=$,S}function PS(e,t,r){for(var n=-1,o=e==null?0:e.length;++nRS)return r;do t%2&&(r+=e),t=FS(t/2),t&&(e+=e);while(t);return r}var NS=zd("length");const IS=NS;var Wd="\\ud800-\\udfff",LS="\\u0300-\\u036f",jS="\\ufe20-\\ufe2f",DS="\\u20d0-\\u20ff",zS=LS+jS+DS,HS="\\ufe0e\\ufe0f",BS="["+Wd+"]",_c="["+zS+"]",Oc="\\ud83c[\\udffb-\\udfff]",WS="(?:"+_c+"|"+Oc+")",Vd="[^"+Wd+"]",Ud="(?:\\ud83c[\\udde6-\\uddff]){2}",Gd="[\\ud800-\\udbff][\\udc00-\\udfff]",VS="\\u200d",qd=WS+"?",Kd="["+HS+"]?",US="(?:"+VS+"(?:"+[Vd,Ud,Gd].join("|")+")"+Kd+qd+")*",GS=Kd+qd+US,qS="(?:"+[Vd+_c+"?",_c,Ud,Gd,BS].join("|")+")",Xd=RegExp(Oc+"(?="+Oc+")|"+qS+GS,"g");function KS(e){for(var t=Xd.lastIndex=0;Xd.test(e);)++t;return t}function Yd(e){return vc(e)?KS(e):IS(e)}var XS=Math.ceil;function YS(e,t){t=t===void 0?" ":oc(t);var r=t.length;if(r<2)return r?Bd(t,e):t;var n=Bd(t,XS(e/Yd(t)));return vc(t)?V1(hw(n),0,e).join(""):n.slice(0,e)}function ZS(e,t,r){e=dd(e),t=Zf(t);var n=t?Yd(e):0;return t&&n=iC){var l=t?null:oC(e);if(l)return Cc(l);a=!1,o=Md,c=new ei}else c=t?[]:s;e:for(;++nnew Proxy(e,t);const Pc=Object.getPrototypeOf,Tc=new WeakMap,Jd=e=>e&&(Tc.has(e)?Tc.get(e):Pc(e)===Object.prototype||Pc(e)===Array.prototype),Sa=e=>typeof e=="object"&&e!==null,lC=e=>{if(Array.isArray(e))return Array.from(e);const t=Object.getOwnPropertyDescriptors(e);return Object.values(t).forEach(r=>{r.configurable=!0}),Object.create(Pc(e),t)},kc=e=>e[$c]||e,eh=(e,t,r,n)=>{if(!Jd(e))return e;let o=n&&n.get(e);if(!o){const c=kc(e);o=(l=>Object.values(Object.getOwnPropertyDescriptors(l)).some(u=>!u.configurable&&!u.writable))(c)?[c,lC(c)]:[c],n==null||n.set(e,o)}const[i,a]=o;let s=r&&r.get(i);return s&&s[1].f===!!a||(s=((c,l)=>{const u={f:l};let f=!1;const d=(v,m)=>{if(!f){let p=u[ti].get(c);if(p||(p={},u[ti].set(c,p)),v===ri)p[ri]=!0;else{let b=p[v];b||(b=new Set,p[v]=b),b.add(m)}}},g={get:(v,m)=>m===$c?c:(d("k",m),eh(Reflect.get(v,m),u[ti],u.c)),has:(v,m)=>m===sC?(f=!0,u[ti].delete(c),!0):(d("h",m),Reflect.has(v,m)),getOwnPropertyDescriptor:(v,m)=>(d("o",m),Reflect.getOwnPropertyDescriptor(v,m)),ownKeys:v=>(d(ri),Reflect.ownKeys(v))};return l&&(g.set=g.deleteProperty=()=>!1),[g,u]})(i,!!a),s[1].p=cC(a||i,s[0]),r&&r.set(i,s)),s[1][ti]=t,s[1].c=r,s[1].p},th=(e,t,r,n)=>{if(Object.is(e,t))return!1;if(!Sa(e)||!Sa(t))return!0;const o=r.get(kc(e));if(!o)return!0;if(n){const a=n.get(e);if(a&&a.n===t)return a.g;n.set(e,{n:t,g:!1})}let i=null;try{for(const a of o.h||[])if(i=Reflect.has(e,a)!==Reflect.has(t,a),i)return i;if(o[ri]===!0){if(i=((a,s)=>{const c=Reflect.ownKeys(a),l=Reflect.ownKeys(s);return c.length!==l.length||c.some((u,f)=>u!==l[f])})(e,t),i)return i}else for(const a of o.o||[])if(i=!!Reflect.getOwnPropertyDescriptor(e,a)!=!!Reflect.getOwnPropertyDescriptor(t,a),i)return i;for(const a of o.k||[])if(i=th(e[a],t[a],r,n),i)return i;return i===null&&(i=!0),i}finally{n&&n.set(e,{n:t,g:i})}},uC=e=>Jd(e)&&e[$c]||null,rh=(e,t=!0)=>{Tc.set(e,t)},fC=(e,t,r)=>{const n=[],o=new WeakSet,i=(a,s)=>{if(o.has(a))return;Sa(a)&&o.add(a);const c=Sa(a)&&t.get(kc(a));if(c){var l,u;if((l=c.h)==null||l.forEach(d=>{const g=`:has(${String(d)})`;n.push(s?[...s,g]:[g])}),c[ri]===!0){const d=":ownKeys";n.push(s?[...s,d]:[d])}else{var f;(f=c.o)==null||f.forEach(d=>{const g=`:hasOwn(${String(d)})`;n.push(s?[...s,g]:[g])})}(u=c.k)==null||u.forEach(d=>{r&&!("value"in(Object.getOwnPropertyDescriptor(a,d)||{}))||i(a[d],s?[...s,d]:[d])})}else s&&n.push(s)};return i(e),n},Mc=e=>typeof e=="object"&&e!==null,tn=new WeakMap,Ca=new WeakSet,dC=(e=Object.is,t=(l,u)=>new Proxy(l,u),r=l=>Mc(l)&&!Ca.has(l)&&(Array.isArray(l)||!(Symbol.iterator in l))&&!(l instanceof WeakMap)&&!(l instanceof WeakSet)&&!(l instanceof Error)&&!(l instanceof Number)&&!(l instanceof Date)&&!(l instanceof String)&&!(l instanceof RegExp)&&!(l instanceof ArrayBuffer),n=l=>{switch(l.status){case"fulfilled":return l.value;case"rejected":throw l.reason;default:throw l}},o=new WeakMap,i=(l,u,f=n)=>{const d=o.get(l);if((d==null?void 0:d[0])===u)return d[1];const g=Array.isArray(l)?[]:Object.create(Object.getPrototypeOf(l));return rh(g,!0),o.set(l,[u,g]),Reflect.ownKeys(l).forEach(v=>{if(Object.getOwnPropertyDescriptor(g,v))return;const m=Reflect.get(l,v),p={value:m,enumerable:!0,configurable:!0};if(Ca.has(m))rh(m,!1);else if(m instanceof Promise)delete p.value,p.get=()=>f(m);else if(tn.has(m)){const[b,w]=tn.get(m);p.value=i(b,w(),f)}Object.defineProperty(g,v,p)}),g},a=new WeakMap,s=[1,1],c=l=>{if(!Mc(l))throw new Error("object required");const u=a.get(l);if(u)return u;let f=s[0];const d=new Set,g=(A,k=++s[0])=>{f!==k&&(f=k,d.forEach(I=>I(A,k)))};let v=s[1];const m=(A=++s[1])=>(v!==A&&!d.size&&(v=A,b.forEach(([k])=>{const I=k[1](A);I>f&&(f=I)})),f),p=A=>(k,I)=>{const M=[...k];M[1]=[A,...M[1]],g(M,I)},b=new Map,w=(A,k)=>{if(({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&b.has(A))throw new Error("prop listener already exists");if(d.size){const I=k[3](p(A));b.set(A,[k,I])}else b.set(A,[k])},E=A=>{var k;const I=b.get(A);I&&(b.delete(A),(k=I[1])==null||k.call(I))},$=A=>(d.add(A),d.size===1&&b.forEach(([I,M],C)=>{if(({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&M)throw new Error("remove already exists");const x=I[3](p(C));b.set(C,[I,x])}),()=>{d.delete(A),d.size===0&&b.forEach(([I,M],C)=>{M&&(M(),b.set(C,[I]))})}),S=Array.isArray(l)?[]:Object.create(Object.getPrototypeOf(l)),_=t(S,{deleteProperty(A,k){const I=Reflect.get(A,k);E(k);const M=Reflect.deleteProperty(A,k);return M&&g(["delete",[k],I]),M},set(A,k,I,M){const C=Reflect.has(A,k),x=Reflect.get(A,k,M);if(C&&(e(x,I)||a.has(I)&&e(x,a.get(I))))return!0;E(k),Mc(I)&&(I=uC(I)||I);let P=I;if(I instanceof Promise)I.then(N=>{I.status="fulfilled",I.value=N,g(["resolve",[k],N])}).catch(N=>{I.status="rejected",I.reason=N,g(["reject",[k],N])});else{!tn.has(I)&&r(I)&&(P=c(I));const N=!Ca.has(P)&&tn.get(P);N&&w(k,N)}return Reflect.set(A,k,P,M),g(["set",[k],I,x]),!0}});a.set(l,_);const R=[S,m,i,$];return tn.set(_,R),Reflect.ownKeys(l).forEach(A=>{const k=Object.getOwnPropertyDescriptor(l,A);"value"in k&&(_[A]=l[A],delete k.value,delete k.writable),Object.defineProperty(S,A,k)}),_})=>[c,tn,Ca,e,t,r,n,o,i,a,s],[hC]=dC();function ni(e={}){return hC(e)}function nh(e,t,r){const n=tn.get(e);({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&!n&&console.warn("Please use proxy object");let o;const i=[],a=n[3];let s=!1;const l=a(u=>{if(i.push(u),r){t(i.splice(0));return}o||(o=Promise.resolve().then(()=>{o=void 0,s&&t(i.splice(0))}))});return s=!0,()=>{s=!1,l()}}function oh(e,t){const r=tn.get(e);({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&!r&&console.warn("Please use proxy object");const[n,o,i]=r;return i(n,o(),t)}var Ac={},gC={get exports(){return Ac},set exports(e){Ac=e}},ih={};/** * @license React * use-sync-external-store-shim.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Xn=T;function mC(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var pC=typeof Object.is=="function"?Object.is:mC,vC=Xn.useState,bC=Xn.useEffect,yC=Xn.useLayoutEffect,wC=Xn.useDebugValue;function SC(e,t){var r=t(),n=vC({inst:{value:r,getSnapshot:t}}),o=n[0].inst,i=n[1];return yC(function(){o.value=r,o.getSnapshot=t,Rc(o)&&i({inst:o})},[e,r,t]),bC(function(){return Rc(o)&&i({inst:o}),e(function(){Rc(o)&&i({inst:o})})},[e]),wC(r),r}function Rc(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!pC(e,r)}catch{return!0}}function CC(e,t){return t()}var EC=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?CC:SC;ih.useSyncExternalStore=Xn.useSyncExternalStore!==void 0?Xn.useSyncExternalStore:EC,function(e){e.exports=ih}(gC);const xC=mb(Ac),{use:ah}=T,{useSyncExternalStore:_C}=xC,OC=(e,t)=>{const r=T.useRef();T.useEffect(()=>{r.current=fC(e,t,!0)}),T.useDebugValue(r.current)},$C=new WeakMap;function Yn(e,t){const r=t==null?void 0:t.sync,n=T.useRef(),o=T.useRef();let i=!0;const a=_C(T.useCallback(l=>{const u=nh(e,l,r);return l(),u},[e,r]),()=>{const l=oh(e,ah);try{if(!i&&n.current&&o.current&&!th(n.current,l,o.current,new WeakMap))return n.current}catch{}return l},()=>oh(e,ah));i=!1;const s=new WeakMap;T.useEffect(()=>{n.current=a,o.current=s}),({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&OC(a,s);const c=T.useMemo(()=>new WeakMap,[]);return eh(a,s,c,$C)}const Fc={accessKey:"",useNarrowMode:!1,initialShowMore:!1,pureRecommend:!1,openInIINAWhenRightClick:!1,usePcDesktopApi:!1,useParallelRequest:!0,autoPreviewWhenKeyboardSelect:!1,autoPreviewUpdateInterval:400},He=ni({...Fc}),sh=Object.keys(Fc),rn=function(){return Yn(He)},ch="bilibili-app-recommend.settings";function PC(){const e=GM_getValue(ch);e&&typeof e=="object"&&Object.assign(He,Zd(e,sh)),nh(He,()=>{TC()})}function TC(){const e=Zd(He,sh);GM_setValue(ch,e)}function lh(e){Object.assign(He,e)}function kC(){return lh(Fc)}PC();const oi=AS(()=>!!document.querySelectorAll(".bili-feed4").length),uh=document.querySelector(".bili-header__bar"),fh=!!(uh&&window.getComputedStyle(uh).display==="none")?50:64,dh=()=>document.body.classList.contains("dark"),hh=ni({value:dh()});function Nc(){return Yn(hh).value}const Ea=new MutationObserver(function(){hh.value=dh()});Ea.observe(document.body,{attributes:!0,attributeFilter:["class"]}),window.addEventListener("unload",()=>{Ea==null||Ea.disconnect()});function mr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function gh(e,t){for(var r=0;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Ue(e){return Ue=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ue(e)}function Oa(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function AC(e,t){if(t&&(Ue(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Oa(e)}function $a(e){var t=MC();return function(){var n=_a(e),o;if(t){var i=_a(this).constructor;o=Reflect.construct(n,arguments,i)}else o=n.apply(this,arguments);return AC(this,o)}}var Lc={},RC={get exports(){return Lc},set exports(e){Lc=e}};/*! Copyright (c) 2018 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var n=[],o=0;o1&&arguments[1]!==void 0?arguments[1]:{},r=[];return T.Children.forEach(e,function(n){n==null&&!t.keepEmpty||(Array.isArray(n)?r=r.concat(Zn(n)):Uo.isFragment(n)&&n.props?r=r.concat(Zn(n.props.children,t)):r.push(n))}),r}var mh={};function FC(e,t){}function NC(e,t,r){!t&&!mh[r]&&(e(!1,r),mh[r]=!0)}function vr(e,t){NC(FC,e,t)}function Qn(e){return Qn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qn(e)}function IC(e,t){if(Qn(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Qn(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ph(e){var t=IC(e,"string");return Qn(t)==="symbol"?t:String(t)}function LC(e,t,r){return t=ph(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function vh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function bh(e){for(var t=1;t0},e.prototype.connect_=function(){!Bc||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),WC?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!Bc||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(t){var r=t.propertyName,n=r===void 0?"":r,o=BC.some(function(i){return!!~n.indexOf(i)});o&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),Sh=function(e,t){for(var r=0,n=Object.keys(t);r"u"||!(Element instanceof Object))){if(!(t instanceof eo(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var r=this.observations_;r.has(t)||(r.set(t,new QC(t)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof eo(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var r=this.observations_;r.has(t)&&(r.delete(t),r.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach(function(r){r.isActive()&&t.activeObservations_.push(r)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,r=this.activeObservations_.map(function(n){return new JC(n.target,n.broadcastRect())});this.callback_.call(t,r,t),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e}(),xh=typeof WeakMap<"u"?new WeakMap:new wh,_h=function(){function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var r=VC.getInstance(),n=new eE(t,r,this);xh.set(this,n)}return e}();["observe","unobserve","disconnect"].forEach(function(e){_h.prototype[e]=function(){var t;return(t=xh.get(this))[e].apply(t,arguments)}});var tE=function(){return typeof Ta.ResizeObserver<"u"?Ta.ResizeObserver:_h}(),nn=new Map;function rE(e){e.forEach(function(t){var r,n=t.target;(r=nn.get(n))===null||r===void 0||r.forEach(function(o){return o(n)})})}var Oh=new tE(rE);function nE(e,t){nn.has(e)||(nn.set(e,new Set),Oh.observe(e)),nn.get(e).add(t)}function oE(e,t){nn.has(e)&&(nn.get(e).delete(t),nn.get(e).size||(Oh.unobserve(e),nn.delete(e)))}function iE(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $h(e,t){for(var r=0;r"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function lE(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uE(e,t){if(t&&(Qn(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return lE(e)}function fE(e){var t=cE();return function(){var n=Aa(e),o;if(t){var i=Aa(this).constructor;o=Reflect.construct(n,arguments,i)}else o=n.apply(this,arguments);return uE(this,o)}}var dE=function(e){sE(r,e);var t=fE(r);function r(){return iE(this,r),t.apply(this,arguments)}return aE(r,[{key:"render",value:function(){return this.props.children}}]),r}(h.Component),Vc=h.createContext(null);function hE(e){var t=e.children,r=e.onBatchResize,n=h.useRef(0),o=h.useRef([]),i=h.useContext(Vc),a=h.useCallback(function(s,c,l){n.current+=1;var u=n.current;o.current.push({size:s,element:c,data:l}),Promise.resolve().then(function(){u===n.current&&(r==null||r(o.current),o.current=[])}),i==null||i(s,c,l)},[r,i]);return h.createElement(Vc.Provider,{value:a},t)}function gE(e,t){var r=e.children,n=e.disabled,o=h.useRef(null),i=h.useRef(null),a=h.useContext(Vc),s=typeof r=="function",c=s?r(o):r,l=h.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),u=!s&&h.isValidElement(c)&&ii(c),f=u?c.ref:null,d=h.useMemo(function(){return Jn(f,o)},[f,o]),g=function(){return Hc(o.current)||Hc(i.current)};h.useImperativeHandle(t,function(){return g()});var v=h.useRef(e);v.current=e;var m=h.useCallback(function(p){var b=v.current,w=b.onResize,E=b.data,$=p.getBoundingClientRect(),S=$.width,y=$.height,_=p.offsetWidth,R=p.offsetHeight,A=Math.floor(S),k=Math.floor(y);if(l.current.width!==A||l.current.height!==k||l.current.offsetWidth!==_||l.current.offsetHeight!==R){var I={width:A,height:k,offsetWidth:_,offsetHeight:R};l.current=I;var M=_===Math.round(S)?S:_,C=R===Math.round(y)?y:R,x=bh(bh({},I),{},{offsetWidth:M,offsetHeight:C});a==null||a(x,p,E),w&&Promise.resolve().then(function(){w(x,p)})}},[]);return h.useEffect(function(){var p=g();return p&&!n&&nE(p,m),function(){return oE(p,m)}},[o.current,n]),h.createElement(dE,{ref:i},u?h.cloneElement(c,{ref:d}):c)}var mE=h.forwardRef(gE),pE="rc-observer-key";function vE(e,t){var r=e.children,n=typeof r=="function"?[r]:Zn(r);return n.map(function(o,i){var a=(o==null?void 0:o.key)||"".concat(pE,"-").concat(i);return h.createElement(mE,jc({},e,{key:a,ref:i===0?t:void 0}),o)})}var Uc=h.forwardRef(vE);Uc.Collection=hE;function oe(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ph(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function H(e){for(var t=1;te.length)&&(t=e.length);for(var r=0,n=new Array(t);r=4;++n,o-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}function wE(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i=0)&&(r[o]=e[o]);return r}function Bt(e,t){if(e==null)return{};var r=wE(e,t),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Mh(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=new Set;function o(i,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,c=n.has(i);if(vr(!c,"Warning: There may be circular references"),c)return!1;if(i===a)return!0;if(r&&s>1)return!1;n.add(i);var l=s+1;if(Array.isArray(i)){if(!Array.isArray(a)||i.length!==a.length)return!1;for(var u=0;u0&&arguments[0]!==void 0?arguments[0]:{},t=e.mark;return t?t.startsWith("data-")?t:"data-".concat(t):_E}function Fa(e){if(e.attachTo)return e.attachTo;var t=document.querySelector("head");return t||document.body}function OE(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function jh(e){return Array.from((Yc.get(e)||e).children).filter(function(t){return t.tagName==="STYLE"})}function Dh(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!kt())return null;var r=t.csp,n=t.prepend,o=document.createElement("style");o.setAttribute(Ih,OE(n)),r!=null&&r.nonce&&(o.nonce=r==null?void 0:r.nonce),o.innerHTML=e;var i=Fa(t),a=i.firstChild;if(n){if(n==="queue"){var s=jh(i).filter(function(c){return["prepend","prependQueue"].includes(c.getAttribute(Ih))});if(s.length)return i.insertBefore(o,s[s.length-1].nextSibling),o}i.insertBefore(o,a)}else i.appendChild(o);return o}function zh(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=Fa(t);return jh(r).find(function(n){return n.getAttribute(Lh(t))===e})}function Na(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=zh(e,t);if(r){var n=Fa(t);n.removeChild(r)}}function $E(e,t){var r=Yc.get(e);if(!r||!xE(document,r)){var n=Dh("",t),o=n.parentNode;Yc.set(e,o),e.removeChild(n)}}function to(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=Fa(r);$E(n,r);var o=zh(t,r);if(o){var i,a;if((i=r.csp)!==null&&i!==void 0&&i.nonce&&o.nonce!==((a=r.csp)===null||a===void 0?void 0:a.nonce)){var s;o.nonce=(s=r.csp)===null||s===void 0?void 0:s.nonce}return o.innerHTML!==e&&(o.innerHTML=e),o}var c=Dh(e,r);return c.setAttribute(Lh(r),t),c}function Ia(e){var t="";return Object.keys(e).forEach(function(r){var n=e[r];t+=r,n&&Ue(n)==="object"?t+=Ia(n):t+=n}),t}function PE(e,t){return Kc("".concat(t,"_").concat(Ia(e)))}var si="layer-".concat(Date.now(),"-").concat(Math.random()).replace(/\./g,""),Hh="903px";function TE(e,t){if(kt()){var r;to(e,si);var n=document.createElement("div");n.style.position="fixed",n.style.left="0",n.style.top="0",t==null||t(n),document.body.appendChild(n);var o=getComputedStyle(n).width===Hh;return(r=n.parentNode)===null||r===void 0||r.removeChild(n),Na(si),o}return!1}var Zc=void 0;function kE(){return Zc===void 0&&(Zc=TE("@layer ".concat(si," { .").concat(si," { width: ").concat(Hh,"!important; } }"),function(e){e.className=si})),Zc}var ME={},AE="css",_n=new Map;function RE(e){_n.set(e,(_n.get(e)||0)+1)}function FE(e){if(typeof document<"u"){var t=document.querySelectorAll("style[".concat(Xc,'="').concat(e,'"]'));t.forEach(function(r){if(r[ai]===Ra){var n;(n=r.parentNode)===null||n===void 0||n.removeChild(r)}})}}function NE(e){_n.set(e,(_n.get(e)||0)-1);var t=Array.from(_n.keys()),r=t.filter(function(n){var o=_n.get(n)||0;return o<=0});r.length2&&arguments[2]!==void 0?arguments[2]:{},n=r.salt,o=n===void 0?"":n,i=r.override,a=i===void 0?ME:i,s=r.formatToken,c=h.useMemo(function(){return Object.assign.apply(Object,[{}].concat(Q(t)))},[t]),l=h.useMemo(function(){return Ia(c)},[c]),u=h.useMemo(function(){return Ia(a)},[a]),f=Nh("token",[o,e.id,l,u],function(){var d=e.getDerivativeToken(c),g=H(H({},d),a);s&&(g=s(g));var v=PE(g,o);g._tokenKey=v,RE(v);var m="".concat(AE,"-").concat(Kc(v));return g._hashId=m,[g,m]},function(d){NE(d[0]._tokenKey)});return f}var LE={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Bh=kt(),jE="_skip_check_";function Wh(e){var t=yn(Cf(e),_f);return t.replace(/\{%%%\:[^;];}/g,";")}function DE(e){return Ue(e)==="object"&&e&&jE in e}function zE(e,t,r){if(!t)return e;var n=".".concat(t),o=r==="low"?":where(".concat(n,")"):n,i=e.split(",").map(function(a){var s,c=a.trim().split(/\s+/),l=c[0]||"",u=((s=l.match(/^\w+/))===null||s===void 0?void 0:s[0])||"";return l="".concat(u).concat(o).concat(l.slice(u.length)),[l].concat(Q(c.slice(1))).join(" ")});return i.join(",")}var HE=function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{root:!0,parentSelectors:[]},o=n.root,i=n.injectHash,a=n.parentSelectors,s=r.hashId,c=r.layer;r.path;var l=r.hashPriority,u=r.transformers,f=u===void 0?[]:u;r.linters;var d="",g={};function v(E){var $=E.getName(s);if(!g[$]){var S=e(E.style,r,{root:!1,parentSelectors:a}),y=G(S,1),_=y[0];g[$]="@keyframes ".concat(E.getName(s)).concat(_)}}function m(E){var $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return E.forEach(function(S){Array.isArray(S)?m(S,$):S&&$.push(S)}),$}var p=m(Array.isArray(t)?t:[t]);if(p.forEach(function(E){var $=typeof E=="string"&&!o?{}:E;if(typeof $=="string")d+="".concat($,` `);else if($._keyframe)v($);else{var S=f.reduce(function(y,_){var R;return(_==null||(R=_.visit)===null||R===void 0?void 0:R.call(_,y))||y},$);Object.keys(S).forEach(function(y){var _=S[y];if(Ue(_)==="object"&&_&&(y!=="animationName"||!_._keyframe)&&!DE(_)){var R=!1,A=y.trim(),k=!1;(o||i)&&s?A.startsWith("@")?R=!0:A=zE(y,s,l):o&&!s&&(A==="&"||A==="")&&(A="",k=!0);var I=e(_,r,{root:k,injectHash:R,parentSelectors:[].concat(Q(a),[A])}),M=G(I,2),C=M[0],x=M[1];g=H(H({},g),x),d+="".concat(A).concat(C)}else{var P,N=(P=_==null?void 0:_.value)!==null&&P!==void 0?P:_,F=y.replace(/[A-Z]/g,function(D){return"-".concat(D.toLowerCase())}),j=N;!LE[y]&&typeof j=="number"&&j!==0&&(j="".concat(j,"px")),y==="animationName"&&_!==null&&_!==void 0&&_._keyframe&&(v(_),j=_.getName(s)),d+="".concat(F,":").concat(j,";")}})}}),!o)d="{".concat(d,"}");else if(c&&kE()){var b=c.split(","),w=b[b.length-1].trim();d="@layer ".concat(w," {").concat(d,"}"),b.length>1&&(d="@layer ".concat(c,"{%%%:%}").concat(d))}return[d,g]};function BE(e,t){return Kc("".concat(e.join("%")).concat(t))}function WE(){return null}function Qc(e,t){var r=e.token,n=e.path,o=e.hashId,i=e.layer,a=h.useContext(Ah),s=a.autoClear;a.mock;var c=a.defaultCache,l=a.hashPriority,u=a.container,f=a.ssrInline,d=a.transformers,g=a.linters,v=r._tokenKey,m=[v].concat(Q(n)),p=Bh,b=Nh("style",m,function(){var y=t(),_=HE(y,{hashId:o,hashPriority:l,layer:i,path:n.join("-"),transformers:d,linters:g}),R=G(_,2),A=R[0],k=R[1],I=Wh(A),M=BE(m,I);if(p){var C=to(I,M,{mark:xn,prepend:"queue",attachTo:u});C[ai]=Ra,C.setAttribute(Xc,v),Object.keys(k).forEach(function(x){to(Wh(k[x]),"_effect-".concat(x),{mark:xn,prepend:"queue",attachTo:u})})}return[I,v,M]},function(y,_){var R=G(y,3),A=R[2];(_||s)&&Bh&&Na(A,{mark:xn})}),w=G(b,3),E=w[0],$=w[1],S=w[2];return function(y){var _;if(!f||p||!c)_=h.createElement(WE,null);else{var R;_=h.createElement("style",Ht({},(R={},oe(R,Xc,$),oe(R,xn,S),R),{dangerouslySetInnerHTML:{__html:E}}))}return h.createElement(h.Fragment,null,_,y)}}var Ct=function(){function e(t,r){mr(this,e),oe(this,"name",void 0),oe(this,"style",void 0),oe(this,"_keyframe",!0),this.name=t,this.style=r}return pr(e,[{key:"getName",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return r?"".concat(r,"-").concat(this.name):this.name}}]),e}();function VE(e,t){if(e.length!==t.length)return!1;for(var r=0;r1&&arguments[1]!==void 0?arguments[1]:!1,a={map:this.cache};return r.forEach(function(s){if(!a)a=void 0;else{var c,l;a=(c=a)===null||c===void 0||(l=c.map)===null||l===void 0?void 0:l.get(s)}}),(n=a)!==null&&n!==void 0&&n.value&&i&&(a.value[1]=this.cacheCallTimes++),(o=a)===null||o===void 0?void 0:o.value}},{key:"get",value:function(r){var n;return(n=this.internalGet(r,!0))===null||n===void 0?void 0:n[0]}},{key:"has",value:function(r){return!!this.internalGet(r)}},{key:"set",value:function(r,n){var o=this;if(!this.has(r)){if(this.size()+1>e.MAX_CACHE_SIZE+e.MAX_CACHE_OFFSET){var i=this.keys.reduce(function(l,u){var f=G(l,2),d=f[1];return o.internalGet(u)[1]0,void 0),Vh+=1}return pr(e,[{key:"getDerivativeToken",value:function(r){return this.derivatives.reduce(function(n,o){return o(r,n)},void 0)}}]),e}(),el=new Jc;function Uh(e){var t=Array.isArray(e)?e:[e];return el.has(t)||el.set(t,new UE(t)),el.get(t)}function ro(e){return e.notSplit=!0,e}ro(["borderTop","borderBottom"]),ro(["borderTop"]),ro(["borderBottom"]),ro(["borderLeft","borderRight"]),ro(["borderLeft"]),ro(["borderRight"]);var GE=T.createContext({});const tl=GE;var On="RC_FORM_INTERNAL_HOOKS",$e=function(){vr(!1,"Can not find FormContext. Please make sure you wrap Field under Form.")},no=h.createContext({getFieldValue:$e,getFieldsValue:$e,getFieldError:$e,getFieldWarning:$e,getFieldsError:$e,isFieldsTouched:$e,isFieldTouched:$e,isFieldValidating:$e,isFieldsValidating:$e,resetFields:$e,setFields:$e,setFieldValue:$e,setFieldsValue:$e,validateFields:$e,submit:$e,getInternalHooks:function(){return $e(),{dispatch:$e,initEntityValue:$e,registerField:$e,useSubscribe:$e,setInitialValues:$e,destroyForm:$e,setCallbacks:$e,registerWatch:$e,getFields:$e,setValidateMessages:$e,setPreserve:$e,getInitialValue:$e}}});function rl(e){return e==null?[]:Array.isArray(e)?e:[e]}function Mt(){Mt=function(){return e};var e={},t=Object.prototype,r=t.hasOwnProperty,n=Object.defineProperty||function(M,C,x){M[C]=x.value},o=typeof Symbol=="function"?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(M,C,x){return Object.defineProperty(M,C,{value:x,enumerable:!0,configurable:!0,writable:!0}),M[C]}try{c({},"")}catch{c=function(x,P,N){return x[P]=N}}function l(M,C,x,P){var N=C&&C.prototype instanceof d?C:d,F=Object.create(N.prototype),j=new A(P||[]);return n(F,"_invoke",{value:S(M,x,j)}),F}function u(M,C,x){try{return{type:"normal",arg:M.call(C,x)}}catch(P){return{type:"throw",arg:P}}}e.wrap=l;var f={};function d(){}function g(){}function v(){}var m={};c(m,i,function(){return this});var p=Object.getPrototypeOf,b=p&&p(p(k([])));b&&b!==t&&r.call(b,i)&&(m=b);var w=v.prototype=d.prototype=Object.create(m);function E(M){["next","throw","return"].forEach(function(C){c(M,C,function(x){return this._invoke(C,x)})})}function $(M,C){function x(N,F,j,D){var B=u(M[N],M,F);if(B.type!=="throw"){var V=B.arg,W=V.value;return W&&Ue(W)=="object"&&r.call(W,"__await")?C.resolve(W.__await).then(function(z){x("next",z,j,D)},function(z){x("throw",z,j,D)}):C.resolve(W).then(function(z){V.value=z,j(V)},function(z){return x("throw",z,j,D)})}D(B.arg)}var P;n(this,"_invoke",{value:function(F,j){function D(){return new C(function(B,V){x(F,j,B,V)})}return P=P?P.then(D,D):D()}})}function S(M,C,x){var P="suspendedStart";return function(N,F){if(P==="executing")throw new Error("Generator is already running");if(P==="completed"){if(N==="throw")throw F;return I()}for(x.method=N,x.arg=F;;){var j=x.delegate;if(j){var D=y(j,x);if(D){if(D===f)continue;return D}}if(x.method==="next")x.sent=x._sent=x.arg;else if(x.method==="throw"){if(P==="suspendedStart")throw P="completed",x.arg;x.dispatchException(x.arg)}else x.method==="return"&&x.abrupt("return",x.arg);P="executing";var B=u(M,C,x);if(B.type==="normal"){if(P=x.done?"completed":"suspendedYield",B.arg===f)continue;return{value:B.arg,done:x.done}}B.type==="throw"&&(P="completed",x.method="throw",x.arg=B.arg)}}}function y(M,C){var x=M.iterator[C.method];if(x===void 0){if(C.delegate=null,C.method==="throw"){if(M.iterator.return&&(C.method="return",C.arg=void 0,y(M,C),C.method==="throw"))return f;C.method="throw",C.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var P=u(x,M.iterator,C.arg);if(P.type==="throw")return C.method="throw",C.arg=P.arg,C.delegate=null,f;var N=P.arg;return N?N.done?(C[M.resultName]=N.value,C.next=M.nextLoc,C.method!=="return"&&(C.method="next",C.arg=void 0),C.delegate=null,f):N:(C.method="throw",C.arg=new TypeError("iterator result is not an object"),C.delegate=null,f)}function _(M){var C={tryLoc:M[0]};1 in M&&(C.catchLoc=M[1]),2 in M&&(C.finallyLoc=M[2],C.afterLoc=M[3]),this.tryEntries.push(C)}function R(M){var C=M.completion||{};C.type="normal",delete C.arg,M.completion=C}function A(M){this.tryEntries=[{tryLoc:"root"}],M.forEach(_,this),this.reset(!0)}function k(M){if(M){var C=M[i];if(C)return C.call(M);if(typeof M.next=="function")return M;if(!isNaN(M.length)){var x=-1,P=function N(){for(;++x=0;--N){var F=this.tryEntries[N],j=F.completion;if(F.tryLoc==="root")return P("end");if(F.tryLoc<=this.prev){var D=r.call(F,"catchLoc"),B=r.call(F,"finallyLoc");if(D&&B){if(this.prev=0;--P){var N=this.tryEntries[P];if(N.tryLoc<=this.prev&&r.call(N,"finallyLoc")&&this.prev=0;--x){var P=this.tryEntries[x];if(P.finallyLoc===C)return this.complete(P.completion,P.afterLoc),R(P),f}},catch:function(C){for(var x=this.tryEntries.length-1;x>=0;--x){var P=this.tryEntries[x];if(P.tryLoc===C){var N=P.completion;if(N.type==="throw"){var F=N.arg;R(P)}return F}}throw new Error("illegal catch attempt")},delegateYield:function(C,x,P){return this.delegate={iterator:k(C),resultName:x,nextLoc:P},this.method==="next"&&(this.arg=void 0),f}},e}function Gh(e,t,r,n,o,i,a){try{var s=e[i](a),c=s.value}catch(l){r(l);return}s.done?t(c):Promise.resolve(c).then(n,o)}function oo(e){return function(){var t=this,r=arguments;return new Promise(function(n,o){var i=e.apply(t,r);function a(c){Gh(i,n,o,a,s,"next",c)}function s(c){Gh(i,n,o,a,s,"throw",c)}a(void 0)})}}function $n(){return $n=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function La(e,t,r){return KE()?La=Reflect.construct.bind():La=function(o,i,a){var s=[null];s.push.apply(s,i);var c=Function.bind.apply(o,s),l=new c;return a&&ci(l,a.prototype),l},La.apply(null,arguments)}function XE(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function ol(e){var t=typeof Map=="function"?new Map:void 0;return ol=function(n){if(n===null||!XE(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(n))return t.get(n);t.set(n,o)}function o(){return La(n,arguments,nl(this).constructor)}return o.prototype=Object.create(n.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),ci(o,n)},ol(e)}var YE=/%[sdj%]/g,ZE=function(){};typeof process<"u"&&process.env;function il(e){if(!e||!e.length)return null;var t={};return e.forEach(function(r){var n=r.field;t[n]=t[n]||[],t[n].push(r)}),t}function At(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=i)return s;switch(s){case"%s":return String(r[o++]);case"%d":return Number(r[o++]);case"%j":try{return JSON.stringify(r[o++])}catch{return"[Circular]"}break;default:return s}});return a}return e}function QE(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Qe(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||QE(t)&&typeof e=="string"&&!e)}function JE(e,t,r){var n=[],o=0,i=e.length;function a(s){n.push.apply(n,s||[]),o++,o===i&&r(n)}e.forEach(function(s){t(s,a)})}function qh(e,t,r){var n=0,o=e.length;function i(a){if(a&&a.length){r(a);return}var s=n;n=n+1,s()\[\]\\.,;:\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},li={integer:function(t){return li.number(t)&&parseInt(t,10)===t},float:function(t){return li.number(t)&&!li.integer(t)},array:function(t){return Array.isArray(t)},regexp:function(t){if(t instanceof RegExp)return!0;try{return!!new RegExp(t)}catch{return!1}},date:function(t){return typeof t.getTime=="function"&&typeof t.getMonth=="function"&&typeof t.getYear=="function"&&!isNaN(t.getTime())},number:function(t){return isNaN(t)?!1:typeof t=="number"},object:function(t){return typeof t=="object"&&!li.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(Qh.email)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(ix())},hex:function(t){return typeof t=="string"&&!!t.match(Qh.hex)}},ax=function(t,r,n,o,i){if(t.required&&r===void 0){Zh(t,r,n,o,i);return}var a=["integer","float","array","regexp","object","method","email","number","date","url","hex"],s=t.type;a.indexOf(s)>-1?li[s](r)||o.push(At(i.messages.types[s],t.fullField,t.type)):s&&typeof r!==t.type&&o.push(At(i.messages.types[s],t.fullField,t.type))},sx=function(t,r,n,o,i){var a=typeof t.len=="number",s=typeof t.min=="number",c=typeof t.max=="number",l=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,u=r,f=null,d=typeof r=="number",g=typeof r=="string",v=Array.isArray(r);if(d?f="number":g?f="string":v&&(f="array"),!f)return!1;v&&(u=r.length),g&&(u=r.replace(l,"_").length),a?u!==t.len&&o.push(At(i.messages[f].len,t.fullField,t.len)):s&&!c&&ut.max?o.push(At(i.messages[f].max,t.fullField,t.max)):s&&c&&(ut.max)&&o.push(At(i.messages[f].range,t.fullField,t.min,t.max))},io="enum",cx=function(t,r,n,o,i){t[io]=Array.isArray(t[io])?t[io]:[],t[io].indexOf(r)===-1&&o.push(At(i.messages[io],t.fullField,t[io].join(", ")))},lx=function(t,r,n,o,i){if(t.pattern){if(t.pattern instanceof RegExp)t.pattern.lastIndex=0,t.pattern.test(r)||o.push(At(i.messages.pattern.mismatch,t.fullField,r,t.pattern));else if(typeof t.pattern=="string"){var a=new RegExp(t.pattern);a.test(r)||o.push(At(i.messages.pattern.mismatch,t.fullField,r,t.pattern))}}},de={required:Zh,whitespace:ox,type:ax,range:sx,enum:cx,pattern:lx},ux=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r,"string")&&!t.required)return n();de.required(t,r,o,a,i,"string"),Qe(r,"string")||(de.type(t,r,o,a,i),de.range(t,r,o,a,i),de.pattern(t,r,o,a,i),t.whitespace===!0&&de.whitespace(t,r,o,a,i))}n(a)},fx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&de.type(t,r,o,a,i)}n(a)},dx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(r===""&&(r=void 0),Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&(de.type(t,r,o,a,i),de.range(t,r,o,a,i))}n(a)},hx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&de.type(t,r,o,a,i)}n(a)},gx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),Qe(r)||de.type(t,r,o,a,i)}n(a)},mx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&(de.type(t,r,o,a,i),de.range(t,r,o,a,i))}n(a)},px=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&(de.type(t,r,o,a,i),de.range(t,r,o,a,i))}n(a)},vx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(r==null&&!t.required)return n();de.required(t,r,o,a,i,"array"),r!=null&&(de.type(t,r,o,a,i),de.range(t,r,o,a,i))}n(a)},bx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&de.type(t,r,o,a,i)}n(a)},yx="enum",wx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i),r!==void 0&&de[yx](t,r,o,a,i)}n(a)},Sx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r,"string")&&!t.required)return n();de.required(t,r,o,a,i),Qe(r,"string")||de.pattern(t,r,o,a,i)}n(a)},Cx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r,"date")&&!t.required)return n();if(de.required(t,r,o,a,i),!Qe(r,"date")){var c;r instanceof Date?c=r:c=new Date(r),de.type(t,c,o,a,i),c&&de.range(t,c.getTime(),o,a,i)}}n(a)},Ex=function(t,r,n,o,i){var a=[],s=Array.isArray(r)?"array":typeof r;de.required(t,r,o,a,i,s),n(a)},al=function(t,r,n,o,i){var a=t.type,s=[],c=t.required||!t.required&&o.hasOwnProperty(t.field);if(c){if(Qe(r,a)&&!t.required)return n();de.required(t,r,o,s,i,a),Qe(r,a)||de.type(t,r,o,s,i)}n(s)},xx=function(t,r,n,o,i){var a=[],s=t.required||!t.required&&o.hasOwnProperty(t.field);if(s){if(Qe(r)&&!t.required)return n();de.required(t,r,o,a,i)}n(a)},ui={string:ux,method:fx,number:dx,boolean:hx,regexp:gx,integer:mx,float:px,array:vx,object:bx,enum:wx,pattern:Sx,date:Cx,url:al,hex:al,email:al,required:Ex,any:xx};function sl(){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 t=JSON.parse(JSON.stringify(this));return t.clone=this.clone,t}}}var cl=sl(),fi=function(){function e(r){this.rules=null,this._messages=cl,this.define(r)}var t=e.prototype;return t.define=function(n){var o=this;if(!n)throw new Error("Cannot configure a schema with no rules");if(typeof n!="object"||Array.isArray(n))throw new Error("Rules must be an object");this.rules={},Object.keys(n).forEach(function(i){var a=n[i];o.rules[i]=Array.isArray(a)?a:[a]})},t.messages=function(n){return n&&(this._messages=Yh(sl(),n)),this._messages},t.validate=function(n,o,i){var a=this;o===void 0&&(o={}),i===void 0&&(i=function(){});var s=n,c=o,l=i;if(typeof c=="function"&&(l=c,c={}),!this.rules||Object.keys(this.rules).length===0)return l&&l(null,s),Promise.resolve(s);function u(m){var p=[],b={};function w($){if(Array.isArray($)){var S;p=(S=p).concat.apply(S,$)}else p.push($)}for(var E=0;E3&&arguments[3]!==void 0?arguments[3]:!1;return t.length&&n&&r===void 0&&!eg(e,t.slice(0,-1))?e:tg(e,t,r,n)}function Da(e){return Array.isArray(e)?Px(e):Ue(e)==="object"&&e!==null?$x(e):e}function $x(e){if(Object.getPrototypeOf(e)===Object.prototype){var t={};for(var r in e)t[r]=Da(e[r]);return t}return e}function Px(e){return e.map(function(t){return Da(t)})}function qe(e){return rl(e)}function on(e,t){var r=eg(e,t);return r}function an(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,o=Ox(e,t,r,n);return o}function rg(e,t){var r={};return t.forEach(function(n){var o=on(e,n);r=an(r,n,o)}),r}function di(e,t){return e&&e.some(function(r){return ig(r,t)})}function ng(e){return Ue(e)==="object"&&e!==null&&Object.getPrototypeOf(e)===Object.prototype}function og(e,t){var r=Array.isArray(e)?Q(e):H({},e);return t&&Object.keys(t).forEach(function(n){var o=r[n],i=t[n],a=ng(o)&&ng(i);r[n]=a?og(o,i||{}):Da(i)}),r}function hi(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=n||r<0||r>=n)return e;var o=e[t],i=t-r;return i>0?[].concat(Q(e.slice(0,r)),[o],Q(e.slice(r,t)),Q(e.slice(t+1,n))):i<0?[].concat(Q(e.slice(0,t)),Q(e.slice(t+1,r+1)),[o],Q(e.slice(r+1,n))):e}var Mx=fi;function Ax(e,t){return e.replace(/\$\{\w+\}/g,function(r){var n=r.slice(2,-1);return t[n]})}var sg="CODE_LOGIC_ERROR";function ll(e,t,r,n,o){return ul.apply(this,arguments)}function ul(){return ul=oo(Mt().mark(function e(t,r,n,o,i){var a,s,c,l,u,f,d,g,v;return Mt().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:return a=H({},n),delete a.ruleIndex,a.validator&&(s=a.validator,a.validator=function(){try{return s.apply(void 0,arguments)}catch(b){return console.error(b),Promise.reject(sg)}}),c=null,a&&a.type==="array"&&a.defaultField&&(c=a.defaultField,delete a.defaultField),l=new Mx(oe({},t,[a])),u=hi({},Jh,o.validateMessages),l.messages(u),f=[],p.prev=9,p.next=12,Promise.resolve(l.validate(oe({},t,r),H({},o)));case 12:p.next=17;break;case 14:p.prev=14,p.t0=p.catch(9),p.t0.errors&&(f=p.t0.errors.map(function(b,w){var E=b.message,$=E===sg?u.default:E;return h.isValidElement($)?h.cloneElement($,{key:"error_".concat(w)}):$}));case 17:if(!(!f.length&&c)){p.next=22;break}return p.next=20,Promise.all(r.map(function(b,w){return ll("".concat(t,".").concat(w),b,c,o,i)}));case 20:return d=p.sent,p.abrupt("return",d.reduce(function(b,w){return[].concat(Q(b),Q(w))},[]));case 22:return g=H(H({},n),{},{name:t,enum:(n.enum||[]).join(", ")},i),v=f.map(function(b){return typeof b=="string"?Ax(b,g):b}),p.abrupt("return",v);case 25:case"end":return p.stop()}},e,null,[[9,14]])})),ul.apply(this,arguments)}function Rx(e,t,r,n,o,i){var a=e.join("."),s=r.map(function(u,f){var d=u.validator,g=H(H({},u),{},{ruleIndex:f});return d&&(g.validator=function(v,m,p){var b=!1,w=function(){for(var S=arguments.length,y=new Array(S),_=0;_0&&arguments[0]!==void 0?arguments[0]:Wt;if(o.validatePromise===f){var S;o.validatePromise=null;var y=[],_=[];(S=$.forEach)===null||S===void 0||S.call($,function(R){var A=R.rule.warningOnly,k=R.errors,I=k===void 0?Wt:k;A?_.push.apply(_,Q(I)):y.push.apply(y,Q(I))}),o.errors=y,o.warnings=_,o.triggerMetaEvent(),o.reRender()}}),E});return o.validatePromise=f,o.dirty=!0,o.errors=Wt,o.warnings=Wt,o.triggerMetaEvent(),o.reRender(),f},o.isFieldValidating=function(){return!!o.validatePromise},o.isFieldTouched=function(){return o.touched},o.isFieldDirty=function(){if(o.dirty||o.props.initialValue!==void 0)return!0;var c=o.props.fieldContext,l=c.getInternalHooks(On),u=l.getInitialValue;return u(o.getNamePath())!==void 0},o.getErrors=function(){return o.errors},o.getWarnings=function(){return o.warnings},o.isListField=function(){return o.props.isListField},o.isList=function(){return o.props.isList},o.isPreserve=function(){return o.props.preserve},o.getMeta=function(){o.prevValidating=o.isFieldValidating();var c={touched:o.isFieldTouched(),validating:o.prevValidating,errors:o.errors,warnings:o.warnings,name:o.getNamePath(),validated:o.validatePromise===null};return c},o.getOnlyChild=function(c){if(typeof c=="function"){var l=o.getMeta();return H(H({},o.getOnlyChild(c(o.getControlled(),l,o.props.fieldContext))),{},{isFunction:!0})}var u=Zn(c);return u.length!==1||!h.isValidElement(u[0])?{child:u,isFunction:!1}:{child:u[0],isFunction:!1}},o.getValue=function(c){var l=o.props.fieldContext.getFieldsValue,u=o.getNamePath();return on(c||l(!0),u)},o.getControlled=function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},l=o.props,u=l.trigger,f=l.validateTrigger,d=l.getValueFromEvent,g=l.normalize,v=l.valuePropName,m=l.getValueProps,p=l.fieldContext,b=f!==void 0?f:p.validateTrigger,w=o.getNamePath(),E=p.getInternalHooks,$=p.getFieldsValue,S=E(On),y=S.dispatch,_=o.getValue(),R=m||function(M){return oe({},v,M)},A=c[u],k=H(H({},c),R(_));k[u]=function(){o.touched=!0,o.dirty=!0,o.triggerMetaEvent();for(var M,C=arguments.length,x=new Array(C),P=0;P=0&&A<=k.length?(l.keys=[].concat(Q(l.keys.slice(0,A)),[l.id],Q(l.keys.slice(A))),w([].concat(Q(k.slice(0,A)),[R],Q(k.slice(A))))):(l.keys=[].concat(Q(l.keys),[l.id]),w([].concat(Q(k),[R]))),l.id+=1},remove:function(R){var A=$(),k=new Set(Array.isArray(R)?R:[R]);k.size<=0||(l.keys=l.keys.filter(function(I,M){return!k.has(M)}),w(A.filter(function(I,M){return!k.has(M)})))},move:function(R,A){if(R!==A){var k=$();R<0||R>=k.length||A<0||A>=k.length||(l.keys=ag(l.keys,R,A),w(ag(k,R,A)))}}},y=b||[];return Array.isArray(y)||(y=[]),o(y.map(function(_,R){var A=l.keys[R];return A===void 0&&(l.keys[R]=l.id,A=l.keys[R],l.id+=1),{name:R,key:A,isListField:!0}}),S,m)})))};function Dx(e){var t=!1,r=e.length,n=[];return e.length?new Promise(function(o,i){e.forEach(function(a,s){a.catch(function(c){return t=!0,c}).then(function(c){r-=1,n[s]=c,!(r>0)&&(t&&i(n),o(n))})})}):Promise.resolve([])}var ug="__@field_split__";function gl(e){return e.map(function(t){return"".concat(Ue(t),":").concat(t)}).join(ug)}var ao=function(){function e(){mr(this,e),this.kvs=new Map}return pr(e,[{key:"set",value:function(r,n){this.kvs.set(gl(r),n)}},{key:"get",value:function(r){return this.kvs.get(gl(r))}},{key:"update",value:function(r,n){var o=this.get(r),i=n(o);i?this.set(r,i):this.delete(r)}},{key:"delete",value:function(r){this.kvs.delete(gl(r))}},{key:"map",value:function(r){return Q(this.kvs.entries()).map(function(n){var o=G(n,2),i=o[0],a=o[1],s=i.split(ug);return r({key:s.map(function(c){var l=c.match(/^([^:]*):(.*)$/),u=G(l,3),f=u[1],d=u[2];return f==="number"?Number(d):d}),value:a})})}},{key:"toJSON",value:function(){var r={};return this.map(function(n){var o=n.key,i=n.value;return r[o.join(".")]=i,null}),r}}]),e}(),zx=["name","errors"],Hx=pr(function e(t){var r=this;mr(this,e),this.formHooked=!1,this.forceRootUpdate=void 0,this.subscribable=!0,this.store={},this.fieldEntities=[],this.initialValues={},this.callbacks={},this.validateMessages=null,this.preserve=null,this.lastValidatePromise=null,this.getForm=function(){return{getFieldValue:r.getFieldValue,getFieldsValue:r.getFieldsValue,getFieldError:r.getFieldError,getFieldWarning:r.getFieldWarning,getFieldsError:r.getFieldsError,isFieldsTouched:r.isFieldsTouched,isFieldTouched:r.isFieldTouched,isFieldValidating:r.isFieldValidating,isFieldsValidating:r.isFieldsValidating,resetFields:r.resetFields,setFields:r.setFields,setFieldValue:r.setFieldValue,setFieldsValue:r.setFieldsValue,validateFields:r.validateFields,submit:r.submit,_init:!0,getInternalHooks:r.getInternalHooks}},this.getInternalHooks=function(n){return n===On?(r.formHooked=!0,{dispatch:r.dispatch,initEntityValue:r.initEntityValue,registerField:r.registerField,useSubscribe:r.useSubscribe,setInitialValues:r.setInitialValues,destroyForm:r.destroyForm,setCallbacks:r.setCallbacks,setValidateMessages:r.setValidateMessages,getFields:r.getFields,setPreserve:r.setPreserve,getInitialValue:r.getInitialValue,registerWatch:r.registerWatch}):(vr(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)},this.useSubscribe=function(n){r.subscribable=n},this.prevWithoutPreserves=null,this.setInitialValues=function(n,o){if(r.initialValues=n||{},o){var i,a=hi({},n,r.store);(i=r.prevWithoutPreserves)===null||i===void 0||i.map(function(s){var c=s.key;a=an(a,c,on(n,c))}),r.prevWithoutPreserves=null,r.updateStore(a)}},this.destroyForm=function(){var n=new ao;r.getFieldEntities(!0).forEach(function(o){r.isMergedPreserve(o.isPreserve())||n.set(o.getNamePath(),!0)}),r.prevWithoutPreserves=n},this.getInitialValue=function(n){var o=on(r.initialValues,n);return n.length?Da(o):o},this.setCallbacks=function(n){r.callbacks=n},this.setValidateMessages=function(n){r.validateMessages=n},this.setPreserve=function(n){r.preserve=n},this.watchList=[],this.registerWatch=function(n){return r.watchList.push(n),function(){r.watchList=r.watchList.filter(function(o){return o!==n})}},this.notifyWatch=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(r.watchList.length){var o=r.getFieldsValue();r.watchList.forEach(function(i){i(o,n)})}},this.timeoutId=null,this.warningUnhooked=function(){},this.updateStore=function(n){r.store=n},this.getFieldEntities=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return n?r.fieldEntities.filter(function(o){return o.getNamePath().length}):r.fieldEntities},this.getFieldsMap=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,o=new ao;return r.getFieldEntities(n).forEach(function(i){var a=i.getNamePath();o.set(a,i)}),o},this.getFieldEntitiesForNamePathList=function(n){if(!n)return r.getFieldEntities(!0);var o=r.getFieldsMap(!0);return n.map(function(i){var a=qe(i);return o.get(a)||{INVALIDATE_NAME_PATH:qe(i)}})},this.getFieldsValue=function(n,o){if(r.warningUnhooked(),n===!0&&!o)return r.store;var i=r.getFieldEntitiesForNamePathList(Array.isArray(n)?n:null),a=[];return i.forEach(function(s){var c,l="INVALIDATE_NAME_PATH"in s?s.INVALIDATE_NAME_PATH:s.getNamePath();if(!(!n&&(!((c=s.isListField)===null||c===void 0)&&c.call(s))))if(!o)a.push(l);else{var u="getMeta"in s?s.getMeta():null;o(u)&&a.push(l)}}),rg(r.store,a.map(qe))},this.getFieldValue=function(n){r.warningUnhooked();var o=qe(n);return on(r.store,o)},this.getFieldsError=function(n){r.warningUnhooked();var o=r.getFieldEntitiesForNamePathList(n);return o.map(function(i,a){return i&&!("INVALIDATE_NAME_PATH"in i)?{name:i.getNamePath(),errors:i.getErrors(),warnings:i.getWarnings()}:{name:qe(n[a]),errors:[],warnings:[]}})},this.getFieldError=function(n){r.warningUnhooked();var o=qe(n),i=r.getFieldsError([o])[0];return i.errors},this.getFieldWarning=function(n){r.warningUnhooked();var o=qe(n),i=r.getFieldsError([o])[0];return i.warnings},this.isFieldsTouched=function(){r.warningUnhooked();for(var n=arguments.length,o=new Array(n),i=0;i0&&arguments[0]!==void 0?arguments[0]:{},o=new ao,i=r.getFieldEntities(!0);i.forEach(function(c){var l=c.props.initialValue,u=c.getNamePath();if(l!==void 0){var f=o.get(u)||new Set;f.add({entity:c,value:l}),o.set(u,f)}});var a=function(l){l.forEach(function(u){var f=u.props.initialValue;if(f!==void 0){var d=u.getNamePath(),g=r.getInitialValue(d);if(g!==void 0)vr(!1,"Form already set 'initialValues' with path '".concat(d.join("."),"'. Field can not overwrite it."));else{var v=o.get(d);if(v&&v.size>1)vr(!1,"Multiple Field with path '".concat(d.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(v){var m=r.getFieldValue(d);(!n.skipExist||m===void 0)&&r.updateStore(an(r.store,d,Q(v)[0].value))}}}})},s;n.entities?s=n.entities:n.namePathList?(s=[],n.namePathList.forEach(function(c){var l=o.get(c);if(l){var u;(u=s).push.apply(u,Q(Q(l).map(function(f){return f.entity})))}})):s=i,a(s)},this.resetFields=function(n){r.warningUnhooked();var o=r.store;if(!n){r.updateStore(hi({},r.initialValues)),r.resetWithFieldInitialValue(),r.notifyObservers(o,null,{type:"reset"}),r.notifyWatch();return}var i=n.map(qe);i.forEach(function(a){var s=r.getInitialValue(a);r.updateStore(an(r.store,a,s))}),r.resetWithFieldInitialValue({namePathList:i}),r.notifyObservers(o,i,{type:"reset"}),r.notifyWatch(i)},this.setFields=function(n){r.warningUnhooked();var o=r.store,i=[];n.forEach(function(a){var s=a.name;a.errors;var c=Bt(a,zx),l=qe(s);i.push(l),"value"in c&&r.updateStore(an(r.store,l,c.value)),r.notifyObservers(o,[l],{type:"setField",data:a})}),r.notifyWatch(i)},this.getFields=function(){var n=r.getFieldEntities(!0),o=n.map(function(i){var a=i.getNamePath(),s=i.getMeta(),c=H(H({},s),{},{name:a,value:r.getFieldValue(a)});return Object.defineProperty(c,"originRCField",{value:!0}),c});return o},this.initEntityValue=function(n){var o=n.props.initialValue;if(o!==void 0){var i=n.getNamePath(),a=on(r.store,i);a===void 0&&r.updateStore(an(r.store,i,o))}},this.isMergedPreserve=function(n){var o=n!==void 0?n:r.preserve;return o??!0},this.registerField=function(n){r.fieldEntities.push(n);var o=n.getNamePath();if(r.notifyWatch([o]),n.props.initialValue!==void 0){var i=r.store;r.resetWithFieldInitialValue({entities:[n],skipExist:!0}),r.notifyObservers(i,[n.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(a,s){var c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(r.fieldEntities=r.fieldEntities.filter(function(f){return f!==n}),!r.isMergedPreserve(s)&&(!a||c.length>1)){var l=a?void 0:r.getInitialValue(o);if(o.length&&r.getFieldValue(o)!==l&&r.fieldEntities.every(function(f){return!ig(f.getNamePath(),o)})){var u=r.store;r.updateStore(an(u,o,l,!0)),r.notifyObservers(u,[o],{type:"remove"}),r.triggerDependenciesUpdate(u,o)}}r.notifyWatch([o])}},this.dispatch=function(n){switch(n.type){case"updateValue":{var o=n.namePath,i=n.value;r.updateValue(o,i);break}case"validateField":{var a=n.namePath,s=n.triggerName;r.validateFields([a],{triggerName:s});break}}},this.notifyObservers=function(n,o,i){if(r.subscribable){var a=H(H({},i),{},{store:r.getFieldsValue(!0)});r.getFieldEntities().forEach(function(s){var c=s.onStoreChange;c(n,o,a)})}else r.forceRootUpdate()},this.triggerDependenciesUpdate=function(n,o){var i=r.getDependencyChildrenFields(o);return i.length&&r.validateFields(i),r.notifyObservers(n,i,{type:"dependenciesUpdate",relatedFields:[o].concat(Q(i))}),i},this.updateValue=function(n,o){var i=qe(n),a=r.store;r.updateStore(an(r.store,i,o)),r.notifyObservers(a,[i],{type:"valueUpdate",source:"internal"}),r.notifyWatch([i]);var s=r.triggerDependenciesUpdate(a,i),c=r.callbacks.onValuesChange;if(c){var l=rg(r.store,[i]);c(l,r.getFieldsValue())}r.triggerOnFieldsChange([i].concat(Q(s)))},this.setFieldsValue=function(n){r.warningUnhooked();var o=r.store;if(n){var i=hi(r.store,n);r.updateStore(i)}r.notifyObservers(o,null,{type:"valueUpdate",source:"external"}),r.notifyWatch()},this.setFieldValue=function(n,o){r.setFields([{name:n,value:o}])},this.getDependencyChildrenFields=function(n){var o=new Set,i=[],a=new ao;r.getFieldEntities().forEach(function(c){var l=c.props.dependencies;(l||[]).forEach(function(u){var f=qe(u);a.update(f,function(){var d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return d.add(c),d})})});var s=function c(l){var u=a.get(l)||new Set;u.forEach(function(f){if(!o.has(f)){o.add(f);var d=f.getNamePath();f.isFieldDirty()&&d.length&&(i.push(d),c(d))}})};return s(n),i},this.triggerOnFieldsChange=function(n,o){var i=r.callbacks.onFieldsChange;if(i){var a=r.getFields();if(o){var s=new ao;o.forEach(function(l){var u=l.name,f=l.errors;s.set(u,f)}),a.forEach(function(l){l.errors=s.get(l.name)||l.errors})}var c=a.filter(function(l){var u=l.name;return di(n,u)});i(c,a)}},this.validateFields=function(n,o){r.warningUnhooked();var i=!!n,a=i?n.map(qe):[],s=[];r.getFieldEntities(!0).forEach(function(u){if(i||a.push(u.getNamePath()),o!=null&&o.recursive&&i){var f=u.getNamePath();f.every(function(v,m){return n[m]===v||n[m]===void 0})&&a.push(f)}if(!(!u.props.rules||!u.props.rules.length)){var d=u.getNamePath();if(!i||di(a,d)){var g=u.validateRules(H({validateMessages:H(H({},Jh),r.validateMessages)},o));s.push(g.then(function(){return{name:d,errors:[],warnings:[]}}).catch(function(v){var m,p=[],b=[];return(m=v.forEach)===null||m===void 0||m.call(v,function(w){var E=w.rule.warningOnly,$=w.errors;E?b.push.apply(b,Q($)):p.push.apply(p,Q($))}),p.length?Promise.reject({name:d,errors:p,warnings:b}):{name:d,errors:p,warnings:b}}))}}});var c=Dx(s);r.lastValidatePromise=c,c.catch(function(u){return u}).then(function(u){var f=u.map(function(d){var g=d.name;return g});r.notifyObservers(r.store,f,{type:"validateFinish"}),r.triggerOnFieldsChange(f,u)});var l=c.then(function(){return r.lastValidatePromise===c?Promise.resolve(r.getFieldsValue(a)):Promise.reject([])}).catch(function(u){var f=u.filter(function(d){return d&&d.errors.length});return Promise.reject({values:r.getFieldsValue(a),errorFields:f,outOfDate:r.lastValidatePromise!==c})});return l.catch(function(u){return u}),l},this.submit=function(){r.warningUnhooked(),r.validateFields().then(function(n){var o=r.callbacks.onFinish;if(o)try{o(n)}catch(i){console.error(i)}}).catch(function(n){var o=r.callbacks.onFinishFailed;o&&o(n)})},this.forceRootUpdate=t});function fg(e){var t=h.useRef(),r=h.useState({}),n=G(r,2),o=n[1];if(!t.current)if(e)t.current=e;else{var i=function(){o({})},a=new Hx(i);t.current=a.getForm()}return[t.current]}var ml=h.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),dg=function(t){var r=t.validateMessages,n=t.onFormChange,o=t.onFormFinish,i=t.children,a=h.useContext(ml),s=h.useRef({});return h.createElement(ml.Provider,{value:H(H({},a),{},{validateMessages:H(H({},a.validateMessages),r),triggerFormChange:function(l,u){n&&n(l,{changedFields:u,forms:s.current}),a.triggerFormChange(l,u)},triggerFormFinish:function(l,u){o&&o(l,{values:u,forms:s.current}),a.triggerFormFinish(l,u)},registerForm:function(l,u){l&&(s.current=H(H({},s.current),{},oe({},l,u))),a.registerForm(l,u)},unregisterForm:function(l){var u=H({},s.current);delete u[l],s.current=u,a.unregisterForm(l)}})},i)},Bx=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed"],Wx=function(t,r){var n=t.name,o=t.initialValues,i=t.fields,a=t.form,s=t.preserve,c=t.children,l=t.component,u=l===void 0?"form":l,f=t.validateMessages,d=t.validateTrigger,g=d===void 0?"onChange":d,v=t.onValuesChange,m=t.onFieldsChange,p=t.onFinish,b=t.onFinishFailed,w=Bt(t,Bx),E=h.useContext(ml),$=fg(a),S=G($,1),y=S[0],_=y.getInternalHooks(On),R=_.useSubscribe,A=_.setInitialValues,k=_.setCallbacks,I=_.setValidateMessages,M=_.setPreserve,C=_.destroyForm;h.useImperativeHandle(r,function(){return y}),h.useEffect(function(){return E.registerForm(n,y),function(){E.unregisterForm(n)}},[E,y,n]),I(H(H({},E.validateMessages),f)),k({onValuesChange:v,onFieldsChange:function(W){if(E.triggerFormChange(n,W),m){for(var z=arguments.length,se=new Array(z>1?z-1:0),J=1;J{const{locale:t={},children:r,_ANT_MARK__:n}=e;h.useEffect(()=>(pg(t&&t.Modal),()=>{pg()}),[t]);const o=h.useMemo(()=>Object.assign(Object.assign({},t),{exist:!0}),[t]);return h.createElement(vg.Provider,{value:o},r)},Yx="5.3.2",za=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"];function lt(e,t){Zx(e)&&(e="100%");var r=Qx(e);return e=t===360?e:Math.min(t,Math.max(0,parseFloat(e))),r&&(e=parseInt(String(e*t),10)/100),Math.abs(e-t)<1e-6?1:(t===360?e=(e<0?e%t+t:e%t)/parseFloat(String(t)):e=e%t/parseFloat(String(t)),e)}function Ha(e){return Math.min(1,Math.max(0,e))}function Zx(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function Qx(e){return typeof e=="string"&&e.indexOf("%")!==-1}function bg(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function Ba(e){return e<=1?"".concat(Number(e)*100,"%"):e}function Pn(e){return e.length===1?"0"+e:String(e)}function Jx(e,t,r){return{r:lt(e,255)*255,g:lt(t,255)*255,b:lt(r,255)*255}}function yg(e,t,r){e=lt(e,255),t=lt(t,255),r=lt(r,255);var n=Math.max(e,t,r),o=Math.min(e,t,r),i=0,a=0,s=(n+o)/2;if(n===o)a=0,i=0;else{var c=n-o;switch(a=s>.5?c/(2-n-o):c/(n+o),n){case e:i=(t-r)/c+(t1&&(r-=1),r<1/6?e+(t-e)*(6*r):r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function e_(e,t,r){var n,o,i;if(e=lt(e,360),t=lt(t,100),r=lt(r,100),t===0)o=r,i=r,n=r;else{var a=r<.5?r*(1+t):r+t-r*t,s=2*r-a;n=bl(s,a,e+1/3),o=bl(s,a,e),i=bl(s,a,e-1/3)}return{r:n*255,g:o*255,b:i*255}}function yl(e,t,r){e=lt(e,255),t=lt(t,255),r=lt(r,255);var n=Math.max(e,t,r),o=Math.min(e,t,r),i=0,a=n,s=n-o,c=n===0?0:s/n;if(n===o)i=0;else{switch(n){case e:i=(t-r)/s+(t>16,g:(e&65280)>>8,b:e&255}}var Sl={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function so(e){var t={r:0,g:0,b:0},r=1,n=null,o=null,i=null,a=!1,s=!1;return typeof e=="string"&&(e=s_(e)),typeof e=="object"&&(Nr(e.r)&&Nr(e.g)&&Nr(e.b)?(t=Jx(e.r,e.g,e.b),a=!0,s=String(e.r).substr(-1)==="%"?"prgb":"rgb"):Nr(e.h)&&Nr(e.s)&&Nr(e.v)?(n=Ba(e.s),o=Ba(e.v),t=t_(e.h,n,o),a=!0,s="hsv"):Nr(e.h)&&Nr(e.s)&&Nr(e.l)&&(n=Ba(e.s),i=Ba(e.l),t=e_(e.h,n,i),a=!0,s="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(r=e.a)),r=bg(r),{ok:a,format:e.format||s,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:r}}var i_="[-\\+]?\\d+%?",a_="[-\\+]?\\d*\\.\\d+%?",sn="(?:".concat(a_,")|(?:").concat(i_,")"),Cl="[\\s|\\(]+(".concat(sn,")[,|\\s]+(").concat(sn,")[,|\\s]+(").concat(sn,")\\s*\\)?"),El="[\\s|\\(]+(".concat(sn,")[,|\\s]+(").concat(sn,")[,|\\s]+(").concat(sn,")[,|\\s]+(").concat(sn,")\\s*\\)?"),Yt={CSS_UNIT:new RegExp(sn),rgb:new RegExp("rgb"+Cl),rgba:new RegExp("rgba"+El),hsl:new RegExp("hsl"+Cl),hsla:new RegExp("hsla"+El),hsv:new RegExp("hsv"+Cl),hsva:new RegExp("hsva"+El),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function s_(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var t=!1;if(Sl[e])e=Sl[e],t=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var r=Yt.rgb.exec(e);return r?{r:r[1],g:r[2],b:r[3]}:(r=Yt.rgba.exec(e),r?{r:r[1],g:r[2],b:r[3],a:r[4]}:(r=Yt.hsl.exec(e),r?{h:r[1],s:r[2],l:r[3]}:(r=Yt.hsla.exec(e),r?{h:r[1],s:r[2],l:r[3],a:r[4]}:(r=Yt.hsv.exec(e),r?{h:r[1],s:r[2],v:r[3]}:(r=Yt.hsva.exec(e),r?{h:r[1],s:r[2],v:r[3],a:r[4]}:(r=Yt.hex8.exec(e),r?{r:Nt(r[1]),g:Nt(r[2]),b:Nt(r[3]),a:wg(r[4]),format:t?"name":"hex8"}:(r=Yt.hex6.exec(e),r?{r:Nt(r[1]),g:Nt(r[2]),b:Nt(r[3]),format:t?"name":"hex"}:(r=Yt.hex4.exec(e),r?{r:Nt(r[1]+r[1]),g:Nt(r[2]+r[2]),b:Nt(r[3]+r[3]),a:wg(r[4]+r[4]),format:t?"name":"hex8"}:(r=Yt.hex3.exec(e),r?{r:Nt(r[1]+r[1]),g:Nt(r[2]+r[2]),b:Nt(r[3]+r[3]),format:t?"name":"hex"}:!1)))))))))}function Nr(e){return!!Yt.CSS_UNIT.exec(String(e))}var ht=function(){function e(t,r){t===void 0&&(t=""),r===void 0&&(r={});var n;if(t instanceof e)return t;typeof t=="number"&&(t=o_(t)),this.originalInput=t;var o=so(t);this.originalInput=t,this.r=o.r,this.g=o.g,this.b=o.b,this.a=o.a,this.roundA=Math.round(100*this.a)/100,this.format=(n=r.format)!==null&&n!==void 0?n:o.format,this.gradientType=r.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=o.ok}return e.prototype.isDark=function(){return this.getBrightness()<128},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},e.prototype.getLuminance=function(){var t=this.toRgb(),r,n,o,i=t.r/255,a=t.g/255,s=t.b/255;return i<=.03928?r=i/12.92:r=Math.pow((i+.055)/1.055,2.4),a<=.03928?n=a/12.92:n=Math.pow((a+.055)/1.055,2.4),s<=.03928?o=s/12.92:o=Math.pow((s+.055)/1.055,2.4),.2126*r+.7152*n+.0722*o},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(t){return this.a=bg(t),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){var t=this.toHsl().s;return t===0},e.prototype.toHsv=function(){var t=yl(this.r,this.g,this.b);return{h:t.h*360,s:t.s,v:t.v,a:this.a}},e.prototype.toHsvString=function(){var t=yl(this.r,this.g,this.b),r=Math.round(t.h*360),n=Math.round(t.s*100),o=Math.round(t.v*100);return this.a===1?"hsv(".concat(r,", ").concat(n,"%, ").concat(o,"%)"):"hsva(".concat(r,", ").concat(n,"%, ").concat(o,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var t=yg(this.r,this.g,this.b);return{h:t.h*360,s:t.s,l:t.l,a:this.a}},e.prototype.toHslString=function(){var t=yg(this.r,this.g,this.b),r=Math.round(t.h*360),n=Math.round(t.s*100),o=Math.round(t.l*100);return this.a===1?"hsl(".concat(r,", ").concat(n,"%, ").concat(o,"%)"):"hsla(".concat(r,", ").concat(n,"%, ").concat(o,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(t){return t===void 0&&(t=!1),wl(this.r,this.g,this.b,t)},e.prototype.toHexString=function(t){return t===void 0&&(t=!1),"#"+this.toHex(t)},e.prototype.toHex8=function(t){return t===void 0&&(t=!1),r_(this.r,this.g,this.b,this.a,t)},e.prototype.toHex8String=function(t){return t===void 0&&(t=!1),"#"+this.toHex8(t)},e.prototype.toHexShortString=function(t){return t===void 0&&(t=!1),this.a===1?this.toHexString(t):this.toHex8String(t)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var t=Math.round(this.r),r=Math.round(this.g),n=Math.round(this.b);return this.a===1?"rgb(".concat(t,", ").concat(r,", ").concat(n,")"):"rgba(".concat(t,", ").concat(r,", ").concat(n,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var t=function(r){return"".concat(Math.round(lt(r,255)*100),"%")};return{r:t(this.r),g:t(this.g),b:t(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var t=function(r){return Math.round(lt(r,255)*100)};return this.a===1?"rgb(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%)"):"rgba(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var t="#"+wl(this.r,this.g,this.b,!1),r=0,n=Object.entries(Sl);r=0,i=!r&&o&&(t.startsWith("hex")||t==="name");return i?t==="name"&&this.a===0?this.toName():this.toRgbString():(t==="rgb"&&(n=this.toRgbString()),t==="prgb"&&(n=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(n=this.toHexString()),t==="hex3"&&(n=this.toHexString(!0)),t==="hex4"&&(n=this.toHex8String(!0)),t==="hex8"&&(n=this.toHex8String()),t==="name"&&(n=this.toName()),t==="hsl"&&(n=this.toHslString()),t==="hsv"&&(n=this.toHsvString()),n||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(t){t===void 0&&(t=10);var r=this.toHsl();return r.l+=t/100,r.l=Ha(r.l),new e(r)},e.prototype.brighten=function(t){t===void 0&&(t=10);var r=this.toRgb();return r.r=Math.max(0,Math.min(255,r.r-Math.round(255*-(t/100)))),r.g=Math.max(0,Math.min(255,r.g-Math.round(255*-(t/100)))),r.b=Math.max(0,Math.min(255,r.b-Math.round(255*-(t/100)))),new e(r)},e.prototype.darken=function(t){t===void 0&&(t=10);var r=this.toHsl();return r.l-=t/100,r.l=Ha(r.l),new e(r)},e.prototype.tint=function(t){return t===void 0&&(t=10),this.mix("white",t)},e.prototype.shade=function(t){return t===void 0&&(t=10),this.mix("black",t)},e.prototype.desaturate=function(t){t===void 0&&(t=10);var r=this.toHsl();return r.s-=t/100,r.s=Ha(r.s),new e(r)},e.prototype.saturate=function(t){t===void 0&&(t=10);var r=this.toHsl();return r.s+=t/100,r.s=Ha(r.s),new e(r)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(t){var r=this.toHsl(),n=(r.h+t)%360;return r.h=n<0?360+n:n,new e(r)},e.prototype.mix=function(t,r){r===void 0&&(r=50);var n=this.toRgb(),o=new e(t).toRgb(),i=r/100,a={r:(o.r-n.r)*i+n.r,g:(o.g-n.g)*i+n.g,b:(o.b-n.b)*i+n.b,a:(o.a-n.a)*i+n.a};return new e(a)},e.prototype.analogous=function(t,r){t===void 0&&(t=6),r===void 0&&(r=30);var n=this.toHsl(),o=360/r,i=[this];for(n.h=(n.h-(o*t>>1)+720)%360;--t;)n.h=(n.h+o)%360,i.push(new e(n));return i},e.prototype.complement=function(){var t=this.toHsl();return t.h=(t.h+180)%360,new e(t)},e.prototype.monochromatic=function(t){t===void 0&&(t=6);for(var r=this.toHsv(),n=r.h,o=r.s,i=r.v,a=[],s=1/t;t--;)a.push(new e({h:n,s:o,v:i})),i=(i+s)%1;return a},e.prototype.splitcomplement=function(){var t=this.toHsl(),r=t.h;return[this,new e({h:(r+72)%360,s:t.s,l:t.l}),new e({h:(r+216)%360,s:t.s,l:t.l})]},e.prototype.onBackground=function(t){var r=this.toRgb(),n=new e(t).toRgb(),o=r.a+n.a*(1-r.a);return new e({r:(r.r*r.a+n.r*n.a*(1-r.a))/o,g:(r.g*r.a+n.g*n.a*(1-r.a))/o,b:(r.b*r.a+n.b*n.a*(1-r.a))/o,a:o})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(t){for(var r=this.toHsl(),n=r.h,o=[this],i=360/t,a=1;a=60&&Math.round(e.h)<=240?n=r?Math.round(e.h)-Wa*t:Math.round(e.h)+Wa*t:n=r?Math.round(e.h)+Wa*t:Math.round(e.h)-Wa*t,n<0?n+=360:n>=360&&(n-=360),n}function Og(e,t,r){if(e.h===0&&e.s===0)return e.s;var n;return r?n=e.s-Sg*t:t===Eg?n=e.s+Sg:n=e.s+c_*t,n>1&&(n=1),r&&t===Cg&&n>.1&&(n=.1),n<.06&&(n=.06),Number(n.toFixed(2))}function $g(e,t,r){var n;return r?n=e.v+l_*t:n=e.v-u_*t,n>1&&(n=1),Number(n.toFixed(2))}function Ir(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=[],n=so(e),o=Cg;o>0;o-=1){var i=xg(n),a=Va(so({h:_g(i,o,!0),s:Og(i,o,!0),v:$g(i,o,!0)}));r.push(a)}r.push(Va(n));for(var s=1;s<=Eg;s+=1){var c=xg(n),l=Va(so({h:_g(c,s),s:Og(c,s),v:$g(c,s)}));r.push(l)}return t.theme==="dark"?f_.map(function(u){var f=u.index,d=u.opacity,g=Va(d_(so(t.backgroundColor||"#141414"),so(r[f]),d*100));return g}):r}var xl={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},_l={},Ol={};Object.keys(xl).forEach(function(e){_l[e]=Ir(xl[e]),_l[e].primary=_l[e][5],Ol[e]=Ir(xl[e],{theme:"dark",backgroundColor:"#141414"}),Ol[e].primary=Ol[e][5]});const Pg=e=>{const{controlHeight:t}=e;return{controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}};function h_(e){const{sizeUnit:t,sizeStep:r}=e;return{sizeXXL:t*(r+8),sizeXL:t*(r+4),sizeLG:t*(r+2),sizeMD:t*(r+1),sizeMS:t*r,size:t*r,sizeSM:t*(r-1),sizeXS:t*(r-2),sizeXXS:t*(r-3)}}const $l={blue:"#1677ff",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#eb2f96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},Ua=Object.assign(Object.assign({},$l),{colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'`,fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:!1});function Tg(e,t){let{generateColorPalettes:r,generateNeutralColorPalettes:n}=t;const{colorSuccess:o,colorWarning:i,colorError:a,colorInfo:s,colorPrimary:c,colorBgBase:l,colorTextBase:u}=e,f=r(c),d=r(o),g=r(i),v=r(a),m=r(s),p=n(l,u);return Object.assign(Object.assign({},p),{colorPrimaryBg:f[1],colorPrimaryBgHover:f[2],colorPrimaryBorder:f[3],colorPrimaryBorderHover:f[4],colorPrimaryHover:f[5],colorPrimary:f[6],colorPrimaryActive:f[7],colorPrimaryTextHover:f[8],colorPrimaryText:f[9],colorPrimaryTextActive:f[10],colorSuccessBg:d[1],colorSuccessBgHover:d[2],colorSuccessBorder:d[3],colorSuccessBorderHover:d[4],colorSuccessHover:d[4],colorSuccess:d[6],colorSuccessActive:d[7],colorSuccessTextHover:d[8],colorSuccessText:d[9],colorSuccessTextActive:d[10],colorErrorBg:v[1],colorErrorBgHover:v[2],colorErrorBorder:v[3],colorErrorBorderHover:v[4],colorErrorHover:v[5],colorError:v[6],colorErrorActive:v[7],colorErrorTextHover:v[8],colorErrorText:v[9],colorErrorTextActive:v[10],colorWarningBg:g[1],colorWarningBgHover:g[2],colorWarningBorder:g[3],colorWarningBorderHover:g[4],colorWarningHover:g[4],colorWarning:g[6],colorWarningActive:g[7],colorWarningTextHover:g[8],colorWarningText:g[9],colorWarningTextActive:g[10],colorInfoBg:m[1],colorInfoBgHover:m[2],colorInfoBorder:m[3],colorInfoBorderHover:m[4],colorInfoHover:m[4],colorInfo:m[6],colorInfoActive:m[7],colorInfoTextHover:m[8],colorInfoText:m[9],colorInfoTextActive:m[10],colorBgMask:new ht("#000").setAlpha(.45).toRgbString(),colorWhite:"#fff"})}const g_=e=>{let t=e,r=e,n=e,o=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?r=4:e<8&&e>=7?r=5:e<14&&e>=8?r=6:e<16&&e>=14?r=7:e>=16&&(r=8),e<6&&e>=2?n=1:e>=6&&(n=2),e>4&&e<8?o=4:e>=8&&(o=6),{borderRadius:e>16?16:e,borderRadiusXS:n,borderRadiusSM:r,borderRadiusLG:t,borderRadiusOuter:o}};function m_(e){const{motionUnit:t,motionBase:r,borderRadius:n,lineWidth:o}=e;return Object.assign({motionDurationFast:`${(r+t).toFixed(1)}s`,motionDurationMid:`${(r+t*2).toFixed(1)}s`,motionDurationSlow:`${(r+t*3).toFixed(1)}s`,lineWidthBold:o+1},g_(n))}const Lr=(e,t)=>new ht(e).setAlpha(t).toRgbString(),mi=(e,t)=>new ht(e).darken(t).toHexString(),p_=e=>{const t=Ir(e);return{1:t[0],2:t[1],3:t[2],4:t[3],5:t[4],6:t[5],7:t[6],8:t[4],9:t[5],10:t[6]}},v_=(e,t)=>{const r=e||"#fff",n=t||"#000";return{colorBgBase:r,colorTextBase:n,colorText:Lr(n,.88),colorTextSecondary:Lr(n,.65),colorTextTertiary:Lr(n,.45),colorTextQuaternary:Lr(n,.25),colorFill:Lr(n,.15),colorFillSecondary:Lr(n,.06),colorFillTertiary:Lr(n,.04),colorFillQuaternary:Lr(n,.02),colorBgLayout:mi(r,4),colorBgContainer:mi(r,0),colorBgElevated:mi(r,0),colorBgSpotlight:Lr(n,.85),colorBorder:mi(r,15),colorBorderSecondary:mi(r,6)}};function b_(e){const t=new Array(10).fill(null).map((r,n)=>{const o=n-1,i=e*Math.pow(2.71828,o/5),a=n>1?Math.floor(i):Math.ceil(i);return Math.floor(a/2)*2});return t[1]=e,t.map(r=>{const n=r+8;return{size:r,lineHeight:n/r}})}const kg=e=>{const t=b_(e),r=t.map(o=>o.size),n=t.map(o=>o.lineHeight);return{fontSizeSM:r[0],fontSize:r[1],fontSizeLG:r[2],fontSizeXL:r[3],fontSizeHeading1:r[6],fontSizeHeading2:r[5],fontSizeHeading3:r[4],fontSizeHeading4:r[3],fontSizeHeading5:r[2],lineHeight:n[1],lineHeightLG:n[2],lineHeightSM:n[0],lineHeightHeading1:n[6],lineHeightHeading2:n[5],lineHeightHeading3:n[4],lineHeightHeading4:n[3],lineHeightHeading5:n[2]}};function Ga(e){const t=Object.keys($l).map(r=>{const n=Ir(e[r]);return new Array(10).fill(1).reduce((o,i,a)=>(o[`${r}-${a+1}`]=n[a],o[`${r}${a+1}`]=n[a],o),{})}).reduce((r,n)=>(r=Object.assign(Object.assign({},r),n),r),{});return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},e),t),Tg(e,{generateColorPalettes:p_,generateNeutralColorPalettes:v_})),kg(e.fontSize)),h_(e)),Pg(e)),m_(e))}function Pl(e){return e>=0&&e<=255}function qa(e,t){const{r,g:n,b:o,a:i}=new ht(e).toRgb();if(i<1)return e;const{r:a,g:s,b:c}=new ht(t).toRgb();for(let l=.01;l<=1;l+=.01){const u=Math.round((r-a*(1-l))/l),f=Math.round((n-s*(1-l))/l),d=Math.round((o-c*(1-l))/l);if(Pl(u)&&Pl(f)&&Pl(d))return new ht({r:u,g:f,b:d,a:Math.round(l*100)/100}).toRgbString()}return new ht({r,g:n,b:o,a:1}).toRgbString()}var y_=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{delete n[d]});const o=Object.assign(Object.assign({},r),n),i=480,a=576,s=768,c=992,l=1200,u=1600;return Object.assign(Object.assign(Object.assign({},o),{colorLink:o.colorInfoText,colorLinkHover:o.colorInfoHover,colorLinkActive:o.colorInfoActive,colorFillContent:o.colorFillSecondary,colorFillContentHover:o.colorFill,colorFillAlter:o.colorFillQuaternary,colorBgContainerDisabled:o.colorFillTertiary,colorBorderBg:o.colorBgContainer,colorSplit:qa(o.colorBorderSecondary,o.colorBgContainer),colorTextPlaceholder:o.colorTextQuaternary,colorTextDisabled:o.colorTextQuaternary,colorTextHeading:o.colorText,colorTextLabel:o.colorTextSecondary,colorTextDescription:o.colorTextTertiary,colorTextLightSolid:o.colorWhite,colorHighlight:o.colorError,colorBgTextHover:o.colorFillSecondary,colorBgTextActive:o.colorFill,colorIcon:o.colorTextTertiary,colorIconHover:o.colorText,colorErrorOutline:qa(o.colorErrorBg,o.colorBgContainer),colorWarningOutline:qa(o.colorWarningBg,o.colorBgContainer),fontSizeIcon:o.fontSizeSM,lineWidthFocus:o.lineWidth*4,lineWidth:o.lineWidth,controlOutlineWidth:o.lineWidth*2,controlInteractiveSize:o.controlHeight/2,controlItemBgHover:o.colorFillTertiary,controlItemBgActive:o.colorPrimaryBg,controlItemBgActiveHover:o.colorPrimaryBgHover,controlItemBgActiveDisabled:o.colorFill,controlTmpOutline:o.colorFillQuaternary,controlOutline:qa(o.colorPrimaryBg,o.colorBgContainer),lineType:o.lineType,borderRadius:o.borderRadius,borderRadiusXS:o.borderRadiusXS,borderRadiusSM:o.borderRadiusSM,borderRadiusLG:o.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:o.sizeXXS,paddingXS:o.sizeXS,paddingSM:o.sizeSM,padding:o.size,paddingMD:o.sizeMD,paddingLG:o.sizeLG,paddingXL:o.sizeXL,paddingContentHorizontalLG:o.sizeLG,paddingContentVerticalLG:o.sizeMS,paddingContentHorizontal:o.sizeMS,paddingContentVertical:o.sizeSM,paddingContentHorizontalSM:o.size,paddingContentVerticalSM:o.sizeXS,marginXXS:o.sizeXXS,marginXS:o.sizeXS,marginSM:o.sizeSM,margin:o.size,marginMD:o.sizeMD,marginLG:o.sizeLG,marginXL:o.sizeXL,marginXXL:o.sizeXXL,boxShadow:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowSecondary:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTertiary:` 0 1px 2px 0 rgba(0, 0, 0, 0.03), 0 1px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px 0 rgba(0, 0, 0, 0.02) `,screenXS:i,screenXSMin:i,screenXSMax:a-1,screenSM:a,screenSMMin:a,screenSMMax:s-1,screenMD:s,screenMDMin:s,screenMDMax:c-1,screenLG:c,screenLGMin:c,screenLGMax:l-1,screenXL:l,screenXLMin:l,screenXLMax:u-1,screenXXL:u,screenXXLMin:u,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:` 0 1px 2px -2px ${new ht("rgba(0, 0, 0, 0.16)").toRgbString()}, 0 3px 6px 0 ${new ht("rgba(0, 0, 0, 0.12)").toRgbString()}, 0 5px 12px 4px ${new ht("rgba(0, 0, 0, 0.09)").toRgbString()} `,boxShadowDrawerRight:` -6px 0 16px 0 rgba(0, 0, 0, 0.08), -3px 0 6px -4px rgba(0, 0, 0, 0.12), -9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerLeft:` 6px 0 16px 0 rgba(0, 0, 0, 0.08), 3px 0 6px -4px rgba(0, 0, 0, 0.12), 9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerUp:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerDown:` 0 -6px 16px 0 rgba(0, 0, 0, 0.08), 0 -3px 6px -4px rgba(0, 0, 0, 0.12), 0 -9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"}),n)}function Mg(e,t){return za.reduce((r,n)=>{const o=e[`${n}1`],i=e[`${n}3`],a=e[`${n}6`],s=e[`${n}7`];return Object.assign(Object.assign({},r),t(n,{lightColor:o,lightBorderColor:i,darkColor:a,textColor:s}))},{})}const S_=(e,t,r,n,o)=>{const i=e/2,a=0,s=i,c=r*1/Math.sqrt(2),l=i-r*(1-1/Math.sqrt(2)),u=i-t*(1/Math.sqrt(2)),f=r*(Math.sqrt(2)-1)+t*(1/Math.sqrt(2)),d=2*i-u,g=f,v=2*i-c,m=l,p=2*i-a,b=s,w=i*Math.sqrt(2)+r*(Math.sqrt(2)-2);return{pointerEvents:"none",width:e,height:e,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:e,height:e/2,background:n,clipPath:`path('M ${a} ${s} A ${r} ${r} 0 0 0 ${c} ${l} L ${u} ${f} A ${t} ${t} 0 0 1 ${d} ${g} L ${v} ${m} A ${r} ${r} 0 0 0 ${p} ${b} Z')`,content:'""'},"&::after":{content:'""',position:"absolute",width:w,height:w,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:`0 0 ${t}px 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:o,zIndex:0,background:"transparent"}}},jr=e=>({boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:e.fontFamily}),C_=()=>({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"}}),E_=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"}}}),x_=(e,t)=>{const{fontFamily:r,fontSize:n}=e,o=`[class^="${t}"], [class*=" ${t}"]`;return{[o]:{fontFamily:r,fontSize:n,boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"},[o]:{boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}}}}},Ka=e=>({outline:`${e.lineWidthFocus}px solid ${e.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),__=e=>({"&:focus-visible":Object.assign({},Ka(e))}),Ag="anticon",O_=(e,t)=>t||(e?`ant-${e}`:"ant"),Je=h.createContext({getPrefixCls:O_,iconPrefixCls:Ag});function cn(e,t,r){return n=>{const[o,i,a]=Ya(),{getPrefixCls:s,iconPrefixCls:c}=T.useContext(Je),l=s();return Qc({theme:o,token:i,hashId:a,path:["Shared",l]},()=>[{"&":E_(i)}]),[Qc({theme:o,token:i,hashId:a,path:[e,n,c]},()=>{const{token:u,flush:f}=P_(i),d=typeof r=="function"?r(u):r,g=Object.assign(Object.assign({},d),i[e]),v=`.${n}`,m=br(u,{componentCls:v,prefixCls:n,iconCls:`.${c}`,antCls:`.${l}`},g),p=t(m,{hashId:a,prefixCls:n,rootPrefixCls:l,iconPrefixCls:c,overrideComponentToken:i[e]});return f(e,g),[x_(i,n),p]}),a]}}const Rg=typeof CSSINJS_STATISTIC<"u";let Tl=!0;function br(){for(var e=arguments.length,t=new Array(e),r=0;r{Object.keys(o).forEach(a=>{Object.defineProperty(n,a,{configurable:!0,enumerable:!0,get:()=>o[a]})})}),Tl=!0,n}function $_(){}function P_(e){let t,r=e,n=$_;return Rg&&(t=new Set,r=new Proxy(e,{get(o,i){return Tl&&t.add(i),o[i]}}),n=(o,i)=>{Array.from(t)}),{token:r,keys:t,flush:n}}const T_=Uh(Ga),Xa={token:Ua,hashed:!0},Fg=T.createContext(Xa);function Ya(){const{token:e,hashed:t,theme:r,components:n}=T.useContext(Fg),o=`${Yx}-${t||""}`,i=r||T_,[a,s]=IE(i,[Ua,e],{salt:o,override:Object.assign({override:e},n),formatToken:w_});return[i,a,t?s:""]}const k_=`-ant-${Date.now()}-${Math.random()}`;function M_(e,t){const r={},n=(a,s)=>{let c=a.clone();return c=(s==null?void 0:s(c))||c,c.toRgbString()},o=(a,s)=>{const c=new ht(a),l=Ir(c.toRgbString());r[`${s}-color`]=n(c),r[`${s}-color-disabled`]=l[1],r[`${s}-color-hover`]=l[4],r[`${s}-color-active`]=l[6],r[`${s}-color-outline`]=c.clone().setAlpha(.2).toRgbString(),r[`${s}-color-deprecated-bg`]=l[0],r[`${s}-color-deprecated-border`]=l[2]};if(t.primaryColor){o(t.primaryColor,"primary");const a=new ht(t.primaryColor),s=Ir(a.toRgbString());s.forEach((l,u)=>{r[`primary-${u+1}`]=l}),r["primary-color-deprecated-l-35"]=n(a,l=>l.lighten(35)),r["primary-color-deprecated-l-20"]=n(a,l=>l.lighten(20)),r["primary-color-deprecated-t-20"]=n(a,l=>l.tint(20)),r["primary-color-deprecated-t-50"]=n(a,l=>l.tint(50)),r["primary-color-deprecated-f-12"]=n(a,l=>l.setAlpha(l.getAlpha()*.12));const c=new ht(s[0]);r["primary-color-active-deprecated-f-30"]=n(c,l=>l.setAlpha(l.getAlpha()*.3)),r["primary-color-active-deprecated-d-02"]=n(c,l=>l.darken(2))}return t.successColor&&o(t.successColor,"success"),t.warningColor&&o(t.warningColor,"warning"),t.errorColor&&o(t.errorColor,"error"),t.infoColor&&o(t.infoColor,"info"),` :root { ${Object.keys(r).map(a=>`--${e}-${a}: ${r[a]};`).join(` `)} } `.trim()}function A_(e,t){const r=M_(e,t);kt()&&to(r,`${k_}-dynamic-theme`)}const kl=h.createContext(!1),R_=e=>{let{children:t,disabled:r}=e;const n=h.useContext(kl);return h.createElement(kl.Provider,{value:r??n},t)},Za=kl,Ml=h.createContext(void 0),F_=e=>{let{children:t,size:r}=e;const n=h.useContext(Ml);return h.createElement(Ml.Provider,{value:r||n},t)},pi=Ml;function N_(){const e=T.useContext(Za),t=T.useContext(pi);return{componentDisabled:e,componentSize:t}}function I_(e,t){const r=e||{},n=r.inherit===!1||!t?Xa:t;return Dc(()=>{if(!e)return t;const i=Object.assign({},n.components);return Object.keys(e.components||{}).forEach(a=>{i[a]=Object.assign(Object.assign({},i[a]),e.components[a])}),Object.assign(Object.assign(Object.assign({},n),r),{token:Object.assign(Object.assign({},n.token),r.token),components:i})},[r,n],(i,a)=>i.some((s,c)=>{const l=a[c];return!Mh(s,l,!0)}))}const L_=e=>{const[t,r]=Ya();return Qc({theme:t,token:r,hashId:"",path:["ant-design-icons",e]},()=>[{[`.${e}`]:Object.assign(Object.assign({},C_()),{[`.${e} .${e}-icon`]:{display:"block"}})}])};var j_=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{let{prefixCls:t,iconPrefixCls:r,theme:n}=e;t!==void 0&&(Ng=t),n&&A_(H_(),n)},W_=e=>{const{children:t,csp:r,autoInsertSpaceInButton:n,form:o,locale:i,componentSize:a,direction:s,space:c,virtual:l,dropdownMatchSelectWidth:u,legacyLocale:f,parentContext:d,iconPrefixCls:g,theme:v,componentDisabled:m}=e,p=h.useCallback((C,x)=>{const{prefixCls:P}=e;if(x)return x;const N=P||d.getPrefixCls("");return C?`${N}-${C}`:N},[d.getPrefixCls,e.prefixCls]),b=g||d.iconPrefixCls||Ag,w=b!==d.iconPrefixCls,E=r||d.csp,$=L_(b),S=I_(v,d.theme),y={csp:E,autoInsertSpaceInButton:n,locale:i||f,direction:s,space:c,virtual:l,dropdownMatchSelectWidth:u,getPrefixCls:p,iconPrefixCls:b,theme:S},_=Object.assign({},d);Object.keys(y).forEach(C=>{y[C]!==void 0&&(_[C]=y[C])}),D_.forEach(C=>{const x=e[C];x&&(_[C]=x)});const R=Dc(()=>_,_,(C,x)=>{const P=Object.keys(C),N=Object.keys(x);return P.length!==N.length||P.some(F=>C[F]!==x[F])}),A=h.useMemo(()=>({prefixCls:b,csp:E}),[b,E]);let k=w?$(t):t;const I=h.useMemo(()=>{var C,x,P;return hi({},((C=pl.Form)===null||C===void 0?void 0:C.defaultValidateMessages)||{},((P=(x=R.locale)===null||x===void 0?void 0:x.Form)===null||P===void 0?void 0:P.defaultValidateMessages)||{},(o==null?void 0:o.validateMessages)||{})},[R,o==null?void 0:o.validateMessages]);Object.keys(I).length>0&&(k=h.createElement(dg,{validateMessages:I},t)),i&&(k=h.createElement(Xx,{locale:i,_ANT_MARK__:Kx},k)),(b||E)&&(k=h.createElement(tl.Provider,{value:A},k)),a&&(k=h.createElement(F_,{size:a},k));const M=h.useMemo(()=>{const C=S||{},{algorithm:x,token:P}=C,N=j_(C,["algorithm","token"]),F=x&&(!Array.isArray(x)||x.length>0)?Uh(x):void 0;return Object.assign(Object.assign({},N),{theme:F,token:Object.assign(Object.assign({},Ua),P)})},[S]);return v&&(k=h.createElement(Fg.Provider,{value:M},k)),m!==void 0&&(k=h.createElement(R_,{disabled:m},k)),h.createElement(Je.Provider,{value:R},k)},co=e=>{const t=h.useContext(Je),r=h.useContext(vg);return h.createElement(W_,Object.assign({parentContext:t,legacyLocale:r},e))};co.ConfigContext=Je,co.SizeContext=pi,co.config=B_,co.useConfig=N_,Object.defineProperty(co,"SizeContext",{get:()=>pi});const V_=co;var Ig=function(t){return+setTimeout(t,16)},Lg=function(t){return clearTimeout(t)};typeof window<"u"&&"requestAnimationFrame"in window&&(Ig=function(t){return window.requestAnimationFrame(t)},Lg=function(t){return window.cancelAnimationFrame(t)});var jg=0,Al=new Map;function Dg(e){Al.delete(e)}var Tn=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;jg+=1;var n=jg;function o(i){if(i===0)Dg(n),t();else{var a=Ig(function(){o(i-1)});Al.set(n,a)}}return o(r),n};Tn.cancel=function(e){var t=Al.get(e);return Dg(t),Lg(t)};function U_(e,t){vr(e,"[@ant-design/icons] ".concat(t))}function zg(e){return Ue(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(Ue(e.icon)==="object"||typeof e.icon=="function")}function Hg(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Object.keys(e).reduce(function(t,r){var n=e[r];switch(r){case"class":t.className=n,delete t.class;break;default:t[r]=n}return t},{})}function Rl(e,t,r){return r?T.createElement(e.tag,H(H({key:t},Hg(e.attrs)),r),(e.children||[]).map(function(n,o){return Rl(n,"".concat(t,"-").concat(e.tag,"-").concat(o))})):T.createElement(e.tag,H({key:t},Hg(e.attrs)),(e.children||[]).map(function(n,o){return Rl(n,"".concat(t,"-").concat(e.tag,"-").concat(o))}))}function Bg(e){return Ir(e)[0]}function Wg(e){return e?Array.isArray(e)?e:[e]:[]}var G_=` .anticon { display: inline-block; color: inherit; font-style: normal; line-height: 0; text-align: center; text-transform: none; vertical-align: -0.125em; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } .anticon > * { line-height: 1; } .anticon svg { display: inline-block; } .anticon::before { display: none; } .anticon .anticon-icon { display: block; } .anticon[tabindex] { cursor: pointer; } .anticon-spin::before, .anticon-spin { display: inline-block; -webkit-animation: loadingCircle 1s infinite linear; animation: loadingCircle 1s infinite linear; } @-webkit-keyframes loadingCircle { 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } @keyframes loadingCircle { 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } `,q_=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:G_,r=T.useContext(tl),n=r.csp,o=r.prefixCls,i=t;o&&(i=i.replace(/anticon/g,o)),T.useEffect(function(){to(i,"@ant-design-icons",{prepend:!0,csp:n})},[])},K_=["icon","className","onClick","style","primaryColor","secondaryColor"],vi={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function X_(e){var t=e.primaryColor,r=e.secondaryColor;vi.primaryColor=t,vi.secondaryColor=r||Bg(t),vi.calculated=!!r}function Y_(){return H({},vi)}var Qa=function(t){var r=t.icon,n=t.className,o=t.onClick,i=t.style,a=t.primaryColor,s=t.secondaryColor,c=Bt(t,K_),l=vi;if(a&&(l={primaryColor:a,secondaryColor:s||Bg(a)}),q_(),U_(zg(r),"icon should be icon definiton, but got ".concat(r)),!zg(r))return null;var u=r;return u&&typeof u.icon=="function"&&(u=H(H({},u),{},{icon:u.icon(l.primaryColor,l.secondaryColor)})),Rl(u.icon,"svg-".concat(u.name),H({className:n,onClick:o,style:i,"data-icon":u.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},c))};Qa.displayName="IconReact",Qa.getTwoToneColors=Y_,Qa.setTwoToneColors=X_;const Fl=Qa;function Vg(e){var t=Wg(e),r=G(t,2),n=r[0],o=r[1];return Fl.setTwoToneColors({primaryColor:n,secondaryColor:o})}function Z_(){var e=Fl.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor}var Q_=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];Vg("#1890ff");var Ja=h.forwardRef(function(e,t){var r,n=e.className,o=e.icon,i=e.spin,a=e.rotate,s=e.tabIndex,c=e.onClick,l=e.twoToneColor,u=Bt(e,Q_),f=h.useContext(tl),d=f.prefixCls,g=d===void 0?"anticon":d,v=f.rootClassName,m=Y(v,g,(r={},oe(r,"".concat(g,"-").concat(o.name),!!o.name),oe(r,"".concat(g,"-spin"),!!i||o.name==="loading"),r),n),p=s;p===void 0&&c&&(p=-1);var b=a?{msTransform:"rotate(".concat(a,"deg)"),transform:"rotate(".concat(a,"deg)")}:void 0,w=Wg(l),E=G(w,2),$=E[0],S=E[1];return h.createElement("span",H(H({role:"img","aria-label":o.name},u),{},{ref:t,tabIndex:p,onClick:c,className:m}),h.createElement(Fl,{icon:o,primaryColor:$,secondaryColor:S,style:b}))});Ja.displayName="AntdIcon",Ja.getTwoToneColor=Z_,Ja.setTwoToneColor=Vg;const Ug=Ja;var J_={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"}}]},name:"close",theme:"outlined"};const eO=J_;var Gg=function(t,r){return h.createElement(Ug,H(H({},t),{},{ref:r,icon:eO}))};Gg.displayName="CloseOutlined";const tO=h.forwardRef(Gg);function qg(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit".concat(e)]="webkit".concat(t),r["Moz".concat(e)]="moz".concat(t),r["ms".concat(e)]="MS".concat(t),r["O".concat(e)]="o".concat(t.toLowerCase()),r}function rO(e,t){var r={animationend:qg("Animation","AnimationEnd"),transitionend:qg("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete r.animationend.animation,"TransitionEvent"in t||delete r.transitionend.transition),r}var nO=rO(kt(),typeof window<"u"?window:{}),Kg={};if(kt()){var oO=document.createElement("div");Kg=oO.style}var es={};function Xg(e){if(es[e])return es[e];var t=nO[e];if(t)for(var r=Object.keys(t),n=r.length,o=0;o1&&arguments[1]!==void 0?arguments[1]:2;t();var i=Tn(function(){o<=1?n({isCanceled:function(){return i!==e.current}}):r(n,o-1)});e.current=i}return h.useEffect(function(){return function(){t()}},[]),[r,t]};var nm=kt()?T.useLayoutEffect:T.useEffect,om=[Dr,uo,fo,Nl],im=!1,aO=!0;function am(e){return e===fo||e===Nl}const sO=function(e,t){var r=ho(rm),n=G(r,2),o=n[0],i=n[1],a=iO(),s=G(a,2),c=s[0],l=s[1];function u(){i(Dr,!0)}return nm(function(){if(o!==rm&&o!==Nl){var f=om.indexOf(o),d=om[f+1],g=t(o);g===im?i(d,!0):c(function(v){function m(){v.isCanceled()||i(d,!0)}g===!0?m():Promise.resolve(g).then(m)})}},[e,o]),h.useEffect(function(){return function(){l()}},[]),[u,o]},cO=function(e){var t=T.useRef(),r=T.useRef(e);r.current=e;var n=h.useCallback(function(a){r.current(a)},[]);function o(a){a&&(a.removeEventListener(em,n),a.removeEventListener(Jg,n))}function i(a){t.current&&t.current!==a&&o(t.current),a&&a!==t.current&&(a.addEventListener(em,n),a.addEventListener(Jg,n),t.current=a)}return h.useEffect(function(){return function(){o(t.current)}},[]),[i,o]};function lO(e,t,r,n){var o=n.motionEnter,i=o===void 0?!0:o,a=n.motionAppear,s=a===void 0?!0:a,c=n.motionLeave,l=c===void 0?!0:c,u=n.motionDeadline,f=n.motionLeaveImmediately,d=n.onAppearPrepare,g=n.onEnterPrepare,v=n.onLeavePrepare,m=n.onAppearStart,p=n.onEnterStart,b=n.onLeaveStart,w=n.onAppearActive,E=n.onEnterActive,$=n.onLeaveActive,S=n.onAppearEnd,y=n.onEnterEnd,_=n.onLeaveEnd,R=n.onVisibleChanged,A=ho(),k=G(A,2),I=k[0],M=k[1],C=ho(lo),x=G(C,2),P=x[0],N=x[1],F=ho(null),j=G(F,2),D=j[0],B=j[1],V=T.useRef(!1),W=T.useRef(null);function z(){return r()}var se=T.useRef(!1);function J(ne){var re=z();if(!(ne&&!ne.deadline&&ne.target!==re)){var pe=se.current,Xe;P===ts&&pe?Xe=S==null?void 0:S(re,ne):P===rs&&pe?Xe=y==null?void 0:y(re,ne):P===ns&&pe&&(Xe=_==null?void 0:_(re,ne)),P!==lo&&pe&&Xe!==!1&&(N(lo,!0),B(null,!0))}}var me=cO(J),ge=G(me,1),ye=ge[0],te=h.useMemo(function(){var ne,re,pe;switch(P){case ts:return ne={},oe(ne,Dr,d),oe(ne,uo,m),oe(ne,fo,w),ne;case rs:return re={},oe(re,Dr,g),oe(re,uo,p),oe(re,fo,E),re;case ns:return pe={},oe(pe,Dr,v),oe(pe,uo,b),oe(pe,fo,$),pe;default:return{}}},[P]),we=sO(P,function(ne){if(ne===Dr){var re=te[Dr];return re?re(z()):im}if(q in te){var pe;B(((pe=te[q])===null||pe===void 0?void 0:pe.call(te,z(),null))||null)}return q===fo&&(ye(z()),u>0&&(clearTimeout(W.current),W.current=setTimeout(function(){J({deadline:!0})},u))),aO}),Pe=G(we,2),Te=Pe[0],q=Pe[1],le=am(q);se.current=le,nm(function(){M(t);var ne=V.current;if(V.current=!0,!!e){var re;!ne&&t&&s&&(re=ts),ne&&t&&i&&(re=rs),(ne&&!t&&l||!ne&&f&&!t&&l)&&(re=ns),re&&(N(re),Te())}},[t]),T.useEffect(function(){(P===ts&&!s||P===rs&&!i||P===ns&&!l)&&N(lo)},[s,i,l]),T.useEffect(function(){return function(){V.current=!1,clearTimeout(W.current)}},[]);var Se=h.useRef(!1);T.useEffect(function(){I&&(Se.current=!0),I!==void 0&&P===lo&&((Se.current||I)&&(R==null||R(I)),Se.current=!0)},[I,P]);var Fe=D;return te[Dr]&&q===uo&&(Fe=H({transition:"none"},Fe)),[P,q,Fe,I??t]}var uO=function(e){xa(r,e);var t=$a(r);function r(){return mr(this,r),t.apply(this,arguments)}return pr(r,[{key:"render",value:function(){return this.props.children}}]),r}(h.Component);function fO(e){var t=e;Ue(e)==="object"&&(t=e.transitionSupport);function r(o){return!!(o.motionName&&t)}var n=h.forwardRef(function(o,i){var a=o.visible,s=a===void 0?!0:a,c=o.removeOnLeave,l=c===void 0?!0:c,u=o.forceRender,f=o.children,d=o.motionName,g=o.leavedClassName,v=o.eventProps,m=r(o),p=T.useRef(),b=T.useRef();function w(){try{return p.current instanceof HTMLElement?p.current:Hc(b.current)}catch{return null}}var E=lO(m,s,w,o),$=G(E,4),S=$[0],y=$[1],_=$[2],R=$[3],A=h.useRef(R);R&&(A.current=!0);var k=h.useCallback(function(F){p.current=F,zc(i,F)},[i]),I,M=H(H({},v),{},{visible:s});if(!f)I=null;else if(S===lo||!r(o))R?I=f(H({},M),k):!l&&A.current&&g?I=f(H(H({},M),{},{className:g}),k):u||!l&&!g?I=f(H(H({},M),{},{style:{display:"none"}}),k):I=null;else{var C,x;y===Dr?x="prepare":am(y)?x="active":y===uo&&(x="start"),I=f(H(H({},M),{},{className:Y(tm(d,S),(C={},oe(C,tm(d,"".concat(S,"-").concat(x)),x),oe(C,d,typeof d=="string"),C)),style:_}),k)}if(h.isValidElement(I)&&ii(I)){var P=I,N=P.ref;N||(I=h.cloneElement(I,{ref:k}))}return h.createElement(uO,{ref:b},I)});return n.displayName="CSSMotion",n}const bi=fO(Qg);var Il="add",Ll="keep",jl="remove",Dl="removed";function dO(e){var t;return e&&Ue(e)==="object"&&"key"in e?t=e:t={key:e},H(H({},t),{},{key:String(t.key)})}function zl(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(dO)}function hO(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=[],n=0,o=t.length,i=zl(e),a=zl(t);i.forEach(function(l){for(var u=!1,f=n;f1});return c.forEach(function(l){r=r.filter(function(u){var f=u.key,d=u.status;return f!==l||d!==jl}),r.forEach(function(u){u.key===l&&(u.status=Ll)})}),r}var gO=["component","children","onVisibleChanged","onAllRemoved"],mO=["status"],pO=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function vO(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:bi,r=function(n){xa(i,n);var o=$a(i);function i(){var a;mr(this,i);for(var s=arguments.length,c=new Array(s),l=0;l((r.startsWith("data-")||r.startsWith("aria-")||r==="role")&&!r.startsWith("data-__")&&(t[r]=e[r]),t),{})}const{isValidElement:Hl}=h;function sm(e){return e&&Hl(e)&&e.type===h.Fragment}function yO(e,t,r){return Hl(e)?h.cloneElement(e,typeof r=="function"?r(e.props||{}):r):t}function os(e,t){return yO(e,e,t)}function zr(e){var t=h.useRef();t.current=e;var r=h.useCallback(function(){for(var n,o=arguments.length,i=new Array(o),a=0;a=K.F1&&r<=K.F12)return!1;switch(r){case K.ALT:case K.CAPS_LOCK:case K.CONTEXT_MENU:case K.CTRL:case K.DOWN:case K.END:case K.ESC:case K.HOME:case K.INSERT:case K.LEFT:case K.MAC_FF_META:case K.META:case K.NUMLOCK:case K.NUM_CENTER:case K.PAGE_DOWN:case K.PAGE_UP:case K.PAUSE:case K.PRINT_SCREEN:case K.RIGHT:case K.SHIFT:case K.UP:case K.WIN_KEY:case K.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(t){if(t>=K.ZERO&&t<=K.NINE||t>=K.NUM_ZERO&&t<=K.NUM_MULTIPLY||t>=K.A&&t<=K.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&t===0)return!0;switch(t){case K.SPACE:case K.QUESTION_MARK:case K.NUM_PLUS:case K.NUM_MINUS:case K.NUM_PERIOD:case K.NUM_DIVISION:case K.SEMICOLON:case K.DASH:case K.EQUALS:case K.COMMA:case K.PERIOD:case K.SLASH:case K.APOSTROPHE:case K.SINGLE_QUOTE:case K.OPEN_SQUARE_BRACKET:case K.BACKSLASH:case K.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},wO={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};const SO=wO;var cm=function(t,r){return h.createElement(Ug,H(H({},t),{},{ref:r,icon:SO}))};cm.displayName="LoadingOutlined";const lm=h.forwardRef(cm);var yi=H({},Hv),CO=yi.version,EO=yi.render,xO=yi.unmountComponentAtNode,is;try{var _O=Number((CO||"").split(".")[0]);_O>=18&&(is=yi.createRoot)}catch{}function um(e){var t=yi.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&Ue(t)==="object"&&(t.usingClientEntryPoint=e)}var as="__rc_react_root__";function OO(e,t){um(!0);var r=t[as]||is(t);um(!1),r.render(e),t[as]=r}function $O(e,t){EO(e,t)}function PO(e,t){if(is){OO(e,t);return}$O(e,t)}function TO(e){return Bl.apply(this,arguments)}function Bl(){return Bl=oo(Mt().mark(function e(t){return Mt().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.resolve().then(function(){var o;(o=t[as])===null||o===void 0||o.unmount(),delete t[as]}));case 1:case"end":return n.stop()}},e)})),Bl.apply(this,arguments)}function kO(e){xO(e)}function MO(e){return Wl.apply(this,arguments)}function Wl(){return Wl=oo(Mt().mark(function e(t){return Mt().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(is===void 0){n.next=2;break}return n.abrupt("return",TO(t));case 2:kO(t);case 3:case"end":return n.stop()}},e)})),Wl.apply(this,arguments)}const AO=e=>{const{componentCls:t}=e;return{[t]:{display:"inline-flex","&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"}}}},RO=e=>{const{componentCls:t}=e;return{[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},[`${t}-item`]:{"&:empty":{display:"none"}}}}},fm=cn("Space",e=>[RO(e),AO(e)]);var dm=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{const r=h.useContext(Vl),n=h.useMemo(()=>{if(!r)return"";const{compactDirection:o,isFirstItem:i,isLastItem:a}=r,s=o==="vertical"?"-vertical-":"-";return Y({[`${e}-compact${s}item`]:!0,[`${e}-compact${s}first-item`]:i,[`${e}-compact${s}last-item`]:a,[`${e}-compact${s}item-rtl`]:t==="rtl"})},[e,t,r]);return{compactSize:r==null?void 0:r.compactSize,compactDirection:r==null?void 0:r.compactDirection,compactItemClassnames:n}},NO=e=>{var{children:t}=e,r=dm(e,["children"]);return h.createElement(Vl.Provider,{value:r},t)},IO=e=>{const{getPrefixCls:t,direction:r}=h.useContext(Je),{size:n="middle",direction:o,block:i,prefixCls:a,className:s,rootClassName:c,children:l}=e,u=dm(e,["size","direction","block","prefixCls","className","rootClassName","children"]),f=t("space-compact",a),[d,g]=fm(f),v=Y(f,g,{[`${f}-rtl`]:r==="rtl",[`${f}-block`]:i,[`${f}-vertical`]:o==="vertical"},s,c),m=h.useContext(Vl),p=Zn(l),b=h.useMemo(()=>p.map((w,E)=>{const $=w&&w.key||`${f}-item-${E}`;return h.createElement(NO,{key:$,compactSize:n,compactDirection:o,isFirstItem:E===0&&(!m||(m==null?void 0:m.isFirstItem)),isLastItem:E===p.length-1&&(!m||(m==null?void 0:m.isLastItem))},w)}),[n,p,m]);return p.length===0?null:d(h.createElement("div",Object.assign({className:v},u),b))},hm=function(e){if(!e)return!1;if(e instanceof Element){if(e.offsetParent)return!0;if(e.getBBox){var t=e.getBBox(),r=t.width,n=t.height;if(r||n)return!0}if(e.getBoundingClientRect){var o=e.getBoundingClientRect(),i=o.width,a=o.height;if(i||a)return!0}}return!1},LO=e=>{const{componentCls:t,colorPrimary:r}=e;return{[t]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:`var(--wave-color, ${r})`,boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:[`box-shadow 0.4s ${e.motionEaseOutCirc}`,`opacity 2s ${e.motionEaseOutCirc}`].join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0}}}}},jO=cn("Wave",e=>[LO(e)]);function DO(e){const t=(e||"").match(/rgba?\((\d*), (\d*), (\d*)(, [\d.]*)?\)/);return t&&t[1]&&t[2]&&t[3]?!(t[1]===t[2]&&t[2]===t[3]):!0}function Ul(e){return e&&e!=="#fff"&&e!=="#ffffff"&&e!=="rgb(255, 255, 255)"&&e!=="rgba(255, 255, 255, 1)"&&DO(e)&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&e!=="transparent"}function zO(e){const{borderTopColor:t,borderColor:r,backgroundColor:n}=getComputedStyle(e);return Ul(t)?t:Ul(r)?r:Ul(n)?n:null}function Gl(e){return Number.isNaN(e)?0:e}const HO=e=>{const{className:t,target:r}=e,n=h.useRef(null),[o,i]=h.useState(null),[a,s]=h.useState([]),[c,l]=h.useState(0),[u,f]=h.useState(0),[d,g]=h.useState(0),[v,m]=h.useState(0),[p,b]=h.useState(!1),w={left:c,top:u,width:d,height:v,borderRadius:a.map($=>`${$}px`).join(" ")};o&&(w["--wave-color"]=o);function E(){const $=getComputedStyle(r);i(zO(r));const S=$.position==="static",{borderLeftWidth:y,borderTopWidth:_}=$;l(S?r.offsetLeft:Gl(-parseFloat(y))),f(S?r.offsetTop:Gl(-parseFloat(_))),g(r.offsetWidth),m(r.offsetHeight);const{borderTopLeftRadius:R,borderTopRightRadius:A,borderBottomLeftRadius:k,borderBottomRightRadius:I}=$;s([R,A,I,k].map(M=>Gl(parseFloat(M))))}return h.useEffect(()=>{if(r){const $=Tn(()=>{E(),b(!0)});let S;return typeof ResizeObserver<"u"&&(S=new ResizeObserver(E),S.observe(r)),()=>{Tn.cancel($),S==null||S.disconnect()}}},[]),p?h.createElement(bi,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:($,S)=>{var y;if(S.deadline||S.propertyName==="opacity"){const _=(y=n.current)===null||y===void 0?void 0:y.parentElement;MO(_).then(()=>{var R;(R=_.parentElement)===null||R===void 0||R.removeChild(_)})}return!1}},$=>{let{className:S}=$;return h.createElement("div",{ref:n,className:Y(t,S),style:w})}):null};function BO(e,t){const r=document.createElement("div");r.style.position="absolute",r.style.left="0px",r.style.top="0px",e==null||e.insertBefore(r,e==null?void 0:e.firstChild),PO(h.createElement(HO,{target:e,className:t}),r)}function WO(e,t){function r(){const n=e.current;BO(n,t)}return r}const gm=e=>{const{children:t,disabled:r}=e,{getPrefixCls:n}=T.useContext(Je),o=T.useRef(null),i=n("wave"),[,a]=jO(i),s=WO(o,Y(i,a));if(T.useEffect(()=>{const l=o.current;if(!l||l.nodeType!==1||r)return;const u=f=>{f.target.tagName==="INPUT"||!hm(f.target)||!l.getAttribute||l.getAttribute("disabled")||l.disabled||l.className.includes("disabled")||l.className.includes("-leave")||s()};return l.addEventListener("click",u,!0),()=>{l.removeEventListener("click",u,!0)}},[r]),!T.isValidElement(t))return t??null;const c=ii(t)?Jn(t.ref,o):o;return os(t,{ref:c})};var VO=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{const{getPrefixCls:t,direction:r}=h.useContext(Je),{prefixCls:n,size:o,className:i}=e,a=VO(e,["prefixCls","size","className"]),s=t("btn-group",n),[,,c]=Ya();let l="";switch(o){case"large":l="lg";break;case"small":l="sm";break}const u=Y(s,{[`${s}-${l}`]:l,[`${s}-rtl`]:r==="rtl"},i,c);return h.createElement(mm.Provider,{value:o},h.createElement("div",Object.assign({},a,{className:u})))},pm=/^[\u4e00-\u9fa5]{2}$/,ql=pm.test.bind(pm);function GO(e){return typeof e=="string"}function Kl(e){return e==="text"||e==="link"}function qO(e,t){if(e==null)return;const r=t?" ":"";return typeof e!="string"&&typeof e!="number"&&GO(e.type)&&ql(e.props.children)?os(e,{children:e.props.children.split("").join(r)}):typeof e=="string"?ql(e)?T.createElement("span",null,e.split("").join(r)):T.createElement("span",null,e):sm(e)?T.createElement("span",null,e):e}function KO(e,t){let r=!1;const n=[];return T.Children.forEach(e,o=>{const i=typeof o,a=i==="string"||i==="number";if(r&&a){const s=n.length-1,c=n[s];n[s]=`${c}${o}`}else n.push(o);r=a}),T.Children.map(n,o=>qO(o,t))}const Xl=()=>({width:0,opacity:0,transform:"scale(0)"}),Yl=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"}),XO=e=>{let{prefixCls:t,loading:r,existIcon:n}=e;const o=!!r;return n?T.createElement("span",{className:`${t}-loading-icon`},T.createElement(lm,null)):T.createElement(bi,{visible:o,motionName:`${t}-loading-icon-motion`,removeOnLeave:!0,onAppearStart:Xl,onAppearActive:Yl,onEnterStart:Xl,onEnterActive:Yl,onLeaveStart:Yl,onLeaveActive:Xl},(i,a)=>{let{className:s,style:c}=i;return T.createElement("span",{className:`${t}-loading-icon`,style:c,ref:a},T.createElement(lm,{className:s}))})},vm=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}}),YO=e=>{const{componentCls:t,fontSize:r,lineWidth:n,colorPrimaryHover:o,colorErrorHover:i}=e;return{[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:-n,[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,[`&:hover, &:focus, &:active`]:{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:r}},vm(`${t}-primary`,o),vm(`${t}-danger`,i)]}};function ZO(e,t,r){const{focusElCls:n,focus:o,borderElCls:i}=r,a=i?"> *":"",s=["hover",o?"focus":null,"active"].filter(Boolean).map(c=>`&:${c} ${a}`).join(",");return{[`&-item:not(${t}-last-item)`]:{marginInlineEnd:-e.lineWidth},"&-item":Object.assign(Object.assign({[s]:{zIndex:2}},n?{[`&${n}`]:{zIndex:2}}:{}),{[`&[disabled] ${a}`]:{zIndex:0}})}}function QO(e,t,r){const{borderElCls:n}=r,o=n?`> ${n}`:"";return{[`&-item:not(${t}-first-item):not(${t}-last-item) ${o}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function JO(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{focus:!0};const{componentCls:r}=e,n=`${r}-compact`;return{[n]:Object.assign(Object.assign({},ZO(e,n,t)),QO(r,n,t))}}function e$(e,t){return{[`&-item:not(${t}-last-item)`]:{marginBottom:-e.lineWidth},"&-item":{"&:hover,&:focus,&:active":{zIndex:2},"&[disabled]":{zIndex:0}}}}function t$(e,t){return{[`&-item:not(${t}-first-item):not(${t}-last-item)`]:{borderRadius:0},[`&-item${t}-first-item:not(${t}-last-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${t}-last-item:not(${t}-first-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}}}function r$(e){const t=`${e.componentCls}-compact-vertical`;return{[t]:Object.assign(Object.assign({},e$(e,t)),t$(e.componentCls,t))}}const n$=e=>{const{componentCls:t,iconCls:r}=e;return{[t]:{outline:"none",position:"relative",display:"inline-block",fontWeight:400,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",backgroundColor:"transparent",border:`${e.lineWidth}px ${e.lineType} transparent`,cursor:"pointer",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation",lineHeight:e.lineHeight,color:e.colorText,"> span":{display:"inline-block"},[`> ${r} + span, > span + ${r}`]:{marginInlineStart:e.marginXS},"> a":{color:"currentColor"},"&:not(:disabled)":Object.assign({},__(e)),[`&-icon-only${t}-compact-item`]:{flex:"none"},[`&-compact-item${t}-primary`]:{[`&:not([disabled]) + ${t}-compact-item${t}-primary:not([disabled])`]:{position:"relative","&:before":{position:"absolute",top:-e.lineWidth,insetInlineStart:-e.lineWidth,display:"inline-block",width:e.lineWidth,height:`calc(100% + ${e.lineWidth*2}px)`,backgroundColor:e.colorPrimaryHover,content:'""'}}},"&-compact-vertical-item":{[`&${t}-primary`]:{[`&:not([disabled]) + ${t}-compact-vertical-item${t}-primary:not([disabled])`]:{position:"relative","&:before":{position:"absolute",top:-e.lineWidth,insetInlineStart:-e.lineWidth,display:"inline-block",width:`calc(100% + ${e.lineWidth*2}px)`,height:e.lineWidth,backgroundColor:e.colorPrimaryHover,content:'""'}}}}}}},Hr=(e,t)=>({"&:not(:disabled)":{"&:hover":e,"&:active":t}}),o$=e=>({minWidth:e.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),i$=e=>({borderRadius:e.controlHeight,paddingInlineStart:e.controlHeight/2,paddingInlineEnd:e.controlHeight/2}),Zl=e=>({cursor:"not-allowed",borderColor:e.colorBorder,color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,boxShadow:"none"}),ss=(e,t,r,n,o,i,a)=>({[`&${e}-background-ghost`]:Object.assign(Object.assign({color:t||void 0,backgroundColor:"transparent",borderColor:r||void 0,boxShadow:"none"},Hr(Object.assign({backgroundColor:"transparent"},i),Object.assign({backgroundColor:"transparent"},a))),{"&:disabled":{cursor:"not-allowed",color:n||void 0,borderColor:o||void 0}})}),Ql=e=>({"&:disabled":Object.assign({},Zl(e))}),bm=e=>Object.assign({},Ql(e)),cs=e=>({"&:disabled":{cursor:"not-allowed",color:e.colorTextDisabled}}),ym=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},bm(e)),{backgroundColor:e.colorBgContainer,borderColor:e.colorBorder,boxShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`}),Hr({color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),ss(e.componentCls,e.colorBgContainer,e.colorBgContainer,e.colorTextDisabled,e.colorBorder)),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign(Object.assign({color:e.colorError,borderColor:e.colorError},Hr({color:e.colorErrorHover,borderColor:e.colorErrorBorderHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),ss(e.componentCls,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder)),Ql(e))}),a$=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},bm(e)),{color:e.colorTextLightSolid,backgroundColor:e.colorPrimary,boxShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`}),Hr({color:e.colorTextLightSolid,backgroundColor:e.colorPrimaryHover},{color:e.colorTextLightSolid,backgroundColor:e.colorPrimaryActive})),ss(e.componentCls,e.colorPrimary,e.colorPrimary,e.colorTextDisabled,e.colorBorder,{color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign(Object.assign({backgroundColor:e.colorError,boxShadow:`0 ${e.controlOutlineWidth}px 0 ${e.colorErrorOutline}`},Hr({backgroundColor:e.colorErrorHover},{backgroundColor:e.colorErrorActive})),ss(e.componentCls,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder,{color:e.colorErrorHover,borderColor:e.colorErrorHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),Ql(e))}),s$=e=>Object.assign(Object.assign({},ym(e)),{borderStyle:"dashed"}),c$=e=>Object.assign(Object.assign(Object.assign({color:e.colorLink},Hr({color:e.colorLinkHover},{color:e.colorLinkActive})),cs(e)),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign({color:e.colorError},Hr({color:e.colorErrorHover},{color:e.colorErrorActive})),cs(e))}),l$=e=>Object.assign(Object.assign(Object.assign({},Hr({color:e.colorText,backgroundColor:e.colorBgTextHover},{color:e.colorText,backgroundColor:e.colorBgTextActive})),cs(e)),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign({color:e.colorError},cs(e)),Hr({color:e.colorErrorHover,backgroundColor:e.colorErrorBg},{color:e.colorErrorHover,backgroundColor:e.colorErrorBg}))}),u$=e=>Object.assign(Object.assign({},Zl(e)),{[`&${e.componentCls}:hover`]:Object.assign({},Zl(e))}),f$=e=>{const{componentCls:t}=e;return{[`${t}-default`]:ym(e),[`${t}-primary`]:a$(e),[`${t}-dashed`]:s$(e),[`${t}-link`]:c$(e),[`${t}-text`]:l$(e),[`${t}-disabled`]:u$(e)}},Jl=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const{componentCls:r,iconCls:n,controlHeight:o,fontSize:i,lineHeight:a,lineWidth:s,borderRadius:c,buttonPaddingHorizontal:l}=e,u=Math.max(0,(o-i*a)/2-s),f=l-s,d=`${r}-icon-only`;return[{[`${r}${t}`]:{fontSize:i,height:o,padding:`${u}px ${f}px`,borderRadius:c,[`&${d}`]:{width:o,paddingInlineStart:0,paddingInlineEnd:0,[`&${r}-round`]:{width:"auto"},"> span":{transform:"scale(1.143)"}},[`&${r}-loading`]:{opacity:e.opacityLoading,cursor:"default"},[`${r}-loading-icon`]:{transition:`width ${e.motionDurationSlow} ${e.motionEaseInOut}, opacity ${e.motionDurationSlow} ${e.motionEaseInOut}`},[`&:not(${d}) ${r}-loading-icon > ${n}`]:{marginInlineEnd:e.marginXS}}},{[`${r}${r}-circle${t}`]:o$(e)},{[`${r}${r}-round${t}`]:i$(e)}]},d$=e=>Jl(e),h$=e=>{const t=br(e,{controlHeight:e.controlHeightSM,padding:e.paddingXS,buttonPaddingHorizontal:8,borderRadius:e.borderRadiusSM});return Jl(t,`${e.componentCls}-sm`)},g$=e=>{const t=br(e,{controlHeight:e.controlHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG});return Jl(t,`${e.componentCls}-lg`)},m$=e=>{const{componentCls:t}=e;return{[t]:{[`&${t}-block`]:{width:"100%"}}}},p$=cn("Button",e=>{const{controlTmpOutline:t,paddingContentHorizontal:r}=e,n=br(e,{colorOutlineDefault:t,buttonPaddingHorizontal:r});return[n$(n),h$(n),d$(n),g$(n),m$(n),f$(n),YO(n),JO(e),r$(e)]});var v$=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{const{loading:r=!1,prefixCls:n,type:o="default",danger:i,shape:a="default",size:s,disabled:c,className:l,rootClassName:u,children:f,icon:d,ghost:g=!1,block:v=!1,htmlType:m="button"}=e,p=v$(e,["loading","prefixCls","type","danger","shape","size","disabled","className","rootClassName","children","icon","ghost","block","htmlType"]),{getPrefixCls:b,autoInsertSpaceInButton:w,direction:E}=h.useContext(Je),$=b("btn",n),[S,y]=p$($),_=h.useContext(pi),R=h.useContext(Za),A=c??R,k=h.useContext(mm),I=h.useMemo(()=>b$(r),[r]),[M,C]=h.useState(I.loading),[x,P]=h.useState(!1),N=t||h.createRef(),F=()=>h.Children.count(f)===1&&!d&&!Kl(o),j=()=>{if(!N||!N.current||w===!1)return;const q=N.current.textContent;F()&&ql(q)?x||P(!0):x&&P(!1)};h.useEffect(()=>{let q=null;I.delay>0?q=window.setTimeout(()=>{q=null,C(!0)},I.delay):C(I.loading);function le(){q&&(window.clearTimeout(q),q=null)}return le},[I]),h.useEffect(j,[N]);const D=q=>{const{onClick:le}=e;if(M||A){q.preventDefault();return}le==null||le(q)},B=w!==!1,{compactSize:V,compactItemClassnames:W}=FO($,E),z={large:"lg",small:"sm",middle:void 0},se=V||k||s||_,J=se&&z[se]||"",me=M?"loading":d,ge=Th(p,["navigate"]),ye=ge.href!==void 0&&A,te=Y($,y,{[`${$}-${a}`]:a!=="default"&&a,[`${$}-${o}`]:o,[`${$}-${J}`]:J,[`${$}-icon-only`]:!f&&f!==0&&!!me,[`${$}-background-ghost`]:g&&!Kl(o),[`${$}-loading`]:M,[`${$}-two-chinese-chars`]:x&&B&&!M,[`${$}-block`]:v,[`${$}-dangerous`]:!!i,[`${$}-rtl`]:E==="rtl",[`${$}-disabled`]:ye},W,l,u),we=d&&!M?d:h.createElement(XO,{existIcon:!!d,prefixCls:$,loading:!!M}),Pe=f||f===0?KO(f,F()&&B):null;if(ge.href!==void 0)return S(h.createElement("a",Object.assign({},ge,{className:te,onClick:D,ref:N}),we,Pe));let Te=h.createElement("button",Object.assign({},p,{type:m,className:te,onClick:D,disabled:A,ref:N}),we,Pe);return Kl(o)||(Te=h.createElement(gm,{disabled:!!M},Te)),S(Te)},eu=h.forwardRef(y$);eu.Group=UO,eu.__ANT_BUTTON=!0;const go=eu,w$=(e,t,r)=>r!==void 0?r:`${e}-${t}`;var wm=h.createContext(null),vt=kt()?h.useLayoutEffect:h.useEffect,Sm=function(t,r){var n=h.useRef(!0);vt(function(){if(!n.current)return t()},r),vt(function(){return n.current=!1,function(){n.current=!0}},[])},Cm=[];function S$(e,t){var r=h.useState(function(){if(!kt())return null;var v=document.createElement("div");return v}),n=G(r,1),o=n[0],i=h.useRef(!1),a=h.useContext(wm),s=h.useState(Cm),c=G(s,2),l=c[0],u=c[1],f=a||(i.current?void 0:function(v){u(function(m){var p=[v].concat(Q(m));return p})});function d(){o.parentElement||document.body.appendChild(o),i.current=!0}function g(){var v;(v=o.parentElement)===null||v===void 0||v.removeChild(o),i.current=!1}return vt(function(){return e?a?a(d):d():g(),g},[e]),vt(function(){l.length&&(l.forEach(function(v){return v()}),u(Cm))},[l]),[o,f]}var tu;function C$(e){if(typeof document>"u")return 0;if(e||tu===void 0){var t=document.createElement("div");t.style.width="100%",t.style.height="200px";var r=document.createElement("div"),n=r.style;n.position="absolute",n.top="0",n.left="0",n.pointerEvents="none",n.visibility="hidden",n.width="200px",n.height="150px",n.overflow="hidden",r.appendChild(t),document.body.appendChild(r);var o=t.offsetWidth;r.style.overflow="scroll";var i=t.offsetWidth;o===i&&(i=r.clientWidth),document.body.removeChild(r),tu=o-i}return tu}function E$(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}var x$="rc-util-locker-".concat(Date.now()),Em=0;function _$(e){var t=!!e,r=h.useState(function(){return Em+=1,"".concat(x$,"_").concat(Em)}),n=G(r,1),o=n[0];vt(function(){if(t){var i=C$(),a=E$();to(` html body { overflow-y: hidden; `.concat(a?"width: calc(100% - ".concat(i,"px);"):"",` }`),o)}else Na(o);return function(){Na(o)}},[t,o])}var xm=!1;function O$(e){return typeof e=="boolean"&&(xm=e),xm}var _m=function(t){return t===!1?!1:!kt()||!t?null:typeof t=="string"?document.querySelector(t):typeof t=="function"?t():t},Om=h.forwardRef(function(e,t){var r=e.open,n=e.autoLock,o=e.getContainer;e.debug;var i=e.autoDestroy,a=i===void 0?!0:i,s=e.children,c=h.useState(r),l=G(c,2),u=l[0],f=l[1],d=u||r;h.useEffect(function(){(a||r)&&f(r)},[r,a]);var g=h.useState(function(){return _m(o)}),v=G(g,2),m=v[0],p=v[1];h.useEffect(function(){var I=_m(o);p(I??null)});var b=S$(d&&!m),w=G(b,2),E=w[0],$=w[1],S=m??E;_$(n&&r&&kt()&&(S===E||S===document.body));var y=null;if(s&&ii(s)&&t){var _=s;y=_.ref}var R=yh(y,t);if(!d||!kt()||m===void 0)return null;var A=S===!1||O$(),k=s;return t&&(k=h.cloneElement(s,{ref:R})),h.createElement(wm.Provider,{value:$},A?k:ve.createPortal(k,S))});function $$(){var e=H({},h);return e.useId}var $m=0;function P$(e){var t=h.useState("ssr-id"),r=G(t,2),n=r[0],o=r[1],i=$$(),a=i==null?void 0:i();return h.useEffect(function(){if(!i){var s=$m;$m+=1,o("rc_unique_".concat(s))}},[]),e||a||n}const Pm=h.createContext({}),T$=()=>kt()&&window.document.documentElement;let ls;const k$=()=>{if(!T$())return!1;if(ls!==void 0)return ls;const e=document.createElement("div");return e.style.display="flex",e.style.flexDirection="column",e.style.rowGap="1px",e.appendChild(document.createElement("div")),e.appendChild(document.createElement("div")),document.body.appendChild(e),ls=e.scrollHeight===1,document.body.removeChild(e),ls},M$=e=>({animationDuration:e,animationFillMode:"both"}),A$=e=>({animationDuration:e,animationFillMode:"both"}),R$=function(e,t,r,n){const i=(arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1)?"&":"";return{[` ${i}${e}-enter, ${i}${e}-appear `]:Object.assign(Object.assign({},M$(n)),{animationPlayState:"paused"}),[`${i}${e}-leave`]:Object.assign(Object.assign({},A$(n)),{animationPlayState:"paused"}),[` ${i}${e}-enter${e}-enter-active, ${i}${e}-appear${e}-appear-active `]:{animationName:t,animationPlayState:"running"},[`${i}${e}-leave${e}-leave-active`]:{animationName:r,animationPlayState:"running",pointerEvents:"none"}}},F$=new Ct("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),N$=new Ct("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),Tm=new Ct("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),km=new Ct("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),I$=new Ct("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),L$=new Ct("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),j$=new Ct("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),D$=new Ct("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),z$=new Ct("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),H$=new Ct("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),B$=new Ct("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),W$=new Ct("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),V$={zoom:{inKeyframes:F$,outKeyframes:N$},"zoom-big":{inKeyframes:Tm,outKeyframes:km},"zoom-big-fast":{inKeyframes:Tm,outKeyframes:km},"zoom-left":{inKeyframes:j$,outKeyframes:D$},"zoom-right":{inKeyframes:z$,outKeyframes:H$},"zoom-up":{inKeyframes:I$,outKeyframes:L$},"zoom-down":{inKeyframes:B$,outKeyframes:W$}},U$=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:o,outKeyframes:i}=V$[t];return[R$(n,o,i,t==="zoom-big-fast"?e.motionDurationFast:e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]};function ru(e){return e!==void 0}function nu(e,t){var r=t||{},n=r.defaultValue,o=r.value,i=r.onChange,a=r.postState,s=ho(function(){return ru(o)?o:ru(n)?typeof n=="function"?n():n:typeof e=="function"?e():e}),c=G(s,2),l=c[0],u=c[1],f=o!==void 0?o:l,d=a?a(f):f,g=zr(i),v=ho([f]),m=G(v,2),p=m[0],b=m[1];Sm(function(){var E=p[0];l!==E&&g(l,E)},[p]),Sm(function(){ru(o)||u(o)},[o]);var w=zr(function(E,$){u(E,$),b([f],$)});return[d,w]}const G$=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 Mm=h.createContext(null);function Am(e){return e?Array.isArray(e)?e:[e]:[]}function q$(e,t,r,n){return h.useMemo(function(){var o=Am(r??t),i=Am(n??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,r,n])}function K$(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0;return r?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}function X$(e,t,r,n){for(var o=r.points,i=Object.keys(e),a=0;a0&&arguments[0]!==void 0?arguments[0]:"";return[e[0],e[1]]}function mo(e,t){var r=t[0],n=t[1],o,i;return r==="t"?i=e.y:r==="b"?i=e.y+e.height:i=e.y+e.height/2,n==="l"?o=e.x:n==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:i}}function ln(e,t){var r={t:"b",b:"t",l:"r",r:"l"};return e.map(function(n,o){return o===t?r[n]||"c":n}).join("")}function Y$(e,t,r,n,o,i,a){var s=h.useState({ready:!1,offsetX:0,offsetY:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[n]||{}}),c=G(s,2),l=c[0],u=c[1],f=h.useRef(0),d=h.useMemo(function(){return t?ou(t):[]},[t]),g=zr(function(){if(t&&r&&e){let Bn=function(wt,nt){var cr=wt+B,Wi=nt+D,jo=Math.max(wt,z.left),Vi=Math.max(nt,z.top),Ui=Math.min(cr,z.right),Do=Math.min(Wi,z.bottom);return(Ui-jo)*(Do-Vi)};var p=t,b=p.style.left,w=p.style.top,E=p.ownerDocument,$=us(p),S=H(H({},o[n]),i);p.style.left="0",p.style.top="0";var y;if(Array.isArray(r))y={x:r[0],y:r[1],width:0,height:0};else{var _=r.getBoundingClientRect();y={x:_.x,y:_.y,width:_.width,height:_.height}}var R=p.getBoundingClientRect(),A=$.getComputedStyle(p),k=A.width,I=A.height,M=E.documentElement,C=M.clientWidth,x=M.clientHeight,P=M.scrollWidth,N=M.scrollHeight,F=M.scrollTop,j=M.scrollLeft,D=R.height,B=R.width,V=y.height,W=y.width,z=S.htmlRegion==="scroll"?{left:-j,top:-F,right:P-j,bottom:N-F}:{left:0,top:0,right:C,bottom:x};(d||[]).forEach(function(wt){if(!(wt instanceof HTMLBodyElement)){var nt=wt.getBoundingClientRect(),cr=wt.offsetHeight,Wi=wt.clientHeight,jo=wt.offsetWidth,Vi=wt.clientWidth,Ui=fs(Math.round(nt.width/jo*1e3)/1e3),Do=fs(Math.round(nt.height/cr*1e3)/1e3),sf=(jo-Vi)*Ui,cf=(cr-Wi)*Do,lf=nt.x+nt.width-sf,Ls=nt.y+nt.height-cf;z.left=Math.max(z.left,nt.left),z.top=Math.max(z.top,nt.top),z.right=Math.min(z.right,lf),z.bottom=Math.min(z.bottom,Ls)}}),p.style.left=b,p.style.top=w;var se=fs(Math.round(B/parseFloat(k)*1e3)/1e3),J=fs(Math.round(D/parseFloat(I)*1e3)/1e3);if(se===0||J===0||Pa(r)&&!hm(r))return;var me=S.offset,ge=S.targetOffset,ye=me||[],te=G(ye,2),we=te[0],Pe=we===void 0?0:we,Te=te[1],q=Te===void 0?0:Te,le=ge||[],Se=G(le,2),Fe=Se[0],ne=Fe===void 0?0:Fe,re=Se[1],pe=re===void 0?0:re;y.x+=ne,y.y+=pe;var Xe=S.points||[],Dt=G(Xe,2),gn=Dt[0],qr=Dt[1],st=Fm(qr),Ce=Fm(gn),Kr=mo(y,st),ke=mo(R,Ce),Me=H({},S),Ne=Kr.x-ke.x+Pe,fe=Kr.y-ke.y+q,Ot=Bn(Ne,fe),Gt=mo(y,["t","l"]),nr=mo(R,["t","l"]),mt=mo(y,["b","r"]),or=mo(R,["b","r"]),mn=S.overflow||{},Fo=mn.adjustX,jn=mn.adjustY,Dn=mn.shiftX,zn=mn.shiftY,No=function(nt){return typeof nt=="boolean"?nt:nt>=0},Xr=R.y+fe,pt=Xr+D,Yr=No(jn),Pr=Ce[0]===st[0];if(Yr&&Ce[0]==="t"&&pt>z.bottom){var Zr=fe;Pr?Zr-=D-V:Zr=Gt.y-or.y-q,Bn(Ne,Zr)>Ot&&(fe=Zr,Me.points=[ln(Ce,0),ln(st,0)])}if(Yr&&Ce[0]==="b"&&XrOt&&(fe=ir,Me.points=[ln(Ce,0),ln(st,0)])}var Qr=R.x+Ne,$t=Qr+B,Hn=No(Fo),qt=Ce[1]===st[1];if(Hn&&Ce[1]==="l"&&$t>z.right){var Jr=Ne;qt?Jr-=B-W:Jr=Gt.x-or.x-Pe,Bn(Jr,fe)>Ot&&(Ne=Jr,Me.points=[ln(Ce,1),ln(st,1)])}if(Hn&&Ce[1]==="r"&&QrOt&&(Ne=Tr,Me.points=[ln(Ce,1),ln(st,1)])}var ar=Dn===!0?0:Dn;typeof ar=="number"&&(Qrz.right&&(Ne-=$t-z.right,y.x>z.right-ar&&(Ne+=y.x-z.right+ar)));var kr=zn===!0?0:zn;typeof kr=="number"&&(Xrz.bottom&&(fe-=pt-z.bottom,y.y>z.bottom-kr&&(fe+=y.y-z.bottom+kr)));var pn=R.x+Ne,Ie=pn+B,he=R.y+fe,ae=he+D,We=y.x,Ae=We+W,sr=y.y,zt=sr+V,Kt=Math.max(pn,We),ft=Math.min(Ie,Ae),Io=(Kt+ft)/2,Lo=Io-pn,en=Math.max(he,sr),Bi=Math.min(ae,zt),of=(en+Bi)/2,af=of-he;a==null||a(t,Me),u({ready:!0,offsetX:Ne/se,offsetY:fe/J,arrowX:Lo/se,arrowY:af/J,scaleX:se,scaleY:J,align:Me})}}),v=function(){f.current+=1;var b=f.current;Promise.resolve().then(function(){f.current===b&&g()})},m=function(){u(function(b){return H(H({},b),{},{ready:!1})})};return vt(m,[n]),vt(function(){e||m()},[e]),[l.ready,l.offsetX,l.offsetY,l.arrowX,l.arrowY,l.scaleX,l.scaleY,l.align,v]}function Z$(e,t,r,n){vt(function(){if(e&&t&&r){let u=function(){n()};var o=t,i=r,a=ou(o),s=ou(i),c=us(i),l=new Set([c].concat(Q(a),Q(s)));return l.forEach(function(f){f.addEventListener("scroll",u,{passive:!0})}),c.addEventListener("resize",u,{passive:!0}),n(),function(){l.forEach(function(f){f.removeEventListener("scroll",u),c.removeEventListener("resize",u)})}}},[e,t,r])}function Q$(e){var t=e.prefixCls,r=e.align,n=e.arrowX,o=n===void 0?0:n,i=e.arrowY,a=i===void 0?0:i,s=h.useRef();if(!r||!r.points)return null;var c={position:"absolute"};if(r.autoArrow!==!1){var l=r.points[0],u=r.points[1],f=l[0],d=l[1],g=u[0],v=u[1];f===g||!["t","b"].includes(f)?c.top=a:f==="t"?c.top=0:c.bottom=0,d===v||!["l","r"].includes(d)?c.left=o:d==="l"?c.left=0:c.right=0}return h.createElement("div",{ref:s,className:"".concat(t,"-arrow"),style:c})}function J$(e){var t=e.prefixCls,r=e.open,n=e.zIndex,o=e.mask,i=e.motion;return o?React.createElement(bi,Ht({},i,{motionAppear:!0,visible:r,removeOnLeave:!0}),function(a){var s=a.className;return React.createElement("div",{style:{zIndex:n},className:Y("".concat(t,"-mask"),s)})}):null}var eP=h.forwardRef(function(e,t){var r=e.popup,n=e.className,o=e.prefixCls,i=e.style,a=e.target,s=e.onVisibleChanged,c=e.open,l=e.keepDom,u=e.onClick,f=e.mask,d=e.arrow,g=e.align,v=e.arrowX,m=e.arrowY,p=e.motion,b=e.maskMotion,w=e.forceRender,E=e.getPopupContainer,$=e.autoDestroy,S=e.portal,y=e.zIndex,_=e.onMouseEnter,R=e.onMouseLeave,A=e.ready,k=e.offsetX,I=e.offsetY,M=e.onAlign,C=e.onPrepare,x=e.stretch,P=e.targetWidth,N=e.targetHeight,F=typeof r=="function"?r():r,j=c||l,D=(E==null?void 0:E.length)>0,B=h.useState(!E||!D),V=G(B,2),W=V[0],z=V[1];if(vt(function(){!W&&D&&a&&z(!0)},[W,D,a]),!W)return null;var se=A||!c?{left:k,top:I}:{left:"-1000vw",top:"-1000vh"},J={};return x&&(x.includes("height")&&N?J.height=N:x.includes("minHeight")&&N&&(J.minHeight=N),x.includes("width")&&P?J.width=P:x.includes("minWidth")&&P&&(J.minWidth=P)),c||(J.pointerEvents="none"),h.createElement(S,{open:w||j,getContainer:E&&function(){return E(a)},autoDestroy:$},h.createElement(J$,{prefixCls:o,open:c,zIndex:y,mask:f,motion:b}),h.createElement(Uc,{onResize:M,disabled:!c},function(me){return h.createElement(bi,Ht({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:w,leavedClassName:"".concat(o,"-hidden")},p,{onAppearPrepare:C,onEnterPrepare:C,visible:c,onVisibleChanged:function(ye){var te;p==null||(te=p.onVisibleChanged)===null||te===void 0||te.call(p,ye),s(ye)}}),function(ge,ye){var te=ge.className,we=ge.style,Pe=Y(o,te,n);return h.createElement("div",{ref:Jn(me,t,ye),className:Pe,style:H(H(H(H({},se),J),we),{},{boxSizing:"border-box",zIndex:y},i),onMouseEnter:_,onMouseLeave:R,onClick:u},d&&h.createElement(Q$,{prefixCls:o,align:g,arrowX:v,arrowY:m}),F)})}))}),tP=h.forwardRef(function(e,t){var r=e.children,n=e.getTriggerDOMNode,o=ii(r),i=h.useCallback(function(s){zc(t,n?n(s):s)},[n]),a=yh(i,r.ref);return o?h.cloneElement(r,{ref:a}):r}),rP=["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","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"];function nP(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Om,t=h.forwardRef(function(r,n){var o=r.prefixCls,i=o===void 0?"rc-trigger-popup":o,a=r.children,s=r.action,c=s===void 0?"hover":s,l=r.showAction,u=r.hideAction,f=r.popupVisible,d=r.defaultPopupVisible,g=r.onPopupVisibleChange,v=r.afterPopupVisibleChange,m=r.mouseEnterDelay,p=r.mouseLeaveDelay,b=p===void 0?.1:p,w=r.focusDelay,E=r.blurDelay,$=r.mask,S=r.maskClosable,y=S===void 0?!0:S,_=r.getPopupContainer,R=r.forceRender,A=r.autoDestroy,k=r.destroyPopupOnHide,I=r.popup,M=r.popupClassName,C=r.popupStyle,x=r.popupPlacement,P=r.builtinPlacements,N=P===void 0?{}:P,F=r.popupAlign,j=r.zIndex,D=r.stretch,B=r.getPopupClassNameFromAlign,V=r.alignPoint,W=r.onPopupClick,z=r.onPopupAlign,se=r.arrow,J=r.popupMotion,me=r.maskMotion,ge=r.popupTransitionName,ye=r.popupAnimation,te=r.maskTransitionName,we=r.maskAnimation,Pe=r.className,Te=r.getTriggerDOMNode,q=Bt(r,rP),le=A||k||!1,Se=h.useState(!1),Fe=G(Se,2),ne=Fe[0],re=Fe[1];vt(function(){re(G$())},[]);var pe=h.useRef({}),Xe=h.useContext(Mm),Dt=h.useMemo(function(){return{registerSubPopup:function(ce,Oe){pe.current[ce]=Oe,Xe==null||Xe.registerSubPopup(ce,Oe)}}},[Xe]),gn=P$(),qr=h.useState(null),st=G(qr,2),Ce=st[0],Kr=st[1],ke=zr(function(X){Pa(X)&&Ce!==X&&Kr(X),Xe==null||Xe.registerSubPopup(gn,X)}),Me=h.useState(null),Ne=G(Me,2),fe=Ne[0],Ot=Ne[1],Gt=zr(function(X){Pa(X)&&fe!==X&&Ot(X)}),nr=h.Children.only(a),mt=(nr==null?void 0:nr.props)||{},or={},mn=zr(function(X){var ce,Oe,De=fe;return(De==null?void 0:De.contains(X))||(De==null||(ce=De.getRootNode())===null||ce===void 0?void 0:ce.host)===X||X===De||(Ce==null?void 0:Ce.contains(X))||(Ce==null||(Oe=Ce.getRootNode())===null||Oe===void 0?void 0:Oe.host)===X||X===Ce||Object.values(pe.current).some(function(Ge){return Ge.contains(X)||X===Ge})}),Fo=Rm(i,J,ye,ge),jn=Rm(i,me,we,te),Dn=h.useState(d||!1),zn=G(Dn,2),No=zn[0],Xr=zn[1],pt=f??No,Yr=zr(function(X){f===void 0&&Xr(X)});vt(function(){Xr(f||!1)},[f]);var Pr=h.useRef(pt);Pr.current=pt;var Zr=zr(function(X){pt!==X&&(Yr(X),g==null||g(X))}),ir=h.useRef(),Qr=function(){clearTimeout(ir.current)},$t=function(ce){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;Qr(),Oe===0?Zr(ce):ir.current=setTimeout(function(){Zr(ce)},Oe*1e3)};h.useEffect(function(){return Qr},[]);var Hn=h.useState(!1),qt=G(Hn,2),Jr=qt[0],Tr=qt[1],ar=h.useRef(!0);vt(function(){(!ar.current||pt)&&Tr(!0),ar.current=!0},[pt]);var kr=h.useState(null),pn=G(kr,2),Ie=pn[0],he=pn[1],ae=h.useState([0,0]),We=G(ae,2),Ae=We[0],sr=We[1],zt=function(ce){sr([ce.clientX,ce.clientY])},Kt=Y$(pt,Ce,V?Ae:fe,x,N,F,z),ft=G(Kt,9),Io=ft[0],Lo=ft[1],en=ft[2],Bi=ft[3],of=ft[4],af=ft[5],Bn=ft[6],wt=ft[7],nt=ft[8],cr=zr(function(){Jr||nt()});Z$(pt,fe,Ce,cr),vt(function(){cr()},[Ae]),vt(function(){pt&&!(N!=null&&N[x])&&cr()},[JSON.stringify(F)]);var Wi=h.useMemo(function(){var X=X$(N,i,wt,V);return Y(X,B==null?void 0:B(wt))},[wt,B,N,i,V]);h.useImperativeHandle(n,function(){return{forceAlign:cr}});var jo=function(ce){Tr(!1),nt(),v==null||v(ce)},Vi=function(){return new Promise(function(ce){he(function(){return ce})})};vt(function(){Ie&&(nt(),Ie(),he(null))},[Ie]);var Ui=h.useState(0),Do=G(Ui,2),sf=Do[0],cf=Do[1],lf=h.useState(0),Ls=G(lf,2),$M=Ls[0],PM=Ls[1],TM=function(ce,Oe){if(cr(),D){var De=Oe.getBoundingClientRect();cf(De.width),PM(De.height)}},kM=q$(ne,c,l,u),Rv=G(kM,2),js=Rv[0],Ds=Rv[1],zs=function(ce,Oe,De,Ge){or[ce]=function(Bs){var zo;Ge==null||Ge(Bs),$t(Oe,De);for(var ff=arguments.length,jv=new Array(ff>1?ff-1:0),Ws=1;Ws1?Oe-1:0),Ge=1;Ge1?Oe-1:0),Ge=1;Genew ht(e).setAlpha(t).toRgbString(),bo=(e,t)=>new ht(e).lighten(t).toHexString(),lP=e=>{const t=Ir(e,{theme:"dark"});return{1:t[0],2:t[1],3:t[2],4:t[3],5:t[6],6:t[5],7:t[4],8:t[6],9:t[5],10:t[4]}},uP=(e,t)=>{const r=e||"#000",n=t||"#fff";return{colorBgBase:r,colorTextBase:n,colorText:un(n,.85),colorTextSecondary:un(n,.65),colorTextTertiary:un(n,.45),colorTextQuaternary:un(n,.25),colorFill:un(n,.18),colorFillSecondary:un(n,.12),colorFillTertiary:un(n,.08),colorFillQuaternary:un(n,.04),colorBgElevated:bo(r,12),colorBgContainer:bo(r,8),colorBgLayout:bo(r,0),colorBgSpotlight:bo(r,26),colorBorder:bo(r,26),colorBorderSecondary:bo(r,19)}},fP=(e,t)=>{const r=Object.keys($l).map(o=>{const i=Ir(e[o],{theme:"dark"});return new Array(10).fill(1).reduce((a,s,c)=>(a[`${o}-${c+1}`]=i[c],a[`${o}${c+1}`]=i[c],a),{})}).reduce((o,i)=>(o=Object.assign(Object.assign({},o),i),o),{}),n=t??Ga(e);return Object.assign(Object.assign(Object.assign({},n),r),Tg(e,{generateColorPalettes:lP,generateNeutralColorPalettes:uP}))};function dP(e){const{sizeUnit:t,sizeStep:r}=e,n=r-2;return{sizeXXL:t*(n+10),sizeXL:t*(n+6),sizeLG:t*(n+2),sizeMD:t*(n+2),sizeMS:t*(n+1),size:t*n,sizeSM:t*n,sizeXS:t*(n-1),sizeXXS:t*(n-1)}}const hP=(e,t)=>{const r=t??Ga(e),n=r.fontSizeSM,o=r.controlHeight-4;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},r),dP(t??e)),kg(n)),{controlHeight:o}),Pg(Object.assign(Object.assign({},r),{controlHeight:o})))};function gP(){const[e,t,r]=Ya();return{theme:e,token:t,hashId:r}}const iu={defaultConfig:Xa,defaultSeed:Xa.token,useToken:gP,defaultAlgorithm:Ga,darkAlgorithm:fP,compactAlgorithm:hP},Im=8;function Lm(e){const t=Im,{contentRadius:r,limitVerticalRadius:n}=e,o=r>12?r+2:12;return{dropdownArrowOffset:o,dropdownArrowOffsetVertical:n?t:o}}function ds(e,t){return e?t:{}}function mP(e,t){const{componentCls:r,sizePopupArrow:n,borderRadiusXS:o,borderRadiusOuter:i,boxShadowPopoverArrow:a}=e,{colorBg:s,contentRadius:c=e.borderRadiusLG,limitVerticalRadius:l,arrowDistance:u=0,arrowPlacement:f={left:!0,right:!0,top:!0,bottom:!0}}=t,{dropdownArrowOffsetVertical:d,dropdownArrowOffset:g}=Lm({contentRadius:c,limitVerticalRadius:l});return{[r]:Object.assign(Object.assign(Object.assign(Object.assign({[`${r}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},S_(n,o,i,s,a)),{"&:before":{background:s}})]},ds(!!f.top,{[[`&-placement-top ${r}-arrow`,`&-placement-topLeft ${r}-arrow`,`&-placement-topRight ${r}-arrow`].join(",")]:{bottom:u,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},[`&-placement-topLeft ${r}-arrow`]:{left:{_skip_check_:!0,value:g}},[`&-placement-topRight ${r}-arrow`]:{right:{_skip_check_:!0,value:g}}})),ds(!!f.bottom,{[[`&-placement-bottom ${r}-arrow`,`&-placement-bottomLeft ${r}-arrow`,`&-placement-bottomRight ${r}-arrow`].join(",")]:{top:u,transform:"translateY(-100%)"},[`&-placement-bottom ${r}-arrow`]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},[`&-placement-bottomLeft ${r}-arrow`]:{left:{_skip_check_:!0,value:g}},[`&-placement-bottomRight ${r}-arrow`]:{right:{_skip_check_:!0,value:g}}})),ds(!!f.left,{[[`&-placement-left ${r}-arrow`,`&-placement-leftTop ${r}-arrow`,`&-placement-leftBottom ${r}-arrow`].join(",")]:{right:{_skip_check_:!0,value:u},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:d},[`&-placement-leftBottom ${r}-arrow`]:{bottom:d}})),ds(!!f.right,{[[`&-placement-right ${r}-arrow`,`&-placement-rightTop ${r}-arrow`,`&-placement-rightBottom ${r}-arrow`].join(",")]:{left:{_skip_check_:!0,value:u},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:d},[`&-placement-rightBottom ${r}-arrow`]:{bottom:d}}))}}function pP(e,t,r,n){if(n===!1)return{adjustX:!1,adjustY:!1};const o=n&&typeof n=="object"?n:{},i={};switch(e){case"top":case"bottom":i.shiftX=t.dropdownArrowOffset*2+r;break;case"left":case"right":i.shiftY=t.dropdownArrowOffsetVertical*2+r;break}const a=Object.assign(Object.assign({},i),o);return a.shiftX||(a.adjustX=!0),a.shiftY||(a.adjustY=!0),a}const jm={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"]}},vP={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"]}},bP=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function yP(e){const{arrowWidth:t,autoAdjustOverflow:r,arrowPointAtCenter:n,offset:o,borderRadius:i}=e,a=t/2,s={};return Object.keys(jm).forEach(c=>{const l=n&&vP[c]||jm[c],u=Object.assign(Object.assign({},l),{offset:[0,0]});switch(s[c]=u,bP.has(c)&&(u.autoArrow=!1),c){case"top":case"topLeft":case"topRight":u.offset[1]=-a-o;break;case"bottom":case"bottomLeft":case"bottomRight":u.offset[1]=a+o;break;case"left":case"leftTop":case"leftBottom":u.offset[0]=-a-o;break;case"right":case"rightTop":case"rightBottom":u.offset[0]=a+o;break}const f=Lm({contentRadius:i,limitVerticalRadius:!0});if(n)switch(c){case"topLeft":case"bottomLeft":u.offset[0]=-f.dropdownArrowOffset-a;break;case"topRight":case"bottomRight":u.offset[0]=f.dropdownArrowOffset+a;break;case"leftTop":case"rightTop":u.offset[1]=-f.dropdownArrowOffset-a;break;case"leftBottom":case"rightBottom":u.offset[1]=f.dropdownArrowOffset+a;break}u.overflow=pP(c,f,t,r)}),s}const wP=e=>{const{componentCls:t,tooltipMaxWidth:r,tooltipColor:n,tooltipBg:o,tooltipBorderRadius:i,zIndexPopup:a,controlHeight:s,boxShadowSecondary:c,paddingSM:l,paddingXS:u,tooltipRadiusOuter:f}=e;return[{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},jr(e)),{position:"absolute",zIndex:a,display:"block",width:"max-content",maxWidth:r,visibility:"visible","&-hidden":{display:"none"},"--antd-arrow-background-color":o,[`${t}-inner`]:{minWidth:s,minHeight:s,padding:`${l/2}px ${u}px`,color:n,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:o,borderRadius:i,boxShadow:c},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${t}-inner`]:{borderRadius:Math.min(i,Im)}},[`${t}-content`]:{position:"relative"}}),Mg(e,(d,g)=>{let{darkColor:v}=g;return{[`&${t}-${d}`]:{[`${t}-inner`]:{backgroundColor:v},[`${t}-arrow`]:{"--antd-arrow-background-color":v}}}})),{"&-rtl":{direction:"rtl"}})},mP(br(e,{borderRadiusOuter:f}),{colorBg:"var(--antd-arrow-background-color)",contentRadius:i,limitVerticalRadius:!0}),{[`${t}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},Dm=(e,t)=>cn("Tooltip",n=>{if(t===!1)return[];const{borderRadius:o,colorTextLightSolid:i,colorBgDefault:a,borderRadiusOuter:s}=n,c=br(n,{tooltipMaxWidth:250,tooltipColor:i,tooltipBorderRadius:o,tooltipBg:a,tooltipRadiusOuter:s>4?4:s});return[wP(c),U$(n,"zoom-big-fast")]},n=>{let{zIndexPopupBase:o,colorBgSpotlight:i}=n;return{zIndexPopup:o+70,colorBgDefault:i}})(e),SP=za.map(e=>`${e}-inverse`),CP=["success","processing","error","default","warning"];function zm(e){return(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0)?[].concat(Q(SP),Q(za)).includes(e):za.includes(e)}function EP(e){return CP.includes(e)}function Hm(e,t){const r=zm(t),n=Y({[`${e}-${t}`]:t&&r}),o={},i={};return t&&!r&&(o.background=t,i["--antd-arrow-background-color"]=t),{className:n,overlayStyle:o,arrowStyle:i}}function xP(e){const{prefixCls:t,className:r,placement:n="top",title:o,color:i,overlayInnerStyle:a}=e,{getPrefixCls:s}=h.useContext(Je),c=s("tooltip",t),[l,u]=Dm(c,!0),f=Hm(c,i),d=Object.assign(Object.assign({},a),f.overlayStyle),g=f.arrowStyle;return l(h.createElement("div",{className:Y(u,c,`${c}-pure`,`${c}-placement-${n}`,r,f.className),style:g},h.createElement("div",{className:`${c}-arrow`}),h.createElement(Nm,Object.assign({},e,{className:u,prefixCls:c,overlayInnerStyle:d}),o)))}var _P=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{const r={},n=Object.assign({},e);return t.forEach(o=>{e&&o in e&&(r[o]=e[o],delete n[o])}),{picked:r,omitted:n}};function PP(e,t){const r=e.type;if((r.__ANT_BUTTON===!0||e.type==="button")&&e.props.disabled||r.__ANT_SWITCH===!0&&(e.props.disabled||e.props.loading)||r.__ANT_RADIO===!0&&e.props.disabled){const{picked:n,omitted:o}=$P(e.props.style,["position","left","right","top","bottom","float","display","zIndex"]),i=Object.assign(Object.assign({display:"inline-block"},n),{cursor:"not-allowed",width:e.props.block?"100%":void 0}),a=Object.assign(Object.assign({},o),{pointerEvents:"none"}),s=os(e,{style:a,className:null});return h.createElement("span",{style:i,className:Y(e.props.className,`${t}-disabled-compatible-wrapper`)},s)}return e}const Bm=h.forwardRef((e,t)=>{var r,n;const{prefixCls:o,openClassName:i,getTooltipContainer:a,overlayClassName:s,color:c,overlayInnerStyle:l,children:u,afterOpenChange:f,afterVisibleChange:d,destroyTooltipOnHide:g,arrow:v=!0}=e,m=!!v,{token:p}=OP(),{getPopupContainer:b,getPrefixCls:w,direction:E}=h.useContext(Je),$=h.useRef(null),S=()=>{var q;(q=$.current)===null||q===void 0||q.forceAlign()};h.useImperativeHandle(t,()=>({forceAlign:S,forcePopupAlign:()=>{S()}}));const[y,_]=nu(!1,{value:(r=e.open)!==null&&r!==void 0?r:e.visible,defaultValue:(n=e.defaultOpen)!==null&&n!==void 0?n:e.defaultVisible}),R=()=>{const{title:q,overlay:le}=e;return!q&&!le&&q!==0},A=q=>{var le,Se;_(R()?!1:q),R()||((le=e.onOpenChange)===null||le===void 0||le.call(e,q),(Se=e.onVisibleChange)===null||Se===void 0||Se.call(e,q))},k=()=>{var q,le;const{builtinPlacements:Se,arrowPointAtCenter:Fe=!1,autoAdjustOverflow:ne=!0}=e;let re=Fe;return typeof v=="object"&&(re=(le=(q=v.pointAtCenter)!==null&&q!==void 0?q:v.arrowPointAtCenter)!==null&&le!==void 0?le:Fe),Se||yP({arrowPointAtCenter:re,autoAdjustOverflow:ne,arrowWidth:m?p.sizePopupArrow:0,borderRadius:p.borderRadius,offset:p.marginXXS})},I=(q,le)=>{const Se=k(),Fe=Object.keys(Se).find(ne=>{var re,pe;return Se[ne].points[0]===((re=le.points)===null||re===void 0?void 0:re[0])&&Se[ne].points[1]===((pe=le.points)===null||pe===void 0?void 0:pe[1])});if(Fe){const ne=q.getBoundingClientRect(),re={top:"50%",left:"50%"};/top|Bottom/.test(Fe)?re.top=`${ne.height-le.offset[1]}px`:/Top|bottom/.test(Fe)&&(re.top=`${-le.offset[1]}px`),/left|Right/.test(Fe)?re.left=`${ne.width-le.offset[0]}px`:/right|Left/.test(Fe)&&(re.left=`${-le.offset[0]}px`),q.style.transformOrigin=`${re.left} ${re.top}`}},M=()=>{const{title:q,overlay:le}=e;return q===0?q:le||q||""},{getPopupContainer:C,placement:x="top",mouseEnterDelay:P=.1,mouseLeaveDelay:N=.1,overlayStyle:F,rootClassName:j}=e,D=_P(e,["getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName"]),B=w("tooltip",o),V=w(),W=e["data-popover-inject"];let z=y;!("open"in e)&&!("visible"in e)&&R()&&(z=!1);const se=PP(Hl(u)&&!sm(u)?u:h.createElement("span",null,u),B),J=se.props,me=!J.className||typeof J.className=="string"?Y(J.className,{[i||`${B}-open`]:!0}):J.className,[ge,ye]=Dm(B,!W),te=Hm(B,c),we=Object.assign(Object.assign({},l),te.overlayStyle),Pe=te.arrowStyle,Te=Y(s,{[`${B}-rtl`]:E==="rtl"},te.className,j,ye);return ge(h.createElement(cP,Object.assign({},D,{showArrow:m,placement:x,mouseEnterDelay:P,mouseLeaveDelay:N,prefixCls:B,overlayClassName:Te,overlayStyle:Object.assign(Object.assign({},Pe),F),getTooltipContainer:C||a||b,ref:$,builtinPlacements:k(),overlay:M(),visible:z,onVisibleChange:A,afterVisibleChange:f??d,onPopupAlign:I,overlayInnerStyle:we,arrowContent:h.createElement("span",{className:`${B}-arrow-content`}),motion:{motionName:w$(V,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:!!g}),z?os(se,{className:me}):se))});Bm._InternalPanelDoNotUseOrYouWillBeFired=xP;const Wm=Bm,TP=()=>{const[e,t]=h.useState(!1);return h.useEffect(()=>{t(k$())},[]),e};function kP(e){let{className:t,direction:r,index:n,marginDirection:o,children:i,split:a,wrap:s}=e;const{horizontalSize:c,verticalSize:l,latestIndex:u,supportFlexGap:f}=h.useContext(Vm);let d={};return f||(r==="vertical"?n{const{getPrefixCls:t,space:r,direction:n}=h.useContext(Je),{size:o=(r==null?void 0:r.size)||"small",align:i,className:a,rootClassName:s,children:c,direction:l="horizontal",prefixCls:u,split:f,style:d,wrap:g=!1}=e,v=MP(e,["size","align","className","rootClassName","children","direction","prefixCls","split","style","wrap"]),m=TP(),[p,b]=h.useMemo(()=>(Array.isArray(o)?o:[o,o]).map(x=>RP(x)),[o]),w=Zn(c,{keepEmpty:!0}),E=i===void 0&&l==="horizontal"?"center":i,$=t("space",u),[S,y]=fm($),_=Y($,y,`${$}-${l}`,{[`${$}-rtl`]:n==="rtl",[`${$}-align-${E}`]:E},a,s),R=`${$}-item`,A=n==="rtl"?"marginLeft":"marginRight";let k=0;const I=w.map((x,P)=>{x!=null&&(k=P);const N=x&&x.key||`${R}-${P}`;return h.createElement(kP,{className:R,key:N,direction:l,index:P,marginDirection:A,split:f,wrap:g},x)}),M=h.useMemo(()=>({horizontalSize:p,verticalSize:b,latestIndex:k,supportFlexGap:m}),[p,b,k,m]);if(w.length===0)return null;const C={};return g&&(C.flexWrap="wrap",m||(C.marginBottom=-b)),m&&(C.columnGap=p,C.rowGap=b),S(h.createElement("div",Object.assign({className:_,style:Object.assign(Object.assign({},C),d)},v),h.createElement(Vm.Provider,{value:M},I)))};Um.Compact=IO;const Gm=Um;var au={},FP={get exports(){return au},set exports(e){au=e}};(function(e,t){(function(r,n){e.exports=n()})(gb,function(){var r=1e3,n=6e4,o=36e5,i="millisecond",a="second",s="minute",c="hour",l="day",u="week",f="month",d="quarter",g="year",v="date",m="Invalid Date",p=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,b=/\[([^\]]+)]|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,w={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(C){var x=["th","st","nd","rd"],P=C%100;return"["+C+(x[(P-20)%10]||x[P]||x[0])+"]"}},E=function(C,x,P){var N=String(C);return!N||N.length>=x?C:""+Array(x+1-N.length).join(P)+C},$={s:E,z:function(C){var x=-C.utcOffset(),P=Math.abs(x),N=Math.floor(P/60),F=P%60;return(x<=0?"+":"-")+E(N,2,"0")+":"+E(F,2,"0")},m:function C(x,P){if(x.date()1)return C(D[0])}else{var B=x.name;y[B]=x,F=B}return!N&&F&&(S=F),F||!N&&S},A=function(C,x){if(_(C))return C.clone();var P=typeof x=="object"?x:{};return P.date=C,P.args=arguments,new I(P)},k=$;k.l=R,k.i=_,k.w=function(C,x){return A(C,{locale:x.$L,utc:x.$u,x:x.$x,$offset:x.$offset})};var I=function(){function C(P){this.$L=R(P.locale,null,!0),this.parse(P)}var x=C.prototype;return x.parse=function(P){this.$d=function(N){var F=N.date,j=N.utc;if(F===null)return new Date(NaN);if(k.u(F))return new Date;if(F instanceof Date)return new Date(F);if(typeof F=="string"&&!/Z$/i.test(F)){var D=F.match(p);if(D){var B=D[2]-1||0,V=(D[7]||"0").substring(0,3);return j?new Date(Date.UTC(D[1],B,D[3]||1,D[4]||0,D[5]||0,D[6]||0,V)):new Date(D[1],B,D[3]||1,D[4]||0,D[5]||0,D[6]||0,V)}}return new Date(F)}(P),this.$x=P.x||{},this.init()},x.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()},x.$utils=function(){return k},x.isValid=function(){return this.$d.toString()!==m},x.isSame=function(P,N){var F=A(P);return this.startOf(N)<=F&&F<=this.endOf(N)},x.isAfter=function(P,N){return A(P){const{componentCls:t,antCls:r}=e,n=`${t}-group`;return{[n]:Object.assign(Object.assign({},jr(e)),{display:"inline-block",fontSize:0,[`&${n}-rtl`]:{direction:"rtl"},[`${r}-badge ${r}-badge-count`]:{zIndex:1},[`> ${r}-badge:not(:first-child) > ${r}-button-wrapper`]:{borderInlineStart:"none"}})}},DP=e=>{const{componentCls:t,radioWrapperMarginRight:r,radioCheckedColor:n,radioSize:o,motionDurationSlow:i,motionDurationMid:a,motionEaseInOut:s,motionEaseInOutCirc:c,radioButtonBg:l,colorBorder:u,lineWidth:f,radioDotSize:d,colorBgContainerDisabled:g,colorTextDisabled:v,paddingXS:m,radioDotDisabledColor:p,lineType:b,radioDotDisabledSize:w,wireframe:E,colorWhite:$}=e,S=`${t}-inner`;return{[`${t}-wrapper`]:Object.assign(Object.assign({},jr(e)),{position:"relative",display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:r,cursor:"pointer",[`&${t}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:e.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},[`${t}-checked::after`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:"100%",height:"100%",border:`${f}px ${b} ${n}`,borderRadius:"50%",visibility:"hidden",animationName:LP,animationDuration:i,animationTimingFunction:s,animationFillMode:"both",content:'""'},[t]:Object.assign(Object.assign({},jr(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center"}),[`${t}-wrapper:hover &, &:hover ${S}`]:{borderColor:n},[`${t}-input:focus-visible + ${S}`]:Object.assign({},Ka(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:o,height:o,marginBlockStart:o/-2,marginInlineStart:o/-2,backgroundColor:E?n:$,borderBlockStart:0,borderInlineStart:0,borderRadius:o,transform:"scale(0)",opacity:0,transition:`all ${i} ${c}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:o,height:o,backgroundColor:l,borderColor:u,borderStyle:"solid",borderWidth:f,borderRadius:"50%",transition:`all ${a}`},[`${t}-input`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,insetBlockEnd:0,insetInlineStart:0,zIndex:1,cursor:"pointer",opacity:0},[`${t}-checked`]:{[S]:{borderColor:n,backgroundColor:E?l:n,"&::after":{transform:`scale(${d/o})`,opacity:1,transition:`all ${i} ${c}`}}},[`${t}-disabled`]:{cursor:"not-allowed",[S]:{backgroundColor:g,borderColor:u,cursor:"not-allowed","&::after":{backgroundColor:p}},[`${t}-input`]:{cursor:"not-allowed"},[`${t}-disabled + span`]:{color:v,cursor:"not-allowed"},[`&${t}-checked`]:{[S]:{"&::after":{transform:`scale(${w/o})`}}}},[`span${t} + *`]:{paddingInlineStart:m,paddingInlineEnd:m}})}},zP=e=>{const{radioButtonColor:t,controlHeight:r,componentCls:n,lineWidth:o,lineType:i,colorBorder:a,motionDurationSlow:s,motionDurationMid:c,radioButtonPaddingHorizontal:l,fontSize:u,radioButtonBg:f,fontSizeLG:d,controlHeightLG:g,controlHeightSM:v,paddingXS:m,borderRadius:p,borderRadiusSM:b,borderRadiusLG:w,radioCheckedColor:E,radioButtonCheckedBg:$,radioButtonHoverColor:S,radioButtonActiveColor:y,radioSolidCheckedColor:_,colorTextDisabled:R,colorBgContainerDisabled:A,radioDisabledButtonCheckedColor:k,radioDisabledButtonCheckedBg:I}=e;return{[`${n}-button-wrapper`]:{position:"relative",display:"inline-block",height:r,margin:0,paddingInline:l,paddingBlock:0,color:t,fontSize:u,lineHeight:`${r-o*2}px`,background:f,border:`${o}px ${i} ${a}`,borderBlockStartWidth:o+.02,borderInlineStartWidth:0,borderInlineEndWidth:o,cursor:"pointer",transition:[`color ${c}`,`background ${c}`,`border-color ${c}`,`box-shadow ${c}`].join(","),a:{color:t},[`> ${n}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:first-child)":{"&::before":{position:"absolute",insetBlockStart:-o,insetInlineStart:-o,display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:o,paddingInline:0,backgroundColor:a,transition:`background-color ${s}`,content:'""'}},"&:first-child":{borderInlineStart:`${o}px ${i} ${a}`,borderStartStartRadius:p,borderEndStartRadius:p},"&:last-child":{borderStartEndRadius:p,borderEndEndRadius:p},"&:first-child:last-child":{borderRadius:p},[`${n}-group-large &`]:{height:g,fontSize:d,lineHeight:`${g-o*2}px`,"&:first-child":{borderStartStartRadius:w,borderEndStartRadius:w},"&:last-child":{borderStartEndRadius:w,borderEndEndRadius:w}},[`${n}-group-small &`]:{height:v,paddingInline:m-o,paddingBlock:0,lineHeight:`${v-o*2}px`,"&:first-child":{borderStartStartRadius:b,borderEndStartRadius:b},"&:last-child":{borderStartEndRadius:b,borderEndEndRadius:b}},"&:hover":{position:"relative",color:E},"&:has(:focus-visible)":Object.assign({},Ka(e)),[`${n}-inner, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${n}-button-wrapper-disabled)`]:{zIndex:1,color:E,background:$,borderColor:E,"&::before":{backgroundColor:E},"&:first-child":{borderColor:E},"&:hover":{color:S,borderColor:S,"&::before":{backgroundColor:S}},"&:active":{color:y,borderColor:y,"&::before":{backgroundColor:y}}},[`${n}-group-solid &-checked:not(${n}-button-wrapper-disabled)`]:{color:_,background:E,borderColor:E,"&:hover":{color:_,background:S,borderColor:S},"&:active":{color:_,background:y,borderColor:y}},"&-disabled":{color:R,backgroundColor:A,borderColor:a,cursor:"not-allowed","&:first-child, &:hover":{color:R,backgroundColor:A,borderColor:a}},[`&-disabled${n}-button-wrapper-checked`]:{color:k,backgroundColor:I,borderColor:a,boxShadow:"none"}}}},Ym=cn("Radio",e=>{const{padding:t,lineWidth:r,controlItemBgActiveDisabled:n,colorTextDisabled:o,colorBgContainer:i,fontSizeLG:a,controlOutline:s,colorPrimaryHover:c,colorPrimaryActive:l,colorText:u,colorPrimary:f,marginXS:d,controlOutlineWidth:g,colorTextLightSolid:v,wireframe:m}=e,p=`0 0 0 ${g}px ${s}`,b=p,w=a,E=4,$=w-E*2,S=m?$:w-(E+r)*2,y=f,_=u,R=c,A=l,k=t-r,C=br(e,{radioFocusShadow:p,radioButtonFocusShadow:b,radioSize:w,radioDotSize:S,radioDotDisabledSize:$,radioCheckedColor:y,radioDotDisabledColor:o,radioSolidCheckedColor:v,radioButtonBg:i,radioButtonCheckedBg:i,radioButtonColor:_,radioButtonHoverColor:R,radioButtonActiveColor:A,radioButtonPaddingHorizontal:k,radioDisabledButtonCheckedBg:n,radioDisabledButtonCheckedColor:o,radioWrapperMarginRight:d});return[jP(C),DP(C),zP(C)]});var HP=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{var r,n;const o=h.useContext(Km),i=h.useContext(Xm),{getPrefixCls:a,direction:s}=h.useContext(Je),c=h.useRef(),l=Jn(t,c),{isFormItemInput:u}=h.useContext(Pm),f=A=>{var k,I;(k=e.onChange)===null||k===void 0||k.call(e,A),(I=o==null?void 0:o.onChange)===null||I===void 0||I.call(o,A)},{prefixCls:d,className:g,rootClassName:v,children:m,style:p}=e,b=HP(e,["prefixCls","className","rootClassName","children","style"]),w=a("radio",d),E=((o==null?void 0:o.optionType)||i)==="button"?`${w}-button`:w,[$,S]=Ym(w),y=Object.assign({},b),_=h.useContext(Za);o&&(y.name=o.name,y.onChange=f,y.checked=e.value===o.value,y.disabled=(r=y.disabled)!==null&&r!==void 0?r:o.disabled),y.disabled=(n=y.disabled)!==null&&n!==void 0?n:_;const R=Y(`${E}-wrapper`,{[`${E}-wrapper-checked`]:y.checked,[`${E}-wrapper-disabled`]:y.disabled,[`${E}-wrapper-rtl`]:s==="rtl",[`${E}-wrapper-in-form-item`]:u},g,v,S);return $(h.createElement("label",{className:R,style:p,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave},h.createElement(su,Object.assign({},y,{type:"radio",prefixCls:E,ref:l})),m!==void 0?h.createElement("span",null,m):null))},hs=h.forwardRef(BP),WP=h.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n}=h.useContext(Je),o=h.useContext(pi),[i,a]=nu(e.defaultValue,{value:e.value}),s=C=>{const x=i,P=C.target.value;"value"in e||a(P);const{onChange:N}=e;N&&P!==x&&N(C)},{prefixCls:c,className:l,rootClassName:u,options:f,buttonStyle:d="outline",disabled:g,children:v,size:m,style:p,id:b,onMouseEnter:w,onMouseLeave:E,onFocus:$,onBlur:S}=e,y=r("radio",c),_=`${y}-group`,[R,A]=Ym(y);let k=v;f&&f.length>0&&(k=f.map(C=>typeof C=="string"||typeof C=="number"?h.createElement(hs,{key:C.toString(),prefixCls:y,disabled:g,value:C,checked:i===C},C):h.createElement(hs,{key:`radio-group-value-options-${C.value}`,prefixCls:y,disabled:C.disabled||g,value:C.value,checked:i===C.value,style:C.style},C.label)));const I=m||o,M=Y(_,`${_}-${d}`,{[`${_}-${I}`]:I,[`${_}-rtl`]:n==="rtl"},l,u,A);return R(h.createElement("div",Object.assign({},bO(e),{className:M,style:p,onMouseEnter:w,onMouseLeave:E,onFocus:$,onBlur:S,id:b,ref:t}),h.createElement(NP,{value:{onChange:s,value:i,disabled:e.disabled,name:e.name,optionType:e.optionType}},k)))}),VP=h.memo(WP);var UP=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{const{getPrefixCls:r}=h.useContext(Je),{prefixCls:n}=e,o=UP(e,["prefixCls"]),i=r("radio",n);return h.createElement(IP,{value:"button"},h.createElement(hs,Object.assign({prefixCls:i},o,{type:"radio",ref:t})))},qP=h.forwardRef(GP),gs=hs;gs.Button=qP,gs.Group=VP,gs.__ANT_RADIO=!0;const cu=gs,KP=new Ct("antCheckboxEffect",{"0%":{transform:"scale(1)",opacity:.5},"100%":{transform:"scale(1.6)",opacity:0}}),XP=e=>{const{checkboxCls:t}=e,r=`${t}-wrapper`;return[{[`${t}-group`]:Object.assign(Object.assign({},jr(e)),{display:"inline-flex"}),[r]:Object.assign(Object.assign({},jr(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${r}`]:{marginInlineStart:e.marginXS},[`&${r}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[t]:Object.assign(Object.assign({},jr(e)),{top:"0.2em",position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,width:"100%",height:"100%",cursor:"pointer",opacity:0,[`&:focus-visible + ${t}-inner`]:Object.assign({},Ka(e))},[`${t}-inner`]:{boxSizing:"border-box",position:"relative",top:0,insetInlineStart:0,display:"block",width:e.checkboxSize,height:e.checkboxSize,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:e.checkboxSize/14*5,height:e.checkboxSize/14*8,border:`${e.lineWidthBold}px solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`}},"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}})},{[t]:{"&-indeterminate":{[`${t}-inner`]:{"&:after":{top:"50%",insetInlineStart:"50%",width:e.fontSizeLG/2,height:e.fontSizeLG/2,backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}}}}},{[`${r}:hover ${t}:after`]:{visibility:"visible"},[` ${r}:not(${r}-disabled), ${t}:not(${t}-disabled) `]:{[`&:hover ${t}-inner`]:{borderColor:e.colorPrimary}},[`${r}:not(${r}-disabled)`]:{[`&:hover ${t}-checked:not(${t}-disabled) ${t}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${t}-checked:not(${t}-disabled):after`]:{borderColor:e.colorPrimaryHover}}},{[`${t}-checked`]:{[`${t}-inner`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`}},"&:after":{position:"absolute",top:0,insetInlineStart:0,width:"100%",height:"100%",borderRadius:e.borderRadiusSM,visibility:"hidden",border:`${e.lineWidthBold}px solid ${e.colorPrimary}`,animationName:KP,animationDuration:e.motionDurationSlow,animationTimingFunction:"ease-in-out",animationFillMode:"backwards",content:'""',transition:`all ${e.motionDurationSlow}`}},[` ${r}-checked:not(${r}-disabled), ${t}-checked:not(${t}-disabled) `]:{[`&:hover ${t}-inner`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${t}:after`]:{borderColor:e.colorPrimaryHover}}},{[`${r}-disabled`]:{cursor:"not-allowed"},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},[`${t}-inner`]:{background:e.colorBgContainerDisabled,borderColor:e.colorBorder,"&:after":{borderColor:e.colorTextDisabled}},"&:after":{display:"none"},"& + span":{color:e.colorTextDisabled},[`&${t}-indeterminate ${t}-inner::after`]:{background:e.colorTextDisabled}}}]};function YP(e,t){const r=br(t,{checkboxCls:`.${e}`,checkboxSize:t.controlInteractiveSize});return[XP(r)]}const Zm=cn("Checkbox",(e,t)=>{let{prefixCls:r}=t;return[YP(r,e)]});var ZP=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{var{defaultValue:r,children:n,options:o=[],prefixCls:i,className:a,rootClassName:s,style:c,onChange:l}=e,u=ZP(e,["defaultValue","children","options","prefixCls","className","rootClassName","style","onChange"]);const{getPrefixCls:f,direction:d}=h.useContext(Je),[g,v]=h.useState(u.value||r||[]),[m,p]=h.useState([]);h.useEffect(()=>{"value"in u&&v(u.value||[])},[u.value]);const b=()=>o.map(M=>typeof M=="string"||typeof M=="number"?{label:M,value:M}:M),w=M=>{p(C=>C.filter(x=>x!==M))},E=M=>{p(C=>[].concat(Q(C),[M]))},$=M=>{const C=g.indexOf(M.value),x=Q(g);C===-1?x.push(M.value):x.splice(C,1),"value"in u||v(x);const P=b();l==null||l(x.filter(N=>m.includes(N)).sort((N,F)=>{const j=P.findIndex(B=>B.value===N),D=P.findIndex(B=>B.value===F);return j-D}))},S=f("checkbox",i),y=`${S}-group`,[_,R]=Zm(S),A=Th(u,["value","disabled"]);o&&o.length>0&&(n=b().map(M=>h.createElement(Jm,{prefixCls:S,key:M.value.toString(),disabled:"disabled"in M?M.disabled:u.disabled,value:M.value,checked:g.includes(M.value),onChange:M.onChange,className:`${y}-item`,style:M.style},M.label)));const k={toggleOption:$,value:g,disabled:u.disabled,name:u.name,registerValue:E,cancelValue:w},I=Y(y,{[`${y}-rtl`]:d==="rtl"},a,s,R);return _(h.createElement("div",Object.assign({className:I,style:c},A,{ref:t}),h.createElement(Qm.Provider,{value:k},n)))},JP=h.forwardRef(QP),e2=h.memo(JP);var t2=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{var r,{prefixCls:n,className:o,rootClassName:i,children:a,indeterminate:s=!1,style:c,onMouseEnter:l,onMouseLeave:u,skipGroup:f=!1,disabled:d}=e,g=t2(e,["prefixCls","className","rootClassName","children","indeterminate","style","onMouseEnter","onMouseLeave","skipGroup","disabled"]);const{getPrefixCls:v,direction:m}=h.useContext(Je),p=h.useContext(Qm),{isFormItemInput:b}=h.useContext(Pm),w=h.useContext(Za),E=(r=(p==null?void 0:p.disabled)||d)!==null&&r!==void 0?r:w,$=h.useRef(g.value);h.useEffect(()=>{p==null||p.registerValue(g.value)},[]),h.useEffect(()=>{if(!f)return g.value!==$.current&&(p==null||p.cancelValue($.current),p==null||p.registerValue(g.value),$.current=g.value),()=>p==null?void 0:p.cancelValue(g.value)},[g.value]);const S=v("checkbox",n),[y,_]=Zm(S),R=Object.assign({},g);p&&!f&&(R.onChange=function(){g.onChange&&g.onChange.apply(g,arguments),p.toggleOption&&p.toggleOption({label:a,value:g.value})},R.name=p.name,R.checked=p.value.includes(g.value));const A=Y({[`${S}-wrapper`]:!0,[`${S}-rtl`]:m==="rtl",[`${S}-wrapper-checked`]:R.checked,[`${S}-wrapper-disabled`]:E,[`${S}-wrapper-in-form-item`]:b},o,i,_),k=Y({[`${S}-indeterminate`]:s},_),I=s?"mixed":void 0;return y(h.createElement("label",{className:A,style:c,onMouseEnter:l,onMouseLeave:u},h.createElement(su,Object.assign({"aria-checked":I},R,{prefixCls:S,className:k,disabled:E,ref:t})),a!==void 0&&h.createElement("span",null,a)))},Jm=h.forwardRef(r2),lu=Jm;lu.Group=e2,lu.__ANT_CHECKBOX=!0;const n2=lu;var kn=h.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0});function uu(e,t,r){return(e-t)/(r-t)}function fu(e,t,r,n){var o=uu(t,r,n),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 yo(e,t){return Array.isArray(e)?e[t]:e}var o2=["prefixCls","value","valueIndex","onStartMove","style","render","dragging","onOffsetChange"],i2=h.forwardRef(function(e,t){var r,n,o=e.prefixCls,i=e.value,a=e.valueIndex,s=e.onStartMove,c=e.style,l=e.render,u=e.dragging,f=e.onOffsetChange,d=Bt(e,o2),g=h.useContext(kn),v=g.min,m=g.max,p=g.direction,b=g.disabled,w=g.keyboard,E=g.range,$=g.tabIndex,S=g.ariaLabelForHandle,y=g.ariaLabelledByForHandle,_=g.ariaValueTextFormatterForHandle,R="".concat(o,"-handle"),A=function(x){b||s(x,a)},k=function(x){if(!b&&w){var P=null;switch(x.which||x.keyCode){case K.LEFT:P=p==="ltr"||p==="btt"?-1:1;break;case K.RIGHT:P=p==="ltr"||p==="btt"?1:-1;break;case K.UP:P=p!=="ttb"?1:-1;break;case K.DOWN:P=p!=="ttb"?-1:1;break;case K.HOME:P="min";break;case K.END:P="max";break;case K.PAGE_UP:P=2;break;case K.PAGE_DOWN:P=-2;break}P!==null&&(x.preventDefault(),f(P,a))}},I=fu(p,i,v,m),M=h.createElement("div",Ht({ref:t,className:Y(R,(r={},oe(r,"".concat(R,"-").concat(a+1),E),oe(r,"".concat(R,"-dragging"),u),r)),style:H(H({},I),c),onMouseDown:A,onTouchStart:A,onKeyDown:k,tabIndex:b?null:yo($,a),role:"slider","aria-valuemin":v,"aria-valuemax":m,"aria-valuenow":i,"aria-disabled":b,"aria-label":yo(S,a),"aria-labelledby":yo(y,a),"aria-valuetext":(n=yo(_,a))===null||n===void 0?void 0:n(i)},d));return l&&(M=l(M,{index:a,prefixCls:o,value:i,dragging:u})),M}),a2=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","draggingIndex"],s2=h.forwardRef(function(e,t){var r=e.prefixCls,n=e.style,o=e.onStartMove,i=e.onOffsetChange,a=e.values,s=e.handleRender,c=e.draggingIndex,l=Bt(e,a2),u=h.useRef({});return h.useImperativeHandle(t,function(){return{focus:function(d){var g;(g=u.current[d])===null||g===void 0||g.focus()}}}),h.createElement(h.Fragment,null,a.map(function(f,d){return h.createElement(i2,Ht({ref:function(v){v?u.current[d]=v:delete u.current[d]},dragging:c===d,prefixCls:r,style:yo(n,d),key:d,value:f,valueIndex:d,onStartMove:o,onOffsetChange:i,render:s},l))}))});function ep(e){var t="touches"in e?e.touches[0]:e;return{pageX:t.pageX,pageY:t.pageY}}function c2(e,t,r,n,o,i,a,s,c){var l=h.useState(null),u=G(l,2),f=u[0],d=u[1],g=h.useState(-1),v=G(g,2),m=v[0],p=v[1],b=h.useState(r),w=G(b,2),E=w[0],$=w[1],S=h.useState(r),y=G(S,2),_=y[0],R=y[1],A=h.useRef(null),k=h.useRef(null);h.useEffect(function(){m===-1&&$(r)},[r,m]),h.useEffect(function(){return function(){document.removeEventListener("mousemove",A.current),document.removeEventListener("mouseup",k.current),document.removeEventListener("touchmove",A.current),document.removeEventListener("touchend",k.current)}},[]);var I=function(F,j){E.some(function(D,B){return D!==F[B]})&&(j!==void 0&&d(j),$(F),a(F))},M=function(F,j){if(F===-1){var D=_[0],B=_[_.length-1],V=n-D,W=o-B,z=j*(o-n);z=Math.max(z,V),z=Math.min(z,W);var se=i(D+z);z=se-D;var J=_.map(function(te){return te+z});I(J)}else{var me=(o-n)*j,ge=Q(E);ge[F]=_[F];var ye=c(ge,me,F,"dist");I(ye.values,ye.value)}},C=h.useRef(M);C.current=M;var x=function(F,j){F.stopPropagation();var D=r[j];p(j),d(D),R(r);var B=ep(F),V=B.pageX,W=B.pageY,z=function(me){me.preventDefault();var ge=ep(me),ye=ge.pageX,te=ge.pageY,we=ye-V,Pe=te-W,Te=e.current.getBoundingClientRect(),q=Te.width,le=Te.height,Se;switch(t){case"btt":Se=-Pe/le;break;case"ttb":Se=Pe/le;break;case"rtl":Se=-we/q;break;default:Se=we/q}C.current(j,Se)},se=function J(me){me.preventDefault(),document.removeEventListener("mouseup",J),document.removeEventListener("mousemove",z),document.removeEventListener("touchend",J),document.removeEventListener("touchmove",z),A.current=null,k.current=null,p(-1),s()};document.addEventListener("mouseup",se),document.addEventListener("mousemove",z),document.addEventListener("touchend",se),document.addEventListener("touchmove",z),A.current=z,k.current=se},P=h.useMemo(function(){var N=Q(r).sort(function(j,D){return j-D}),F=Q(E).sort(function(j,D){return j-D});return N.every(function(j,D){return j===F[D]})?E:r},[r,E]);return[m,f,P,x]}function l2(e){var t=e.prefixCls,r=e.style,n=e.start,o=e.end,i=e.index,a=e.onStartMove,s=h.useContext(kn),c=s.direction,l=s.min,u=s.max,f=s.disabled,d=s.range,g="".concat(t,"-track"),v=uu(n,l,u),m=uu(o,l,u),p=function(E){!f&&a&&a(E,-1)},b={};switch(c){case"rtl":b.right="".concat(v*100,"%"),b.width="".concat(m*100-v*100,"%");break;case"btt":b.bottom="".concat(v*100,"%"),b.height="".concat(m*100-v*100,"%");break;case"ttb":b.top="".concat(v*100,"%"),b.height="".concat(m*100-v*100,"%");break;default:b.left="".concat(v*100,"%"),b.width="".concat(m*100-v*100,"%")}return h.createElement("div",{className:Y(g,d&&"".concat(g,"-").concat(i+1)),style:H(H({},b),r),onMouseDown:p,onTouchStart:p})}function u2(e){var t=e.prefixCls,r=e.style,n=e.values,o=e.startPoint,i=e.onStartMove,a=h.useContext(kn),s=a.included,c=a.range,l=a.min,u=h.useMemo(function(){if(!c){if(n.length===0)return[];var f=o??l,d=n[0];return[{start:Math.min(f,d),end:Math.max(f,d)}]}for(var g=[],v=0;v3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof m=="number"){var w,E=v[p],$=E+m,S=[];n.forEach(function(k){S.push(k.value)}),S.push(e,t),S.push(s(E));var y=m>0?1:-1;b==="unit"?S.push(s(E+y*r)):S.push(s($)),S=S.filter(function(k){return k!==null}).filter(function(k){return m<0?k<=E:k>=E}),b==="unit"&&(S=S.filter(function(k){return k!==E}));var _=b==="unit"?E:$;w=S[0];var R=Math.abs(w-_);if(S.forEach(function(k){var I=Math.abs(k-_);I1){var A=Q(v);return A[p]=w,g(A,m-y,p,b)}return w}else{if(m==="min")return e;if(m==="max")return t}},u=function(v,m,p){var b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",w=v[p],E=l(v,m,p,b);return{value:E,changed:E!==w}},f=function(v){return i===null&&v===0||typeof i=="number"&&v3&&arguments[3]!==void 0?arguments[3]:"unit",w=v.map(c),E=w[p],$=l(w,m,p,b);if(w[p]=$,o===!1){var S=i||0;p>0&&w[p-1]!==E&&(w[p]=Math.max(w[p],w[p-1]+S)),p0;A-=1)for(var k=!0;f(w[A]-w[A-1])&&k;){var I=u(w,-1,A-1);w[A-1]=I.value,k=I.changed}for(var M=w.length-1;M>0;M-=1)for(var C=!0;f(w[M]-w[M-1])&&C;){var x=u(w,-1,M-1);w[M-1]=x.value,C=x.changed}for(var P=0;P=0?x:!1},[x,pe]),Dt=h.useMemo(function(){var Ie=Object.keys(me||{});return Ie.map(function(he){var ae=me[he],We={value:Number(he)};return ae&&Ue(ae)==="object"&&!h.isValidElement(ae)&&("label"in ae||"style"in ae)?(We.style=ae.style,We.label=ae.label):We.label=ae,We}).filter(function(he){var ae=he.label;return ae||typeof ae=="number"}).sort(function(he,ae){return he.value-ae.value})},[me]),gn=m2(ne,re,pe,Dt,M,Xe),qr=G(gn,2),st=qr[0],Ce=qr[1],Kr=nu(S,{value:$}),ke=G(Kr,2),Me=ke[0],Ne=ke[1],fe=h.useMemo(function(){var Ie=Me==null?[]:Array.isArray(Me)?Me:[Me],he=G(Ie,1),ae=he[0],We=ae===void 0?ne:ae,Ae=Me===null?[]:[We];if(y){if(Ae=Q(Ie),_||Me===void 0){var sr=_>=0?_+1:2;for(Ae=Ae.slice(0,sr);Ae.length=0&&le.current.focus(Ie)}Dn(null)},[jn]);var No=h.useMemo(function(){return P&&pe===null?!1:P},[P,pe]),Xr=function(){k==null||k(Gt(Ot.current))},pt=c2(Se,Fe,fe,ne,re,st,nr,Xr,Ce),Yr=G(pt,4),Pr=Yr[0],Zr=Yr[1],ir=Yr[2],Qr=Yr[3],$t=function(he,ae){Qr(he,ae),A==null||A(Gt(Ot.current))},Hn=Pr!==-1;h.useEffect(function(){if(!Hn){var Ie=fe.lastIndexOf(Zr);le.current.focus(Ie)}},[Hn]);var qt=h.useMemo(function(){return Q(ir).sort(function(Ie,he){return Ie-he})},[ir]),Jr=h.useMemo(function(){return y?[qt[0],qt[qt.length-1]]:[ne,qt[0]]},[qt,y,ne]),Tr=G(Jr,2),ar=Tr[0],kr=Tr[1];h.useImperativeHandle(t,function(){return{focus:function(){le.current.focus(0)},blur:function(){var he=document,ae=he.activeElement;Se.current.contains(ae)&&(ae==null||ae.blur())}}}),h.useEffect(function(){f&&le.current.focus(0)},[]);var pn=h.useMemo(function(){return{min:ne,max:re,direction:Fe,disabled:c,keyboard:u,step:pe,included:D,includedStart:ar,includedEnd:kr,range:y,tabIndex:we,ariaLabelForHandle:Pe,ariaLabelledByForHandle:Te,ariaValueTextFormatterForHandle:q}},[ne,re,Fe,c,u,pe,D,ar,kr,y,we,Pe,Te,q]);return h.createElement(kn.Provider,{value:pn},h.createElement("div",{ref:Se,className:Y(o,i,(r={},oe(r,"".concat(o,"-disabled"),c),oe(r,"".concat(o,"-vertical"),F),oe(r,"".concat(o,"-horizontal"),!F),oe(r,"".concat(o,"-with-marks"),Dt.length),r)),style:a,onMouseDown:or},h.createElement("div",{className:"".concat(o,"-rail"),style:z}),h.createElement(u2,{prefixCls:o,style:V,values:qt,startPoint:B,onStartMove:No?$t:null}),h.createElement(g2,{prefixCls:o,marks:Dt,dots:ge,style:se,activeStyle:J}),h.createElement(s2,{ref:le,prefixCls:o,style:W,values:ir,draggingIndex:Pr,onStartMove:$t,onOffsetChange:zn,onFocus:d,onBlur:g,handleRender:ye}),h.createElement(d2,{prefixCls:o,marks:Dt,onClick:mt})))});const v2=h.forwardRef((e,t)=>{const{open:r}=e,n=T.useRef(null),o=T.useRef(null);function i(){Tn.cancel(o.current),o.current=null}function a(){o.current=Tn(()=>{var s;(s=n.current)===null||s===void 0||s.forcePopupAlign(),o.current=null})}return h.useEffect(()=>(r?a():i(),i),[r,e.title]),h.createElement(Wm,Object.assign({ref:Jn(n,t)},e))}),b2=e=>{const{componentCls:t,controlSize:r,dotSize:n,marginFull:o,marginPart:i,colorFillContentHover:a}=e;return{[t]:Object.assign(Object.assign({},jr(e)),{position:"relative",height:r,margin:`${i}px ${o}px`,padding:0,cursor:"pointer",touchAction:"none",["&-vertical"]:{margin:`${o}px ${i}px`},[`${t}-rail`]:{position:"absolute",backgroundColor:e.colorFillTertiary,borderRadius:e.borderRadiusXS,transition:`background-color ${e.motionDurationMid}`},[`${t}-track`]:{position:"absolute",backgroundColor:e.colorPrimaryBorder,borderRadius:e.borderRadiusXS,transition:`background-color ${e.motionDurationMid}`},"&:hover":{[`${t}-rail`]:{backgroundColor:e.colorFillSecondary},[`${t}-track`]:{backgroundColor:e.colorPrimaryBorderHover},[`${t}-dot`]:{borderColor:a},[`${t}-handle::after`]:{boxShadow:`0 0 0 ${e.handleLineWidth}px ${e.colorPrimaryBorderHover}`},[`${t}-dot-active`]:{borderColor:e.colorPrimary}},[`${t}-handle`]:{position:"absolute",width:e.handleSize,height:e.handleSize,outline:"none",[`${t}-dragging`]:{zIndex:1},"&::before":{content:'""',position:"absolute",insetInlineStart:-e.handleLineWidth,insetBlockStart:-e.handleLineWidth,width:e.handleSize+e.handleLineWidth*2,height:e.handleSize+e.handleLineWidth*2,backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:e.handleSize,height:e.handleSize,backgroundColor:e.colorBgElevated,boxShadow:`0 0 0 ${e.handleLineWidth}px ${e.colorPrimaryBorder}`,borderRadius:"50%",cursor:"pointer",transition:` inset-inline-start ${e.motionDurationMid}, inset-block-start ${e.motionDurationMid}, width ${e.motionDurationMid}, height ${e.motionDurationMid}, box-shadow ${e.motionDurationMid} `},"&:hover, &:active, &:focus":{"&::before":{insetInlineStart:-((e.handleSizeHover-e.handleSize)/2+e.handleLineWidthHover),insetBlockStart:-((e.handleSizeHover-e.handleSize)/2+e.handleLineWidthHover),width:e.handleSizeHover+e.handleLineWidthHover*2,height:e.handleSizeHover+e.handleLineWidthHover*2},"&::after":{boxShadow:`0 0 0 ${e.handleLineWidthHover}px ${e.colorPrimary}`,width:e.handleSizeHover,height:e.handleSizeHover,insetInlineStart:(e.handleSize-e.handleSizeHover)/2,insetBlockStart:(e.handleSize-e.handleSizeHover)/2}}},[`${t}-mark`]:{position:"absolute",fontSize:e.fontSize},[`${t}-mark-text`]:{position:"absolute",display:"inline-block",color:e.colorTextDescription,textAlign:"center",wordBreak:"keep-all",cursor:"pointer",userSelect:"none","&-active":{color:e.colorText}},[`${t}-step`]:{position:"absolute",background:"transparent",pointerEvents:"none"},[`${t}-dot`]:{position:"absolute",width:n,height:n,backgroundColor:e.colorBgElevated,border:`${e.handleLineWidth}px solid ${e.colorBorderSecondary}`,borderRadius:"50%",cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,pointerEvents:"auto","&-active":{borderColor:e.colorPrimaryBorder}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-rail`]:{backgroundColor:`${e.colorFillSecondary} !important`},[`${t}-track`]:{backgroundColor:`${e.colorTextDisabled} !important`},[` ${t}-dot `]:{backgroundColor:e.colorBgElevated,borderColor:e.colorTextDisabled,boxShadow:"none",cursor:"not-allowed"},[`${t}-handle::after`]:{backgroundColor:e.colorBgElevated,cursor:"not-allowed",width:e.handleSize,height:e.handleSize,boxShadow:`0 0 0 ${e.handleLineWidth}px ${new ht(e.colorTextDisabled).onBackground(e.colorBgContainer).toHexShortString()}`,insetInlineStart:0,insetBlockStart:0},[` ${t}-mark-text, ${t}-dot `]:{cursor:"not-allowed !important"}}})}},tp=(e,t)=>{const{componentCls:r,railSize:n,handleSize:o,dotSize:i}=e,a=t?"paddingBlock":"paddingInline",s=t?"width":"height",c=t?"height":"width",l=t?"insetBlockStart":"insetInlineStart",u=t?"top":"insetInlineStart";return{[a]:n,[c]:n*3,[`${r}-rail`]:{[s]:"100%",[c]:n},[`${r}-track`]:{[c]:n},[`${r}-handle`]:{[l]:(n*3-o)/2},[`${r}-mark`]:{insetInlineStart:0,top:0,[u]:o,[s]:"100%"},[`${r}-step`]:{insetInlineStart:0,top:0,[u]:n,[s]:"100%",[c]:n},[`${r}-dot`]:{position:"absolute",[l]:(n-i)/2}}},y2=e=>{const{componentCls:t,marginPartWithMark:r}=e;return{[`${t}-horizontal`]:Object.assign(Object.assign({},tp(e,!0)),{[`&${t}-with-marks`]:{marginBottom:r}})}},w2=e=>{const{componentCls:t}=e;return{[`${t}-vertical`]:Object.assign(Object.assign({},tp(e,!1)),{height:"100%"})}},S2=cn("Slider",e=>{const t=br(e,{marginPart:(e.controlHeight-e.controlSize)/2,marginFull:e.controlSize/2,marginPartWithMark:e.controlHeightLG-e.controlSize});return[b2(t),y2(t),w2(t)]},e=>{const r=e.controlHeightLG/4,n=e.controlHeightSM/2,o=e.lineWidth+1,i=e.lineWidth+1*3;return{controlSize:r,railSize:4,handleSize:r,handleSizeHover:n,dotSize:8,handleLineWidth:o,handleLineWidthHover:i}});var C2=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);otypeof e=="number"?e.toString():"",x2=h.forwardRef((e,t)=>{const{prefixCls:r,range:n,className:o,rootClassName:i,tooltipPrefixCls:a,tipFormatter:s,tooltipVisible:c,getTooltipPopupContainer:l,tooltipPlacement:u}=e,f=C2(e,["prefixCls","range","className","rootClassName","tooltipPrefixCls","tipFormatter","tooltipVisible","getTooltipPopupContainer","tooltipPlacement"]),{getPrefixCls:d,direction:g,getPopupContainer:v}=h.useContext(Je),[m,p]=h.useState({}),b=(k,I)=>{p(M=>Object.assign(Object.assign({},M),{[k]:I}))},w=(k,I)=>k||(I?g==="rtl"?"left":"right":"top"),E=d("slider",r),[$,S]=S2(E),y=Y(o,i,{[`${E}-rtl`]:g==="rtl"},S);g==="rtl"&&!f.vertical&&(f.reverse=!f.reverse);const[_,R]=h.useMemo(()=>n?typeof n=="object"?[!0,n.draggableTrack]:[!0,!1]:[!1],[n]),A=(k,I)=>{var M;const{index:C,dragging:x}=I,{tooltip:P={},vertical:N}=e,F=Object.assign({},P),{open:j,placement:D,getPopupContainer:B,prefixCls:V,formatter:W}=F;let z;W||W===null?z=W:s||s===null?z=s:z=E2;const se=z?m[C]||x:!1,J=(M=j??c)!==null&&M!==void 0?M:j===void 0&&se,me=Object.assign(Object.assign({},k.props),{onMouseEnter:()=>b(C,!0),onMouseLeave:()=>b(C,!1)}),ge=d("tooltip",V??a);return h.createElement(v2,{prefixCls:ge,title:z?z(I.value):"",open:J,placement:w(D??u,N),key:C,overlayClassName:`${E}-tooltip`,getPopupContainer:B||l||v},h.cloneElement(k,me))};return $(h.createElement(p2,Object.assign({},f,{step:f.step,range:_,draggableTrack:R,className:y,ref:t,prefixCls:E,handleRender:A})))});function _2(e){return typeof e!="string"?e:e.charAt(0).toUpperCase()+e.slice(1)}const ms=(e,t,r)=>{const n=_2(r);return{[`${e.componentCls}-${t}`]:{color:e[`color${r}`],background:e[`color${n}Bg`],borderColor:e[`color${n}Border`]}}},O2=e=>Mg(e,(t,r)=>{let{textColor:n,lightBorderColor:o,lightColor:i,darkColor:a}=r;return{[`${e.componentCls}-${t}`]:{color:n,background:i,borderColor:o,"&-inverse":{color:e.colorTextLightSolid,background:a,borderColor:a}}}}),$2=e=>{const{paddingXXS:t,lineWidth:r,tagPaddingHorizontal:n,componentCls:o}=e,i=n-r,a=t-r;return{[o]:Object.assign(Object.assign({},jr(e)),{display:"inline-block",height:"auto",marginInlineEnd:e.marginXS,paddingInline:i,fontSize:e.tagFontSize,lineHeight:`${e.tagLineHeight}px`,whiteSpace:"nowrap",background:e.tagDefaultBg,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,opacity:1,transition:`all ${e.motionDurationMid}`,textAlign:"start",[`&${o}-rtl`]:{direction:"rtl"},"&, a, a:hover":{color:e.tagDefaultColor},[`${o}-close-icon`]:{marginInlineStart:a,color:e.colorTextDescription,fontSize:e.tagIconSize,cursor:"pointer",transition:`all ${e.motionDurationMid}`,"&:hover":{color:e.colorTextHeading}},[`&${o}-has-color`]:{borderColor:"transparent",[`&, a, a:hover, ${e.iconCls}-close, ${e.iconCls}-close:hover`]:{color:e.colorTextLightSolid}},["&-checkable"]:{backgroundColor:"transparent",borderColor:"transparent",cursor:"pointer",[`&:not(${o}-checkable-checked):hover`]:{color:e.colorPrimary,backgroundColor:e.colorFillSecondary},"&:active, &-checked":{color:e.colorTextLightSolid},"&-checked":{backgroundColor:e.colorPrimary,"&:hover":{backgroundColor:e.colorPrimaryHover}},"&:active":{backgroundColor:e.colorPrimaryActive}},["&-hidden"]:{display:"none"},[`> ${e.iconCls} + span, > span + ${e.iconCls}`]:{marginInlineStart:i}})}},rp=cn("Tag",e=>{const{fontSize:t,lineHeight:r,lineWidth:n,fontSizeIcon:o}=e,i=Math.round(t*r),a=e.fontSizeSM,s=i-n*2,c=e.colorFillAlter,l=e.colorText,u=br(e,{tagFontSize:a,tagLineHeight:s,tagDefaultBg:c,tagDefaultColor:l,tagIconSize:o-2*n,tagPaddingHorizontal:8});return[$2(u),O2(u),ms(u,"success","Success"),ms(u,"processing","Info"),ms(u,"error","Error"),ms(u,"warning","Warning")]});var P2=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{var{prefixCls:t,className:r,checked:n,onChange:o,onClick:i}=e,a=P2(e,["prefixCls","className","checked","onChange","onClick"]);const{getPrefixCls:s}=h.useContext(Je),c=g=>{o==null||o(!n),i==null||i(g)},l=s("tag",t),[u,f]=rp(l),d=Y(l,{[`${l}-checkable`]:!0,[`${l}-checkable-checked`]:n},r,f);return u(h.createElement("span",Object.assign({},a,{className:d,onClick:c})))};var k2=globalThis&&globalThis.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o{var{prefixCls:r,className:n,rootClassName:o,style:i,children:a,icon:s,color:c,onClose:l,closeIcon:u,closable:f=!1}=e,d=k2(e,["prefixCls","className","rootClassName","style","children","icon","color","onClose","closeIcon","closable"]);const{getPrefixCls:g,direction:v}=h.useContext(Je),[m,p]=h.useState(!0);h.useEffect(()=>{"visible"in d&&p(d.visible)},[d.visible]);const b=zm(c)||EP(c),w=Object.assign({backgroundColor:c&&!b?c:void 0},i),E=g("tag",r),[$,S]=rp(E),y=Y(E,{[`${E}-${c}`]:b,[`${E}-has-color`]:c&&!b,[`${E}-hidden`]:!m,[`${E}-rtl`]:v==="rtl"},n,o,S),_=C=>{C.stopPropagation(),l==null||l(C),!C.defaultPrevented&&p(!1)},R=()=>f?u?h.createElement("span",{className:`${E}-close-icon`,onClick:_},u):h.createElement(tO,{className:`${E}-close-icon`,onClick:_}):null,A=typeof d.onClick=="function"||a&&a.type==="a",k=s||null,I=k?h.createElement(h.Fragment,null,k,h.createElement("span",null,a)):a,M=h.createElement("span",Object.assign({},d,{ref:t,className:y,style:w}),I,R());return $(A?h.createElement(gm,null,M):M)},np=h.forwardRef(M2);np.CheckableTag=T2;const ps=np;function op({children:e}){const t=Nc();return L(V_,{theme:{algorithm:t?iu.darkAlgorithm:iu.defaultAlgorithm,token:{colorPrimary:"#ff6699"}},children:e})}var wo={},A2={get exports(){return wo},set exports(e){wo=e}};const R2=(e,t)=>Math.floor(Math.random()*(t-e+1)+e),ip=()=>{const e=new Error("Delay aborted");return e.name="AbortError",e},ap=({clearTimeout:e,setTimeout:t,willResolve:r})=>(n,{value:o,signal:i}={})=>{if(i&&i.aborted)return Promise.reject(ip());let a,s,c;const l=e||clearTimeout,u=()=>{l(a),c(ip())},f=()=>{i&&i.removeEventListener("abort",u)},d=new Promise((g,v)=>{s=()=>{f(),r?g(o):v(o)},c=v,a=(t||setTimeout)(s,n)});return i&&i.addEventListener("abort",u,{once:!0}),d.clear=()=>{l(a),a=null,s()},d},sp=e=>{const t=ap({...e,willResolve:!0});return t.reject=ap({...e,willResolve:!1}),t.range=(r,n,o)=>t(R2(r,n),o),t},du=sp();du.createWithTimers=sp,A2.exports=du,wo.default=du;const F2=10*1e3,N2=200;async function cp(e,t){let r=[];const n=()=>{r=Array.from(document.querySelectorAll(e))};n();const o=performance.now();for(;!r.length&&performance.now()-ot.remove())}function lp(){var t;const e=(((t=document.activeElement)==null?void 0:t.tagName)||"").toLowerCase();return!!(["input","textarea"].includes(e)||document.querySelector(".center-search__bar.is-focus"))}var vs,up=ve;vs=up.createRoot,up.hydrateRoot;const uA="";var gu={},Et={};Object.defineProperty(Et,"__esModule",{value:!0}),Et.DEFAULT_ICON_CONFIGS=void 0,Et.IconConverter=mp,Et.IconProvider=void 0,Et.IconWrapper=W2;var bs=I2(T);function fp(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,r=new WeakMap;return(fp=function(n){return n?r:t})(e)}function I2(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var r=fp(t);if(r&&r.has(e))return r.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(i!=="default"&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(n,i,a):n[i]=e[i]}return n.default=e,r&&r.set(e,n),n}var L2=["size","strokeWidth","strokeLinecap","strokeLinejoin","theme","fill","className","spin"];function dp(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function hp(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function z2(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i=0)&&(r[o]=e[o]);return r}var gp={size:"1em",strokeWidth:4,strokeLinecap:"round",strokeLinejoin:"round",rtl:!1,theme:"outline",colors:{outline:{fill:"#333",background:"transparent"},filled:{fill:"#333",background:"#FFF"},twoTone:{fill:"#333",twoTone:"#2F88FF"},multiColor:{outStrokeColor:"#333",outFillColor:"#2F88FF",innerStrokeColor:"#FFF",innerFillColor:"#43CCF8"}},prefix:"i"};Et.DEFAULT_ICON_CONFIGS=gp;function H2(){return"icon-"+((1+Math.random())*4294967296|0).toString(16).substring(1)}function mp(e,t,r){var n=typeof t.fill=="string"?[t.fill]:t.fill||[],o=[],i=t.theme||r.theme;switch(i){case"outline":o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push("none"),o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push("none");break;case"filled":o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push("#FFF"),o.push("#FFF");break;case"two-tone":o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push(typeof n[1]=="string"?n[1]:r.colors.twoTone.twoTone),o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push(typeof n[1]=="string"?n[1]:r.colors.twoTone.twoTone);break;case"multi-color":o.push(typeof n[0]=="string"?n[0]:"currentColor"),o.push(typeof n[1]=="string"?n[1]:r.colors.multiColor.outFillColor),o.push(typeof n[2]=="string"?n[2]:r.colors.multiColor.innerStrokeColor),o.push(typeof n[3]=="string"?n[3]:r.colors.multiColor.innerFillColor);break}return{size:t.size||r.size,strokeWidth:t.strokeWidth||r.strokeWidth,strokeLinecap:t.strokeLinecap||r.strokeLinecap,strokeLinejoin:t.strokeLinejoin||r.strokeLinejoin,colors:o,id:e}}var pp=(0,bs.createContext)(gp),B2=pp.Provider;Et.IconProvider=B2;function W2(e,t,r){return function(n){var o=n.size,i=n.strokeWidth,a=n.strokeLinecap,s=n.strokeLinejoin,c=n.theme,l=n.fill,u=n.className,f=n.spin,d=D2(n,L2),g=(0,bs.useContext)(pp),v=(0,bs.useMemo)(H2,[]),m=mp(v,{size:o,strokeWidth:i,strokeLinecap:a,strokeLinejoin:s,theme:c,fill:l},g),p=[g.prefix+"-icon"];return p.push(g.prefix+"-icon-"+e),t&&g.rtl&&p.push(g.prefix+"-icon-rtl"),f&&p.push(g.prefix+"-icon-spin"),u&&p.push(u),bs.default.createElement("span",hp(hp({},d),{},{className:p.join(" ")}),r(m))}}Object.defineProperty(gu,"__esModule",{value:!0});var vp=gu.default=void 0,mu=U2(T),V2=Et;function U2(e){return e&&e.__esModule?e:{default:e}}var G2=(0,V2.IconWrapper)("close",!1,function(e){return mu.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},mu.default.createElement("path",{d:"M8 8L40 40",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),mu.default.createElement("path",{d:"M8 40L40 8",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});vp=gu.default=G2;var pu={};Object.defineProperty(pu,"__esModule",{value:!0});var bp=pu.default=void 0,vu=K2(T),q2=Et;function K2(e){return e&&e.__esModule?e:{default:e}}var X2=(0,q2.IconWrapper)("config",!1,function(e){return vu.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},vu.default.createElement("path",{d:"M24 4L18 10H10V18L4 24L10 30V38H18L24 44L30 38H38V30L44 24L38 18V10H30L24 4Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),vu.default.createElement("path",{d:"M24 30C27.3137 30 30 27.3137 30 24C30 20.6863 27.3137 18 24 18C20.6863 18 18 20.6863 18 24C18 27.3137 20.6863 30 24 30Z",fill:e.colors[3],stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}))});bp=pu.default=X2;var bu={};Object.defineProperty(bu,"__esModule",{value:!0});var yp=bu.default=void 0,wi=Z2(T),Y2=Et;function Z2(e){return e&&e.__esModule?e:{default:e}}var Q2=(0,Y2.IconWrapper)("distraught-face",!1,function(e){return wi.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},wi.default.createElement("path",{d:"M24 44C35.0457 44 44 35.0457 44 24C44 12.9543 35.0457 4 24 4C12.9543 4 4 12.9543 4 24C4 35.0457 12.9543 44 24 44Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),wi.default.createElement("path",{d:"M24 29C29 29 31 33 31 33H17C17 33 19 29 24 29Z",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),wi.default.createElement("path",{d:"M32 17L29 20L32 23",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),wi.default.createElement("path",{d:"M16 17L19 20L16 23",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});yp=bu.default=Q2;var yu={};Object.defineProperty(yu,"__esModule",{value:!0});var wp=yu.default=void 0,Si=eT(T),J2=Et;function eT(e){return e&&e.__esModule?e:{default:e}}var tT=(0,J2.IconWrapper)("info",!0,function(e){return Si.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},Si.default.createElement("path",{d:"M24 44C29.5228 44 34.5228 41.7614 38.1421 38.1421C41.7614 34.5228 44 29.5228 44 24C44 18.4772 41.7614 13.4772 38.1421 9.85786C34.5228 6.23858 29.5228 4 24 4C18.4772 4 13.4772 6.23858 9.85786 9.85786C6.23858 13.4772 4 18.4772 4 24C4 29.5228 6.23858 34.5228 9.85786 38.1421C13.4772 41.7614 18.4772 44 24 44Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinejoin:e.strokeLinejoin}),Si.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M24 11C25.3807 11 26.5 12.1193 26.5 13.5C26.5 14.8807 25.3807 16 24 16C22.6193 16 21.5 14.8807 21.5 13.5C21.5 12.1193 22.6193 11 24 11Z",fill:e.colors[2]}),Si.default.createElement("path",{d:"M24.5 34V20H23.5H22.5",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),Si.default.createElement("path",{d:"M21 34H28",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});wp=yu.default=tT;var wu={};Object.defineProperty(wu,"__esModule",{value:!0});var Sp=wu.default=void 0,Su=nT(T),rT=Et;function nT(e){return e&&e.__esModule?e:{default:e}}var oT=(0,rT.IconWrapper)("loading",!0,function(e){return Su.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},Su.default.createElement("path",{d:"M4 24C4 35.0457 12.9543 44 24 44V44C35.0457 44 44 35.0457 44 24C44 12.9543 35.0457 4 24 4",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),Su.default.createElement("path",{d:"M36 24C36 17.3726 30.6274 12 24 12C17.3726 12 12 17.3726 12 24C12 30.6274 17.3726 36 24 36V36",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});Sp=wu.default=oT;var Cu={};Object.defineProperty(Cu,"__esModule",{value:!0});var Cp=Cu.default=void 0,yr=aT(T),iT=Et;function aT(e){return e&&e.__esModule?e:{default:e}}var sT=(0,iT.IconWrapper)("loading-three",!1,function(e){return yr.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},yr.default.createElement("path",{d:"M24 44C35.0457 44 44 35.0457 44 24C44 12.9543 35.0457 4 24 4C12.9543 4 4 12.9543 4 24C4 35.0457 12.9543 44 24 44Z",fill:e.colors[1],stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M24 12V15",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M32.4852 15.5147L30.3639 17.636",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M36 24H33",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M32.4852 32.4853L30.3639 30.364",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M24 36V33",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M15.5148 32.4853L17.6361 30.364",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M12 24H15",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),yr.default.createElement("path",{d:"M15.5148 15.5147L17.6361 17.636",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});Cp=Cu.default=sT;var Eu={};Object.defineProperty(Eu,"__esModule",{value:!0});var Ep=Eu.default=void 0,xu=lT(T),cT=Et;function lT(e){return e&&e.__esModule?e:{default:e}}var uT=(0,cT.IconWrapper)("return",!0,function(e){return xu.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},xu.default.createElement("path",{d:"M12.9998 8L6 14L12.9998 21",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),xu.default.createElement("path",{d:"M6 14H28.9938C35.8768 14 41.7221 19.6204 41.9904 26.5C42.2739 33.7696 36.2671 40 28.9938 40H11.9984",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});Ep=Eu.default=uT;const fT={Close:vp,Config:bp,DistraughtFace:yp,Return:Ep,Loading:Sp,LoadingThree:Cp,Info:wp};function Mn({name:e,theme:t,size:r,fill:n,...o}){t||(t="outline"),r||(r=24);const i=Nc();n||(n=i?"#fff":"#333");const a=fT[e];return L(a,{theme:t,size:r,fill:n,...o,style:{fontSize:0,...o.style}})}function So(){for(var e=arguments.length,t=new Array(e),r=0;r(t,r)=>{const n=T.useRef(!1);e(()=>()=>{n.current=!1},[]),e(()=>{if(!n.current)n.current=!0;else return t()},r)};function $p(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);otypeof e=="function",pT=e=>typeof e=="string",Pp=e=>typeof e=="number",Ou=!1;function _e(e){Ou&&(Co(e)||console.error(`useMemoizedFn expected parameter is a function, got ${typeof e}`));const t=T.useRef(e);t.current=T.useMemo(()=>e,[e]);const r=T.useRef();return r.current||(r.current=function(...n){return t.current.apply(this,n)}),r.current}const ys=Op(T.useEffect),Tp=(e,{manual:t,ready:r=!0,defaultParams:n=[],refreshDeps:o=[],refreshDepsAction:i})=>{const a=T.useRef(!1);return a.current=!1,ys(()=>{!t&&r&&(a.current=!0,e.run(...n))},[r]),ys(()=>{a.current||t||(a.current=!0,i?i():e.refresh())},[...o]),{onBefore:()=>{if(!r)return{stopNow:!0}}}};Tp.onInit=({ready:e=!0,manual:t})=>({loading:!t&&e});const vT=Tp;function $u(e,t){if(e===t)return!0;for(let r=0;r{Ou&&(Co(e)||console.error(`useUnmount expected parameter is a function, got ${typeof e}`));const t=Ci(e);T.useEffect(()=>()=>{t.current()},[])},ws=new Map,bT=(e,t,r)=>{const n=ws.get(e);n!=null&&n.timer&&clearTimeout(n.timer);let o;t>-1&&(o=setTimeout(()=>{ws.delete(e)},t)),ws.set(e,Object.assign(Object.assign({},r),{timer:o}))},yT=e=>ws.get(e),Ss=new Map,wT=e=>Ss.get(e),ST=(e,t)=>{Ss.set(e,t),t.then(r=>(Ss.delete(e),r)).catch(()=>{Ss.delete(e)})},An={},CT=(e,t)=>{An[e]&&An[e].forEach(r=>r(t))},Pu=(e,t)=>(An[e]||(An[e]=[]),An[e].push(t),function(){const n=An[e].indexOf(t);An[e].splice(n,1)}),ET=(e,{cacheKey:t,cacheTime:r=5*60*1e3,staleTime:n=0,setCache:o,getCache:i})=>{const a=T.useRef(),s=T.useRef(),c=(u,f)=>{o?o(f):bT(u,r,f),CT(u,f.data)},l=(u,f=[])=>i?i(f):yT(u);return kp(()=>{if(!t)return;const u=l(t);u&&Object.hasOwnProperty.call(u,"data")&&(e.state.data=u.data,e.state.params=u.params,(n===-1||new Date().getTime()-u.time<=n)&&(e.state.loading=!1)),a.current=Pu(t,f=>{e.setState({data:f})})},[]),Ei(()=>{var u;(u=a.current)===null||u===void 0||u.call(a)}),t?{onBefore:u=>{const f=l(t,u);return!f||!Object.hasOwnProperty.call(f,"data")?{}:n===-1||new Date().getTime()-f.time<=n?{loading:!1,data:f==null?void 0:f.data,error:void 0,returnNow:!0}:{data:f==null?void 0:f.data,error:void 0}},onRequest:(u,f)=>{let d=wT(t);return d&&d!==s.current?{servicePromise:d}:(d=u(...f),s.current=d,ST(t,d),{servicePromise:d})},onSuccess:(u,f)=>{var d;t&&((d=a.current)===null||d===void 0||d.call(a),c(t,{data:u,params:f,time:new Date().getTime()}),a.current=Pu(t,g=>{e.setState({data:g})}))},onMutate:u=>{var f;t&&((f=a.current)===null||f===void 0||f.call(a),c(t,{data:u,params:e.state.params,time:new Date().getTime()}),a.current=Pu(t,d=>{e.setState({data:d})}))}}:{}},xT=(e,{debounceWait:t,debounceLeading:r,debounceTrailing:n,debounceMaxWait:o})=>{const i=T.useRef(),a=T.useMemo(()=>{const s={};return r!==void 0&&(s.leading=r),n!==void 0&&(s.trailing=n),o!==void 0&&(s.maxWait=o),s},[r,n,o]);return T.useEffect(()=>{if(t){const s=e.runAsync.bind(e);return i.current=Hd(c=>{c()},t,a),e.runAsync=(...c)=>new Promise((l,u)=>{var f;(f=i.current)===null||f===void 0||f.call(i,()=>{s(...c).then(l).catch(u)})}),()=>{var c;(c=i.current)===null||c===void 0||c.cancel(),e.runAsync=s}}},[t,a]),t?{onCancel:()=>{var s;(s=i.current)===null||s===void 0||s.cancel()}}:{}},_T=(e,{loadingDelay:t,ready:r})=>{const n=T.useRef();if(!t)return{};const o=()=>{n.current&&clearTimeout(n.current)};return{onBefore:()=>(o(),r!==!1&&(n.current=setTimeout(()=>{e.setState({loading:!0})},t)),{loading:!1}),onFinally:()=>{o()},onCancel:()=>{o()}}},xi=!!(typeof window<"u"&&window.document&&window.document.createElement);function Tu(){return xi?document.visibilityState!=="hidden":!0}const _i=[];function OT(e){return _i.push(e),function(){const r=_i.indexOf(e);_i.splice(r,1)}}if(xi){const e=()=>{if(Tu())for(let t=0;t<_i.length;t++){const r=_i[t];r()}};window.addEventListener("visibilitychange",e,!1)}const $T=(e,{pollingInterval:t,pollingWhenHidden:r=!0,pollingErrorRetryCount:n=-1})=>{const o=T.useRef(),i=T.useRef(),a=T.useRef(0),s=()=>{var c;o.current&&clearTimeout(o.current),(c=i.current)===null||c===void 0||c.call(i)};return ys(()=>{t||s()},[t]),t?{onBefore:()=>{s()},onError:()=>{a.current+=1},onSuccess:()=>{a.current=0},onFinally:()=>{n===-1||n!==-1&&a.current<=n?o.current=setTimeout(()=>{!r&&!Tu()?i.current=OT(()=>{e.refresh()}):e.refresh()},t):a.current=0},onCancel:()=>{s()}}:{}};function PT(e,t){let r=!1;return(...n)=>{r||(r=!0,e(...n),setTimeout(()=>{r=!1},t))}}function TT(){return xi&&typeof navigator.onLine<"u"?navigator.onLine:!0}const Oi=[];function kT(e){return Oi.push(e),function(){const r=Oi.indexOf(e);r>-1&&Oi.splice(r,1)}}if(xi){const e=()=>{if(!(!Tu()||!TT()))for(let t=0;t{const n=T.useRef(),o=()=>{var i;(i=n.current)===null||i===void 0||i.call(n)};return T.useEffect(()=>{if(t){const i=PT(e.refresh.bind(e),r);n.current=kT(()=>{i()})}return()=>{o()}},[t,r]),Ei(()=>{o()}),{}},AT=(e,{retryInterval:t,retryCount:r})=>{const n=T.useRef(),o=T.useRef(0),i=T.useRef(!1);return r?{onBefore:()=>{i.current||(o.current=0),i.current=!1,n.current&&clearTimeout(n.current)},onSuccess:()=>{o.current=0},onError:()=>{if(o.current+=1,r===-1||o.current<=r){const a=t??Math.min(1e3*Math.pow(2,o.current),3e4);n.current=setTimeout(()=>{i.current=!0,e.refresh()},a)}else o.current=0},onCancel:()=>{o.current=0,n.current&&clearTimeout(n.current)}}:{}},RT=(e,{throttleWait:t,throttleLeading:r,throttleTrailing:n})=>{const o=T.useRef(),i={};return r!==void 0&&(i.leading=r),n!==void 0&&(i.trailing=n),T.useEffect(()=>{if(t){const a=e.runAsync.bind(e);return o.current=tC(s=>{s()},t,i),e.runAsync=(...s)=>new Promise((c,l)=>{var u;(u=o.current)===null||u===void 0||u.call(o,()=>{a(...s).then(c).catch(l)})}),()=>{var s;e.runAsync=a,(s=o.current)===null||s===void 0||s.cancel()}}},[t,r,n]),t?{onCancel:()=>{var a;(a=o.current)===null||a===void 0||a.cancel()}}:{}},Mp=e=>{Ou&&(Co(e)||console.error(`useMount: parameter \`fn\` expected to be a function, but got "${typeof e}".`)),T.useEffect(()=>{e==null||e()},[])},FT=()=>{const[,e]=T.useState({});return T.useCallback(()=>e({}),[])};class NT{constructor(t,r,n,o={}){this.serviceRef=t,this.options=r,this.subscribe=n,this.initState=o,this.count=0,this.state={loading:!1,params:void 0,data:void 0,error:void 0},this.state=Object.assign(Object.assign(Object.assign({},this.state),{loading:!r.manual}),o)}setState(t={}){this.state=Object.assign(Object.assign({},this.state),t),this.subscribe()}runPluginHandler(t,...r){const n=this.pluginImpls.map(o=>{var i;return(i=o[t])===null||i===void 0?void 0:i.call(o,...r)}).filter(Boolean);return Object.assign({},...n)}runAsync(...t){var r,n,o,i,a,s,c,l,u,f;return mT(this,void 0,void 0,function*(){this.count+=1;const d=this.count,g=this.runPluginHandler("onBefore",t),{stopNow:v=!1,returnNow:m=!1}=g,p=$p(g,["stopNow","returnNow"]);if(v)return new Promise(()=>{});if(this.setState(Object.assign({loading:!0,params:t},p)),m)return Promise.resolve(p.data);(n=(r=this.options).onBefore)===null||n===void 0||n.call(r,t);try{let{servicePromise:b}=this.runPluginHandler("onRequest",this.serviceRef.current,t);b||(b=this.serviceRef.current(...t));const w=yield b;return d!==this.count?new Promise(()=>{}):(this.setState({data:w,error:void 0,loading:!1}),(i=(o=this.options).onSuccess)===null||i===void 0||i.call(o,w,t),this.runPluginHandler("onSuccess",w,t),(s=(a=this.options).onFinally)===null||s===void 0||s.call(a,t,w,void 0),d===this.count&&this.runPluginHandler("onFinally",t,w,void 0),w)}catch(b){if(d!==this.count)return new Promise(()=>{});throw this.setState({error:b,loading:!1}),(l=(c=this.options).onError)===null||l===void 0||l.call(c,b,t),this.runPluginHandler("onError",b,t),(f=(u=this.options).onFinally)===null||f===void 0||f.call(u,t,void 0,b),d===this.count&&this.runPluginHandler("onFinally",t,void 0,b),b}})}run(...t){this.runAsync(...t).catch(r=>{this.options.onError||console.error(r)})}cancel(){this.count+=1,this.setState({loading:!1}),this.runPluginHandler("onCancel")}refresh(){this.run(...this.state.params||[])}refreshAsync(){return this.runAsync(...this.state.params||[])}mutate(t){const r=Co(t)?t(this.state.data):t;this.runPluginHandler("onMutate",r),this.setState({data:r})}}function IT(e,t={},r=[]){const{manual:n=!1}=t,o=$p(t,["manual"]),i=Object.assign({manual:n},o),a=Ci(e),s=FT(),c=kp(()=>{const l=r.map(u=>{var f;return(f=u==null?void 0:u.onInit)===null||f===void 0?void 0:f.call(u,i)}).filter(Boolean);return new NT(a,i,s,Object.assign({},...l))},[]);return c.options=i,c.pluginImpls=r.map(l=>l(c,i)),Mp(()=>{if(!n){const l=c.state.params||t.defaultParams||[];c.run(...l)}}),Ei(()=>{c.cancel()}),{loading:c.state.loading,data:c.state.data,error:c.state.error,params:c.state.params||[],cancel:_e(c.cancel.bind(c)),refresh:_e(c.refresh.bind(c)),refreshAsync:_e(c.refreshAsync.bind(c)),run:_e(c.run.bind(c)),runAsync:_e(c.runAsync.bind(c)),mutate:_e(c.mutate.bind(c))}}function Ap(e,t,r){return IT(e,t,[...r||[],xT,_T,$T,MT,RT,vT,ET,AT])}function Rp(e=!1,t){const[r,n]=T.useState(e),o=T.useMemo(()=>{const i=t===void 0?!e:t;return{toggle:()=>n(u=>u===e?i:e),set:u=>n(u),setLeft:()=>n(e),setRight:()=>n(i)}},[]);return[r,o]}function LT(e=!1){const[t,{toggle:r,set:n}]=Rp(e),o=T.useMemo(()=>({toggle:r,set:s=>n(!!s),setTrue:()=>n(!0),setFalse:()=>n(!1)}),[]);return[t,o]}function Cs(e,t){if(!xi)return;if(!e)return t;let r;return Co(e)?r=e():"current"in e?r=e.current:r=e,r}const Fp=(e=>(r,n,o)=>{const i=T.useRef(!1),a=T.useRef([]),s=T.useRef([]),c=T.useRef();e(()=>{var l;const f=(Array.isArray(o)?o:[o]).map(d=>Cs(d));if(!i.current){i.current=!0,a.current=f,s.current=n,c.current=r();return}(f.length!==a.current.length||!$u(f,a.current)||!$u(n,s.current))&&((l=c.current)===null||l===void 0||l.call(c),a.current=f,s.current=n,c.current=r())}),Ei(()=>{var l;(l=c.current)===null||l===void 0||l.call(c),i.current=!1})})(T.useEffect);function $i(e,t,r={}){const n=Ci(t);Fp(()=>{const o=Cs(r.target,window);if(!(o!=null&&o.addEventListener))return;const i=a=>n.current(a);return o.addEventListener(e,i,{capture:r.capture,once:r.once,passive:r.passive}),()=>{o.removeEventListener(e,i,{capture:r.capture})}},[e,r.capture,r.once,r.passive],r.target)}function jT(e){const[t,r]=T.useState(e),n=T.useRef(t);n.current=t;const o=T.useCallback(()=>n.current,[]);return[t,r,o]}const ku=(e,t)=>{const{onEnter:r,onLeave:n,onChange:o}=t||{},[i,{setTrue:a,setFalse:s}]=LT(!1);return $i("mouseenter",()=>{r==null||r(),a(),o==null||o(!0)},{target:e}),$i("mouseleave",()=>{n==null||n(),s(),o==null||o(!1)},{target:e}),i},DT=(e,t=[])=>TS(e,t),zT=(e,t,r)=>{const n=T.useRef(),o=T.useRef(0);DT(t,n.current)||(n.current=t,o.current+=1),Fp(e,[o.current],r)},HT=/(mac|iphone|ipod|ipad)/i.test(typeof navigator<"u"?navigator==null?void 0:navigator.platform:""),Es={0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,pausebreak:19,capslock:20,esc:27,space:32,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,a:65,b:66,c:67,d:68,e:69,f:70,g:71,h:72,i:73,j:74,k:75,l:76,m:77,n:78,o:79,p:80,q:81,r:82,s:83,t:84,u:85,v:86,w:87,x:88,y:89,z:90,leftwindowkey:91,rightwindowkey:92,selectkey:93,numpad0:96,numpad1:97,numpad2:98,numpad3:99,numpad4:100,numpad5:101,numpad6:102,numpad7:103,numpad8:104,numpad9:105,multiply:106,add:107,subtract:109,decimalpoint:110,divide:111,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,numlock:144,scrolllock:145,semicolon:186,equalsign:187,comma:188,dash:189,period:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222};HT?Es.meta=[91,93]:Es.meta=[91,92];const Mu={ctrl:e=>e.ctrlKey,shift:e=>e.shiftKey,alt:e=>e.altKey,meta:e=>e.type==="keyup"?Es.meta.includes(e.keyCode):e.metaKey};function BT(e){const t=Object.keys(Mu).reduce((r,n)=>Mu[n](e)?r+1:r,0);return[16,17,18,91,92].includes(e.keyCode)?t:t+1}function Np(e,t,r){if(!e.key)return!1;if(Pp(t))return e.keyCode===t;const n=t.split(".");let o=0;for(const i of n){const a=Mu[i],s=Es[i.toLowerCase()];(a&&a(e)||s&&s===e.keyCode)&&o++}return r?o===n.length&&BT(e)===n.length:o===n.length}function WT(e,t){return Co(e)?e:pT(e)||Pp(e)?r=>Np(r,e,t):Array.isArray(e)?r=>e.some(n=>Np(r,n,t)):()=>!!e}const VT=["keydown"];function it(e,t,r){const{events:n=VT,target:o,exactMatch:i=!1,useCapture:a=!1}=r||{},s=Ci(t),c=Ci(e);zT(()=>{var l;const u=Cs(o,window);if(!u)return;const f=d=>{var g;if(WT(c.current,i)(d))return(g=s.current)===null||g===void 0?void 0:g.call(s,d)};for(const d of n)(l=u==null?void 0:u.addEventListener)===null||l===void 0||l.call(u,d,f,a);return()=>{var d;for(const g of n)(d=u==null?void 0:u.removeEventListener)===null||d===void 0||d.call(u,g,f,a)}},[n],o)}function Ip(e){const t=T.useRef(0),[r,n]=T.useState(e),o=T.useCallback(i=>{cancelAnimationFrame(t.current),t.current=requestAnimationFrame(()=>{n(i)})},[]);return Ei(()=>{cancelAnimationFrame(t.current)}),[r,o]}const UT={screenX:NaN,screenY:NaN,clientX:NaN,clientY:NaN,pageX:NaN,pageY:NaN,elementX:NaN,elementY:NaN,elementH:NaN,elementW:NaN,elementPosX:NaN,elementPosY:NaN},GT=e=>{const[t,r]=Ip(UT);return $i("mousemove",n=>{const{screenX:o,screenY:i,clientX:a,clientY:s,pageX:c,pageY:l}=n,u={screenX:o,screenY:i,clientX:a,clientY:s,pageX:c,pageY:l,elementX:NaN,elementY:NaN,elementH:NaN,elementW:NaN,elementPosX:NaN,elementPosY:NaN},f=Cs(e);if(f){const{left:d,top:g,width:v,height:m}=f.getBoundingClientRect();u.elementPosX=d+window.pageXOffset,u.elementPosY=g+window.pageYOffset,u.elementX=c-u.elementPosX,u.elementY=l-u.elementPosY,u.elementW=v,u.elementH=m}r(u)},{target:()=>document}),t},qT=()=>{const e=T.useRef(!1);return T.useEffect(()=>(e.current=!1,()=>{e.current=!0}),[]),e},KT=Op(T.useLayoutEffect),Zt={modalMask:"_modal-mask_qk630_1",modal:"_modal_qk630_1",modalHeader:"_modal-header_qk630_23",modalBody:"_modal-body_qk630_30",modalTitle:"_modal-title_qk630_35",btnClose:"_btn-close_qk630_42"};let Pi=0;const XT=()=>{Pi++,document.body.style.overflow="hidden"},YT=()=>{Pi--,Pi<0&&(Pi=0),Pi===0&&(document.body.style.overflow="")};function Au({show:e,onHide:t,children:r,clsModalMask:n,clsModal:o,hideWhenMaskOnClick:i=!1,hideWhenEsc:a=!1}){T.useLayoutEffect(()=>{e?XT():YT()},[e]);const s=T.useRef(null),c=Nc(),{bg:l,c:u}=T.useMemo(()=>{const m=window.getComputedStyle(document.body)["background-color"],p=window.getComputedStyle(document.body).color;return{bg:m,c:p}},[c]),f=T.useMemo(()=>c?{"--bg":l,"--c":u,backgroundColor:l,color:u}:{},[l,u,c]),d=T.useId(),g=T.useMemo(()=>{const m=document.createElement("div");return m.setAttribute("data-id","base-modal-"+d),document.body.appendChild(m),m},[]),v=_e(m=>{var p;(p=s.current)!=null&&p.contains(m.target)||i&&t()});return it("esc",m=>{e&&a&&(m.preventDefault(),m.stopImmediatePropagation(),setTimeout(t))}),e?ve.createPortal(L("div",{className:Y(Zt.modalMask,n),onClick:v,children:L("div",{className:Y(Zt.modal,o),style:f,ref:s,children:r})}),g):null}const Ru=e=>L(Mn,{...e,name:"Close",size:18,style:{cursor:"pointer",marginLeft:10,...e.style}}),Lp="_toast-container_mcbuq_1",jp="_single-line_mcbuq_17",NA={toastContainer:Lp,singleLine:jp};function xt(e,t=2e3){const r=document.createElement("div");r.className=Lp,r.innerText=e,!e.includes(` `)&&!e.includes("r.remove(),t)}const ZT="请求失败, 请重试 !!!",QT="操作失败, 请重试 !!!";function Dp(){return xt(ZT)}function zp(){return xt(QT)}function JT(e){const t=ni({data:Array.from(e||[]),has(r){return this.data.some(n=>n[0]===r)},set(r,n){const o=this.data.find(i=>i[0]===r);return o?o[1]=n:this.data.push([r,n]),this},get(r){var n;return(n=this.data.find(o=>o[0]===r))==null?void 0:n[1]},delete(r){const n=this.data.findIndex(o=>o[0]===r);return n===-1?!1:(this.data.splice(n,1),!0)},clear(){this.data.splice(0)},get size(){return this.data.length},toJSON(){return new Map(this.data)},forEach(r){this.data.forEach(n=>{r(n[1],n[0],this)})},keys(){return this.data.map(r=>r[0]).values()},values(){return this.data.map(r=>r[1]).values()},entries(){return new Map(this.data).entries()},get[Symbol.toStringTag](){return"Map"},[Symbol.iterator](){return this.entries()}});return Object.defineProperties(t,{data:{enumerable:!1},size:{enumerable:!1},toJSON:{enumerable:!1}}),Object.seal(t),t}const Hp="27eb53fc9058f8c3";async function ek(){var c,l;const t=(await ze.get("https://passport.bilibili.com/login/app/third",{params:{appkey:Hp,api:"https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png",sign:"04224646d1fea004e79606d3b038c84a"},withCredentials:!0})).data;if(!((c=t==null?void 0:t.data)!=null&&c.has_login))return{errmsg:"你必须登录B站之后才能使用授权",json:t};if(!((l=t==null?void 0:t.data)!=null&&l.confirm_uri))return{errmsg:"无法获得授权网址",json:t};const r=t.data.confirm_uri;let n;const o=new Promise(u=>{window.addEventListener("message",f=>{if(f.origin!="https://www.mcbbs.net"||!f.data)return;const d=f.data.match(/access_key=([0-9a-z]{32})/);if(!d||!d[1])return u({errmsg:"没有获得匹配的密钥"});u(d[1])}),n=setTimeout(()=>{u({errmsg:"获取授权超时"})},10*1e3)}),i=document.createElement("iframe");i.src=r,i.style.display="none",document.body.appendChild(i);function a(){i.remove(),n&&(clearTimeout(n),n=void 0)}const s=await o;return a(),s}async function tk(){const e=await ek();if(typeof e=="object"&&"errmsg"in e){xt(e.errmsg);return}const t=e;return He.accessKey=t,xt("获取成功"),t}function rk(){He.accessKey="",xt("已删除 access_key")}const Bp="https://api.bilibili.com",Wp="https://app.bilibili.com",xs=ze.create({baseURL:Bp});xs.interceptors.request.use(function(e){var t;return(t=e.params)!=null&&t._||(e.params={...e.params,_:Date.now()}),e},function(e){return Promise.reject(e)});const _s=ze.create({adapter:Wn});_s.interceptors.request.use(function(e){return e.params={appkey:Hp,access_key:He.accessKey||"",...e.params},e},function(e){return Promise.reject(e)}),_s.interceptors.response.use(e=>{if(e.config.responseType==="json"&&e.data&&e.data instanceof ArrayBuffer){const t=new TextDecoder,r=new Uint8Array(e.data),n=t.decode(r);e.data=n;try{e.data=JSON.parse(n)}catch{}}return e});function nk(){var t;const e=(t=document.cookie.match(/bili_jct=([0-9a-fA-F]{32})/))==null?void 0:t[1];if(!e)throw xt("找不到 csrf token, 请检查是否登录"),new Error("找不到 csrf token, 请检查是否登录");return e}const Ti=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,Vp=new Set,ok=(e,t,r,n)=>{typeof process=="object"&&process&&typeof process.emitWarning=="function"?process.emitWarning(e,t,r,n):console.error(`[${r}] ${t}: ${e}`)},ik=e=>!Vp.has(e),fn=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),Up=e=>fn(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?Os:null:null;class Os extends Array{constructor(t){super(t),this.fill(0)}}const To=class{constructor(t,r){Ze(this,"heap");Ze(this,"length");if(!O(To,Po))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new r(t),this.length=0}static create(t){const r=Up(t);if(!r)return[];ee(To,Po,!0);const n=new To(t,r);return ee(To,Po,!1),n}push(t){this.heap[this.length++]=t}pop(){return this.heap[--this.length]}};let $s=To;Po=new WeakMap,ue($s,Po,!1);const nf=class{constructor(t){ue(this,Li);ue(this,Is);ue(this,Or);ue(this,$r);ue(this,zi);ue(this,Ao);ue(this,Ro);ue(this,Re);ue(this,Hi);ue(this,Ln);ue(this,Qt,void 0);ue(this,It,void 0);ue(this,xr,void 0);ue(this,Jt,void 0);ue(this,ko,void 0);Ze(this,"ttl");Ze(this,"ttlResolution");Ze(this,"ttlAutopurge");Ze(this,"updateAgeOnGet");Ze(this,"updateAgeOnHas");Ze(this,"allowStale");Ze(this,"noDisposeOnSet");Ze(this,"noUpdateTTL");Ze(this,"maxEntrySize");Ze(this,"sizeCalculation");Ze(this,"noDeleteOnFetchRejection");Ze(this,"noDeleteOnStaleGet");Ze(this,"allowStaleOnFetchAbort");Ze(this,"allowStaleOnFetchRejection");Ze(this,"ignoreFetchAbort");ue(this,tt,void 0);ue(this,er,void 0);ue(this,rt,void 0);ue(this,je,void 0);ue(this,ie,void 0);ue(this,yt,void 0);ue(this,Lt,void 0);ue(this,gt,void 0);ue(this,at,void 0);ue(this,tr,void 0);ue(this,ut,void 0);ue(this,Vr,void 0);ue(this,Ur,void 0);ue(this,rr,void 0);ue(this,_r,void 0);ue(this,hn,void 0);ue(this,_t,void 0);ue(this,Nn,()=>{});ue(this,Gr,()=>{});ue(this,ji,()=>{});ue(this,jt,()=>!1);ue(this,In,t=>{});ue(this,Mo,(t,r,n)=>{});ue(this,Di,(t,r,n,o)=>{if(n||o)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});const{max:r=0,ttl:n,ttlResolution:o=1,ttlAutopurge:i,updateAgeOnGet:a,updateAgeOnHas:s,allowStale:c,dispose:l,disposeAfter:u,noDisposeOnSet:f,noUpdateTTL:d,maxSize:g=0,maxEntrySize:v=0,sizeCalculation:m,fetchMethod:p,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:w,allowStaleOnFetchRejection:E,allowStaleOnFetchAbort:$,ignoreFetchAbort:S}=t;if(r!==0&&!fn(r))throw new TypeError("max option must be a nonnegative integer");const y=r?Up(r):Array;if(!y)throw new Error("invalid max value: "+r);if(ee(this,Qt,r),ee(this,It,g),this.maxEntrySize=v||O(this,It),this.sizeCalculation=m,this.sizeCalculation){if(!O(this,It)&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(p!==void 0&&typeof p!="function")throw new TypeError("fetchMethod must be a function if specified");if(ee(this,ko,p),ee(this,hn,!!p),ee(this,rt,new Map),ee(this,je,new Array(r).fill(void 0)),ee(this,ie,new Array(r).fill(void 0)),ee(this,yt,new y(r)),ee(this,Lt,new y(r)),ee(this,gt,0),ee(this,at,0),ee(this,tr,$s.create(r)),ee(this,tt,0),ee(this,er,0),typeof l=="function"&&ee(this,xr,l),typeof u=="function"?(ee(this,Jt,u),ee(this,ut,[])):(ee(this,Jt,void 0),ee(this,ut,void 0)),ee(this,_r,!!O(this,xr)),ee(this,_t,!!O(this,Jt)),this.noDisposeOnSet=!!f,this.noUpdateTTL=!!d,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!E,this.allowStaleOnFetchAbort=!!$,this.ignoreFetchAbort=!!S,this.maxEntrySize!==0){if(O(this,It)!==0&&!fn(O(this,It)))throw new TypeError("maxSize must be a positive integer if specified");if(!fn(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");Z(this,Is,Dv).call(this)}if(this.allowStale=!!c,this.noDeleteOnStaleGet=!!w,this.updateAgeOnGet=!!a,this.updateAgeOnHas=!!s,this.ttlResolution=fn(o)||o===0?o:1,this.ttlAutopurge=!!i,this.ttl=n||0,this.ttl){if(!fn(this.ttl))throw new TypeError("ttl must be a positive integer if specified");Z(this,Li,hf).call(this)}if(O(this,Qt)===0&&this.ttl===0&&O(this,It)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!O(this,Qt)&&!O(this,It)){const _="LRU_CACHE_UNBOUNDED";ik(_)&&(Vp.add(_),ok("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",_,nf))}}static unsafeExposeInternals(t){return{starts:O(t,Ur),ttls:O(t,rr),sizes:O(t,Vr),keyMap:O(t,rt),keyList:O(t,je),valList:O(t,ie),next:O(t,yt),prev:O(t,Lt),get head(){return O(t,gt)},get tail(){return O(t,at)},free:O(t,tr),isBackgroundFetch:r=>{var n;return Z(n=t,Re,Ve).call(n,r)},backgroundFetch:(r,n,o,i)=>{var a;return Z(a=t,Ro,Gs).call(a,r,n,o,i)},moveToTail:r=>{var n;return Z(n=t,Ln,Gi).call(n,r)},indexes:r=>{var n;return Z(n=t,Or,vn).call(n,r)},rindexes:r=>{var n;return Z(n=t,$r,bn).call(n,r)},isStale:r=>{var n;return O(n=t,jt).call(n,r)}}}get max(){return O(this,Qt)}get maxSize(){return O(this,It)}get calculatedSize(){return O(this,er)}get size(){return O(this,tt)}get fetchMethod(){return O(this,ko)}get dispose(){return O(this,xr)}get disposeAfter(){return O(this,Jt)}getRemainingTTL(t){return O(this,rt).has(t)?1/0:0}*entries(){for(const t of Z(this,Or,vn).call(this))O(this,ie)[t]!==void 0&&O(this,je)[t]!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield[O(this,je)[t],O(this,ie)[t]])}*rentries(){for(const t of Z(this,$r,bn).call(this))O(this,ie)[t]!==void 0&&O(this,je)[t]!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield[O(this,je)[t],O(this,ie)[t]])}*keys(){for(const t of Z(this,Or,vn).call(this)){const r=O(this,je)[t];r!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield r)}}*rkeys(){for(const t of Z(this,$r,bn).call(this)){const r=O(this,je)[t];r!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield r)}}*values(){for(const t of Z(this,Or,vn).call(this))O(this,ie)[t]!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield O(this,ie)[t])}*rvalues(){for(const t of Z(this,$r,bn).call(this))O(this,ie)[t]!==void 0&&!Z(this,Re,Ve).call(this,O(this,ie)[t])&&(yield O(this,ie)[t])}[Symbol.iterator](){return this.entries()}find(t,r={}){for(const n of Z(this,Or,vn).call(this)){const o=O(this,ie)[n],i=Z(this,Re,Ve).call(this,o)?o.__staleWhileFetching:o;if(i!==void 0&&t(i,O(this,je)[n],this))return this.get(O(this,je)[n],r)}}forEach(t,r=this){for(const n of Z(this,Or,vn).call(this)){const o=O(this,ie)[n],i=Z(this,Re,Ve).call(this,o)?o.__staleWhileFetching:o;i!==void 0&&t.call(r,i,O(this,je)[n],this)}}rforEach(t,r=this){for(const n of Z(this,$r,bn).call(this)){const o=O(this,ie)[n],i=Z(this,Re,Ve).call(this,o)?o.__staleWhileFetching:o;i!==void 0&&t.call(r,i,O(this,je)[n],this)}}purgeStale(){let t=!1;for(const r of Z(this,$r,bn).call(this,{allowStale:!0}))O(this,jt).call(this,r)&&(this.delete(O(this,je)[r]),t=!0);return t}dump(){const t=[];for(const r of Z(this,Or,vn).call(this,{allowStale:!0})){const n=O(this,je)[r],o=O(this,ie)[r],i=Z(this,Re,Ve).call(this,o)?o.__staleWhileFetching:o;if(i===void 0||n===void 0)continue;const a={value:i};if(O(this,rr)&&O(this,Ur)){a.ttl=O(this,rr)[r];const s=Ti.now()-O(this,Ur)[r];a.start=Math.floor(Date.now()-s)}O(this,Vr)&&(a.size=O(this,Vr)[r]),t.unshift([n,a])}return t}load(t){this.clear();for(const[r,n]of t){if(n.start){const o=Date.now()-n.start;n.start=Ti.now()-o}this.set(r,n.value,n)}}set(t,r,n={}){var d,g,v;const{ttl:o=this.ttl,start:i,noDisposeOnSet:a=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:c}=n;let{noUpdateTTL:l=this.noUpdateTTL}=n;const u=O(this,Di).call(this,t,r,n.size||0,s);if(this.maxEntrySize&&u>this.maxEntrySize)return c&&(c.set="miss",c.maxEntrySizeExceeded=!0),this.delete(t),this;let f=O(this,tt)===0?void 0:O(this,rt).get(t);if(f===void 0)f=O(this,tt)===0?O(this,at):O(this,tr).length!==0?O(this,tr).pop():O(this,tt)===O(this,Qt)?Z(this,Ao,Us).call(this,!1):O(this,tt),O(this,je)[f]=t,O(this,ie)[f]=r,O(this,rt).set(t,f),O(this,yt)[O(this,at)]=f,O(this,Lt)[f]=O(this,at),ee(this,at,f),Vs(this,tt)._++,O(this,Mo).call(this,f,u,c),c&&(c.set="add"),l=!1;else{Z(this,Ln,Gi).call(this,f);const m=O(this,ie)[f];if(r!==m){if(O(this,hn)&&Z(this,Re,Ve).call(this,m)?m.__abortController.abort(new Error("replaced")):a||(O(this,_r)&&((d=O(this,xr))==null||d.call(this,m,t,"set")),O(this,_t)&&((g=O(this,ut))==null||g.push([m,t,"set"]))),O(this,In).call(this,f),O(this,Mo).call(this,f,u,c),O(this,ie)[f]=r,c){c.set="replace";const p=m&&Z(this,Re,Ve).call(this,m)?m.__staleWhileFetching:m;p!==void 0&&(c.oldValue=p)}}else c&&(c.set="update")}if(o!==0&&!O(this,rr)&&Z(this,Li,hf).call(this),O(this,rr)&&(l||O(this,ji).call(this,f,o,i),c&&O(this,Gr).call(this,c,f)),!a&&O(this,_t)&&O(this,ut)){const m=O(this,ut);let p;for(;p=m==null?void 0:m.shift();)(v=O(this,Jt))==null||v.call(this,...p)}return this}pop(){var t;try{for(;O(this,tt);){const r=O(this,ie)[O(this,gt)];if(Z(this,Ao,Us).call(this,!0),Z(this,Re,Ve).call(this,r)){if(r.__staleWhileFetching)return r.__staleWhileFetching}else if(r!==void 0)return r}}finally{if(O(this,_t)&&O(this,ut)){const r=O(this,ut);let n;for(;n=r==null?void 0:r.shift();)(t=O(this,Jt))==null||t.call(this,...n)}}}has(t,r={}){const{updateAgeOnHas:n=this.updateAgeOnHas,status:o}=r,i=O(this,rt).get(t);if(i!==void 0){const a=O(this,ie)[i];if(Z(this,Re,Ve).call(this,a)&&a.__staleWhileFetching===void 0)return!1;if(O(this,jt).call(this,i))o&&(o.has="stale",O(this,Gr).call(this,o,i));else return n&&O(this,Nn).call(this,i),o&&(o.has="hit",O(this,Gr).call(this,o,i)),!0}else o&&(o.has="miss");return!1}peek(t,r={}){const{allowStale:n=this.allowStale}=r,o=O(this,rt).get(t);if(o!==void 0&&(n||!O(this,jt).call(this,o))){const i=O(this,ie)[o];return Z(this,Re,Ve).call(this,i)?i.__staleWhileFetching:i}}async fetch(t,r={}){const{allowStale:n=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:i=this.noDeleteOnStaleGet,ttl:a=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:c=0,sizeCalculation:l=this.sizeCalculation,noUpdateTTL:u=this.noUpdateTTL,noDeleteOnFetchRejection:f=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:d=this.allowStaleOnFetchRejection,ignoreFetchAbort:g=this.ignoreFetchAbort,allowStaleOnFetchAbort:v=this.allowStaleOnFetchAbort,context:m,forceRefresh:p=!1,status:b,signal:w}=r;if(!O(this,hn))return b&&(b.fetch="get"),this.get(t,{allowStale:n,updateAgeOnGet:o,noDeleteOnStaleGet:i,status:b});const E={allowStale:n,updateAgeOnGet:o,noDeleteOnStaleGet:i,ttl:a,noDisposeOnSet:s,size:c,sizeCalculation:l,noUpdateTTL:u,noDeleteOnFetchRejection:f,allowStaleOnFetchRejection:d,allowStaleOnFetchAbort:v,ignoreFetchAbort:g,status:b,signal:w};let $=O(this,rt).get(t);if($===void 0){b&&(b.fetch="miss");const S=Z(this,Ro,Gs).call(this,t,$,E,m);return S.__returned=S}else{const S=O(this,ie)[$];if(Z(this,Re,Ve).call(this,S)){const k=n&&S.__staleWhileFetching!==void 0;return b&&(b.fetch="inflight",k&&(b.returnedStale=!0)),k?S.__staleWhileFetching:S.__returned=S}const y=O(this,jt).call(this,$);if(!p&&!y)return b&&(b.fetch="hit"),Z(this,Ln,Gi).call(this,$),o&&O(this,Nn).call(this,$),b&&O(this,Gr).call(this,b,$),S;const _=Z(this,Ro,Gs).call(this,t,$,E,m),A=_.__staleWhileFetching!==void 0&&n;return b&&(b.fetch=y?"stale":"refresh",A&&y&&(b.returnedStale=!0)),A?_.__staleWhileFetching:_.__returned=_}}get(t,r={}){const{allowStale:n=this.allowStale,updateAgeOnGet:o=this.updateAgeOnGet,noDeleteOnStaleGet:i=this.noDeleteOnStaleGet,status:a}=r,s=O(this,rt).get(t);if(s!==void 0){const c=O(this,ie)[s],l=Z(this,Re,Ve).call(this,c);return a&&O(this,Gr).call(this,a,s),O(this,jt).call(this,s)?(a&&(a.get="stale"),l?(a&&n&&c.__staleWhileFetching!==void 0&&(a.returnedStale=!0),n?c.__staleWhileFetching:void 0):(i||this.delete(t),a&&n&&(a.returnedStale=!0),n?c:void 0)):(a&&(a.get="hit"),l?c.__staleWhileFetching:(Z(this,Ln,Gi).call(this,s),o&&O(this,Nn).call(this,s),c))}else a&&(a.get="miss")}delete(t){var n,o,i,a;let r=!1;if(O(this,tt)!==0){const s=O(this,rt).get(t);if(s!==void 0)if(r=!0,O(this,tt)===1)this.clear();else{O(this,In).call(this,s);const c=O(this,ie)[s];Z(this,Re,Ve).call(this,c)?c.__abortController.abort(new Error("deleted")):(O(this,_r)||O(this,_t))&&(O(this,_r)&&((n=O(this,xr))==null||n.call(this,c,t,"delete")),O(this,_t)&&((o=O(this,ut))==null||o.push([c,t,"delete"]))),O(this,rt).delete(t),O(this,je)[s]=void 0,O(this,ie)[s]=void 0,s===O(this,at)?ee(this,at,O(this,Lt)[s]):s===O(this,gt)?ee(this,gt,O(this,yt)[s]):(O(this,yt)[O(this,Lt)[s]]=O(this,yt)[s],O(this,Lt)[O(this,yt)[s]]=O(this,Lt)[s]),Vs(this,tt)._--,O(this,tr).push(s)}}if(O(this,_t)&&((i=O(this,ut))!=null&&i.length)){const s=O(this,ut);let c;for(;c=s==null?void 0:s.shift();)(a=O(this,Jt))==null||a.call(this,...c)}return r}clear(){var t,r,n;for(const o of Z(this,$r,bn).call(this,{allowStale:!0})){const i=O(this,ie)[o];if(Z(this,Re,Ve).call(this,i))i.__abortController.abort(new Error("deleted"));else{const a=O(this,je)[o];O(this,_r)&&((t=O(this,xr))==null||t.call(this,i,a,"delete")),O(this,_t)&&((r=O(this,ut))==null||r.push([i,a,"delete"]))}}if(O(this,rt).clear(),O(this,ie).fill(void 0),O(this,je).fill(void 0),O(this,rr)&&O(this,Ur)&&(O(this,rr).fill(0),O(this,Ur).fill(0)),O(this,Vr)&&O(this,Vr).fill(0),ee(this,gt,0),ee(this,at,0),O(this,tr).length=0,ee(this,er,0),ee(this,tt,0),O(this,_t)&&O(this,ut)){const o=O(this,ut);let i;for(;i=o==null?void 0:o.shift();)(n=O(this,Jt))==null||n.call(this,...i)}}};let Fu=nf;Qt=new WeakMap,It=new WeakMap,xr=new WeakMap,Jt=new WeakMap,ko=new WeakMap,tt=new WeakMap,er=new WeakMap,rt=new WeakMap,je=new WeakMap,ie=new WeakMap,yt=new WeakMap,Lt=new WeakMap,gt=new WeakMap,at=new WeakMap,tr=new WeakMap,ut=new WeakMap,Vr=new WeakMap,Ur=new WeakMap,rr=new WeakMap,_r=new WeakMap,hn=new WeakMap,_t=new WeakMap,Li=new WeakSet,hf=function(){const t=new Os(O(this,Qt)),r=new Os(O(this,Qt));ee(this,rr,t),ee(this,Ur,r),ee(this,ji,(i,a,s=Ti.now())=>{if(r[i]=a!==0?s:0,t[i]=a,a!==0&&this.ttlAutopurge){const c=setTimeout(()=>{O(this,jt).call(this,i)&&this.delete(O(this,je)[i])},a+1);c.unref&&c.unref()}}),ee(this,Nn,i=>{r[i]=t[i]!==0?Ti.now():0}),ee(this,Gr,(i,a)=>{if(t[a]){const s=t[a],c=r[a];i.ttl=s,i.start=c,i.now=n||o(),i.remainingTTL=i.now+s-c}});let n=0;const o=()=>{const i=Ti.now();if(this.ttlResolution>0){n=i;const a=setTimeout(()=>n=0,this.ttlResolution);a.unref&&a.unref()}return i};this.getRemainingTTL=i=>{const a=O(this,rt).get(i);return a===void 0?0:t[a]===0||r[a]===0?1/0:r[a]+t[a]-(n||o())},ee(this,jt,i=>t[i]!==0&&r[i]!==0&&(n||o())-r[i]>t[i])},Nn=new WeakMap,Gr=new WeakMap,ji=new WeakMap,jt=new WeakMap,Is=new WeakSet,Dv=function(){const t=new Os(O(this,Qt));ee(this,er,0),ee(this,Vr,t),ee(this,In,r=>{ee(this,er,O(this,er)-t[r]),t[r]=0}),ee(this,Di,(r,n,o,i)=>{if(Z(this,Re,Ve).call(this,n))return 0;if(!fn(o))if(i){if(typeof i!="function")throw new TypeError("sizeCalculation must be a function");if(o=i(n,r),!fn(o))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");return o}),ee(this,Mo,(r,n,o)=>{if(t[r]=n,O(this,It)){const i=O(this,It)-t[r];for(;O(this,er)>i;)Z(this,Ao,Us).call(this,!0)}ee(this,er,O(this,er)+t[r]),o&&(o.entrySize=n,o.totalCalculatedSize=O(this,er))})},In=new WeakMap,Mo=new WeakMap,Di=new WeakMap,Or=new WeakSet,vn=function*({allowStale:t=this.allowStale}={}){if(O(this,tt))for(let r=O(this,at);!(!Z(this,zi,gf).call(this,r)||((t||!O(this,jt).call(this,r))&&(yield r),r===O(this,gt)));)r=O(this,Lt)[r]},$r=new WeakSet,bn=function*({allowStale:t=this.allowStale}={}){if(O(this,tt))for(let r=O(this,gt);!(!Z(this,zi,gf).call(this,r)||((t||!O(this,jt).call(this,r))&&(yield r),r===O(this,at)));)r=O(this,yt)[r]},zi=new WeakSet,gf=function(t){return t!==void 0&&O(this,rt).get(O(this,je)[t])===t},Ao=new WeakSet,Us=function(t){var i,a;const r=O(this,gt),n=O(this,je)[r],o=O(this,ie)[r];return O(this,hn)&&Z(this,Re,Ve).call(this,o)?o.__abortController.abort(new Error("evicted")):(O(this,_r)||O(this,_t))&&(O(this,_r)&&((i=O(this,xr))==null||i.call(this,o,n,"evict")),O(this,_t)&&((a=O(this,ut))==null||a.push([o,n,"evict"]))),O(this,In).call(this,r),t&&(O(this,je)[r]=void 0,O(this,ie)[r]=void 0,O(this,tr).push(r)),O(this,tt)===1?(ee(this,gt,ee(this,at,0)),O(this,tr).length=0):ee(this,gt,O(this,yt)[r]),O(this,rt).delete(n),Vs(this,tt)._--,r},Ro=new WeakSet,Gs=function(t,r,n,o){const i=r===void 0?void 0:O(this,ie)[r];if(Z(this,Re,Ve).call(this,i))return i;const a=new AbortController,{signal:s}=n;s==null||s.addEventListener("abort",()=>a.abort(s.reason),{signal:a.signal});const c={signal:a.signal,options:n,context:o},l=(m,p=!1)=>{const{aborted:b}=a.signal,w=n.ignoreFetchAbort&&m!==void 0;if(n.status&&(b&&!p?(n.status.fetchAborted=!0,n.status.fetchError=a.signal.reason,w&&(n.status.fetchAbortIgnored=!0)):n.status.fetchResolved=!0),b&&!w&&!p)return f(a.signal.reason);const E=g;return O(this,ie)[r]===g&&(m===void 0?E.__staleWhileFetching?O(this,ie)[r]=E.__staleWhileFetching:this.delete(t):(n.status&&(n.status.fetchUpdated=!0),this.set(t,m,c.options))),m},u=m=>(n.status&&(n.status.fetchRejected=!0,n.status.fetchError=m),f(m)),f=m=>{const{aborted:p}=a.signal,b=p&&n.allowStaleOnFetchAbort,w=b||n.allowStaleOnFetchRejection,E=w||n.noDeleteOnFetchRejection,$=g;if(O(this,ie)[r]===g&&(!E||$.__staleWhileFetching===void 0?this.delete(t):b||(O(this,ie)[r]=$.__staleWhileFetching)),w)return n.status&&$.__staleWhileFetching!==void 0&&(n.status.returnedStale=!0),$.__staleWhileFetching;if($.__returned===$)throw m},d=(m,p)=>{var w;const b=(w=O(this,ko))==null?void 0:w.call(this,t,i,c);b&&b instanceof Promise&&b.then(E=>m(E),p),a.signal.addEventListener("abort",()=>{(!n.ignoreFetchAbort||n.allowStaleOnFetchAbort)&&(m(),n.allowStaleOnFetchAbort&&(m=E=>l(E,!0)))})};n.status&&(n.status.fetchDispatched=!0);const g=new Promise(d).then(l,u),v=Object.assign(g,{__abortController:a,__staleWhileFetching:i,__returned:void 0});return r===void 0?(this.set(t,v,{...c.options,status:void 0}),r=O(this,rt).get(t)):O(this,ie)[r]=v,v},Re=new WeakSet,Ve=function(t){if(!O(this,hn))return!1;const r=t;return!!r&&r instanceof Promise&&r.hasOwnProperty("__staleWhileFetching")&&r.__abortController instanceof AbortController},Hi=new WeakSet,mf=function(t,r){O(this,Lt)[r]=t,O(this,yt)[t]=r},Ln=new WeakSet,Gi=function(t){t!==O(this,at)&&(t===O(this,gt)?ee(this,gt,O(this,yt)[t]):Z(this,Hi,mf).call(this,O(this,Lt)[t],O(this,yt)[t]),Z(this,Hi,mf).call(this,O(this,at),t),ee(this,at,t))};const ak=Fu;async function sk(e){return(await xs.get("/pvideo",{params:{aid:e}})).data.data}async function ck(e){return[]}const Nu=new ak({max:200});async function lk(e){if(Nu.has(e))return Nu.get(e);const[t,r]=await Promise.all([sk(e),ck()]);return Nu.set(e,{pvideoData:t,dmData:r}),{pvideoData:t,dmData:r}}function Gp(e){return async function(r){const n=new FormData;n.append("aid",r),n.append("csrf",nk());const i=(await xs.post("/x/v2/history/toview/"+e,n,{withCredentials:!0})).data,a=(i==null?void 0:i.code)===0&&(i==null?void 0:i.message)==="0";return a||xt((i==null?void 0:i.message)||"出错了"),a}}const uk=Gp("add"),fk=Gp("del"),qp=e=>{const t={dislike:"/x/feed/dislike",cancel:"/x/feed/dislike/cancel"}[e];return async function(r,n){const i=(await _s.get(Wp+t,{params:{goto:r.goto,id:r.param,reason_id:n,build:"1",mobi_app:"android",idx:(Date.now()/1e3).toFixed(0)}})).data;return(i==null?void 0:i.code)===0&&(i==null?void 0:i.message)==="0"}},dk=qp("dislike"),hk=qp("cancel"),Ut={modal:"_modal_1rloz_1",titleDesc:"_title-desc_1rloz_4",reasonList:"_reason-list_1rloz_8",reason:"_reason_1rloz_8",active:"_active_1rloz_29",reasonNo:"_reason-no_1rloz_33",tipsContainer:"_tips-container_1rloz_47",tips:"_tips_1rloz_47"},Ps=JT();function gk(){return Yn(Ps)}function mk(e){const t=gk();if(e)return t.get(e)}function pk({show:e,onHide:t,item:r}){const[n,o]=T.useState(!1),i=_e(async g=>{if(!r)return;let v=!1,m;try{o(!0),v=await dk(r,g.id)}catch(p){m=p}finally{o(!1)}if(m)return console.error(m.stack||m),Dp();v?xt("已标记不想看"):zp(),v&&(Ps.set(r.param,{...g}),t())}),a=T.useMemo(()=>{var g;return((g=r==null?void 0:r.three_point)==null?void 0:g.dislike_reasons)||[]},[r]),s=()=>!!e&&!!r,c=["1","2","3","4","5","6"];it(c,g=>{if(!s()||!c.includes(g.key))return;const v=Number(g.key)-1;u(v);const m=document.querySelectorAll(`.${Ut.reason}`)[v]||null;m==null||m.click()});const[l,u]=T.useState(a.length-1);KT(()=>{u(a.length-1)},[a]);const f=g=>()=>{if(!s())return;const v=l+g;v<0||v>a.length-1||u(v)};it("leftarrow",f(-1)),it("rightarrow",f(1)),it("uparrow",f(-2)),it("downarrow",f(2)),it("enter",g=>{var v;s()&&(l<0||l>a.length-1||(g.preventDefault(),g.stopImmediatePropagation(),(v=document.querySelector(`.${Ut.reason}.${Ut.active}`))==null||v.click()))});const d=T.useMemo(()=>{var g;return((g=a[l])==null?void 0:g.name)||""},[a,l]);return U(Au,{show:e,onHide:t,clsModal:Ut.modal,hideWhenMaskOnClick:!0,hideWhenEsc:!0,children:[U("div",{className:Zt.modalHeader,children:[U("div",{className:Zt.modalTitle,children:["我不想看",L("span",{className:Ut.titleDesc,children:"(选择后将减少相似内容推荐)"})]}),L("div",{className:"space",style:{flex:1}}),L(Ru,{onClick:t})]}),U("div",{className:Zt.modalBody,children:[L("div",{className:Ut.reasonList,children:a.map((g,v)=>U("button",{className:Y(Ut.reason,{[Ut.active]:v===l}),"data-id":g.id,onClick:()=>{u(v),i(g)},disabled:n,children:[L("span",{className:Ut.reasonNo,children:v+1}),g.name]},g.id))}),U("div",{className:Ut.tipsContainer,children:[U("div",{className:Ut.tips,children:[L(Mn,{name:"Info",size:15,style:{marginRight:5}}),"使用删除键打开弹框, 数字键选择, Esc 关闭"]}),d&&U("div",{className:Ut.tips,children:[L(Mn,{name:"Info",size:15,style:{marginRight:5}}),"已选择「",d,"」, 回车键提交"]})]})]})]})}const Ts={show:!1,onHide:Xp,item:null},Kp=ni({value:Ts.show}),vk=function(){return Yn(Kp).value};function Xp(){setTimeout(()=>{Yp({show:!1,item:null})})}function Yp(e){Object.assign(Ts,e),Kp.value=Ts.show,bk().render(L(pk,{...Ts,onHide:Xp}))}let Iu;function bk(){if(!Iu){const e=document.createElement("div");e.classList.add("show-dislike-container"),document.body.appendChild(e),Iu=vs(e)}return Iu}function yk(e){e!=null&&e.param&&Ps.has(e.param)||Yp({show:!0,item:e})}function wk(e){if(!e)return"00:00";const t=Math.trunc(e/3600);e-=t*3600;const r=Math.trunc(e/60);e-=r*60;const o=[t,r,e];return o[0]===0&&o.shift(),o.map(a=>ZS(a.toString(),2,"0")).join(":")}function Lu(e){if(!e)return"";if(e<=9999)return e.toString();let t=(e/1e4).toFixed(1);return t=t.replace(/\.0$/,""),`${t}万`}const et={biliVideoCard:"_bili-video-card_e62cr_1",imageWrapper:"_image-wrapper_e62cr_4",previewCardWrapper:"_preview-card-wrapper_e62cr_8",previewCardInner:"_preview-card-inner_e62cr_21",watchLater:"_watch-later_e62cr_25",badge:"_badge_e62cr_28",recommendReason:"_recommend-reason_e62cr_36",bangumiDesc:"_bangumi-desc_e62cr_51",btnDislike:"_btn-dislike_e62cr_54",btnDislikeIcon:"_btn-dislike-icon_e62cr_69",btnDislikeTip:"_btn-dislike-tip_e62cr_76",dislikedWrapper:"_disliked-wrapper_e62cr_91",dislikeContentCover:"_dislike-content-cover_e62cr_105",dislikeContentCoverInner:"_dislike-content-cover-inner_e62cr_111",dislikeIcon:"_dislike-icon_e62cr_122",dislikeReason:"_dislike-reason_e62cr_125",dislikeDesc:"_dislike-desc_e62cr_129",dislikeContentAction:"_dislike-content-action_e62cr_133",skeletonActive:"_skeleton-active_e62cr_150",antSkeletonLoading:"_ant-skeleton-loading_e62cr_1"};function Sk(...e){for(const t of e)if(!isNaN(t))return t;return 0}function Ck({className:e,videoDuration:t,pvideo:r,mouseEnterRelativeX:n,previewAnimationProgress:o}){const i=T.useRef(null),a=GT(i),[s,c]=T.useState(()=>({width:0,height:0}));Mp(()=>{var d;const f=(d=i.current)==null?void 0:d.getBoundingClientRect();f&&c({width:f.width,height:f.height})});let l=0;if(o)l=o;else{const f=Sk(a.elementX,n||0);s.width&&f&&!isNaN(f)&&(l=f/s.width,l<0&&(l=0),l>1&&(l=1))}const u={videoDuration:t,pvideo:r,elWidth:s.width,elHeight:s.height,progress:l};return L("div",{ref:i,className:Y(et.previewCardWrapper,e),children:!!(r&&s.width&&s.height&&l)&&L(Ek,{...u})})}function Ek({videoDuration:e,pvideo:t,elWidth:r,elHeight:n,progress:o}){var S;const i=Math.floor((e||0)*o);let a=T.useMemo(()=>{const y=(t==null?void 0:t.index)||[];let _=_k(y,i);return _!==-1?_:i>y[y.length-1]?(_=Math.floor(y.length*o)-1,_<0&&(_=0),_):0},[t,i]);const{img_x_len:s,img_y_len:c,img_x_size:l,img_y_size:u}=t,f=c*s;a=a+1;const d=Math.floor(a/f),g=a-d*f,v=((S=t.image)==null?void 0:S[d])||"",m=Math.floor(g/s)+1,p=g-(m-1)*s,b=r*s,w=n*c,E=(m-1)*n,$=(p-1)*r;return L("div",{className:et.previewCardInner,style:{backgroundColor:"black",backgroundImage:`url(${v})`,backgroundPosition:`-${$}px -${E}px`,backgroundSize:`${b}px ${w}px`},children:L(xk,{progress:o})})}function xk({progress:e}){return L("div",{className:"track",style:{position:"absolute",bottom:0,left:0,backgroundColor:"#eee",width:"100%",height:2},children:L("div",{className:"bar",style:{backgroundColor:"#fa6a9d",height:"100%",width:`${e*100}%`}})})}function _k(e,t){let r=0,n=e.length-1,o=-1;for(;r<=n;){const s=Math.floor((r+n)/2),c=e[s];if(t===c)return s;c{if(!e)return"";const t=qm.unix(e);return t.format("YYYY")===Ok?t.format("M-D"):t.format("YY-M-D")},Pk=e=>(e||"").replace(/^http:\/\//,"https://"),ju=T.memo(T.forwardRef(function({style:t,className:r,item:n,loading:o,active:i,...a},s){o=o??!n;const c=U("div",{className:Y("bili-video-card__skeleton",{hide:!o,[et.skeletonActive]:o}),children:[L("div",{className:"bili-video-card__skeleton--cover"}),L("div",{className:"bili-video-card__skeleton--info",children:U("div",{className:"bili-video-card__skeleton--right",children:[L("p",{className:"bili-video-card__skeleton--text"}),L("p",{className:"bili-video-card__skeleton--text short"}),L("p",{className:"bili-video-card__skeleton--light"})]})})]}),l=mk((n==null?void 0:n.api)==="app"&&n.param),u=T.useRef(null),f=T.useRef(null);return T.useImperativeHandle(s,()=>({async onCancelDislike(){var d;await((d=u.current)==null?void 0:d.onCancelDislike())},async onToggleWatchLater(){var d;await((d=f.current)==null?void 0:d.onToggleWatchLater())},onTriggerDislike(){var d;(d=f.current)==null||d.onTriggerDislike()},onStartPreviewAnimation(){var d;(d=f.current)==null||d.onStartPreviewAnimation()},onHotkeyPreviewAnimation(){var d;(d=f.current)==null||d.onHotkeyPreviewAnimation()}}),[u,f]),U("div",{style:t,className:Y("bili-video-card",et.biliVideoCard,r),"data-report":"partition_recommend.content",...a,children:[c,!o&&n&&(l?L(Tk,{ref:u,item:n,dislikedReason:l}):L(kk,{ref:f,item:n,active:i}))]})})),Tk=T.memo(T.forwardRef(function({dislikedReason:t,item:r},n){const o=_e(async()=>{if(!(t!=null&&t.id))return;let i=!1,a;try{i=await hk(r,t.id)}catch(s){a=s}if(a)return console.error(a.stack||a),Dp();i?xt("已撤销"):zp(),i&&Ps.delete(r.param)});return T.useImperativeHandle(n,()=>({onCancelDislike:o}),[]),U("div",{className:Y(et.dislikedWrapper),children:[L("div",{className:et.dislikeContentCover,children:U("div",{className:et.dislikeContentCoverInner,children:[L(Mn,{name:"DistraughtFace",size:32,className:et.dislikeIcon}),L("div",{className:et.dislikeReason,children:t==null?void 0:t.name}),L("div",{className:et.dislikeDesc,children:(t==null?void 0:t.toast)||"将减少此类内容推荐"})]})}),L("div",{className:et.dislikeContentAction,children:U("button",{onClick:o,children:[L(Mn,{name:"Return",size:"16",style:{marginRight:4,marginTop:-2}}),"撤销"]})})]})})),kk=T.memo(T.forwardRef(function({item:t,active:r=!1},n){var st,Ce,Kr;const o=t.api==="pc",i=t.api==="app",a=String(o?t.id:t.param),s=o?t.bvid:"",c=t.goto,l=o?t.stat.view:void 0,u=o?t.stat.like:void 0,f=t.title,d=o?t.pic:t.cover,g=o?t.pubdate:void 0,v=(o?t.duration:(st=t.player_args)==null?void 0:st.duration)||0,m=o?t.owner.name:t.args.up_name;o&&t.owner.face;const p=o?t.owner.mid:t.args.up_id,b=void 0,w=o?void 0:t.badge,E=o?void 0:((Ce=t.desc_button)==null?void 0:Ce.text)||"",$=o?(Kr=t.rcmd_reason)==null?void 0:Kr.content:t.rcmd_reason,S=T.useMemo(()=>$k(g),[g]),y=T.useMemo(()=>Pk(d),[d]),[_,R]=T.useState(null),[A,k]=T.useState(!1),I=_e(async()=>{if(!_&&!A)try{k(!0);const ke=await lk(a);R(ke)}finally{k(!1)}}),M=T.useRef(null),[C,x]=T.useState(void 0);$i("mouseenter",ke=>{var Ot;const Me=(Ot=M.current)==null?void 0:Ot.getBoundingClientRect();if(!Me)return;const{x:Ne}=Me,fe=ke.pageX-window.pageXOffset-Ne;x(fe)},{target:M});const P=ku(M),{onStartPreviewAnimation:N,onHotkeyPreviewAnimation:F,previewAnimationProgress:j}=Mk({active:r,tryFetchVideoData:I,videoPreviewWrapperRef:M});ys(()=>{r&&He.autoPreviewWhenKeyboardSelect&&N()},[r]);const D=T.useRef(null),B=ku(D),[V,W]=T.useState(!1),{accessKey:z}=rn(),se=!!z;T.useEffect(()=>{P&&I()},[P]),T.useImperativeHandle(n,()=>({onToggleWatchLater:ge,onTriggerDislike:we,onStartPreviewAnimation:N,onHotkeyPreviewAnimation:F}),[]);const[J,me]=T.useState(!1),ge=_e(async ke=>{if(ke==null||ke.preventDefault(),J)return;me(!0);const Me=V?fk:uk;let Ne=!1;try{Ne=await Me(a)}finally{me(!1)}Ne&&W(fe=>!fe)}),ye=T.useRef(null),te=ku(ye),we=_e(ke=>{ke==null||ke.stopPropagation(),ke==null||ke.preventDefault(),i&&yk(t)}),Pe=t.goto==="bangumi",Te=t.goto==="av",q=o?Te&&s?`/video/${s}`:t.uri:Te?`/video/av${t.param}`:t.uri,le=T.useMemo(()=>wk(v),[v]),Se=T.useMemo(()=>Lu(l),[l]),Fe=T.useMemo(()=>Lu(u),[u]),ne=T.useMemo(()=>Lu(b),[b]),re=o?Fe:ne,pe=_e(ke=>{if(!He.openInIINAWhenRightClick)return;const Me=new URL(q,location.href).href,Ne=`iina://open?url=${encodeURIComponent(Me)}`;window.open(Ne,"_self"),ke.preventDefault()}),Xe=({text:ke,iconSvgName:Me})=>U("span",{className:"bili-video-card__stats--item",children:[L("svg",{className:"bili-video-card__stats--icon",children:L("use",{xlinkHref:Me})}),L("span",{className:"bili-video-card__stats--text",children:ke})]}),Dt={play:"#widget-video-play-count",danmaku:"#widget-video-danmaku",like:"#widget-agree",bangumiFollow:"#widget-agree"},gn={1:"play",2:"like",3:"danmaku",4:"bangumiFollow"},qr=ke=>{const Me=gn[ke]||gn[1];return Dt[Me]};return U("div",{className:"bili-video-card__wrap __scale-wrap",onContextMenu:pe,children:[L("a",{href:q,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:U("div",{className:"bili-video-card__image __scale-player-wrap",ref:M,children:[U("div",{className:Y("bili-video-card__image--wrap",et.imageWrapper),children:[U("picture",{className:"v-img bili-video-card__cover",children:[L("source",{srcSet:`${y}@672w_378h_1c_!web-home-common-cover.avif`,type:"image/avif"}),L("source",{srcSet:`${y}@672w_378h_1c_!web-home-common-cover.webp`,type:"image/webp"}),L("img",{src:`${y}@672w_378h_1c_!web-home-common-cover`,alt:f,loading:"eager"})]}),(P||r&&j)&&L(Ck,{videoDuration:v,pvideo:_==null?void 0:_.pvideoData,mouseEnterRelativeX:C,previewAnimationProgress:j}),U("div",{className:`bili-watch-later ${et.watchLater}`,style:{display:P||r?"flex":"none"},ref:D,onClick:ge,children:[L("svg",{className:"bili-watch-later__icon",children:L("use",{xlinkHref:V?"#widget-watch-save":"#widget-watch-later"})}),L("span",{className:"bili-watch-later__tip",style:{display:B?"block":"none"},children:V?"移除":"稍后再看"})]}),i&&se&&U("div",{ref:ye,className:et.btnDislike,onClick:we,style:{display:P?"flex":"none"},children:[L("svg",{className:et.btnDislikeIcon,children:L("use",{xlinkHref:"#widget-close"})}),L("span",{className:et.btnDislikeTip,style:{display:te?"block":"none"},children:"我不想看"})]})]}),L("div",{className:"bili-video-card__mask",children:U("div",{className:"bili-video-card__stats",children:[L("div",{className:"bili-video-card__stats--left",children:o?U(Xt,{children:[Xe({text:Se,iconSvgName:Dt.play}),Xe({text:c==="av"?Fe:re,iconSvgName:Dt.like})]}):U(Xt,{children:[Xe({iconSvgName:qr(t.cover_left_icon_1),text:t.cover_left_text_1}),Xe({iconSvgName:qr(t.cover_left_icon_2),text:t.cover_left_text_2})]})}),L("span",{className:"bili-video-card__stats__duration",children:Te&&le})]})})]})}),L("div",{className:"bili-video-card__info __scale-disable",children:U("div",{className:"bili-video-card__info--right",children:[L("a",{href:q,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:L("h3",{className:"bili-video-card__info--tit",title:f,children:f})}),U("p",{className:"bili-video-card__info--bottom",children:[Te&&U("a",{className:"bili-video-card__info--owner",href:`//space.bilibili.com/${p}`,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:[$?L("span",{className:et.recommendReason,children:$}):L("svg",{className:"bili-video-card__info--owner__up",children:L("use",{xlinkHref:"#widget-up"})}),L("span",{className:"bili-video-card__info--author",children:m}),S&&U("span",{className:"bili-video-card__info--date",children:["· ",S]})]}),Pe&&U("a",{className:"bili-video-card__info--owner",href:q,target:"_blank",children:[L("span",{className:et.badge,children:w||""}),L("span",{className:et.bangumiDesc,children:E||""})]})]})]})})]})}));function Mk({active:e,tryFetchVideoData:t,videoPreviewWrapperRef:r}){const[n,o]=Ip(void 0),[i,a]=T.useState(!1);$i("mousemove",w=>{a(!0),u()},{target:r});const s=qT(),c=T.useRef(void 0),l=_e(()=>!!(i||!e||s.current)),u=_e(()=>{c.current&&cancelAnimationFrame(c.current),c.current=void 0,o(void 0),d(!1)}),[f,d,g]=jT(!1),v=T.useRef(),m=_e(()=>{var w;if(!c.current){b();return}d(E=>!E),f&&((w=v.current)==null||w.call(v,n||0))}),p=_e(()=>n||0),b=_e(()=>{a(!1),d(!1),t(),u();const w=8e3,E=()=>typeof He.autoPreviewUpdateInterval=="number"?He.autoPreviewUpdateInterval:400;let $=performance.now(),S=0;v.current=()=>{$=performance.now()-p()*w};function y(_){if(l()){u();return}const R=()=>{const A=performance.now()-$,k=Math.min(A%w/w,1);o(k)};g()||(E()?(!S||performance.now()-S>=E())&&(S=performance.now(),R()):R()),c.current=requestAnimationFrame(y)}c.current=requestAnimationFrame(y)});return{onHotkeyPreviewAnimation:m,onStartPreviewAnimation:b,previewAnimationProgress:n}}const Zp="bilibili-app-recommend";var ki={},Ak={get exports(){return ki},set exports(e){ki=e}},ks={},Rk={get exports(){return ks},set exports(e){ks=e}},Eo={},Fk={get exports(){return Eo},set exports(e){Eo=e}},Ke=Fk.exports={},wr,Sr;function Du(){throw new Error("setTimeout has not been defined")}function zu(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?wr=setTimeout:wr=Du}catch{wr=Du}try{typeof clearTimeout=="function"?Sr=clearTimeout:Sr=zu}catch{Sr=zu}})();function Qp(e){if(wr===setTimeout)return setTimeout(e,0);if((wr===Du||!wr)&&setTimeout)return wr=setTimeout,setTimeout(e,0);try{return wr(e,0)}catch{try{return wr.call(null,e,0)}catch{return wr.call(this,e,0)}}}function Nk(e){if(Sr===clearTimeout)return clearTimeout(e);if((Sr===zu||!Sr)&&clearTimeout)return Sr=clearTimeout,clearTimeout(e);try{return Sr(e)}catch{try{return Sr.call(null,e)}catch{return Sr.call(this,e)}}}var Br=[],xo=!1,Rn,Ms=-1;function Ik(){!xo||!Rn||(xo=!1,Rn.length?Br=Rn.concat(Br):Ms=-1,Br.length&&Jp())}function Jp(){if(!xo){var e=Qp(Ik);xo=!0;for(var t=Br.length;t;){for(Rn=Br,Br=[];++Ms1)for(var r=1;r=o)return s;switch(s){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch{return"[Circular]"}default:return s}}),a=n[r];r=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),Fs(t)?r.showHidden=t:t&&Yu(r,t),Er(r.showHidden)&&(r.showHidden=!1),Er(r.depth)&&(r.depth=2),Er(r.colors)&&(r.colors=!1),Er(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=jk),Rs(r,e,r.depth)}Cr.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},Cr.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function jk(e,t){var r=Cr.styles[t];return r?"\x1B["+Cr.colors[r][0]+"m"+e+"\x1B["+Cr.colors[r][1]+"m":e}function Dk(e,t){return e}function zk(e){var t={};return e.forEach(function(r,n){t[r]=!0}),t}function Rs(e,t,r){if(e.customInspect&&t&&Ni(t.inspect)&&t.inspect!==Cr&&!(t.constructor&&t.constructor.prototype===t)){var n=t.inspect(r,e);return Ai(n)||(n=Rs(e,n,r)),n}var o=Hk(e,t);if(o)return o;var i=Object.keys(t),a=zk(i);if(e.showHidden&&(i=Object.getOwnPropertyNames(t)),Fi(t)&&(i.indexOf("message")>=0||i.indexOf("description")>=0))return Vu(t);if(i.length===0){if(Ni(t)){var s=t.name?": "+t.name:"";return e.stylize("[Function"+s+"]","special")}if(Ri(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(Ns(t))return e.stylize(Date.prototype.toString.call(t),"date");if(Fi(t))return Vu(t)}var c="",l=!1,u=["{","}"];if(Gu(t)&&(l=!0,u=["[","]"]),Ni(t)){var f=t.name?": "+t.name:"";c=" [Function"+f+"]"}if(Ri(t)&&(c=" "+RegExp.prototype.toString.call(t)),Ns(t)&&(c=" "+Date.prototype.toUTCString.call(t)),Fi(t)&&(c=" "+Vu(t)),i.length===0&&(!l||t.length==0))return u[0]+c+u[1];if(r<0)return Ri(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special");e.seen.push(t);var d;return l?d=Bk(e,t,r,a,i):d=i.map(function(g){return Uu(e,t,r,a,g,l)}),e.seen.pop(),Wk(d,c,u)}function Hk(e,t){if(Er(t))return e.stylize("undefined","undefined");if(Ai(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(qu(t))return e.stylize(""+t,"number");if(Fs(t))return e.stylize(""+t,"boolean");if(Mi(t))return e.stylize("null","null")}function Vu(e){return"["+Error.prototype.toString.call(e)+"]"}function Bk(e,t,r,n,o){for(var i=[],a=0,s=t.length;a-1&&(i?s=s.split(` `).map(function(l){return" "+l}).join(` `).substr(2):s=` `+s.split(` `).map(function(l){return" "+l}).join(` `))):s=e.stylize("[Circular]","special")),Er(a)){if(i&&o.match(/^\d+$/))return s;a=JSON.stringify(""+o),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function Wk(e,t,r){var n=e.reduce(function(o,i){return i.indexOf(` `)>=0,o+i.replace(/\u001b\[\d\d?m/g,"").length+1},0);return n>60?r[0]+(t===""?"":t+` `)+" "+e.join(`, `)+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}function Gu(e){return Array.isArray(e)}function Fs(e){return typeof e=="boolean"}function Mi(e){return e===null}function nv(e){return e==null}function qu(e){return typeof e=="number"}function Ai(e){return typeof e=="string"}function ov(e){return typeof e=="symbol"}function Er(e){return e===void 0}function Ri(e){return Fn(e)&&Ku(e)==="[object RegExp]"}function Fn(e){return typeof e=="object"&&e!==null}function Ns(e){return Fn(e)&&Ku(e)==="[object Date]"}function Fi(e){return Fn(e)&&(Ku(e)==="[object Error]"||e instanceof Error)}function Ni(e){return typeof e=="function"}function iv(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}function av(e){return Buffer.isBuffer(e)}function Ku(e){return Object.prototype.toString.call(e)}function Xu(e){return e<10?"0"+e.toString(10):e.toString(10)}var Vk=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Uk(){var e=new Date,t=[Xu(e.getHours()),Xu(e.getMinutes()),Xu(e.getSeconds())].join(":");return[e.getDate(),Vk[e.getMonth()],t].join(" ")}function sv(){console.log("%s - %s",Uk(),_o.apply(null,arguments))}function Yu(e,t){if(!t||!Fn(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}function cv(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var Gk=pb(Object.freeze(Object.defineProperty({__proto__:null,_extend:Yu,debuglog:rv,default:{inherits:tv,_extend:Yu,log:sv,isBuffer:av,isPrimitive:iv,isFunction:Ni,isError:Fi,isDate:Ns,isObject:Fn,isRegExp:Ri,isUndefined:Er,isSymbol:ov,isString:Ai,isNumber:qu,isNullOrUndefined:nv,isNull:Mi,isBoolean:Fs,isArray:Gu,inspect:Cr,deprecate:Bu,format:_o,debuglog:rv},deprecate:Bu,format:_o,inherits:tv,inspect:Cr,isArray:Gu,isBoolean:Fs,isBuffer:av,isDate:Ns,isError:Fi,isFunction:Ni,isNull:Mi,isNullOrUndefined:nv,isNumber:qu,isObject:Fn,isPrimitive:iv,isRegExp:Ri,isString:Ai,isSymbol:ov,isUndefined:Er,log:sv},Symbol.toStringTag,{value:"Module"}))).format;function qk(){(typeof AbortController>"u"||typeof AbortSignal>"u")&&console.error("[promise.timeout] need global AbortController & AbortSingal")}function Kk(e,t){return function(){var r=this,n=[].slice.call(arguments);qk();var o=new AbortController;return n.push(o.signal),new Promise(function(i,a){var s=setTimeout(function(){var c=new lv(t);a(c),o.abort()},t);Promise.resolve(e.apply(r,n)).then(function(c){clearTimeout(s),i(c)},function(c){clearTimeout(s),a(c)})})}}let lv=class zv extends Error{constructor(t){super(),this.timeout=t,this.message=Gk("timeout of %sms exceed",t),Error.captureStackTrace(this,zv)}};Rk.exports=Kk,ks.TimeoutError=lv;const uv=ks,Xk=uv.TimeoutError;Ak.exports=function(t,r){const n=t;r=r||{};const o=r.times||5,i=r.timeout;i&&(t=uv(t,i));const a=r.onerror;return async function(){const s=this,c=[].slice.call(arguments),l=new Array(o);for(let u=0;u"} ${this.times} times`,this.timeout&&(this.message+=` with timeout = ${this.timeout}ms`),Error.captureStackTrace(this,this.constructor)}}class Yk extends Error{constructor(t){super(),t instanceof Error?(this.originalError=t,{message:t}=t):(this.originalError=new Error(t),this.originalError.stack=this.stack),this.name="AbortError",this.message=t}}var Zk=ki.RetryError=fv;ki.TimeoutError=Xk;class Zu extends Error{constructor(t){super(),Error.captureStackTrace(this,Zu),this.json=t,this.message=t.message||JSON.stringify(t)}}async function Qk(){var n;const t=(await _s.get(Wp+"/x/v2/feed/index",{responseType:"json",params:{build:"1",mobi_app:"android",idx:(Date.now()/1e3).toFixed(0)+"0"+(Math.random()*10).toFixed(0)}})).data;if(!t.data){if(t.code===-663)throw new Zu(t);return xt(`${Zp}: 未知错误, 请联系开发者 code=${t.code} message=${t.message||""}`,5e3),[]}return((n=t==null?void 0:t.data)==null?void 0:n.items)||[]}const Jk=ki(Qk,{times:5,timeout:2e3,onerror(e,t){console.info("[%s] tryGetRecommend onerror: index=%s",Zp,t,e)}});async function dv(){try{return await Jk()}catch(e){if(e instanceof Zk){console.error(e.errors);const t=[_o("请求出错, 已重试%s次:",e.times),...e.errors.map((r,n)=>_o(" %s) %s",n+1,r.message)),"","请重新获取 access_key 后重试~"].join(` `);xt(t,5e3)}throw e}}async function hv(e){let t=[];const r=async()=>{t=(await Promise.all(new Array(e).fill(0).map(()=>dv()))).flat()},n=async()=>{for(let o=1;o<=e;o++)t=t.concat(await dv())};return await(He.useParallelRequest?r:n)(),t=Qd(t,o=>o.param),t.map(o=>({...o,api:"app",uniqId:o.param+"-"+crypto.randomUUID()}))}async function eM(){return hv(2)}async function gv(e){const t=e.page++;return(await xs.get("/x/web-interface/index/top/rcmd",{baseURL:Bp,withCredentials:!0,params:{fresh_type:3,version:1,ps:14,fresh_idx:t,fresh_idx_1h:t,homepage_ver:1}})).data.data.item}async function mv(e,t){let r=[];const n=async()=>{r=(await Promise.all(new Array(e).fill(0).map(()=>gv(t)))).flat()},o=async()=>{for(let i=1;i<=e;i++)r=r.concat(await gv(t))};return await(He.useParallelRequest?n:o)(),r=Qd(r,i=>i.id),r.forEach(i=>{var a,s;((a=i.rcmd_reason)==null?void 0:a.reason_type)===1&&((s=i.rcmd_reason).content||(s.content="已关注"))}),r.map(i=>({...i,uniqId:i.id+"-"+crypto.randomUUID(),api:"pc"}))}async function tM(e){return mv(1,e)}async function pv(e,t){return He.usePcDesktopApi?mv(e,t):hv(e)}async function rM(e){return He.usePcDesktopApi?tM(e):eM()}var bt={},nM={get exports(){return bt},set exports(e){bt=e}},oM="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",iM=oM,aM=iM;function vv(){}function bv(){}bv.resetWarningCache=vv;var sM=function(){function e(n,o,i,a,s,c){if(c!==aM){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:bv,resetWarningCache:vv};return r.PropTypes=r,r};nM.exports=sM();class Qu extends T.Component{constructor(t){super(t),this.scrollListener=this.scrollListener.bind(this),this.eventListenerOptions=this.eventListenerOptions.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this)}componentDidMount(){this.pageLoaded=this.props.pageStart,this.options=this.eventListenerOptions(),this.attachScrollListener()}componentDidUpdate(){if(this.props.isReverse&&this.loadMore){const t=this.getParentElement(this.scrollComponent);t.scrollTop=t.scrollHeight-this.beforeScrollHeight+this.beforeScrollTop,this.loadMore=!1}this.attachScrollListener()}componentWillUnmount(){this.detachScrollListener(),this.detachMousewheelListener()}isPassiveSupported(){let t=!1;const r={get passive(){t=!0}};try{document.addEventListener("test",null,r),document.removeEventListener("test",null,r)}catch{}return t}eventListenerOptions(){let t=this.props.useCapture;return this.isPassiveSupported()?t={useCapture:this.props.useCapture,passive:!0}:t={passive:!1},t}setDefaultLoader(t){this.defaultLoader=t}detachMousewheelListener(){let t=window;this.props.useWindow===!1&&(t=this.scrollComponent.parentNode),t.removeEventListener("mousewheel",this.mousewheelListener,this.options?this.options:this.props.useCapture)}detachScrollListener(){let t=window;this.props.useWindow===!1&&(t=this.getParentElement(this.scrollComponent)),t.removeEventListener("scroll",this.scrollListener,this.options?this.options:this.props.useCapture),t.removeEventListener("resize",this.scrollListener,this.options?this.options:this.props.useCapture)}getParentElement(t){const r=this.props.getScrollParent&&this.props.getScrollParent();return r??(t&&t.parentNode)}filterProps(t){return t}attachScrollListener(){const t=this.getParentElement(this.scrollComponent);if(!this.props.hasMore||!t)return;let r=window;this.props.useWindow===!1&&(r=t),r.addEventListener("mousewheel",this.mousewheelListener,this.options?this.options:this.props.useCapture),r.addEventListener("scroll",this.scrollListener,this.options?this.options:this.props.useCapture),r.addEventListener("resize",this.scrollListener,this.options?this.options:this.props.useCapture),this.props.initialLoad&&this.scrollListener()}mousewheelListener(t){t.deltaY===1&&!this.isPassiveSupported()&&t.preventDefault()}scrollListener(){const t=this.scrollComponent,r=window,n=this.getParentElement(t);let o;if(this.props.useWindow){const i=document.documentElement||document.body.parentNode||document.body,a=r.pageYOffset!==void 0?r.pageYOffset:i.scrollTop;this.props.isReverse?o=a:o=this.calculateOffset(t,a)}else this.props.isReverse?o=n.scrollTop:o=t.scrollHeight-n.scrollTop-n.clientHeight;o{this.scrollComponent=b,u&&u(b)};const p=[r];return o&&(s?a?p.unshift(s):p.push(s):this.defaultLoader&&(a?p.unshift(this.defaultLoader):p.push(this.defaultLoader))),T.createElement(n,m,p)}}Ze(Qu,"propTypes",{children:bt.node.isRequired,element:bt.node,hasMore:bt.bool,initialLoad:bt.bool,isReverse:bt.bool,loader:bt.node,loadMore:bt.func.isRequired,pageStart:bt.number,ref:bt.func,getScrollParent:bt.func,threshold:bt.number,useCapture:bt.bool,useWindow:bt.bool}),Ze(Qu,"defaultProps",{element:"div",hasMore:!1,initialLoad:!0,pageStart:0,ref:null,threshold:250,useWindow:!0,isReverse:!1,useCapture:!1,loader:null,getScrollParent:null});const Ju="_video-grid_14t5i_9",yv="_limit-two-lines_14t5i_19",ef="_internal-testing_14t5i_43",cM="_limit-one-line_14t5i_50",wv="_narrow-mode_14t5i_71",hR={videoGrid:Ju,limitTwoLines:yv,internalTesting:ef,limitOneLine:cM,narrowMode:wv};function lM({enabled:e,refresh:t,minIndex:r=0,maxIndex:n,containerRef:o,getScrollerRect:i,changeScrollY:a,videoCardRefs:s}){const[c,l]=T.useState(void 0),u=_e(()=>!(!e||lp())),f=_e(()=>{var _;if(typeof c!="number"||!o.current)return!1;const S=i(),y=(_=o.current.querySelector(`.${Oo.card}.${Oo.cardActive}`))==null?void 0:_.getBoundingClientRect();return!(!S||!y||y.top-S.top<-(S.height+y.height)||y.top-S.top>S.height*2+y.height)}),d=S=>y=>{if(!u())return;y==null||y.preventDefault();let _=typeof S=="number"?S:S();const R=f()?c+_:v();if(Rn){w(n);return}l(R),w(R)};it("leftarrow",d(-1),{exactMatch:!0}),it("rightarrow",d(1),{exactMatch:!0}),it("uparrow",d(()=>-$()),{exactMatch:!0}),it("downarrow",d($),{exactMatch:!0});const g=()=>{u()&&l(void 0)};it("esc",g),it("enter",()=>{!u()||typeof c!="number"||E(c)}),it("backspace",()=>{var S;!u()||typeof c!="number"||(S=s[c])==null||S.onTriggerDislike()}),it(["s","w"],()=>{var S;!u()||typeof c!="number"||(S=s[c])==null||S.onToggleWatchLater()},{exactMatch:!0}),it(["period","p"],()=>{var S;!u()||typeof c!="number"||(S=s[c])==null||S.onHotkeyPreviewAnimation()},{exactMatch:!0});function v(){const S=i();if(!S)return 0;const y=p();for(let _=0;_=S.top)return _;return 0}const m=`.${Oo.card}`;function p(){var S;return[...((S=o.current)==null?void 0:S.querySelectorAll(m))||[]]}function b(S){return p()[S]}function w(S){var A;const y=b(S);(A=y==null?void 0:y.scrollIntoViewIfNeeded)==null||A.call(y,!1);const _=i(),R=y.getBoundingClientRect();if(!(!_||!R)){if(R.top<=_.top){const k=-(_.top-R.top+10);a==null||a({offset:k});return}if(_.bottom-R.bottom<10){const k=10-(_.bottom-R.bottom);a==null||a({offset:k});return}}}function E(S){const y=b(S);if(!y)return;const _=y.querySelector(".bili-video-card__wrap > a");_==null||_.click()}function $(){if(He.useNarrowMode)return 2;let S=Sv.get(window.innerWidth);if(S)return S;const y=o.current;if(!y)return 0;const _=window.getComputedStyle(y);return _.display!=="grid"?0:(S=_.gridTemplateColumns.split(" ").length,Sv.set(window.innerWidth,S),S)}return{activeIndex:c,clearActiveIndex:g}}const Sv=new Map,Oo={loader:_u` text-align: center; line-height: 60px; font-size: 120%; `,card:_u` border: 2px solid transparent; /* global class under .card */ .bili-video-card__info { padding-left: 2px; padding-bottom: 1px; margin-top: calc(var(--info-margin-top) - 1px); } `,cardActive:_u` border-color: #fb7299; border-radius: 6px; overflow: hidden; `},Cv=T.forwardRef(({infiteScrollUseWindow:e,shortcutEnabled:t,onScrollToTop:r,className:n,scrollerRef:o},i)=>{const[a,s]=T.useState([]),[c,l]=T.useState(!1),u=T.useMemo(()=>({page:1}),[]),f=_e(async()=>{await(r==null?void 0:r());try{E(),l(!0),u.page=1,s(await pv(2,u)),E()}finally{l(!1)}});T.useImperativeHandle(i,()=>({refresh:f}),[]);const d=_e(async()=>{const S=await pv(2,u);s(y=>[...y,...S])}),{useNarrowMode:g}=rn(),v=T.useRef(null),m=_e(()=>{var S;if(e){const y=fh+50;return new DOMRect(0,y,window.innerWidth,window.innerHeight-y)}else return(S=o==null?void 0:o.current)==null?void 0:S.getBoundingClientRect()}),p=vk(),b=T.useMemo(()=>new Array(a.length).fill(void 0),[a.length]),{activeIndex:w,clearActiveIndex:E}=lM({enabled:t&&!p,refresh:f,maxIndex:a.length-1,containerRef:v,getScrollerRect:m,videoCardRefs:b,changeScrollY:e?function({offset:S,absolute:y}){const _=document.documentElement;if(typeof S=="number"){_.scrollTop+=S;return}if(typeof y=="number"){_.scrollTop=y;return}}:void 0}),$=oi();return L(Qu,{pageStart:0,loadMore:d,hasMore:!0,useWindow:e,threshold:window.innerHeight,style:{minHeight:"100%"},loader:L("div",{className:Oo.loader,children:"加载中..."},0),children:L("div",{ref:v,className:Y(Ju,{[ef]:$},{[wv]:g},n),children:a.map((S,y)=>{const _=y===w;return L(ju,{ref:R=>b[y]=R,className:Y(Oo.card,{[Oo.cardActive]:_}),loading:c,item:S,active:_},S.uniqId)})})})}),Ev=L(go,{target:"_blank",href:"https://github.com/indefined/UserScripts/tree/master/bilibiliHome#%E6%8E%88%E6%9D%83%E8%AF%B4%E6%98%8E",children:"access_key 说明"});function xv({style:e,className:t}){const{runAsync:r,loading:n}=Ap(tk,{manual:!0}),{accessKey:o}=rn(),i=T.useRef(null),a=_e(async()=>{var l;await r()&&((l=i.current)==null||l.set(!1))});return L(Gm,{size:"small",style:e,className:t,children:o?U(Xt,{children:[L(go,{onClick:()=>a(),disabled:n,children:L("span",{children:"重新获取 access_key"})}),L(go,{onClick:rk,children:L("span",{children:"删除 access_key"})})]}):U(Xt,{children:[Ev,L(go,{onClick:a,disabled:n,size:"middle",children:L("span",{children:"获取 access_key"})})]})})}function dn({configKey:e,label:t,className:r,extraAction:n,tooltip:o}){const a=!!rn()[e],s=T.useCallback(l=>{const u=l.target.checked;lh({[e]:u}),n==null||n(u)},[]);let c=t||e;return o&&(c=L(Wm,{title:o,zIndex:11100,overlayStyle:{width:"max-content",maxWidth:"50vw"},children:c})),L(n2,{className:r,checked:a,onChange:s,children:c})}var uM={name:"1qkltea",styles:"margin-left:5px"};const fM=function(){const e=uM;return U(Xt,{children:[L(dn,{configKey:"initialShowMore",label:"自动查看更多",css:e}),L(dn,{configKey:"useNarrowMode",label:"启用居中模式",css:e})]})},Be={configIcon:"_config-icon_1d50l_1",settingsGroup:"_settings-group_1d50l_6",settingsGroupTitle:"_settings-group-title_1d50l_9",settingsGroupContent:"_settings-group-content_1d50l_12",row:"_row_1d50l_18",check:"_check_1d50l_26"};async function _v(){xt("即将刷新网页"),await wo(500),location.reload()}function dM(){if(window.confirm("确定?"))return kC(),_v()}function Ov(e,t,r){return it(e,()=>{He[t]=!He[t];const n=!He[t];xt(`已${n?"禁用":"启用"}「${r}」`)},{exactMatch:!0})}function hM({show:e,onHide:t}){const{usePcDesktopApi:r,autoPreviewUpdateInterval:n}=rn();return Ov(["shift.p"],"autoPreviewWhenKeyboardSelect","键盘选中后自动开始预览"),Ov(["shift.c"],"useNarrowMode","居中模式"),U(Au,{show:e,onHide:t,hideWhenMaskOnClick:!0,hideWhenEsc:!0,children:[U("div",{className:Zt.modalHeader,children:[U("div",{className:Zt.modalTitle,children:[L(Mn,{name:"Config",className:Be.configIcon}),"设置项"]}),L("div",{className:"space",style:{flex:1}}),L(Ru,{onClick:t})]}),U("main",{className:Zt.modalBody,children:[U("div",{className:Be.settingsGroup,children:[L("div",{className:Be.settingsGroupTitle,children:"接口切换"}),U("div",{className:Y(Be.settingsGroupContent),children:[U(cu.Group,{buttonStyle:"solid",value:r?"desktop":"app",onChange:o=>{const i=o.target.value;He.usePcDesktopApi=i==="desktop"},children:[L(cu.Button,{value:"desktop",children:"使用桌面端接口"}),L(cu.Button,{value:"app",children:"使用 App 端接口"})]}),!r&&L("div",{className:Be.row,style:{marginTop:5},children:L(xv,{})})]})]}),U("div",{className:Be.settingsGroup,children:[L("div",{className:Be.settingsGroupTitle,children:"开关"}),U("div",{className:Y(Be.settingsGroupContent,Be.row),children:[L(dn,{configKey:"pureRecommend",label:"开启纯推荐模式",tooltip:U(Xt,{children:["首页只保留推荐",L("br",{}),"P.S 需要刷新网页~"]}),className:Be.check,extraAction:_v}),L(dn,{configKey:"initialShowMore",label:"自动查看更多",tooltip:"打开首页时默认打开推荐弹框",className:Be.check,extraAction:o=>{o&&xt("已开启自动查看更多: 下次打开首页时将直接展示推荐弹框")}}),L(dn,{configKey:"useNarrowMode",label:"启用居中模式",tooltip:U(Xt,{children:["居中两列",L("br",{}),"切换设置快捷键: ",L(ps,{color:"green",children:"shift+c"})]}),className:Be.check}),L(dn,{configKey:"useParallelRequest",label:"批量请求时使用并行",tooltip:U(Xt,{children:["并行快但可能有重复",L("br",{}),"推荐视频大量重复时关闭这个试试~"]}),className:Be.check}),L(dn,{configKey:"autoPreviewWhenKeyboardSelect",label:"键盘选中后自动开始预览",className:Be.check,tooltip:U(Xt,{children:["手动预览快捷键: ",L(ps,{color:"green",children:"."})," or ",L(ps,{color:"green",children:"p"}),L("br",{}),"切换设置快捷键: ",L(ps,{color:"green",children:"shift+p"})]})}),U("div",{style:{width:"100%",display:"flex",alignItems:"center"},children:["预览更新间隔",L(x2,{style:{flex:1,margin:"0 15px"},min:0,max:1e3,keyboard:!0,onChange:o=>He.autoPreviewUpdateInterval=o,value:n,tooltip:{open:!0}}),U("span",{style:{width:"65px"},children:["(",n,"ms)"]})]})]})]}),U("div",{className:Be.settingsGroup,children:[L("div",{className:Be.settingsGroupTitle,children:"高级"}),U("div",{className:Y(Be.settingsGroupContent),children:[L("div",{className:Be.row,children:L(go,{onClick:dM,danger:!0,children:"恢复默认设置"})}),L("div",{className:Be.row,style:{marginTop:10},children:L(dn,{configKey:"openInIINAWhenRightClick",label:"右键在 IINA 中打开",className:Be.check})})]})]}),U("div",{className:Be.settingsGroup,children:[L("div",{className:Be.settingsGroupTitle,children:"帮助"}),L("div",{className:Y(Be.settingsGroupContent),children:L("div",{className:Be.row,children:U(Gm,{size:"small",children:[L(go,{href:"https://github.com/magicdawn/bilibili-app-recommend#%E5%BF%AB%E6%8D%B7%E9%94%AE%E8%AF%B4%E6%98%8E",target:"_blank",children:"查看可用的快捷键"}),Ev]})})})]})]})]})}var tf={};Object.defineProperty(tf,"__esModule",{value:!0});var $v=tf.useSticky=void 0;const rf=T;function gM(){const e=(0,rf.useRef)(null),[t,r]=(0,rf.useState)(!1);return(0,rf.useEffect)(()=>{function n(){if(!e.current)return;const o=e.current.getBoundingClientRect().top,i=parseInt(getComputedStyle(e.current).top),a=o<=i;a&&!t?r(!0):!a&&t&&r(!1)}return n(),document.addEventListener("scroll",n),window.addEventListener("resize",n),window.addEventListener("orientationchange",n),()=>{document.removeEventListener("scroll",n),window.removeEventListener("resize",n),window.removeEventListener("orientationchange",n)}},[t]),[e,t]}$v=tf.useSticky=gM;const Pv={expandBtn:"_expand-btn_wdzp9_1",expanded:"_expanded_wdzp9_12"},mM=T.forwardRef(function({children:t},r){const[n,o]=Rp(!1);T.useImperativeHandle(r,()=>o,[o]);const i=L("button",{className:Y("primary-btn",Pv.expandBtn),onClick:o.toggle,children:L("svg",{className:Y({[Pv.expanded]:n}),children:L("use",{xlinkHref:"#widget-arrow"})})});return U(Xt,{children:[i,n&&t]})}),Ii={modalMask:"_modal-mask_juq7d_1",narrowMode:"_narrow-mode_juq7d_1",modal:"_modal_juq7d_1",modalHeader:"_modal-header_juq7d_21",modalBody:"_modal-body_juq7d_22",btnRefresh:"_btn-refresh_juq7d_25"},pM=T.memo(function({show:t,onHide:r}){const n=T.useRef(null),o=T.useRef(null),{useNarrowMode:i}=rn(),a=T.useMemo(()=>({[Ii.narrowMode]:i}),[i]),s=_e(()=>{var l;return(l=o.current)==null?void 0:l.refresh()}),c=_e(()=>{n.current&&(n.current.scrollTop=0)});return U(Au,{show:t,onHide:r,clsModalMask:Y(a),clsModal:Y(Ii.modal,a),children:[U("div",{className:Y(Zt.modalHeader,Ii.modalHeader),children:[L("div",{className:Zt.modalTitle,children:"推荐"}),L("div",{className:"space",style:{flex:1}}),L(mM,{children:L(fM,{})}),L(Av,{onClick:s,className:Ii.btnRefresh,refreshHotkeyEnabled:t}),L(Ru,{onClick:r})]}),L("div",{className:Y(Zt.modalBody,Ii.modalBody),ref:n,children:L(Cv,{ref:o,shortcutEnabled:t,onScrollToTop:c,infiteScrollUseWindow:!1,scrollerRef:n})})]})}),Tv={btn:So` padding: 0; width: 31px; height: 31px; border-radius: 50%; `,icon:So` svg { width: 14px; height: 14px; } `},$o=ni({modalFeedVisible:He.initialShowMore,modalConfigVisible:!1}),kv=function(){return Yn($o)},vM=()=>{$o.modalFeedVisible=!0},bM=()=>{$o.modalFeedVisible=!1},yM=()=>{$o.modalConfigVisible=!0},wM=()=>{$o.modalConfigVisible=!1};function Mv({onRefresh:e,refreshHotkeyEnabled:t}){const{accessKey:r,pureRecommend:n,usePcDesktopApi:o}=rn(),{modalFeedVisible:i,modalConfigVisible:a}=Yn($o),[s,c]=$v();return U(Xt,{children:[U("div",{ref:s,className:"area-header",css:[So` margin-bottom: 0; height: 50px; `,n&&So` position: sticky; top: ${fh}px; z-index: 1000; `,n&&c&&So` background-color: var(--bg1_float); box-shadow: 0 2px 4px rgb(0 0 0 / 8%); `,"",""],children:[U("div",{className:"left",children:[L("a",{id:"影视",className:"the-world area-anchor","data-id":"25"}),L("svg",{className:"icon",children:L("use",{xlinkHref:"#channel-cinephile"})}),L("a",{className:"title",href:"#",children:L("span",{children:"推荐"})})]}),U("div",{className:"right",children:[!o&&!r&&L(xv,{style:{marginLeft:5}}),L("button",{className:"primary-btn",css:Tv.btn,onClick:yM,children:L(Mn,{name:"Config",css:Tv.icon})}),L(Av,{onClick:e,refreshHotkeyEnabled:t}),!n&&U("button",{className:"primary-btn see-more",onClick:vM,children:[L("span",{children:"查看更多"}),L("svg",{children:L("use",{xlinkHref:"#widget-arrow"})})]})]})]}),L(pM,{show:i,onHide:bM}),L(hM,{show:a,onHide:wM})]})}const Av=T.forwardRef(function({onClick:e,className:t="",style:r,refreshHotkeyEnabled:n},o){n??(n=!0);const[i,a]=T.useState(0),s=_e(l=>(a(u=>u+360),e==null?void 0:e(l))),c=T.useRef(null);return T.useImperativeHandle(o,()=>({click(){var l;(l=c.current)==null||l.click()}}),[]),it("r",()=>{var l;n&&(lp()||(l=c.current)==null||l.click())},{exactMatch:!0}),U("button",{className:`primary-btn roll-btn ${t}`,onClick:s,style:r,ref:c,children:[L("svg",{style:{transform:`rotate(${i}deg)`,width:"10px",height:"10px",transition:i===360?"transform .5s ease":"unset"},onTransitionEnd:()=>{a(0)},children:L("use",{xlinkHref:"#widget-roll"})}),L("span",{children:"换一换"})]})}),SM={grid:So` /* card=299 col-gap=20 */ width: ${299*2+20}px; margin: 0 auto; `};function CM(){const{useNarrowMode:e}=rn(),{modalFeedVisible:t,modalConfigVisible:r}=kv(),n=T.useRef(null),o=_e(()=>{var a;return(a=n.current)==null?void 0:a.refresh()}),i=_e(()=>{document.documentElement.scrollTop=0});return U("section",{"data-area":"推荐",children:[L(Mv,{onRefresh:o,refreshHotkeyEnabled:!(t||r)}),L(Cv,{ref:n,css:[e&&SM.grid,"",""],shortcutEnabled:!(t||r),infiteScrollUseWindow:!0,onScrollToTop:i})]})}function EM(){const e=T.useMemo(()=>new Array(20).fill(0).map(()=>crypto.randomUUID()),[]),t=oi(),r=T.useMemo(()=>({page:1}),[]),{data:n,loading:o,error:i,refresh:a}=Ap(()=>rM(r));i&&console.error(i.stack||i);const{modalConfigVisible:s,modalFeedVisible:c}=kv();return U("section",{"data-area":"推荐",children:[L(Mv,{onRefresh:a,refreshHotkeyEnabled:!(s||c)}),L("div",{className:Y(Ju,yv,{[ef]:t}),style:{marginBottom:t?30:0},children:o||i?e.map(l=>L(ju,{},l)):n.map(l=>L(ju,{item:l},l.uniqId))})]})}(function(){var t;if(location.href.startsWith("https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?"))return window.stop(),(t=window.top)==null?void 0:t.postMessage(location.href,"https://www.bilibili.com");if(location.pathname==="/")return xM()})();async function xM(){return hu(".adblock-tips"),cp("html.gray",e=>e.classList.remove("gray")),He.pureRecommend?OM():_M()}async function _M(){const t=Date.now()+1e4;let r;for(;;){if(document.querySelector(".bili-layout > section.bili-grid")){const i=document.querySelector(".bili-layout > section.bili-grid");r=a=>i==null?void 0:i.insertAdjacentElement("afterend",a);break}if(oi()&&document.querySelector(".bili-feed4-layout")){r=i=>{var a;return(a=document.querySelector(".bili-feed4-layout"))==null?void 0:a.insertAdjacentElement("afterbegin",i)};break}if(Date.now()>t)break;await wo(200)}if(!r){console.error("[bilibili-app-recommend]: init fail");return}const n=document.createElement("section");r(n),vs(n).render(L(op,{children:L(EM,{})}))}async function OM(){var o,i;oi()?((o=document.querySelector(".bili-feed4 .bili-feed4-layout"))==null||o.remove(),hu(".bili-feed4 .header-channel")):((i=document.querySelector(".bili-layout"))==null||i.remove(),hu(".bili-footer"));const e=document.createElement("div");e.classList.add(oi()?"bili-feed4-layout":"bili-layout","pure-recommend");const t=document.querySelector(".bili-header");t==null||t.insertAdjacentElement("afterend",e);const r=document.createElement("section");e==null||e.appendChild(r),vs(r).render(L(op,{children:L(CM,{})}))}})(React,ReactDOM,axios,axiosGmxhrAdapter);