// ==UserScript== // @name bilibili-app-recommend // @namespace https://magicdawn.fun // @version 0.11.1 // @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 https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png // @match *://www.bilibili.com/index.html // @match *://www.bilibili.com/?* // @match https://www.mcbbs.net/template/mcbbs/image/special_photo_bg.png?* // @match *://www.bilibili.com/index.html?* // @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 // @grant unsafeWindow // @downloadURL none // ==/UserScript== (e=>{const t=document.createElement("style");t.dataset.source="vite-plugin-monkey",t.textContent=e,document.head.append(t)})(" .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_1jzhe_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-color:#ffb243;color:#fff;border-radius:6px;white-space:pre-wrap}._toast-container_1jzhe_1._single-line_1jzhe_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_mlccj_1{position:relative}._image-wrapper_mlccj_4{border-radius:6px;overflow:hidden}._preview-card-wrapper_mlccj_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_mlccj_8 ._preview-card-inner_mlccj_21{width:100%;height:100%}._watch-later_mlccj_25{z-index:5}._badge_mlccj_28{color:#fa6a9d;border-radius:2px;border:1px #fa6a9d solid;line-height:20px;padding:0 10px;transform:scale(.8);transform-origin:center left}._recommend-reason_mlccj_37{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_mlccj_52{color:default}._btn-dislike_mlccj_55{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_mlccj_55 ._btn-dislike-icon_mlccj_70{pointer-events:none;user-select:none;width:12px;height:12px;color:#fff}._btn-dislike_mlccj_55 ._btn-dislike-tip_mlccj_77{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_mlccj_92{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_mlccj_92{border:1px solid #333}._disliked-wrapper_mlccj_92 ._dislike-content-cover_mlccj_106{border-top-left-radius:6px;border-top-right-radius:6px;padding-top:56.25%;position:relative}._disliked-wrapper_mlccj_92 ._dislike-content-cover_mlccj_106 ._dislike-content-cover-inner_mlccj_112{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center}._disliked-wrapper_mlccj_92 ._dislike-content-cover_mlccj_106 ._dislike-content-cover-inner_mlccj_112 ._dislike-icon_mlccj_123{margin-bottom:5px}._disliked-wrapper_mlccj_92 ._dislike-content-cover_mlccj_106 ._dislike-content-cover-inner_mlccj_112 ._dislike-reason_mlccj_126{font-size:20px;text-align:center}._disliked-wrapper_mlccj_92 ._dislike-content-cover_mlccj_106 ._dislike-content-cover-inner_mlccj_112 ._dislike-desc_mlccj_130{font-size:16px;text-align:center}._disliked-wrapper_mlccj_92 ._dislike-content-action_mlccj_134{flex:1;width:100%;border-top:1px solid #eee;display:flex;align-items:center;justify-content:center}body.dark ._disliked-wrapper_mlccj_92 ._dislike-content-action_mlccj_134{border-top:1px solid #333}._disliked-wrapper_mlccj_92 ._dislike-content-action_mlccj_134 button{font-size:16px;color:inherit;display:flex;align-items:center}._skeleton-active_mlccj_151 .bili-video-card__skeleton--cover,._skeleton-active_mlccj_151 .bili-video-card__skeleton--text,._skeleton-active_mlccj_151 .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_mlccj_1;animation-duration:1.4s;animation-timing-function:ease;animation-iteration-count:infinite}@keyframes _ant-skeleton-loading_mlccj_1{0%{background-position:100% 50%}to{background-position:0 50%}}._video-grid_tu03i_9{display:grid;position:relative;width:100%;grid-gap:20px 12px}@media (max-width: 1099.9px){._video-grid_tu03i_9{grid-template-columns:repeat(4,1fr)}._video-grid_tu03i_9._limit-two-lines_tu03i_19>*:nth-of-type(1n + 9){display:none!important}}@media (min-width: 1100px) and (max-width: 1700.9px){._video-grid_tu03i_9{grid-template-columns:repeat(5,1fr)}._video-grid_tu03i_9._limit-two-lines_tu03i_19>*:nth-of-type(1n + 11){display:none!important}}@media (min-width: 1701px) and (max-width: 2199.9px){._video-grid_tu03i_9{grid-template-columns:repeat(6,1fr)}._video-grid_tu03i_9._limit-two-lines_tu03i_19>*:nth-of-type(1n + 13){display:none!important}}@media (min-width: 2200px){._video-grid_tu03i_9{grid-template-columns:repeat(7,1fr)}._video-grid_tu03i_9._limit-two-lines_tu03i_19>*:nth-of-type(1n + 15){display:none!important}}._video-grid_tu03i_9._internal-testing_tu03i_51{grid-gap:20px 20px}@media (max-width: 1399.9px){._video-grid_tu03i_9._internal-testing_tu03i_51{grid-template-columns:repeat(4,1fr)}._video-grid_tu03i_9._internal-testing_tu03i_51._limit-one-line_tu03i_58>*:nth-of-type(1n + 5){display:none!important}._video-grid_tu03i_9._internal-testing_tu03i_51._limit-two-lines_tu03i_19>*:nth-of-type(1n + 9){display:none!important}}@media (min-width: 1400px){._video-grid_tu03i_9._internal-testing_tu03i_51{grid-template-columns:repeat(5,1fr)}._video-grid_tu03i_9._internal-testing_tu03i_51._limit-one-line_tu03i_58>*:nth-of-type(1n + 6){display:none!important}._video-grid_tu03i_9._internal-testing_tu03i_51._limit-two-lines_tu03i_19>*:nth-of-type(1n + 11){display:none!important}}._narrow-mode_tu03i_79{grid-template-columns:repeat(2,1fr)!important}._config-icon_1qntb_1{line-height:1;margin-right:5px;font-size:0}._settings-group_1qntb_6{margin-bottom:10px}._settings-group_1qntb_6 ._settings-group-title_1qntb_9{font-size:2em;display:flex;align-items:center}._settings-group_1qntb_6 ._settings-group-sub-title_1qntb_14{font-size:1.3em;display:flex;align-items:center;margin-top:15px}._settings-group_1qntb_6 ._settings-group-content_1qntb_20{color:default}._settings-group_1qntb_6 ._settings-group-content_1qntb_20 button:first-child{margin-left:0}._row_1qntb_26{display:flex;align-items:center;flex-wrap:wrap}._row_1qntb_26 .primary-btn:first-child{margin-left:0}._check_1qntb_34{margin-bottom:5px;margin-inline-start:0!important;margin-inline-end:5px!important}._setting-tabs_1qntb_39.ant-tabs .ant-tabs-tab{padding-left:5px}._tab-pane_1qntb_42{min-height:40vh}._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_7bwzz_1._narrow-mode_7bwzz_1{background-color:#000000e6}._modal_7bwzz_1{width:calc(100vw - 30px);height:calc(100vh - 30px);max-height:unset;padding-right:0}._modal_7bwzz_1._narrow-mode_7bwzz_1{width:606px;height:calc(100vh - 10px);border:none}body.dark ._modal_7bwzz_1._narrow-mode_7bwzz_1{border:none}._modal-header_7bwzz_18,._modal-body_7bwzz_19{padding-right:15px}body.dark ._btn-refresh_7bwzz_22{color:#eee!important;background-color:#333!important;border-color:transparent!important;height:auto;padding:8px 12px;line-height:16px;font-size:13px} "); (function (f, $o, sf, G1) { 'use strict'; function _interopNamespaceDefault(e) { const n = Object.create(null, { [Symbol.toStringTag]: { value: 'Module' } }); if (e) { for (const k in e) { if (k !== 'default') { const d = Object.getOwnPropertyDescriptor(e, k); Object.defineProperty(n, k, d.get ? d : { enumerable: true, get: () => e[k] }); } } } n.default = e; return Object.freeze(n); } const f__namespace = /*#__PURE__*/_interopNamespaceDefault(f); const $o__namespace = /*#__PURE__*/_interopNamespaceDefault($o); var k1=Object.defineProperty;var L1=(e,t,r)=>t in e?k1(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var F1=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Pt=(e,t,r)=>(L1(e,typeof t!="symbol"?t+"":t,r),r),Wc=(e,t,r)=>{if(!t.has(e))throw TypeError("Cannot "+r)};var k=(e,t,r)=>(Wc(e,t,"read from private field"),r?r.call(e):t.get(e)),je=(e,t,r)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,r);},Se=(e,t,r,n)=>(Wc(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),ws=(e,t,r,n)=>({set _(i){Se(e,t,i,r);},get _(){return k(e,t,n)}}),he=(e,t,r)=>(Wc(e,t,"access private method"),r);var cj=F1((jn,zn)=>{var _m=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Kn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function K1(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){if(this instanceof n){var i=[null];i.push.apply(i,arguments);var o=Function.bind.apply(t,i);return new o}return t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return e[n]}});}),r}var Pm={exports:{}},Dl={};/** * @license React * react-jsx-runtime.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 q1=f,X1=Symbol.for("react.element"),Y1=Symbol.for("react.fragment"),Z1=Object.prototype.hasOwnProperty,Q1=q1.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,J1={key:!0,ref:!0,__self:!0,__source:!0};function Om(e,t,r){var n,i={},o=null,a=null;r!==void 0&&(o=""+r),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(a=t.ref);for(n in t)Z1.call(t,n)&&!J1.hasOwnProperty(n)&&(i[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps,t)i[n]===void 0&&(i[n]=t[n]);return {$$typeof:X1,type:e,key:o,ref:a,props:i,_owner:Q1.current}}Dl.Fragment=Y1;Dl.jsx=Om;Dl.jsxs=Om;Pm.exports=Dl;var Ma=Pm.exports;function ew(e){if(e.sheet)return e.sheet;for(var t=0;t0?ir(Io,--wr):0,Eo--,Ut===10&&(Eo=1,zl--),Ut}function Dr(){return Ut=wr2||Na(Ut)>3?"":" "}function hw(e,t){for(;--t&&Dr()&&!(Ut<48||Ut>102||Ut>57&&Ut<65||Ut>70&&Ut<97););return Ja(e,Vs()+(t<6&&Sn()==32&&Dr()==32))}function zu(e){for(;Dr();)switch(Ut){case e:return wr;case 34:case 39:e!==34&&e!==39&&zu(Ut);break;case 40:e===41&&zu(e);break;case 92:Dr();break}return wr}function vw(e,t){for(;Dr()&&e+Ut!==47+10;)if(e+Ut===42+42&&Sn()===47)break;return "/*"+Ja(t,wr-1)+"*"+jl(e===47?e:Dr())}function pw(e){for(;!Na(Sn());)Dr();return Ja(e,wr)}function km(e){return Am(Gs("",null,null,null,[""],e=Im(e),0,[0],e))}function Gs(e,t,r,n,i,o,a,s,l){for(var c=0,u=0,d=a,h=0,v=0,p=0,m=1,g=1,b=1,w=0,S="",$=i,x=o,y=n,C=S;g;)switch(p=w,w=Dr()){case 40:if(p!=108&&ir(C,d-1)==58){ju(C+=ut(Us(w),"&","&\f"),"&\f")!=-1&&(b=-1);break}case 34:case 39:case 91:C+=Us(w);break;case 9:case 10:case 13:case 32:C+=fw(p);break;case 92:C+=hw(Vs()-1,7);continue;case 47:switch(Sn()){case 42:case 47:Ss(mw(vw(Dr(),Vs()),t,r),l);break;default:C+="/";}break;case 123*m:s[c++]=gn(C)*b;case 125*m:case 59:case 0:switch(w){case 0:case 125:g=0;case 59+u:b==-1&&(C=ut(C,/\f/g,"")),v>0&&gn(C)-d&&Ss(v>32?Ah(C+";",n,r,d-1):Ah(ut(C," ","")+";",n,r,d-2),l);break;case 59:C+=";";default:if(Ss(y=Ih(C,t,r,c,u,i,s,S,$=[],x=[],d),o),w===123)if(u===0)Gs(C,t,y,y,$,o,d,s,x);else switch(h===99&&ir(C,3)===110?100:h){case 100:case 108:case 109:case 115:Gs(e,y,y,n&&Ss(Ih(e,y,y,0,0,i,s,S,i,$=[],d),x),i,x,d,s,n?$:x);break;default:Gs(C,y,y,y,[""],x,0,s,x);}}c=u=v=0,m=b=1,S=C="",d=a;break;case 58:d=1+gn(C),v=p;default:if(m<1){if(w==123)--m;else if(w==125&&m++==0&&dw()==125)continue}switch(C+=jl(w),w*m){case 38:b=u>0?1:(C+="\f",-1);break;case 44:s[c++]=(gn(C)-1)*b,b=1;break;case 64:Sn()===45&&(C+=Us(Dr())),h=Sn(),u=d=gn(S=C+=pw(Vs())),w++;break;case 45:p===45&&gn(C)==2&&(m=0);}}return o}function Ih(e,t,r,n,i,o,a,s,l,c,u){for(var d=i-1,h=i===0?o:[""],v=uf(h),p=0,m=0,g=0;p0?h[b]+" "+w:ut(w,/&\f/g,h[b])))&&(l[g++]=S);return Hl(e,t,r,i===0?lf:s,l,c,u)}function mw(e,t,r){return Hl(e,t,r,Tm,jl(uw()),Ra(e,2,-2),0)}function Ah(e,t,r,n){return Hl(e,t,r,cf,Ra(e,0,n),Ra(e,n+1,-1),n)}function Ti(e,t){for(var r="",n=uf(e),i=0;i6)switch(ir(e,t+1)){case 109:if(ir(e,t+4)!==45)break;case 102:return ut(e,/(.+:)(.+)-([^]+)/,"$1"+ct+"$2-$3$1"+dl+(ir(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return ~ju(e,"stretch")?Fm(ut(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(ir(e,t+1)!==115)break;case 6444:switch(ir(e,gn(e)-3-(~ju(e,"!important")&&10))){case 107:return ut(e,":",":"+ct)+e;case 101:return ut(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ct+(ir(e,14)===45?"inline-":"")+"box$3$1"+ct+"$2$3$1"+sr+"$2box$3")+e}break;case 5936:switch(ir(e,t+11)){case 114:return ct+e+sr+ut(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return ct+e+sr+ut(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return ct+e+sr+ut(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return ct+e+sr+e+e}return e}var Ew=function(t,r,n,i){if(t.length>-1&&!t.return)switch(t.type){case cf:t.return=Fm(t.value,t.length);break;case Mm:return Ti([Yo(t,{value:ut(t.value,"@","@"+ct)})],i);case lf:if(t.length)return cw(t.props,function(o){switch(lw(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ti([Yo(t,{props:[ut(o,/:(read-\w+)/,":"+dl+"$1")]})],i);case"::placeholder":return Ti([Yo(t,{props:[ut(o,/:(plac\w+)/,":"+ct+"input-$1")]}),Yo(t,{props:[ut(o,/:(plac\w+)/,":"+dl+"$1")]}),Yo(t,{props:[ut(o,/:(plac\w+)/,sr+"input-$1")]})],i)}return ""})}},_w=[Ew],Dm=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 g=m.getAttribute("data-emotion");g.indexOf(" ")!==-1&&(document.head.appendChild(m),m.setAttribute("data-s",""));});}var i=t.stylisPlugins||_w,o={},a,s=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+r+' "]'),function(m){for(var g=m.getAttribute("data-emotion").split(" "),b=1;b=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16);}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Lw={animationIterationCount:1,aspectRatio: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},Fw=/[A-Z]|^ms/g,Dw=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Um=function(t){return t.charCodeAt(1)===45},Lh=function(t){return t!=null&&typeof t!="boolean"},Bc=yw(function(e){return Um(e)?e:e.replace(Fw,"-$&").toLowerCase()}),Fh=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Dw,function(n,i,o){return bn={name:i,styles:o,next:bn},i})}return Lw[t]!==1&&!Um(t)&&typeof r=="number"&&r!==0?r+"px":r};function Ia(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 bn={name:r.name,styles:r.styles,next:bn},r.name;if(r.styles!==void 0){var n=r.next;if(n!==void 0)for(;n!==void 0;)bn={name:n.name,styles:n.styles,next:bn},n=n.next;var i=r.styles+";";return i}return jw(e,t,r)}case"function":{if(e!==void 0){var o=bn,a=r(e);return bn=o,Ia(e,t,a)}break}}if(t==null)return r;var s=t[r];return s!==void 0?s:r}function jw(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i0)return a(u);if(h==="number"&&isFinite(u))return d.long?l(u):s(u);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(u))};function a(u){if(u=String(u),!(u.length>100)){var d=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(u);if(d){var h=parseFloat(d[1]),v=(d[2]||"ms").toLowerCase();switch(v){case"years":case"year":case"yrs":case"yr":case"y":return h*o;case"weeks":case"week":case"w":return h*i;case"days":case"day":case"d":return h*n;case"hours":case"hour":case"hrs":case"hr":case"h":return h*r;case"minutes":case"minute":case"mins":case"min":case"m":return h*t;case"seconds":case"second":case"secs":case"sec":case"s":return h*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return h;default:return}}}}function s(u){var d=Math.abs(u);return d>=n?Math.round(u/n)+"d":d>=r?Math.round(u/r)+"h":d>=t?Math.round(u/t)+"m":d>=e?Math.round(u/e)+"s":u+"ms"}function l(u){var d=Math.abs(u);return d>=n?c(u,d,n,"day"):d>=r?c(u,d,r,"hour"):d>=t?c(u,d,t,"minute"):d>=e?c(u,d,e,"second"):u+" ms"}function c(u,d,h,v){var p=d>=h*1.5;return Math.round(u/h)+" "+v+(p?"s":"")}return Vc}function qw(e){r.debug=r,r.default=r,r.coerce=l,r.disable=o,r.enable=i,r.enabled=a,r.humanize=Kw(),r.destroy=c,Object.keys(e).forEach(u=>{r[u]=e[u];}),r.names=[],r.skips=[],r.formatters={};function t(u){let d=0;for(let h=0;h{if(y==="%%")return "%";$++;const M=r.formatters[C];if(typeof M=="function"){const R=g[$];y=M.call(b,R),g.splice($,1),$--;}return y}),r.formatArgs.call(b,g),(b.log||r.log).apply(b,g);}return m.namespace=u,m.useColors=r.useColors(),m.color=r.selectColor(u),m.extend=n,m.destroy=r.destroy,Object.defineProperty(m,"enabled",{enumerable:!0,configurable:!1,get:()=>h!==null?h:(v!==r.namespaces&&(v=r.namespaces,p=r.enabled(u)),p),set:g=>{h=g;}}),typeof r.init=="function"&&r.init(m),m}function n(u,d){const h=r(this.namespace+(typeof d>"u"?":":d)+u);return h.log=this.log,h}function i(u){r.save(u),r.namespaces=u,r.names=[],r.skips=[];let d;const h=(typeof u=="string"?u:"").split(/[\s,]+/),v=h.length;for(d=0;d"-"+d)].join(",");return r.enable(""),u}function a(u){if(u[u.length-1]==="*")return !0;let d,h;for(d=0,h=r.skips.length;d{let l=!1;return ()=>{l||(l=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."));}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function r(){return typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function n(l){if(l[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+l[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const c="color: "+this.color;l.splice(1,0,c,"color: inherit");let u=0,d=0;l[0].replace(/%[a-zA-Z%]/g,h=>{h!=="%%"&&(u++,h==="%c"&&(d=u));}),l.splice(d,0,c);}t.log=console.debug||console.log||(()=>{});function i(l){try{l?t.storage.setItem("debug",l):t.storage.removeItem("debug");}catch{}}function o(){let l;try{l=t.storage.getItem("debug");}catch{}return !l&&typeof process<"u"&&"env"in process&&(l={}.DEBUG),l}function a(){try{return localStorage}catch{}}e.exports=Xw(t);const{formatters:s}=e.exports;s.j=function(l){try{return JSON.stringify(l)}catch(c){return "[UnexpectedJSONParseError]: "+c.message}};})(Wu,Wu.exports);var Yw=Wu.exports;const Zw=Kn(Yw),ui="bilibili-app-recommend",Qw="bilibili_app_recommend",Xm=Zw(ui);var Jw=typeof global=="object"&&global&&global.Object===Object&&global;const Ym=Jw;var eS=typeof self=="object"&&self&&self.Object===Object&&self,tS=Ym||eS||Function("return this")();const On=tS;var rS=On.Symbol;const $n=rS;var Zm=Object.prototype,nS=Zm.hasOwnProperty,iS=Zm.toString,Zo=$n?$n.toStringTag:void 0;function oS(e){var t=nS.call(e,Zo),r=e[Zo];try{e[Zo]=void 0;var n=!0;}catch{}var i=iS.call(e);return n&&(t?e[Zo]=r:delete e[Zo]),i}var aS=Object.prototype,sS=aS.toString;function lS(e){return sS.call(e)}var cS="[object Null]",uS="[object Undefined]",zh=$n?$n.toStringTag:void 0;function Ao(e){return e==null?e===void 0?uS:cS:zh&&zh in Object(e)?oS(e):lS(e)}function _o(e){return e!=null&&typeof e=="object"}var dS="[object Symbol]";function Jl(e){return typeof e=="symbol"||_o(e)&&Ao(e)==dS}function fS(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r0){if(++t>=GS)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function YS(e){return function(){return e}}var ZS=function(){try{var e=Li(Object,"defineProperty");return e({},"",{}),e}catch{}}();const fl=ZS;var QS=fl?function(e,t){return fl(e,"toString",{configurable:!0,enumerable:!1,value:YS(t),writable:!0})}:Jm;const JS=QS;var eC=XS(JS);const tC=eC;function rC(e,t,r,n){for(var i=e.length,o=r+(n?1:-1);n?o--:++o-1}var sC=9007199254740991,lC=/^(?:0|[1-9]\d*)$/;function mf(e,t){var r=typeof e;return t=t??sC,!!t&&(r=="number"||r!="symbol"&&lC.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=vC}function pC(e){return e!=null&&bf(e.length)&&!eg(e)}var mC=Object.prototype;function gC(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||mC;return e===r}function bC(e,t){for(var r=-1,n=Array(e);++r-1}function Rx(e,t){var r=this.__data__,n=ec(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function qn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t0&&r(s)?t>1?sg(s,t-1,r,n,i):ag(i,s):n||(i[i.length]=s);}return i}function Yx(e){var t=e==null?0:e.length;return t?sg(e,1):[]}function Zx(e){return tC(hC(e,void 0,Yx),e+"")}var Qx="Expected a function";function Jx(e,t){var r;if(typeof t!="function")throw new TypeError(Qx);return e=ES(e),function(){return --e>0&&(r=t.apply(this,arguments)),e<=1&&(t=void 0),r}}function e$(){this.__data__=new qn,this.size=0;}function t$(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function r$(e){return this.__data__.get(e)}function n$(e){return this.__data__.has(e)}var i$=200;function o$(e,t){var r=this.__data__;if(r instanceof qn){var n=r.__data__;if(!ka||n.lengths))return !1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,v=r&O$?new La:void 0;for(o.set(e,t),o.set(t,e);++d=t||C<0||d&&M>=o}function b(){var y=qc();if(g(y))return w(y);s=setTimeout(b,m(y));}function w(y){return s=void 0,h&&n?v(y):(n=i=void 0,a)}function S(){s!==void 0&&clearTimeout(s),c=0,n=l=i=s=void 0;}function $(){return s===void 0?a:w(qc())}function x(){var y=qc(),C=g(y);if(n=arguments,i=this,l=y,C){if(s===void 0)return p(l);if(d)return clearTimeout(s),s=setTimeout(b,t),v(l)}return s===void 0&&(s=setTimeout(b,t)),a}return x.cancel=S,x.flush=$,x}function pE(e,t,r){for(var n=-1,i=e==null?0:e.length;++n=PE){var c=t?null:_E(e);if(c)return xf(c);a=!1,i=lg,l=new La;}else l=t?[]:s;e:for(;++nnew Proxy(e,t);const qu=Object.getPrototypeOf,Xu=new WeakMap,pg=e=>e&&(Xu.has(e)?Xu.get(e):qu(e)===Object.prototype||qu(e)===Array.prototype),hl=e=>typeof e=="object"&&e!==null,RE=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(qu(e),t)},Ef=e=>e[$f]||e,mg=(e,t,r,n)=>{if(!pg(e))return e;let i=n&&n.get(e);if(!i){const l=Ef(e);i=(c=>Object.values(Object.getOwnPropertyDescriptors(c)).some(u=>!u.configurable&&!u.writable))(l)?[l,RE(l)]:[l],n==null||n.set(e,i);}const[o,a]=i;let s=r&&r.get(o);return s&&s[1].f===!!a||(s=((l,c)=>{const u={f:c};let d=!1;const h=(p,m)=>{if(!d){let g=u[Qo].get(l);if(g||(g={},u[Qo].set(l,g)),p===ga)g[ga]=!0;else {let b=g[p];b||(b=new Set,g[p]=b),b.add(m);}}},v={get:(p,m)=>m===$f?l:(h("k",m),mg(Reflect.get(p,m),u[Qo],u.c,u.t)),has:(p,m)=>m===TE?(d=!0,u[Qo].delete(l),!0):(h("h",m),Reflect.has(p,m)),getOwnPropertyDescriptor:(p,m)=>(h("o",m),Reflect.getOwnPropertyDescriptor(p,m)),ownKeys:p=>(h(ga),Reflect.ownKeys(p))};return c&&(v.set=v.deleteProperty=()=>!1),[v,u]})(o,!!a),s[1].p=ME(a||o,s[0]),r&&r.set(o,s)),s[1][Qo]=t,s[1].c=r,s[1].t=n,s[1].p},gg=(e,t,r,n)=>{if(Object.is(e,t))return !1;if(!hl(e)||!hl(t))return !0;const i=r.get(Ef(e));if(!i)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 o=null;try{for(const a of i.h||[])if(o=Reflect.has(e,a)!==Reflect.has(t,a),o)return o;if(i[ga]===!0){if(o=((a,s)=>{const l=Reflect.ownKeys(a),c=Reflect.ownKeys(s);return l.length!==c.length||l.some((u,d)=>u!==c[d])})(e,t),o)return o}else for(const a of i.o||[])if(o=!!Reflect.getOwnPropertyDescriptor(e,a)!=!!Reflect.getOwnPropertyDescriptor(t,a),o)return o;for(const a of i.k||[])if(o=gg(e[a],t[a],r,n),o)return o;return o===null&&(o=!0),o}finally{n&&n.set(e,{n:t,g:o});}},NE=e=>pg(e)&&e[$f]||null,fv=(e,t=!0)=>{Xu.set(e,t);},IE=(e,t,r)=>{const n=[],i=new WeakSet,o=(a,s)=>{if(i.has(a))return;hl(a)&&i.add(a);const l=hl(a)&&t.get(Ef(a));if(l){var c,u;if((c=l.h)==null||c.forEach(h=>{const v=`:has(${String(h)})`;n.push(s?[...s,v]:[v]);}),l[ga]===!0){const h=":ownKeys";n.push(s?[...s,h]:[h]);}else {var d;(d=l.o)==null||d.forEach(h=>{const v=`:hasOwn(${String(h)})`;n.push(s?[...s,v]:[v]);});}(u=l.k)==null||u.forEach(h=>{r&&!("value"in(Object.getOwnPropertyDescriptor(a,h)||{}))||o(a[h],s?[...s,h]:[h]);});}else s&&n.push(s);};return o(e),n},Xc=e=>typeof e=="object"&&e!==null,ii=new WeakMap,xs=new WeakSet,AE=(e=Object.is,t=(c,u)=>new Proxy(c,u),r=c=>Xc(c)&&!xs.has(c)&&(Array.isArray(c)||!(Symbol.iterator in c))&&!(c instanceof WeakMap)&&!(c instanceof WeakSet)&&!(c instanceof Error)&&!(c instanceof Number)&&!(c instanceof Date)&&!(c instanceof String)&&!(c instanceof RegExp)&&!(c instanceof ArrayBuffer),n=c=>{switch(c.status){case"fulfilled":return c.value;case"rejected":throw c.reason;default:throw c}},i=new WeakMap,o=(c,u,d=n)=>{const h=i.get(c);if((h==null?void 0:h[0])===u)return h[1];const v=Array.isArray(c)?[]:Object.create(Object.getPrototypeOf(c));return fv(v,!0),i.set(c,[u,v]),Reflect.ownKeys(c).forEach(p=>{if(Object.getOwnPropertyDescriptor(v,p))return;const m=Reflect.get(c,p),g={value:m,enumerable:!0,configurable:!0};if(xs.has(m))fv(m,!1);else if(m instanceof Promise)delete g.value,g.get=()=>d(m);else if(ii.has(m)){const[b,w]=ii.get(m);g.value=o(b,w(),d);}Object.defineProperty(v,p,g);}),v},a=new WeakMap,s=[1,1],l=c=>{if(!Xc(c))throw new Error("object required");const u=a.get(c);if(u)return u;let d=s[0];const h=new Set,v=(R,P=++s[0])=>{d!==P&&(d=P,h.forEach(N=>N(R,P)));};let p=s[1];const m=(R=++s[1])=>(p!==R&&!h.size&&(p=R,b.forEach(([P])=>{const N=P[1](R);N>d&&(d=N);})),d),g=R=>(P,N)=>{const _=[...P];_[1]=[R,..._[1]],v(_,N);},b=new Map,w=(R,P)=>{if(({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&b.has(R))throw new Error("prop listener already exists");if(h.size){const N=P[3](g(R));b.set(R,[P,N]);}else b.set(R,[P]);},S=R=>{var P;const N=b.get(R);N&&(b.delete(R),(P=N[1])==null||P.call(N));},$=R=>(h.add(R),h.size===1&&b.forEach(([N,_],E)=>{if(({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&_)throw new Error("remove already exists");const O=N[3](g(E));b.set(E,[N,O]);}),()=>{h.delete(R),h.size===0&&b.forEach(([N,_],E)=>{_&&(_(),b.set(E,[N]));});}),x=Array.isArray(c)?[]:Object.create(Object.getPrototypeOf(c)),C=t(x,{deleteProperty(R,P){const N=Reflect.get(R,P);S(P);const _=Reflect.deleteProperty(R,P);return _&&v(["delete",[P],N]),_},set(R,P,N,_){const E=Reflect.has(R,P),O=Reflect.get(R,P,_);if(E&&(e(O,N)||a.has(N)&&e(O,a.get(N))))return !0;S(P),Xc(N)&&(N=NE(N)||N);let T=N;if(N instanceof Promise)N.then(A=>{N.status="fulfilled",N.value=A,v(["resolve",[P],A]);}).catch(A=>{N.status="rejected",N.reason=A,v(["reject",[P],A]);});else {!ii.has(N)&&r(N)&&(T=l(N));const A=!xs.has(T)&&ii.get(T);A&&w(P,A);}return Reflect.set(R,P,T,_),v(["set",[P],N,O]),!0}});a.set(c,C);const M=[x,m,o,$];return ii.set(C,M),Reflect.ownKeys(c).forEach(R=>{const P=Object.getOwnPropertyDescriptor(c,R);"value"in P&&(C[R]=c[R],delete P.value,delete P.writable),Object.defineProperty(x,R,P);}),C})=>[l,ii,xs,e,t,r,n,i,o,a,s],[kE]=AE();function ts(e={}){return kE(e)}function bg(e,t,r){const n=ii.get(e);({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&!n&&console.warn("Please use proxy object");let i;const o=[],a=n[3];let s=!1;const c=a(u=>{if(o.push(u),r){t(o.splice(0));return}i||(i=Promise.resolve().then(()=>{i=void 0,s&&t(o.splice(0));}));});return s=!0,()=>{s=!1,c();}}function hv(e,t){const r=ii.get(e);({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&!r&&console.warn("Please use proxy object");const[n,i,o]=r;return o(n,i(),t)}var yg={exports:{}},wg={};/** * @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 Po=f;function LE(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var FE=typeof Object.is=="function"?Object.is:LE,DE=Po.useState,jE=Po.useEffect,zE=Po.useLayoutEffect,HE=Po.useDebugValue;function WE(e,t){var r=t(),n=DE({inst:{value:r,getSnapshot:t}}),i=n[0].inst,o=n[1];return zE(function(){i.value=r,i.getSnapshot=t,Yc(i)&&o({inst:i});},[e,r,t]),jE(function(){return Yc(i)&&o({inst:i}),e(function(){Yc(i)&&o({inst:i});})},[e]),HE(r),r}function Yc(e){var t=e.getSnapshot;e=e.value;try{var r=t();return !FE(e,r)}catch{return !0}}function BE(e,t){return t()}var VE=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?BE:WE;wg.useSyncExternalStore=Po.useSyncExternalStore!==void 0?Po.useSyncExternalStore:VE;yg.exports=wg;var UE=yg.exports;const GE=Kn(UE),{use:vv}=f,{useSyncExternalStore:KE}=GE,qE=(e,t)=>{const r=f.useRef();f.useEffect(()=>{r.current=IE(e,t,!0);}),f.useDebugValue(r.current);},XE=new WeakMap;function ko(e,t){const r=t==null?void 0:t.sync,n=f.useRef(),i=f.useRef();let o=!0;const a=KE(f.useCallback(c=>{const u=bg(e,c,r);return c(),u},[e,r]),()=>{const c=hv(e,vv);try{if(!o&&n.current&&i.current&&!gg(n.current,c,i.current,new WeakMap))return n.current}catch{}return c},()=>hv(e,vv));o=!1;const s=new WeakMap;f.useEffect(()=>{n.current=a,i.current=s;}),({BASE_URL:"/",MODE:"production",DEV:!1,PROD:!0,SSR:!1}&&"production")!=="production"&&qE(a,s);const l=f.useMemo(()=>new WeakMap,[]);return mg(a,s,l,XE)}const _f={accessKey:"",useNarrowMode:!1,initialShowMore:!1,pureRecommend:!1,openInIINAWhenRightClick:!1,usePcDesktopApi:!1,useParallelRequest:!0,autoPreviewWhenKeyboardSelect:!1,autoPreviewUpdateInterval:400,autoPreviewWhenHover:!1,theme:"",filterMinPlayCountEnabled:!1,filterMinPlayCount:1e4,filterMinDurationEnabled:!1,filterMinDuration:60,enableFilterForFollowed:!1},et=ts({..._f}),Sg=Object.keys(_f),_n=function(){return ko(et)},YE=ui,Cg=`${YE}.settings`;function ZE(){const e=GM_getValue(Cg);e&&typeof e=="object"&&Object.assign(et,vg(e,Sg)),bg(et,()=>{QE();});}function QE(){const e=vg(et,Sg);GM_setValue(Cg,e);}function Fa(e){Object.assign(et,e);}function JE(){return Fa(_f)}ZE();var xg={exports:{}};(function(e,t){(function(r,n){e.exports=n();})(_m,function(){var r=1e3,n=6e4,i=36e5,o="millisecond",a="second",s="minute",l="hour",c="day",u="week",d="month",h="quarter",v="year",p="date",m="Invalid Date",g=/^(\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(E){var O=["th","st","nd","rd"],T=E%100;return "["+E+(O[(T-20)%10]||O[T]||O[0])+"]"}},S=function(E,O,T){var A=String(E);return !A||A.length>=O?E:""+Array(O+1-A.length).join(T)+E},$={s:S,z:function(E){var O=-E.utcOffset(),T=Math.abs(O),A=Math.floor(T/60),I=T%60;return (O<=0?"+":"-")+S(A,2,"0")+":"+S(I,2,"0")},m:function E(O,T){if(O.date()1)return E(j[0])}else {var B=O.name;y[B]=O,I=B;}return !A&&I&&(x=I),I||!A&&x},R=function(E,O){if(C(E))return E.clone();var T=typeof O=="object"?O:{};return T.date=E,T.args=arguments,new N(T)},P=$;P.l=M,P.i=C,P.w=function(E,O){return R(E,{locale:O.$L,utc:O.$u,x:O.$x,$offset:O.$offset})};var N=function(){function E(T){this.$L=M(T.locale,null,!0),this.parse(T);}var O=E.prototype;return O.parse=function(T){this.$d=function(A){var I=A.date,L=A.utc;if(I===null)return new Date(NaN);if(P.u(I))return new Date;if(I instanceof Date)return new Date(I);if(typeof I=="string"&&!/Z$/i.test(I)){var j=I.match(g);if(j){var B=j[2]-1||0,G=(j[7]||"0").substring(0,3);return L?new Date(Date.UTC(j[1],B,j[3]||1,j[4]||0,j[5]||0,j[6]||0,G)):new Date(j[1],B,j[3]||1,j[4]||0,j[5]||0,j[6]||0,G)}}return new Date(I)}(T),this.$x=T.x||{},this.init();},O.init=function(){var T=this.$d;this.$y=T.getFullYear(),this.$M=T.getMonth(),this.$D=T.getDate(),this.$W=T.getDay(),this.$H=T.getHours(),this.$m=T.getMinutes(),this.$s=T.getSeconds(),this.$ms=T.getMilliseconds();},O.$utils=function(){return P},O.isValid=function(){return this.$d.toString()!==m},O.isSame=function(T,A){var I=R(T);return this.startOf(A)<=I&&I<=this.endOf(A)},O.isAfter=function(T,A){return R(T)!!document.querySelectorAll(".bili-feed4").length),pv=document.querySelector(".bili-header__bar"),n_=!!(pv&&window.getComputedStyle(pv).display==="none"),Eg=n_?50:64,_g=()=>document.body.classList.contains("dark"),Pg=ts({value:_g()});function ac(){return ko(Pg).value}const Ks=new MutationObserver(function(){Pg.value=_g();});Ks.observe(document.body,{attributes:!0,attributeFilter:["class"]});window.addEventListener("unload",()=>{Ks==null||Ks.disconnect();});function $r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ot(e){"@babel/helpers - typeof";return ot=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},ot(e)}function i_(e,t){if(ot(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(ot(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}function Og(e){var t=i_(e,"string");return ot(t)==="symbol"?t:String(t)}function mv(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 ze(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function a_(e,t){if(t&&(ot(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ze(e)}function Fo(e){var t=o_();return function(){var n=vl(e),i;if(t){var o=vl(this).constructor;i=Reflect.construct(n,arguments,o);}else i=n.apply(this,arguments);return a_(this,i)}}var Tg={exports:{}};/*! 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=[],i=0;i1&&arguments[1]!==void 0?arguments[1]:{},r=[];return f.Children.forEach(e,function(n){n==null&&!t.keepEmpty||(Array.isArray(n)?r=r.concat(di(n)):vf.isFragment(n)&&n.props?r=r.concat(di(n.props.children,t)):r.push(n));}),r}var Zu={},l_=function(t){};function c_(e,t){}function u_(e,t){}function d_(){Zu={};}function Mg(e,t,r){!t&&!Zu[r]&&(e(!1,r),Zu[r]=!0);}function dr(e,t){Mg(c_,e,t);}function f_(e,t){Mg(u_,e,t);}dr.preMessage=l_;dr.resetWarned=d_;dr.noteOnce=f_;function H(e,t,r){return t=Og(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function gv(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n);}return r}function D(e){for(var t=1;t0},e.prototype.connect_=function(){!Qu||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),b_?(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(){!Qu||!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,i=g_.some(function(o){return !!~n.indexOf(o)});i&&this.refresh();},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),Ng=function(e,t){for(var r=0,n=Object.keys(t);r"u"||!(Element instanceof Object))){if(!(t instanceof Oo(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var r=this.observations_;r.has(t)||(r.set(t,new P_(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 Oo(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 O_(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}(),Ag=typeof WeakMap<"u"?new WeakMap:new Rg,kg=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=y_.getInstance(),n=new T_(t,r,this);Ag.set(this,n);}return e}();["observe","unobserve","disconnect"].forEach(function(e){kg.prototype[e]=function(){var t;return (t=Ag.get(this))[e].apply(t,arguments)};});var Lg=function(){return typeof gl.ResizeObserver<"u"?gl.ResizeObserver:kg}(),ai=new Map;function M_(e){e.forEach(function(t){var r,n=t.target;(r=ai.get(n))===null||r===void 0||r.forEach(function(i){return i(n)});});}var Fg=new Lg(M_);function R_(e,t){ai.has(e)||(ai.set(e,new Set),Fg.observe(e)),ai.get(e).add(t);}function N_(e,t){ai.has(e)&&(ai.get(e).delete(t),ai.get(e).size||(Fg.unobserve(e),ai.delete(e)));}var I_=function(e){Lo(r,e);var t=Fo(r);function r(){return $r(this,r),t.apply(this,arguments)}return Er(r,[{key:"render",value:function(){return this.props.children}}]),r}(f__namespace.Component),Ju=f__namespace.createContext(null);function A_(e){var t=e.children,r=e.onBatchResize,n=f__namespace.useRef(0),i=f__namespace.useRef([]),o=f__namespace.useContext(Ju),a=f__namespace.useCallback(function(s,l,c){n.current+=1;var u=n.current;i.current.push({size:s,element:l,data:c}),Promise.resolve().then(function(){u===n.current&&(r==null||r(i.current),i.current=[]);}),o==null||o(s,l,c);},[r,o]);return f__namespace.createElement(Ju.Provider,{value:a},t)}function k_(e,t){var r=e.children,n=e.disabled,i=f__namespace.useRef(null),o=f__namespace.useRef(null),a=f__namespace.useContext(Ju),s=typeof r=="function",l=s?r(i):r,c=f__namespace.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),u=!s&&f__namespace.isValidElement(l)&&fi(l),d=u?l.ref:null,h=f__namespace.useMemo(function(){return Kr(d,i)},[d,i]),v=function(){return ml(i.current)||ml(o.current)};f__namespace.useImperativeHandle(t,function(){return v()});var p=f__namespace.useRef(e);p.current=e;var m=f__namespace.useCallback(function(g){var b=p.current,w=b.onResize,S=b.data,$=g.getBoundingClientRect(),x=$.width,y=$.height,C=g.offsetWidth,M=g.offsetHeight,R=Math.floor(x),P=Math.floor(y);if(c.current.width!==R||c.current.height!==P||c.current.offsetWidth!==C||c.current.offsetHeight!==M){var N={width:R,height:P,offsetWidth:C,offsetHeight:M};c.current=N;var _=C===Math.round(x)?x:C,E=M===Math.round(y)?y:M,O=D(D({},N),{},{offsetWidth:_,offsetHeight:E});a==null||a(O,g,S),w&&Promise.resolve().then(function(){w(O,g);});}},[]);return f__namespace.useEffect(function(){var g=v();return g&&!n&&R_(g,m),function(){return N_(g,m)}},[i.current,n]),f__namespace.createElement(I_,{ref:o},u?f__namespace.cloneElement(l,{ref:h}):l)}var L_=f__namespace.forwardRef(k_),F_="rc-observer-key";function D_(e,t){var r=e.children,n=typeof r=="function"?[r]:di(r);return n.map(function(i,o){var a=(i==null?void 0:i.key)||"".concat(F_,"-").concat(o);return f__namespace.createElement(L_,Ce({},e,{key:a,ref:o===0?t:void 0}),i)})}var Ai=f__namespace.forwardRef(D_);Ai.Collection=A_;function uc(e,t){var r=D({},e);return Array.isArray(t)&&t.forEach(function(n){delete r[n];}),r}function ed(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=4;++n,i-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16);}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}function H_(e,t){if(e==null)return {};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}function Xe(e,t){if(e==null)return {};var r=H_(e,t),n,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n]);}return r}function rs(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=new Set;function i(o,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,l=n.has(o);if(dr(!l,"Warning: There may be circular references"),l)return !1;if(o===a)return !0;if(r&&s>1)return !1;n.add(o);var c=s+1;if(Array.isArray(o)){if(!Array.isArray(a)||o.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):U_}function dc(e){if(e.attachTo)return e.attachTo;var t=document.querySelector("head");return t||document.body}function G_(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function zg(e){return Array.from((rd.get(e)||e).children).filter(function(t){return t.tagName==="STYLE"})}function Hg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!Sr())return null;var r=t.csp,n=t.prepend,i=document.createElement("style");i.setAttribute(yv,G_(n)),r!=null&&r.nonce&&(i.nonce=r==null?void 0:r.nonce),i.innerHTML=e;var o=dc(t),a=o.firstChild;if(n){if(n==="queue"){var s=zg(o).filter(function(l){return ["prepend","prependQueue"].includes(l.getAttribute(yv))});if(s.length)return o.insertBefore(i,s[s.length-1].nextSibling),i}o.insertBefore(i,a);}else o.appendChild(i);return i}function Wg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=dc(t);return zg(r).find(function(n){return n.getAttribute(jg(t))===e})}function yl(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=Wg(e,t);if(r){var n=dc(t);n.removeChild(r);}}function K_(e,t){var r=rd.get(e);if(!r||!ba(document,r)){var n=Hg("",t),i=n.parentNode;rd.set(e,i),e.removeChild(n);}}function To(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=dc(r);K_(n,r);var i=Wg(t,r);if(i){var o,a;if((o=r.csp)!==null&&o!==void 0&&o.nonce&&i.nonce!==((a=r.csp)===null||a===void 0?void 0:a.nonce)){var s;i.nonce=(s=r.csp)===null||s===void 0?void 0:s.nonce;}return i.innerHTML!==e&&(i.innerHTML=e),i}var l=Hg(e,r);return l.setAttribute(jg(r),t),l}function wl(e){var t="";return Object.keys(e).forEach(function(r){var n=e[r];t+=r,n&&ot(n)==="object"?t+=wl(n):t+=n;}),t}function q_(e,t){return Tf("".concat(t,"_").concat(wl(e)))}var ya="layer-".concat(Date.now(),"-").concat(Math.random()).replace(/\./g,""),Bg="903px";function X_(e,t){if(Sr()){var r;To(e,ya);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 i=getComputedStyle(n).width===Bg;return (r=n.parentNode)===null||r===void 0||r.removeChild(n),yl(ya),i}return !1}var Zc=void 0;function Y_(){return Zc===void 0&&(Zc=X_("@layer ".concat(ya," { .").concat(ya," { width: ").concat(Bg,"!important; } }"),function(e){e.className=ya;})),Zc}function Vg(e){if(Array.isArray(e))return e}function Z_(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,o,a,s=[],l=!0,c=!1;try{if(o=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1;}else for(;!(l=(n=o.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(u){c=!0,i=u;}finally{try{if(!l&&r.return!=null&&(a=r.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}}function Ug(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function W(e,t){return Vg(e)||Z_(e,t)||Of(e,t)||Ug()}function Gg(e,t,r,n){var i=f__namespace.useContext(Mf),o=i.cache,a=[e].concat(le(t));return f__namespace.useMemo(function(){o.update(a,function(s){var l=s||[],c=W(l,2),u=c[0],d=u===void 0?0:u,h=c[1],v=h,p=v||r();return [d+1,p]});},[a.join("_")]),f__namespace.useEffect(function(){return function(){o.update(a,function(s){var l=s||[],c=W(l,2),u=c[0],d=u===void 0?0:u,h=c[1],v=d-1;return v===0?(n==null||n(h,!1),null):[d-1,h]});}},a),o.get(a)[1]}var Q_={},J_="css",wi=new Map;function eP(e){wi.set(e,(wi.get(e)||0)+1);}function tP(e,t){if(typeof document<"u"){var r=document.querySelectorAll("style[".concat(td,'="').concat(e,'"]'));r.forEach(function(n){if(n[so]===t){var i;(i=n.parentNode)===null||i===void 0||i.removeChild(n);}});}}function rP(e,t){wi.set(e,(wi.get(e)||0)-1);var r=Array.from(wi.keys()),n=r.filter(function(i){var o=wi.get(i)||0;return o<=0});n.length2&&arguments[2]!==void 0?arguments[2]:{},n=f.useContext(Mf),i=n.cache.instanceId,o=r.salt,a=o===void 0?"":o,s=r.override,l=s===void 0?Q_:s,c=r.formatToken,u=f__namespace.useMemo(function(){return Object.assign.apply(Object,[{}].concat(le(t)))},[t]),d=f__namespace.useMemo(function(){return wl(u)},[u]),h=f__namespace.useMemo(function(){return wl(l)},[l]),v=Gg("token",[a,e.id,d,h],function(){var p=e.getDerivativeToken(u),m=D(D({},p),l);c&&(m=c(m));var g=q_(m,a);m._tokenKey=g,eP(g);var b="".concat(J_,"-").concat(Tf(g));return m._hashId=b,[m,b]},function(p){rP(p[0]._tokenKey,i);});return v}var iP={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},wv=Sr(),oP="_skip_check_",Kg="_multi_value_";function Sv(e){var t=Ti(km(e),Lm);return t.replace(/\{%%%\:[^;];}/g,";")}function aP(e){return ot(e)==="object"&&e&&(oP in e||Kg in e)}function sP(e,t,r){if(!t)return e;var n=".".concat(t),i=r==="low"?":where(".concat(n,")"):n,o=e.split(",").map(function(a){var s,l=a.trim().split(/\s+/),c=l[0]||"",u=((s=c.match(/^\w+/))===null||s===void 0?void 0:s[0])||"";return c="".concat(u).concat(i).concat(c.slice(u.length)),[c].concat(le(l.slice(1))).join(" ")});return o.join(",")}var lP=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:[]},i=n.root,o=n.injectHash,a=n.parentSelectors,s=r.hashId,l=r.layer;r.path;var c=r.hashPriority,u=r.transformers,d=u===void 0?[]:u;r.linters;var h="",v={};function p(S){var $=S.getName(s);if(!v[$]){var x=e(S.style,r,{root:!1,parentSelectors:a}),y=W(x,1),C=y[0];v[$]="@keyframes ".concat(S.getName(s)).concat(C);}}function m(S){var $=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return S.forEach(function(x){Array.isArray(x)?m(x,$):x&&$.push(x);}),$}var g=m(Array.isArray(t)?t:[t]);if(g.forEach(function(S){var $=typeof S=="string"&&!i?{}:S;if(typeof $=="string")h+="".concat($,` `);else if($._keyframe)p($);else {var x=d.reduce(function(y,C){var M;return (C==null||(M=C.visit)===null||M===void 0?void 0:M.call(C,y))||y},$);Object.keys(x).forEach(function(y){var C=x[y];if(ot(C)==="object"&&C&&(y!=="animationName"||!C._keyframe)&&!aP(C)){var M=!1,R=y.trim(),P=!1;(i||o)&&s?R.startsWith("@")?M=!0:R=sP(y,s,c):i&&!s&&(R==="&"||R==="")&&(R="",P=!0);var N=e(C,r,{root:P,injectHash:M,parentSelectors:[].concat(le(a),[R])}),_=W(N,2),E=_[0],O=_[1];v=D(D({},v),O),h+="".concat(R).concat(E);}else {let I=function(L,j){var B=L.replace(/[A-Z]/g,function(z){return "-".concat(z.toLowerCase())}),G=j;!iP[L]&&typeof G=="number"&&G!==0&&(G="".concat(G,"px")),L==="animationName"&&j!==null&&j!==void 0&&j._keyframe&&(p(j),G=j.getName(s)),h+="".concat(B,":").concat(G,";");};var T,A=(T=C==null?void 0:C.value)!==null&&T!==void 0?T:C;ot(C)==="object"&&C!==null&&C!==void 0&&C[Kg]&&Array.isArray(A)?A.forEach(function(L){I(y,L);}):I(y,A);}});}}),!i)h="{".concat(h,"}");else if(l&&Y_()){var b=l.split(","),w=b[b.length-1].trim();h="@layer ".concat(w," {").concat(h,"}"),b.length>1&&(h="@layer ".concat(l,"{%%%:%}").concat(h));}return [h,v]};function cP(e,t){return Tf("".concat(e.join("%")).concat(t))}function uP(){return null}function nd(e,t){var r=e.token,n=e.path,i=e.hashId,o=e.layer,a=e.nonce,s=f__namespace.useContext(Mf),l=s.autoClear;s.mock;var c=s.defaultCache,u=s.hashPriority,d=s.container,h=s.ssrInline,v=s.transformers,p=s.linters,m=s.cache,g=r._tokenKey,b=[g].concat(le(n)),w=wv,S=Gg("style",b,function(){var M=t(),R=lP(M,{hashId:i,hashPriority:u,layer:o,path:n.join("-"),transformers:v,linters:p}),P=W(R,2),N=P[0],_=P[1],E=Sv(N),O=cP(b,E);if(w){var T={mark:vo,prepend:"queue",attachTo:d},A=typeof a=="function"?a():a;A&&(T.csp={nonce:A});var I=To(E,O,T);I[so]=m.instanceId,I.setAttribute(td,g),Object.keys(_).forEach(function(L){To(Sv(_[L]),"_effect-".concat(L),T);});}return [E,g,O]},function(M,R){var P=W(M,3),N=P[2];(R||l)&&wv&&yl(N,{mark:vo});}),$=W(S,3),x=$[0],y=$[1],C=$[2];return function(M){var R;if(!h||w||!c)R=f__namespace.createElement(uP,null);else {var P;R=f__namespace.createElement("style",Ce({},(P={},H(P,td,y),H(P,vo,C),P),{dangerouslySetInnerHTML:{__html:x}}));}return f__namespace.createElement(f__namespace.Fragment,null,R,M)}}var Dt=function(){function e(t,r){$r(this,e),H(this,"name",void 0),H(this,"style",void 0),H(this,"_keyframe",!0),this.name=t,this.style=r;}return Er(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 dP(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 l,c;a=(l=a)===null||l===void 0||(c=l.map)===null||c===void 0?void 0:c.get(s);}}),(n=a)!==null&&n!==void 0&&n.value&&o&&(a.value[1]=this.cacheCallTimes++),(i=a)===null||i===void 0?void 0:i.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 i=this;if(!this.has(r)){if(this.size()+1>e.MAX_CACHE_SIZE+e.MAX_CACHE_OFFSET){var o=this.keys.reduce(function(c,u){var d=W(c,2),h=d[1];return i.internalGet(u)[1]0,void 0),Cv+=1;}return Er(e,[{key:"getDerivativeToken",value:function(r){return this.derivatives.reduce(function(n,i){return i(r,n)},void 0)}}]),e}(),Qc=new Rf;function qg(e){var t=Array.isArray(e)?e:[e];return Qc.has(t)||Qc.set(t,new fP(t)),Qc.get(t)}function Ki(e){return e.notSplit=!0,e}Ki(["borderTop","borderBottom"]),Ki(["borderTop"]),Ki(["borderBottom"]),Ki(["borderLeft","borderRight"]),Ki(["borderLeft"]),Ki(["borderRight"]);var hP=f.createContext({});const Nf=hP;var Ci="RC_FORM_INTERNAL_HOOKS",bt=function(){dr(!1,"Can not find FormContext. Please make sure you wrap Field under Form.");},Mo=f__namespace.createContext({getFieldValue:bt,getFieldsValue:bt,getFieldError:bt,getFieldWarning:bt,getFieldsError:bt,isFieldsTouched:bt,isFieldTouched:bt,isFieldValidating:bt,isFieldsValidating:bt,resetFields:bt,setFields:bt,setFieldValue:bt,setFieldsValue:bt,validateFields:bt,submit:bt,getInternalHooks:function(){return bt(),{dispatch:bt,initEntityValue:bt,registerField:bt,useSubscribe:bt,setInitialValues:bt,destroyForm:bt,setCallbacks:bt,registerWatch:bt,getFields:bt,setValidateMessages:bt,setPreserve:bt,getInitialValue:bt}}}),id=f__namespace.createContext(null);function od(e){return e==null?[]:Array.isArray(e)?e:[e]}function vP(e){return e&&!!e._init}function pr(){pr=function(){return e};var e={},t=Object.prototype,r=t.hasOwnProperty,n=Object.defineProperty||function(_,E,O){_[E]=O.value;},i=typeof Symbol=="function"?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function l(_,E,O){return Object.defineProperty(_,E,{value:O,enumerable:!0,configurable:!0,writable:!0}),_[E]}try{l({},"");}catch{l=function(O,T,A){return O[T]=A};}function c(_,E,O,T){var A=E&&E.prototype instanceof h?E:h,I=Object.create(A.prototype),L=new R(T||[]);return n(I,"_invoke",{value:x(_,O,L)}),I}function u(_,E,O){try{return {type:"normal",arg:_.call(E,O)}}catch(T){return {type:"throw",arg:T}}}e.wrap=c;var d={};function h(){}function v(){}function p(){}var m={};l(m,o,function(){return this});var g=Object.getPrototypeOf,b=g&&g(g(P([])));b&&b!==t&&r.call(b,o)&&(m=b);var w=p.prototype=h.prototype=Object.create(m);function S(_){["next","throw","return"].forEach(function(E){l(_,E,function(O){return this._invoke(E,O)});});}function $(_,E){function O(A,I,L,j){var B=u(_[A],_,I);if(B.type!=="throw"){var G=B.arg,z=G.value;return z&&ot(z)=="object"&&r.call(z,"__await")?E.resolve(z.__await).then(function(V){O("next",V,L,j);},function(V){O("throw",V,L,j);}):E.resolve(z).then(function(V){G.value=V,L(G);},function(V){return O("throw",V,L,j)})}j(B.arg);}var T;n(this,"_invoke",{value:function(I,L){function j(){return new E(function(B,G){O(I,L,B,G);})}return T=T?T.then(j,j):j()}});}function x(_,E,O){var T="suspendedStart";return function(A,I){if(T==="executing")throw new Error("Generator is already running");if(T==="completed"){if(A==="throw")throw I;return N()}for(O.method=A,O.arg=I;;){var L=O.delegate;if(L){var j=y(L,O);if(j){if(j===d)continue;return j}}if(O.method==="next")O.sent=O._sent=O.arg;else if(O.method==="throw"){if(T==="suspendedStart")throw T="completed",O.arg;O.dispatchException(O.arg);}else O.method==="return"&&O.abrupt("return",O.arg);T="executing";var B=u(_,E,O);if(B.type==="normal"){if(T=O.done?"completed":"suspendedYield",B.arg===d)continue;return {value:B.arg,done:O.done}}B.type==="throw"&&(T="completed",O.method="throw",O.arg=B.arg);}}}function y(_,E){var O=E.method,T=_.iterator[O];if(T===void 0)return E.delegate=null,O==="throw"&&_.iterator.return&&(E.method="return",E.arg=void 0,y(_,E),E.method==="throw")||O!=="return"&&(E.method="throw",E.arg=new TypeError("The iterator does not provide a '"+O+"' method")),d;var A=u(T,_.iterator,E.arg);if(A.type==="throw")return E.method="throw",E.arg=A.arg,E.delegate=null,d;var I=A.arg;return I?I.done?(E[_.resultName]=I.value,E.next=_.nextLoc,E.method!=="return"&&(E.method="next",E.arg=void 0),E.delegate=null,d):I:(E.method="throw",E.arg=new TypeError("iterator result is not an object"),E.delegate=null,d)}function C(_){var E={tryLoc:_[0]};1 in _&&(E.catchLoc=_[1]),2 in _&&(E.finallyLoc=_[2],E.afterLoc=_[3]),this.tryEntries.push(E);}function M(_){var E=_.completion||{};E.type="normal",delete E.arg,_.completion=E;}function R(_){this.tryEntries=[{tryLoc:"root"}],_.forEach(C,this),this.reset(!0);}function P(_){if(_){var E=_[o];if(E)return E.call(_);if(typeof _.next=="function")return _;if(!isNaN(_.length)){var O=-1,T=function A(){for(;++O<_.length;)if(r.call(_,O))return A.value=_[O],A.done=!1,A;return A.value=void 0,A.done=!0,A};return T.next=T}}return {next:N}}function N(){return {value:void 0,done:!0}}return v.prototype=p,n(w,"constructor",{value:p,configurable:!0}),n(p,"constructor",{value:v,configurable:!0}),v.displayName=l(p,s,"GeneratorFunction"),e.isGeneratorFunction=function(_){var E=typeof _=="function"&&_.constructor;return !!E&&(E===v||(E.displayName||E.name)==="GeneratorFunction")},e.mark=function(_){return Object.setPrototypeOf?Object.setPrototypeOf(_,p):(_.__proto__=p,l(_,s,"GeneratorFunction")),_.prototype=Object.create(w),_},e.awrap=function(_){return {__await:_}},S($.prototype),l($.prototype,a,function(){return this}),e.AsyncIterator=$,e.async=function(_,E,O,T,A){A===void 0&&(A=Promise);var I=new $(c(_,E,O,T),A);return e.isGeneratorFunction(E)?I:I.next().then(function(L){return L.done?L.value:I.next()})},S(w),l(w,s,"Generator"),l(w,o,function(){return this}),l(w,"toString",function(){return "[object Generator]"}),e.keys=function(_){var E=Object(_),O=[];for(var T in E)O.push(T);return O.reverse(),function A(){for(;O.length;){var I=O.pop();if(I in E)return A.value=I,A.done=!1,A}return A.done=!0,A}},e.values=P,R.prototype={constructor:R,reset:function(E){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(M),!E)for(var O in this)O.charAt(0)==="t"&&r.call(this,O)&&!isNaN(+O.slice(1))&&(this[O]=void 0);},stop:function(){this.done=!0;var E=this.tryEntries[0].completion;if(E.type==="throw")throw E.arg;return this.rval},dispatchException:function(E){if(this.done)throw E;var O=this;function T(G,z){return L.type="throw",L.arg=E,O.next=G,z&&(O.method="next",O.arg=void 0),!!z}for(var A=this.tryEntries.length-1;A>=0;--A){var I=this.tryEntries[A],L=I.completion;if(I.tryLoc==="root")return T("end");if(I.tryLoc<=this.prev){var j=r.call(I,"catchLoc"),B=r.call(I,"finallyLoc");if(j&&B){if(this.prev=0;--T){var A=this.tryEntries[T];if(A.tryLoc<=this.prev&&r.call(A,"finallyLoc")&&this.prev=0;--O){var T=this.tryEntries[O];if(T.finallyLoc===E)return this.complete(T.completion,T.afterLoc),M(T),d}},catch:function(E){for(var O=this.tryEntries.length-1;O>=0;--O){var T=this.tryEntries[O];if(T.tryLoc===E){var A=T.completion;if(A.type==="throw"){var I=A.arg;M(T);}return I}}throw new Error("illegal catch attempt")},delegateYield:function(E,O,T){return this.delegate={iterator:P(E),resultName:O,nextLoc:T},this.method==="next"&&(this.arg=void 0),d}},e}function xv(e,t,r,n,i,o,a){try{var s=e[o](a),l=s.value;}catch(c){r(c);return}s.done?t(l):Promise.resolve(l).then(n,i);}function Fi(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function a(l){xv(o,n,i,a,s,"next",l);}function s(l){xv(o,n,i,a,s,"throw",l);}a(void 0);})}}function xi(){return xi=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 qs(e,t,r){return mP()?qs=Reflect.construct.bind():qs=function(i,o,a){var s=[null];s.push.apply(s,o);var l=Function.bind.apply(i,s),c=new l;return a&&ja(c,a.prototype),c},qs.apply(null,arguments)}function gP(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function sd(e){var t=typeof Map=="function"?new Map:void 0;return sd=function(n){if(n===null||!gP(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,i);}function i(){return qs(n,arguments,ad(this).constructor)}return i.prototype=Object.create(n.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),ja(i,n)},sd(e)}var bP=/%[sdj%]/g,yP=function(){};typeof process<"u"&&process.env;function ld(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 Fr(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n=o)return s;switch(s){case"%s":return String(r[i++]);case"%d":return Number(r[i++]);case"%j":try{return JSON.stringify(r[i++])}catch{return "[Circular]"}break;default:return s}});return a}return e}function wP(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Zt(e,t){return !!(e==null||t==="array"&&Array.isArray(e)&&!e.length||wP(t)&&typeof e=="string"&&!e)}function SP(e,t,r){var n=[],i=0,o=e.length;function a(s){n.push.apply(n,s||[]),i++,i===o&&r(n);}e.forEach(function(s){t(s,a);});}function $v(e,t,r){var n=0,i=e.length;function o(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},ua={integer:function(t){return ua.number(t)&&parseInt(t,10)===t},float:function(t){return ua.number(t)&&!ua.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"&&!ua.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(Ov.email)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(PP())},hex:function(t){return typeof t=="string"&&!!t.match(Ov.hex)}},OP=function(t,r,n,i,o){if(t.required&&r===void 0){Xg(t,r,n,i,o);return}var a=["integer","float","array","regexp","object","method","email","number","date","url","hex"],s=t.type;a.indexOf(s)>-1?ua[s](r)||i.push(Fr(o.messages.types[s],t.fullField,t.type)):s&&typeof r!==t.type&&i.push(Fr(o.messages.types[s],t.fullField,t.type));},TP=function(t,r,n,i,o){var a=typeof t.len=="number",s=typeof t.min=="number",l=typeof t.max=="number",c=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,u=r,d=null,h=typeof r=="number",v=typeof r=="string",p=Array.isArray(r);if(h?d="number":v?d="string":p&&(d="array"),!d)return !1;p&&(u=r.length),v&&(u=r.replace(c,"_").length),a?u!==t.len&&i.push(Fr(o.messages[d].len,t.fullField,t.len)):s&&!l&&ut.max?i.push(Fr(o.messages[d].max,t.fullField,t.max)):s&&l&&(ut.max)&&i.push(Fr(o.messages[d].range,t.fullField,t.min,t.max));},qi="enum",MP=function(t,r,n,i,o){t[qi]=Array.isArray(t[qi])?t[qi]:[],t[qi].indexOf(r)===-1&&i.push(Fr(o.messages[qi],t.fullField,t[qi].join(", ")));},RP=function(t,r,n,i,o){if(t.pattern){if(t.pattern instanceof RegExp)t.pattern.lastIndex=0,t.pattern.test(r)||i.push(Fr(o.messages.pattern.mismatch,t.fullField,r,t.pattern));else if(typeof t.pattern=="string"){var a=new RegExp(t.pattern);a.test(r)||i.push(Fr(o.messages.pattern.mismatch,t.fullField,r,t.pattern));}}},Je={required:Xg,whitespace:_P,type:OP,range:TP,enum:MP,pattern:RP},NP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r,"string")&&!t.required)return n();Je.required(t,r,i,a,o,"string"),Zt(r,"string")||(Je.type(t,r,i,a,o),Je.range(t,r,i,a,o),Je.pattern(t,r,i,a,o),t.whitespace===!0&&Je.whitespace(t,r,i,a,o));}n(a);},IP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&Je.type(t,r,i,a,o);}n(a);},AP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(r===""&&(r=void 0),Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&(Je.type(t,r,i,a,o),Je.range(t,r,i,a,o));}n(a);},kP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&Je.type(t,r,i,a,o);}n(a);},LP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),Zt(r)||Je.type(t,r,i,a,o);}n(a);},FP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&(Je.type(t,r,i,a,o),Je.range(t,r,i,a,o));}n(a);},DP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&(Je.type(t,r,i,a,o),Je.range(t,r,i,a,o));}n(a);},jP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(r==null&&!t.required)return n();Je.required(t,r,i,a,o,"array"),r!=null&&(Je.type(t,r,i,a,o),Je.range(t,r,i,a,o));}n(a);},zP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&Je.type(t,r,i,a,o);}n(a);},HP="enum",WP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o),r!==void 0&&Je[HP](t,r,i,a,o);}n(a);},BP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r,"string")&&!t.required)return n();Je.required(t,r,i,a,o),Zt(r,"string")||Je.pattern(t,r,i,a,o);}n(a);},VP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r,"date")&&!t.required)return n();if(Je.required(t,r,i,a,o),!Zt(r,"date")){var l;r instanceof Date?l=r:l=new Date(r),Je.type(t,l,i,a,o),l&&Je.range(t,l.getTime(),i,a,o);}}n(a);},UP=function(t,r,n,i,o){var a=[],s=Array.isArray(r)?"array":typeof r;Je.required(t,r,i,a,o,s),n(a);},Jc=function(t,r,n,i,o){var a=t.type,s=[],l=t.required||!t.required&&i.hasOwnProperty(t.field);if(l){if(Zt(r,a)&&!t.required)return n();Je.required(t,r,i,s,o,a),Zt(r,a)||Je.type(t,r,i,s,o);}n(s);},GP=function(t,r,n,i,o){var a=[],s=t.required||!t.required&&i.hasOwnProperty(t.field);if(s){if(Zt(r)&&!t.required)return n();Je.required(t,r,i,a,o);}n(a);},wa={string:NP,method:IP,number:AP,boolean:kP,regexp:LP,integer:FP,float:DP,array:jP,object:zP,enum:WP,pattern:BP,date:VP,url:Jc,hex:Jc,email:Jc,required:UP,any:GP};function cd(){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 ud=cd(),ns=function(){function e(r){this.rules=null,this._messages=ud,this.define(r);}var t=e.prototype;return t.define=function(n){var i=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(o){var a=n[o];i.rules[o]=Array.isArray(a)?a:[a];});},t.messages=function(n){return n&&(this._messages=Pv(cd(),n)),this._messages},t.validate=function(n,i,o){var a=this;i===void 0&&(i={}),o===void 0&&(o=function(){});var s=n,l=i,c=o;if(typeof l=="function"&&(c=l,l={}),!this.rules||Object.keys(this.rules).length===0)return c&&c(null,s),Promise.resolve(s);function u(m){var g=[],b={};function w($){if(Array.isArray($)){var x;g=(x=g).concat.apply(x,$);}else g.push($);}for(var S=0;S3&&arguments[3]!==void 0?arguments[3]:!1;return t.length&&n&&r===void 0&&!Fn(e,t.slice(0,-1))?e:Zg(e,t,r,n)}function fc(e){return Array.isArray(e)?XP(e):ot(e)==="object"&&e!==null?qP(e):e}function qP(e){if(Object.getPrototypeOf(e)===Object.prototype){var t={};for(var r in e)t[r]=fc(e[r]);return t}return e}function XP(e){return e.map(function(t){return fc(t)})}function Ht(e){return od(e)}function Tv(e,t){var r={};return t.forEach(function(n){var i=Fn(e,n);r=ei(r,n,i);}),r}function Sa(e,t){return e&&e.some(function(r){return Jg(r,t)})}function Mv(e){return ot(e)==="object"&&e!==null&&Object.getPrototypeOf(e)===Object.prototype}function Qg(e,t){var r=Array.isArray(e)?le(e):D({},e);return t&&Object.keys(t).forEach(function(n){var i=r[n],o=t[n],a=Mv(i)&&Mv(o);r[n]=a?Qg(i,o||{}):fc(o);}),r}function Ca(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 i=e[t],o=t-r;return o>0?[].concat(le(e.slice(0,r)),[i],le(e.slice(r,t)),le(e.slice(t+1,n))):o<0?[].concat(le(e.slice(0,t)),le(e.slice(t+1,r+1)),[i],le(e.slice(r+1,n))):e}var Nv=ns;function QP(e,t){return e.replace(/\$\{\w+\}/g,function(r){var n=r.slice(2,-1);return t[n]})}var Iv="CODE_LOGIC_ERROR";function dd(e,t,r,n,i){return fd.apply(this,arguments)}function fd(){return fd=Fi(pr().mark(function e(t,r,n,i,o){var a,s,l,c,u,d,h,v,p;return pr().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return a=D({},n),delete a.ruleIndex,Nv.warning=function(){},a.validator&&(s=a.validator,a.validator=function(){try{return s.apply(void 0,arguments)}catch(b){return console.error(b),Promise.reject(Iv)}}),l=null,a&&a.type==="array"&&a.defaultField&&(l=a.defaultField,delete a.defaultField),c=new Nv(H({},t,[a])),u=Ca({},Yg,i.validateMessages),c.messages(u),d=[],g.prev=10,g.next=13,Promise.resolve(c.validate(H({},t,r),D({},i)));case 13:g.next=18;break;case 15:g.prev=15,g.t0=g.catch(10),g.t0.errors&&(d=g.t0.errors.map(function(b,w){var S=b.message,$=S===Iv?u.default:S;return f__namespace.isValidElement($)?f__namespace.cloneElement($,{key:"error_".concat(w)}):$}));case 18:if(!(!d.length&&l)){g.next=23;break}return g.next=21,Promise.all(r.map(function(b,w){return dd("".concat(t,".").concat(w),b,l,i,o)}));case 21:return h=g.sent,g.abrupt("return",h.reduce(function(b,w){return [].concat(le(b),le(w))},[]));case 23:return v=D(D({},n),{},{name:t,enum:(n.enum||[]).join(", ")},o),p=d.map(function(b){return typeof b=="string"?QP(b,v):b}),g.abrupt("return",p);case 26:case"end":return g.stop()}},e,null,[[10,15]])})),fd.apply(this,arguments)}function JP(e,t,r,n,i,o){var a=e.join("."),s=r.map(function(u,d){var h=u.validator,v=D(D({},u),{},{ruleIndex:d});return h&&(v.validator=function(p,m,g){var b=!1,w=function(){for(var x=arguments.length,y=new Array(x),C=0;C0&&arguments[0]!==void 0?arguments[0]:Hr;if(i.validatePromise===m){var C;i.validatePromise=null;var M=[],R=[];(C=y.forEach)===null||C===void 0||C.call(y,function(P){var N=P.rule.warningOnly,_=P.errors,E=_===void 0?Hr:_;N?R.push.apply(R,le(E)):M.push.apply(M,le(E));}),i.errors=M,i.warnings=R,i.triggerMetaEvent(),i.reRender();}}),x});return p||(i.validatePromise=m,i.dirty=!0,i.errors=Hr,i.warnings=Hr,i.triggerMetaEvent(),i.reRender()),m},i.isFieldValidating=function(){return !!i.validatePromise},i.isFieldTouched=function(){return i.touched},i.isFieldDirty=function(){if(i.dirty||i.props.initialValue!==void 0)return !0;var l=i.props.fieldContext,c=l.getInternalHooks(Ci),u=c.getInitialValue;return u(i.getNamePath())!==void 0},i.getErrors=function(){return i.errors},i.getWarnings=function(){return i.warnings},i.isListField=function(){return i.props.isListField},i.isList=function(){return i.props.isList},i.isPreserve=function(){return i.props.preserve},i.getMeta=function(){i.prevValidating=i.isFieldValidating();var l={touched:i.isFieldTouched(),validating:i.prevValidating,errors:i.errors,warnings:i.warnings,name:i.getNamePath(),validated:i.validatePromise===null};return l},i.getOnlyChild=function(l){if(typeof l=="function"){var c=i.getMeta();return D(D({},i.getOnlyChild(l(i.getControlled(),c,i.props.fieldContext))),{},{isFunction:!0})}var u=di(l);return u.length!==1||!f__namespace.isValidElement(u[0])?{child:u,isFunction:!1}:{child:u[0],isFunction:!1}},i.getValue=function(l){var c=i.props.fieldContext.getFieldsValue,u=i.getNamePath();return Fn(l||c(!0),u)},i.getControlled=function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},c=i.props,u=c.trigger,d=c.validateTrigger,h=c.getValueFromEvent,v=c.normalize,p=c.valuePropName,m=c.getValueProps,g=c.fieldContext,b=d!==void 0?d:g.validateTrigger,w=i.getNamePath(),S=g.getInternalHooks,$=g.getFieldsValue,x=S(Ci),y=x.dispatch,C=i.getValue(),M=m||function(_){return H({},p,_)},R=l[u],P=D(D({},l),M(C));P[u]=function(){i.touched=!0,i.dirty=!0,i.triggerMetaEvent();for(var _,E=arguments.length,O=new Array(E),T=0;T=0&&N<=_.length?(d.keys=[].concat(le(d.keys.slice(0,N)),[d.id],le(d.keys.slice(N))),$([].concat(le(_.slice(0,N)),[P],le(_.slice(N))))):(d.keys=[].concat(le(d.keys),[d.id]),$([].concat(le(_),[P]))),d.id+=1;},remove:function(P){var N=y(),_=new Set(Array.isArray(P)?P:[P]);_.size<=0||(d.keys=d.keys.filter(function(E,O){return !_.has(O)}),$(N.filter(function(E,O){return !_.has(O)})));},move:function(P,N){if(P!==N){var _=y();P<0||P>=_.length||N<0||N>=_.length||(d.keys=Rv(d.keys,P,N),$(Rv(_,P,N)));}}},M=S||[];return Array.isArray(M)||(M=[]),i(M.map(function(R,P){var N=d.keys[P];return N===void 0&&(d.keys[P]=d.id,N=d.keys[P],d.id+=1),{name:P,key:N,isListField:!0}}),C,b)})))};function iO(e){var t=!1,r=e.length,n=[];return e.length?new Promise(function(i,o){e.forEach(function(a,s){a.catch(function(l){return t=!0,l}).then(function(l){r-=1,n[s]=l,!(r>0)&&(t&&o(n),i(n));});});}):Promise.resolve([])}var tb="__@field_split__";function eu(e){return e.map(function(t){return "".concat(ot(t),":").concat(t)}).join(tb)}var Xi=function(){function e(){$r(this,e),this.kvs=new Map;}return Er(e,[{key:"set",value:function(r,n){this.kvs.set(eu(r),n);}},{key:"get",value:function(r){return this.kvs.get(eu(r))}},{key:"update",value:function(r,n){var i=this.get(r),o=n(i);o?this.set(r,o):this.delete(r);}},{key:"delete",value:function(r){this.kvs.delete(eu(r));}},{key:"map",value:function(r){return le(this.kvs.entries()).map(function(n){var i=W(n,2),o=i[0],a=i[1],s=o.split(tb);return r({key:s.map(function(l){var c=l.match(/^([^:]*):(.*)$/),u=W(c,3),d=u[1],h=u[2];return d==="number"?Number(h):h}),value:a})})}},{key:"toJSON",value:function(){var r={};return this.map(function(n){var i=n.key,o=n.value;return r[i.join(".")]=o,null}),r}}]),e}(),oO=["name"],aO=Er(function e(t){var r=this;$r(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===Ci?(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}):(dr(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)},this.useSubscribe=function(n){r.subscribable=n;},this.prevWithoutPreserves=null,this.setInitialValues=function(n,i){if(r.initialValues=n||{},i){var o,a=Ca({},n,r.store);(o=r.prevWithoutPreserves)===null||o===void 0||o.map(function(s){var l=s.key;a=ei(a,l,Fn(n,l));}),r.prevWithoutPreserves=null,r.updateStore(a);}},this.destroyForm=function(){var n=new Xi;r.getFieldEntities(!0).forEach(function(i){r.isMergedPreserve(i.isPreserve())||n.set(i.getNamePath(),!0);}),r.prevWithoutPreserves=n;},this.getInitialValue=function(n){var i=Fn(r.initialValues,n);return n.length?fc(i):i},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(i){return i!==n});}},this.notifyWatch=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];if(r.watchList.length){var i=r.getFieldsValue(),o=r.getFieldsValue(!0);r.watchList.forEach(function(a){a(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(i){return i.getNamePath().length}):r.fieldEntities},this.getFieldsMap=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,i=new Xi;return r.getFieldEntities(n).forEach(function(o){var a=o.getNamePath();i.set(a,o);}),i},this.getFieldEntitiesForNamePathList=function(n){if(!n)return r.getFieldEntities(!0);var i=r.getFieldsMap(!0);return n.map(function(o){var a=Ht(o);return i.get(a)||{INVALIDATE_NAME_PATH:Ht(o)}})},this.getFieldsValue=function(n,i){if(r.warningUnhooked(),n===!0&&!i)return r.store;var o=r.getFieldEntitiesForNamePathList(Array.isArray(n)?n:null),a=[];return o.forEach(function(s){var l,c="INVALIDATE_NAME_PATH"in s?s.INVALIDATE_NAME_PATH:s.getNamePath();if(!(!n&&(!((l=s.isListField)===null||l===void 0)&&l.call(s))))if(!i)a.push(c);else {var u="getMeta"in s?s.getMeta():null;i(u)&&a.push(c);}}),Tv(r.store,a.map(Ht))},this.getFieldValue=function(n){r.warningUnhooked();var i=Ht(n);return Fn(r.store,i)},this.getFieldsError=function(n){r.warningUnhooked();var i=r.getFieldEntitiesForNamePathList(n);return i.map(function(o,a){return o&&!("INVALIDATE_NAME_PATH"in o)?{name:o.getNamePath(),errors:o.getErrors(),warnings:o.getWarnings()}:{name:Ht(n[a]),errors:[],warnings:[]}})},this.getFieldError=function(n){r.warningUnhooked();var i=Ht(n),o=r.getFieldsError([i])[0];return o.errors},this.getFieldWarning=function(n){r.warningUnhooked();var i=Ht(n),o=r.getFieldsError([i])[0];return o.warnings},this.isFieldsTouched=function(){r.warningUnhooked();for(var n=arguments.length,i=new Array(n),o=0;o0&&arguments[0]!==void 0?arguments[0]:{},i=new Xi,o=r.getFieldEntities(!0);o.forEach(function(l){var c=l.props.initialValue,u=l.getNamePath();if(c!==void 0){var d=i.get(u)||new Set;d.add({entity:l,value:c}),i.set(u,d);}});var a=function(c){c.forEach(function(u){var d=u.props.initialValue;if(d!==void 0){var h=u.getNamePath(),v=r.getInitialValue(h);if(v!==void 0)dr(!1,"Form already set 'initialValues' with path '".concat(h.join("."),"'. Field can not overwrite it."));else {var p=i.get(h);if(p&&p.size>1)dr(!1,"Multiple Field with path '".concat(h.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(p){var m=r.getFieldValue(h);(!n.skipExist||m===void 0)&&r.updateStore(ei(r.store,h,le(p)[0].value));}}}});},s;n.entities?s=n.entities:n.namePathList?(s=[],n.namePathList.forEach(function(l){var c=i.get(l);if(c){var u;(u=s).push.apply(u,le(le(c).map(function(d){return d.entity})));}})):s=o,a(s);},this.resetFields=function(n){r.warningUnhooked();var i=r.store;if(!n){r.updateStore(Ca({},r.initialValues)),r.resetWithFieldInitialValue(),r.notifyObservers(i,null,{type:"reset"}),r.notifyWatch();return}var o=n.map(Ht);o.forEach(function(a){var s=r.getInitialValue(a);r.updateStore(ei(r.store,a,s));}),r.resetWithFieldInitialValue({namePathList:o}),r.notifyObservers(i,o,{type:"reset"}),r.notifyWatch(o);},this.setFields=function(n){r.warningUnhooked();var i=r.store,o=[];n.forEach(function(a){var s=a.name,l=Xe(a,oO),c=Ht(s);o.push(c),"value"in l&&r.updateStore(ei(r.store,c,l.value)),r.notifyObservers(i,[c],{type:"setField",data:a});}),r.notifyWatch(o);},this.getFields=function(){var n=r.getFieldEntities(!0),i=n.map(function(o){var a=o.getNamePath(),s=o.getMeta(),l=D(D({},s),{},{name:a,value:r.getFieldValue(a)});return Object.defineProperty(l,"originRCField",{value:!0}),l});return i},this.initEntityValue=function(n){var i=n.props.initialValue;if(i!==void 0){var o=n.getNamePath(),a=Fn(r.store,o);a===void 0&&r.updateStore(ei(r.store,o,i));}},this.isMergedPreserve=function(n){var i=n!==void 0?n:r.preserve;return i??!0},this.registerField=function(n){r.fieldEntities.push(n);var i=n.getNamePath();if(r.notifyWatch([i]),n.props.initialValue!==void 0){var o=r.store;r.resetWithFieldInitialValue({entities:[n],skipExist:!0}),r.notifyObservers(o,[n.getNamePath()],{type:"valueUpdate",source:"internal"});}return function(a,s){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(r.fieldEntities=r.fieldEntities.filter(function(d){return d!==n}),!r.isMergedPreserve(s)&&(!a||l.length>1)){var c=a?void 0:r.getInitialValue(i);if(i.length&&r.getFieldValue(i)!==c&&r.fieldEntities.every(function(d){return !Jg(d.getNamePath(),i)})){var u=r.store;r.updateStore(ei(u,i,c,!0)),r.notifyObservers(u,[i],{type:"remove"}),r.triggerDependenciesUpdate(u,i);}}r.notifyWatch([i]);}},this.dispatch=function(n){switch(n.type){case"updateValue":{var i=n.namePath,o=n.value;r.updateValue(i,o);break}case"validateField":{var a=n.namePath,s=n.triggerName;r.validateFields([a],{triggerName:s});break}}},this.notifyObservers=function(n,i,o){if(r.subscribable){var a=D(D({},o),{},{store:r.getFieldsValue(!0)});r.getFieldEntities().forEach(function(s){var l=s.onStoreChange;l(n,i,a);});}else r.forceRootUpdate();},this.triggerDependenciesUpdate=function(n,i){var o=r.getDependencyChildrenFields(i);return o.length&&r.validateFields(o),r.notifyObservers(n,o,{type:"dependenciesUpdate",relatedFields:[i].concat(le(o))}),o},this.updateValue=function(n,i){var o=Ht(n),a=r.store;r.updateStore(ei(r.store,o,i)),r.notifyObservers(a,[o],{type:"valueUpdate",source:"internal"}),r.notifyWatch([o]);var s=r.triggerDependenciesUpdate(a,o),l=r.callbacks.onValuesChange;if(l){var c=Tv(r.store,[o]);l(c,r.getFieldsValue());}r.triggerOnFieldsChange([o].concat(le(s)));},this.setFieldsValue=function(n){r.warningUnhooked();var i=r.store;if(n){var o=Ca(r.store,n);r.updateStore(o);}r.notifyObservers(i,null,{type:"valueUpdate",source:"external"}),r.notifyWatch();},this.setFieldValue=function(n,i){r.setFields([{name:n,value:i}]);},this.getDependencyChildrenFields=function(n){var i=new Set,o=[],a=new Xi;r.getFieldEntities().forEach(function(l){var c=l.props.dependencies;(c||[]).forEach(function(u){var d=Ht(u);a.update(d,function(){var h=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new Set;return h.add(l),h});});});var s=function l(c){var u=a.get(c)||new Set;u.forEach(function(d){if(!i.has(d)){i.add(d);var h=d.getNamePath();d.isFieldDirty()&&h.length&&(o.push(h),l(h));}});};return s(n),o},this.triggerOnFieldsChange=function(n,i){var o=r.callbacks.onFieldsChange;if(o){var a=r.getFields();if(i){var s=new Xi;i.forEach(function(c){var u=c.name,d=c.errors;s.set(u,d);}),a.forEach(function(c){c.errors=s.get(c.name)||c.errors;});}var l=a.filter(function(c){var u=c.name;return Sa(n,u)});o(l,a);}},this.validateFields=function(n,i){r.warningUnhooked();var o,a;Array.isArray(n)||typeof n=="string"||typeof i=="string"?(o=n,a=i):a=n;var s=!!o,l=s?o.map(Ht):[],c=[];r.getFieldEntities(!0).forEach(function(h){var v;if(s||l.push(h.getNamePath()),!((v=a)===null||v===void 0)&&v.recursive&&s){var p=h.getNamePath();p.every(function(b,w){return o[w]===b||o[w]===void 0})&&l.push(p);}if(!(!h.props.rules||!h.props.rules.length)){var m=h.getNamePath();if(!s||Sa(l,m)){var g=h.validateRules(D({validateMessages:D(D({},Yg),r.validateMessages)},a));c.push(g.then(function(){return {name:m,errors:[],warnings:[]}}).catch(function(b){var w,S=[],$=[];return (w=b.forEach)===null||w===void 0||w.call(b,function(x){var y=x.rule.warningOnly,C=x.errors;y?$.push.apply($,le(C)):S.push.apply(S,le(C));}),S.length?Promise.reject({name:m,errors:S,warnings:$}):{name:m,errors:S,warnings:$}}));}}});var u=iO(c);r.lastValidatePromise=u,u.catch(function(h){return h}).then(function(h){var v=h.map(function(p){var m=p.name;return m});r.notifyObservers(r.store,v,{type:"validateFinish"}),r.triggerOnFieldsChange(v,h);});var d=u.then(function(){return r.lastValidatePromise===u?Promise.resolve(r.getFieldsValue(l)):Promise.reject([])}).catch(function(h){var v=h.filter(function(p){return p&&p.errors.length});return Promise.reject({values:r.getFieldsValue(l),errorFields:v,outOfDate:r.lastValidatePromise!==u})});return d.catch(function(h){return h}),r.triggerOnFieldsChange(l),d},this.submit=function(){r.warningUnhooked(),r.validateFields().then(function(n){var i=r.callbacks.onFinish;if(i)try{i(n);}catch(o){console.error(o);}}).catch(function(n){var i=r.callbacks.onFinishFailed;i&&i(n);});},this.forceRootUpdate=t;});function rb(e){var t=f__namespace.useRef(),r=f__namespace.useState({}),n=W(r,2),i=n[1];if(!t.current)if(e)t.current=e;else {var o=function(){i({});},a=new aO(o);t.current=a.getForm();}return [t.current]}var pd=f__namespace.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),nb=function(t){var r=t.validateMessages,n=t.onFormChange,i=t.onFormFinish,o=t.children,a=f__namespace.useContext(pd),s=f__namespace.useRef({});return f__namespace.createElement(pd.Provider,{value:D(D({},a),{},{validateMessages:D(D({},a.validateMessages),r),triggerFormChange:function(c,u){n&&n(c,{changedFields:u,forms:s.current}),a.triggerFormChange(c,u);},triggerFormFinish:function(c,u){i&&i(c,{values:u,forms:s.current}),a.triggerFormFinish(c,u);},registerForm:function(c,u){c&&(s.current=D(D({},s.current),{},H({},c,u))),a.registerForm(c,u);},unregisterForm:function(c){var u=D({},s.current);delete u[c],s.current=u,a.unregisterForm(c);}})},o)},sO=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed"],lO=function(t,r){var n=t.name,i=t.initialValues,o=t.fields,a=t.form,s=t.preserve,l=t.children,c=t.component,u=c===void 0?"form":c,d=t.validateMessages,h=t.validateTrigger,v=h===void 0?"onChange":h,p=t.onValuesChange,m=t.onFieldsChange,g=t.onFinish,b=t.onFinishFailed,w=Xe(t,sO),S=f__namespace.useContext(pd),$=rb(a),x=W($,1),y=x[0],C=y.getInternalHooks(Ci),M=C.useSubscribe,R=C.setInitialValues,P=C.setCallbacks,N=C.setValidateMessages,_=C.setPreserve,E=C.destroyForm;f__namespace.useImperativeHandle(r,function(){return y}),f__namespace.useEffect(function(){return S.registerForm(n,y),function(){S.unregisterForm(n);}},[S,y,n]),N(D(D({},S.validateMessages),d)),P({onValuesChange:p,onFieldsChange:function(z){if(S.triggerFormChange(n,z),m){for(var V=arguments.length,q=new Array(V>1?V-1:0),U=1;U{const{locale:t={},children:r,_ANT_MARK__:n}=e;f__namespace.useEffect(()=>(Fv(t&&t.Modal),()=>{Fv();}),[t]);const i=f__namespace.useMemo(()=>Object.assign(Object.assign({},t),{exist:!0}),[t]);return f__namespace.createElement(ob.Provider,{value:i},r)},yO=bO,wO="5.5.0",Sl=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"];function or(e,t){SO(e)&&(e="100%");var r=CO(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 Es(e){return Math.min(1,Math.max(0,e))}function SO(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function CO(e){return typeof e=="string"&&e.indexOf("%")!==-1}function ab(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function _s(e){return e<=1?"".concat(Number(e)*100,"%"):e}function $i(e){return e.length===1?"0"+e:String(e)}function xO(e,t,r){return {r:or(e,255)*255,g:or(t,255)*255,b:or(r,255)*255}}function Dv(e,t,r){e=or(e,255),t=or(t,255),r=or(r,255);var n=Math.max(e,t,r),i=Math.min(e,t,r),o=0,a=0,s=(n+i)/2;if(n===i)a=0,o=0;else {var l=n-i;switch(a=s>.5?l/(2-n-i):l/(n+i),n){case e:o=(t-r)/l+(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 $O(e,t,r){var n,i,o;if(e=or(e,360),t=or(t,100),r=or(r,100),t===0)i=r,o=r,n=r;else {var a=r<.5?r*(1+t):r+t-r*t,s=2*r-a;n=ru(s,a,e+1/3),i=ru(s,a,e),o=ru(s,a,e-1/3);}return {r:n*255,g:i*255,b:o*255}}function md(e,t,r){e=or(e,255),t=or(t,255),r=or(r,255);var n=Math.max(e,t,r),i=Math.min(e,t,r),o=0,a=n,s=n-i,l=n===0?0:s/n;if(n===i)o=0;else {switch(n){case e:o=(t-r)/s+(t>16,g:(e&65280)>>8,b:e&255}}var bd={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 oo(e){var t={r:0,g:0,b:0},r=1,n=null,i=null,o=null,a=!1,s=!1;return typeof e=="string"&&(e=RO(e)),typeof e=="object"&&(Nn(e.r)&&Nn(e.g)&&Nn(e.b)?(t=xO(e.r,e.g,e.b),a=!0,s=String(e.r).substr(-1)==="%"?"prgb":"rgb"):Nn(e.h)&&Nn(e.s)&&Nn(e.v)?(n=_s(e.s),i=_s(e.v),t=EO(e.h,n,i),a=!0,s="hsv"):Nn(e.h)&&Nn(e.s)&&Nn(e.l)&&(n=_s(e.s),o=_s(e.l),t=$O(e.h,n,o),a=!0,s="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(r=e.a)),r=ab(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 TO="[-\\+]?\\d+%?",MO="[-\\+]?\\d*\\.\\d+%?",si="(?:".concat(MO,")|(?:").concat(TO,")"),nu="[\\s|\\(]+(".concat(si,")[,|\\s]+(").concat(si,")[,|\\s]+(").concat(si,")\\s*\\)?"),iu="[\\s|\\(]+(".concat(si,")[,|\\s]+(").concat(si,")[,|\\s]+(").concat(si,")[,|\\s]+(").concat(si,")\\s*\\)?"),Xr={CSS_UNIT:new RegExp(si),rgb:new RegExp("rgb"+nu),rgba:new RegExp("rgba"+iu),hsl:new RegExp("hsl"+nu),hsla:new RegExp("hsla"+iu),hsv:new RegExp("hsv"+nu),hsva:new RegExp("hsva"+iu),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 RO(e){if(e=e.trim().toLowerCase(),e.length===0)return !1;var t=!1;if(bd[e])e=bd[e],t=!0;else if(e==="transparent")return {r:0,g:0,b:0,a:0,format:"name"};var r=Xr.rgb.exec(e);return r?{r:r[1],g:r[2],b:r[3]}:(r=Xr.rgba.exec(e),r?{r:r[1],g:r[2],b:r[3],a:r[4]}:(r=Xr.hsl.exec(e),r?{h:r[1],s:r[2],l:r[3]}:(r=Xr.hsla.exec(e),r?{h:r[1],s:r[2],l:r[3],a:r[4]}:(r=Xr.hsv.exec(e),r?{h:r[1],s:r[2],v:r[3]}:(r=Xr.hsva.exec(e),r?{h:r[1],s:r[2],v:r[3],a:r[4]}:(r=Xr.hex8.exec(e),r?{r:Nr(r[1]),g:Nr(r[2]),b:Nr(r[3]),a:jv(r[4]),format:t?"name":"hex8"}:(r=Xr.hex6.exec(e),r?{r:Nr(r[1]),g:Nr(r[2]),b:Nr(r[3]),format:t?"name":"hex"}:(r=Xr.hex4.exec(e),r?{r:Nr(r[1]+r[1]),g:Nr(r[2]+r[2]),b:Nr(r[3]+r[3]),a:jv(r[4]+r[4]),format:t?"name":"hex8"}:(r=Xr.hex3.exec(e),r?{r:Nr(r[1]+r[1]),g:Nr(r[2]+r[2]),b:Nr(r[3]+r[3]),format:t?"name":"hex"}:!1)))))))))}function Nn(e){return !!Xr.CSS_UNIT.exec(String(e))}var ur=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=OO(t)),this.originalInput=t;var i=oo(t);this.originalInput=t,this.r=i.r,this.g=i.g,this.b=i.b,this.a=i.a,this.roundA=Math.round(100*this.a)/100,this.format=(n=r.format)!==null&&n!==void 0?n:i.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=i.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,i,o=t.r/255,a=t.g/255,s=t.b/255;return o<=.03928?r=o/12.92:r=Math.pow((o+.055)/1.055,2.4),a<=.03928?n=a/12.92:n=Math.pow((a+.055)/1.055,2.4),s<=.03928?i=s/12.92:i=Math.pow((s+.055)/1.055,2.4),.2126*r+.7152*n+.0722*i},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(t){return this.a=ab(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=md(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=md(this.r,this.g,this.b),r=Math.round(t.h*360),n=Math.round(t.s*100),i=Math.round(t.v*100);return this.a===1?"hsv(".concat(r,", ").concat(n,"%, ").concat(i,"%)"):"hsva(".concat(r,", ").concat(n,"%, ").concat(i,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var t=Dv(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=Dv(this.r,this.g,this.b),r=Math.round(t.h*360),n=Math.round(t.s*100),i=Math.round(t.l*100);return this.a===1?"hsl(".concat(r,", ").concat(n,"%, ").concat(i,"%)"):"hsla(".concat(r,", ").concat(n,"%, ").concat(i,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(t){return t===void 0&&(t=!1),gd(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),_O(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(or(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(or(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="#"+gd(this.r,this.g,this.b,!1),r=0,n=Object.entries(bd);r=0,o=!r&&i&&(t.startsWith("hex")||t==="name");return o?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=Es(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=Es(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=Es(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=Es(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(),i=new e(t).toRgb(),o=r/100,a={r:(i.r-n.r)*o+n.r,g:(i.g-n.g)*o+n.g,b:(i.b-n.b)*o+n.b,a:(i.a-n.a)*o+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(),i=360/r,o=[this];for(n.h=(n.h-(i*t>>1)+720)%360;--t;)n.h=(n.h+i)%360,o.push(new e(n));return o},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,i=r.s,o=r.v,a=[],s=1/t;t--;)a.push(new e({h:n,s:i,v:o})),o=(o+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(),i=r.a+n.a*(1-r.a);return new e({r:(r.r*r.a+n.r*n.a*(1-r.a))/i,g:(r.g*r.a+n.g*n.a*(1-r.a))/i,b:(r.b*r.a+n.b*n.a*(1-r.a))/i,a:i})},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,i=[this],o=360/t,a=1;a=60&&Math.round(e.h)<=240?n=r?Math.round(e.h)-Ps*t:Math.round(e.h)+Ps*t:n=r?Math.round(e.h)+Ps*t:Math.round(e.h)-Ps*t,n<0?n+=360:n>=360&&(n-=360),n}function Bv(e,t,r){if(e.h===0&&e.s===0)return e.s;var n;return r?n=e.s-zv*t:t===lb?n=e.s+zv:n=e.s+NO*t,n>1&&(n=1),r&&t===sb&&n>.1&&(n=.1),n<.06&&(n=.06),Number(n.toFixed(2))}function Vv(e,t,r){var n;return r?n=e.v+IO*t:n=e.v-AO*t,n>1&&(n=1),Number(n.toFixed(2))}function Un(e){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=[],n=oo(e),i=sb;i>0;i-=1){var o=Hv(n),a=Os(oo({h:Wv(o,i,!0),s:Bv(o,i,!0),v:Vv(o,i,!0)}));r.push(a);}r.push(Os(n));for(var s=1;s<=lb;s+=1){var l=Hv(n),c=Os(oo({h:Wv(l,s),s:Bv(l,s),v:Vv(l,s)}));r.push(c);}return t.theme==="dark"?kO.map(function(u){var d=u.index,h=u.opacity,v=Os(LO(oo(t.backgroundColor||"#141414"),oo(r[d]),h*100));return v}):r}var ou={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"},au={},su={};Object.keys(ou).forEach(function(e){au[e]=Un(ou[e]),au[e].primary=au[e][5],su[e]=Un(ou[e],{theme:"dark",backgroundColor:"#141414"}),su[e].primary=su[e][5];});const FO=e=>{const{controlHeight:t}=e;return {controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}},cb=FO;function DO(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 kf={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"},hc=Object.assign(Object.assign({},kf),{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,motion:!0});function ub(e,t){let{generateColorPalettes:r,generateNeutralColorPalettes:n}=t;const{colorSuccess:i,colorWarning:o,colorError:a,colorInfo:s,colorPrimary:l,colorBgBase:c,colorTextBase:u}=e,d=r(l),h=r(i),v=r(o),p=r(a),m=r(s),g=n(c,u);return Object.assign(Object.assign({},g),{colorPrimaryBg:d[1],colorPrimaryBgHover:d[2],colorPrimaryBorder:d[3],colorPrimaryBorderHover:d[4],colorPrimaryHover:d[5],colorPrimary:d[6],colorPrimaryActive:d[7],colorPrimaryTextHover:d[8],colorPrimaryText:d[9],colorPrimaryTextActive:d[10],colorSuccessBg:h[1],colorSuccessBgHover:h[2],colorSuccessBorder:h[3],colorSuccessBorderHover:h[4],colorSuccessHover:h[4],colorSuccess:h[6],colorSuccessActive:h[7],colorSuccessTextHover:h[8],colorSuccessText:h[9],colorSuccessTextActive:h[10],colorErrorBg:p[1],colorErrorBgHover:p[2],colorErrorBorder:p[3],colorErrorBorderHover:p[4],colorErrorHover:p[5],colorError:p[6],colorErrorActive:p[7],colorErrorTextHover:p[8],colorErrorText:p[9],colorErrorTextActive:p[10],colorWarningBg:v[1],colorWarningBgHover:v[2],colorWarningBorder:v[3],colorWarningBorderHover:v[4],colorWarningHover:v[4],colorWarning:v[6],colorWarningActive:v[7],colorWarningTextHover:v[8],colorWarningText:v[9],colorWarningTextActive:v[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 ur("#000").setAlpha(.45).toRgbString(),colorWhite:"#fff"})}const jO=e=>{let t=e,r=e,n=e,i=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?r=4:e<8&&e>=7?r=5:e<14&&e>=8?r=6:e<16&&e>=14?r=7:e>=16&&(r=8),e<6&&e>=2?n=1:e>=6&&(n=2),e>4&&e<8?i=4:e>=8&&(i=6),{borderRadius:e>16?16:e,borderRadiusXS:n,borderRadiusSM:r,borderRadiusLG:t,borderRadiusOuter:i}},zO=jO;function HO(e){const{motionUnit:t,motionBase:r,borderRadius:n,lineWidth:i}=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:i+1},zO(n))}const In=(e,t)=>new ur(e).setAlpha(t).toRgbString(),Jo=(e,t)=>new ur(e).darken(t).toHexString(),WO=e=>{const t=Un(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]}},BO=(e,t)=>{const r=e||"#fff",n=t||"#000";return {colorBgBase:r,colorTextBase:n,colorText:In(n,.88),colorTextSecondary:In(n,.65),colorTextTertiary:In(n,.45),colorTextQuaternary:In(n,.25),colorFill:In(n,.15),colorFillSecondary:In(n,.06),colorFillTertiary:In(n,.04),colorFillQuaternary:In(n,.02),colorBgLayout:Jo(r,4),colorBgContainer:Jo(r,0),colorBgElevated:Jo(r,0),colorBgSpotlight:In(n,.85),colorBorder:Jo(r,15),colorBorderSecondary:Jo(r,6)}};function VO(e){const t=new Array(10).fill(null).map((r,n)=>{const i=n-1,o=e*Math.pow(2.71828,i/5),a=n>1?Math.floor(o):Math.ceil(o);return Math.floor(a/2)*2});return t[1]=e,t.map(r=>{const n=r+8;return {size:r,lineHeight:n/r}})}const UO=e=>{const t=VO(e),r=t.map(i=>i.size),n=t.map(i=>i.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]}},db=UO;function vc(e){const t=Object.keys(kf).map(r=>{const n=Un(e[r]);return new Array(10).fill(1).reduce((i,o,a)=>(i[`${r}-${a+1}`]=n[a],i[`${r}${a+1}`]=n[a],i),{})}).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),ub(e,{generateColorPalettes:WO,generateNeutralColorPalettes:BO})),db(e.fontSize)),DO(e)),cb(e)),HO(e))}function lu(e){return e>=0&&e<=255}function Ts(e,t){const{r,g:n,b:i,a:o}=new ur(e).toRgb();if(o<1)return e;const{r:a,g:s,b:l}=new ur(t).toRgb();for(let c=.01;c<=1;c+=.01){const u=Math.round((r-a*(1-c))/c),d=Math.round((n-s*(1-c))/c),h=Math.round((i-l*(1-c))/c);if(lu(u)&&lu(d)&&lu(h))return new ur({r:u,g:d,b:h,a:Math.round(c*100)/100}).toRgbString()}return new ur({r,g:n,b:i,a:1}).toRgbString()}var GO=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 i=0,n=Object.getOwnPropertySymbols(e);i{delete n[h];});const i=Object.assign(Object.assign({},r),n),o=480,a=576,s=768,l=992,c=1200,u=1600;if(i.motion===!1){const h="0s";i.motionDurationFast=h,i.motionDurationMid=h,i.motionDurationSlow=h;}return Object.assign(Object.assign(Object.assign({},i),{colorLink:i.colorInfoText,colorLinkHover:i.colorInfoHover,colorLinkActive:i.colorInfoActive,colorFillContent:i.colorFillSecondary,colorFillContentHover:i.colorFill,colorFillAlter:i.colorFillQuaternary,colorBgContainerDisabled:i.colorFillTertiary,colorBorderBg:i.colorBgContainer,colorSplit:Ts(i.colorBorderSecondary,i.colorBgContainer),colorTextPlaceholder:i.colorTextQuaternary,colorTextDisabled:i.colorTextQuaternary,colorTextHeading:i.colorText,colorTextLabel:i.colorTextSecondary,colorTextDescription:i.colorTextTertiary,colorTextLightSolid:i.colorWhite,colorHighlight:i.colorError,colorBgTextHover:i.colorFillSecondary,colorBgTextActive:i.colorFill,colorIcon:i.colorTextTertiary,colorIconHover:i.colorText,colorErrorOutline:Ts(i.colorErrorBg,i.colorBgContainer),colorWarningOutline:Ts(i.colorWarningBg,i.colorBgContainer),fontSizeIcon:i.fontSizeSM,lineWidthFocus:i.lineWidth*4,lineWidth:i.lineWidth,controlOutlineWidth:i.lineWidth*2,controlInteractiveSize:i.controlHeight/2,controlItemBgHover:i.colorFillTertiary,controlItemBgActive:i.colorPrimaryBg,controlItemBgActiveHover:i.colorPrimaryBgHover,controlItemBgActiveDisabled:i.colorFill,controlTmpOutline:i.colorFillQuaternary,controlOutline:Ts(i.colorPrimaryBg,i.colorBgContainer),lineType:i.lineType,borderRadius:i.borderRadius,borderRadiusXS:i.borderRadiusXS,borderRadiusSM:i.borderRadiusSM,borderRadiusLG:i.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:i.sizeXXS,paddingXS:i.sizeXS,paddingSM:i.sizeSM,padding:i.size,paddingMD:i.sizeMD,paddingLG:i.sizeLG,paddingXL:i.sizeXL,paddingContentHorizontalLG:i.sizeLG,paddingContentVerticalLG:i.sizeMS,paddingContentHorizontal:i.sizeMS,paddingContentVertical:i.sizeSM,paddingContentHorizontalSM:i.size,paddingContentVerticalSM:i.sizeXS,marginXXS:i.sizeXXS,marginXS:i.sizeXS,marginSM:i.sizeSM,margin:i.size,marginMD:i.sizeMD,marginLG:i.sizeLG,marginXL:i.sizeXL,marginXXL:i.sizeXXL,boxShadow:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowSecondary:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTertiary:` 0 1px 2px 0 rgba(0, 0, 0, 0.03), 0 1px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px 0 rgba(0, 0, 0, 0.02) `,screenXS:o,screenXSMin:o,screenXSMax:a-1,screenSM:a,screenSMMin:a,screenSMMax:s-1,screenMD:s,screenMDMin:s,screenMDMax:l-1,screenLG:l,screenLGMin:l,screenLGMax:c-1,screenXL:c,screenXLMin:c,screenXLMax:u-1,screenXXL:u,screenXXLMin:u,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:` 0 1px 2px -2px ${new ur("rgba(0, 0, 0, 0.16)").toRgbString()}, 0 3px 6px 0 ${new ur("rgba(0, 0, 0, 0.12)").toRgbString()}, 0 5px 12px 4px ${new ur("rgba(0, 0, 0, 0.09)").toRgbString()} `,boxShadowDrawerRight:` -6px 0 16px 0 rgba(0, 0, 0, 0.08), -3px 0 6px -4px rgba(0, 0, 0, 0.12), -9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerLeft:` 6px 0 16px 0 rgba(0, 0, 0, 0.08), 3px 0 6px -4px rgba(0, 0, 0, 0.12), 9px 0 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerUp:` 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowDrawerDown:` 0 -6px 16px 0 rgba(0, 0, 0, 0.08), 0 -3px 6px -4px rgba(0, 0, 0, 0.12), 0 -9px 28px 8px rgba(0, 0, 0, 0.05) `,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"}),n)}const fb="anticon",qO=(e,t)=>t||(e?`ant-${e}`:"ant"),Wt=f__namespace.createContext({getPrefixCls:qO,iconPrefixCls:fb}),XO=(e,t,r,n,i)=>{const o=e/2,a=0,s=o,l=r*1/Math.sqrt(2),c=o-r*(1-1/Math.sqrt(2)),u=o-t*(1/Math.sqrt(2)),d=r*(Math.sqrt(2)-1)+t*(1/Math.sqrt(2)),h=2*o-u,v=d,p=2*o-l,m=c,g=2*o-a,b=s,w=o*Math.sqrt(2)+r*(Math.sqrt(2)-2),S=r*(Math.sqrt(2)-1);return {pointerEvents:"none",width:e,height:e,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:e,height:e/2,background:n,clipPath:{_multi_value_:!0,value:[`polygon(${S}px 100%, 50% ${S}px, ${2*o-S}px 100%, ${S}px 100%)`,`path('M ${a} ${s} A ${r} ${r} 0 0 0 ${l} ${c} L ${u} ${d} A ${t} ${t} 0 0 1 ${h} ${v} L ${p} ${m} A ${r} ${r} 0 0 0 ${g} ${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:i,zIndex:0,background:"transparent"}}},YO={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},yr=e=>({boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:e.fontFamily}),hb=()=>({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"}}),ZO=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),QO=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"}}}),JO=(e,t)=>{const{fontFamily:r,fontSize:n}=e,i=`[class^="${t}"], [class*=" ${t}"]`;return {[i]:{fontFamily:r,fontSize:n,boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"},[i]:{boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}}}}},pc=e=>({outline:`${e.lineWidthFocus}px solid ${e.colorPrimaryBorder}`,outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),Lf=e=>({"&:focus-visible":Object.assign({},pc(e))});function Tn(e,t,r,n){return i=>{const[o,a,s]=os(),{getPrefixCls:l,iconPrefixCls:c,csp:u}=f.useContext(Wt),d=l(),h={theme:o,token:a,hashId:s,nonce:()=>u==null?void 0:u.nonce};return nd(Object.assign(Object.assign({},h),{path:["Shared",d]}),()=>[{"&":QO(a)}]),[nd(Object.assign(Object.assign({},h),{path:[e,i,c]}),()=>{const{token:v,flush:p}=tT(a),m=typeof r=="function"?r(v):r,g=Object.assign(Object.assign({},m),a[e]),b=`.${i}`,w=mr(v,{componentCls:b,prefixCls:i,iconCls:`.${c}`,antCls:`.${d}`},g),S=t(w,{hashId:s,prefixCls:i,rootPrefixCls:d,iconPrefixCls:c,overrideComponentToken:a[e]});return p(e,g),[(n==null?void 0:n.resetStyle)===!1?null:JO(a,i),S]}),s]}}const vb=typeof CSSINJS_STATISTIC<"u";let yd=!0;function mr(){for(var e=arguments.length,t=new Array(e),r=0;r{Object.keys(i).forEach(a=>{Object.defineProperty(n,a,{configurable:!0,enumerable:!0,get:()=>i[a]});});}),yd=!0,n}function eT(){}function tT(e){let t,r=e,n=eT;return vb&&(t=new Set,r=new Proxy(e,{get(i,o){return yd&&t.add(o),i[o]}}),n=(i,o)=>{Array.from(t);}),{token:r,keys:t,flush:n}}function pb(e,t){return Sl.reduce((r,n)=>{const i=e[`${n}1`],o=e[`${n}3`],a=e[`${n}6`],s=e[`${n}7`];return Object.assign(Object.assign({},r),t(n,{lightColor:i,lightBorderColor:o,darkColor:a,textColor:s}))},{})}const rT=qg(vc),Cl={token:hc,hashed:!0},mb=f.createContext(Cl);function os(){const{token:e,hashed:t,theme:r,components:n}=f.useContext(mb),i=`${wO}-${t||""}`,o=r||rT,[a,s]=nP(o,[hc,e],{salt:i,override:Object.assign({override:e},n),formatToken:KO});return [o,a,t?s:""]}const nT=`-ant-${Date.now()}-${Math.random()}`;function iT(e,t){const r={},n=(a,s)=>{let l=a.clone();return l=(s==null?void 0:s(l))||l,l.toRgbString()},i=(a,s)=>{const l=new ur(a),c=Un(l.toRgbString());r[`${s}-color`]=n(l),r[`${s}-color-disabled`]=c[1],r[`${s}-color-hover`]=c[4],r[`${s}-color-active`]=c[6],r[`${s}-color-outline`]=l.clone().setAlpha(.2).toRgbString(),r[`${s}-color-deprecated-bg`]=c[0],r[`${s}-color-deprecated-border`]=c[2];};if(t.primaryColor){i(t.primaryColor,"primary");const a=new ur(t.primaryColor),s=Un(a.toRgbString());s.forEach((c,u)=>{r[`primary-${u+1}`]=c;}),r["primary-color-deprecated-l-35"]=n(a,c=>c.lighten(35)),r["primary-color-deprecated-l-20"]=n(a,c=>c.lighten(20)),r["primary-color-deprecated-t-20"]=n(a,c=>c.tint(20)),r["primary-color-deprecated-t-50"]=n(a,c=>c.tint(50)),r["primary-color-deprecated-f-12"]=n(a,c=>c.setAlpha(c.getAlpha()*.12));const l=new ur(s[0]);r["primary-color-active-deprecated-f-30"]=n(l,c=>c.setAlpha(c.getAlpha()*.3)),r["primary-color-active-deprecated-d-02"]=n(l,c=>c.darken(2));}return t.successColor&&i(t.successColor,"success"),t.warningColor&&i(t.warningColor,"warning"),t.errorColor&&i(t.errorColor,"error"),t.infoColor&&i(t.infoColor,"info"),` :root { ${Object.keys(r).map(a=>`--${e}-${a}: ${r[a]};`).join(` `)} } `.trim()}function oT(e,t){const r=iT(e,t);Sr()&&To(r,`${nT}-dynamic-theme`);}const wd=f__namespace.createContext(!1),aT=e=>{let{children:t,disabled:r}=e;const n=f__namespace.useContext(wd);return f__namespace.createElement(wd.Provider,{value:r??n},t)},as=wd,sT=e=>{const t=f.useContext(mc);return f.useMemo(()=>e?typeof e=="string"?e??t:e instanceof Function?e(t):t:t,[e,t])},Do=sT,gb=f__namespace.createContext(void 0),lT=e=>{let{children:t,size:r}=e;const n=Do(r);return f__namespace.createElement(gb.Provider,{value:n},t)},mc=gb;function cT(){const e=f.useContext(as),t=f.useContext(mc);return {componentDisabled:e,componentSize:t}}function uT(e,t){const r=e||{},n=r.inherit===!1||!t?Cl:t;return sc(()=>{if(!e)return t;const o=Object.assign({},n.components);return Object.keys(e.components||{}).forEach(a=>{o[a]=Object.assign(Object.assign({},o[a]),e.components[a]);}),Object.assign(Object.assign(Object.assign({},n),r),{token:Object.assign(Object.assign({},n.token),r.token),components:o})},[r,n],(o,a)=>o.some((s,l)=>{const c=a[l];return !rs(s,c,!0)}))}var dT=["children"],bb=f__namespace.createContext({});function fT(e){var t=e.children,r=Xe(e,dT);return f__namespace.createElement(bb.Provider,{value:r},t)}var hT=function(e){Lo(r,e);var t=Fo(r);function r(){return $r(this,r),t.apply(this,arguments)}return Er(r,[{key:"render",value:function(){return this.props.children}}]),r}(f__namespace.Component);function Mi(e){var t=f__namespace.useRef(!1),r=f__namespace.useState(e),n=W(r,2),i=n[0],o=n[1];f__namespace.useEffect(function(){return t.current=!1,function(){t.current=!0;}},[]);function a(s,l){l&&t.current||o(s);}return [i,a]}var yi="none",Ms="appear",Rs="enter",Ns="leave",Uv="none",rn="prepare",lo="start",co="active",Ff="end",yb="prepared";function Gv(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 vT(e,t){var r={animationend:Gv("Animation","AnimationEnd"),transitionend:Gv("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete r.animationend.animation,"TransitionEvent"in t||delete r.transitionend.transition),r}var pT=vT(Sr(),typeof window<"u"?window:{}),wb={};if(Sr()){var mT=document.createElement("div");wb=mT.style;}var Is={};function Sb(e){if(Is[e])return Is[e];var t=pT[e];if(t)for(var r=Object.keys(t),n=r.length,i=0;i1&&arguments[1]!==void 0?arguments[1]:1;Yv+=1;var n=Yv;function i(o){if(o===0)Ob(n),t();else {var a=_b(function(){i(o-1);});Df.set(n,a);}}return i(r),n};It.cancel=function(e){var t=Df.get(e);return Ob(t),Pb(t)};const bT=function(){var e=f__namespace.useRef(null);function t(){It.cancel(e.current);}function r(n){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;t();var o=It(function(){i<=1?n({isCanceled:function(){return o!==e.current}}):r(n,i-1);});e.current=o;}return f__namespace.useEffect(function(){return function(){t();}},[]),[r,t]};var yT=[rn,lo,co,Ff],wT=[rn,yb],Tb=!1,ST=!0;function Mb(e){return e===co||e===Ff}const CT=function(e,t,r){var n=Mi(Uv),i=W(n,2),o=i[0],a=i[1],s=bT(),l=W(s,2),c=l[0],u=l[1];function d(){a(rn,!0);}var h=t?wT:yT;return Eb(function(){if(o!==Uv&&o!==Ff){var v=h.indexOf(o),p=h[v+1],m=r(o);m===Tb?a(p,!0):p&&c(function(g){function b(){g.isCanceled()||a(p,!0);}m===!0?b():Promise.resolve(m).then(b);});}},[e,o]),f__namespace.useEffect(function(){return function(){u();}},[]),[d,o]};function xT(e,t,r,n){var i=n.motionEnter,o=i===void 0?!0:i,a=n.motionAppear,s=a===void 0?!0:a,l=n.motionLeave,c=l===void 0?!0:l,u=n.motionDeadline,d=n.motionLeaveImmediately,h=n.onAppearPrepare,v=n.onEnterPrepare,p=n.onLeavePrepare,m=n.onAppearStart,g=n.onEnterStart,b=n.onLeaveStart,w=n.onAppearActive,S=n.onEnterActive,$=n.onLeaveActive,x=n.onAppearEnd,y=n.onEnterEnd,C=n.onLeaveEnd,M=n.onVisibleChanged,R=Mi(),P=W(R,2),N=P[0],_=P[1],E=Mi(yi),O=W(E,2),T=O[0],A=O[1],I=Mi(null),L=W(I,2),j=L[0],B=L[1],G=f.useRef(!1),z=f.useRef(null);function V(){return r()}var q=f.useRef(!1);function U(){A(yi,!0),B(null,!0);}function Q(ge){var ve=V();if(!(ge&&!ge.deadline&&ge.target!==ve)){var $e=q.current,Ye;T===Ms&&$e?Ye=x==null?void 0:x(ve,ge):T===Rs&&$e?Ye=y==null?void 0:y(ve,ge):T===Ns&&$e&&(Ye=C==null?void 0:C(ve,ge)),T!==yi&&$e&&Ye!==!1&&U();}}var ie=gT(Q),Z=W(ie,1),te=Z[0],ae=function(ve){var $e,Ye,dt;switch(ve){case Ms:return $e={},H($e,rn,h),H($e,lo,m),H($e,co,w),$e;case Rs:return Ye={},H(Ye,rn,v),H(Ye,lo,g),H(Ye,co,S),Ye;case Ns:return dt={},H(dt,rn,p),H(dt,lo,b),H(dt,co,$),dt;default:return {}}},ue=f__namespace.useMemo(function(){return ae(T)},[T]),Ee=CT(T,!e,function(ge){if(ge===rn){var ve=ue[rn];return ve?ve(V()):Tb}if(se in ue){var $e;B((($e=ue[se])===null||$e===void 0?void 0:$e.call(ue,V(),null))||null);}return se===co&&(te(V()),u>0&&(clearTimeout(z.current),z.current=setTimeout(function(){Q({deadline:!0});},u))),se===yb&&U(),ST}),J=W(Ee,2),oe=J[0],se=J[1],re=Mb(se);q.current=re,Eb(function(){_(t);var ge=G.current;G.current=!0;var ve;!ge&&t&&s&&(ve=Ms),ge&&t&&o&&(ve=Rs),(ge&&!t&&c||!ge&&d&&!t&&c)&&(ve=Ns);var $e=ae(ve);ve&&(e||$e[rn])?(A(ve),oe()):A(yi);},[t]),f.useEffect(function(){(T===Ms&&!s||T===Rs&&!o||T===Ns&&!c)&&A(yi);},[s,o,c]),f.useEffect(function(){return function(){G.current=!1,clearTimeout(z.current);}},[]);var xe=f__namespace.useRef(!1);f.useEffect(function(){N&&(xe.current=!0),N!==void 0&&T===yi&&((xe.current||N)&&(M==null||M(N)),xe.current=!0);},[N,T]);var de=j;return ue[rn]&&se===lo&&(de=D({transition:"none"},de)),[T,se,de,N??t]}function $T(e){var t=e;ot(e)==="object"&&(t=e.transitionSupport);function r(i,o){return !!(i.motionName&&t&&o!==!1)}var n=f__namespace.forwardRef(function(i,o){var a=i.visible,s=a===void 0?!0:a,l=i.removeOnLeave,c=l===void 0?!0:l,u=i.forceRender,d=i.children,h=i.motionName,v=i.leavedClassName,p=i.eventProps,m=f__namespace.useContext(bb),g=m.motion,b=r(i,g),w=f.useRef(),S=f.useRef();function $(){try{return w.current instanceof HTMLElement?w.current:ml(S.current)}catch{return null}}var x=xT(b,s,$,i),y=W(x,4),C=y[0],M=y[1],R=y[2],P=y[3],N=f__namespace.useRef(P);P&&(N.current=!0);var _=f__namespace.useCallback(function(B){w.current=B,Pf(o,B);},[o]),E,O=D(D({},p),{},{visible:s});if(!d)E=null;else if(C===yi)P?E=d(D({},O),_):!c&&N.current&&v?E=d(D(D({},O),{},{className:v}),_):u||!c&&!v?E=d(D(D({},O),{},{style:{display:"none"}}),_):E=null;else {var T,A;M===rn?A="prepare":Mb(M)?A="active":M===lo&&(A="start");var I=Xv(h,"".concat(C,"-").concat(A));E=d(D(D({},O),{},{className:K(Xv(h,C),(T={},H(T,I,I&&A),H(T,h,typeof h=="string"),T)),style:R}),_);}if(f__namespace.isValidElement(E)&&fi(E)){var L=E,j=L.ref;j||(E=f__namespace.cloneElement(E,{ref:_}));}return f__namespace.createElement(hT,{ref:S},E)});return n.displayName="CSSMotion",n}const Mn=$T($b);var Sd="add",Cd="keep",xd="remove",cu="removed";function ET(e){var t;return e&&ot(e)==="object"&&"key"in e?t=e:t={key:e},D(D({},t),{},{key:String(t.key)})}function $d(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return e.map(ET)}function _T(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=[],n=0,i=t.length,o=$d(e),a=$d(t);o.forEach(function(c){for(var u=!1,d=n;d1});return l.forEach(function(c){r=r.filter(function(u){var d=u.key,h=u.status;return d!==c||h!==xd}),r.forEach(function(u){u.key===c&&(u.status=Cd);});}),r}var PT=["component","children","onVisibleChanged","onAllRemoved"],OT=["status"],TT=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function MT(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Mn,r=function(n){Lo(o,n);var i=Fo(o);function o(){var a;$r(this,o);for(var s=arguments.length,l=new Array(s),c=0;c{const[r,n]=os();return nd({theme:r,token:n,hashId:"",path:["ant-design-icons",e],nonce:()=>t==null?void 0:t.nonce},()=>[{[`.${e}`]:Object.assign(Object.assign({},hb()),{[`.${e} .${e}-icon`]:{display:"block"}})}])},IT=NT;var AT=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 i=0,n=Object.getOwnPropertySymbols(e);i{let{prefixCls:t,iconPrefixCls:r,theme:n}=e;t!==void 0&&(Rb=t),n&&oT(FT(),n);},jT=e=>{const{children:t,csp:r,autoInsertSpaceInButton:n,form:i,locale:o,componentSize:a,direction:s,space:l,virtual:c,dropdownMatchSelectWidth:u,popupMatchSelectWidth:d,popupOverflow:h,legacyLocale:v,parentContext:p,iconPrefixCls:m,theme:g,componentDisabled:b}=e,w=f__namespace.useCallback((T,A)=>{const{prefixCls:I}=e;if(A)return A;const L=I||p.getPrefixCls("");return T?`${L}-${T}`:L},[p.getPrefixCls,e.prefixCls]),S=m||p.iconPrefixCls||fb,$=S!==p.iconPrefixCls,x=r||p.csp,y=IT(S,x),C=uT(g,p.theme),M={csp:x,autoInsertSpaceInButton:n,locale:o||v,direction:s,space:l,virtual:c,popupMatchSelectWidth:d??u,popupOverflow:h,getPrefixCls:w,iconPrefixCls:S,theme:C},R=Object.assign({},p);Object.keys(M).forEach(T=>{M[T]!==void 0&&(R[T]=M[T]);}),kT.forEach(T=>{const A=e[T];A&&(R[T]=A);});const P=sc(()=>R,R,(T,A)=>{const I=Object.keys(T),L=Object.keys(A);return I.length!==L.length||I.some(j=>T[j]!==A[j])}),N=f__namespace.useMemo(()=>({prefixCls:S,csp:x}),[S,x]);let _=$?y(t):t;const E=f__namespace.useMemo(()=>{var T,A,I;return Ca({},((T=Af.Form)===null||T===void 0?void 0:T.defaultValidateMessages)||{},((I=(A=P.locale)===null||A===void 0?void 0:A.Form)===null||I===void 0?void 0:I.defaultValidateMessages)||{},(i==null?void 0:i.validateMessages)||{})},[P,i==null?void 0:i.validateMessages]);Object.keys(E).length>0&&(_=f__namespace.createElement(nb,{validateMessages:E},t)),o&&(_=f__namespace.createElement(yO,{locale:o,_ANT_MARK__:gO},_)),(S||x)&&(_=f__namespace.createElement(Nf.Provider,{value:N},_)),a&&(_=f__namespace.createElement(lT,{size:a},_)),_=f__namespace.createElement(RT,null,_);const O=f__namespace.useMemo(()=>{const T=C||{},{algorithm:A,token:I}=T,L=AT(T,["algorithm","token"]),j=A&&(!Array.isArray(A)||A.length>0)?qg(A):void 0;return Object.assign(Object.assign({},L),{theme:j,token:Object.assign(Object.assign({},hc),I)})},[C]);return g&&(_=f__namespace.createElement(mb.Provider,{value:O},_)),b!==void 0&&(_=f__namespace.createElement(aT,{disabled:b},_)),f__namespace.createElement(Wt.Provider,{value:P},_)},jo=e=>{const t=f__namespace.useContext(Wt),r=f__namespace.useContext(ob);return f__namespace.createElement(jT,Object.assign({parentContext:t,legacyLocale:r},e))};jo.ConfigContext=Wt;jo.SizeContext=mc;jo.config=DT;jo.useConfig=cT;Object.defineProperty(jo,"SizeContext",{get:()=>mc});const Nb=jo;function da(e,t,r,n){var i=$o.unstable_batchedUpdates?function(a){$o.unstable_batchedUpdates(r,a);}:r;return e.addEventListener&&e.addEventListener(t,i,n),{remove:function(){e.removeEventListener&&e.removeEventListener(t,i,n);}}}function zT(e,t){dr(e,"[@ant-design/icons] ".concat(t));}function Zv(e){return ot(e)==="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(ot(e.icon)==="object"||typeof e.icon=="function")}function Qv(){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 Ed(e,t,r){return r?f.createElement(e.tag,D(D({key:t},Qv(e.attrs)),r),(e.children||[]).map(function(n,i){return Ed(n,"".concat(t,"-").concat(e.tag,"-").concat(i))})):f.createElement(e.tag,D({key:t},Qv(e.attrs)),(e.children||[]).map(function(n,i){return Ed(n,"".concat(t,"-").concat(e.tag,"-").concat(i))}))}function Ib(e){return Un(e)[0]}function Ab(e){return e?Array.isArray(e)?e:[e]:[]}var HT=` .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); } } `,WT=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:HT,r=f.useContext(Nf),n=r.csp,i=r.prefixCls,o=t;i&&(o=o.replace(/anticon/g,i)),f.useEffect(function(){To(o,"@ant-design-icons",{prepend:!0,csp:n});},[]);},BT=["icon","className","onClick","style","primaryColor","secondaryColor"],xa={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1};function VT(e){var t=e.primaryColor,r=e.secondaryColor;xa.primaryColor=t,xa.secondaryColor=r||Ib(t),xa.calculated=!!r;}function UT(){return D({},xa)}var gc=function(t){var r=t.icon,n=t.className,i=t.onClick,o=t.style,a=t.primaryColor,s=t.secondaryColor,l=Xe(t,BT),c=xa;if(a&&(c={primaryColor:a,secondaryColor:s||Ib(a)}),WT(),zT(Zv(r),"icon should be icon definiton, but got ".concat(r)),!Zv(r))return null;var u=r;return u&&typeof u.icon=="function"&&(u=D(D({},u),{},{icon:u.icon(c.primaryColor,c.secondaryColor)})),Ed(u.icon,"svg-".concat(u.name),D({className:n,onClick:i,style:o,"data-icon":u.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},l))};gc.displayName="IconReact";gc.getTwoToneColors=UT;gc.setTwoToneColors=VT;const jf=gc;function kb(e){var t=Ab(e),r=W(t,2),n=r[0],i=r[1];return jf.setTwoToneColors({primaryColor:n,secondaryColor:i})}function GT(){var e=jf.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor}var KT=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];kb("#1890ff");var bc=f__namespace.forwardRef(function(e,t){var r,n=e.className,i=e.icon,o=e.spin,a=e.rotate,s=e.tabIndex,l=e.onClick,c=e.twoToneColor,u=Xe(e,KT),d=f__namespace.useContext(Nf),h=d.prefixCls,v=h===void 0?"anticon":h,p=d.rootClassName,m=K(p,v,(r={},H(r,"".concat(v,"-").concat(i.name),!!i.name),H(r,"".concat(v,"-spin"),!!o||i.name==="loading"),r),n),g=s;g===void 0&&l&&(g=-1);var b=a?{msTransform:"rotate(".concat(a,"deg)"),transform:"rotate(".concat(a,"deg)")}:void 0,w=Ab(c),S=W(w,2),$=S[0],x=S[1];return f__namespace.createElement("span",D(D({role:"img","aria-label":i.name},u),{},{ref:t,tabIndex:g,onClick:l,className:m}),f__namespace.createElement(jf,{icon:i,primaryColor:$,secondaryColor:x,style:b}))});bc.displayName="AntdIcon";bc.getTwoToneColor=GT;bc.setTwoToneColor=kb;const zo=bc;var qT={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 XT=qT;var Lb=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:XT}))};Lb.displayName="CloseOutlined";const Fb=f__namespace.forwardRef(Lb);function YT(e){return Object.keys(e).reduce((t,r)=>((r.startsWith("data-")||r.startsWith("aria-")||r==="role")&&!r.startsWith("data-__")&&(t[r]=e[r]),t),{})}const{isValidElement:zf}=f__namespace;function Db(e){return e&&zf(e)&&e.type===f__namespace.Fragment}function ZT(e,t,r){return zf(e)?f__namespace.cloneElement(e,typeof r=="function"?r(e.props||{}):r):t}function Ro(e,t){return ZT(e,e,t)}function nn(e){var t=f__namespace.useRef();t.current=e;var r=f__namespace.useCallback(function(){for(var n,i=arguments.length,o=new Array(i),a=0;a=Y.F1&&r<=Y.F12)return !1;switch(r){case Y.ALT:case Y.CAPS_LOCK:case Y.CONTEXT_MENU:case Y.CTRL:case Y.DOWN:case Y.END:case Y.ESC:case Y.HOME:case Y.INSERT:case Y.LEFT:case Y.MAC_FF_META:case Y.META:case Y.NUMLOCK:case Y.NUM_CENTER:case Y.PAGE_DOWN:case Y.PAGE_UP:case Y.PAUSE:case Y.PRINT_SCREEN:case Y.RIGHT:case Y.SHIFT:case Y.UP:case Y.WIN_KEY:case Y.WIN_KEY_RIGHT:return !1;default:return !0}},isCharacterKey:function(t){if(t>=Y.ZERO&&t<=Y.NINE||t>=Y.NUM_ZERO&&t<=Y.NUM_MULTIPLY||t>=Y.A&&t<=Y.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&t===0)return !0;switch(t){case Y.SPACE:case Y.QUESTION_MARK:case Y.NUM_PLUS:case Y.NUM_MINUS:case Y.NUM_PERIOD:case Y.NUM_DIVISION:case Y.SEMICOLON:case Y.DASH:case Y.EQUALS:case Y.COMMA:case Y.PERIOD:case Y.SLASH:case Y.APOSTROPHE:case Y.SINGLE_QUOTE:case Y.OPEN_SQUARE_BRACKET:case Y.BACKSLASH:case Y.CLOSE_SQUARE_BRACKET:return !0;default:return !1}}},QT={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 JT=QT;var jb=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:JT}))};jb.displayName="LoadingOutlined";const eM=f__namespace.forwardRef(jb);var ss=D({},$o__namespace),tM=ss.version,rM=ss.render,nM=ss.unmountComponentAtNode,yc;try{var iM=Number((tM||"").split(".")[0]);iM>=18&&(yc=ss.createRoot);}catch{}function Jv(e){var t=ss.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&ot(t)==="object"&&(t.usingClientEntryPoint=e);}var xl="__rc_react_root__";function oM(e,t){Jv(!0);var r=t[xl]||yc(t);Jv(!1),r.render(e),t[xl]=r;}function aM(e,t){rM(e,t);}function sM(e,t){if(yc){oM(e,t);return}aM(e,t);}function lM(e){return _d.apply(this,arguments)}function _d(){return _d=Fi(pr().mark(function e(t){return pr().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",Promise.resolve().then(function(){var i;(i=t[xl])===null||i===void 0||i.unmount(),delete t[xl];}));case 1:case"end":return n.stop()}},e)})),_d.apply(this,arguments)}function cM(e){nM(e);}function uM(e){return Pd.apply(this,arguments)}function Pd(){return Pd=Fi(pr().mark(function e(t){return pr().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(yc===void 0){n.next=2;break}return n.abrupt("return",lM(t));case 2:cM(t);case 3:case"end":return n.stop()}},e)})),Pd.apply(this,arguments)}const wc=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 i=e.getBoundingClientRect(),o=i.width,a=i.height;if(o||a)return !0}}return !1},dM=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}}}}},fM=Tn("Wave",e=>[dM(e)]);function hM(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 uu(e){return e&&e!=="#fff"&&e!=="#ffffff"&&e!=="rgb(255, 255, 255)"&&e!=="rgba(255, 255, 255, 1)"&&hM(e)&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&e!=="transparent"}function vM(e){const{borderTopColor:t,borderColor:r,backgroundColor:n}=getComputedStyle(e);return uu(t)?t:uu(r)?r:uu(n)?n:null}function du(e){return Number.isNaN(e)?0:e}const pM=e=>{const{className:t,target:r}=e,n=f__namespace.useRef(null),[i,o]=f__namespace.useState(null),[a,s]=f__namespace.useState([]),[l,c]=f__namespace.useState(0),[u,d]=f__namespace.useState(0),[h,v]=f__namespace.useState(0),[p,m]=f__namespace.useState(0),[g,b]=f__namespace.useState(!1),w={left:l,top:u,width:h,height:p,borderRadius:a.map($=>`${$}px`).join(" ")};i&&(w["--wave-color"]=i);function S(){const $=getComputedStyle(r);o(vM(r));const x=$.position==="static",{borderLeftWidth:y,borderTopWidth:C}=$;c(x?r.offsetLeft:du(-parseFloat(y))),d(x?r.offsetTop:du(-parseFloat(C))),v(r.offsetWidth),m(r.offsetHeight);const{borderTopLeftRadius:M,borderTopRightRadius:R,borderBottomLeftRadius:P,borderBottomRightRadius:N}=$;s([M,R,N,P].map(_=>du(parseFloat(_))));}return f__namespace.useEffect(()=>{if(r){const $=It(()=>{S(),b(!0);});let x;return typeof ResizeObserver<"u"&&(x=new ResizeObserver(S),x.observe(r)),()=>{It.cancel($),x==null||x.disconnect();}}},[]),g?f__namespace.createElement(Mn,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:($,x)=>{var y;if(x.deadline||x.propertyName==="opacity"){const C=(y=n.current)===null||y===void 0?void 0:y.parentElement;uM(C).then(()=>{C==null||C.remove();});}return !1}},$=>{let{className:x}=$;return f__namespace.createElement("div",{ref:n,className:K(t,x),style:w})}):null};function mM(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),sM(f__namespace.createElement(pM,{target:e,className:t}),r);}function gM(e,t){function r(){const n=e.current;mM(n,t);}return r}const bM=e=>{const{children:t,disabled:r}=e,{getPrefixCls:n}=f.useContext(Wt),i=f.useRef(null),o=n("wave"),[,a]=fM(o),s=gM(i,K(o,a));if(f.useEffect(()=>{const c=i.current;if(!c||c.nodeType!==1||r)return;const u=d=>{d.target.tagName==="INPUT"||!wc(d.target)||!c.getAttribute||c.getAttribute("disabled")||c.disabled||c.className.includes("disabled")||c.className.includes("-leave")||s();};return c.addEventListener("click",u,!0),()=>{c.removeEventListener("click",u,!0);}},[r]),!f.isValidElement(t))return t??null;const l=fi(t)?Kr(t.ref,i):i;return Ro(t,{ref:l})},zb=bM,yM=e=>{const{componentCls:t}=e;return {[t]:{display:"inline-flex","&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"}}}},wM=yM,SM=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"}}}},Hb=Tn("Space",e=>[SM(e),wM(e)],()=>({}),{resetStyle:!1});var Wb=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 i=0,n=Object.getOwnPropertySymbols(e);i{const r=f__namespace.useContext(Sc),n=f__namespace.useMemo(()=>{if(!r)return "";const{compactDirection:i,isFirstItem:o,isLastItem:a}=r,s=i==="vertical"?"-vertical-":"-";return K({[`${e}-compact${s}item`]:!0,[`${e}-compact${s}first-item`]:o,[`${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}},Od=e=>{let{children:t}=e;return f__namespace.createElement(Sc.Provider,{value:null},t)},CM=e=>{var{children:t}=e,r=Wb(e,["children"]);return f__namespace.createElement(Sc.Provider,{value:r},t)},xM=e=>{const{getPrefixCls:t,direction:r}=f__namespace.useContext(Wt),{size:n,direction:i,block:o,prefixCls:a,className:s,rootClassName:l,children:c}=e,u=Wb(e,["size","direction","block","prefixCls","className","rootClassName","children"]),d=Do(S=>{var $;return ($=n??S)!==null&&$!==void 0?$:"middle"}),h=t("space-compact",a),[v,p]=Hb(h),m=K(h,p,{[`${h}-rtl`]:r==="rtl",[`${h}-block`]:o,[`${h}-vertical`]:i==="vertical"},s,l),g=f__namespace.useContext(Sc),b=di(c),w=f__namespace.useMemo(()=>b.map((S,$)=>{const x=S&&S.key||`${h}-item-${$}`;return f__namespace.createElement(CM,{key:x,compactSize:d,compactDirection:i,isFirstItem:$===0&&(!g||(g==null?void 0:g.isFirstItem)),isLastItem:$===b.length-1&&(!g||(g==null?void 0:g.isLastItem))},S)}),[n,b,g]);return b.length===0?null:v(f__namespace.createElement("div",Object.assign({className:m},u),w))},$M=f.forwardRef((e,t)=>{const{className:r,style:n,children:i,prefixCls:o}=e,a=K(`${o}-icon`,r);return f.createElement("span",{ref:t,className:a,style:n},i)}),Vb=$M,ep=f.forwardRef((e,t)=>{let{prefixCls:r,className:n,style:i,iconClassName:o}=e;const a=K(`${r}-loading-icon`,n);return f.createElement(Vb,{prefixCls:r,className:a,style:i,ref:t},f.createElement(eM,{className:o}))}),fu=()=>({width:0,opacity:0,transform:"scale(0)"}),hu=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"}),EM=e=>{let{prefixCls:t,loading:r,existIcon:n,className:i,style:o}=e;const a=!!r;return n?f.createElement(ep,{prefixCls:t,className:i,style:o}):f.createElement(Mn,{visible:a,motionName:`${t}-loading-icon-motion`,removeOnLeave:!0,onAppearStart:fu,onAppearActive:hu,onEnterStart:fu,onEnterActive:hu,onLeaveStart:hu,onLeaveActive:fu},(s,l)=>{let{className:c,style:u}=s;return f.createElement(ep,{prefixCls:t,className:i,style:Object.assign(Object.assign({},o),u),ref:l,iconClassName:c})})},_M=EM;var PM=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{getPrefixCls:t,direction:r}=f__namespace.useContext(Wt),{prefixCls:n,size:i,className:o}=e,a=PM(e,["prefixCls","size","className"]),s=t("btn-group",n),[,,l]=os();let c="";switch(i){case"large":c="lg";break;case"small":c="sm";break}const u=K(s,{[`${s}-${c}`]:c,[`${s}-rtl`]:r==="rtl"},o,l);return f__namespace.createElement(Ub.Provider,{value:i},f__namespace.createElement("div",Object.assign({},a,{className:u})))},TM=OM,tp=/^[\u4e00-\u9fa5]{2}$/,Td=tp.test.bind(tp);function MM(e){return typeof e=="string"}function vu(e){return e==="text"||e==="link"}function RM(e,t){if(e==null)return;const r=t?" ":"";return typeof e!="string"&&typeof e!="number"&&MM(e.type)&&Td(e.props.children)?Ro(e,{children:e.props.children.split("").join(r)}):typeof e=="string"?Td(e)?f.createElement("span",null,e.split("").join(r)):f.createElement("span",null,e):Db(e)?f.createElement("span",null,e):e}function NM(e,t){let r=!1;const n=[];return f.Children.forEach(e,i=>{const o=typeof i,a=o==="string"||o==="number";if(r&&a){const s=n.length-1,l=n[s];n[s]=`${l}${i}`;}else n.push(i);r=a;}),f.Children.map(n,i=>RM(i,t))}function IM(e,t,r){const{focusElCls:n,focus:i,borderElCls:o}=r,a=o?"> *":"",s=["hover",i?"focus":null,"active"].filter(Boolean).map(l=>`&:${l} ${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 AM(e,t,r){const{borderElCls:n}=r,i=n?`> ${n}`:"";return {[`&-item:not(${t}-first-item):not(${t}-last-item) ${i}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${i}, &${e}-sm ${i}, &${e}-lg ${i}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${i}, &${e}-sm ${i}, &${e}-lg ${i}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function Gb(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({},IM(e,n,t)),AM(r,n,t))}}function kM(e,t){return {[`&-item:not(${t}-last-item)`]:{marginBottom:-e.lineWidth},"&-item":{"&:hover,&:focus,&:active":{zIndex:2},"&[disabled]":{zIndex:0}}}}function LM(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 FM(e){const t=`${e.componentCls}-compact-vertical`;return {[t]:Object.assign(Object.assign({},kM(e,t)),LM(e.componentCls,t))}}const rp=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}}),DM=e=>{const{componentCls:t,fontSize:r,lineWidth:n,colorPrimaryHover:i,colorErrorHover:o}=e;return {[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:-n,[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,[`&:hover, &:focus, &:active`]:{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:r}},rp(`${t}-primary`,i),rp(`${t}-danger`,o)]}},jM=DM,zM=e=>{const{componentCls:t,iconCls:r,buttonFontWeight:n}=e;return {[t]:{outline:"none",position:"relative",display:"inline-block",fontWeight:n,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"},[`${t}-icon`]:{lineHeight:0},[`&:not(${t}-icon-only) > ${t}-icon`]:{[`&${t}-loading-icon, &:not(:last-child)`]:{marginInlineEnd:e.marginXS}},[`> span + ${r}`]:{marginInlineStart:e.marginXS},"> a":{color:"currentColor"},"&:not(:disabled)":Object.assign({},Lf(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:'""'}}}}}}},Gn=(e,t)=>({"&:not(:disabled)":{"&:hover":e,"&:active":t}}),HM=e=>({minWidth:e.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),WM=e=>({borderRadius:e.controlHeight,paddingInlineStart:e.controlHeight/2,paddingInlineEnd:e.controlHeight/2}),Md=e=>({cursor:"not-allowed",borderColor:e.colorBorder,color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,boxShadow:"none"}),$l=(e,t,r,n,i,o,a)=>({[`&${e}-background-ghost`]:Object.assign(Object.assign({color:t||void 0,backgroundColor:"transparent",borderColor:r||void 0,boxShadow:"none"},Gn(Object.assign({backgroundColor:"transparent"},o),Object.assign({backgroundColor:"transparent"},a))),{"&:disabled":{cursor:"not-allowed",color:n||void 0,borderColor:i||void 0}})}),Hf=e=>({"&:disabled":Object.assign({},Md(e))}),Kb=e=>Object.assign({},Hf(e)),El=e=>({"&:disabled":{cursor:"not-allowed",color:e.colorTextDisabled}}),qb=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Kb(e)),{backgroundColor:e.colorBgContainer,borderColor:e.colorBorder,boxShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`}),Gn({color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),$l(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},Gn({color:e.colorErrorHover,borderColor:e.colorErrorBorderHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),$l(e.componentCls,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder)),Hf(e))}),BM=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Kb(e)),{color:e.colorTextLightSolid,backgroundColor:e.colorPrimary,boxShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`}),Gn({color:e.colorTextLightSolid,backgroundColor:e.colorPrimaryHover},{color:e.colorTextLightSolid,backgroundColor:e.colorPrimaryActive})),$l(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}`},Gn({backgroundColor:e.colorErrorHover},{backgroundColor:e.colorErrorActive})),$l(e.componentCls,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder,{color:e.colorErrorHover,borderColor:e.colorErrorHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),Hf(e))}),VM=e=>Object.assign(Object.assign({},qb(e)),{borderStyle:"dashed"}),UM=e=>Object.assign(Object.assign(Object.assign({color:e.colorLink},Gn({color:e.colorLinkHover},{color:e.colorLinkActive})),El(e)),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign({color:e.colorError},Gn({color:e.colorErrorHover},{color:e.colorErrorActive})),El(e))}),GM=e=>Object.assign(Object.assign(Object.assign({},Gn({color:e.colorText,backgroundColor:e.colorBgTextHover},{color:e.colorText,backgroundColor:e.colorBgTextActive})),El(e)),{[`&${e.componentCls}-dangerous`]:Object.assign(Object.assign({color:e.colorError},El(e)),Gn({color:e.colorErrorHover,backgroundColor:e.colorErrorBg},{color:e.colorErrorHover,backgroundColor:e.colorErrorBg}))}),KM=e=>Object.assign(Object.assign({},Md(e)),{[`&${e.componentCls}:hover`]:Object.assign({},Md(e))}),qM=e=>{const{componentCls:t}=e;return {[`${t}-default`]:qb(e),[`${t}-primary`]:BM(e),[`${t}-dashed`]:VM(e),[`${t}-link`]:UM(e),[`${t}-text`]:GM(e),[`${t}-disabled`]:KM(e)}},Wf=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const{componentCls:r,controlHeight:n,fontSize:i,lineHeight:o,lineWidth:a,borderRadius:s,buttonPaddingHorizontal:l,iconCls:c}=e,u=Math.max(0,(n-i*o)/2-a),d=l-a,h=`${r}-icon-only`;return [{[`${r}${t}`]:{fontSize:i,height:n,padding:`${u}px ${d}px`,borderRadius:s,[`&${h}`]:{width:n,paddingInlineStart:0,paddingInlineEnd:0,[`&${r}-round`]:{width:"auto"},[c]:{fontSize:e.buttonIconOnlyFontSize}},[`&${r}-loading`]:{opacity:e.opacityLoading,cursor:"default"},[`${r}-loading-icon`]:{transition:`width ${e.motionDurationSlow} ${e.motionEaseInOut}, opacity ${e.motionDurationSlow} ${e.motionEaseInOut}`}}},{[`${r}${r}-circle${t}`]:HM(e)},{[`${r}${r}-round${t}`]:WM(e)}]},XM=e=>Wf(e),YM=e=>{const t=mr(e,{controlHeight:e.controlHeightSM,padding:e.paddingXS,buttonPaddingHorizontal:8,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.fontSizeLG-2});return Wf(t,`${e.componentCls}-sm`)},ZM=e=>{const t=mr(e,{controlHeight:e.controlHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.fontSizeLG+2});return Wf(t,`${e.componentCls}-lg`)},QM=e=>{const{componentCls:t}=e;return {[t]:{[`&${t}-block`]:{width:"100%"}}}},JM=Tn("Button",e=>{const{controlTmpOutline:t,paddingContentHorizontal:r}=e,n=mr(e,{colorOutlineDefault:t,buttonPaddingHorizontal:r,buttonIconOnlyFontSize:e.fontSizeLG,buttonFontWeight:400});return [zM(n),YM(n),XM(n),ZM(n),QM(n),qM(n),jM(n),Gb(e),FM(e)]});var eR=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{loading:r=!1,prefixCls:n,type:i="default",danger:o,shape:a="default",size:s,styles:l,disabled:c,className:u,rootClassName:d,children:h,icon:v,ghost:p=!1,block:m=!1,htmlType:g="button",classNames:b}=e,w=eR(e,["loading","prefixCls","type","danger","shape","size","styles","disabled","className","rootClassName","children","icon","ghost","block","htmlType","classNames"]),{getPrefixCls:S,autoInsertSpaceInButton:$,direction:x}=f.useContext(Wt),y=S("btn",n),[C,M]=JM(y),R=f.useContext(as),P=c??R,N=f.useContext(Ub),_=f.useMemo(()=>tR(r),[r]),[E,O]=f.useState(_.loading),[T,A]=f.useState(!1),L=Kr(t,f.createRef()),j=f.Children.count(h)===1&&!v&&!vu(i);f.useEffect(()=>{let oe=null;_.delay>0?oe=setTimeout(()=>{oe=null,O(!0);},_.delay):O(_.loading);function se(){oe&&(clearTimeout(oe),oe=null);}return se},[_]),f.useEffect(()=>{if(!L||!L.current||$===!1)return;const oe=L.current.textContent;j&&Td(oe)?T||A(!0):T&&A(!1);},[L]);const B=oe=>{const{onClick:se}=e;if(E||P){oe.preventDefault();return}se==null||se(oe);},G=$!==!1,{compactSize:z,compactItemClassnames:V}=Bb(y,x),q={large:"lg",small:"sm",middle:void 0},U=Do(oe=>{var se,re;return (re=(se=z??N)!==null&&se!==void 0?se:s)!==null&&re!==void 0?re:oe}),Q=U&&q[U]||"",ie=E?"loading":v,Z=uc(w,["navigate"]),te=Z.href!==void 0&&P,ae=K(y,M,{[`${y}-${a}`]:a!=="default"&&a,[`${y}-${i}`]:i,[`${y}-${Q}`]:Q,[`${y}-icon-only`]:!h&&h!==0&&!!ie,[`${y}-background-ghost`]:p&&!vu(i),[`${y}-loading`]:E,[`${y}-two-chinese-chars`]:T&&G&&!E,[`${y}-block`]:m,[`${y}-dangerous`]:!!o,[`${y}-rtl`]:x==="rtl",[`${y}-disabled`]:te},V,u,d),ue=v&&!E?f.createElement(Vb,{prefixCls:y,className:b==null?void 0:b.icon,style:l==null?void 0:l.icon},v):f.createElement(_M,{existIcon:!!v,prefixCls:y,loading:!!E}),Ee=h||h===0?NM(h,j&&G):null;if(Z.href!==void 0)return C(f.createElement("a",Object.assign({},Z,{className:ae,onClick:B,ref:L}),ue,Ee));let J=f.createElement("button",Object.assign({},w,{type:g,className:ae,onClick:B,disabled:P,ref:L}),ue,Ee);return vu(i)||(J=f.createElement(zb,{disabled:!!E},J)),C(J)},Bf=f.forwardRef(rR);Bf.Group=TM;Bf.__ANT_BUTTON=!0;const an=Bf,Xb=(e,t,r)=>r!==void 0?r:`${e}-${t}`;var Yb=f__namespace.createContext(null),Gt=Sr()?f__namespace.useLayoutEffect:f__namespace.useEffect,po=function(t,r){var n=f__namespace.useRef(!0);Gt(function(){if(!n.current)return t()},r),Gt(function(){return n.current=!1,function(){n.current=!0;}},[]);},np=[];function nR(e,t){var r=f__namespace.useState(function(){if(!Sr())return null;var p=document.createElement("div");return p}),n=W(r,1),i=n[0],o=f__namespace.useRef(!1),a=f__namespace.useContext(Yb),s=f__namespace.useState(np),l=W(s,2),c=l[0],u=l[1],d=a||(o.current?void 0:function(p){u(function(m){var g=[p].concat(le(m));return g});});function h(){i.parentElement||document.body.appendChild(i),o.current=!0;}function v(){var p;(p=i.parentElement)===null||p===void 0||p.removeChild(i),o.current=!1;}return Gt(function(){return e?a?a(h):h():v(),v},[e]),Gt(function(){c.length&&(c.forEach(function(p){return p()}),u(np));},[c]),[i,d]}var pu;function iR(e){if(typeof document>"u")return 0;if(e||pu===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 i=t.offsetWidth;r.style.overflow="scroll";var o=t.offsetWidth;i===o&&(o=r.clientWidth),document.body.removeChild(r),pu=i-o;}return pu}function oR(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}var aR="rc-util-locker-".concat(Date.now()),ip=0;function sR(e){var t=!!e,r=f__namespace.useState(function(){return ip+=1,"".concat(aR,"_").concat(ip)}),n=W(r,1),i=n[0];Gt(function(){if(t){var o=iR(),a=oR();To(` html body { overflow-y: hidden; `.concat(a?"width: calc(100% - ".concat(o,"px);"):"",` }`),i);}else yl(i);return function(){yl(i);}},[t,i]);}var op=!1;function lR(e){return typeof e=="boolean"&&(op=e),op}var ap=function(t){return t===!1?!1:!Sr()||!t?null:typeof t=="string"?document.querySelector(t):typeof t=="function"?t():t},Zb=f__namespace.forwardRef(function(e,t){var r=e.open,n=e.autoLock,i=e.getContainer;e.debug;var o=e.autoDestroy,a=o===void 0?!0:o,s=e.children,l=f__namespace.useState(r),c=W(l,2),u=c[0],d=c[1],h=u||r;f__namespace.useEffect(function(){(a||r)&&d(r);},[r,a]);var v=f__namespace.useState(function(){return ap(i)}),p=W(v,2),m=p[0],g=p[1];f__namespace.useEffect(function(){var N=ap(i);g(N??null);});var b=nR(h&&!m),w=W(b,2),S=w[0],$=w[1],x=m??S;sR(n&&r&&Sr()&&(x===S||x===document.body));var y=null;if(s&&fi(s)&&t){var C=s;y=C.ref;}var M=lc(y,t);if(!h||!Sr()||m===void 0)return null;var R=x===!1||lR(),P=s;return t&&(P=f__namespace.cloneElement(s,{ref:M})),f__namespace.createElement(Yb.Provider,{value:$},R?P:$o.createPortal(P,x))});function cR(){var e=D({},f__namespace);return e.useId}var sp=0;function uR(e){var t=f__namespace.useState("ssr-id"),r=W(t,2),n=r[0],i=r[1],o=cR(),a=o==null?void 0:o();return f__namespace.useEffect(function(){if(!o){var s=sp;sp+=1,i("rc_unique_".concat(s));}},[]),e||a||n}const za=f__namespace.createContext({}),lp=e=>{let{children:t,status:r,override:n}=e;const i=f.useContext(za),o=f.useMemo(()=>{const a=Object.assign({},i);return n&&delete a.isFormItemInput,r&&(delete a.status,delete a.hasFeedback,delete a.feedbackIcon),a},[r,n,i]);return f__namespace.createElement(za.Provider,{value:o},t)},dR=()=>Sr()&&window.document.documentElement;let As;const fR=()=>{if(!dR())return !1;if(As!==void 0)return As;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),As=e.scrollHeight===1,document.body.removeChild(e),As},hR=e=>({animationDuration:e,animationFillMode:"both"}),vR=e=>({animationDuration:e,animationFillMode:"both"}),Qb=function(e,t,r,n){const o=(arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1)?"&":"";return {[` ${o}${e}-enter, ${o}${e}-appear `]:Object.assign(Object.assign({},hR(n)),{animationPlayState:"paused"}),[`${o}${e}-leave`]:Object.assign(Object.assign({},vR(n)),{animationPlayState:"paused"}),[` ${o}${e}-enter${e}-enter-active, ${o}${e}-appear${e}-appear-active `]:{animationName:t,animationPlayState:"running"},[`${o}${e}-leave${e}-leave-active`]:{animationName:r,animationPlayState:"running",pointerEvents:"none"}}},pR=new Dt("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),mR=new Dt("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),gR=new Dt("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),bR=new Dt("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),yR=new Dt("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),wR=new Dt("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}}),SR=new Dt("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),CR=new Dt("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}}),xR={"slide-up":{inKeyframes:pR,outKeyframes:mR},"slide-down":{inKeyframes:gR,outKeyframes:bR},"slide-left":{inKeyframes:yR,outKeyframes:wR},"slide-right":{inKeyframes:SR,outKeyframes:CR}},cp=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:i,outKeyframes:o}=xR[t];return [Qb(n,i,o,e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:e.motionEaseOutQuint,["&-prepare"]:{transform:"scale(1)"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInQuint}}]},$R=new Dt("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),ER=new Dt("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),up=new Dt("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),dp=new Dt("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),_R=new Dt("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),PR=new Dt("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),OR=new Dt("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),TR=new Dt("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),MR=new Dt("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),RR=new Dt("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),NR=new Dt("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),IR=new Dt("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),AR={zoom:{inKeyframes:$R,outKeyframes:ER},"zoom-big":{inKeyframes:up,outKeyframes:dp},"zoom-big-fast":{inKeyframes:up,outKeyframes:dp},"zoom-left":{inKeyframes:OR,outKeyframes:TR},"zoom-right":{inKeyframes:MR,outKeyframes:RR},"zoom-up":{inKeyframes:_R,outKeyframes:PR},"zoom-down":{inKeyframes:NR,outKeyframes:IR}},kR=(e,t)=>{const{antCls:r}=e,n=`${r}-${t}`,{inKeyframes:i,outKeyframes:o}=AR[t];return [Qb(n,i,o,t==="zoom-big-fast"?e.motionDurationFast:e.motionDurationMid),{[` ${n}-enter, ${n}-appear `]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${n}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]};function mu(e){return e!==void 0}function Cn(e,t){var r=t||{},n=r.defaultValue,i=r.value,o=r.onChange,a=r.postState,s=Mi(function(){return mu(i)?i:mu(n)?typeof n=="function"?n():n:typeof e=="function"?e():e}),l=W(s,2),c=l[0],u=l[1],d=i!==void 0?i:c,h=a?a(d):d,v=nn(o),p=Mi([d]),m=W(p,2),g=m[0],b=m[1];po(function(){var S=g[0];c!==S&&v(c,S);},[g]),po(function(){mu(i)||u(i);},[i]);var w=nn(function(S,$){u(S,$),b([d],$);});return [h,w]}const Cc=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 LR=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],Yi=void 0;function FR(e,t){var r=e.prefixCls,n=e.invalidate,i=e.item,o=e.renderItem,a=e.responsive,s=e.responsiveDisabled,l=e.registerSize,c=e.itemKey,u=e.className,d=e.style,h=e.children,v=e.display,p=e.order,m=e.component,g=m===void 0?"div":m,b=Xe(e,LR),w=a&&!v;function S(M){l(c,M);}f__namespace.useEffect(function(){return function(){S(null);}},[]);var $=o&&i!==Yi?o(i):h,x;n||(x={opacity:w?0:1,height:w?0:Yi,overflowY:w?"hidden":Yi,order:a?p:Yi,pointerEvents:w?"none":Yi,position:w?"absolute":Yi});var y={};w&&(y["aria-hidden"]=!0);var C=f__namespace.createElement(g,Ce({className:K(!n&&r,u),style:D(D({},x),d)},y,b,{ref:t}),$);return a&&(C=f__namespace.createElement(Ai,{onResize:function(R){var P=R.offsetWidth;S(P);},disabled:s},C)),C}var $a=f__namespace.forwardRef(FR);$a.displayName="Item";function DR(e){if(typeof MessageChannel>"u")It(e);else {var t=new MessageChannel;t.port1.onmessage=function(){return e()},t.port2.postMessage(void 0);}}function jR(){var e=f__namespace.useRef(null),t=function(n){e.current||(e.current=[],DR(function(){$o.unstable_batchedUpdates(function(){e.current.forEach(function(i){i();}),e.current=null;});})),e.current.push(n);};return t}function ea(e,t){var r=f__namespace.useState(t),n=W(r,2),i=n[0],o=n[1],a=nn(function(s){e(function(){o(s);});});return [i,a]}var zR=["component"],HR=["className"],WR=["className"],BR=function(t,r){var n=f__namespace.useContext(_l);if(!n){var i=t.component,o=i===void 0?"div":i,a=Xe(t,zR);return f__namespace.createElement(o,Ce({},a,{ref:r}))}var s=n.className,l=Xe(n,HR),c=t.className,u=Xe(t,WR);return f__namespace.createElement(_l.Provider,{value:null},f__namespace.createElement($a,Ce({ref:r,className:K(s,c)},l,u)))},Jb=f__namespace.forwardRef(BR);Jb.displayName="RawItem";var VR=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],_l=f__namespace.createContext(null),e0="responsive",t0="invalidate";function UR(e){return "+ ".concat(e.length," ...")}function GR(e,t){var r=e.prefixCls,n=r===void 0?"rc-overflow":r,i=e.data,o=i===void 0?[]:i,a=e.renderItem,s=e.renderRawItem,l=e.itemKey,c=e.itemWidth,u=c===void 0?10:c,d=e.ssr,h=e.style,v=e.className,p=e.maxCount,m=e.renderRest,g=e.renderRawRest,b=e.suffix,w=e.component,S=w===void 0?"div":w,$=e.itemComponent,x=e.onVisibleChange,y=Xe(e,VR),C=d==="full",M=jR(),R=ea(M,null),P=W(R,2),N=P[0],_=P[1],E=N||0,O=ea(M,new Map),T=W(O,2),A=T[0],I=T[1],L=ea(M,0),j=W(L,2),B=j[0],G=j[1],z=ea(M,0),V=W(z,2),q=V[0],U=V[1],Q=ea(M,0),ie=W(Q,2),Z=ie[0],te=ie[1],ae=f.useState(null),ue=W(ae,2),Ee=ue[0],J=ue[1],oe=f.useState(null),se=W(oe,2),re=se[0],xe=se[1],de=f__namespace.useMemo(function(){return re===null&&C?Number.MAX_SAFE_INTEGER:re||0},[re,N]),ge=f.useState(!1),ve=W(ge,2),$e=ve[0],Ye=ve[1],dt="".concat(n,"-item"),xt=Math.max(B,q),tt=p===e0,ke=o.length&&tt,Fe=p===t0,Oe=ke||typeof p=="number"&&o.length>p,De=f.useMemo(function(){var be=o;return ke?N===null&&C?be=o:be=o.slice(0,Math.min(o.length,E/u)):typeof p=="number"&&(be=o.slice(0,p)),be},[o,u,N,p,ke]),Te=f.useMemo(function(){return ke?o.slice(de+1):o.slice(De.length)},[o,De,ke,de]),He=f.useCallback(function(be,We){var Ue;return typeof l=="function"?l(be):(Ue=l&&(be==null?void 0:be[l]))!==null&&Ue!==void 0?Ue:We},[l]),rt=f.useCallback(a||function(be){return be},[a]);function ft(be,We,Ue){re===be&&(We===void 0||We===Ee)||(xe(be),Ue||(Ye(beE){ft(Et-1,be-_t-Z+q);break}}b&&wt(0)+Z>E&&J(null);}},[E,A,q,Z,He,De]);var fe=$e&&!!Te.length,ce={};Ee!==null&&ke&&(ce={position:"absolute",left:Ee,top:0});var _e={prefixCls:dt,responsive:ke,component:$,invalidate:Fe},we=s?function(be,We){var Ue=He(be,We);return f__namespace.createElement(_l.Provider,{key:Ue,value:D(D({},_e),{},{order:We,item:be,itemKey:Ue,registerSize:Ze,display:We<=de})},s(be,We))}:function(be,We){var Ue=He(be,We);return f__namespace.createElement($a,Ce({},_e,{order:We,key:Ue,item:be,renderItem:rt,itemKey:Ue,registerSize:Ze,display:We<=de}))},Ve,$t={order:fe?de:Number.MAX_SAFE_INTEGER,className:"".concat(dt,"-rest"),registerSize:at,display:fe};if(g)g&&(Ve=f__namespace.createElement(_l.Provider,{value:D(D({},_e),$t)},g(Te)));else {var At=m||UR;Ve=f__namespace.createElement($a,Ce({},_e,$t),typeof At=="function"?At(Te):At);}var kt=f__namespace.createElement(S,Ce({className:K(!Fe&&n,v),style:h,ref:t},y),De.map(we),Oe?Ve:null,b&&f__namespace.createElement($a,Ce({},_e,{responsive:tt,responsiveDisabled:!ke,order:de,className:"".concat(dt,"-suffix"),registerSize:st,display:!0,style:ce}),b));return tt&&(kt=f__namespace.createElement(Ai,{onResize:Ke,disabled:!ke},kt)),kt}var Wn=f__namespace.forwardRef(GR);Wn.displayName="Overflow";Wn.Item=Jb;Wn.RESPONSIVE=e0;Wn.INVALIDATE=t0;var fp=f__namespace.createContext(null);function hp(e){return e?Array.isArray(e)?e:[e]:[]}function KR(e,t,r,n){return f__namespace.useMemo(function(){var i=hp(r??t),o=hp(n??t),a=new Set(i),s=new Set(o);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 qR(){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 XR(e,t,r,n){for(var i=r.points,o=Object.keys(e),a=0;a1&&arguments[1]!==void 0?arguments[1]:1;return Number.isNaN(e)?t:e}function ta(e){return Ha(parseFloat(e),0)}function pp(e,t){var r=D({},e);return (t||[]).forEach(function(n){if(!(n instanceof HTMLBodyElement)){var i=ls(n).getComputedStyle(n),o=i.overflow,a=i.overflowClipMargin,s=i.borderTopWidth,l=i.borderBottomWidth,c=i.borderLeftWidth,u=i.borderRightWidth,d=n.getBoundingClientRect(),h=n.offsetHeight,v=n.clientHeight,p=n.offsetWidth,m=n.clientWidth,g=ta(s),b=ta(l),w=ta(c),S=ta(u),$=Ha(Math.round(d.width/p*1e3)/1e3),x=Ha(Math.round(d.height/h*1e3)/1e3),y=(p-m-w-S)*$,C=(h-v-g-b)*x,M=g*x,R=b*x,P=w*$,N=S*$,_=0,E=0;if(o==="clip"){var O=ta(a);_=O*$,E=O*x;}var T=d.x+P-_,A=d.y+M-E,I=T+d.width+2*_-P-N-y,L=A+d.height+2*E-M-R-C;r.left=Math.max(r.left,T),r.top=Math.max(r.top,A),r.right=Math.min(r.right,I),r.bottom=Math.min(r.bottom,L);}}),r}function mp(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r="".concat(t),n=r.match(/^(.*)\%$/);return n?e*(parseFloat(n[1])/100):parseFloat(r)}function gp(e,t){var r=t||[],n=W(r,2),i=n[0],o=n[1];return [mp(e.width,i),mp(e.height,o)]}function bp(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return [e[0],e[1]]}function Zi(e,t){var r=t[0],n=t[1],i,o;return r==="t"?o=e.y:r==="b"?o=e.y+e.height:o=e.y+e.height/2,n==="l"?i=e.x:n==="r"?i=e.x+e.width:i=e.x+e.width/2,{x:i,y:o}}function Qn(e,t){var r={t:"b",b:"t",l:"r",r:"l"};return e.map(function(n,i){return i===t?r[n]||"c":n}).join("")}function YR(e,t,r,n,i,o,a){var s=f__namespace.useState({ready:!1,offsetX:0,offsetY:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:i[n]||{}}),l=W(s,2),c=l[0],u=l[1],d=f__namespace.useRef(0),h=f__namespace.useMemo(function(){return t?Rd(t):[]},[t]),v=f__namespace.useRef({}),p=function(){v.current={};};e||p();var m=nn(function(){if(t&&r&&e){let qe=function(zt,Qt){var hr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:J,vi=P.x+zt,pi=P.y+Qt,zc=vi+z,Hc=pi+G,ms=Math.max(vi,hr.left),gs=Math.max(pi,hr.top),qo=Math.min(zc,hr.right),bs=Math.min(Hc,hr.bottom);return Math.max(0,(qo-ms)*(bs-gs))},Vt=function(){Et=P.y+st,_t=Et+G,gr=P.x+at,fr=gr+z;};var w=t,S=w.style.left,$=w.style.top,x=w.ownerDocument,y=ls(w),C=D(D({},i[n]),o);w.style.left="0",w.style.top="0";var M;if(Array.isArray(r))M={x:r[0],y:r[1],width:0,height:0};else {var R=r.getBoundingClientRect();M={x:R.x,y:R.y,width:R.width,height:R.height};}var P=w.getBoundingClientRect(),N=y.getComputedStyle(w),_=N.width,E=N.height,O=x.documentElement,T=O.clientWidth,A=O.clientHeight,I=O.scrollWidth,L=O.scrollHeight,j=O.scrollTop,B=O.scrollLeft,G=P.height,z=P.width,V=M.height,q=M.width,U={left:0,top:0,right:T,bottom:A},Q={left:-B,top:-j,right:I-B,bottom:L-j},ie=C.htmlRegion,Z="visible",te="visibleFirst";ie!=="scroll"&&ie!==te&&(ie=Z);var ae=ie===te,ue=pp(Q,h),Ee=pp(U,h),J=ie===Z?Ee:ue,oe=ae?Ee:J;w.style.left=S,w.style.top=$;var se=Ha(Math.round(z/parseFloat(_)*1e3)/1e3),re=Ha(Math.round(G/parseFloat(E)*1e3)/1e3);if(se===0||re===0||pl(r)&&!wc(r))return;var xe=C.offset,de=C.targetOffset,ge=gp(P,xe),ve=W(ge,2),$e=ve[0],Ye=ve[1],dt=gp(M,de),xt=W(dt,2),tt=xt[0],ke=xt[1];M.x-=tt,M.y-=ke;var Fe=C.points||[],Oe=W(Fe,2),De=Oe[0],Te=Oe[1],He=bp(Te),rt=bp(De),ft=Zi(M,He),Ke=Zi(P,rt),Ze=D({},C),at=ft.x-Ke.x+$e,st=ft.y-Ke.y+Ye,wt=qe(at,st),fe=qe(at,st,Ee),ce=Zi(M,["t","l"]),_e=Zi(P,["t","l"]),we=Zi(M,["b","r"]),Ve=Zi(P,["b","r"]),$t=C.overflow||{},At=$t.adjustX,kt=$t.adjustY,be=$t.shiftX,We=$t.shiftY,Ue=function(Qt){return typeof Qt=="boolean"?Qt:Qt>=0},Et,_t,gr,fr;Vt();var Lt=Ue(kt),zr=rt[0]===He[0];if(Lt&&rt[0]==="t"&&(_t>oe.bottom||v.current.bt)){var tr=st;zr?tr-=G-V:tr=ce.y-Ve.y-Ye;var Ge=qe(at,tr),Ie=qe(at,tr,Ee);Ge>wt||Ge===wt&&(!ae||Ie>=fe)?(v.current.bt=!0,st=tr,Ze.points=[Qn(rt,0),Qn(He,0)]):v.current.bt=!1;}if(Lt&&rt[0]==="b"&&(Etwt||ht===wt&&(!ae||nt>=fe)?(v.current.tb=!0,st=pe,Ze.points=[Qn(rt,0),Qn(He,0)]):v.current.tb=!1;}var ar=Ue(At),Pe=rt[1]===He[1];if(ar&&rt[1]==="l"&&(fr>oe.right||v.current.rl)){var ye=at;Pe?ye-=z-q:ye=ce.x-Ve.x-$e;var Be=qe(ye,st),Mt=qe(ye,st,Ee);Be>wt||Be===wt&&(!ae||Mt>=fe)?(v.current.rl=!0,at=ye,Ze.points=[Qn(rt,1),Qn(He,1)]):v.current.rl=!1;}if(ar&&rt[1]==="r"&&(grwt||Rt===wt&&(!ae||Pr>=fe)?(v.current.lr=!0,at=jt,Ze.points=[Qn(rt,1),Qn(He,1)]):v.current.lr=!1;}Vt();var qr=be===!0?0:be;typeof qr=="number"&&(grJ.right&&(at-=fr-J.right,M.x>J.right-qr&&(at+=M.x-J.right+qr)));var Rn=We===!0?0:We;typeof Rn=="number"&&(EtJ.bottom&&(st-=_t-J.bottom,M.y>J.bottom-Rn&&(st+=M.y-J.bottom+Rn)));var hi=P.x+at,Zn=hi+z,cn=P.y+st,Or=cn+G,zi=M.x,Bo=zi+q,Hi=M.y,Wi=Hi+V,Bi=Math.max(hi,zi),Vo=Math.min(Zn,Bo),Uo=(Bi+Vo)/2,Go=Uo-hi,Vi=Math.max(cn,Hi),Ko=Math.min(Or,Wi),St=(Vi+Ko)/2,lt=St-cn;a==null||a(t,Ze),u({ready:!0,offsetX:at/se,offsetY:st/re,arrowX:Go/se,arrowY:lt/re,scaleX:se,scaleY:re,align:Ze});}}),g=function(){d.current+=1;var S=d.current;Promise.resolve().then(function(){d.current===S&&m();});},b=function(){u(function(S){return D(D({},S),{},{ready:!1})});};return Gt(b,[n]),Gt(function(){e||b();},[e]),[c.ready,c.offsetX,c.offsetY,c.arrowX,c.arrowY,c.scaleX,c.scaleY,c.align,g]}function ZR(e,t,r,n){Gt(function(){if(e&&t&&r){let u=function(){n();};var i=t,o=r,a=Rd(i),s=Rd(o),l=ls(o),c=new Set([l].concat(le(a),le(s)));return c.forEach(function(d){d.addEventListener("scroll",u,{passive:!0});}),l.addEventListener("resize",u,{passive:!0}),n(),function(){c.forEach(function(d){d.removeEventListener("scroll",u),l.removeEventListener("resize",u);});}}},[e,t,r]);}function QR(e){var t=e.prefixCls,r=e.align,n=e.arrow,i=e.arrowPos,o=n||{},a=o.className,s=o.content,l=i.x,c=l===void 0?0:l,u=i.y,d=u===void 0?0:u,h=f__namespace.useRef();if(!r||!r.points)return null;var v={position:"absolute"};if(r.autoArrow!==!1){var p=r.points[0],m=r.points[1],g=p[0],b=p[1],w=m[0],S=m[1];g===w||!["t","b"].includes(g)?v.top=d:g==="t"?v.top=0:v.bottom=0,b===S||!["l","r"].includes(b)?v.left=c:b==="l"?v.left=0:v.right=0;}return f__namespace.createElement("div",{ref:h,className:K("".concat(t,"-arrow"),a),style:v},s)}function JR(e){var t=e.prefixCls,r=e.open,n=e.zIndex,i=e.mask,o=e.motion;return i?f__namespace.createElement(Mn,Ce({},o,{motionAppear:!0,visible:r,removeOnLeave:!0}),function(a){var s=a.className;return f__namespace.createElement("div",{style:{zIndex:n},className:K("".concat(t,"-mask"),s)})}):null}var eN=f__namespace.memo(function(e){var t=e.children;return t},function(e,t){return t.cache}),tN=f__namespace.forwardRef(function(e,t){var r=e.popup,n=e.className,i=e.prefixCls,o=e.style,a=e.target,s=e.onVisibleChanged,l=e.open,c=e.keepDom,u=e.onClick,d=e.mask,h=e.arrow,v=e.arrowPos,p=e.align,m=e.motion,g=e.maskMotion,b=e.forceRender,w=e.getPopupContainer,S=e.autoDestroy,$=e.portal,x=e.zIndex,y=e.onMouseEnter,C=e.onMouseLeave,M=e.ready,R=e.offsetX,P=e.offsetY,N=e.onAlign,_=e.onPrepare,E=e.stretch,O=e.targetWidth,T=e.targetHeight,A=typeof r=="function"?r():r,I=l||c,L=(w==null?void 0:w.length)>0,j=f__namespace.useState(!w||!L),B=W(j,2),G=B[0],z=B[1];if(Gt(function(){!G&&L&&a&&z(!0);},[G,L,a]),!G)return null;var V=M||!l?{left:R,top:P}:{left:"-1000vw",top:"-1000vh"},q={};return E&&(E.includes("height")&&T?q.height=T:E.includes("minHeight")&&T&&(q.minHeight=T),E.includes("width")&&O?q.width=O:E.includes("minWidth")&&O&&(q.minWidth=O)),l||(q.pointerEvents="none"),f__namespace.createElement($,{open:b||I,getContainer:w&&function(){return w(a)},autoDestroy:S},f__namespace.createElement(JR,{prefixCls:i,open:l,zIndex:x,mask:d,motion:g}),f__namespace.createElement(Ai,{onResize:N,disabled:!l},function(U){return f__namespace.createElement(Mn,Ce({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:b,leavedClassName:"".concat(i,"-hidden")},m,{onAppearPrepare:_,onEnterPrepare:_,visible:l,onVisibleChanged:function(ie){var Z;m==null||(Z=m.onVisibleChanged)===null||Z===void 0||Z.call(m,ie),s(ie);}}),function(Q,ie){var Z=Q.className,te=Q.style,ae=K(i,Z,n);return f__namespace.createElement("div",{ref:Kr(U,t,ie),className:ae,style:D(D(D(D({"--arrow-x":"".concat(v.x||0,"px"),"--arrow-y":"".concat(v.y||0,"px")},V),q),te),{},{boxSizing:"border-box",zIndex:x},o),onMouseEnter:y,onMouseLeave:C,onClick:u},h&&f__namespace.createElement(QR,{prefixCls:i,arrow:h,arrowPos:v,align:p}),f__namespace.createElement(eN,{cache:!l},A))})}))}),rN=f__namespace.forwardRef(function(e,t){var r=e.children,n=e.getTriggerDOMNode,i=fi(r),o=f__namespace.useCallback(function(s){Pf(t,n?n(s):s);},[n]),a=lc(o,r.ref);return i?f__namespace.cloneElement(r,{ref:a}):r}),nN=["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 iN(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Zb,t=f__namespace.forwardRef(function(r,n){var i=r.prefixCls,o=i===void 0?"rc-trigger-popup":i,a=r.children,s=r.action,l=s===void 0?"hover":s,c=r.showAction,u=r.hideAction,d=r.popupVisible,h=r.defaultPopupVisible,v=r.onPopupVisibleChange,p=r.afterPopupVisibleChange,m=r.mouseEnterDelay,g=r.mouseLeaveDelay,b=g===void 0?.1:g,w=r.focusDelay,S=r.blurDelay,$=r.mask,x=r.maskClosable,y=x===void 0?!0:x,C=r.getPopupContainer,M=r.forceRender,R=r.autoDestroy,P=r.destroyPopupOnHide,N=r.popup,_=r.popupClassName,E=r.popupStyle,O=r.popupPlacement,T=r.builtinPlacements,A=T===void 0?{}:T,I=r.popupAlign,L=r.zIndex,j=r.stretch,B=r.getPopupClassNameFromAlign,G=r.alignPoint,z=r.onPopupClick,V=r.onPopupAlign,q=r.arrow,U=r.popupMotion,Q=r.maskMotion,ie=r.popupTransitionName,Z=r.popupAnimation,te=r.maskTransitionName,ae=r.maskAnimation,ue=r.className,Ee=r.getTriggerDOMNode,J=Xe(r,nN),oe=R||P||!1,se=f__namespace.useState(!1),re=W(se,2),xe=re[0],de=re[1];Gt(function(){de(Cc());},[]);var ge=f__namespace.useRef({}),ve=f__namespace.useContext(fp),$e=f__namespace.useMemo(function(){return {registerSubPopup:function(Me,pt){ge.current[Me]=pt,ve==null||ve.registerSubPopup(Me,pt);}}},[ve]),Ye=uR(),dt=f__namespace.useState(null),xt=W(dt,2),tt=xt[0],ke=xt[1],Fe=nn(function(me){pl(me)&&tt!==me&&ke(me),ve==null||ve.registerSubPopup(Ye,me);}),Oe=f__namespace.useState(null),De=W(Oe,2),Te=De[0],He=De[1],rt=nn(function(me){pl(me)&&Te!==me&&He(me);}),ft=f__namespace.Children.only(a),Ke=(ft==null?void 0:ft.props)||{},Ze={},at=nn(function(me){var Me,pt,yt=Te;return (yt==null?void 0:yt.contains(me))||(yt==null||(Me=yt.getRootNode())===null||Me===void 0?void 0:Me.host)===me||me===yt||(tt==null?void 0:tt.contains(me))||(tt==null||(pt=tt.getRootNode())===null||pt===void 0?void 0:pt.host)===me||me===tt||Object.values(ge.current).some(function(vt){return (vt==null?void 0:vt.contains(me))||me===vt})}),st=vp(o,U,Z,ie),wt=vp(o,Q,ae,te),fe=f__namespace.useState(h||!1),ce=W(fe,2),_e=ce[0],we=ce[1],Ve=d??_e,$t=nn(function(me){d===void 0&&we(me);});Gt(function(){we(d||!1);},[d]);var At=f__namespace.useRef(Ve);At.current=Ve;var kt=nn(function(me){Ve!==me&&($t(me),v==null||v(me));}),be=f__namespace.useRef(),We=function(){clearTimeout(be.current);},Ue=function(Me){var pt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;We(),pt===0?kt(Me):be.current=setTimeout(function(){kt(Me);},pt*1e3);};f__namespace.useEffect(function(){return We},[]);var Et=f__namespace.useState(!1),_t=W(Et,2),gr=_t[0],fr=_t[1],Lt=f__namespace.useRef(!0);Gt(function(){(!Lt.current||Ve)&&fr(!0),Lt.current=!0;},[Ve]);var zr=f__namespace.useState(null),tr=W(zr,2),Ge=tr[0],Ie=tr[1],pe=f__namespace.useState([0,0]),ht=W(pe,2),nt=ht[0],ar=ht[1],Pe=function(Me){ar([Me.clientX,Me.clientY]);},ye=YR(Ve,tt,G?nt:Te,O,A,I,V),Be=W(ye,9),Mt=Be[0],jt=Be[1],Rt=Be[2],Pr=Be[3],qr=Be[4],Rn=Be[5],hi=Be[6],Zn=Be[7],cn=Be[8],Or=nn(function(){gr||cn();});ZR(Ve,Te,tt,Or),Gt(function(){Or();},[nt,O]),Gt(function(){Ve&&!(A!=null&&A[O])&&Or();},[JSON.stringify(I)]);var zi=f__namespace.useMemo(function(){var me=XR(A,o,Zn,G);return K(me,B==null?void 0:B(Zn))},[Zn,B,A,o,G]);f__namespace.useImperativeHandle(n,function(){return {forceAlign:Or}});var Bo=function(Me){fr(!1),cn(),p==null||p(Me);},Hi=function(){return new Promise(function(Me){Ie(function(){return Me});})};Gt(function(){Ge&&(cn(),Ge(),Ie(null));},[Ge]);var Wi=f__namespace.useState(0),Bi=W(Wi,2),Vo=Bi[0],Uo=Bi[1],Go=f__namespace.useState(0),Vi=W(Go,2),Ko=Vi[0],St=Vi[1],lt=function(Me,pt){if(Or(),j){var yt=pt.getBoundingClientRect();Uo(yt.width),St(yt.height);}},qe=KR(xe,l,c,u),Vt=W(qe,2),zt=Vt[0],Qt=Vt[1],hr=function(Me,pt,yt,vt){Ze[Me]=function(Xo){var Ui;vt==null||vt(Xo),Ue(pt,yt);for(var mi=arguments.length,Gi=new Array(mi>1?mi-1:0),ys=1;ys1?pt-1:0),vt=1;vt1?pt-1:0),vt=1;vtt||e;var aN={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};const sN=aN;var n0=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:sN}))};n0.displayName="DownOutlined";const lN=f__namespace.forwardRef(n0);var Qi={shiftX:64,adjustY:1},Ji={adjustX:1,shiftY:!0},Wr=[0,0],cN={left:{points:["cr","cl"],overflow:Ji,offset:[-4,0],targetOffset:Wr},right:{points:["cl","cr"],overflow:Ji,offset:[4,0],targetOffset:Wr},top:{points:["bc","tc"],overflow:Qi,offset:[0,-4],targetOffset:Wr},bottom:{points:["tc","bc"],overflow:Qi,offset:[0,4],targetOffset:Wr},topLeft:{points:["bl","tl"],overflow:Qi,offset:[0,-4],targetOffset:Wr},leftTop:{points:["tr","tl"],overflow:Ji,offset:[-4,0],targetOffset:Wr},topRight:{points:["br","tr"],overflow:Qi,offset:[0,-4],targetOffset:Wr},rightTop:{points:["tl","tr"],overflow:Ji,offset:[4,0],targetOffset:Wr},bottomRight:{points:["tr","br"],overflow:Qi,offset:[0,4],targetOffset:Wr},rightBottom:{points:["bl","br"],overflow:Ji,offset:[4,0],targetOffset:Wr},bottomLeft:{points:["tl","bl"],overflow:Qi,offset:[0,4],targetOffset:Wr},leftBottom:{points:["br","bl"],overflow:Ji,offset:[-4,0],targetOffset:Wr}};function i0(e){var t=e.children,r=e.prefixCls,n=e.id,i=e.overlayInnerStyle,o=e.className,a=e.style;return f__namespace.createElement("div",{className:K("".concat(r,"-content"),o),style:a},f__namespace.createElement("div",{className:"".concat(r,"-inner"),id:n,role:"tooltip",style:i},typeof t=="function"?t():t))}var uN=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow"],dN=function(t,r){var n=t.overlayClassName,i=t.trigger,o=i===void 0?["hover"]:i,a=t.mouseEnterDelay,s=a===void 0?0:a,l=t.mouseLeaveDelay,c=l===void 0?.1:l,u=t.overlayStyle,d=t.prefixCls,h=d===void 0?"rc-tooltip":d,v=t.children,p=t.onVisibleChange,m=t.afterVisibleChange,g=t.transitionName,b=t.animation,w=t.motion,S=t.placement,$=S===void 0?"right":S,x=t.align,y=x===void 0?{}:x,C=t.destroyTooltipOnHide,M=C===void 0?!1:C,R=t.defaultVisible,P=t.getTooltipContainer,N=t.overlayInnerStyle;t.arrowContent;var _=t.overlay,E=t.id,O=t.showArrow,T=O===void 0?!0:O,A=Xe(t,uN),I=f.useRef(null);f.useImperativeHandle(r,function(){return I.current});var L=D({},A);"visible"in t&&(L.popupVisible=t.visible);var j=function(){return f__namespace.createElement(i0,{key:"content",prefixCls:h,id:E,overlayInnerStyle:N},_)};return f__namespace.createElement(r0,Ce({popupClassName:n,prefixCls:h,popup:j,action:o,builtinPlacements:cN,popupPlacement:$,ref:I,popupAlign:y,getPopupContainer:P,onPopupVisibleChange:p,afterPopupVisibleChange:m,popupTransitionName:g,popupAnimation:b,popupMotion:w,defaultPopupVisible:R,autoDestroy:M,mouseLeaveDelay:c,popupStyle:u,mouseEnterDelay:s,arrow:T},L),v)};const fN=f.forwardRef(dN),o0=8;function a0(e){const t=o0,{contentRadius:r,limitVerticalRadius:n}=e,i=r>12?r+2:12;return {dropdownArrowOffset:i,dropdownArrowOffsetVertical:n?t:i}}function ks(e,t){return e?t:{}}function hN(e,t){const{componentCls:r,sizePopupArrow:n,borderRadiusXS:i,borderRadiusOuter:o,boxShadowPopoverArrow:a}=e,{colorBg:s,contentRadius:l=e.borderRadiusLG,limitVerticalRadius:c,arrowDistance:u=0,arrowPlacement:d={left:!0,right:!0,top:!0,bottom:!0}}=t,{dropdownArrowOffsetVertical:h,dropdownArrowOffset:v}=a0({contentRadius:l,limitVerticalRadius:c});return {[r]:Object.assign(Object.assign(Object.assign(Object.assign({[`${r}-arrow`]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},XO(n,i,o,s,a)),{"&:before":{background:s}})]},ks(!!d.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:v}},[`&-placement-topRight ${r}-arrow`]:{right:{_skip_check_:!0,value:v}}})),ks(!!d.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:v}},[`&-placement-bottomRight ${r}-arrow`]:{right:{_skip_check_:!0,value:v}}})),ks(!!d.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:h},[`&-placement-leftBottom ${r}-arrow`]:{bottom:h}})),ks(!!d.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:h},[`&-placement-rightBottom ${r}-arrow`]:{bottom:h}}))}}function vN(e,t,r,n){if(n===!1)return {adjustX:!1,adjustY:!1};const i=n&&typeof n=="object"?n:{},o={};switch(e){case"top":case"bottom":o.shiftX=t.dropdownArrowOffset*2+r;break;case"left":case"right":o.shiftY=t.dropdownArrowOffsetVertical*2+r;break}const a=Object.assign(Object.assign({},o),i);return a.shiftX||(a.adjustX=!0),a.shiftY||(a.adjustY=!0),a}const yp={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"]}},pN={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"]}},mN=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function gN(e){const{arrowWidth:t,autoAdjustOverflow:r,arrowPointAtCenter:n,offset:i,borderRadius:o}=e,a=t/2,s={};return Object.keys(yp).forEach(l=>{const c=n&&pN[l]||yp[l],u=Object.assign(Object.assign({},c),{offset:[0,0]});switch(s[l]=u,mN.has(l)&&(u.autoArrow=!1),l){case"top":case"topLeft":case"topRight":u.offset[1]=-a-i;break;case"bottom":case"bottomLeft":case"bottomRight":u.offset[1]=a+i;break;case"left":case"leftTop":case"leftBottom":u.offset[0]=-a-i;break;case"right":case"rightTop":case"rightBottom":u.offset[0]=a+i;break}const d=a0({contentRadius:o,limitVerticalRadius:!0});if(n)switch(l){case"topLeft":case"bottomLeft":u.offset[0]=-d.dropdownArrowOffset-a;break;case"topRight":case"bottomRight":u.offset[0]=d.dropdownArrowOffset+a;break;case"leftTop":case"rightTop":u.offset[1]=-d.dropdownArrowOffset-a;break;case"leftBottom":case"rightBottom":u.offset[1]=d.dropdownArrowOffset+a;break}u.overflow=vN(l,d,t,r);}),s}const Jn=(e,t)=>new ur(e).setAlpha(t).toRgbString(),eo=(e,t)=>new ur(e).lighten(t).toHexString(),bN=e=>{const t=Un(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]}},yN=(e,t)=>{const r=e||"#000",n=t||"#fff";return {colorBgBase:r,colorTextBase:n,colorText:Jn(n,.85),colorTextSecondary:Jn(n,.65),colorTextTertiary:Jn(n,.45),colorTextQuaternary:Jn(n,.25),colorFill:Jn(n,.18),colorFillSecondary:Jn(n,.12),colorFillTertiary:Jn(n,.08),colorFillQuaternary:Jn(n,.04),colorBgElevated:eo(r,12),colorBgContainer:eo(r,8),colorBgLayout:eo(r,0),colorBgSpotlight:eo(r,26),colorBorder:eo(r,26),colorBorderSecondary:eo(r,19)}},wN=(e,t)=>{const r=Object.keys(kf).map(i=>{const o=Un(e[i],{theme:"dark"});return new Array(10).fill(1).reduce((a,s,l)=>(a[`${i}-${l+1}`]=o[l],a[`${i}${l+1}`]=o[l],a),{})}).reduce((i,o)=>(i=Object.assign(Object.assign({},i),o),i),{}),n=t??vc(e);return Object.assign(Object.assign(Object.assign({},n),r),ub(e,{generateColorPalettes:bN,generateNeutralColorPalettes:yN}))},SN=wN;function CN(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 xN=(e,t)=>{const r=t??vc(e),n=r.fontSizeSM,i=r.controlHeight-4;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},r),CN(t??e)),db(n)),{controlHeight:i}),cb(Object.assign(Object.assign({},r),{controlHeight:i})))},$N=xN;function EN(){const[e,t,r]=os();return {theme:e,token:t,hashId:r}}const Nd={defaultConfig:Cl,defaultSeed:Cl.token,useToken:EN,defaultAlgorithm:vc,darkAlgorithm:SN,compactAlgorithm:$N},_N=e=>{const{componentCls:t,tooltipMaxWidth:r,tooltipColor:n,tooltipBg:i,tooltipBorderRadius:o,zIndexPopup:a,controlHeight:s,boxShadowSecondary:l,paddingSM:c,paddingXS:u,tooltipRadiusOuter:d}=e;return [{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},yr(e)),{position:"absolute",zIndex:a,display:"block",width:"max-content",maxWidth:r,visibility:"visible",transformOrigin:"var(--arrow-x, 50%) var(--arrow-y, 50%)","&-hidden":{display:"none"},"--antd-arrow-background-color":i,[`${t}-inner`]:{minWidth:s,minHeight:s,padding:`${c/2}px ${u}px`,color:n,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:i,borderRadius:o,boxShadow:l},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${t}-inner`]:{borderRadius:Math.min(o,o0)}},[`${t}-content`]:{position:"relative"}}),pb(e,(h,v)=>{let{darkColor:p}=v;return {[`&${t}-${h}`]:{[`${t}-inner`]:{backgroundColor:p},[`${t}-arrow`]:{"--antd-arrow-background-color":p}}}})),{"&-rtl":{direction:"rtl"}})},hN(mr(e,{borderRadiusOuter:d}),{colorBg:"var(--antd-arrow-background-color)",contentRadius:o,limitVerticalRadius:!0}),{[`${t}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},s0=(e,t)=>Tn("Tooltip",n=>{if(t===!1)return [];const{borderRadius:i,colorTextLightSolid:o,colorBgDefault:a,borderRadiusOuter:s}=n,l=mr(n,{tooltipMaxWidth:250,tooltipColor:o,tooltipBorderRadius:i,tooltipBg:a,tooltipRadiusOuter:s>4?4:s});return [_N(l),kR(n,"zoom-big-fast")]},n=>{let{zIndexPopupBase:i,colorBgSpotlight:o}=n;return {zIndexPopup:i+70,colorBgDefault:o}})(e),PN=Sl.map(e=>`${e}-inverse`),ON=["success","processing","error","default","warning"];function l0(e){return (arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0)?[].concat(le(PN),le(Sl)).includes(e):Sl.includes(e)}function TN(e){return ON.includes(e)}function c0(e,t){const r=l0(t),n=K({[`${e}-${t}`]:t&&r}),i={},o={};return t&&!r&&(i.background=t,o["--antd-arrow-background-color"]=t),{className:n,overlayStyle:i,arrowStyle:o}}function MN(e){const{prefixCls:t,className:r,placement:n="top",title:i,color:o,overlayInnerStyle:a}=e,{getPrefixCls:s}=f__namespace.useContext(Wt),l=s("tooltip",t),[c,u]=s0(l,!0),d=c0(l,o),h=Object.assign(Object.assign({},a),d.overlayStyle),v=d.arrowStyle;return c(f__namespace.createElement("div",{className:K(u,l,`${l}-pure`,`${l}-placement-${n}`,r,d.className),style:v},f__namespace.createElement("div",{className:`${l}-arrow`}),f__namespace.createElement(i0,Object.assign({},e,{className:u,prefixCls:l,overlayInnerStyle:h}),i)))}var RN=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 i=0,n=Object.getOwnPropertySymbols(e);i{const r={},n=Object.assign({},e);return t.forEach(i=>{e&&i in e&&(r[i]=e[i],delete n[i]);}),{picked:r,omitted:n}};function AN(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:i}=IN(e.props.style,["position","left","right","top","bottom","float","display","zIndex"]),o=Object.assign(Object.assign({display:"inline-block"},n),{cursor:"not-allowed",width:e.props.block?"100%":void 0}),a=Object.assign(Object.assign({},i),{pointerEvents:"none"}),s=Ro(e,{style:a,className:null});return f__namespace.createElement("span",{style:o,className:K(e.props.className,`${t}-disabled-compatible-wrapper`)},s)}return e}const u0=f__namespace.forwardRef((e,t)=>{var r,n;const{prefixCls:i,openClassName:o,getTooltipContainer:a,overlayClassName:s,color:l,overlayInnerStyle:c,children:u,afterOpenChange:d,afterVisibleChange:h,destroyTooltipOnHide:v,arrow:p=!0,title:m,overlay:g,builtinPlacements:b,arrowPointAtCenter:w=!1,autoAdjustOverflow:S=!0}=e,$=!!p,{token:x}=NN(),{getPopupContainer:y,getPrefixCls:C,direction:M}=f__namespace.useContext(Wt),R=f__namespace.useRef(null),P=()=>{var de;(de=R.current)===null||de===void 0||de.forceAlign();};f__namespace.useImperativeHandle(t,()=>({forceAlign:P,forcePopupAlign:()=>{P();}}));const[N,_]=Cn(!1,{value:(r=e.open)!==null&&r!==void 0?r:e.visible,defaultValue:(n=e.defaultOpen)!==null&&n!==void 0?n:e.defaultVisible}),E=!m&&!g&&m!==0,O=de=>{var ge,ve;_(E?!1:de),E||((ge=e.onOpenChange)===null||ge===void 0||ge.call(e,de),(ve=e.onVisibleChange)===null||ve===void 0||ve.call(e,de));},T=f__namespace.useMemo(()=>{var de,ge;let ve=w;return typeof p=="object"&&(ve=(ge=(de=p.pointAtCenter)!==null&&de!==void 0?de:p.arrowPointAtCenter)!==null&&ge!==void 0?ge:w),b||gN({arrowPointAtCenter:ve,autoAdjustOverflow:S,arrowWidth:$?x.sizePopupArrow:0,borderRadius:x.borderRadius,offset:x.marginXXS})},[w,p,b,x]),A=f__namespace.useMemo(()=>m===0?m:g||m||"",[g,m]),I=f__namespace.createElement(Od,null,typeof A=="function"?A():A),{getPopupContainer:L,placement:j="top",mouseEnterDelay:B=.1,mouseLeaveDelay:G=.1,overlayStyle:z,rootClassName:V}=e,q=RN(e,["getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName"]),U=C("tooltip",i),Q=C(),ie=e["data-popover-inject"];let Z=N;!("open"in e)&&!("visible"in e)&&E&&(Z=!1);const te=AN(zf(u)&&!Db(u)?u:f__namespace.createElement("span",null,u),U),ae=te.props,ue=!ae.className||typeof ae.className=="string"?K(ae.className,{[o||`${U}-open`]:!0}):ae.className,[Ee,J]=s0(U,!ie),oe=c0(U,l),se=Object.assign(Object.assign({},c),oe.overlayStyle),re=oe.arrowStyle,xe=K(s,{[`${U}-rtl`]:M==="rtl"},oe.className,V,J);return Ee(f__namespace.createElement(fN,Object.assign({},q,{showArrow:$,placement:j,mouseEnterDelay:B,mouseLeaveDelay:G,prefixCls:U,overlayClassName:xe,overlayStyle:Object.assign(Object.assign({},re),z),getTooltipContainer:L||a||y,ref:R,builtinPlacements:T,overlay:I,visible:Z,onVisibleChange:O,afterVisibleChange:d??h,overlayInnerStyle:se,arrowContent:f__namespace.createElement("span",{className:`${U}-arrow-content`}),motion:{motionName:Xb(Q,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:!!v}),Z?Ro(te,{className:ue}):te))});u0._InternalPanelDoNotUseOrYouWillBeFired=MN;const Vf=u0;var kN=Y.ESC,LN=Y.TAB;function FN(e){var t=e.visible,r=e.triggerRef,n=e.onVisibleChange,i=e.autoFocus,o=e.overlayRef,a=f__namespace.useRef(!1),s=function(){if(t){var d,h;(d=r.current)===null||d===void 0||(h=d.focus)===null||h===void 0||h.call(d),n==null||n(!1);}},l=function(){var d;return (d=o.current)!==null&&d!==void 0&&d.focus?(o.current.focus(),a.current=!0,!0):!1},c=function(d){switch(d.keyCode){case kN:s();break;case LN:{var h=!1;a.current||(h=l()),h?d.preventDefault():s();break}}};f__namespace.useEffect(function(){return t?(window.addEventListener("keydown",c),i&&It(l,3),function(){window.removeEventListener("keydown",c),a.current=!1;}):function(){a.current=!1;}},[t]);}var DN=f.forwardRef(function(e,t){var r=e.overlay,n=e.arrow,i=e.prefixCls,o=f.useMemo(function(){var s;return typeof r=="function"?s=r():s=r,s},[r]),a=Kr(t,o==null?void 0:o.ref);return f.createElement(f.Fragment,null,n&&f.createElement("div",{className:"".concat(i,"-arrow")}),f.cloneElement(o,{ref:fi(o)?a:void 0}))}),to={adjustX:1,adjustY:1},ro=[0,0],jN={topLeft:{points:["bl","tl"],overflow:to,offset:[0,-4],targetOffset:ro},top:{points:["bc","tc"],overflow:to,offset:[0,-4],targetOffset:ro},topRight:{points:["br","tr"],overflow:to,offset:[0,-4],targetOffset:ro},bottomLeft:{points:["tl","bl"],overflow:to,offset:[0,4],targetOffset:ro},bottom:{points:["tc","bc"],overflow:to,offset:[0,4],targetOffset:ro},bottomRight:{points:["tr","br"],overflow:to,offset:[0,4],targetOffset:ro}},zN=["arrow","prefixCls","transitionName","animation","align","placement","placements","getPopupContainer","showAction","hideAction","overlayClassName","overlayStyle","visible","trigger","autoFocus","overlay","children","onVisibleChange"];function HN(e,t){var r,n=e.arrow,i=n===void 0?!1:n,o=e.prefixCls,a=o===void 0?"rc-dropdown":o,s=e.transitionName,l=e.animation,c=e.align,u=e.placement,d=u===void 0?"bottomLeft":u,h=e.placements,v=h===void 0?jN:h,p=e.getPopupContainer,m=e.showAction,g=e.hideAction,b=e.overlayClassName,w=e.overlayStyle,S=e.visible,$=e.trigger,x=$===void 0?["hover"]:$,y=e.autoFocus,C=e.overlay,M=e.children,R=e.onVisibleChange,P=Xe(e,zN),N=f.useState(),_=W(N,2),E=_[0],O=_[1],T="visible"in e?S:E,A=f.useRef(null),I=f.useRef(null),L=f.useRef(null);f.useImperativeHandle(t,function(){return A.current});var j=function(Z){O(Z),R==null||R(Z);};FN({visible:T,triggerRef:L,onVisibleChange:j,autoFocus:y,overlayRef:I});var B=function(Z){var te=e.onOverlayClick;O(!1),te&&te(Z);},G=function(){return f.createElement(DN,{ref:I,overlay:C,prefixCls:a,arrow:i})},z=function(){return typeof C=="function"?G:G()},V=function(){var Z=e.minOverlayWidthMatchTrigger,te=e.alignPoint;return "minOverlayWidthMatchTrigger"in e?Z:!te},q=function(){var Z=e.openClassName;return Z!==void 0?Z:"".concat(a,"-open")},U=f.cloneElement(M,{className:K((r=M.props)===null||r===void 0?void 0:r.className,T&&q()),ref:fi(M)?Kr(L,M.ref):void 0}),Q=g;return !Q&&x.indexOf("contextMenu")!==-1&&(Q=["click"]),f.createElement(r0,Ce({builtinPlacements:v},P,{prefixCls:a,ref:A,popupClassName:K(b,H({},"".concat(a,"-show-arrow"),i)),popupStyle:w,action:x,showAction:m,hideAction:Q,popupPlacement:d,popupAlign:c,popupTransitionName:s,popupAnimation:l,popupVisible:T,stretch:V()?"minWidth":"",popup:z(),onPopupVisibleChange:j,onPopupClick:B,getPopupContainer:p}),U)}const WN=f.forwardRef(HN);var d0=f__namespace.createContext(null);function Uf(e,t){return e===void 0?null:"".concat(e,"-").concat(t)}function f0(e){var t=f__namespace.useContext(d0);return Uf(t,e)}var BN=["children","locked"],ln=f__namespace.createContext(null);function VN(e,t){var r=D({},e);return Object.keys(t).forEach(function(n){var i=t[n];i!==void 0&&(r[n]=i);}),r}function Wa(e){var t=e.children,r=e.locked,n=Xe(e,BN),i=f__namespace.useContext(ln),o=sc(function(){return VN(i,n)},[i,n],function(a,s){return !r&&(a[0]!==s[0]||!rs(a[1],s[1],!0))});return f__namespace.createElement(ln.Provider,{value:o},t)}var UN=[],h0=f__namespace.createContext(null);function xc(){return f__namespace.useContext(h0)}var v0=f__namespace.createContext(UN);function cs(e){var t=f__namespace.useContext(v0);return f__namespace.useMemo(function(){return e!==void 0?[].concat(le(t),[e]):t},[t,e])}var p0=f__namespace.createContext(null),Gf=f__namespace.createContext({});function wp(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(wc(e)){var r=e.nodeName.toLowerCase(),n=["input","select","textarea","button"].includes(r)||e.isContentEditable||r==="a"&&!!e.getAttribute("href"),i=e.getAttribute("tabindex"),o=Number(i),a=null;return i&&!Number.isNaN(o)?a=o:n&&a===null&&(a=0),n&&e.disabled&&(a=null),a!==null&&(a>=0||t&&a<0)}return !1}function GN(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=le(e.querySelectorAll("*")).filter(function(n){return wp(n,t)});return wp(e,t)&&r.unshift(e),r}var Id=Y.LEFT,Ad=Y.RIGHT,kd=Y.UP,Xs=Y.DOWN,Ys=Y.ENTER,m0=Y.ESC,ra=Y.HOME,na=Y.END,Sp=[kd,Xs,Id,Ad];function KN(e,t,r,n){var i,o,a,s,l="prev",c="next",u="children",d="parent";if(e==="inline"&&n===Ys)return {inlineTrigger:!0};var h=(i={},H(i,kd,l),H(i,Xs,c),i),v=(o={},H(o,Id,r?c:l),H(o,Ad,r?l:c),H(o,Xs,u),H(o,Ys,u),o),p=(a={},H(a,kd,l),H(a,Xs,c),H(a,Ys,u),H(a,m0,d),H(a,Id,r?u:d),H(a,Ad,r?d:u),a),m={inline:h,horizontal:v,vertical:p,inlineSub:h,horizontalSub:p,verticalSub:p},g=(s=m["".concat(e).concat(t?"":"Sub")])===null||s===void 0?void 0:s[n];switch(g){case l:return {offset:-1,sibling:!0};case c:return {offset:1,sibling:!0};case d:return {offset:-1,sibling:!1};case u:return {offset:1,sibling:!1};default:return null}}function qN(e){for(var t=e;t;){if(t.getAttribute("data-menu-list"))return t;t=t.parentElement;}return null}function XN(e,t){for(var r=e||document.activeElement;r;){if(t.has(r))return r;r=r.parentElement;}return null}function g0(e,t){var r=GN(e,!0);return r.filter(function(n){return t.has(n)})}function Cp(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1;if(!e)return null;var i=g0(e,t),o=i.length,a=i.findIndex(function(s){return r===s});return n<0?a===-1?a=o-1:a-=1:n>0&&(a+=1),a=(a+o)%o,i[a]}function YN(e,t,r,n,i,o,a,s,l,c){var u=f__namespace.useRef(),d=f__namespace.useRef();d.current=t;var h=function(){It.cancel(u.current);};return f__namespace.useEffect(function(){return function(){h();}},[]),function(v){var p=v.which;if([].concat(Sp,[Ys,m0,ra,na]).includes(p)){var m,g,b,w=function(){m=new Set,g=new Map,b=new Map;var T=o();return T.forEach(function(A){var I=document.querySelector("[data-menu-id='".concat(Uf(n,A),"']"));I&&(m.add(I),b.set(I,A),g.set(A,I));}),m};w();var S=g.get(t),$=XN(S,m),x=b.get($),y=KN(e,a(x,!0).length===1,r,p);if(!y&&p!==ra&&p!==na)return;(Sp.includes(p)||[ra,na].includes(p))&&v.preventDefault();var C=function(T){if(T){var A=T,I=T.querySelector("a");I!=null&&I.getAttribute("href")&&(A=I);var L=b.get(T);s(L),h(),u.current=It(function(){d.current===L&&A.focus();});}};if([ra,na].includes(p)||y.sibling||!$){var M;!$||e==="inline"?M=i.current:M=qN($);var R,P=g0(M,m);p===ra?R=P[0]:p===na?R=P[P.length-1]:R=Cp(M,m,$,y.offset),C(R);}else if(y.inlineTrigger)l(x);else if(y.offset>0)l(x,!0),h(),u.current=It(function(){w();var O=$.getAttribute("aria-controls"),T=document.getElementById(O),A=Cp(T,m);C(A);},5);else if(y.offset<0){var N=a(x,!0),_=N[N.length-2],E=g.get(_);l(_,!1),C(E);}}c==null||c(v);}}function ZN(e){Promise.resolve().then(e);}var Kf="__RC_UTIL_PATH_SPLIT__",xp=function(t){return t.join(Kf)},QN=function(t){return t.split(Kf)},Ld="rc-menu-more";function JN(){var e=f__namespace.useState({}),t=W(e,2),r=t[1],n=f.useRef(new Map),i=f.useRef(new Map),o=f__namespace.useState([]),a=W(o,2),s=a[0],l=a[1],c=f.useRef(0),u=f.useRef(!1),d=function(){u.current||r({});},h=f.useCallback(function(S,$){var x=xp($);i.current.set(x,S),n.current.set(S,x),c.current+=1;var y=c.current;ZN(function(){y===c.current&&d();});},[]),v=f.useCallback(function(S,$){var x=xp($);i.current.delete(x),n.current.delete(S);},[]),p=f.useCallback(function(S){l(S);},[]),m=f.useCallback(function(S,$){var x=n.current.get(S)||"",y=QN(x);return $&&s.includes(y[0])&&y.unshift(Ld),y},[s]),g=f.useCallback(function(S,$){return S.some(function(x){var y=m(x,!0);return y.includes($)})},[m]),b=function(){var $=le(n.current.keys());return s.length&&$.push(Ld),$},w=f.useCallback(function(S){var $="".concat(n.current.get(S)).concat(Kf),x=new Set;return le(i.current.keys()).forEach(function(y){y.startsWith($)&&x.add(i.current.get(y));}),x},[]);return f__namespace.useEffect(function(){return function(){u.current=!0;}},[]),{registerPath:h,unregisterPath:v,refreshOverflowKeys:p,isSubPathKey:g,getKeyPath:m,getKeys:b,getSubPathKeys:w}}function ao(e){var t=f__namespace.useRef(e);t.current=e;var r=f__namespace.useCallback(function(){for(var n,i=arguments.length,o=new Array(i),a=0;a=0&&r.left>=0&&r.bottom>r.top&&r.right>r.left?r:null}function z2(e,t,r,n){var i=Ne.clone(e),o={width:t.width,height:t.height};return n.adjustX&&i.left=r.left&&i.left+o.width>r.right&&(o.width-=i.left+o.width-r.right),n.adjustX&&i.left+o.width>r.right&&(i.left=Math.max(r.right-o.width,r.left)),n.adjustY&&i.top=r.top&&i.top+o.height>r.bottom&&(o.height-=i.top+o.height-r.bottom),n.adjustY&&i.top+o.height>r.bottom&&(i.top=Math.max(r.bottom-o.height,r.top)),Ne.mix(i,o)}function Jf(e){var t,r,n;if(!Ne.isWindow(e)&&e.nodeType!==9)t=Ne.offset(e),r=Ne.outerWidth(e),n=Ne.outerHeight(e);else {var i=Ne.getWindow(e);t={left:Ne.getWindowScrollLeft(i),top:Ne.getWindowScrollTop(i)},r=Ne.viewportWidth(i),n=Ne.viewportHeight(i);}return t.width=r,t.height=n,t}function Ap(e,t){var r=t.charAt(0),n=t.charAt(1),i=e.width,o=e.height,a=e.left,s=e.top;return r==="c"?s+=o/2:r==="b"&&(s+=o),n==="c"?a+=i/2:n==="r"&&(a+=i),{left:a,top:s}}function Fs(e,t,r,n,i){var o=Ap(t,r[1]),a=Ap(e,r[0]),s=[a.left-o.left,a.top-o.top];return {left:Math.round(e.left-s[0]+n[0]-i[0]),top:Math.round(e.top-s[1]+n[1]-i[1])}}function kp(e,t,r){return e.leftr.right}function Lp(e,t,r){return e.topr.bottom}function H2(e,t,r){return e.left>r.right||e.left+t.widthr.bottom||e.top+t.height=r.right||n.top>=r.bottom}function eh(e,t,r){var n=r.target||t,i=Jf(n),o=!B2(n,r.overflow&&r.overflow.alwaysByViewport);return T0(e,i,r,o)}eh.__getOffsetParent=Hd;eh.__getVisibleRectForElement=Qf;function V2(e,t,r){var n,i,o=Ne.getDocument(e),a=o.defaultView||o.parentWindow,s=Ne.getWindowScrollLeft(a),l=Ne.getWindowScrollTop(a),c=Ne.viewportWidth(a),u=Ne.viewportHeight(a);"pageX"in t?n=t.pageX:n=s+t.clientX,"pageY"in t?i=t.pageY:i=l+t.clientY;var d={left:n,top:i,width:0,height:0},h=n>=0&&n<=s+c&&i>=0&&i<=l+u,v=[r.points[0],"cc"];return T0(e,d,_p(_p({},r),{},{points:v}),h)}const U2=function(e,t){var r=f.useRef(!1),n=f.useRef(null);function i(){window.clearTimeout(n.current);}function o(a){if(i(),!r.current||a===!0){if(e(a)===!1)return;r.current=!0,n.current=window.setTimeout(function(){r.current=!1;},t);}else n.current=window.setTimeout(function(){r.current=!1,o();},t);}return [o,function(){r.current=!1,i();}]};function G2(e,t){return e===t?!0:!e||!t?!1:"pageX"in t&&"pageY"in t?e.pageX===t.pageX&&e.pageY===t.pageY:"clientX"in t&&"clientY"in t?e.clientX===t.clientX&&e.clientY===t.clientY:!1}function K2(e,t){e!==document.activeElement&&ba(t,e)&&typeof e.focus=="function"&&e.focus();}function jp(e,t){var r=null,n=null;function i(a){var s=W(a,1),l=s[0].target;if(document.documentElement.contains(l)){var c=l.getBoundingClientRect(),u=c.width,d=c.height,h=Math.floor(u),v=Math.floor(d);(r!==h||n!==v)&&Promise.resolve().then(function(){t({width:h,height:v});}),r=h,n=v;}}var o=new Lg(i);return e&&o.observe(e),function(){o.disconnect();}}function zp(e){return typeof e!="function"?null:e()}function Hp(e){return ot(e)!=="object"||!e?null:e}var q2=function(t,r){var n=t.children,i=t.disabled,o=t.target,a=t.align,s=t.onAlign,l=t.monitorWindowResize,c=t.monitorBufferTime,u=c===void 0?0:c,d=f.useRef({}),h=f.useRef(),v=f.Children.only(n),p=f.useRef({});p.current.disabled=i,p.current.target=o,p.current.align=a,p.current.onAlign=s;var m=U2(function(){var N=p.current,_=N.disabled,E=N.target,O=N.align,T=N.onAlign,A=h.current;if(!_&&E&&A){var I,L=zp(E),j=Hp(E);d.current.element=L,d.current.point=j,d.current.align=O;var B=document,G=B.activeElement;return L&&wc(L)?I=eh(A,L,O):j&&(I=V2(A,j,O)),K2(G,A),T&&I&&T(A,I),!0}return !1},u),g=W(m,2),b=g[0],w=g[1],S=f.useState(),$=W(S,2),x=$[0],y=$[1],C=f.useState(),M=W(C,2),R=M[0],P=M[1];return Gt(function(){y(zp(o)),P(Hp(o));}),f.useEffect(function(){(d.current.element!==x||!G2(d.current.point,R)||!rs(d.current.align,a))&&b();}),f.useEffect(function(){var N=jp(h.current,b);return N},[h.current]),f.useEffect(function(){var N=jp(x,b);return N},[x]),f.useEffect(function(){i?w():b();},[i]),f.useEffect(function(){if(l){var N=da(window,"resize",b);return N.remove}},[l]),f.useEffect(function(){return function(){w();}},[]),f.useImperativeHandle(r,function(){return {forceAlign:function(){return b(!0)}}}),f.isValidElement(v)&&(v=f.cloneElement(v,{ref:Kr(v.ref,h)})),v},M0=f.forwardRef(q2);M0.displayName="Align";var Wp=["measure","alignPre","align",null,"motion"];const X2=function(e,t){var r=Mi(null),n=W(r,2),i=n[0],o=n[1],a=f.useRef();function s(u){o(u,!0);}function l(){It.cancel(a.current);}function c(u){l(),a.current=It(function(){s(function(d){switch(i){case"align":return "motion";case"motion":return "stable"}return d}),u==null||u();});}return f.useEffect(function(){s("measure");},[e]),f.useEffect(function(){switch(i){case"measure":t();break}i&&(a.current=It(Fi(pr().mark(function u(){var d,h;return pr().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:d=Wp.indexOf(i),h=Wp[d+1],h&&d!==-1&&s(h);case 3:case"end":return p.stop()}},u)}))));},[i]),f.useEffect(function(){return function(){l();}},[]),[i,c]},Y2=function(e){var t=f__namespace.useState({width:0,height:0}),r=W(t,2),n=r[0],i=r[1];function o(s){var l=s.offsetWidth,c=s.offsetHeight,u=s.getBoundingClientRect(),d=u.width,h=u.height;Math.abs(l-d)<1&&Math.abs(c-h)<1&&(l=d,c=h),i({width:l,height:c});}var a=f__namespace.useMemo(function(){var s={};if(e){var l=n.width,c=n.height;e.indexOf("height")!==-1&&c?s.height=c:e.indexOf("minHeight")!==-1&&c&&(s.minHeight=c),e.indexOf("width")!==-1&&l?s.width=l:e.indexOf("minWidth")!==-1&&l&&(s.minWidth=l);}return s},[e,n]);return [a,o]};var R0=f__namespace.forwardRef(function(e,t){var r=e.visible,n=e.prefixCls,i=e.className,o=e.style,a=e.children,s=e.zIndex,l=e.stretch,c=e.destroyPopupOnHide,u=e.forceRender,d=e.align,h=e.point,v=e.getRootDomNode,p=e.getClassNameFromAlign,m=e.onAlign,g=e.onMouseEnter,b=e.onMouseLeave,w=e.onMouseDown,S=e.onTouchStart,$=e.onClick,x=f.useRef(),y=f.useRef(),C=f.useState(),M=W(C,2),R=M[0],P=M[1],N=Y2(l),_=W(N,2),E=_[0],O=_[1];function T(){l&&O(v());}var A=X2(r,T),I=W(A,2),L=I[0],j=I[1],B=f.useState(0),G=W(B,2),z=G[0],V=G[1],q=f.useRef();Gt(function(){L==="alignPre"&&V(0);},[L]);function U(){return h||v}function Q(){var J;(J=x.current)===null||J===void 0||J.forceAlign();}function ie(J,oe){var se=p(oe);R!==se&&P(se),V(function(re){return re+1}),L==="align"&&(m==null||m(J,oe));}Gt(function(){L==="align"&&(z<3?Q():j(function(){var J;(J=q.current)===null||J===void 0||J.call(q);}));},[z]);var Z=D({},S0(e));["onAppearEnd","onEnterEnd","onLeaveEnd"].forEach(function(J){var oe=Z[J];Z[J]=function(se,re){return j(),oe==null?void 0:oe(se,re)};});function te(){return new Promise(function(J){q.current=J;})}f__namespace.useEffect(function(){!Z.motionName&&L==="motion"&&j();},[Z.motionName,L]),f__namespace.useImperativeHandle(t,function(){return {forceAlign:Q,getElement:function(){return y.current}}});var ae=D(D({},E),{},{zIndex:s,opacity:L==="motion"||L==="stable"||!r?void 0:0,pointerEvents:!r&&L!=="stable"?"none":void 0},o),ue=!0;d!=null&&d.points&&(L==="align"||L==="stable")&&(ue=!1);var Ee=a;return f__namespace.Children.count(a)>1&&(Ee=f__namespace.createElement("div",{className:"".concat(n,"-content")},a)),f__namespace.createElement(Mn,Ce({visible:r,ref:y,leavedClassName:"".concat(n,"-hidden")},Z,{onAppearPrepare:te,onEnterPrepare:te,removeOnLeave:c,forceRender:u}),function(J,oe){var se=J.className,re=J.style,xe=K(n,i,R,se);return f__namespace.createElement(M0,{target:U(),key:"popup",ref:x,monitorWindowResize:!0,disabled:ue,align:d,onAlign:ie},f__namespace.createElement("div",{ref:oe,className:xe,onMouseEnter:g,onMouseLeave:b,onMouseDownCapture:w,onTouchStartCapture:S,onClick:$,style:D(D({},re),ae)},Ee))})});R0.displayName="PopupInner";var N0=f__namespace.forwardRef(function(e,t){var r=e.prefixCls,n=e.visible,i=e.zIndex,o=e.children,a=e.mobile;a=a===void 0?{}:a;var s=a.popupClassName,l=a.popupStyle,c=a.popupMotion,u=c===void 0?{}:c,d=a.popupRender,h=e.onClick,v=f__namespace.useRef();f__namespace.useImperativeHandle(t,function(){return {forceAlign:function(){},getElement:function(){return v.current}}});var p=D({zIndex:i},l),m=o;return f__namespace.Children.count(o)>1&&(m=f__namespace.createElement("div",{className:"".concat(r,"-content")},o)),d&&(m=d(m)),f__namespace.createElement(Mn,Ce({visible:n,ref:v,removeOnLeave:!0},u),function(g,b){var w=g.className,S=g.style,$=K(r,s,w);return f__namespace.createElement("div",{ref:b,className:$,onClick:h,style:D(D({},S),p)},m)})});N0.displayName="MobilePopupInner";var Z2=["visible","mobile"],I0=f__namespace.forwardRef(function(e,t){var r=e.visible,n=e.mobile,i=Xe(e,Z2),o=f.useState(r),a=W(o,2),s=a[0],l=a[1],c=f.useState(!1),u=W(c,2),d=u[0],h=u[1],v=D(D({},i),{},{visible:s});f.useEffect(function(){l(r),r&&n&&h(Cc());},[r,n]);var p=d?f__namespace.createElement(N0,Ce({},v,{mobile:n,ref:t})):f__namespace.createElement(R0,Ce({},v,{ref:t}));return f__namespace.createElement("div",null,f__namespace.createElement(g2,v),p)});I0.displayName="Popup";var Bp=f__namespace.createContext(null);function Cu(){}function Q2(){return ""}function J2(e){return e?e.ownerDocument:window.document}var eI=["onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur","onContextMenu"];function tI(e){var t=function(r){Lo(i,r);var n=Fo(i);function i(o){var a;$r(this,i),a=n.call(this,o),H(ze(a),"popupRef",f__namespace.createRef()),H(ze(a),"triggerRef",f__namespace.createRef()),H(ze(a),"portalContainer",void 0),H(ze(a),"attachId",void 0),H(ze(a),"clickOutsideHandler",void 0),H(ze(a),"touchOutsideHandler",void 0),H(ze(a),"contextMenuOutsideHandler1",void 0),H(ze(a),"contextMenuOutsideHandler2",void 0),H(ze(a),"mouseDownTimeout",void 0),H(ze(a),"focusTime",void 0),H(ze(a),"preClickTime",void 0),H(ze(a),"preTouchTime",void 0),H(ze(a),"delayTimer",void 0),H(ze(a),"hasPopupMouseDown",void 0),H(ze(a),"onMouseEnter",function(l){var c=a.props.mouseEnterDelay;a.fireEvents("onMouseEnter",l),a.delaySetPopupVisible(!0,c,c?null:l);}),H(ze(a),"onMouseMove",function(l){a.fireEvents("onMouseMove",l),a.setPoint(l);}),H(ze(a),"onMouseLeave",function(l){a.fireEvents("onMouseLeave",l),a.delaySetPopupVisible(!1,a.props.mouseLeaveDelay);}),H(ze(a),"onPopupMouseEnter",function(){a.clearDelayTimer();}),H(ze(a),"onPopupMouseLeave",function(l){var c;l.relatedTarget&&!l.relatedTarget.setTimeout&&ba((c=a.popupRef.current)===null||c===void 0?void 0:c.getElement(),l.relatedTarget)||a.delaySetPopupVisible(!1,a.props.mouseLeaveDelay);}),H(ze(a),"onFocus",function(l){a.fireEvents("onFocus",l),a.clearDelayTimer(),a.isFocusToShow()&&(a.focusTime=Date.now(),a.delaySetPopupVisible(!0,a.props.focusDelay));}),H(ze(a),"onMouseDown",function(l){a.fireEvents("onMouseDown",l),a.preClickTime=Date.now();}),H(ze(a),"onTouchStart",function(l){a.fireEvents("onTouchStart",l),a.preTouchTime=Date.now();}),H(ze(a),"onBlur",function(l){a.fireEvents("onBlur",l),a.clearDelayTimer(),a.isBlurToHide()&&a.delaySetPopupVisible(!1,a.props.blurDelay);}),H(ze(a),"onContextMenu",function(l){l.preventDefault(),a.fireEvents("onContextMenu",l),a.setPopupVisible(!0,l);}),H(ze(a),"onContextMenuClose",function(){a.isContextMenuToShow()&&a.close();}),H(ze(a),"onClick",function(l){if(a.fireEvents("onClick",l),a.focusTime){var c;if(a.preClickTime&&a.preTouchTime?c=Math.min(a.preClickTime,a.preTouchTime):a.preClickTime?c=a.preClickTime:a.preTouchTime&&(c=a.preTouchTime),Math.abs(c-a.focusTime)<20)return;a.focusTime=0;}a.preClickTime=0,a.preTouchTime=0,a.isClickToShow()&&(a.isClickToHide()||a.isBlurToHide())&&l&&l.preventDefault&&l.preventDefault();var u=!a.state.popupVisible;(a.isClickToHide()&&!u||u&&a.isClickToShow())&&a.setPopupVisible(!a.state.popupVisible,l);}),H(ze(a),"onPopupMouseDown",function(){if(a.hasPopupMouseDown=!0,clearTimeout(a.mouseDownTimeout),a.mouseDownTimeout=window.setTimeout(function(){a.hasPopupMouseDown=!1;},0),a.context){var l;(l=a.context).onPopupMouseDown.apply(l,arguments);}}),H(ze(a),"onDocumentClick",function(l){if(!(a.props.mask&&!a.props.maskClosable)){var c=l.target,u=a.getRootDomNode(),d=a.getPopupDomNode();(!ba(u,c)||a.isContextMenuOnly())&&!ba(d,c)&&!a.hasPopupMouseDown&&a.close();}}),H(ze(a),"getRootDomNode",function(){var l=a.props.getTriggerDOMNode;if(l)return l(a.triggerRef.current);try{var c=ml(a.triggerRef.current);if(c)return c}catch{}return $o.findDOMNode(ze(a))}),H(ze(a),"getPopupClassNameFromAlign",function(l){var c=[],u=a.props,d=u.popupPlacement,h=u.builtinPlacements,v=u.prefixCls,p=u.alignPoint,m=u.getPopupClassNameFromAlign;return d&&h&&c.push(m2(h,v,l,p)),m&&c.push(m(l)),c.join(" ")}),H(ze(a),"getComponent",function(){var l=a.props,c=l.prefixCls,u=l.destroyPopupOnHide,d=l.popupClassName,h=l.onPopupAlign,v=l.popupMotion,p=l.popupAnimation,m=l.popupTransitionName,g=l.popupStyle,b=l.mask,w=l.maskAnimation,S=l.maskTransitionName,$=l.maskMotion,x=l.zIndex,y=l.popup,C=l.stretch,M=l.alignPoint,R=l.mobile,P=l.forceRender,N=l.onPopupClick,_=a.state,E=_.popupVisible,O=_.point,T=a.getPopupAlign(),A={};return a.isMouseEnterToShow()&&(A.onMouseEnter=a.onPopupMouseEnter),a.isMouseLeaveToHide()&&(A.onMouseLeave=a.onPopupMouseLeave),A.onMouseDown=a.onPopupMouseDown,A.onTouchStart=a.onPopupMouseDown,f__namespace.createElement(I0,Ce({prefixCls:c,destroyPopupOnHide:u,visible:E,point:M&&O,className:d,align:T,onAlign:h,animation:p,getClassNameFromAlign:a.getPopupClassNameFromAlign},A,{stretch:C,getRootDomNode:a.getRootDomNode,style:g,mask:b,zIndex:x,transitionName:m,maskAnimation:w,maskTransitionName:S,maskMotion:$,ref:a.popupRef,motion:v,mobile:R,forceRender:P,onClick:N}),typeof y=="function"?y():y)}),H(ze(a),"attachParent",function(l){It.cancel(a.attachId);var c=a.props,u=c.getPopupContainer,d=c.getDocument,h=a.getRootDomNode(),v;u?(h||u.length===0)&&(v=u(h)):v=d(a.getRootDomNode()).body,v?v.appendChild(l):a.attachId=It(function(){a.attachParent(l);});}),H(ze(a),"getContainer",function(){if(!a.portalContainer){var l=a.props.getDocument,c=l(a.getRootDomNode()).createElement("div");c.style.position="absolute",c.style.top="0",c.style.left="0",c.style.width="100%",a.portalContainer=c;}return a.attachParent(a.portalContainer),a.portalContainer}),H(ze(a),"setPoint",function(l){var c=a.props.alignPoint;!c||!l||a.setState({point:{pageX:l.pageX,pageY:l.pageY}});}),H(ze(a),"handlePortalUpdate",function(){a.state.prevPopupVisible!==a.state.popupVisible&&a.props.afterPopupVisibleChange(a.state.popupVisible);}),H(ze(a),"triggerContextValue",{onPopupMouseDown:a.onPopupMouseDown});var s;return "popupVisible"in o?s=!!o.popupVisible:s=!!o.defaultPopupVisible,a.state={prevPopupVisible:s,popupVisible:s},eI.forEach(function(l){a["fire".concat(l)]=function(c){a.fireEvents(l,c);};}),a}return Er(i,[{key:"componentDidMount",value:function(){this.componentDidUpdate();}},{key:"componentDidUpdate",value:function(){var a=this.props,s=this.state;if(s.popupVisible){var l;!this.clickOutsideHandler&&(this.isClickToHide()||this.isContextMenuToShow())&&(l=a.getDocument(this.getRootDomNode()),this.clickOutsideHandler=da(l,"mousedown",this.onDocumentClick)),this.touchOutsideHandler||(l=l||a.getDocument(this.getRootDomNode()),this.touchOutsideHandler=da(l,"touchstart",this.onDocumentClick)),!this.contextMenuOutsideHandler1&&this.isContextMenuToShow()&&(l=l||a.getDocument(this.getRootDomNode()),this.contextMenuOutsideHandler1=da(l,"scroll",this.onContextMenuClose)),!this.contextMenuOutsideHandler2&&this.isContextMenuToShow()&&(this.contextMenuOutsideHandler2=da(window,"blur",this.onContextMenuClose));return}this.clearOutsideHandler();}},{key:"componentWillUnmount",value:function(){this.clearDelayTimer(),this.clearOutsideHandler(),clearTimeout(this.mouseDownTimeout),It.cancel(this.attachId);}},{key:"getPopupDomNode",value:function(){var a;return ((a=this.popupRef.current)===null||a===void 0?void 0:a.getElement())||null}},{key:"getPopupAlign",value:function(){var a=this.props,s=a.popupPlacement,l=a.popupAlign,c=a.builtinPlacements;return s&&c?p2(c,s,l):l}},{key:"setPopupVisible",value:function(a,s){var l=this.props.alignPoint,c=this.state.popupVisible;this.clearDelayTimer(),c!==a&&("popupVisible"in this.props||this.setState({popupVisible:a,prevPopupVisible:c}),this.props.onPopupVisibleChange(a)),l&&s&&a&&this.setPoint(s);}},{key:"delaySetPopupVisible",value:function(a,s,l){var c=this,u=s*1e3;if(this.clearDelayTimer(),u){var d=l?{pageX:l.pageX,pageY:l.pageY}:null;this.delayTimer=window.setTimeout(function(){c.setPopupVisible(a,d),c.clearDelayTimer();},u);}else this.setPopupVisible(a,l);}},{key:"clearDelayTimer",value:function(){this.delayTimer&&(clearTimeout(this.delayTimer),this.delayTimer=null);}},{key:"clearOutsideHandler",value:function(){this.clickOutsideHandler&&(this.clickOutsideHandler.remove(),this.clickOutsideHandler=null),this.contextMenuOutsideHandler1&&(this.contextMenuOutsideHandler1.remove(),this.contextMenuOutsideHandler1=null),this.contextMenuOutsideHandler2&&(this.contextMenuOutsideHandler2.remove(),this.contextMenuOutsideHandler2=null),this.touchOutsideHandler&&(this.touchOutsideHandler.remove(),this.touchOutsideHandler=null);}},{key:"createTwoChains",value:function(a){var s=this.props.children.props,l=this.props;return s[a]&&l[a]?this["fire".concat(a)]:s[a]||l[a]}},{key:"isClickToShow",value:function(){var a=this.props,s=a.action,l=a.showAction;return s.indexOf("click")!==-1||l.indexOf("click")!==-1}},{key:"isContextMenuOnly",value:function(){var a=this.props.action;return a==="contextMenu"||a.length===1&&a[0]==="contextMenu"}},{key:"isContextMenuToShow",value:function(){var a=this.props,s=a.action,l=a.showAction;return s.indexOf("contextMenu")!==-1||l.indexOf("contextMenu")!==-1}},{key:"isClickToHide",value:function(){var a=this.props,s=a.action,l=a.hideAction;return s.indexOf("click")!==-1||l.indexOf("click")!==-1}},{key:"isMouseEnterToShow",value:function(){var a=this.props,s=a.action,l=a.showAction;return s.indexOf("hover")!==-1||l.indexOf("mouseEnter")!==-1}},{key:"isMouseLeaveToHide",value:function(){var a=this.props,s=a.action,l=a.hideAction;return s.indexOf("hover")!==-1||l.indexOf("mouseLeave")!==-1}},{key:"isFocusToShow",value:function(){var a=this.props,s=a.action,l=a.showAction;return s.indexOf("focus")!==-1||l.indexOf("focus")!==-1}},{key:"isBlurToHide",value:function(){var a=this.props,s=a.action,l=a.hideAction;return s.indexOf("focus")!==-1||l.indexOf("blur")!==-1}},{key:"forcePopupAlign",value:function(){if(this.state.popupVisible){var a;(a=this.popupRef.current)===null||a===void 0||a.forceAlign();}}},{key:"fireEvents",value:function(a,s){var l=this.props.children.props[a];l&&l(s);var c=this.props[a];c&&c(s);}},{key:"close",value:function(){this.setPopupVisible(!1);}},{key:"render",value:function(){var a=this.state.popupVisible,s=this.props,l=s.children,c=s.forceRender,u=s.alignPoint,d=s.className,h=s.autoDestroy,v=f__namespace.Children.only(l),p={key:"trigger"};this.isContextMenuToShow()?p.onContextMenu=this.onContextMenu:p.onContextMenu=this.createTwoChains("onContextMenu"),this.isClickToHide()||this.isClickToShow()?(p.onClick=this.onClick,p.onMouseDown=this.onMouseDown,p.onTouchStart=this.onTouchStart):(p.onClick=this.createTwoChains("onClick"),p.onMouseDown=this.createTwoChains("onMouseDown"),p.onTouchStart=this.createTwoChains("onTouchStart")),this.isMouseEnterToShow()?(p.onMouseEnter=this.onMouseEnter,u&&(p.onMouseMove=this.onMouseMove)):p.onMouseEnter=this.createTwoChains("onMouseEnter"),this.isMouseLeaveToHide()?p.onMouseLeave=this.onMouseLeave:p.onMouseLeave=this.createTwoChains("onMouseLeave"),this.isFocusToShow()||this.isBlurToHide()?(p.onFocus=this.onFocus,p.onBlur=this.onBlur):(p.onFocus=this.createTwoChains("onFocus"),p.onBlur=this.createTwoChains("onBlur"));var m=K(v&&v.props&&v.props.className,d);m&&(p.className=m);var g=D({},p);fi(v)&&(g.ref=Kr(this.triggerRef,v.ref));var b=f__namespace.cloneElement(v,g),w;return (a||this.popupRef.current||c)&&(w=f__namespace.createElement(e,{key:"portal",getContainer:this.getContainer,didUpdate:this.handlePortalUpdate},this.getComponent())),!a&&h&&(w=null),f__namespace.createElement(Bp.Provider,{value:this.triggerContextValue},b,w)}}],[{key:"getDerivedStateFromProps",value:function(a,s){var l=a.popupVisible,c={};return l!==void 0&&s.popupVisible!==l&&(c.popupVisible=l,c.prevPopupVisible=s.popupVisible),c}}]),i}(f__namespace.Component);return H(t,"contextType",Bp),H(t,"defaultProps",{prefixCls:"rc-trigger-popup",getPopupClassNameFromAlign:Q2,getDocument:J2,onPopupVisibleChange:Cu,afterPopupVisibleChange:Cu,onPopupAlign:Cu,popupClassName:"",mouseEnterDelay:0,mouseLeaveDelay:.1,focusDelay:0,blurDelay:.15,popupStyle:{},destroyPopupOnHide:!1,popupAlign:{},defaultPopupVisible:!1,mask:!1,maskClosable:!0,action:[],showAction:[],hideAction:[],autoDestroy:!1}),t}const rI=tI(h2);var li={adjustX:1,adjustY:1},nI={topLeft:{points:["bl","tl"],overflow:li,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:li,offset:[0,7]},leftTop:{points:["tr","tl"],overflow:li,offset:[-4,0]},rightTop:{points:["tl","tr"],overflow:li,offset:[4,0]}},iI={topLeft:{points:["bl","tl"],overflow:li,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:li,offset:[0,7]},rightTop:{points:["tr","tl"],overflow:li,offset:[-4,0]},leftTop:{points:["tl","tr"],overflow:li,offset:[4,0]}};function A0(e,t,r){if(t)return t;if(r)return r[e]||r.other}var oI={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"};function aI(e){var t=e.prefixCls,r=e.visible,n=e.children,i=e.popup,o=e.popupClassName,a=e.popupOffset,s=e.disabled,l=e.mode,c=e.onVisibleChange,u=f__namespace.useContext(ln),d=u.getPopupContainer,h=u.rtl,v=u.subMenuOpenDelay,p=u.subMenuCloseDelay,m=u.builtinPlacements,g=u.triggerSubMenuAction,b=u.forceSubMenuRender,w=u.rootClassName,S=u.motion,$=u.defaultMotions,x=f__namespace.useState(!1),y=W(x,2),C=y[0],M=y[1],R=D(h?D({},iI):D({},nI),m),P=oI[l],N=A0(l,S,$),_=f__namespace.useRef(N);l!=="inline"&&(_.current=N);var E=D(D({},_.current),{},{leavedClassName:"".concat(t,"-hidden"),removeOnLeave:!1,motionAppear:!0}),O=f__namespace.useRef();return f__namespace.useEffect(function(){return O.current=It(function(){M(r);}),function(){It.cancel(O.current);}},[r]),f__namespace.createElement(rI,{prefixCls:t,popupClassName:K("".concat(t,"-popup"),H({},"".concat(t,"-rtl"),h),o,w),stretch:l==="horizontal"?"minWidth":null,getPopupContainer:d,builtinPlacements:R,popupPlacement:P,popupVisible:C,popup:i,popupAlign:a&&{offset:a},action:s?[]:[g],mouseEnterDelay:v,mouseLeaveDelay:p,onPopupVisibleChange:c,forceRender:b,popupMotion:E},n)}function sI(e){var t=e.id,r=e.open,n=e.keyPath,i=e.children,o="inline",a=f__namespace.useContext(ln),s=a.prefixCls,l=a.forceSubMenuRender,c=a.motion,u=a.defaultMotions,d=a.mode,h=f__namespace.useRef(!1);h.current=d===o;var v=f__namespace.useState(!h.current),p=W(v,2),m=p[0],g=p[1],b=h.current?r:!1;f__namespace.useEffect(function(){h.current&&g(!1);},[d]);var w=D({},A0(o,c,u));n.length>1&&(w.motionAppear=!1);var S=w.onVisibleChanged;return w.onVisibleChanged=function($){return !h.current&&!$&&g(!0),S==null?void 0:S($)},m?null:f__namespace.createElement(Wa,{mode:o,locked:!h.current},f__namespace.createElement(Mn,Ce({visible:b},w,{forceRender:l,removeOnLeave:!1,leavedClassName:"".concat(s,"-hidden")}),function($){var x=$.className,y=$.style;return f__namespace.createElement(qf,{id:t,className:x,style:y},i)}))}var lI=["style","className","title","eventKey","warnKey","disabled","internalPopupClose","children","itemIcon","expandIcon","popupClassName","popupOffset","onClick","onMouseEnter","onMouseLeave","onTitleClick","onTitleMouseEnter","onTitleMouseLeave"],cI=["active"],uI=function(t){var r,n=t.style,i=t.className,o=t.title,a=t.eventKey;t.warnKey;var s=t.disabled,l=t.internalPopupClose,c=t.children,u=t.itemIcon,d=t.expandIcon,h=t.popupClassName,v=t.popupOffset,p=t.onClick,m=t.onMouseEnter,g=t.onMouseLeave,b=t.onTitleClick,w=t.onTitleMouseEnter,S=t.onTitleMouseLeave,$=Xe(t,lI),x=f0(a),y=f__namespace.useContext(ln),C=y.prefixCls,M=y.mode,R=y.openKeys,P=y.disabled,N=y.overflowDisabled,_=y.activeKey,E=y.selectedKeys,O=y.itemIcon,T=y.expandIcon,A=y.onItemClick,I=y.onOpenChange,L=y.onActive,j=f__namespace.useContext(Gf),B=j._internalRenderSubMenuItem,G=f__namespace.useContext(p0),z=G.isSubPathKey,V=cs(),q="".concat(C,"-submenu"),U=P||s,Q=f__namespace.useRef(),ie=f__namespace.useRef(),Z=u||O,te=d||T,ae=R.includes(a),ue=!N&&ae,Ee=z(E,a),J=b0(a,U,w,S),oe=J.active,se=Xe(J,cI),re=f__namespace.useState(!1),xe=W(re,2),de=xe[0],ge=xe[1],ve=function(Ze){U||ge(Ze);},$e=function(Ze){ve(!0),m==null||m({key:a,domEvent:Ze});},Ye=function(Ze){ve(!1),g==null||g({key:a,domEvent:Ze});},dt=f__namespace.useMemo(function(){return oe||(M!=="inline"?de||z([_],a):!1)},[M,oe,_,de,a,z]),xt=y0(V.length),tt=function(Ze){U||(b==null||b({key:a,domEvent:Ze}),M==="inline"&&I(a,!ae));},ke=ao(function(Ke){p==null||p(Pl(Ke)),A(Ke);}),Fe=function(Ze){M!=="inline"&&I(a,Ze);},Oe=function(){L(a);},De=x&&"".concat(x,"-popup"),Te=f__namespace.createElement("div",Ce({role:"menuitem",style:xt,className:"".concat(q,"-title"),tabIndex:U?null:-1,ref:Q,title:typeof o=="string"?o:null,"data-menu-id":N&&x?null:x,"aria-expanded":ue,"aria-haspopup":!0,"aria-controls":De,"aria-disabled":U,onClick:tt,onFocus:Oe},se),o,f__namespace.createElement(w0,{icon:M!=="horizontal"?te:null,props:D(D({},t),{},{isOpen:ue,isSubMenu:!0})},f__namespace.createElement("i",{className:"".concat(q,"-arrow")}))),He=f__namespace.useRef(M);if(M!=="inline"&&V.length>1?He.current="vertical":He.current=M,!N){var rt=He.current;Te=f__namespace.createElement(aI,{mode:rt,prefixCls:q,visible:!l&&ue&&M!=="inline",popupClassName:h,popupOffset:v,popup:f__namespace.createElement(Wa,{mode:rt==="horizontal"?"vertical":rt},f__namespace.createElement(qf,{id:De,ref:ie},c)),disabled:U,onVisibleChange:Fe},Te);}var ft=f__namespace.createElement(Wn.Item,Ce({role:"none"},$,{component:"li",style:n,className:K(q,"".concat(q,"-").concat(M),i,(r={},H(r,"".concat(q,"-open"),ue),H(r,"".concat(q,"-active"),dt),H(r,"".concat(q,"-selected"),Ee),H(r,"".concat(q,"-disabled"),U),r)),onMouseEnter:$e,onMouseLeave:Ye}),Te,!N&&f__namespace.createElement(sI,{id:De,open:ue,keyPath:V},c));return B&&(ft=B(ft,t,{selected:Ee,active:dt,open:ue,disabled:U})),f__namespace.createElement(Wa,{onItemClick:ke,mode:M==="horizontal"?"vertical":M,itemIcon:Z,expandIcon:te},ft)};function th(e){var t=e.eventKey,r=e.children,n=cs(t),i=Xf(r,n),o=xc();f__namespace.useEffect(function(){if(o)return o.registerPath(t,n),function(){o.unregisterPath(t,n);}},[n]);var a;return o?a=i:a=f__namespace.createElement(uI,e,i),f__namespace.createElement(v0.Provider,{value:n},a)}var dI=["prefixCls","rootClassName","style","className","tabIndex","items","children","direction","id","mode","inlineCollapsed","disabled","disabledOverflow","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","defaultOpenKeys","openKeys","activeKey","defaultActiveFirst","selectable","multiple","defaultSelectedKeys","selectedKeys","onSelect","onDeselect","inlineIndent","motion","defaultMotions","triggerSubMenuAction","builtinPlacements","itemIcon","expandIcon","overflowedIndicator","overflowedIndicatorPopupClassName","getPopupContainer","onClick","onOpenChange","onKeyDown","openAnimation","openTransitionName","_internalRenderMenuItem","_internalRenderSubMenuItem"],no=[],fI=f__namespace.forwardRef(function(e,t){var r,n,i=e,o=i.prefixCls,a=o===void 0?"rc-menu":o,s=i.rootClassName,l=i.style,c=i.className,u=i.tabIndex,d=u===void 0?0:u,h=i.items,v=i.children,p=i.direction,m=i.id,g=i.mode,b=g===void 0?"vertical":g,w=i.inlineCollapsed,S=i.disabled,$=i.disabledOverflow,x=i.subMenuOpenDelay,y=x===void 0?.1:x,C=i.subMenuCloseDelay,M=C===void 0?.1:C,R=i.forceSubMenuRender,P=i.defaultOpenKeys,N=i.openKeys,_=i.activeKey,E=i.defaultActiveFirst,O=i.selectable,T=O===void 0?!0:O,A=i.multiple,I=A===void 0?!1:A,L=i.defaultSelectedKeys,j=i.selectedKeys,B=i.onSelect,G=i.onDeselect,z=i.inlineIndent,V=z===void 0?24:z,q=i.motion,U=i.defaultMotions,Q=i.triggerSubMenuAction,ie=Q===void 0?"hover":Q,Z=i.builtinPlacements,te=i.itemIcon,ae=i.expandIcon,ue=i.overflowedIndicator,Ee=ue===void 0?"...":ue,J=i.overflowedIndicatorPopupClassName,oe=i.getPopupContainer,se=i.onClick,re=i.onOpenChange,xe=i.onKeyDown;i.openAnimation,i.openTransitionName;var de=i._internalRenderMenuItem,ge=i._internalRenderSubMenuItem,ve=Xe(i,dI),$e=f__namespace.useMemo(function(){return f2(v,h,no)},[v,h]),Ye=f__namespace.useState(!1),dt=W(Ye,2),xt=dt[0],tt=dt[1],ke=f__namespace.useRef(),Fe=t2(m),Oe=p==="rtl",De=Cn(P,{value:N,postState:function(lt){return lt||no}}),Te=W(De,2),He=Te[0],rt=Te[1],ft=function(lt){var qe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;function Vt(){rt(lt),re==null||re(lt);}qe?$o.flushSync(Vt):Vt();},Ke=f__namespace.useState(He),Ze=W(Ke,2),at=Ze[0],st=Ze[1],wt=f__namespace.useRef(!1),fe=f__namespace.useMemo(function(){return (b==="inline"||b==="vertical")&&w?["vertical",w]:[b,!1]},[b,w]),ce=W(fe,2),_e=ce[0],we=ce[1],Ve=_e==="inline",$t=f__namespace.useState(_e),At=W($t,2),kt=At[0],be=At[1],We=f__namespace.useState(we),Ue=W(We,2),Et=Ue[0],_t=Ue[1];f__namespace.useEffect(function(){be(_e),_t(we),wt.current&&(Ve?rt(at):ft(no));},[_e,we]);var gr=f__namespace.useState(0),fr=W(gr,2),Lt=fr[0],zr=fr[1],tr=Lt>=$e.length-1||kt!=="horizontal"||$;f__namespace.useEffect(function(){Ve&&st(He);},[He]),f__namespace.useEffect(function(){return wt.current=!0,function(){wt.current=!1;}},[]);var Ge=JN(),Ie=Ge.registerPath,pe=Ge.unregisterPath,ht=Ge.refreshOverflowKeys,nt=Ge.isSubPathKey,ar=Ge.getKeyPath,Pe=Ge.getKeys,ye=Ge.getSubPathKeys,Be=f__namespace.useMemo(function(){return {registerPath:Ie,unregisterPath:pe}},[Ie,pe]),Mt=f__namespace.useMemo(function(){return {isSubPathKey:nt}},[nt]);f__namespace.useEffect(function(){ht(tr?no:$e.slice(Lt+1).map(function(St){return St.key}));},[Lt,tr]);var jt=Cn(_||E&&((r=$e[0])===null||r===void 0?void 0:r.key),{value:_}),Rt=W(jt,2),Pr=Rt[0],qr=Rt[1],Rn=ao(function(St){qr(St);}),hi=ao(function(){qr(void 0);});f.useImperativeHandle(t,function(){return {list:ke.current,focus:function(lt){var qe,Vt=Pr??((qe=$e.find(function(vi){return !vi.props.disabled}))===null||qe===void 0?void 0:qe.key);if(Vt){var zt,Qt,hr;(zt=ke.current)===null||zt===void 0||(Qt=zt.querySelector("li[data-menu-id='".concat(Uf(Fe,Vt),"']")))===null||Qt===void 0||(hr=Qt.focus)===null||hr===void 0||hr.call(Qt,lt);}}}});var Zn=Cn(L||[],{value:j,postState:function(lt){return Array.isArray(lt)?lt:lt==null?no:[lt]}}),cn=W(Zn,2),Or=cn[0],zi=cn[1],Bo=function(lt){if(T){var qe=lt.key,Vt=Or.includes(qe),zt;I?Vt?zt=Or.filter(function(hr){return hr!==qe}):zt=[].concat(le(Or),[qe]):zt=[qe],zi(zt);var Qt=D(D({},lt),{},{selectedKeys:zt});Vt?G==null||G(Qt):B==null||B(Qt);}!I&&He.length&&kt!=="inline"&&ft(no);},Hi=ao(function(St){se==null||se(Pl(St)),Bo(St);}),Wi=ao(function(St,lt){var qe=He.filter(function(zt){return zt!==St});if(lt)qe.push(St);else if(kt!=="inline"){var Vt=ye(St);qe=qe.filter(function(zt){return !Vt.has(zt)});}rs(He,qe,!0)||ft(qe,!0);}),Bi=ao(oe),Vo=function(lt,qe){var Vt=qe??!He.includes(lt);Wi(lt,Vt);},Uo=YN(kt,Pr,Oe,Fe,ke,Pe,ar,qr,Vo,xe);f__namespace.useEffect(function(){tt(!0);},[]);var Go=f__namespace.useMemo(function(){return {_internalRenderMenuItem:de,_internalRenderSubMenuItem:ge}},[de,ge]),Vi=kt!=="horizontal"||$?$e:$e.map(function(St,lt){return f__namespace.createElement(Wa,{key:St.key,overflowDisabled:lt>Lt},St)}),Ko=f__namespace.createElement(Wn,Ce({id:m,ref:ke,prefixCls:"".concat(a,"-overflow"),component:"ul",itemComponent:$c,className:K(a,"".concat(a,"-root"),"".concat(a,"-").concat(kt),c,(n={},H(n,"".concat(a,"-inline-collapsed"),Et),H(n,"".concat(a,"-rtl"),Oe),n),s),dir:p,style:l,role:"menu",tabIndex:d,data:Vi,renderRawItem:function(lt){return lt},renderRawRest:function(lt){var qe=lt.length,Vt=qe?$e.slice(-qe):null;return f__namespace.createElement(th,{eventKey:Ld,title:Ee,disabled:tr,internalPopupClose:qe===0,popupClassName:J},Vt)},maxCount:kt!=="horizontal"||$?Wn.INVALIDATE:Wn.RESPONSIVE,ssr:"full","data-menu-list":!0,onVisibleChange:function(lt){zr(lt);},onKeyDown:Uo},ve));return f__namespace.createElement(Gf.Provider,{value:Go},f__namespace.createElement(d0.Provider,{value:Fe},f__namespace.createElement(Wa,{prefixCls:a,rootClassName:s,mode:kt,openKeys:He,rtl:Oe,disabled:S,motion:xt?q:null,defaultMotions:xt?U:null,activeKey:Pr,onActive:Rn,onInactive:hi,selectedKeys:Or,inlineIndent:V,subMenuOpenDelay:y,subMenuCloseDelay:M,forceSubMenuRender:R,builtinPlacements:Z,triggerSubMenuAction:ie,getPopupContainer:Bi,itemIcon:te,expandIcon:ae,onItemClick:Hi,onOpenChange:Wi},f__namespace.createElement(p0.Provider,{value:Mt},Ko),f__namespace.createElement("div",{style:{display:"none"},"aria-hidden":!0},f__namespace.createElement(h0.Provider,{value:Be},$e)))))}),hI=["className","title","eventKey","children"],vI=["children"],pI=function(t){var r=t.className,n=t.title;t.eventKey;var i=t.children,o=Xe(t,hI),a=f__namespace.useContext(ln),s=a.prefixCls,l="".concat(s,"-item-group");return f__namespace.createElement("li",Ce({role:"presentation"},o,{onClick:function(u){return u.stopPropagation()},className:K(l,r)}),f__namespace.createElement("div",{role:"presentation",className:"".concat(l,"-title"),title:typeof n=="string"?n:void 0},n),f__namespace.createElement("ul",{role:"group",className:"".concat(l,"-list")},i))};function k0(e){var t=e.children,r=Xe(e,vI),n=cs(r.eventKey),i=Xf(t,n),o=xc();return o?i:f__namespace.createElement(pI,uc(r,["warnKey"]),i)}function L0(e){var t=e.className,r=e.style,n=f__namespace.useContext(ln),i=n.prefixCls,o=xc();return o?null:f__namespace.createElement("li",{className:K("".concat(i,"-item-divider"),t),style:r})}var ds=fI;ds.Item=$c;ds.SubMenu=th;ds.ItemGroup=k0;ds.Divider=L0;var mI={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"};const gI=mI;var F0=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:gI}))};F0.displayName="EllipsisOutlined";const bI=f__namespace.forwardRef(F0),yI=()=>{const[e,t]=f__namespace.useState(!1);return f__namespace.useEffect(()=>{t(fR());},[]),e};function wI(e){let{className:t,direction:r,index:n,marginDirection:i,children:o,split:a,wrap:s}=e;const{horizontalSize:l,verticalSize:c,latestIndex:u,supportFlexGap:d}=f__namespace.useContext(D0);let h={};return d||(r==="vertical"?n{const{getPrefixCls:r,space:n,direction:i}=f__namespace.useContext(Wt),{size:o=(n==null?void 0:n.size)||"small",align:a,className:s,rootClassName:l,children:c,direction:u="horizontal",prefixCls:d,split:h,style:v,wrap:p=!1}=e,m=SI(e,["size","align","className","rootClassName","children","direction","prefixCls","split","style","wrap"]),g=yI(),[b,w]=f__namespace.useMemo(()=>(Array.isArray(o)?o:[o,o]).map(T=>xI(T)),[o]),S=di(c,{keepEmpty:!0}),$=a===void 0&&u==="horizontal"?"center":a,x=r("space",d),[y,C]=Hb(x),M=K(x,C,`${x}-${u}`,{[`${x}-rtl`]:i==="rtl",[`${x}-align-${$}`]:$},s,l),R=`${x}-item`,P=i==="rtl"?"marginLeft":"marginRight";let N=0;const _=S.map((T,A)=>{T!=null&&(N=A);const I=T&&T.key||`${R}-${A}`;return f__namespace.createElement(wI,{className:R,key:I,direction:u,index:A,marginDirection:P,split:h,wrap:p},T)}),E=f__namespace.useMemo(()=>({horizontalSize:b,verticalSize:w,latestIndex:N,supportFlexGap:g}),[b,w,N,g]);if(S.length===0)return null;const O={};return p&&(O.flexWrap="wrap",g||(O.marginBottom=-w)),g&&(O.columnGap=b,O.rowGap=w),y(f__namespace.createElement("div",Object.assign({ref:t,className:M,style:Object.assign(Object.assign({},O),v)},m),f__namespace.createElement(D0.Provider,{value:E},_)))}),j0=$I;j0.Compact=xM;const rh=j0,z0=f__namespace.createContext(null),EI=z0.Provider,H0=f__namespace.createContext(null),_I=H0.Provider;var PI=["prefixCls","className","style","checked","disabled","defaultChecked","type","onChange"],W0=f.forwardRef(function(e,t){var r,n=e.prefixCls,i=n===void 0?"rc-checkbox":n,o=e.className,a=e.style,s=e.checked,l=e.disabled,c=e.defaultChecked,u=c===void 0?!1:c,d=e.type,h=d===void 0?"checkbox":d,v=e.onChange,p=Xe(e,PI),m=f.useRef(null),g=Cn(u,{value:s}),b=W(g,2),w=b[0],S=b[1];f.useImperativeHandle(t,function(){return {focus:function(){var C;(C=m.current)===null||C===void 0||C.focus();},blur:function(){var C;(C=m.current)===null||C===void 0||C.blur();},input:m.current}});var $=K(i,o,(r={},H(r,"".concat(i,"-checked"),w),H(r,"".concat(i,"-disabled"),l),r)),x=function(C){l||("checked"in e||S(C.target.checked),v==null||v({target:D(D({},e),{},{checked:C.target.checked}),stopPropagation:function(){C.stopPropagation();},preventDefault:function(){C.preventDefault();},nativeEvent:C.nativeEvent}));};return f__namespace.createElement("span",{className:$,style:a},f__namespace.createElement("input",Ce({},p,{className:"".concat(i,"-input"),ref:m,onChange:x,disabled:l,checked:!!w,type:h})),f__namespace.createElement("span",{className:"".concat(i,"-inner")}))});const OI=new Dt("antRadioEffect",{"0%":{transform:"scale(1)",opacity:.5},"100%":{transform:"scale(1.6)",opacity:0}}),TI=e=>{const{componentCls:t,antCls:r}=e,n=`${t}-group`;return {[n]:Object.assign(Object.assign({},yr(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"}})}},MI=e=>{const{componentCls:t,radioWrapperMarginRight:r,radioCheckedColor:n,radioSize:i,motionDurationSlow:o,motionDurationMid:a,motionEaseInOut:s,motionEaseInOutCirc:l,radioButtonBg:c,colorBorder:u,lineWidth:d,radioDotSize:h,colorBgContainerDisabled:v,colorTextDisabled:p,paddingXS:m,radioDotDisabledColor:g,lineType:b,radioDotDisabledSize:w,wireframe:S,colorWhite:$}=e,x=`${t}-inner`;return {[`${t}-wrapper`]:Object.assign(Object.assign({},yr(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:`${d}px ${b} ${n}`,borderRadius:"50%",visibility:"hidden",animationName:OI,animationDuration:o,animationTimingFunction:s,animationFillMode:"both",content:'""'},[t]:Object.assign(Object.assign({},yr(e)),{position:"relative",display:"inline-block",outline:"none",cursor:"pointer",alignSelf:"center"}),[`${t}-wrapper:hover &, &:hover ${x}`]:{borderColor:n},[`${t}-input:focus-visible + ${x}`]:Object.assign({},pc(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:i,height:i,marginBlockStart:i/-2,marginInlineStart:i/-2,backgroundColor:S?n:$,borderBlockStart:0,borderInlineStart:0,borderRadius:i,transform:"scale(0)",opacity:0,transition:`all ${o} ${l}`,content:'""'},boxSizing:"border-box",position:"relative",insetBlockStart:0,insetInlineStart:0,display:"block",width:i,height:i,backgroundColor:c,borderColor:u,borderStyle:"solid",borderWidth:d,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`]:{[x]:{borderColor:n,backgroundColor:S?c:n,"&::after":{transform:`scale(${h/i})`,opacity:1,transition:`all ${o} ${l}`}}},[`${t}-disabled`]:{cursor:"not-allowed",[x]:{backgroundColor:v,borderColor:u,cursor:"not-allowed","&::after":{backgroundColor:g}},[`${t}-input`]:{cursor:"not-allowed"},[`${t}-disabled + span`]:{color:p,cursor:"not-allowed"},[`&${t}-checked`]:{[x]:{"&::after":{transform:`scale(${w/i})`}}}},[`span${t} + *`]:{paddingInlineStart:m,paddingInlineEnd:m}})}},RI=e=>{const{radioButtonColor:t,controlHeight:r,componentCls:n,lineWidth:i,lineType:o,colorBorder:a,motionDurationSlow:s,motionDurationMid:l,radioButtonPaddingHorizontal:c,fontSize:u,radioButtonBg:d,fontSizeLG:h,controlHeightLG:v,controlHeightSM:p,paddingXS:m,borderRadius:g,borderRadiusSM:b,borderRadiusLG:w,radioCheckedColor:S,radioButtonCheckedBg:$,radioButtonHoverColor:x,radioButtonActiveColor:y,radioSolidCheckedColor:C,colorTextDisabled:M,colorBgContainerDisabled:R,radioDisabledButtonCheckedColor:P,radioDisabledButtonCheckedBg:N}=e;return {[`${n}-button-wrapper`]:{position:"relative",display:"inline-block",height:r,margin:0,paddingInline:c,paddingBlock:0,color:t,fontSize:u,lineHeight:`${r-i*2}px`,background:d,border:`${i}px ${o} ${a}`,borderBlockStartWidth:i+.02,borderInlineStartWidth:0,borderInlineEndWidth:i,cursor:"pointer",transition:[`color ${l}`,`background ${l}`,`border-color ${l}`,`box-shadow ${l}`].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:-i,insetInlineStart:-i,display:"block",boxSizing:"content-box",width:1,height:"100%",paddingBlock:i,paddingInline:0,backgroundColor:a,transition:`background-color ${s}`,content:'""'}},"&:first-child":{borderInlineStart:`${i}px ${o} ${a}`,borderStartStartRadius:g,borderEndStartRadius:g},"&:last-child":{borderStartEndRadius:g,borderEndEndRadius:g},"&:first-child:last-child":{borderRadius:g},[`${n}-group-large &`]:{height:v,fontSize:h,lineHeight:`${v-i*2}px`,"&:first-child":{borderStartStartRadius:w,borderEndStartRadius:w},"&:last-child":{borderStartEndRadius:w,borderEndEndRadius:w}},[`${n}-group-small &`]:{height:p,paddingInline:m-i,paddingBlock:0,lineHeight:`${p-i*2}px`,"&:first-child":{borderStartStartRadius:b,borderEndStartRadius:b},"&:last-child":{borderStartEndRadius:b,borderEndEndRadius:b}},"&:hover":{position:"relative",color:S},"&:has(:focus-visible)":Object.assign({},pc(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:S,background:$,borderColor:S,"&::before":{backgroundColor:S},"&:first-child":{borderColor:S},"&:hover":{color:x,borderColor:x,"&::before":{backgroundColor:x}},"&:active":{color:y,borderColor:y,"&::before":{backgroundColor:y}}},[`${n}-group-solid &-checked:not(${n}-button-wrapper-disabled)`]:{color:C,background:S,borderColor:S,"&:hover":{color:C,background:x,borderColor:x},"&:active":{color:C,background:y,borderColor:y}},"&-disabled":{color:M,backgroundColor:R,borderColor:a,cursor:"not-allowed","&:first-child, &:hover":{color:M,backgroundColor:R,borderColor:a}},[`&-disabled${n}-button-wrapper-checked`]:{color:P,backgroundColor:N,borderColor:a,boxShadow:"none"}}}},B0=Tn("Radio",e=>{const{padding:t,lineWidth:r,controlItemBgActiveDisabled:n,colorTextDisabled:i,colorBgContainer:o,fontSizeLG:a,controlOutline:s,colorPrimaryHover:l,colorPrimaryActive:c,colorText:u,colorPrimary:d,marginXS:h,controlOutlineWidth:v,colorTextLightSolid:p,wireframe:m}=e,g=`0 0 0 ${v}px ${s}`,b=g,w=a,S=4,$=w-S*2,x=m?$:w-(S+r)*2,y=d,C=u,M=l,R=c,P=t-r,E=mr(e,{radioFocusShadow:g,radioButtonFocusShadow:b,radioSize:w,radioDotSize:x,radioDotDisabledSize:$,radioCheckedColor:y,radioDotDisabledColor:i,radioSolidCheckedColor:p,radioButtonBg:o,radioButtonCheckedBg:o,radioButtonColor:C,radioButtonHoverColor:M,radioButtonActiveColor:R,radioButtonPaddingHorizontal:P,radioDisabledButtonCheckedBg:n,radioDisabledButtonCheckedColor:i,radioWrapperMarginRight:h});return [TI(E),MI(E),RI(E)]});var NI=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 i=0,n=Object.getOwnPropertySymbols(e);i{var r,n;const i=f__namespace.useContext(z0),o=f__namespace.useContext(H0),{getPrefixCls:a,direction:s}=f__namespace.useContext(Wt),l=f__namespace.useRef(null),c=Kr(t,l),{isFormItemInput:u}=f__namespace.useContext(za),d=R=>{var P,N;(P=e.onChange)===null||P===void 0||P.call(e,R),(N=i==null?void 0:i.onChange)===null||N===void 0||N.call(i,R);},{prefixCls:h,className:v,rootClassName:p,children:m,style:g}=e,b=NI(e,["prefixCls","className","rootClassName","children","style"]),w=a("radio",h),S=((i==null?void 0:i.optionType)||o)==="button"?`${w}-button`:w,[$,x]=B0(w),y=Object.assign({},b),C=f__namespace.useContext(as);i&&(y.name=i.name,y.onChange=d,y.checked=e.value===i.value,y.disabled=(r=y.disabled)!==null&&r!==void 0?r:i.disabled),y.disabled=(n=y.disabled)!==null&&n!==void 0?n:C;const M=K(`${S}-wrapper`,{[`${S}-wrapper-checked`]:y.checked,[`${S}-wrapper-disabled`]:y.disabled,[`${S}-wrapper-rtl`]:s==="rtl",[`${S}-wrapper-in-form-item`]:u},v,p,x);return $(f__namespace.createElement("label",{className:M,style:g,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave},f__namespace.createElement(W0,Object.assign({},y,{type:"radio",prefixCls:S,ref:c})),m!==void 0?f__namespace.createElement("span",null,m):null))},AI=f__namespace.forwardRef(II),Tl=AI,kI=f__namespace.forwardRef((e,t)=>{const{getPrefixCls:r,direction:n}=f__namespace.useContext(Wt),[i,o]=Cn(e.defaultValue,{value:e.value}),a=_=>{const E=i,O=_.target.value;"value"in e||o(O);const{onChange:T}=e;T&&O!==E&&T(_);},{prefixCls:s,className:l,rootClassName:c,options:u,buttonStyle:d="outline",disabled:h,children:v,size:p,style:m,id:g,onMouseEnter:b,onMouseLeave:w,onFocus:S,onBlur:$}=e,x=r("radio",s),y=`${x}-group`,[C,M]=B0(x);let R=v;u&&u.length>0&&(R=u.map(_=>typeof _=="string"||typeof _=="number"?f__namespace.createElement(Tl,{key:_.toString(),prefixCls:x,disabled:h,value:_,checked:i===_},_):f__namespace.createElement(Tl,{key:`radio-group-value-options-${_.value}`,prefixCls:x,disabled:_.disabled||h,value:_.value,checked:i===_.value,style:_.style},_.label)));const P=Do(p),N=K(y,`${y}-${d}`,{[`${y}-${P}`]:P,[`${y}-rtl`]:n==="rtl"},l,c,M);return C(f__namespace.createElement("div",Object.assign({},YT(e),{className:N,style:m,onMouseEnter:b,onMouseLeave:w,onFocus:S,onBlur:$,id:g,ref:t}),f__namespace.createElement(EI,{value:{onChange:a,value:i,disabled:e.disabled,name:e.name,optionType:e.optionType}},R)))}),LI=f__namespace.memo(kI);var FI=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{getPrefixCls:r}=f__namespace.useContext(Wt),{prefixCls:n}=e,i=FI(e,["prefixCls"]),o=r("radio",n);return f__namespace.createElement(_I,{value:"button"},f__namespace.createElement(Tl,Object.assign({prefixCls:o},i,{type:"radio",ref:t})))},jI=f__namespace.forwardRef(DI),_c=Tl;_c.Button=jI;_c.Group=LI;_c.__ANT_RADIO=!0;const xu=_c,V0=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),Pc=e=>({borderColor:e.inputBorderHoverColor,borderInlineEndWidth:e.lineWidth}),Ml=e=>({borderColor:e.inputBorderHoverColor,boxShadow:`0 0 0 ${e.controlOutlineWidth}px ${e.controlOutline}`,borderInlineEndWidth:e.lineWidth,outline:0}),U0=e=>({color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,boxShadow:"none",cursor:"not-allowed",opacity:1,"&:hover":Object.assign({},Pc(mr(e,{inputBorderHoverColor:e.colorBorder})))}),G0=e=>{const{inputPaddingVerticalLG:t,fontSizeLG:r,lineHeightLG:n,borderRadiusLG:i,inputPaddingHorizontalLG:o}=e;return {padding:`${t}px ${o}px`,fontSize:r,lineHeight:n,borderRadius:i}},K0=e=>({padding:`${e.inputPaddingVerticalSM}px ${e.controlPaddingHorizontalSM-1}px`,borderRadius:e.borderRadiusSM}),q0=(e,t)=>{const{componentCls:r,colorError:n,colorWarning:i,colorErrorOutline:o,colorWarningOutline:a,colorErrorBorderHover:s,colorWarningBorderHover:l}=e;return {[`&-status-error:not(${t}-disabled):not(${t}-borderless)${t}`]:{borderColor:n,"&:hover":{borderColor:s},"&:focus, &-focused":Object.assign({},Ml(mr(e,{inputBorderActiveColor:n,inputBorderHoverColor:n,controlOutline:o}))),[`${r}-prefix, ${r}-suffix`]:{color:n}},[`&-status-warning:not(${t}-disabled):not(${t}-borderless)${t}`]:{borderColor:i,"&:hover":{borderColor:l},"&:focus, &-focused":Object.assign({},Ml(mr(e,{inputBorderActiveColor:i,inputBorderHoverColor:i,controlOutline:a}))),[`${r}-prefix, ${r}-suffix`]:{color:i}}}},X0=e=>Object.assign(Object.assign({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:`${e.inputPaddingVertical}px ${e.inputPaddingHorizontal}px`,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,backgroundColor:e.colorBgContainer,backgroundImage:"none",borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:e.colorBorder,borderRadius:e.borderRadius,transition:`all ${e.motionDurationMid}`},V0(e.colorTextPlaceholder)),{"&:hover":Object.assign({},Pc(e)),"&:focus, &-focused":Object.assign({},Ml(e)),"&-disabled, &[disabled]":Object.assign({},U0(e)),"&-borderless":{"&, &:hover, &:focus, &-focused, &-disabled, &[disabled]":{backgroundColor:"transparent",border:"none",boxShadow:"none"}},"textarea&":{maxWidth:"100%",height:"auto",minHeight:e.controlHeight,lineHeight:e.lineHeight,verticalAlign:"bottom",transition:`all ${e.motionDurationSlow}, height 0s`,resize:"vertical"},"&-lg":Object.assign({},G0(e)),"&-sm":Object.assign({},K0(e)),"&-rtl":{direction:"rtl"},"&-textarea-rtl":{direction:"rtl"}}),zI=e=>{const{componentCls:t,antCls:r}=e;return {position:"relative",display:"table",width:"100%",borderCollapse:"separate",borderSpacing:0,["&[class*='col-']"]:{paddingInlineEnd:e.paddingXS,"&:last-child":{paddingInlineEnd:0}},[`&-lg ${t}, &-lg > ${t}-group-addon`]:Object.assign({},G0(e)),[`&-sm ${t}, &-sm > ${t}-group-addon`]:Object.assign({},K0(e)),[`&-lg ${r}-select-single ${r}-select-selector`]:{height:e.controlHeightLG},[`&-sm ${r}-select-single ${r}-select-selector`]:{height:e.controlHeightSM},[`> ${t}`]:{display:"table-cell","&:not(:first-child):not(:last-child)":{borderRadius:0}},[`${t}-group`]:{["&-addon, &-wrap"]:{display:"table-cell",width:1,whiteSpace:"nowrap",verticalAlign:"middle","&:not(:first-child):not(:last-child)":{borderRadius:0}},"&-wrap > *":{display:"block !important"},"&-addon":{position:"relative",padding:`0 ${e.inputPaddingHorizontal}px`,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,textAlign:"center",backgroundColor:e.colorFillAlter,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadius,transition:`all ${e.motionDurationSlow}`,lineHeight:1,[`${r}-select`]:{margin:`-${e.inputPaddingVertical+1}px -${e.inputPaddingHorizontal}px`,[`&${r}-select-single:not(${r}-select-customize-input)`]:{[`${r}-select-selector`]:{backgroundColor:"inherit",border:`${e.lineWidth}px ${e.lineType} transparent`,boxShadow:"none"}},"&-open, &-focused":{[`${r}-select-selector`]:{color:e.colorPrimary}}},[`${r}-cascader-picker`]:{margin:`-9px -${e.inputPaddingHorizontal}px`,backgroundColor:"transparent",[`${r}-cascader-input`]:{textAlign:"start",border:0,boxShadow:"none"}}},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}},[`${t}`]:{width:"100%",marginBottom:0,textAlign:"inherit","&:focus":{zIndex:1,borderInlineEndWidth:1},"&:hover":{zIndex:1,borderInlineEndWidth:1,[`${t}-search-with-button &`]:{zIndex:0}}},[`> ${t}:first-child, ${t}-group-addon:first-child`]:{borderStartEndRadius:0,borderEndEndRadius:0,[`${r}-select ${r}-select-selector`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}-affix-wrapper`]:{[`&:not(:first-child) ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0},[`&:not(:last-child) ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}:last-child, ${t}-group-addon:last-child`]:{borderStartStartRadius:0,borderEndStartRadius:0,[`${r}-select ${r}-select-selector`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`${t}-affix-wrapper`]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0,[`${t}-search &`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius}},[`&:not(:first-child), ${t}-search &:not(:first-child)`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&${t}-group-compact`]:Object.assign(Object.assign({display:"block"},ZO()),{[`${t}-group-addon, ${t}-group-wrap, > ${t}`]:{"&:not(:first-child):not(:last-child)":{borderInlineEndWidth:e.lineWidth,"&:hover":{zIndex:1},"&:focus":{zIndex:1}}},"& > *":{display:"inline-block",float:"none",verticalAlign:"top",borderRadius:0},[`& > ${t}-affix-wrapper`]:{display:"inline-flex"},[`& > ${r}-picker-range`]:{display:"inline-flex"},"& > *:not(:last-child)":{marginInlineEnd:-e.lineWidth,borderInlineEndWidth:e.lineWidth},[`${t}`]:{float:"none"},[`& > ${r}-select > ${r}-select-selector, & > ${r}-select-auto-complete ${t}, & > ${r}-cascader-picker ${t}, & > ${t}-group-wrapper ${t}`]:{borderInlineEndWidth:e.lineWidth,borderRadius:0,"&:hover":{zIndex:1},"&:focus":{zIndex:1}},[`& > ${r}-select-focused`]:{zIndex:1},[`& > ${r}-select > ${r}-select-arrow`]:{zIndex:1},[`& > *:first-child, & > ${r}-select:first-child > ${r}-select-selector, & > ${r}-select-auto-complete:first-child ${t}, & > ${r}-cascader-picker:first-child ${t}`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius},[`& > *:last-child, & > ${r}-select:last-child > ${r}-select-selector, & > ${r}-cascader-picker:last-child ${t}, & > ${r}-cascader-picker-focused:last-child ${t}`]:{borderInlineEndWidth:e.lineWidth,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius},[`& > ${r}-select-auto-complete ${t}`]:{verticalAlign:"top"},[`${t}-group-wrapper + ${t}-group-wrapper`]:{marginInlineStart:-e.lineWidth,[`${t}-affix-wrapper`]:{borderRadius:0}},[`${t}-group-wrapper:not(:last-child)`]:{[`&${t}-search > ${t}-group`]:{[`& > ${t}-group-addon > ${t}-search-button`]:{borderRadius:0},[`& > ${t}`]:{borderStartStartRadius:e.borderRadius,borderStartEndRadius:0,borderEndEndRadius:0,borderEndStartRadius:e.borderRadius}}}})}};function HI(e){return mr(e,{inputAffixPadding:e.paddingXXS,inputPaddingVertical:Math.max(Math.round((e.controlHeight-e.fontSize*e.lineHeight)/2*10)/10-e.lineWidth,3),inputPaddingVerticalLG:Math.ceil((e.controlHeightLG-e.fontSizeLG*e.lineHeightLG)/2*10)/10-e.lineWidth,inputPaddingVerticalSM:Math.max(Math.round((e.controlHeightSM-e.fontSize*e.lineHeight)/2*10)/10-e.lineWidth,0),inputPaddingHorizontal:e.paddingSM-e.lineWidth,inputPaddingHorizontalSM:e.paddingXS-e.lineWidth,inputPaddingHorizontalLG:e.controlPaddingHorizontal-e.lineWidth,inputBorderHoverColor:e.colorPrimaryHover,inputBorderActiveColor:e.colorPrimaryHover})}var WI={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M176 474h672q8 0 8 8v60q0 8-8 8H176q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"};const BI=WI;var Y0=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:BI}))};Y0.displayName="PlusOutlined";const VI=f__namespace.forwardRef(Y0),Oc=f.createContext(null);var Z0=f__namespace.forwardRef(function(e,t){var r=e.prefixCls,n=e.className,i=e.style,o=e.id,a=e.active,s=e.tabKey,l=e.children;return f__namespace.createElement("div",{id:o&&"".concat(o,"-panel-").concat(s),role:"tabpanel",tabIndex:a?0:-1,"aria-labelledby":o&&"".concat(o,"-tab-").concat(s),"aria-hidden":!a,style:i,className:K(r,a&&"".concat(r,"-active"),n),ref:t},l)}),UI=["key","forceRender","style","className"];function GI(e){var t=e.id,r=e.activeKey,n=e.animated,i=e.tabPosition,o=e.destroyInactiveTabPane,a=f__namespace.useContext(Oc),s=a.prefixCls,l=a.tabs,c=n.tabPane,u="".concat(s,"-tabpane");return f__namespace.createElement("div",{className:K("".concat(s,"-content-holder"))},f__namespace.createElement("div",{className:K("".concat(s,"-content"),"".concat(s,"-content-").concat(i),H({},"".concat(s,"-content-animated"),c))},l.map(function(d){var h=d.key,v=d.forceRender,p=d.style,m=d.className,g=Xe(d,UI),b=h===r;return f__namespace.createElement(Mn,Ce({key:h,visible:b,forceRender:v,removeOnLeave:!!o,leavedClassName:"".concat(u,"-hidden")},n.tabPaneMotion),function(w,S){var $=w.style,x=w.className;return f__namespace.createElement(Z0,Ce({},g,{prefixCls:u,id:t,tabKey:h,animated:c,active:b,style:D(D({},p),$),className:K(m,x),ref:S}))})})))}var Vp={width:0,height:0,left:0,top:0};function KI(e,t,r){return f.useMemo(function(){for(var n,i=new Map,o=t.get((n=e[0])===null||n===void 0?void 0:n.key)||Vp,a=o.left+o.width,s=0;sO?(_=P,y.current="x"):(_=N,y.current="y"),t(-_,-_)&&R.preventDefault();}var M=f.useRef(null);M.current={onTouchStart:S,onTouchMove:$,onTouchEnd:x,onWheel:C},f__namespace.useEffect(function(){function R(E){M.current.onTouchStart(E);}function P(E){M.current.onTouchMove(E);}function N(E){M.current.onTouchEnd(E);}function _(E){M.current.onWheel(E);}return document.addEventListener("touchmove",P,{passive:!1}),document.addEventListener("touchend",N,{passive:!1}),e.current.addEventListener("touchstart",R,{passive:!1}),e.current.addEventListener("wheel",_),function(){document.removeEventListener("touchmove",P),document.removeEventListener("touchend",N);}},[]);}function Q0(e){var t=f.useState(0),r=W(t,2),n=r[0],i=r[1],o=f.useRef(0),a=f.useRef();return a.current=e,po(function(){var s;(s=a.current)===null||s===void 0||s.call(a);},[n]),function(){o.current===n&&(o.current+=1,i(o.current));}}function YI(e){var t=f.useRef([]),r=f.useState({}),n=W(r,2),i=n[1],o=f.useRef(typeof e=="function"?e():e),a=Q0(function(){var l=o.current;t.current.forEach(function(c){l=c(l);}),t.current=[],o.current=l,i({});});function s(l){t.current.push(l),a();}return [o.current,s]}var qp={width:0,height:0,left:0,top:0,right:0};function ZI(e,t,r,n,i,o,a){var s=a.tabs,l=a.tabPosition,c=a.rtl,u,d,h;return ["top","bottom"].includes(l)?(u="width",d=c?"right":"left",h=Math.abs(r)):(u="height",d="top",h=-r),f.useMemo(function(){if(!s.length)return [0,0];for(var v=s.length,p=v,m=0;mh+t){p=m-1;break}}for(var b=0,w=v-1;w>=0;w-=1){var S=e.get(s[w].key)||qp;if(S[d]ye?"left":"right"});}),E=W(_,2),O=E[0],T=E[1],A=Up(0,function(Pe,ye){!N&&S&&S({direction:Pe>ye?"top":"bottom"});}),I=W(A,2),L=I[0],j=I[1],B=f.useState([0,0]),G=W(B,2),z=G[0],V=G[1],q=f.useState([0,0]),U=W(q,2),Q=U[0],ie=U[1],Z=f.useState([0,0]),te=W(Z,2),ae=te[0],ue=te[1],Ee=f.useState([0,0]),J=W(Ee,2),oe=J[0],se=J[1],re=YI(new Map),xe=W(re,2),de=xe[0],ge=xe[1],ve=KI(o,de,Q[0]),$e=zs(z,N),Ye=zs(Q,N),dt=zs(ae,N),xt=zs(oe,N),tt=$eDe?De:Pe}var He=f.useRef(),rt=f.useState(),ft=W(rt,2),Ke=ft[0],Ze=ft[1];function at(){Ze(Date.now());}function st(){window.clearTimeout(He.current);}XI(C,function(Pe,ye){function Be(Mt,jt){Mt(function(Rt){var Pr=Te(Rt+jt);return Pr});}return tt?(N?Be(T,Pe):Be(j,ye),st(),at(),!0):!1}),f.useEffect(function(){return st(),Ke&&(He.current=window.setTimeout(function(){Ze(0);},100)),st},[Ke]);var wt=ZI(ve,ke,N?O:L,Ye,dt,xt,D(D({},e),{},{tabs:o})),fe=W(wt,2),ce=fe[0],_e=fe[1],we=nn(function(){var Pe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:u,ye=ve.get(Pe)||{width:0,height:0,left:0,right:0,top:0};if(N){var Be=O;d?ye.rightO+ke&&(Be=ye.right+ye.width-ke):ye.left<-O?Be=-ye.left:ye.left+ye.width>-O+ke&&(Be=-(ye.left+ye.width-ke)),j(0),T(Te(Be));}else {var Mt=L;ye.top<-L?Mt=-ye.top:ye.top+ye.height>-L+ke&&(Mt=-(ye.top+ye.height-ke)),T(0),j(Te(Mt));}}),Ve={};m==="top"||m==="bottom"?Ve[d?"marginRight":"marginLeft"]=g:Ve.marginTop=g;var $t=o.map(function(Pe,ye){var Be=Pe.key;return f__namespace.createElement(rA,{id:l,prefixCls:i,key:Be,tab:Pe,style:ye===0?void 0:Ve,closable:Pe.closable,editable:v,active:Be===u,renderWrapper:b,removeAriaLabel:p==null?void 0:p.removeAriaLabel,onClick:function(jt){w(Be,jt);},onFocus:function(){we(Be),at(),C.current&&(d||(C.current.scrollLeft=0),C.current.scrollTop=0);}})}),At=function(){return ge(function(){var ye=new Map;return o.forEach(function(Be){var Mt,jt=Be.key,Rt=(Mt=M.current)===null||Mt===void 0?void 0:Mt.querySelector('[data-node-key="'.concat(J0(jt),'"]'));Rt&&ye.set(jt,{width:Rt.offsetWidth,height:Rt.offsetHeight,left:Rt.offsetLeft,top:Rt.offsetTop});}),ye})};f.useEffect(function(){At();},[o.map(function(Pe){return Pe.key}).join("_")]);var kt=Q0(function(){var Pe=io($),ye=io(x),Be=io(y);V([Pe[0]-ye[0]-Be[0],Pe[1]-ye[1]-Be[1]]);var Mt=io(P);ue(Mt);var jt=io(R);se(jt);var Rt=io(M);ie([Rt[0]-Mt[0],Rt[1]-Mt[1]]),At();}),be=o.slice(0,ce),We=o.slice(_e+1),Ue=[].concat(le(be),le(We)),Et=f.useState(),_t=W(Et,2),gr=_t[0],fr=_t[1],Lt=ve.get(u),zr=f.useRef();function tr(){It.cancel(zr.current);}f.useEffect(function(){var Pe={};return Lt&&(N?(d?Pe.right=Lt.right:Pe.left=Lt.left,Pe.width=Lt.width):(Pe.top=Lt.top,Pe.height=Lt.height)),tr(),zr.current=It(function(){fr(Pe);}),tr},[Lt,N,d]),f.useEffect(function(){we();},[u,Oe,De,Xp(Lt),Xp(ve),N]),f.useEffect(function(){kt();},[d]);var Ge=!!Ue.length,Ie="".concat(i,"-nav-wrap"),pe,ht,nt,ar;return N?d?(ht=O>0,pe=O!==De):(pe=O<0,ht=O!==Oe):(nt=L<0,ar=L!==Oe),f__namespace.createElement(Ai,{onResize:kt},f__namespace.createElement("div",{ref:lc(t,$),role:"tablist",className:K("".concat(i,"-nav"),a),style:s,onKeyDown:function(){at();}},f__namespace.createElement(Yp,{ref:x,position:"left",extra:h,prefixCls:i}),f__namespace.createElement("div",{className:K(Ie,(r={},H(r,"".concat(Ie,"-ping-left"),pe),H(r,"".concat(Ie,"-ping-right"),ht),H(r,"".concat(Ie,"-ping-top"),nt),H(r,"".concat(Ie,"-ping-bottom"),ar),r)),ref:C},f__namespace.createElement(Ai,{onResize:kt},f__namespace.createElement("div",{ref:M,className:"".concat(i,"-nav-list"),style:{transform:"translate(".concat(O,"px, ").concat(L,"px)"),transition:Ke?"none":void 0}},$t,f__namespace.createElement(ey,{ref:P,prefixCls:i,locale:p,editable:v,style:D(D({},$t.length===0?void 0:Ve),{},{visibility:Ge?"hidden":null})}),f__namespace.createElement("div",{className:K("".concat(i,"-ink-bar"),H({},"".concat(i,"-ink-bar-animated"),c.inkBar)),style:gr})))),f__namespace.createElement(tA,Ce({},e,{removeAriaLabel:p==null?void 0:p.removeAriaLabel,ref:R,prefixCls:i,tabs:Ue,className:!Ge&&Fe,tabMoving:!!Ke})),f__namespace.createElement(Yp,{ref:y,position:"right",extra:h,prefixCls:i})))}const Zp=f__namespace.forwardRef(nA);var iA=["renderTabBar"],oA=["label","key"];function aA(e){var t=e.renderTabBar,r=Xe(e,iA),n=f__namespace.useContext(Oc),i=n.tabs;if(t){var o=D(D({},r),{},{panes:i.map(function(a){var s=a.label,l=a.key,c=Xe(a,oA);return f__namespace.createElement(Z0,Ce({tab:s,key:l,tabKey:l},c))})});return t(o,Zp)}return f__namespace.createElement(Zp,r)}function sA(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{inkBar:!0,tabPane:!1},t;return e===!1?t={inkBar:!1,tabPane:!1}:e===!0?t={inkBar:!0,tabPane:!1}:t=D({inkBar:!0},ot(e)==="object"?e:{}),t.tabPaneMotion&&t.tabPane===void 0&&(t.tabPane=!0),!t.tabPaneMotion&&t.tabPane&&(t.tabPane=!1),t}var lA=["id","prefixCls","className","items","direction","activeKey","defaultActiveKey","editable","animated","tabPosition","tabBarGutter","tabBarStyle","tabBarExtraContent","locale","moreIcon","moreTransitionName","destroyInactiveTabPane","renderTabBar","onChange","onTabClick","onTabScroll","getPopupContainer","popupClassName"],Qp=0;function cA(e,t){var r,n=e.id,i=e.prefixCls,o=i===void 0?"rc-tabs":i,a=e.className,s=e.items,l=e.direction,c=e.activeKey,u=e.defaultActiveKey,d=e.editable,h=e.animated,v=e.tabPosition,p=v===void 0?"top":v,m=e.tabBarGutter,g=e.tabBarStyle,b=e.tabBarExtraContent,w=e.locale,S=e.moreIcon,$=e.moreTransitionName,x=e.destroyInactiveTabPane,y=e.renderTabBar,C=e.onChange,M=e.onTabClick,R=e.onTabScroll,P=e.getPopupContainer,N=e.popupClassName,_=Xe(e,lA),E=f__namespace.useMemo(function(){return (s||[]).filter(function(re){return re&&ot(re)==="object"&&"key"in re})},[s]),O=l==="rtl",T=sA(h),A=f.useState(!1),I=W(A,2),L=I[0],j=I[1];f.useEffect(function(){j(Cc());},[]);var B=Cn(function(){var re;return (re=E[0])===null||re===void 0?void 0:re.key},{value:c,defaultValue:u}),G=W(B,2),z=G[0],V=G[1],q=f.useState(function(){return E.findIndex(function(re){return re.key===z})}),U=W(q,2),Q=U[0],ie=U[1];f.useEffect(function(){var re=E.findIndex(function(de){return de.key===z});if(re===-1){var xe;re=Math.max(0,Math.min(Q,E.length-1)),V((xe=E[re])===null||xe===void 0?void 0:xe.key);}ie(re);},[E.map(function(re){return re.key}).join("_"),z,Q]);var Z=Cn(null,{value:n}),te=W(Z,2),ae=te[0],ue=te[1];f.useEffect(function(){n||(ue("rc-tabs-".concat(Qp)),Qp+=1);},[]);function Ee(re,xe){M==null||M(re,xe);var de=re!==z;V(re),de&&(C==null||C(re));}var J={id:ae,activeKey:z,animated:T,tabPosition:p,rtl:O,mobile:L},oe,se=D(D({},J),{},{editable:d,locale:w,moreIcon:S,moreTransitionName:$,tabBarGutter:m,onTabClick:Ee,onTabScroll:R,extra:b,style:g,panes:null,getPopupContainer:P,popupClassName:N});return f__namespace.createElement(Oc.Provider,{value:{tabs:E,prefixCls:o}},f__namespace.createElement("div",Ce({ref:t,id:n,className:K(o,"".concat(o,"-").concat(p),(r={},H(r,"".concat(o,"-mobile"),L),H(r,"".concat(o,"-editable"),d),H(r,"".concat(o,"-rtl"),O),r),a)},_),oe,f__namespace.createElement(aA,Ce({},se,{renderTabBar:y})),f__namespace.createElement(GI,Ce({destroyInactiveTabPane:x},J,{animated:T}))))}var uA=f__namespace.forwardRef(cA);const dA=()=>null,fA=dA,hA={motionAppear:!1,motionEnter:!0,motionLeave:!0};function vA(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{inkBar:!0,tabPane:!1},r;return t===!1?r={inkBar:!1,tabPane:!1}:t===!0?r={inkBar:!0,tabPane:!0}:r=Object.assign({inkBar:!0},typeof t=="object"?t:{}),r.tabPane&&(r.tabPaneMotion=Object.assign(Object.assign({},hA),{motionName:Xb(e,"switch")})),r}var pA=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 i=0,n=Object.getOwnPropertySymbols(e);it)}function gA(e,t){if(e)return e;const r=di(t).map(n=>{if(f__namespace.isValidElement(n)){const{key:i,props:o}=n,a=o||{},{tab:s}=a,l=pA(a,["tab"]);return Object.assign(Object.assign({key:String(i)},l),{label:s})}return null});return mA(r)}const bA=e=>{const{componentCls:t,motionDurationSlow:r}=e;return [{[t]:{[`${t}-switch`]:{"&-appear, &-enter":{transition:"none","&-start":{opacity:0},"&-active":{opacity:1,transition:`opacity ${r}`}},"&-leave":{position:"absolute",transition:"none",inset:0,"&-start":{opacity:1},"&-active":{opacity:0,transition:`opacity ${r}`}}}}},[cp(e,"slide-up"),cp(e,"slide-down")]]},yA=bA,wA=e=>{const{componentCls:t,tabsCardHorizontalPadding:r,tabsCardHeadBackground:n,tabsCardGutter:i,colorBorderSecondary:o}=e;return {[`${t}-card`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{margin:0,padding:r,background:n,border:`${e.lineWidth}px ${e.lineType} ${o}`,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`},[`${t}-tab-active`]:{color:e.colorPrimary,background:e.colorBgContainer},[`${t}-ink-bar`]:{visibility:"hidden"}},[`&${t}-top, &${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginLeft:{_skip_check_:!0,value:`${i}px`}}}},[`&${t}-top`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`},[`${t}-tab-active`]:{borderBottomColor:e.colorBgContainer}}},[`&${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`0 0 ${e.borderRadiusLG}px ${e.borderRadiusLG}px`},[`${t}-tab-active`]:{borderTopColor:e.colorBgContainer}}},[`&${t}-left, &${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginTop:`${i}px`}}},[`&${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`${e.borderRadiusLG}px 0 0 ${e.borderRadiusLG}px`}},[`${t}-tab-active`]:{borderRightColor:{_skip_check_:!0,value:e.colorBgContainer}}}},[`&${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`0 ${e.borderRadiusLG}px ${e.borderRadiusLG}px 0`}},[`${t}-tab-active`]:{borderLeftColor:{_skip_check_:!0,value:e.colorBgContainer}}}}}}},SA=e=>{const{componentCls:t,tabsHoverColor:r,dropdownEdgeChildVerticalPadding:n}=e;return {[`${t}-dropdown`]:Object.assign(Object.assign({},yr(e)),{position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:e.zIndexPopup,display:"block","&-hidden":{display:"none"},[`${t}-dropdown-menu`]:{maxHeight:e.tabsDropdownHeight,margin:0,padding:`${n}px 0`,overflowX:"hidden",overflowY:"auto",textAlign:{_skip_check_:!0,value:"left"},listStyleType:"none",backgroundColor:e.colorBgContainer,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,"&-item":Object.assign(Object.assign({},YO),{display:"flex",alignItems:"center",minWidth:e.tabsDropdownWidth,margin:0,padding:`${e.paddingXXS}px ${e.paddingSM}px`,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"> span":{flex:1,whiteSpace:"nowrap"},"&-remove":{flex:"none",marginLeft:{_skip_check_:!0,value:e.marginSM},color:e.colorTextDescription,fontSize:e.fontSizeSM,background:"transparent",border:0,cursor:"pointer","&:hover":{color:r}},"&:hover":{background:e.controlItemBgHover},"&-disabled":{"&, &:hover":{color:e.colorTextDisabled,background:"transparent",cursor:"not-allowed"}}})}})}},CA=e=>{const{componentCls:t,margin:r,colorBorderSecondary:n}=e;return {[`${t}-top, ${t}-bottom`]:{flexDirection:"column",[`> ${t}-nav, > div > ${t}-nav`]:{margin:`0 0 ${r}px 0`,"&::before":{position:"absolute",right:{_skip_check_:!0,value:0},left:{_skip_check_:!0,value:0},borderBottom:`${e.lineWidth}px ${e.lineType} ${n}`,content:"''"},[`${t}-ink-bar`]:{height:e.lineWidthBold,"&-animated":{transition:`width ${e.motionDurationSlow}, left ${e.motionDurationSlow}, right ${e.motionDurationSlow}`}},[`${t}-nav-wrap`]:{"&::before, &::after":{top:0,bottom:0,width:e.controlHeight},"&::before":{left:{_skip_check_:!0,value:0},boxShadow:e.boxShadowTabsOverflowLeft},"&::after":{right:{_skip_check_:!0,value:0},boxShadow:e.boxShadowTabsOverflowRight},[`&${t}-nav-wrap-ping-left::before`]:{opacity:1},[`&${t}-nav-wrap-ping-right::after`]:{opacity:1}}}},[`${t}-top`]:{[`> ${t}-nav, > div > ${t}-nav`]:{"&::before":{bottom:0},[`${t}-ink-bar`]:{bottom:0}}},[`${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,marginTop:`${r}px`,marginBottom:0,"&::before":{top:0},[`${t}-ink-bar`]:{top:0}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0}},[`${t}-left, ${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{flexDirection:"column",minWidth:e.controlHeight*1.25,[`${t}-tab`]:{padding:`${e.paddingXS}px ${e.paddingLG}px`,textAlign:"center"},[`${t}-tab + ${t}-tab`]:{margin:`${e.margin}px 0 0 0`},[`${t}-nav-wrap`]:{flexDirection:"column","&::before, &::after":{right:{_skip_check_:!0,value:0},left:{_skip_check_:!0,value:0},height:e.controlHeight},"&::before":{top:0,boxShadow:e.boxShadowTabsOverflowTop},"&::after":{bottom:0,boxShadow:e.boxShadowTabsOverflowBottom},[`&${t}-nav-wrap-ping-top::before`]:{opacity:1},[`&${t}-nav-wrap-ping-bottom::after`]:{opacity:1}},[`${t}-ink-bar`]:{width:e.lineWidthBold,"&-animated":{transition:`height ${e.motionDurationSlow}, top ${e.motionDurationSlow}`}},[`${t}-nav-list, ${t}-nav-operations`]:{flex:"1 0 auto",flexDirection:"column"}}},[`${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-ink-bar`]:{right:{_skip_check_:!0,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{marginLeft:{_skip_check_:!0,value:`-${e.lineWidth}px`},borderLeft:{_skip_check_:!0,value:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingLeft:{_skip_check_:!0,value:e.paddingLG}}}},[`${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,[`${t}-ink-bar`]:{left:{_skip_check_:!0,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0,marginRight:{_skip_check_:!0,value:-e.lineWidth},borderRight:{_skip_check_:!0,value:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingRight:{_skip_check_:!0,value:e.paddingLG}}}}}},xA=e=>{const{componentCls:t,padding:r}=e;return {[t]:{"&-small":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:`${e.paddingXS}px 0`,fontSize:e.fontSize}}},"&-large":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:`${r}px 0`,fontSize:e.fontSizeLG}}}},[`${t}-card`]:{[`&${t}-small`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:`${e.paddingXXS*1.5}px ${r}px`}},[`&${t}-bottom`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`0 0 ${e.borderRadius}px ${e.borderRadius}px`}},[`&${t}-top`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`${e.borderRadius}px ${e.borderRadius}px 0 0`}},[`&${t}-right`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`0 ${e.borderRadius}px ${e.borderRadius}px 0`}}},[`&${t}-left`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:!0,value:`${e.borderRadius}px 0 0 ${e.borderRadius}px`}}}},[`&${t}-large`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:`${e.paddingXS}px ${r}px ${e.paddingXXS*1.5}px`}}}}}},$A=e=>{const{componentCls:t,tabsActiveColor:r,tabsHoverColor:n,iconCls:i,tabsHorizontalGutter:o}=e,a=`${t}-tab`;return {[a]:{position:"relative",display:"inline-flex",alignItems:"center",padding:`${e.paddingSM}px 0`,fontSize:`${e.fontSize}px`,background:"transparent",border:0,outline:"none",cursor:"pointer","&-btn, &-remove":Object.assign({"&:focus:not(:focus-visible), &:active":{color:r}},Lf(e)),"&-btn":{outline:"none",transition:"all 0.3s"},"&-remove":{flex:"none",marginRight:{_skip_check_:!0,value:-e.marginXXS},marginLeft:{_skip_check_:!0,value:e.marginXS},color:e.colorTextDescription,fontSize:e.fontSizeSM,background:"transparent",border:"none",outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"&:hover":{color:e.colorTextHeading}},"&:hover":{color:n},[`&${a}-active ${a}-btn`]:{color:e.colorPrimary,textShadow:e.tabsActiveTextShadow},[`&${a}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${a}-disabled ${a}-btn, &${a}-disabled ${t}-remove`]:{"&:focus, &:active":{color:e.colorTextDisabled}},[`& ${a}-remove ${i}`]:{margin:0},[i]:{marginRight:{_skip_check_:!0,value:e.marginSM}}},[`${a} + ${a}`]:{margin:{_skip_check_:!0,value:`0 0 0 ${o}px`}}}},EA=e=>{const{componentCls:t,tabsHorizontalGutter:r,iconCls:n,tabsCardGutter:i}=e;return {[`${t}-rtl`]:{direction:"rtl",[`${t}-nav`]:{[`${t}-tab`]:{margin:{_skip_check_:!0,value:`0 0 0 ${r}px`},[`${t}-tab:last-of-type`]:{marginLeft:{_skip_check_:!0,value:0}},[n]:{marginRight:{_skip_check_:!0,value:0},marginLeft:{_skip_check_:!0,value:`${e.marginSM}px`}},[`${t}-tab-remove`]:{marginRight:{_skip_check_:!0,value:`${e.marginXS}px`},marginLeft:{_skip_check_:!0,value:`-${e.marginXXS}px`},[n]:{margin:0}}}},[`&${t}-left`]:{[`> ${t}-nav`]:{order:1},[`> ${t}-content-holder`]:{order:0}},[`&${t}-right`]:{[`> ${t}-nav`]:{order:0},[`> ${t}-content-holder`]:{order:1}},[`&${t}-card${t}-top, &${t}-card${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginRight:{_skip_check_:!0,value:`${i}px`},marginLeft:{_skip_check_:!0,value:0}}}}},[`${t}-dropdown-rtl`]:{direction:"rtl"},[`${t}-menu-item`]:{[`${t}-dropdown-rtl`]:{textAlign:{_skip_check_:!0,value:"right"}}}}},_A=e=>{const{componentCls:t,tabsCardHorizontalPadding:r,tabsCardHeight:n,tabsCardGutter:i,tabsHoverColor:o,tabsActiveColor:a,colorBorderSecondary:s}=e;return {[t]:Object.assign(Object.assign(Object.assign(Object.assign({},yr(e)),{display:"flex",[`> ${t}-nav, > div > ${t}-nav`]:{position:"relative",display:"flex",flex:"none",alignItems:"center",[`${t}-nav-wrap`]:{position:"relative",display:"flex",flex:"auto",alignSelf:"stretch",overflow:"hidden",whiteSpace:"nowrap",transform:"translate(0)","&::before, &::after":{position:"absolute",zIndex:1,opacity:0,transition:`opacity ${e.motionDurationSlow}`,content:"''",pointerEvents:"none"}},[`${t}-nav-list`]:{position:"relative",display:"flex",transition:`opacity ${e.motionDurationSlow}`},[`${t}-nav-operations`]:{display:"flex",alignSelf:"stretch"},[`${t}-nav-operations-hidden`]:{position:"absolute",visibility:"hidden",pointerEvents:"none"},[`${t}-nav-more`]:{position:"relative",padding:r,background:"transparent",border:0,color:e.colorText,"&::after":{position:"absolute",right:{_skip_check_:!0,value:0},bottom:0,left:{_skip_check_:!0,value:0},height:e.controlHeightLG/8,transform:"translateY(100%)",content:"''"}},[`${t}-nav-add`]:Object.assign({minWidth:`${n}px`,marginLeft:{_skip_check_:!0,value:`${i}px`},padding:`0 ${e.paddingXS}px`,background:"transparent",border:`${e.lineWidth}px ${e.lineType} ${s}`,borderRadius:`${e.borderRadiusLG}px ${e.borderRadiusLG}px 0 0`,outline:"none",cursor:"pointer",color:e.colorText,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`,"&:hover":{color:o},"&:active, &:focus:not(:focus-visible)":{color:a}},Lf(e))},[`${t}-extra-content`]:{flex:"none"},[`${t}-ink-bar`]:{position:"absolute",background:e.colorPrimary,pointerEvents:"none"}}),$A(e)),{[`${t}-content`]:{position:"relative",width:"100%"},[`${t}-content-holder`]:{flex:"auto",minWidth:0,minHeight:0},[`${t}-tabpane`]:{outline:"none","&-hidden":{display:"none"}}}),[`${t}-centered`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-nav-wrap`]:{[`&:not([class*='${t}-nav-wrap-ping'])`]:{justifyContent:"center"}}}}}},PA=Tn("Tabs",e=>{const t=e.controlHeightLG,r=mr(e,{tabsHoverColor:e.colorPrimaryHover,tabsActiveColor:e.colorPrimaryActive,tabsCardHorizontalPadding:`${(t-Math.round(e.fontSize*e.lineHeight))/2-e.lineWidth}px ${e.padding}px`,tabsCardHeight:t,tabsCardGutter:e.marginXXS/2,tabsHorizontalGutter:32,tabsCardHeadBackground:e.colorFillAlter,dropdownEdgeChildVerticalPadding:e.paddingXXS,tabsActiveTextShadow:"0 0 0.25px currentcolor",tabsDropdownHeight:200,tabsDropdownWidth:120});return [xA(r),EA(r),CA(r),SA(r),wA(r),_A(r),yA(r)]},e=>({zIndexPopup:e.zIndexPopupBase+50}));var OA=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 i=0,n=Object.getOwnPropertySymbols(e);i{let{key:E,event:O}=_;o==null||o(N==="add"?O:E,N);},removeIcon:f__namespace.createElement(Fb,null),addIcon:l||f__namespace.createElement(VI,null),showAdd:a!==!0});const C=b(),M=gA(d,u),R=vA(S,h),P=Do(i);return $(f__namespace.createElement(uA,Object.assign({direction:g,getPopupContainer:w,moreTransitionName:`${C}-slide-up`},v,{items:M,className:K({[`${S}-${P}`]:P,[`${S}-card`]:["card","editable-card"].includes(t),[`${S}-editable-card`]:t==="editable-card",[`${S}-centered`]:s},r,n,x),popupClassName:K(c,x),editable:y,moreIcon:m,prefixCls:S,animated:R})))}ty.TabPane=fA;const TA=new Dt("antCheckboxEffect",{"0%":{transform:"scale(1)",opacity:.5},"100%":{transform:"scale(1.6)",opacity:0}}),MA=e=>{const{checkboxCls:t}=e,r=`${t}-wrapper`;return [{[`${t}-group`]:Object.assign(Object.assign({},yr(e)),{display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}}),[r]:Object.assign(Object.assign({},yr(e)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${r}`]:{marginInlineStart:0},[`&${r}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[t]:Object.assign(Object.assign({},yr(e)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"start",transform:`translate(0, ${e.lineHeight*e.fontSize/2-e.checkboxSize/2}px)`,[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${t}-inner`]:Object.assign({},pc(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:TA,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 RA(e,t){const r=mr(t,{checkboxCls:`.${e}`,checkboxSize:t.controlInteractiveSize});return [MA(r)]}const ry=Tn("Checkbox",(e,t)=>{let{prefixCls:r}=t;return [RA(r,e)]});var NA=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 i=0,n=Object.getOwnPropertySymbols(e);i{var{defaultValue:r,children:n,options:i=[],prefixCls:o,className:a,rootClassName:s,style:l,onChange:c}=e,u=NA(e,["defaultValue","children","options","prefixCls","className","rootClassName","style","onChange"]);const{getPrefixCls:d,direction:h}=f__namespace.useContext(Wt),[v,p]=f__namespace.useState(u.value||r||[]),[m,g]=f__namespace.useState([]);f__namespace.useEffect(()=>{"value"in u&&p(u.value||[]);},[u.value]);const b=()=>i.map(_=>typeof _=="string"||typeof _=="number"?{label:_,value:_}:_),w=_=>{g(E=>E.filter(O=>O!==_));},S=_=>{g(E=>[].concat(le(E),[_]));},$=_=>{const E=v.indexOf(_.value),O=le(v);E===-1?O.push(_.value):O.splice(E,1),"value"in u||p(O);const T=b();c==null||c(O.filter(A=>m.includes(A)).sort((A,I)=>{const L=T.findIndex(B=>B.value===A),j=T.findIndex(B=>B.value===I);return L-j}));},x=d("checkbox",o),y=`${x}-group`,[C,M]=ry(x),R=uc(u,["value","disabled"]);i&&i.length>0&&(n=b().map(_=>f__namespace.createElement(iy,{prefixCls:x,key:_.value.toString(),disabled:"disabled"in _?_.disabled:u.disabled,value:_.value,checked:v.includes(_.value),onChange:_.onChange,className:`${y}-item`,style:_.style},_.label)));const P={toggleOption:$,value:v,disabled:u.disabled,name:u.name,registerValue:S,cancelValue:w},N=K(y,{[`${y}-rtl`]:h==="rtl"},a,s,M);return C(f__namespace.createElement("div",Object.assign({className:N,style:l},R,{ref:t}),f__namespace.createElement(ny.Provider,{value:P},n)))},AA=f__namespace.forwardRef(IA),kA=f__namespace.memo(AA);var LA=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 i=0,n=Object.getOwnPropertySymbols(e);i{var r,{prefixCls:n,className:i,rootClassName:o,children:a,indeterminate:s=!1,style:l,onMouseEnter:c,onMouseLeave:u,skipGroup:d=!1,disabled:h}=e,v=LA(e,["prefixCls","className","rootClassName","children","indeterminate","style","onMouseEnter","onMouseLeave","skipGroup","disabled"]);const{getPrefixCls:p,direction:m}=f__namespace.useContext(Wt),g=f__namespace.useContext(ny),{isFormItemInput:b}=f__namespace.useContext(za),w=f__namespace.useContext(as),S=(r=(g==null?void 0:g.disabled)||h)!==null&&r!==void 0?r:w,$=f__namespace.useRef(v.value);f__namespace.useEffect(()=>{g==null||g.registerValue(v.value);},[]),f__namespace.useEffect(()=>{if(!d)return v.value!==$.current&&(g==null||g.cancelValue($.current),g==null||g.registerValue(v.value),$.current=v.value),()=>g==null?void 0:g.cancelValue(v.value)},[v.value]);const x=p("checkbox",n),[y,C]=ry(x),M=Object.assign({},v);g&&!d&&(M.onChange=function(){v.onChange&&v.onChange.apply(v,arguments),g.toggleOption&&g.toggleOption({label:a,value:v.value});},M.name=g.name,M.checked=g.value.includes(v.value));const R=K({[`${x}-wrapper`]:!0,[`${x}-rtl`]:m==="rtl",[`${x}-wrapper-checked`]:M.checked,[`${x}-wrapper-disabled`]:S,[`${x}-wrapper-in-form-item`]:b},i,o,C),P=K({[`${x}-indeterminate`]:s},C),N=s?"mixed":void 0;return y(f__namespace.createElement("label",{className:R,style:l,onMouseEnter:c,onMouseLeave:u},f__namespace.createElement(W0,Object.assign({"aria-checked":N},M,{prefixCls:x,className:P,disabled:S,ref:t})),a!==void 0&&f__namespace.createElement("span",null,a)))},DA=f__namespace.forwardRef(FA),iy=DA,nh=iy;nh.Group=kA;nh.__ANT_CHECKBOX=!0;const jA=nh;var zA={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z"}}]},name:"up",theme:"outlined"};const HA=zA;var oy=function(t,r){return f__namespace.createElement(zo,D(D({},t),{},{ref:r,icon:HA}))};oy.displayName="UpOutlined";const WA=f__namespace.forwardRef(oy);function Wd(){return typeof BigInt=="function"}function Ri(e){var t=e.trim(),r=t.startsWith("-");r&&(t=t.slice(1)),t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),t.startsWith(".")&&(t="0".concat(t));var n=t||"0",i=n.split("."),o=i[0]||"0",a=i[1]||"0";o==="0"&&a==="0"&&(r=!1);var s=r?"-":"";return {negative:r,negativeStr:s,trimStr:n,integerStr:o,decimalStr:a,fullStr:"".concat(s).concat(n)}}function ih(e){var t=String(e);return !Number.isNaN(Number(t))&&t.includes("e")}function Va(e){var t=String(e);if(ih(e)){var r=Number(t.slice(t.indexOf("e-")+2)),n=t.match(/\.(\d+)/);return n!=null&&n[1]&&(r+=n[1].length),r}return t.includes(".")&&oh(t)?t.length-t.indexOf(".")-1:0}function Tc(e){var t=String(e);if(ih(e)){if(e>Number.MAX_SAFE_INTEGER)return String(Wd()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(eNumber.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(i0&&arguments[0]!==void 0?arguments[0]:!0;return r?this.isInvalidate()?"":Tc(this.number):this.origin}}]),e}(),VA=function(){function e(t){if($r(this,e),H(this,"origin",""),H(this,"negative",void 0),H(this,"integer",void 0),H(this,"decimal",void 0),H(this,"decimalLen",void 0),H(this,"empty",void 0),H(this,"nan",void 0),ay(t)){this.empty=!0;return}if(this.origin=String(t),t==="-"||Number.isNaN(t)){this.nan=!0;return}var r=t;if(ih(r)&&(r=Number(r)),r=typeof r=="string"?r:Tc(r),oh(r)){var n=Ri(r);this.negative=n.negative;var i=n.trimStr.split(".");this.integer=BigInt(i[0]);var o=i[1]||"0";this.decimal=BigInt(o),this.decimalLen=o.length;}else this.nan=!0;}return Er(e,[{key:"getMark",value:function(){return this.negative?"-":""}},{key:"getIntegerStr",value:function(){return this.integer.toString()}},{key:"getDecimalStr",value:function(){return this.decimal.toString().padStart(this.decimalLen,"0")}},{key:"alignDecimal",value:function(r){var n="".concat(this.getMark()).concat(this.getIntegerStr()).concat(this.getDecimalStr().padEnd(r,"0"));return BigInt(n)}},{key:"negate",value:function(){var r=new e(this.toString());return r.negative=!r.negative,r}},{key:"add",value:function(r){if(this.isInvalidate())return new e(r);var n=new e(r);if(n.isInvalidate())return this;var i=Math.max(this.getDecimalStr().length,n.getDecimalStr().length),o=this.alignDecimal(i),a=n.alignDecimal(i),s=(o+a).toString(),l=Ri(s),c=l.negativeStr,u=l.trimStr,d="".concat(c).concat(u.padStart(i+1,"0"));return new e("".concat(d.slice(0,-i),".").concat(d.slice(-i)))}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return this.nan}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(r){return this.toString()===(r==null?void 0:r.toString())}},{key:"lessEquals",value:function(r){return this.add(r.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return r?this.isInvalidate()?"":Ri("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e}();function Yr(e){return Wd()?new VA(e):new BA(e)}function Qs(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(e==="")return "";var i=Ri(e),o=i.negativeStr,a=i.integerStr,s=i.decimalStr,l="".concat(t).concat(s),c="".concat(o).concat(a);if(r>=0){var u=Number(s[r]);if(u>=5&&!n){var d=Yr(e).add("".concat(o,"0.").concat("0".repeat(r)).concat(10-u));return Qs(d.toString(),t,r,n)}return r===0?c:"".concat(c).concat(t).concat(s.padEnd(r,"0").slice(0,r))}return l===".0"?c:"".concat(c).concat(l)}var UA=function(){var t=f.useState(!1),r=W(t,2),n=r[0],i=r[1];return Gt(function(){i(Cc());},[]),n},GA=200,KA=600;function qA(e){var t=e.prefixCls,r=e.upNode,n=e.downNode,i=e.upDisabled,o=e.downDisabled,a=e.onStep,s=f__namespace.useRef(),l=f__namespace.useRef();l.current=a;var c=function(b,w){b.preventDefault(),l.current(w);function S(){l.current(w),s.current=setTimeout(S,GA);}s.current=setTimeout(S,KA);},u=function(){clearTimeout(s.current);};f__namespace.useEffect(function(){return u},[]);var d=UA();if(d)return null;var h="".concat(t,"-handler"),v=K(h,"".concat(h,"-up"),H({},"".concat(h,"-up-disabled"),i)),p=K(h,"".concat(h,"-down"),H({},"".concat(h,"-down-disabled"),o)),m={unselectable:"on",role:"button",onMouseUp:u,onMouseLeave:u};return f__namespace.createElement("div",{className:"".concat(h,"-wrap")},f__namespace.createElement("span",Ce({},m,{onMouseDown:function(b){c(b,!0);},"aria-label":"Increase Value","aria-disabled":i,className:v}),r||f__namespace.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-up-inner")})),f__namespace.createElement("span",Ce({},m,{onMouseDown:function(b){c(b,!1);},"aria-label":"Decrease Value","aria-disabled":o,className:p}),n||f__namespace.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-down-inner")})))}function Jp(e){var t=typeof e=="number"?Tc(e):Ri(e).fullStr,r=t.includes(".");return r?Ri(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}function XA(e,t){var r=f.useRef(null);function n(){try{var o=e.selectionStart,a=e.selectionEnd,s=e.value,l=s.substring(0,o),c=s.substring(a);r.current={start:o,end:a,value:s,beforeTxt:l,afterTxt:c};}catch{}}function i(){if(e&&r.current&&t)try{var o=e.value,a=r.current,s=a.beforeTxt,l=a.afterTxt,c=a.start,u=o.length;if(o.endsWith(l))u=o.length-r.current.afterTxt.length;else if(o.startsWith(s))u=s.length;else {var d=s[c-1],h=o.indexOf(d,c-1);h!==-1&&(u=h+1);}e.setSelectionRange(u,u);}catch(v){dr(!1,"Something warning of cursor restore. Please fire issue about this: ".concat(v.message));}}return [n,i]}const YA=function(){var e=f.useRef(0),t=function(){It.cancel(e.current);};return f.useEffect(function(){return t},[]),function(r){t(),e.current=It(function(){r();});}};var ZA=["prefixCls","className","style","min","max","step","defaultValue","value","disabled","readOnly","upHandler","downHandler","keyboard","controls","stringMode","parser","formatter","precision","decimalSeparator","onChange","onInput","onPressEnter","onStep"],em=function(t,r){return t||r.isEmpty()?r.toString():r.toNumber()},tm=function(t){var r=Yr(t);return r.isInvalidate()?null:r},sy=f__namespace.forwardRef(function(e,t){var r,n=e.prefixCls,i=n===void 0?"rc-input-number":n,o=e.className,a=e.style,s=e.min,l=e.max,c=e.step,u=c===void 0?1:c,d=e.defaultValue,h=e.value,v=e.disabled,p=e.readOnly,m=e.upHandler,g=e.downHandler,b=e.keyboard,w=e.controls,S=w===void 0?!0:w,$=e.stringMode,x=e.parser,y=e.formatter,C=e.precision,M=e.decimalSeparator,R=e.onChange,P=e.onInput,N=e.onPressEnter,_=e.onStep,E=Xe(e,ZA),O="".concat(i,"-input"),T=f__namespace.useRef(null),A=f__namespace.useState(!1),I=W(A,2),L=I[0],j=I[1],B=f__namespace.useRef(!1),G=f__namespace.useRef(!1),z=f__namespace.useRef(!1),V=f__namespace.useState(function(){return Yr(h??d)}),q=W(V,2),U=q[0],Q=q[1];function ie(fe){h===void 0&&Q(fe);}var Z=f__namespace.useCallback(function(fe,ce){if(!ce)return C>=0?C:Math.max(Va(fe),Va(u))},[C,u]),te=f__namespace.useCallback(function(fe){var ce=String(fe);if(x)return x(ce);var _e=ce;return M&&(_e=_e.replace(M,".")),_e.replace(/[^\w.-]+/g,"")},[x,M]),ae=f__namespace.useRef(""),ue=f__namespace.useCallback(function(fe,ce){if(y)return y(fe,{userTyping:ce,input:String(ae.current)});var _e=typeof fe=="number"?Tc(fe):fe;if(!ce){var we=Z(_e,ce);if(oh(_e)&&(M||we>=0)){var Ve=M||".";_e=Qs(_e,Ve,we);}}return _e},[y,Z,M]),Ee=f__namespace.useState(function(){var fe=d??h;return U.isInvalidate()&&["string","number"].includes(ot(fe))?Number.isNaN(fe)?"":fe:ue(U.toString(),!1)}),J=W(Ee,2),oe=J[0],se=J[1];ae.current=oe;function re(fe,ce){se(ue(fe.isInvalidate()?fe.toString(!1):fe.toString(!ce),ce));}var xe=f__namespace.useMemo(function(){return tm(l)},[l,C]),de=f__namespace.useMemo(function(){return tm(s)},[s,C]),ge=f__namespace.useMemo(function(){return !xe||!U||U.isInvalidate()?!1:xe.lessEquals(U)},[xe,U]),ve=f__namespace.useMemo(function(){return !de||!U||U.isInvalidate()?!1:U.lessEquals(de)},[de,U]),$e=XA(T.current,L),Ye=W($e,2),dt=Ye[0],xt=Ye[1],tt=function(ce){return xe&&!ce.lessEquals(xe)?xe:de&&!de.lessEquals(ce)?de:null},ke=function(ce){return !tt(ce)},Fe=function(ce,_e){var we=ce,Ve=ke(we)||we.isEmpty();if(!we.isEmpty()&&!_e&&(we=tt(we)||we,Ve=!0),!p&&!v&&Ve){var $t=we.toString(),At=Z($t,_e);return At>=0&&(we=Yr(Qs($t,".",At)),ke(we)||(we=Yr(Qs($t,".",At,!0)))),we.equals(U)||(ie(we),R==null||R(we.isEmpty()?null:em($,we)),h===void 0&&re(we,_e)),we}return U},Oe=YA(),De=function fe(ce){if(dt(),se(ce),!G.current){var _e=te(ce),we=Yr(_e);we.isNaN()||Fe(we,!0);}P==null||P(ce),Oe(function(){var Ve=ce;x||(Ve=ce.replace(/。/g,".")),Ve!==ce&&fe(Ve);});},Te=function(){G.current=!0;},He=function(){G.current=!1,De(T.current.value);},rt=function(ce){De(ce.target.value);},ft=function(ce){var _e;if(!(ce&&ge||!ce&&ve)){B.current=!1;var we=Yr(z.current?Jp(u):u);ce||(we=we.negate());var Ve=(U||Yr(0)).add(we.toString()),$t=Fe(Ve,!1);_==null||_(em($,$t),{offset:z.current?Jp(u):u,type:ce?"up":"down"}),(_e=T.current)===null||_e===void 0||_e.focus();}},Ke=function(ce){var _e=Yr(te(oe)),we=_e;_e.isNaN()?we=U:we=Fe(_e,ce),h!==void 0?re(U,!1):we.isNaN()||re(we,!1);},Ze=function(){B.current=!0;},at=function(ce){var _e=ce.which,we=ce.shiftKey;B.current=!0,we?z.current=!0:z.current=!1,_e===Y.ENTER&&(G.current||(B.current=!1),Ke(!1),N==null||N(ce)),b!==!1&&!G.current&&[Y.UP,Y.DOWN].includes(_e)&&(ft(Y.UP===_e),ce.preventDefault());},st=function(){B.current=!1,z.current=!1;},wt=function(){Ke(!1),j(!1),B.current=!1;};return po(function(){U.isInvalidate()||re(U,!1);},[C]),po(function(){var fe=Yr(h);Q(fe);var ce=Yr(te(oe));(!fe.equals(ce)||!B.current||y)&&re(fe,B.current);},[h]),po(function(){y&&xt();},[oe]),f__namespace.createElement("div",{className:K(i,o,(r={},H(r,"".concat(i,"-focused"),L),H(r,"".concat(i,"-disabled"),v),H(r,"".concat(i,"-readonly"),p),H(r,"".concat(i,"-not-a-number"),U.isNaN()),H(r,"".concat(i,"-out-of-range"),!U.isInvalidate()&&!ke(U)),r)),style:a,onFocus:function(){j(!0);},onBlur:wt,onKeyDown:at,onKeyUp:st,onCompositionStart:Te,onCompositionEnd:He,onBeforeInput:Ze},S&&f__namespace.createElement(qA,{prefixCls:i,upNode:m,downNode:g,upDisabled:ge,downDisabled:ve,onStep:ft}),f__namespace.createElement("div",{className:"".concat(O,"-wrap")},f__namespace.createElement("input",Ce({autoComplete:"off",role:"spinbutton","aria-valuemin":s,"aria-valuemax":l,"aria-valuenow":U.isInvalidate()?null:U.toString(),step:u},E,{ref:Kr(T,t),className:O,value:oe,onChange:rt,disabled:v,readOnly:p}))))});sy.displayName="InputNumber";const QA=e=>{const{componentCls:t,lineWidth:r,lineType:n,colorBorder:i,borderRadius:o,fontSizeLG:a,controlHeightLG:s,controlHeightSM:l,colorError:c,inputPaddingHorizontalSM:u,colorTextDescription:d,motionDurationMid:h,colorPrimary:v,controlHeight:p,inputPaddingHorizontal:m,colorBgContainer:g,colorTextDisabled:b,borderRadiusSM:w,borderRadiusLG:S,controlWidth:$,handleVisible:x}=e;return [{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},yr(e)),X0(e)),q0(e,t)),{display:"inline-block",width:$,margin:0,padding:0,border:`${r}px ${n} ${i}`,borderRadius:o,"&-rtl":{direction:"rtl",[`${t}-input`]:{direction:"rtl"}},"&-lg":{padding:0,fontSize:a,borderRadius:S,[`input${t}-input`]:{height:s-2*r}},"&-sm":{padding:0,borderRadius:w,[`input${t}-input`]:{height:l-2*r,padding:`0 ${u}px`}},"&:hover":Object.assign({},Pc(e)),"&-focused":Object.assign({},Ml(e)),"&-disabled":Object.assign(Object.assign({},U0(e)),{[`${t}-input`]:{cursor:"not-allowed"}}),"&-out-of-range":{[`${t}-input-wrap`]:{input:{color:c}}},"&-group":Object.assign(Object.assign(Object.assign({},yr(e)),zI(e)),{"&-wrapper":{display:"inline-block",textAlign:"start",verticalAlign:"top",[`${t}-affix-wrapper`]:{width:"100%"},"&-lg":{[`${t}-group-addon`]:{borderRadius:S}},"&-sm":{[`${t}-group-addon`]:{borderRadius:w}}}}),[t]:{"&-input":Object.assign(Object.assign(Object.assign(Object.assign({},yr(e)),{width:"100%",height:p-2*r,padding:`0 ${m}px`,textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:o,outline:0,transition:`all ${h} linear`,appearance:"textfield",fontSize:"inherit",verticalAlign:"top"}),V0(e.colorTextPlaceholder)),{'&[type="number"]::-webkit-inner-spin-button, &[type="number"]::-webkit-outer-spin-button':{margin:0,webkitAppearance:"none",appearance:"none"}})}})},{[t]:{[`&:hover ${t}-handler-wrap, &-focused ${t}-handler-wrap`]:{opacity:1},[`${t}-handler-wrap`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleWidth,height:"100%",background:g,borderStartStartRadius:0,borderStartEndRadius:o,borderEndEndRadius:o,borderEndStartRadius:0,opacity:x===!0?1:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`opacity ${h} linear ${h}`,[`${t}-handler`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",[` ${t}-handler-up-inner, ${t}-handler-down-inner `]:{marginInlineEnd:0,fontSize:e.handleFontSize}}},[`${t}-handler`]:{height:"50%",overflow:"hidden",color:d,fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",borderInlineStart:`${r}px ${n} ${i}`,transition:`all ${h} linear`,"&:active":{background:e.colorFillAlter},"&:hover":{height:"60%",[` ${t}-handler-up-inner, ${t}-handler-down-inner `]:{color:v}},"&-up-inner, &-down-inner":Object.assign(Object.assign({},hb()),{color:d,transition:`all ${h} linear`,userSelect:"none"})},[`${t}-handler-up`]:{borderStartEndRadius:o},[`${t}-handler-down`]:{borderBlockStart:`${r}px ${n} ${i}`,borderEndEndRadius:o},"&-disabled, &-readonly":{[`${t}-handler-wrap`]:{display:"none"},[`${t}-input`]:{color:"inherit"}},[` ${t}-handler-up-disabled, ${t}-handler-down-disabled `]:{cursor:"not-allowed"},[` ${t}-handler-up-disabled:hover &-handler-up-inner, ${t}-handler-down-disabled:hover &-handler-down-inner `]:{color:b}}},{[`${t}-borderless`]:{borderColor:"transparent",boxShadow:"none",[`${t}-handler-down`]:{borderBlockStartWidth:0}}}]},JA=e=>{const{componentCls:t,inputPaddingHorizontal:r,inputAffixPadding:n,controlWidth:i,borderRadiusLG:o,borderRadiusSM:a}=e;return {[`${t}-affix-wrapper`]:Object.assign(Object.assign(Object.assign({},X0(e)),q0(e,`${t}-affix-wrapper`)),{position:"relative",display:"inline-flex",width:i,padding:0,paddingInlineStart:r,"&-lg":{borderRadius:o},"&-sm":{borderRadius:a},[`&:not(${t}-affix-wrapper-disabled):hover`]:Object.assign(Object.assign({},Pc(e)),{zIndex:1}),"&-focused, &:focus":{zIndex:1},"&-disabled":{[`${t}[disabled]`]:{background:"transparent"}},[`> div${t}`]:{width:"100%",border:"none",outline:"none",[`&${t}-focused`]:{boxShadow:"none !important"}},[`input${t}-input`]:{padding:0},"&::before":{width:0,visibility:"hidden",content:'"\\a0"'},[`${t}-handler-wrap`]:{zIndex:2},[t]:{"&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center",pointerEvents:"none"},"&-prefix":{marginInlineEnd:n},"&-suffix":{position:"absolute",insetBlockStart:0,insetInlineEnd:0,zIndex:1,height:"100%",marginInlineEnd:r,marginInlineStart:n}}})}},ek=Tn("InputNumber",e=>{const t=HI(e);return [QA(t),JA(t),Gb(t)]},e=>({controlWidth:90,handleWidth:e.controlHeightSM-e.lineWidth*2,handleFontSize:e.fontSize/2,handleVisible:"auto"}));var tk=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{getPrefixCls:r,direction:n}=f__namespace.useContext(Wt),[i,o]=f__namespace.useState(!1),a=f__namespace.useRef(null);f__namespace.useImperativeHandle(t,()=>a.current);const{className:s,rootClassName:l,size:c,disabled:u,prefixCls:d,addonBefore:h,addonAfter:v,prefix:p,bordered:m=!0,readOnly:g,status:b,controls:w}=e,S=tk(e,["className","rootClassName","size","disabled","prefixCls","addonBefore","addonAfter","prefix","bordered","readOnly","status","controls"]),$=r("input-number",d),[x,y]=ek($),{compactSize:C,compactItemClassnames:M}=Bb($,n);let R=f__namespace.createElement(WA,{className:`${$}-handler-up-inner`}),P=f__namespace.createElement(lN,{className:`${$}-handler-down-inner`});const N=typeof w=="boolean"?w:void 0;typeof w=="object"&&(R=typeof w.upIcon>"u"?R:f__namespace.createElement("span",{className:`${$}-handler-up-inner`},w.upIcon),P=typeof w.downIcon>"u"?P:f__namespace.createElement("span",{className:`${$}-handler-down-inner`},w.downIcon));const{hasFeedback:_,status:E,isFormItemInput:O,feedbackIcon:T}=f__namespace.useContext(za),A=oN(E,b),I=Do(q=>{var U;return (U=C??c)!==null&&U!==void 0?U:q}),L=p!=null||_,j=!!(h||v),B=f__namespace.useContext(as),G=u??B,z=K({[`${$}-lg`]:I==="large",[`${$}-sm`]:I==="small",[`${$}-rtl`]:n==="rtl",[`${$}-borderless`]:!m,[`${$}-in-form-item`]:O},gu($,A),M,y,s,!L&&!j&&l);let V=f__namespace.createElement(sy,Object.assign({ref:a,disabled:G,className:z,upHandler:R,downHandler:P,prefixCls:$,readOnly:g,controls:N},S));if(L){const q=K(`${$}-affix-wrapper`,gu(`${$}-affix-wrapper`,A,_),{[`${$}-affix-wrapper-focused`]:i,[`${$}-affix-wrapper-disabled`]:e.disabled,[`${$}-affix-wrapper-sm`]:I==="small",[`${$}-affix-wrapper-lg`]:I==="large",[`${$}-affix-wrapper-rtl`]:n==="rtl",[`${$}-affix-wrapper-readonly`]:g,[`${$}-affix-wrapper-borderless`]:!m},!j&&s,!j&&l,y);V=f__namespace.createElement("div",{className:q,style:e.style,onMouseUp:()=>a.current.focus()},p&&f__namespace.createElement("span",{className:`${$}-prefix`},p),Ro(V,{style:null,value:e.value,onFocus:U=>{var Q;o(!0),(Q=e.onFocus)===null||Q===void 0||Q.call(e,U);},onBlur:U=>{var Q;o(!1),(Q=e.onBlur)===null||Q===void 0||Q.call(e,U);}}),_&&f__namespace.createElement("span",{className:`${$}-suffix`},T));}if(j){const q=`${$}-group`,U=`${q}-addon`,Q=h?f__namespace.createElement("div",{className:U},h):null,ie=v?f__namespace.createElement("div",{className:U},v):null,Z=K(`${$}-wrapper`,q,y,{[`${q}-rtl`]:n==="rtl"}),te=K(`${$}-group-wrapper`,{[`${$}-group-wrapper-sm`]:I==="small",[`${$}-group-wrapper-lg`]:I==="large",[`${$}-group-wrapper-rtl`]:n==="rtl"},gu(`${$}-group-wrapper`,A,_),y,s,l);V=f__namespace.createElement("div",{className:te,style:e.style},f__namespace.createElement("div",{className:Z},Q&&f__namespace.createElement(Od,null,f__namespace.createElement(lp,{status:!0,override:!0},Q)),Ro(V,{style:null,disabled:G}),ie&&f__namespace.createElement(Od,null,f__namespace.createElement(lp,{status:!0,override:!0},ie))));}return x(V)}),cy=ly,rk=e=>f__namespace.createElement(Nb,{theme:{components:{InputNumber:{handleVisible:!0}}}},f__namespace.createElement(ly,Object.assign({},e)));cy._InternalPanelDoNotUseOrYouWillBeFired=rk;const rm=cy;var Di=f__namespace.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0});function Bd(e,t,r){return (e-t)/(r-t)}function ah(e,t,r,n){var i=Bd(t,r,n),o={};switch(e){case"rtl":o.right="".concat(i*100,"%"),o.transform="translateX(50%)";break;case"btt":o.bottom="".concat(i*100,"%"),o.transform="translateY(50%)";break;case"ttb":o.top="".concat(i*100,"%"),o.transform="translateY(-50%)";break;default:o.left="".concat(i*100,"%"),o.transform="translateX(-50%)";break}return o}function uo(e,t){return Array.isArray(e)?e[t]:e}var nk=["prefixCls","value","valueIndex","onStartMove","style","render","dragging","onOffsetChange"],ik=f__namespace.forwardRef(function(e,t){var r,n,i=e.prefixCls,o=e.value,a=e.valueIndex,s=e.onStartMove,l=e.style,c=e.render,u=e.dragging,d=e.onOffsetChange,h=Xe(e,nk),v=f__namespace.useContext(Di),p=v.min,m=v.max,g=v.direction,b=v.disabled,w=v.keyboard,S=v.range,$=v.tabIndex,x=v.ariaLabelForHandle,y=v.ariaLabelledByForHandle,C=v.ariaValueTextFormatterForHandle,M="".concat(i,"-handle"),R=function(O){b||s(O,a);},P=function(O){if(!b&&w){var T=null;switch(O.which||O.keyCode){case Y.LEFT:T=g==="ltr"||g==="btt"?-1:1;break;case Y.RIGHT:T=g==="ltr"||g==="btt"?1:-1;break;case Y.UP:T=g!=="ttb"?1:-1;break;case Y.DOWN:T=g!=="ttb"?-1:1;break;case Y.HOME:T="min";break;case Y.END:T="max";break;case Y.PAGE_UP:T=2;break;case Y.PAGE_DOWN:T=-2;break}T!==null&&(O.preventDefault(),d(T,a));}},N=ah(g,o,p,m),_=f__namespace.createElement("div",Ce({ref:t,className:K(M,(r={},H(r,"".concat(M,"-").concat(a+1),S),H(r,"".concat(M,"-dragging"),u),r)),style:D(D({},N),l),onMouseDown:R,onTouchStart:R,onKeyDown:P,tabIndex:b?null:uo($,a),role:"slider","aria-valuemin":p,"aria-valuemax":m,"aria-valuenow":o,"aria-disabled":b,"aria-label":uo(x,a),"aria-labelledby":uo(y,a),"aria-valuetext":(n=uo(C,a))===null||n===void 0?void 0:n(o)},h));return c&&(_=c(_,{index:a,prefixCls:i,value:o,dragging:u})),_}),ok=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","draggingIndex"],ak=f__namespace.forwardRef(function(e,t){var r=e.prefixCls,n=e.style,i=e.onStartMove,o=e.onOffsetChange,a=e.values,s=e.handleRender,l=e.draggingIndex,c=Xe(e,ok),u=f__namespace.useRef({});return f__namespace.useImperativeHandle(t,function(){return {focus:function(h){var v;(v=u.current[h])===null||v===void 0||v.focus();}}}),f__namespace.createElement(f__namespace.Fragment,null,a.map(function(d,h){return f__namespace.createElement(ik,Ce({ref:function(p){p?u.current[h]=p:delete u.current[h];},dragging:l===h,prefixCls:r,style:uo(n,h),key:h,value:d,valueIndex:h,onStartMove:i,onOffsetChange:o,render:s},c))}))});function nm(e){var t="touches"in e?e.touches[0]:e;return {pageX:t.pageX,pageY:t.pageY}}function sk(e,t,r,n,i,o,a,s,l){var c=f__namespace.useState(null),u=W(c,2),d=u[0],h=u[1],v=f__namespace.useState(-1),p=W(v,2),m=p[0],g=p[1],b=f__namespace.useState(r),w=W(b,2),S=w[0],$=w[1],x=f__namespace.useState(r),y=W(x,2),C=y[0],M=y[1],R=f__namespace.useRef(null),P=f__namespace.useRef(null);f__namespace.useEffect(function(){m===-1&&$(r);},[r,m]),f__namespace.useEffect(function(){return function(){document.removeEventListener("mousemove",R.current),document.removeEventListener("mouseup",P.current),document.removeEventListener("touchmove",R.current),document.removeEventListener("touchend",P.current);}},[]);var N=function(I,L){S.some(function(j,B){return j!==I[B]})&&(L!==void 0&&h(L),$(I),a(I));},_=function(I,L){if(I===-1){var j=C[0],B=C[C.length-1],G=n-j,z=i-B,V=L*(i-n);V=Math.max(V,G),V=Math.min(V,z);var q=o(j+V);V=q-j;var U=C.map(function(te){return te+V});N(U);}else {var Q=(i-n)*L,ie=le(S);ie[I]=C[I];var Z=l(ie,Q,I,"dist");N(Z.values,Z.value);}},E=f__namespace.useRef(_);E.current=_;var O=function(I,L){I.stopPropagation();var j=r[L];g(L),h(j),M(r);var B=nm(I),G=B.pageX,z=B.pageY,V=function(Q){Q.preventDefault();var ie=nm(Q),Z=ie.pageX,te=ie.pageY,ae=Z-G,ue=te-z,Ee=e.current.getBoundingClientRect(),J=Ee.width,oe=Ee.height,se;switch(t){case"btt":se=-ue/oe;break;case"ttb":se=ue/oe;break;case"rtl":se=-ae/J;break;default:se=ae/J;}E.current(L,se);},q=function U(Q){Q.preventDefault(),document.removeEventListener("mouseup",U),document.removeEventListener("mousemove",V),document.removeEventListener("touchend",U),document.removeEventListener("touchmove",V),R.current=null,P.current=null,g(-1),s();};document.addEventListener("mouseup",q),document.addEventListener("mousemove",V),document.addEventListener("touchend",q),document.addEventListener("touchmove",V),R.current=V,P.current=q;},T=f__namespace.useMemo(function(){var A=le(r).sort(function(L,j){return L-j}),I=le(S).sort(function(L,j){return L-j});return A.every(function(L,j){return L===I[j]})?S:r},[r,S]);return [m,d,T,O]}function lk(e){var t=e.prefixCls,r=e.style,n=e.start,i=e.end,o=e.index,a=e.onStartMove,s=f__namespace.useContext(Di),l=s.direction,c=s.min,u=s.max,d=s.disabled,h=s.range,v="".concat(t,"-track"),p=Bd(n,c,u),m=Bd(i,c,u),g=function(S){!d&&a&&a(S,-1);},b={};switch(l){case"rtl":b.right="".concat(p*100,"%"),b.width="".concat(m*100-p*100,"%");break;case"btt":b.bottom="".concat(p*100,"%"),b.height="".concat(m*100-p*100,"%");break;case"ttb":b.top="".concat(p*100,"%"),b.height="".concat(m*100-p*100,"%");break;default:b.left="".concat(p*100,"%"),b.width="".concat(m*100-p*100,"%");}return f__namespace.createElement("div",{className:K(v,h&&"".concat(v,"-").concat(o+1)),style:D(D({},b),r),onMouseDown:g,onTouchStart:g})}function ck(e){var t=e.prefixCls,r=e.style,n=e.values,i=e.startPoint,o=e.onStartMove,a=f__namespace.useContext(Di),s=a.included,l=a.range,c=a.min,u=f__namespace.useMemo(function(){if(!l){if(n.length===0)return [];var d=i??c,h=n[0];return [{start:Math.min(d,h),end:Math.max(d,h)}]}for(var v=[],p=0;p3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof m=="number"){var w,S=p[g],$=S+m,x=[];n.forEach(function(P){x.push(P.value);}),x.push(e,t),x.push(s(S));var y=m>0?1:-1;b==="unit"?x.push(s(S+y*r)):x.push(s($)),x=x.filter(function(P){return P!==null}).filter(function(P){return m<0?P<=S:P>=S}),b==="unit"&&(x=x.filter(function(P){return P!==S}));var C=b==="unit"?S:$;w=x[0];var M=Math.abs(w-C);if(x.forEach(function(P){var N=Math.abs(P-C);N1){var R=le(p);return R[g]=w,v(R,m-y,g,b)}return w}else {if(m==="min")return e;if(m==="max")return t}},u=function(p,m,g){var b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",w=p[g],S=c(p,m,g,b);return {value:S,changed:S!==w}},d=function(p){return o===null&&p===0||typeof o=="number"&&p3&&arguments[3]!==void 0?arguments[3]:"unit",w=p.map(l),S=w[g],$=c(w,m,g,b);if(w[g]=$,i===!1){var x=o||0;g>0&&w[g-1]!==S&&(w[g]=Math.max(w[g],w[g-1]+x)),g0;R-=1)for(var P=!0;d(w[R]-w[R-1])&&P;){var N=u(w,-1,R-1);w[R-1]=N.value,P=N.changed;}for(var _=w.length-1;_>0;_-=1)for(var E=!0;d(w[_]-w[_-1])&&E;){var O=u(w,-1,_-1);w[_-1]=O.value,E=O.changed;}for(var T=0;T=0?O:!1},[O,ge]),$e=f__namespace.useMemo(function(){var Ge=Object.keys(Q||{});return Ge.map(function(Ie){var pe=Q[Ie],ht={value:Number(Ie)};return pe&&ot(pe)==="object"&&!f__namespace.isValidElement(pe)&&("label"in pe||"style"in pe)?(ht.style=pe.style,ht.label=pe.label):ht.label=pe,ht}).filter(function(Ie){var pe=Ie.label;return pe||typeof pe=="number"}).sort(function(Ie,pe){return Ie.value-pe.value})},[Q]),Ye=vk(xe,de,ge,$e,_,ve),dt=W(Ye,2),xt=dt[0],tt=dt[1],ke=Cn(x,{value:$}),Fe=W(ke,2),Oe=Fe[0],De=Fe[1],Te=f__namespace.useMemo(function(){var Ge=Oe==null?[]:Array.isArray(Oe)?Oe:[Oe],Ie=W(Ge,1),pe=Ie[0],ht=pe===void 0?xe:pe,nt=Oe===null?[]:[ht];if(y){if(nt=le(Ge),C||Oe===void 0){var ar=C>=0?C+1:2;for(nt=nt.slice(0,ar);nt.length=0&&oe.current.focus(Ge);}fe(null);},[wt]);var _e=f__namespace.useMemo(function(){return T&&ge===null?!1:T},[T,ge]),we=function(){P==null||P(rt(He.current));},Ve=sk(se,re,Te,xe,de,xt,ft,we,tt),$t=W(Ve,4),At=$t[0],kt=$t[1],be=$t[2],We=$t[3],Ue=function(Ie,pe){We(Ie,pe),R==null||R(rt(He.current));},Et=At!==-1;f__namespace.useEffect(function(){if(!Et){var Ge=Te.lastIndexOf(kt);oe.current.focus(Ge);}},[Et]);var _t=f__namespace.useMemo(function(){return le(be).sort(function(Ge,Ie){return Ge-Ie})},[be]),gr=f__namespace.useMemo(function(){return y?[_t[0],_t[_t.length-1]]:[xe,_t[0]]},[_t,y,xe]),fr=W(gr,2),Lt=fr[0],zr=fr[1];f__namespace.useImperativeHandle(t,function(){return {focus:function(){oe.current.focus(0);},blur:function(){var Ie=document,pe=Ie.activeElement;se.current.contains(pe)&&(pe==null||pe.blur());}}}),f__namespace.useEffect(function(){d&&oe.current.focus(0);},[]);var tr=f__namespace.useMemo(function(){return {min:xe,max:de,direction:re,disabled:l,keyboard:u,step:ge,included:j,includedStart:Lt,includedEnd:zr,range:y,tabIndex:ae,ariaLabelForHandle:ue,ariaLabelledByForHandle:Ee,ariaValueTextFormatterForHandle:J}},[xe,de,re,l,u,ge,j,Lt,zr,y,ae,ue,Ee,J]);return f__namespace.createElement(Di.Provider,{value:tr},f__namespace.createElement("div",{ref:se,className:K(i,o,(r={},H(r,"".concat(i,"-disabled"),l),H(r,"".concat(i,"-vertical"),I),H(r,"".concat(i,"-horizontal"),!I),H(r,"".concat(i,"-with-marks"),$e.length),r)),style:a,onMouseDown:Ze},f__namespace.createElement("div",{className:"".concat(i,"-rail"),style:V}),f__namespace.createElement(ck,{prefixCls:i,style:G,values:_t,startPoint:B,onStartMove:_e?Ue:null}),f__namespace.createElement(hk,{prefixCls:i,marks:$e,dots:ie,style:q,activeStyle:U}),f__namespace.createElement(ak,{ref:oe,prefixCls:i,style:z,values:be,draggingIndex:At,onStartMove:Ue,onOffsetChange:ce,onFocus:h,onBlur:v,handleRender:Z}),f__namespace.createElement(dk,{prefixCls:i,marks:$e,onClick:Ke})))});const mk=f__namespace.forwardRef((e,t)=>{const{open:r}=e,n=f.useRef(null),i=f.useRef(null);function o(){It.cancel(i.current),i.current=null;}function a(){i.current=It(()=>{var s;(s=n.current)===null||s===void 0||s.forceAlign(),i.current=null;});}return f__namespace.useEffect(()=>(r?a():o(),o),[r,e.title]),f__namespace.createElement(Vf,Object.assign({ref:Kr(n,t)},e))}),gk=mk,bk=e=>{const{componentCls:t,controlSize:r,dotSize:n,marginFull:i,marginPart:o,colorFillContentHover:a}=e;return {[t]:Object.assign(Object.assign({},yr(e)),{position:"relative",height:r,margin:`${o}px ${i}px`,padding:0,cursor:"pointer",touchAction:"none",["&-vertical"]:{margin:`${i}px ${o}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 ur(e.colorTextDisabled).onBackground(e.colorBgContainer).toHexShortString()}`,insetInlineStart:0,insetBlockStart:0},[` ${t}-mark-text, ${t}-dot `]:{cursor:"not-allowed !important"}}})}},uy=(e,t)=>{const{componentCls:r,railSize:n,handleSize:i,dotSize:o}=e,a=t?"paddingBlock":"paddingInline",s=t?"width":"height",l=t?"height":"width",c=t?"insetBlockStart":"insetInlineStart",u=t?"top":"insetInlineStart";return {[a]:n,[l]:n*3,[`${r}-rail`]:{[s]:"100%",[l]:n},[`${r}-track`]:{[l]:n},[`${r}-handle`]:{[c]:(n*3-i)/2},[`${r}-mark`]:{insetInlineStart:0,top:0,[u]:i,[s]:"100%"},[`${r}-step`]:{insetInlineStart:0,top:0,[u]:n,[s]:"100%",[l]:n},[`${r}-dot`]:{position:"absolute",[c]:(n-o)/2}}},yk=e=>{const{componentCls:t,marginPartWithMark:r}=e;return {[`${t}-horizontal`]:Object.assign(Object.assign({},uy(e,!0)),{[`&${t}-with-marks`]:{marginBottom:r}})}},wk=e=>{const{componentCls:t}=e;return {[`${t}-vertical`]:Object.assign(Object.assign({},uy(e,!1)),{height:"100%"})}},Sk=Tn("Slider",e=>{const t=mr(e,{marginPart:(e.controlHeight-e.controlSize)/2,marginFull:e.controlSize/2,marginPartWithMark:e.controlHeightLG-e.controlSize});return [bk(t),yk(t),wk(t)]},e=>{const r=e.controlHeightLG/4,n=e.controlHeightSM/2,i=e.lineWidth+1,o=e.lineWidth+1*3;return {controlSize:r,railSize:4,handleSize:r,handleSizeHover:n,dotSize:8,handleLineWidth:i,handleLineWidthHover:o}});var Ck=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 i=0,n=Object.getOwnPropertySymbols(e);itypeof e=="number"?e.toString():"",$k=f__namespace.forwardRef((e,t)=>{const{prefixCls:r,range:n,className:i,rootClassName:o,tooltipPrefixCls:a,tipFormatter:s,tooltipVisible:l,getTooltipPopupContainer:c,tooltipPlacement:u}=e,d=Ck(e,["prefixCls","range","className","rootClassName","tooltipPrefixCls","tipFormatter","tooltipVisible","getTooltipPopupContainer","tooltipPlacement"]),{getPrefixCls:h,direction:v,getPopupContainer:p}=f__namespace.useContext(Wt),[m,g]=f__namespace.useState({}),b=(P,N)=>{g(_=>Object.assign(Object.assign({},_),{[P]:N}));},w=(P,N)=>P||(N?v==="rtl"?"left":"right":"top"),S=h("slider",r),[$,x]=Sk(S),y=K(i,o,{[`${S}-rtl`]:v==="rtl"},x);v==="rtl"&&!d.vertical&&(d.reverse=!d.reverse);const[C,M]=f__namespace.useMemo(()=>n?typeof n=="object"?[!0,n.draggableTrack]:[!0,!1]:[!1],[n]),R=(P,N)=>{var _;const{index:E,dragging:O}=N,{tooltip:T={},vertical:A}=e,I=Object.assign({},T),{open:L,placement:j,getPopupContainer:B,prefixCls:G,formatter:z}=I;let V;z||z===null?V=z:s||s===null?V=s:V=xk;const q=V?m[E]||O:!1,U=(_=L??l)!==null&&_!==void 0?_:L===void 0&&q,Q=Object.assign(Object.assign({},P.props),{onMouseEnter:()=>b(E,!0),onMouseLeave:()=>b(E,!1)}),ie=h("tooltip",G??a);return f__namespace.createElement(gk,{prefixCls:ie,title:V?V(N.value):"",open:U,placement:w(j??u,A),key:E,overlayClassName:`${S}-tooltip`,getPopupContainer:B||c||p},f__namespace.cloneElement(P,Q))};return $(f__namespace.createElement(pk,Object.assign({},d,{step:d.step,range:C,draggableTrack:M,className:y,ref:t,prefixCls:S,handleRender:R})))}),Ek=$k;function _k(e){return typeof e!="string"?e:e.charAt(0).toUpperCase()+e.slice(1)}const Hs=(e,t,r)=>{const n=_k(r);return {[`${e.componentCls}-${t}`]:{color:e[`color${r}`],background:e[`color${n}Bg`],borderColor:e[`color${n}Border`]}}},Pk=e=>pb(e,(t,r)=>{let{textColor:n,lightBorderColor:i,lightColor:o,darkColor:a}=r;return {[`${e.componentCls}-${t}`]:{color:n,background:o,borderColor:i,"&-inverse":{color:e.colorTextLightSolid,background:a,borderColor:a},[`&${e.componentCls}-borderless`]:{borderColor:"transparent"}}}}),Ok=e=>{const{paddingXXS:t,lineWidth:r,tagPaddingHorizontal:n,componentCls:i}=e,o=n-r,a=t-r;return {[i]:Object.assign(Object.assign({},yr(e)),{display:"inline-block",height:"auto",marginInlineEnd:e.marginXS,paddingInline:o,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",[`&${i}-rtl`]:{direction:"rtl"},"&, a, a:hover":{color:e.tagDefaultColor},[`${i}-close-icon`]:{marginInlineStart:a,color:e.colorTextDescription,fontSize:e.tagIconSize,cursor:"pointer",transition:`all ${e.motionDurationMid}`,"&:hover":{color:e.colorTextHeading}},[`&${i}-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(${i}-checkable-checked):hover`]:{color:e.colorPrimary,backgroundColor:e.colorFillSecondary},"&:active, &-checked":{color:e.colorTextLightSolid},"&-checked":{backgroundColor:e.colorPrimary,"&:hover":{backgroundColor:e.colorPrimaryHover}},"&:active":{backgroundColor:e.colorPrimaryActive}},["&-hidden"]:{display:"none"},[`> ${e.iconCls} + span, > span + ${e.iconCls}`]:{marginInlineStart:o}}),[`${i}-borderless`]:{borderColor:"transparent",background:e.tagBorderlessBg}}},dy=Tn("Tag",e=>{const{fontSize:t,lineHeight:r,lineWidth:n,fontSizeIcon:i}=e,o=Math.round(t*r),a=e.fontSizeSM,s=o-n*2,l=e.colorFillQuaternary,c=e.colorText,u=mr(e,{tagFontSize:a,tagLineHeight:s,tagDefaultBg:l,tagDefaultColor:c,tagIconSize:i-2*n,tagPaddingHorizontal:8,tagBorderlessBg:e.colorFillTertiary});return [Ok(u),Pk(u),Hs(u,"success","Success"),Hs(u,"processing","Info"),Hs(u,"error","Error"),Hs(u,"warning","Warning")]});var Tk=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{prefixCls:t,className:r,checked:n,onChange:i,onClick:o}=e,a=Tk(e,["prefixCls","className","checked","onChange","onClick"]),{getPrefixCls:s}=f__namespace.useContext(Wt),l=v=>{i==null||i(!n),o==null||o(v);},c=s("tag",t),[u,d]=dy(c),h=K(c,{[`${c}-checkable`]:!0,[`${c}-checkable-checked`]:n},r,d);return u(f__namespace.createElement("span",Object.assign({},a,{className:h,onClick:l})))},Rk=Mk;var Nk=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 i=0,n=Object.getOwnPropertySymbols(e);i{const{prefixCls:r,className:n,rootClassName:i,style:o,children:a,icon:s,color:l,onClose:c,closeIcon:u,closable:d=!1,bordered:h=!0}=e,v=Nk(e,["prefixCls","className","rootClassName","style","children","icon","color","onClose","closeIcon","closable","bordered"]),{getPrefixCls:p,direction:m}=f__namespace.useContext(Wt),[g,b]=f__namespace.useState(!0);f__namespace.useEffect(()=>{"visible"in v&&b(v.visible);},[v.visible]);const w=l0(l)||TN(l),S=Object.assign({backgroundColor:l&&!w?l:void 0},o),$=p("tag",r),[x,y]=dy($),C=K($,{[`${$}-${l}`]:w,[`${$}-has-color`]:l&&!w,[`${$}-hidden`]:!g,[`${$}-rtl`]:m==="rtl",[`${$}-borderless`]:!h},n,i,y),M=O=>{O.stopPropagation(),c==null||c(O),!O.defaultPrevented&&b(!1);},R=f__namespace.useMemo(()=>d?u?f__namespace.createElement("span",{className:`${$}-close-icon`,onClick:M},u):f__namespace.createElement(Fb,{className:`${$}-close-icon`,onClick:M}):null,[d,u,$,M]),P=typeof v.onClick=="function"||a&&a.type==="a",N=s||null,_=N?f__namespace.createElement(f__namespace.Fragment,null,N,f__namespace.createElement("span",null,a)):a,E=f__namespace.createElement("span",Object.assign({},v,{ref:t,className:C,style:S}),_,R);return x(P?f__namespace.createElement(zb,null,E):E)},fy=f__namespace.forwardRef(Ik);fy.CheckableTag=Rk;const oa=fy;function Ur(){for(var e=arguments.length,t=new Array(e),r=0;re.id===(et.theme||Ua.id))||Ua}function Ho(){const e=_n().theme||Ua.id;return f.useMemo(()=>sh.find(t=>t.id===e)||Ua,[e])}var Lk={name:"lj8i4f",styles:"width:50px;height:50px;padding:3px;border:2px solid transparent;border-radius:5px;margin:0 auto"},Fk={name:"yf99n4",styles:"min-width:70px;text-align:center;margin:0 15px 15px 0;cursor:pointer"};function Dk(){const e=Ho().id;return F("div",{style:{display:"flex",flexWrap:"wrap"},children:sh.map(t=>{const r=e===t.id;return ee("div",{css:Fk,onClick:n=>{Fa({theme:t.id});},children:[F("div",{className:"preview-wrapper",css:[Lk,r&&Ur("border-color:",t.colorPrimary,";",""),"",""],children:F("div",{className:"preview",css:Ur("width:100%;height:100%;background-color:",t.colorPrimary,";border-radius:5px;","")})}),t.name]},t.id)})})}function hy({children:e}){const t=ac(),{colorPrimary:r}=Ho();return F(Nb,{theme:{algorithm:t?Nd.darkAlgorithm:Nd.defaultAlgorithm,token:{colorPrimary:r}},children:e})}function im(e){return F(Vf,{...e,zIndex:11100,overlayStyle:{width:"max-content",maxWidth:"50vw",...e.overlayInnerStyle},children:e.children})}var lh={exports:{}};const jk=(e,t)=>Math.floor(Math.random()*(t-e+1)+e),om=()=>{const e=new Error("Delay aborted");return e.name="AbortError",e},am=({clearTimeout:e,setTimeout:t,willResolve:r})=>(n,{value:i,signal:o}={})=>{if(o&&o.aborted)return Promise.reject(om());let a,s,l;const c=e||clearTimeout,u=()=>{c(a),l(om());},d=()=>{o&&o.removeEventListener("abort",u);},h=new Promise((v,p)=>{s=()=>{d(),r?v(i):p(i);},l=p,a=(t||setTimeout)(s,n);});return o&&o.addEventListener("abort",u,{once:!0}),h.clear=()=>{c(a),a=null,s();},h},vy=e=>{const t=am({...e,willResolve:!0});return t.reject=am({...e,willResolve:!1}),t.range=(r,n,i)=>t(jk(r,n),i),t},ch=vy();ch.createWithTimers=vy;lh.exports=ch;lh.exports.default=ch;var zk=lh.exports;const Mc=Kn(zk),Hk=10*1e3,Wk=200;async function py(e,t,r=()=>!0){let n=[];const i=()=>{n=Array.from(document.querySelectorAll(e)).filter(r);};i();const a=performance.now()+Hk;for(;!n.length&&performance.now()n.remove(),t)}function Rc(){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 Nc,sm=$o;Nc=sm.createRoot,sm.hydrateRoot;var uh={},_r={};Object.defineProperty(_r,"__esModule",{value:!0});_r.DEFAULT_ICON_CONFIGS=void 0;_r.IconConverter=by;_r.IconProvider=void 0;_r.IconWrapper=Yk;var el=Bk(f);function my(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,r=new WeakMap;return (my=function(n){return n?r:t})(e)}function Bk(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return {default:e};var r=my(t);if(r&&r.has(e))return r.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(o!=="default"&&Object.prototype.hasOwnProperty.call(e,o)){var a=i?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(n,o,a):n[o]=e[o];}return n.default=e,r&&r.set(e,n),n}var Vk=["size","strokeWidth","strokeLinecap","strokeLinejoin","theme","fill","className","spin"];function lm(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n);}return r}function cm(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n]);}return r}function Kk(e,t){if(e==null)return {};var r={},n=Object.keys(e),i,o;for(o=0;o=0)&&(r[i]=e[i]);return r}var gy={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"};_r.DEFAULT_ICON_CONFIGS=gy;function qk(){return "icon-"+((1+Math.random())*4294967296|0).toString(16).substring(1)}function by(e,t,r){var n=typeof t.fill=="string"?[t.fill]:t.fill||[],i=[],o=t.theme||r.theme;switch(o){case"outline":i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push("none"),i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push("none");break;case"filled":i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push("#FFF"),i.push("#FFF");break;case"two-tone":i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push(typeof n[1]=="string"?n[1]:r.colors.twoTone.twoTone),i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push(typeof n[1]=="string"?n[1]:r.colors.twoTone.twoTone);break;case"multi-color":i.push(typeof n[0]=="string"?n[0]:"currentColor"),i.push(typeof n[1]=="string"?n[1]:r.colors.multiColor.outFillColor),i.push(typeof n[2]=="string"?n[2]:r.colors.multiColor.innerStrokeColor),i.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:i,id:e}}var yy=(0, el.createContext)(gy),Xk=yy.Provider;_r.IconProvider=Xk;function Yk(e,t,r){return function(n){var i=n.size,o=n.strokeWidth,a=n.strokeLinecap,s=n.strokeLinejoin,l=n.theme,c=n.fill,u=n.className,d=n.spin,h=Gk(n,Vk),v=(0, el.useContext)(yy),p=(0, el.useMemo)(qk,[]),m=by(p,{size:i,strokeWidth:o,strokeLinecap:a,strokeLinejoin:s,theme:l,fill:c},v),g=[v.prefix+"-icon"];return g.push(v.prefix+"-icon-"+e),t&&v.rtl&&g.push(v.prefix+"-icon-rtl"),d&&g.push(v.prefix+"-icon-spin"),u&&g.push(u),el.default.createElement("span",cm(cm({},h),{},{className:g.join(" ")}),r(m))}}Object.defineProperty(uh,"__esModule",{value:!0});var wy=uh.default=void 0,$u=Qk(f),Zk=_r;function Qk(e){return e&&e.__esModule?e:{default:e}}var Jk=(0, Zk.IconWrapper)("close",!1,function(e){return $u.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},$u.default.createElement("path",{d:"M8 8L40 40",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),$u.default.createElement("path",{d:"M8 40L40 8",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});wy=uh.default=Jk;var dh={};Object.defineProperty(dh,"__esModule",{value:!0});var Sy=dh.default=void 0,Eu=tL(f),eL=_r;function tL(e){return e&&e.__esModule?e:{default:e}}var rL=(0, eL.IconWrapper)("config",!1,function(e){return Eu.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},Eu.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}),Eu.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}))});Sy=dh.default=rL;var fh={};Object.defineProperty(fh,"__esModule",{value:!0});var Cy=fh.default=void 0,aa=iL(f),nL=_r;function iL(e){return e&&e.__esModule?e:{default:e}}var oL=(0, nL.IconWrapper)("distraught-face",!1,function(e){return aa.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},aa.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}),aa.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}),aa.default.createElement("path",{d:"M32 17L29 20L32 23",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),aa.default.createElement("path",{d:"M16 17L19 20L16 23",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});Cy=fh.default=oL;var hh={};Object.defineProperty(hh,"__esModule",{value:!0});var xy=hh.default=void 0,sa=sL(f),aL=_r;function sL(e){return e&&e.__esModule?e:{default:e}}var lL=(0, aL.IconWrapper)("info",!0,function(e){return sa.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},sa.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}),sa.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]}),sa.default.createElement("path",{d:"M24.5 34V20H23.5H22.5",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),sa.default.createElement("path",{d:"M21 34H28",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});xy=hh.default=lL;var vh={};Object.defineProperty(vh,"__esModule",{value:!0});var $y=vh.default=void 0,_u=uL(f),cL=_r;function uL(e){return e&&e.__esModule?e:{default:e}}var dL=(0, cL.IconWrapper)("loading",!0,function(e){return _u.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},_u.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}),_u.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}))});$y=vh.default=dL;var ph={};Object.defineProperty(ph,"__esModule",{value:!0});var Ey=ph.default=void 0,un=hL(f),fL=_r;function hL(e){return e&&e.__esModule?e:{default:e}}var vL=(0, fL.IconWrapper)("loading-three",!1,function(e){return un.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},un.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}),un.default.createElement("path",{d:"M24 12V15",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M32.4852 15.5147L30.3639 17.636",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M36 24H33",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M32.4852 32.4853L30.3639 30.364",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M24 36V33",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M15.5148 32.4853L17.6361 30.364",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M12 24H15",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),un.default.createElement("path",{d:"M15.5148 15.5147L17.6361 17.636",stroke:e.colors[2],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}))});Ey=ph.default=vL;var mh={};Object.defineProperty(mh,"__esModule",{value:!0});var _y=mh.default=void 0,Pu=mL(f),pL=_r;function mL(e){return e&&e.__esModule?e:{default:e}}var gL=(0, pL.IconWrapper)("return",!0,function(e){return Pu.default.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 48 48",fill:"none"},Pu.default.createElement("path",{d:"M12.9998 8L6 14L12.9998 21",stroke:e.colors[0],strokeWidth:e.strokeWidth,strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin}),Pu.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}))});_y=mh.default=gL;const bL={Close:wy,Config:Sy,DistraughtFace:Cy,Return:_y,Loading:$y,LoadingThree:Ey,Info:xy};function Bn({name:e,theme:t,size:r,fill:n,...i}){t||(t="outline"),r||(r=24);const o=ac();n||(n=o?"#fff":"#333");const a=bL[e];return F(a,{theme:t,size:r,fill:n,...i,style:{fontSize:0,...i.style}})}function um(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function dm(e,t,r){var n=[],i=pf(e,n,r);return n.length<2?r:i+t(n)}var yL=function(t){var r=Dm(t);r.sheet.speedy=function(s){this.isSpeedy=s;},r.compat=!0;var n=function(){for(var l=arguments.length,c=new Array(l),u=0;u0&&o[o.length-1])&&(c[0]===6||c[0]===2)){r=0;continue}if(c[0]===3&&(!o||c[1]>o[0]&&c[1]=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ft(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var n=r.call(e),i,o=[],a;try{for(;(t===void 0||t-- >0)&&!(i=n.next()).done;)o.push(i.value);}catch(s){a={error:s};}finally{try{i&&!i.done&&(r=n.return)&&r.call(n);}finally{if(a)throw a.error}}return o}function cr(e,t,r){if(r||arguments.length===2)for(var n=0,i=t.length,o;n-1&&(i=setTimeout(function(){tl.delete(e);},t)),tl.set(e,on(on({},r),{timer:i}));},TL=function(e){return tl.get(e)},rl=new Map,ML=function(e){return rl.get(e)},RL=function(e,t){rl.set(e,t),t.then(function(r){return rl.delete(e),r}).catch(function(){rl.delete(e);});},Si={},NL=function(e,t){Si[e]&&Si[e].forEach(function(r){return r(t)});},Ou=function(e,t){return Si[e]||(Si[e]=[]),Si[e].push(t),function(){var n=Si[e].indexOf(t);Si[e].splice(n,1);}},IL=function(e,t){var r=t.cacheKey,n=t.cacheTime,i=n===void 0?5*60*1e3:n,o=t.staleTime,a=o===void 0?0:o,s=t.setCache,l=t.getCache,c=f.useRef(),u=f.useRef(),d=function(v,p){s?s(p):OL(v,i,p),NL(v,p.data);},h=function(v,p){return p===void 0&&(p=[]),l?l(p):TL(v)};return Ry(function(){if(r){var v=h(r);v&&Object.hasOwnProperty.call(v,"data")&&(e.state.data=v.data,e.state.params=v.params,(a===-1||new Date().getTime()-v.time<=a)&&(e.state.loading=!1)),c.current=Ou(r,function(p){e.setState({data:p});});}},[]),fs(function(){var v;(v=c.current)===null||v===void 0||v.call(c);}),r?{onBefore:function(v){var p=h(r,v);return !p||!Object.hasOwnProperty.call(p,"data")?{}:a===-1||new Date().getTime()-p.time<=a?{loading:!1,data:p==null?void 0:p.data,error:void 0,returnNow:!0}:{data:p==null?void 0:p.data,error:void 0}},onRequest:function(v,p){var m=ML(r);return m&&m!==u.current?{servicePromise:m}:(m=v.apply(void 0,cr([],Ft(p),!1)),u.current=m,RL(r,m),{servicePromise:m})},onSuccess:function(v,p){var m;r&&((m=c.current)===null||m===void 0||m.call(c),d(r,{data:v,params:p,time:new Date().getTime()}),c.current=Ou(r,function(g){e.setState({data:g});}));},onMutate:function(v){var p;r&&((p=c.current)===null||p===void 0||p.call(c),d(r,{data:v,params:e.state.params,time:new Date().getTime()}),c.current=Ou(r,function(m){e.setState({data:m});}));}}:{}};const AL=IL;var kL=function(e,t){var r=t.debounceWait,n=t.debounceLeading,i=t.debounceTrailing,o=t.debounceMaxWait,a=f.useRef(),s=f.useMemo(function(){var l={};return n!==void 0&&(l.leading=n),i!==void 0&&(l.trailing=i),o!==void 0&&(l.maxWait=o),l},[n,i,o]);return f.useEffect(function(){if(r){var l=e.runAsync.bind(e);return a.current=hg(function(c){c();},r,s),e.runAsync=function(){for(var c=[],u=0;u-1&&_a.splice(r,1);}}if(hs){var hm=function(){if(!(!gh()||!UL()))for(var e=0;e<_a.length;e++){var t=_a[e];t();}};window.addEventListener("visibilitychange",hm,!1),window.addEventListener("focus",hm,!1);}var KL=function(e,t){var r=t.refreshOnWindowFocus,n=t.focusTimespan,i=n===void 0?5e3:n,o=f.useRef(),a=function(){var s;(s=o.current)===null||s===void 0||s.call(o);};return f.useEffect(function(){if(r){var s=VL(e.refresh.bind(e),i);o.current=GL(function(){s();});}return function(){a();}},[r,i]),fs(function(){a();}),{}};const qL=KL;var XL=function(e,t){var r=t.retryInterval,n=t.retryCount,i=f.useRef(),o=f.useRef(0),a=f.useRef(!1);return n?{onBefore:function(){a.current||(o.current=0),a.current=!1,i.current&&clearTimeout(i.current);},onSuccess:function(){o.current=0;},onError:function(){if(o.current+=1,n===-1||o.current<=n){var s=r??Math.min(1e3*Math.pow(2,o.current),3e4);i.current=setTimeout(function(){a.current=!0,e.refresh();},s);}else o.current=0;},onCancel:function(){o.current=0,i.current&&clearTimeout(i.current);}}:{}};const YL=XL;var ZL=function(e,t){var r=t.throttleWait,n=t.throttleLeading,i=t.throttleTrailing,o=f.useRef(),a={};return n!==void 0&&(a.leading=n),i!==void 0&&(a.trailing=i),f.useEffect(function(){if(r){var s=e.runAsync.bind(e);return o.current=xE(function(l){l();},r,a),e.runAsync=function(){for(var l=[],c=0;c{ha++,document.body.style.overflow="hidden";},TF=()=>{ha--,ha<0&&(ha=0),ha===0&&(document.body.style.overflow="");};function yh({show:e,onHide:t,children:r,styleModalMask:n,clsModalMask:i,styleModal:o,clsModal:a,width:s,hideWhenMaskOnClick:l=!1,hideWhenEsc:c=!1}){f.useLayoutEffect(()=>{e?OF():TF();},[e]);const u=f.useRef(null),d=ac(),{bg:h,c:v}=f.useMemo(()=>{const w=window.getComputedStyle(document.body)["background-color"],S=window.getComputedStyle(document.body).color;return {bg:w,c:S}},[d]),p=f.useMemo(()=>d?{"--bg":h,"--c":v,backgroundColor:h,color:v}:{},[h,v,d]),m=f.useId(),g=f.useMemo(()=>{const w=document.createElement("div");return w.setAttribute("data-id","base-modal-"+m),document.body.appendChild(w),w},[]),b=mt(w=>{var S;(S=u.current)!=null&&S.contains(w.target)||w.target.closest('.ant-tooltip-inner[role="tooltip"]')||l&&t();});return Xt("esc",w=>{e&&c&&(w.preventDefault(),w.stopImmediatePropagation(),setTimeout(t));}),e?$o.createPortal(F("div",{className:K(sn.modalMask,i),style:n,onClick:b,children:F("div",{className:K(sn.modal,a),style:{...p,width:s,...o},ref:u,children:r})}),g):null}const wh=e=>F(Bn,{...e,name:"Close",size:18,style:{cursor:"pointer",marginLeft:10,...e.style}}),MF="_toast-container_1jzhe_1",RF="_single-line_1jzhe_17";function Cr(e,t=2e3){const r=document.createElement("div");r.className=MF,r.innerText=e;const{colorPrimary:n}=kk();r.style.backgroundColor=n,!e.includes(` `)&&!e.includes("r.remove(),t);}const NF="请求失败, 请重试 !!!",IF="操作失败, 请重试 !!!";function Fy(){return Cr(NF)}function Dy(){return Cr(IF)}function AF(e){const t=ts({data:Array.from(e||[]),has(r){return this.data.some(n=>n[0]===r)},set(r,n){const i=this.data.find(o=>o[0]===r);return i?i[1]=n:this.data.push([r,n]),this},get(r){var n;return (n=this.data.find(i=>i[0]===r))==null?void 0:n[1]},delete(r){const n=this.data.findIndex(i=>i[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 jy="27eb53fc9058f8c3";async function kF(){var c,u;const t=(await sf.get("https://passport.bilibili.com/login/app/third",{params:{appkey:jy,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(!((u=t==null?void 0:t.data)!=null&&u.confirm_uri))return {errmsg:"无法获得授权网址",json:t};const r=t.data.confirm_uri;let n,i;const o=new Promise(d=>{const h=v=>{if(v.origin!="https://www.mcbbs.net"||!v.data)return;const p=v.data.match(/access_key=([0-9a-z]{32})/);if(!p||!p[1])return d({errmsg:"没有获得匹配的密钥"});d(p[1]);};window.addEventListener("message",h),i=()=>window.removeEventListener("message",h),n=setTimeout(()=>{d({errmsg:"获取授权超时"});},10*1e3);}),a=document.createElement("iframe");a.src=r,a.style.display="none",document.body.appendChild(a);function s(){a==null||a.remove(),i==null||i(),i=void 0,n&&(clearTimeout(n),n=void 0);}const l=await o;return s(),l}async function LF(){const e=await kF();if(typeof e=="object"&&"errmsg"in e){Cr(e.errmsg);return}const t=e;return et.accessKey=t,Cr("获取成功"),t}function FF(){et.accessKey="",Cr("已删除 access_key");}const zy="https://api.bilibili.com",Hy="https://app.bilibili.com",kc=sf.create({baseURL:zy});kc.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 Lc=sf.create({adapter:G1});Lc.interceptors.request.use(function(e){return e.params={appkey:jy,access_key:et.accessKey||"",...e.params},e},function(e){return Promise.reject(e)});Lc.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 DF(){var t;const e=(t=document.cookie.match(/bili_jct=([0-9a-fA-F]{32})/))==null?void 0:t[1];if(!e)throw Cr("找不到 csrf token, 请检查是否登录"),new Error("找不到 csrf token, 请检查是否登录");return e}const la=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,Wy=new Set,Kd=typeof process=="object"&&process?process:{},By=(e,t,r,n)=>{typeof Kd.emitWarning=="function"?Kd.emitWarning(e,t,r,n):console.error(`[${r}] ${t}: ${e}`);};let Nl=globalThis.AbortController,pm=globalThis.AbortSignal;var $m;if(typeof Nl>"u"){pm=class{constructor(){Pt(this,"onabort");Pt(this,"_onabort",[]);Pt(this,"reason");Pt(this,"aborted",!1);}addEventListener(n,i){this._onabort.push(i);}},Nl=class{constructor(){Pt(this,"signal",new pm);t();}abort(n){var i,o;if(!this.signal.aborted){this.signal.reason=n,this.signal.aborted=!0;for(const a of this.signal._onabort)a(n);(o=(i=this.signal).onabort)==null||o.call(i,n);}}};let e=(($m=Kd.env)==null?void 0:$m.LRU_CACHE_IGNORE_AC_WARNING)!=="1";const t=()=>{e&&(e=!1,By("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",t));};}const jF=e=>!Wy.has(e),ti=e=>e&&e===Math.floor(e)&&e>0&&isFinite(e),Vy=e=>ti(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?il:null:null;class il extends Array{constructor(t){super(t),this.fill(0);}}var yo;const fo=class{constructor(t,r){Pt(this,"heap");Pt(this,"length");if(!k(fo,yo))throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new r(t),this.length=0;}static create(t){const r=Vy(t);if(!r)return [];Se(fo,yo,!0);const n=new fo(t,r);return Se(fo,yo,!1),n}push(t){this.heap[this.length++]=t;}pop(){return this.heap[--this.length]}};let ol=fo;yo=new WeakMap,je(ol,yo,!1);var Zr,Ir,hn,Qr,wo,Kt,Jr,qt,Ot,Ae,vr,Ar,lr,Jt,en,rr,An,kn,tn,vn,oi,br,qa,Xd,_i,Ln,Xa,kr,Ll,Uy,Pi,So,Ya,pn,ri,mn,ni,Za,Yd,Co,al,xo,sl,Ct,Nt,Qa,Zd,Oi,va;const Nh=class{constructor(t){je(this,qa);je(this,Ll);je(this,pn);je(this,mn);je(this,Za);je(this,Co);je(this,xo);je(this,Ct);je(this,Qa);je(this,Oi);je(this,Zr,void 0);je(this,Ir,void 0);je(this,hn,void 0);je(this,Qr,void 0);je(this,wo,void 0);Pt(this,"ttl");Pt(this,"ttlResolution");Pt(this,"ttlAutopurge");Pt(this,"updateAgeOnGet");Pt(this,"updateAgeOnHas");Pt(this,"allowStale");Pt(this,"noDisposeOnSet");Pt(this,"noUpdateTTL");Pt(this,"maxEntrySize");Pt(this,"sizeCalculation");Pt(this,"noDeleteOnFetchRejection");Pt(this,"noDeleteOnStaleGet");Pt(this,"allowStaleOnFetchAbort");Pt(this,"allowStaleOnFetchRejection");Pt(this,"ignoreFetchAbort");je(this,Kt,void 0);je(this,Jr,void 0);je(this,qt,void 0);je(this,Ot,void 0);je(this,Ae,void 0);je(this,vr,void 0);je(this,Ar,void 0);je(this,lr,void 0);je(this,Jt,void 0);je(this,en,void 0);je(this,rr,void 0);je(this,An,void 0);je(this,kn,void 0);je(this,tn,void 0);je(this,vn,void 0);je(this,oi,void 0);je(this,br,void 0);je(this,_i,()=>{});je(this,Ln,()=>{});je(this,Xa,()=>{});je(this,kr,()=>!1);je(this,Pi,t=>{});je(this,So,(t,r,n)=>{});je(this,Ya,(t,r,n,i)=>{if(n||i)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0});const{max:r=0,ttl:n,ttlResolution:i=1,ttlAutopurge:o,updateAgeOnGet:a,updateAgeOnHas:s,allowStale:l,dispose:c,disposeAfter:u,noDisposeOnSet:d,noUpdateTTL:h,maxSize:v=0,maxEntrySize:p=0,sizeCalculation:m,fetchMethod:g,noDeleteOnFetchRejection:b,noDeleteOnStaleGet:w,allowStaleOnFetchRejection:S,allowStaleOnFetchAbort:$,ignoreFetchAbort:x}=t;if(r!==0&&!ti(r))throw new TypeError("max option must be a nonnegative integer");const y=r?Vy(r):Array;if(!y)throw new Error("invalid max value: "+r);if(Se(this,Zr,r),Se(this,Ir,v),this.maxEntrySize=p||k(this,Ir),this.sizeCalculation=m,this.sizeCalculation){if(!k(this,Ir)&&!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(g!==void 0&&typeof g!="function")throw new TypeError("fetchMethod must be a function if specified");if(Se(this,wo,g),Se(this,oi,!!g),Se(this,qt,new Map),Se(this,Ot,new Array(r).fill(void 0)),Se(this,Ae,new Array(r).fill(void 0)),Se(this,vr,new y(r)),Se(this,Ar,new y(r)),Se(this,lr,0),Se(this,Jt,0),Se(this,en,ol.create(r)),Se(this,Kt,0),Se(this,Jr,0),typeof c=="function"&&Se(this,hn,c),typeof u=="function"?(Se(this,Qr,u),Se(this,rr,[])):(Se(this,Qr,void 0),Se(this,rr,void 0)),Se(this,vn,!!k(this,hn)),Se(this,br,!!k(this,Qr)),this.noDisposeOnSet=!!d,this.noUpdateTTL=!!h,this.noDeleteOnFetchRejection=!!b,this.allowStaleOnFetchRejection=!!S,this.allowStaleOnFetchAbort=!!$,this.ignoreFetchAbort=!!x,this.maxEntrySize!==0){if(k(this,Ir)!==0&&!ti(k(this,Ir)))throw new TypeError("maxSize must be a positive integer if specified");if(!ti(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");he(this,Ll,Uy).call(this);}if(this.allowStale=!!l,this.noDeleteOnStaleGet=!!w,this.updateAgeOnGet=!!a,this.updateAgeOnHas=!!s,this.ttlResolution=ti(i)||i===0?i:1,this.ttlAutopurge=!!o,this.ttl=n||0,this.ttl){if(!ti(this.ttl))throw new TypeError("ttl must be a positive integer if specified");he(this,qa,Xd).call(this);}if(k(this,Zr)===0&&this.ttl===0&&k(this,Ir)===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!k(this,Zr)&&!k(this,Ir)){const C="LRU_CACHE_UNBOUNDED";jF(C)&&(Wy.add(C),By("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",C,Nh));}}static unsafeExposeInternals(t){return {starts:k(t,kn),ttls:k(t,tn),sizes:k(t,An),keyMap:k(t,qt),keyList:k(t,Ot),valList:k(t,Ae),next:k(t,vr),prev:k(t,Ar),get head(){return k(t,lr)},get tail(){return k(t,Jt)},free:k(t,en),isBackgroundFetch:r=>{var n;return he(n=t,Ct,Nt).call(n,r)},backgroundFetch:(r,n,i,o)=>{var a;return he(a=t,xo,sl).call(a,r,n,i,o)},moveToTail:r=>{var n;return he(n=t,Oi,va).call(n,r)},indexes:r=>{var n;return he(n=t,pn,ri).call(n,r)},rindexes:r=>{var n;return he(n=t,mn,ni).call(n,r)},isStale:r=>{var n;return k(n=t,kr).call(n,r)}}}get max(){return k(this,Zr)}get maxSize(){return k(this,Ir)}get calculatedSize(){return k(this,Jr)}get size(){return k(this,Kt)}get fetchMethod(){return k(this,wo)}get dispose(){return k(this,hn)}get disposeAfter(){return k(this,Qr)}getRemainingTTL(t){return k(this,qt).has(t)?1/0:0}*entries(){for(const t of he(this,pn,ri).call(this))k(this,Ae)[t]!==void 0&&k(this,Ot)[t]!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield [k(this,Ot)[t],k(this,Ae)[t]]);}*rentries(){for(const t of he(this,mn,ni).call(this))k(this,Ae)[t]!==void 0&&k(this,Ot)[t]!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield [k(this,Ot)[t],k(this,Ae)[t]]);}*keys(){for(const t of he(this,pn,ri).call(this)){const r=k(this,Ot)[t];r!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield r);}}*rkeys(){for(const t of he(this,mn,ni).call(this)){const r=k(this,Ot)[t];r!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield r);}}*values(){for(const t of he(this,pn,ri).call(this))k(this,Ae)[t]!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield k(this,Ae)[t]);}*rvalues(){for(const t of he(this,mn,ni).call(this))k(this,Ae)[t]!==void 0&&!he(this,Ct,Nt).call(this,k(this,Ae)[t])&&(yield k(this,Ae)[t]);}[Symbol.iterator](){return this.entries()}find(t,r={}){for(const n of he(this,pn,ri).call(this)){const i=k(this,Ae)[n],o=he(this,Ct,Nt).call(this,i)?i.__staleWhileFetching:i;if(o!==void 0&&t(o,k(this,Ot)[n],this))return this.get(k(this,Ot)[n],r)}}forEach(t,r=this){for(const n of he(this,pn,ri).call(this)){const i=k(this,Ae)[n],o=he(this,Ct,Nt).call(this,i)?i.__staleWhileFetching:i;o!==void 0&&t.call(r,o,k(this,Ot)[n],this);}}rforEach(t,r=this){for(const n of he(this,mn,ni).call(this)){const i=k(this,Ae)[n],o=he(this,Ct,Nt).call(this,i)?i.__staleWhileFetching:i;o!==void 0&&t.call(r,o,k(this,Ot)[n],this);}}purgeStale(){let t=!1;for(const r of he(this,mn,ni).call(this,{allowStale:!0}))k(this,kr).call(this,r)&&(this.delete(k(this,Ot)[r]),t=!0);return t}dump(){const t=[];for(const r of he(this,pn,ri).call(this,{allowStale:!0})){const n=k(this,Ot)[r],i=k(this,Ae)[r],o=he(this,Ct,Nt).call(this,i)?i.__staleWhileFetching:i;if(o===void 0||n===void 0)continue;const a={value:o};if(k(this,tn)&&k(this,kn)){a.ttl=k(this,tn)[r];const s=la.now()-k(this,kn)[r];a.start=Math.floor(Date.now()-s);}k(this,An)&&(a.size=k(this,An)[r]),t.unshift([n,a]);}return t}load(t){this.clear();for(const[r,n]of t){if(n.start){const i=Date.now()-n.start;n.start=la.now()-i;}this.set(r,n.value,n);}}set(t,r,n={}){var h,v,p;if(r===void 0)return this.delete(t),this;const{ttl:i=this.ttl,start:o,noDisposeOnSet:a=this.noDisposeOnSet,sizeCalculation:s=this.sizeCalculation,status:l}=n;let{noUpdateTTL:c=this.noUpdateTTL}=n;const u=k(this,Ya).call(this,t,r,n.size||0,s);if(this.maxEntrySize&&u>this.maxEntrySize)return l&&(l.set="miss",l.maxEntrySizeExceeded=!0),this.delete(t),this;let d=k(this,Kt)===0?void 0:k(this,qt).get(t);if(d===void 0)d=k(this,Kt)===0?k(this,Jt):k(this,en).length!==0?k(this,en).pop():k(this,Kt)===k(this,Zr)?he(this,Co,al).call(this,!1):k(this,Kt),k(this,Ot)[d]=t,k(this,Ae)[d]=r,k(this,qt).set(t,d),k(this,vr)[k(this,Jt)]=d,k(this,Ar)[d]=k(this,Jt),Se(this,Jt,d),ws(this,Kt)._++,k(this,So).call(this,d,u,l),l&&(l.set="add"),c=!1;else {he(this,Oi,va).call(this,d);const m=k(this,Ae)[d];if(r!==m){if(k(this,oi)&&he(this,Ct,Nt).call(this,m)?m.__abortController.abort(new Error("replaced")):a||(k(this,vn)&&((h=k(this,hn))==null||h.call(this,m,t,"set")),k(this,br)&&((v=k(this,rr))==null||v.push([m,t,"set"]))),k(this,Pi).call(this,d),k(this,So).call(this,d,u,l),k(this,Ae)[d]=r,l){l.set="replace";const g=m&&he(this,Ct,Nt).call(this,m)?m.__staleWhileFetching:m;g!==void 0&&(l.oldValue=g);}}else l&&(l.set="update");}if(i!==0&&!k(this,tn)&&he(this,qa,Xd).call(this),k(this,tn)&&(c||k(this,Xa).call(this,d,i,o),l&&k(this,Ln).call(this,l,d)),!a&&k(this,br)&&k(this,rr)){const m=k(this,rr);let g;for(;g=m==null?void 0:m.shift();)(p=k(this,Qr))==null||p.call(this,...g);}return this}pop(){var t;try{for(;k(this,Kt);){const r=k(this,Ae)[k(this,lr)];if(he(this,Co,al).call(this,!0),he(this,Ct,Nt).call(this,r)){if(r.__staleWhileFetching)return r.__staleWhileFetching}else if(r!==void 0)return r}}finally{if(k(this,br)&&k(this,rr)){const r=k(this,rr);let n;for(;n=r==null?void 0:r.shift();)(t=k(this,Qr))==null||t.call(this,...n);}}}has(t,r={}){const{updateAgeOnHas:n=this.updateAgeOnHas,status:i}=r,o=k(this,qt).get(t);if(o!==void 0){const a=k(this,Ae)[o];if(he(this,Ct,Nt).call(this,a)&&a.__staleWhileFetching===void 0)return !1;if(k(this,kr).call(this,o))i&&(i.has="stale",k(this,Ln).call(this,i,o));else return n&&k(this,_i).call(this,o),i&&(i.has="hit",k(this,Ln).call(this,i,o)),!0}else i&&(i.has="miss");return !1}peek(t,r={}){const{allowStale:n=this.allowStale}=r,i=k(this,qt).get(t);if(i!==void 0&&(n||!k(this,kr).call(this,i))){const o=k(this,Ae)[i];return he(this,Ct,Nt).call(this,o)?o.__staleWhileFetching:o}}async fetch(t,r={}){const{allowStale:n=this.allowStale,updateAgeOnGet:i=this.updateAgeOnGet,noDeleteOnStaleGet:o=this.noDeleteOnStaleGet,ttl:a=this.ttl,noDisposeOnSet:s=this.noDisposeOnSet,size:l=0,sizeCalculation:c=this.sizeCalculation,noUpdateTTL:u=this.noUpdateTTL,noDeleteOnFetchRejection:d=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:h=this.allowStaleOnFetchRejection,ignoreFetchAbort:v=this.ignoreFetchAbort,allowStaleOnFetchAbort:p=this.allowStaleOnFetchAbort,context:m,forceRefresh:g=!1,status:b,signal:w}=r;if(!k(this,oi))return b&&(b.fetch="get"),this.get(t,{allowStale:n,updateAgeOnGet:i,noDeleteOnStaleGet:o,status:b});const S={allowStale:n,updateAgeOnGet:i,noDeleteOnStaleGet:o,ttl:a,noDisposeOnSet:s,size:l,sizeCalculation:c,noUpdateTTL:u,noDeleteOnFetchRejection:d,allowStaleOnFetchRejection:h,allowStaleOnFetchAbort:p,ignoreFetchAbort:v,status:b,signal:w};let $=k(this,qt).get(t);if($===void 0){b&&(b.fetch="miss");const x=he(this,xo,sl).call(this,t,$,S,m);return x.__returned=x}else {const x=k(this,Ae)[$];if(he(this,Ct,Nt).call(this,x)){const P=n&&x.__staleWhileFetching!==void 0;return b&&(b.fetch="inflight",P&&(b.returnedStale=!0)),P?x.__staleWhileFetching:x.__returned=x}const y=k(this,kr).call(this,$);if(!g&&!y)return b&&(b.fetch="hit"),he(this,Oi,va).call(this,$),i&&k(this,_i).call(this,$),b&&k(this,Ln).call(this,b,$),x;const C=he(this,xo,sl).call(this,t,$,S,m),R=C.__staleWhileFetching!==void 0&&n;return b&&(b.fetch=y?"stale":"refresh",R&&y&&(b.returnedStale=!0)),R?C.__staleWhileFetching:C.__returned=C}}get(t,r={}){const{allowStale:n=this.allowStale,updateAgeOnGet:i=this.updateAgeOnGet,noDeleteOnStaleGet:o=this.noDeleteOnStaleGet,status:a}=r,s=k(this,qt).get(t);if(s!==void 0){const l=k(this,Ae)[s],c=he(this,Ct,Nt).call(this,l);return a&&k(this,Ln).call(this,a,s),k(this,kr).call(this,s)?(a&&(a.get="stale"),c?(a&&n&&l.__staleWhileFetching!==void 0&&(a.returnedStale=!0),n?l.__staleWhileFetching:void 0):(o||this.delete(t),a&&n&&(a.returnedStale=!0),n?l:void 0)):(a&&(a.get="hit"),c?l.__staleWhileFetching:(he(this,Oi,va).call(this,s),i&&k(this,_i).call(this,s),l))}else a&&(a.get="miss");}delete(t){var n,i,o,a;let r=!1;if(k(this,Kt)!==0){const s=k(this,qt).get(t);if(s!==void 0)if(r=!0,k(this,Kt)===1)this.clear();else {k(this,Pi).call(this,s);const l=k(this,Ae)[s];he(this,Ct,Nt).call(this,l)?l.__abortController.abort(new Error("deleted")):(k(this,vn)||k(this,br))&&(k(this,vn)&&((n=k(this,hn))==null||n.call(this,l,t,"delete")),k(this,br)&&((i=k(this,rr))==null||i.push([l,t,"delete"]))),k(this,qt).delete(t),k(this,Ot)[s]=void 0,k(this,Ae)[s]=void 0,s===k(this,Jt)?Se(this,Jt,k(this,Ar)[s]):s===k(this,lr)?Se(this,lr,k(this,vr)[s]):(k(this,vr)[k(this,Ar)[s]]=k(this,vr)[s],k(this,Ar)[k(this,vr)[s]]=k(this,Ar)[s]),ws(this,Kt)._--,k(this,en).push(s);}}if(k(this,br)&&((o=k(this,rr))!=null&&o.length)){const s=k(this,rr);let l;for(;l=s==null?void 0:s.shift();)(a=k(this,Qr))==null||a.call(this,...l);}return r}clear(){var t,r,n;for(const i of he(this,mn,ni).call(this,{allowStale:!0})){const o=k(this,Ae)[i];if(he(this,Ct,Nt).call(this,o))o.__abortController.abort(new Error("deleted"));else {const a=k(this,Ot)[i];k(this,vn)&&((t=k(this,hn))==null||t.call(this,o,a,"delete")),k(this,br)&&((r=k(this,rr))==null||r.push([o,a,"delete"]));}}if(k(this,qt).clear(),k(this,Ae).fill(void 0),k(this,Ot).fill(void 0),k(this,tn)&&k(this,kn)&&(k(this,tn).fill(0),k(this,kn).fill(0)),k(this,An)&&k(this,An).fill(0),Se(this,lr,0),Se(this,Jt,0),k(this,en).length=0,Se(this,Jr,0),Se(this,Kt,0),k(this,br)&&k(this,rr)){const i=k(this,rr);let o;for(;o=i==null?void 0:i.shift();)(n=k(this,Qr))==null||n.call(this,...o);}}};let qd=Nh;Zr=new WeakMap,Ir=new WeakMap,hn=new WeakMap,Qr=new WeakMap,wo=new WeakMap,Kt=new WeakMap,Jr=new WeakMap,qt=new WeakMap,Ot=new WeakMap,Ae=new WeakMap,vr=new WeakMap,Ar=new WeakMap,lr=new WeakMap,Jt=new WeakMap,en=new WeakMap,rr=new WeakMap,An=new WeakMap,kn=new WeakMap,tn=new WeakMap,vn=new WeakMap,oi=new WeakMap,br=new WeakMap,qa=new WeakSet,Xd=function(){const t=new il(k(this,Zr)),r=new il(k(this,Zr));Se(this,tn,t),Se(this,kn,r),Se(this,Xa,(o,a,s=la.now())=>{if(r[o]=a!==0?s:0,t[o]=a,a!==0&&this.ttlAutopurge){const l=setTimeout(()=>{k(this,kr).call(this,o)&&this.delete(k(this,Ot)[o]);},a+1);l.unref&&l.unref();}}),Se(this,_i,o=>{r[o]=t[o]!==0?la.now():0;}),Se(this,Ln,(o,a)=>{if(t[a]){const s=t[a],l=r[a];o.ttl=s,o.start=l,o.now=n||i();const c=o.now-l;o.remainingTTL=s-c;}});let n=0;const i=()=>{const o=la.now();if(this.ttlResolution>0){n=o;const a=setTimeout(()=>n=0,this.ttlResolution);a.unref&&a.unref();}return o};this.getRemainingTTL=o=>{const a=k(this,qt).get(o);if(a===void 0)return 0;const s=t[a],l=r[a];if(s===0||l===0)return 1/0;const c=(n||i())-l;return s-c},Se(this,kr,o=>t[o]!==0&&r[o]!==0&&(n||i())-r[o]>t[o]);},_i=new WeakMap,Ln=new WeakMap,Xa=new WeakMap,kr=new WeakMap,Ll=new WeakSet,Uy=function(){const t=new il(k(this,Zr));Se(this,Jr,0),Se(this,An,t),Se(this,Pi,r=>{Se(this,Jr,k(this,Jr)-t[r]),t[r]=0;}),Se(this,Ya,(r,n,i,o)=>{if(he(this,Ct,Nt).call(this,n))return 0;if(!ti(i))if(o){if(typeof o!="function")throw new TypeError("sizeCalculation must be a function");if(i=o(n,r),!ti(i))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 i}),Se(this,So,(r,n,i)=>{if(t[r]=n,k(this,Ir)){const o=k(this,Ir)-t[r];for(;k(this,Jr)>o;)he(this,Co,al).call(this,!0);}Se(this,Jr,k(this,Jr)+t[r]),i&&(i.entrySize=n,i.totalCalculatedSize=k(this,Jr));});},Pi=new WeakMap,So=new WeakMap,Ya=new WeakMap,pn=new WeakSet,ri=function*({allowStale:t=this.allowStale}={}){if(k(this,Kt))for(let r=k(this,Jt);!(!he(this,Za,Yd).call(this,r)||((t||!k(this,kr).call(this,r))&&(yield r),r===k(this,lr)));)r=k(this,Ar)[r];},mn=new WeakSet,ni=function*({allowStale:t=this.allowStale}={}){if(k(this,Kt))for(let r=k(this,lr);!(!he(this,Za,Yd).call(this,r)||((t||!k(this,kr).call(this,r))&&(yield r),r===k(this,Jt)));)r=k(this,vr)[r];},Za=new WeakSet,Yd=function(t){return t!==void 0&&k(this,qt).get(k(this,Ot)[t])===t},Co=new WeakSet,al=function(t){var o,a;const r=k(this,lr),n=k(this,Ot)[r],i=k(this,Ae)[r];return k(this,oi)&&he(this,Ct,Nt).call(this,i)?i.__abortController.abort(new Error("evicted")):(k(this,vn)||k(this,br))&&(k(this,vn)&&((o=k(this,hn))==null||o.call(this,i,n,"evict")),k(this,br)&&((a=k(this,rr))==null||a.push([i,n,"evict"]))),k(this,Pi).call(this,r),t&&(k(this,Ot)[r]=void 0,k(this,Ae)[r]=void 0,k(this,en).push(r)),k(this,Kt)===1?(Se(this,lr,Se(this,Jt,0)),k(this,en).length=0):Se(this,lr,k(this,vr)[r]),k(this,qt).delete(n),ws(this,Kt)._--,r},xo=new WeakSet,sl=function(t,r,n,i){const o=r===void 0?void 0:k(this,Ae)[r];if(he(this,Ct,Nt).call(this,o))return o;const a=new Nl,{signal:s}=n;s==null||s.addEventListener("abort",()=>a.abort(s.reason),{signal:a.signal});const l={signal:a.signal,options:n,context:i},c=(m,g=!1)=>{const{aborted:b}=a.signal,w=n.ignoreFetchAbort&&m!==void 0;if(n.status&&(b&&!g?(n.status.fetchAborted=!0,n.status.fetchError=a.signal.reason,w&&(n.status.fetchAbortIgnored=!0)):n.status.fetchResolved=!0),b&&!w&&!g)return d(a.signal.reason);const S=v;return k(this,Ae)[r]===v&&(m===void 0?S.__staleWhileFetching?k(this,Ae)[r]=S.__staleWhileFetching:this.delete(t):(n.status&&(n.status.fetchUpdated=!0),this.set(t,m,l.options))),m},u=m=>(n.status&&(n.status.fetchRejected=!0,n.status.fetchError=m),d(m)),d=m=>{const{aborted:g}=a.signal,b=g&&n.allowStaleOnFetchAbort,w=b||n.allowStaleOnFetchRejection,S=w||n.noDeleteOnFetchRejection,$=v;if(k(this,Ae)[r]===v&&(!S||$.__staleWhileFetching===void 0?this.delete(t):b||(k(this,Ae)[r]=$.__staleWhileFetching)),w)return n.status&&$.__staleWhileFetching!==void 0&&(n.status.returnedStale=!0),$.__staleWhileFetching;if($.__returned===$)throw m},h=(m,g)=>{var w;const b=(w=k(this,wo))==null?void 0:w.call(this,t,o,l);b&&b instanceof Promise&&b.then(S=>m(S),g),a.signal.addEventListener("abort",()=>{(!n.ignoreFetchAbort||n.allowStaleOnFetchAbort)&&(m(),n.allowStaleOnFetchAbort&&(m=S=>c(S,!0)));});};n.status&&(n.status.fetchDispatched=!0);const v=new Promise(h).then(c,u),p=Object.assign(v,{__abortController:a,__staleWhileFetching:o,__returned:void 0});return r===void 0?(this.set(t,p,{...l.options,status:void 0}),r=k(this,qt).get(t)):k(this,Ae)[r]=p,p},Ct=new WeakSet,Nt=function(t){if(!k(this,oi))return !1;const r=t;return !!r&&r instanceof Promise&&r.hasOwnProperty("__staleWhileFetching")&&r.__abortController instanceof Nl},Qa=new WeakSet,Zd=function(t,r){k(this,Ar)[r]=t,k(this,vr)[t]=r;},Oi=new WeakSet,va=function(t){t!==k(this,Jt)&&(t===k(this,lr)?Se(this,lr,k(this,vr)[t]):he(this,Qa,Zd).call(this,k(this,Ar)[t],k(this,vr)[t]),he(this,Qa,Zd).call(this,k(this,Jt),t),Se(this,Jt,t));};async function zF(e){return (await kc.get("/pvideo",{params:{aid:e}})).data.data}async function HF(e){return []}const Mu=new qd({max:200});async function WF(e){if(Mu.has(e))return Mu.get(e);const[t,r]=await Promise.all([zF(e),HF()]);return Mu.set(e,{pvideoData:t,dmData:r}),{pvideoData:t,dmData:r}}function Gy(e){return async function(r){const n=new FormData;n.append("aid",r),n.append("csrf",DF());const o=(await kc.post("/x/v2/history/toview/"+e,n,{withCredentials:!0})).data,a=(o==null?void 0:o.code)===0&&(o==null?void 0:o.message)==="0";return a||Cr((o==null?void 0:o.message)||"出错了"),a}}const BF=Gy("add"),VF=Gy("del"),Ky=e=>{const t={dislike:"/x/feed/dislike",cancel:"/x/feed/dislike/cancel"}[e];return async function(r,n){const o=(await Lc.get(Hy+t,{params:{goto:r.goto,id:r.param,reason_id:n,build:"1",mobi_app:"android",idx:(Date.now()/1e3).toFixed(0)}})).data;return (o==null?void 0:o.code)===0&&(o==null?void 0:o.message)==="0"}},UF=Ky("dislike"),GF=Ky("cancel"),KF="_modal_1rloz_1",qF="_title-desc_1rloz_4",XF="_reason-list_1rloz_8",YF="_reason_1rloz_8",ZF="_active_1rloz_29",QF="_reason-no_1rloz_33",JF="_tips-container_1rloz_47",eD="_tips_1rloz_47",Br={modal:KF,titleDesc:qF,reasonList:XF,reason:YF,active:ZF,reasonNo:QF,tipsContainer:JF,tips:eD},Fc=AF();function tD(){return ko(Fc)}function rD(e){const t=tD();if(e)return t.get(e)}function nD({show:e,onHide:t,item:r}){const[n,i]=f.useState(!1),o=mt(async p=>{if(!r)return;let m=!1,g;try{i(!0),m=await UF(r,p.id);}catch(b){g=b;}finally{i(!1);}if(g)return console.error(g.stack||g),Fy();m?Cr("已标记不想看"):Dy(),m&&(Fc.set(r.param,{...p}),t());}),a=f.useMemo(()=>{var p;return ((p=r==null?void 0:r.three_point)==null?void 0:p.dislike_reasons)||[]},[r]),s=()=>!!e&&!!r,l=["1","2","3","4","5","6"];Xt(l,p=>{if(!s()||!l.includes(p.key))return;const m=Number(p.key)-1;u(m);const g=document.querySelectorAll(`.${Br.reason}`)[m]||null;g==null||g.click();});const[c,u]=f.useState(a.length-1);SF(()=>{u(a.length-1);},[a]);const d=p=>()=>{if(!s())return;const m=c+p;m<0||m>a.length-1||u(m);};Xt("leftarrow",d(-1)),Xt("rightarrow",d(1)),Xt("uparrow",d(-2)),Xt("downarrow",d(2)),Xt("enter",p=>{var m;s()&&(c<0||c>a.length-1||(p.preventDefault(),p.stopImmediatePropagation(),(m=document.querySelector(`.${Br.reason}.${Br.active}`))==null||m.click()));});const h=f.useMemo(()=>{var p;return ((p=a[c])==null?void 0:p.name)||""},[a,c]),{colorPrimary:v}=Ho();return ee(yh,{show:e,onHide:t,clsModal:Br.modal,hideWhenMaskOnClick:!0,hideWhenEsc:!0,children:[ee("div",{className:sn.modalHeader,children:[ee("div",{className:sn.modalTitle,children:["我不想看",F("span",{className:Br.titleDesc,children:"(选择后将减少相似内容推荐)"})]}),F("div",{className:"space",style:{flex:1}}),F(wh,{onClick:t})]}),ee("div",{className:sn.modalBody,children:[F("div",{className:Br.reasonList,children:a.map((p,m)=>ee("button",{className:K(Br.reason,{[Br.active]:m===c}),style:{...m===c&&{borderColor:v}},"data-id":p.id,onClick:()=>{u(m),o(p);},disabled:n,children:[F("span",{className:Br.reasonNo,style:{backgroundColor:v},children:m+1}),p.name]},p.id))}),ee("div",{className:Br.tipsContainer,children:[ee("div",{className:Br.tips,children:[F(Bn,{name:"Info",size:15,style:{marginRight:5}}),"使用删除键打开弹框, 数字键选择, Esc 关闭"]}),h&&ee("div",{className:Br.tips,children:[F(Bn,{name:"Info",size:15,style:{marginRight:5}}),"已选择「",h,"」, 回车键提交"]})]})]})]})}const ll={show:!1,onHide:Xy,item:null},qy=ts({value:ll.show}),iD=function(){return ko(qy).value};function Xy(){setTimeout(()=>{Yy({show:!1,item:null});});}function Yy(e){Object.assign(ll,e),qy.value=ll.show,oD().render(F(nD,{...ll,onHide:Xy}));}let Ru;function oD(){if(!Ru){const e=document.createElement("div");e.classList.add("show-dislike-container"),document.body.appendChild(e),Ru=Nc(e);}return Ru}function aD(e){e!=null&&e.param&&Fc.has(e.param)||Yy({show:!0,item:e});}function sD(e){return e||(e=0),oc.duration(e||0,"seconds").format(e>=3600?"HH:mm:ss":"mm:ss")}function Nu(e){if(!e)return "";if(e<=9999)return e.toString();let t=(e/1e4).toFixed(1);return t=t.replace(/\.0$/,""),`${t}万`}function mm(e){if(e){if(e==="-")return 0;if(/^\d+$/.test(e))return Number(e);if(/^\d+(\.\d+?)?万$/.test(e))return Number(e.slice(0,-1))*1e4}}const lD="_bili-video-card_mlccj_1",cD="_image-wrapper_mlccj_4",uD="_preview-card-wrapper_mlccj_8",dD="_preview-card-inner_mlccj_21",fD="_watch-later_mlccj_25",hD="_badge_mlccj_28",vD="_recommend-reason_mlccj_37",pD="_bangumi-desc_mlccj_52",mD="_btn-dislike_mlccj_55",gD="_btn-dislike-icon_mlccj_70",bD="_btn-dislike-tip_mlccj_77",yD="_disliked-wrapper_mlccj_92",wD="_dislike-content-cover_mlccj_106",SD="_dislike-content-cover-inner_mlccj_112",CD="_dislike-icon_mlccj_123",xD="_dislike-reason_mlccj_126",$D="_dislike-desc_mlccj_130",ED="_dislike-content-action_mlccj_134",_D="_skeleton-active_mlccj_151",PD="_ant-skeleton-loading_mlccj_1",Yt={biliVideoCard:lD,imageWrapper:cD,previewCardWrapper:uD,previewCardInner:dD,watchLater:fD,badge:hD,recommendReason:vD,bangumiDesc:pD,btnDislike:mD,btnDislikeIcon:gD,btnDislikeTip:bD,dislikedWrapper:yD,dislikeContentCover:wD,dislikeContentCoverInner:SD,dislikeIcon:CD,dislikeReason:xD,dislikeDesc:$D,dislikeContentAction:ED,skeletonActive:_D,antSkeletonLoading:PD};function OD(...e){for(const t of e)if(!isNaN(t))return t;return 0}function TD({className:e,videoDuration:t,pvideo:r,mouseEnterRelativeX:n,previewAnimationProgress:i}){const o=f.useRef(null),a=bF(o),[s,l]=f.useState(()=>({width:0,height:0}));bh(()=>{var h;const d=(h=o.current)==null?void 0:h.getBoundingClientRect();d&&l({width:d.width,height:d.height});});let c=0;if(typeof i=="number")c=i;else {const d=OD(a.elementX,n||0);s.width&&d&&!isNaN(d)&&(c=d/s.width,c<0&&(c=0),c>1&&(c=1));}const u={videoDuration:t,pvideo:r,elWidth:s.width,elHeight:s.height,progress:c};return F("div",{ref:o,className:K(Yt.previewCardWrapper,e),children:!!(r&&s.width&&s.height&&c)&&F(MD,{...u})})}function MD({videoDuration:e,pvideo:t,elWidth:r,elHeight:n,progress:i}){var x;const o=Math.floor((e||0)*i);let a=f.useMemo(()=>{const y=(t==null?void 0:t.index)||[];let C=ND(y,o);return C!==-1?C:o>y[y.length-1]?(C=Math.floor(y.length*i)-1,C<0&&(C=0),C):0},[t,o]);const{img_x_len:s,img_y_len:l,img_x_size:c,img_y_size:u}=t,d=l*s;a=a+1;const h=Math.floor(a/d),v=a-h*d,p=((x=t.image)==null?void 0:x[h])||"",m=Math.floor(v/s)+1,g=v-(m-1)*s,b=r*s,w=n*l,S=(m-1)*n,$=(g-1)*r;return F("div",{className:Yt.previewCardInner,style:{backgroundColor:"black",backgroundImage:`url(${p})`,backgroundPosition:`-${$}px -${S}px`,backgroundSize:`${b}px ${w}px`},children:F(RD,{progress:i})})}function RD({progress:e}){const{colorPrimary:t}=Ho();return F("div",{className:"track",style:{position:"absolute",bottom:0,left:0,backgroundColor:"#eee",width:"100%",height:2},children:F("div",{className:"bar",style:{backgroundColor:t,height:"100%",width:`${e*100}%`}})})}function ND(e,t){let r=0,n=e.length-1,i=-1;for(;r<=n;){const s=Math.floor((r+n)/2),l=e[s];if(t===l)return s;l{const t=Ka[e]||Ka[1];return Qd[t]},kD=e=>{const t=Ka[e];if(t)return ID[t]};function gm(e){return {iconSvgName:AD(e),iconSvgScale:kD(e)}}function Zy(e){var M,R,P;const t=e.api==="pc",r=e.api==="app",n=String(t?e.id:e.param),i=t?e.bvid:"",o=e.goto,a=N=>{if(t)return;const{cover_left_icon_1:_,cover_left_text_1:E,cover_left_icon_2:O,cover_left_text_2:T}=e;if(_&&Ka[_]===N)return mm(E);if(O&&Ka[O]===N)return mm(T)},s=t?e.stat.view:a("play"),l=t?e.stat.like:void 0,c=void 0,u=t?e.stat.danmaku:a("danmaku"),d=e.title,h=t?e.pic:e.cover,v=t?e.pubdate:void 0,p=(t?e.duration:(M=e.player_args)==null?void 0:M.duration)||0,m=t?e.owner.name:e.args.up_name,g=t?e.owner.face:void 0,b=t?e.owner.mid:e.args.up_id,w=void 0,S=t?void 0:e.badge,$=t?void 0:((R=e.desc_button)==null?void 0:R.text)||e.desc||"",x=t?void 0:e.badge_style,y=t?(P=e.rcmd_reason)==null?void 0:P.content:e.rcmd_reason,C=t?void 0:e.rcmd_reason_style;return {isPc:t,isApp:r,id:n,bvid:i,goto:o,play:s,like:l,coin:c,danmaku:u,title:d,coverRaw:h,pubdate:v,duration:p,name:m,face:g,mid:b,favorite:w,recommendReason:y,recommendReasonStyleConfig:C,appBadge:S,appBadgeDesc:$,appBadgeStyleConfig:x}}const LD=oc().format("YYYY"),FD=e=>{if(!e)return "";const t=oc.unix(e);return t.format("YYYY")===LD?t.format("M-D"):t.format("YY-M-D")},DD=e=>(e||"").replace(/^http:\/\//,"https://"),Il=f.memo(f.forwardRef(function({style:t,className:r,item:n,loading:i,active:o,...a},s){i=i??!n;const l=ee("div",{className:K("bili-video-card__skeleton",{hide:!i,[Yt.skeletonActive]:i}),children:[F("div",{className:"bili-video-card__skeleton--cover"}),F("div",{className:"bili-video-card__skeleton--info",children:ee("div",{className:"bili-video-card__skeleton--right",children:[F("p",{className:"bili-video-card__skeleton--text"}),F("p",{className:"bili-video-card__skeleton--text short"}),F("p",{className:"bili-video-card__skeleton--light"})]})})]}),c=rD((n==null?void 0:n.api)==="app"&&n.param),u=f.useRef(null),d=f.useRef(null);return f.useImperativeHandle(s,()=>({async onCancelDislike(){var h;await((h=u.current)==null?void 0:h.onCancelDislike());},async onToggleWatchLater(){var h;await((h=d.current)==null?void 0:h.onToggleWatchLater());},onTriggerDislike(){var h;(h=d.current)==null||h.onTriggerDislike();},onStartPreviewAnimation(){var h;(h=d.current)==null||h.onStartPreviewAnimation();},onHotkeyPreviewAnimation(){var h;(h=d.current)==null||h.onHotkeyPreviewAnimation();}}),[u,d]),ee("div",{style:t,className:K("bili-video-card",Yt.biliVideoCard,r),"data-report":"partition_recommend.content",...a,children:[l,!i&&n&&(c?F(jD,{ref:u,item:n,dislikedReason:c}):F(zD,{ref:d,item:n,active:o}))]})})),jD=f.memo(f.forwardRef(function({dislikedReason:t,item:r},n){const i=mt(async()=>{if(!(t!=null&&t.id))return;let o=!1,a;try{o=await GF(r,t.id);}catch(s){a=s;}if(a)return console.error(a.stack||a),Fy();o?Cr("已撤销"):Dy(),o&&Fc.delete(r.param);});return f.useImperativeHandle(n,()=>({onCancelDislike:i}),[]),ee("div",{className:K(Yt.dislikedWrapper),children:[F("div",{className:Yt.dislikeContentCover,children:ee("div",{className:Yt.dislikeContentCoverInner,children:[F(Bn,{name:"DistraughtFace",size:32,className:Yt.dislikeIcon}),F("div",{className:Yt.dislikeReason,children:t==null?void 0:t.name}),F("div",{className:Yt.dislikeDesc,children:(t==null?void 0:t.toast)||"将减少此类内容推荐"})]})}),F("div",{className:Yt.dislikeContentAction,children:ee("button",{onClick:i,children:[F(Bn,{name:"Return",size:"16",style:{marginRight:4,marginTop:-2}}),"撤销"]})})]})})),zD=f.memo(f.forwardRef(function({item:t,active:r=!1},n){const i=t.api==="pc",o=t.api==="app",{id:a,bvid:s,goto:l,play:c,like:u,coin:d,danmaku:h,title:v,coverRaw:p,pubdate:m,duration:g,name:b,face:w,mid:S,recommendReason:$,recommendReasonStyleConfig:x,favorite:y,appBadge:C,appBadgeDesc:M,appBadgeStyleConfig:R}=f.useMemo(()=>Zy(t),[t]),P=t.goto==="av",N=t.goto==="bangumi",_=t.goto==="picture";["av","bangumi","picture"].includes(l)||console.warn(`[${ui}]: none (av,bangumi,picture) goto type %s`,l,t);const E=f.useMemo(()=>FD(m),[m]),O=f.useMemo(()=>DD(p),[p]),[T,A]=f.useState(null),I=f.useRef(!1),L=mt(async()=>{if(!T&&!I.current)try{I.current=!0,A(await WF(a));}finally{I.current=!1;}}),j=f.useRef(null),[B,G]=f.useState(void 0);Ni("mouseenter",Fe=>{var He;const Oe=(He=j.current)==null?void 0:He.getBoundingClientRect();if(!Oe)return;const{x:De}=Oe,Te=Fe.pageX-window.pageXOffset-De;G(Te);},{target:j});const z=Tu(j),{autoPreviewWhenHover:V}=_n(),{onStartPreviewAnimation:q,onHotkeyPreviewAnimation:U,previewAnimationProgress:Q}=HD({id:a,title:v,autoPreviewWhenHover:V,active:r,tryFetchVideoData:L,videoPreviewWrapperRef:j});Rl(()=>{r&&(unsafeWindow[`${Qw}_activeItem`]=t,et.autoPreviewWhenKeyboardSelect&&q());},[r]);const ie=f.useRef(null),Z=Tu(ie),[te,ae]=f.useState(!1),{accessKey:ue}=_n(),Ee=!!ue;f.useEffect(()=>{z&&L();},[z]),f.useImperativeHandle(n,()=>({onToggleWatchLater:se,onTriggerDislike:de,onStartPreviewAnimation:q,onHotkeyPreviewAnimation:U}),[]);const[J,oe]=f.useState(!1),se=mt(async Fe=>{if(Fe==null||Fe.preventDefault(),J)return;oe(!0);const Oe=te?VF:BF;let De=!1;try{De=await Oe(a);}finally{oe(!1);}De&&ae(Te=>!Te);}),re=f.useRef(null),xe=Tu(re),de=mt(Fe=>{Fe==null||Fe.stopPropagation(),Fe==null||Fe.preventDefault(),o&&aD(t);}),ge=f.useMemo(()=>i?P&&s?`/video/${s}`:t.uri:(()=>{var Fe;if(t.uri.startsWith("http://")||t.uri.startsWith("https://"))return t.uri;if(P)return `/video/av${t.param}`;if(N)return console.warn(`[${ui}]: bangumi uri should not starts with 'bilibili://': %s`,t.uri),t.uri;if(_){const Oe=(Fe=/^bilibili:\/\/article\/(\d+)$/.exec(t.uri))==null?void 0:Fe[1];return Oe?`/read/cv${Oe}`:t.uri}return t.uri})(),[t]),ve=f.useMemo(()=>sD(g),[g]),$e=f.useMemo(()=>Nu(c),[c]),Ye=f.useMemo(()=>Nu(u),[u]),dt=f.useMemo(()=>Nu(y),[y]),xt=i?Ye:dt,tt=mt(Fe=>{if(!et.openInIINAWhenRightClick)return;const Oe=new URL(ge,location.href).href,De=`iina://open?url=${encodeURIComponent(Oe)}`;window.open(De,"_self"),Fe.preventDefault();}),ke=({text:Fe,iconSvgName:Oe,iconSvgScale:De})=>ee("span",{className:"bili-video-card__stats--item",children:[F("svg",{className:"bili-video-card__stats--icon",style:{transform:De?`scale(${De})`:void 0},children:F("use",{href:Oe})}),F("span",{className:"bili-video-card__stats--text",children:Fe})]});return ee("div",{className:"bili-video-card__wrap __scale-wrap",onContextMenu:tt,children:[F("a",{href:ge,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:ee("div",{className:"bili-video-card__image __scale-player-wrap",ref:j,children:[ee("div",{className:K("bili-video-card__image--wrap",Yt.imageWrapper),children:[ee("picture",{className:"v-img bili-video-card__cover",children:[F("source",{srcSet:`${O}@672w_378h_1c_!web-home-common-cover.avif`,type:"image/avif"}),F("source",{srcSet:`${O}@672w_378h_1c_!web-home-common-cover.webp`,type:"image/webp"}),F("img",{src:`${O}@672w_378h_1c_!web-home-common-cover`,alt:v,loading:"eager"})]}),(z||typeof Q=="number")&&F(TD,{videoDuration:g,pvideo:T==null?void 0:T.pvideoData,mouseEnterRelativeX:B,previewAnimationProgress:Q}),ee("div",{className:`bili-watch-later ${Yt.watchLater}`,style:{display:z||r?"flex":"none"},ref:ie,onClick:se,children:[F("svg",{className:"bili-watch-later__icon",children:F("use",{href:te?"#widget-watch-save":"#widget-watch-later"})}),F("span",{className:"bili-watch-later__tip",style:{display:Z?"block":"none"},children:te?"移除":"稍后再看"})]}),o&&Ee&&ee("div",{ref:re,className:Yt.btnDislike,onClick:de,style:{display:z?"flex":"none"},children:[F("svg",{className:Yt.btnDislikeIcon,children:F("use",{href:"#widget-close"})}),F("span",{className:Yt.btnDislikeTip,style:{display:xe?"block":"none"},children:"我不想看"})]})]}),F("div",{className:"bili-video-card__mask",children:ee("div",{className:"bili-video-card__stats",children:[F("div",{className:"bili-video-card__stats--left",children:i?ee(nr,{children:[ke({text:$e,iconSvgName:Qd.play}),ke({text:l==="av"?Ye:xt,iconSvgName:Qd.like})]}):ee(nr,{children:[t.cover_left_text_1&&ke({...gm(t.cover_left_icon_1),text:l==="picture"?t.cover_left_text_1+(t.cover_left_1_content_description||""):t.cover_left_text_1}),t.cover_left_text_2&&ke({...gm(t.cover_left_icon_2),text:l==="picture"?t.cover_left_text_2+(t.cover_left_2_content_description||""):t.cover_left_text_2})]})}),F("span",{className:"bili-video-card__stats__duration",children:P&&ve})]})})]})}),F("div",{className:"bili-video-card__info __scale-disable",children:ee("div",{className:"bili-video-card__info--right",children:[F("a",{href:ge,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:F("h3",{className:"bili-video-card__info--tit",title:v,children:v})}),F("p",{className:"bili-video-card__info--bottom",children:P?ee("a",{className:"bili-video-card__info--owner",href:`//space.bilibili.com/${S}`,target:"_blank","data-mod":"partition_recommend","data-idx":"content","data-ext":"click",children:[$?F("span",{className:Yt.recommendReason,children:$}):F("svg",{className:"bili-video-card__info--owner__up",children:F("use",{href:"#widget-up"})}),F("span",{className:"bili-video-card__info--author",children:b}),E&&ee("span",{className:"bili-video-card__info--date",children:["· ",E]})]}):C||M?ee("a",{className:"bili-video-card__info--owner",href:ge,target:"_blank",children:[F("span",{className:Yt.badge,children:C||""}),F("span",{className:Yt.bangumiDesc,children:M||""})]}):null})]})})]})}));function HD({id:e,title:t,autoPreviewWhenHover:r,active:n,tryFetchVideoData:i,videoPreviewWrapperRef:o}){const[s,l]=Ly(void 0),[c,u]=f.useState(!1),d=f.useRef(!1),h=f.useRef(!1);Ni("mouseenter",M=>{d.current=!0,r&&!p.current&&C(!0);},{target:o}),Ni("mouseleave",M=>{d.current=!1;},{target:o}),Ni("mousemove",M=>{u(!0),r||g();},{target:o});const v=wF(),p=f.useRef(void 0),m=mt(()=>{if(v.current)return !0;if(r){if(h.current){if(!d.current)return !0}else if(!n)return !0}else if(!n||c)return !0;return !1}),g=mt((M=!1)=>{p.current&&cancelAnimationFrame(p.current),p.current=void 0,l(void 0),w(!1);}),[b,w,S]=nl(!1),$=f.useRef(),x=mt(()=>{var M;if(!p.current){C();return}w(R=>!R),b&&((M=$.current)==null||M.call($,s||0));}),y=mt(()=>s||0),C=mt((M=!1)=>{h.current=M,u(!1),w(!1),i(),g(!0),l(O=>typeof O>"u"?0:O);const R=8e3,P=()=>typeof et.autoPreviewUpdateInterval=="number"?et.autoPreviewUpdateInterval:400;let N=performance.now(),_=0;$.current=()=>{N=performance.now()-y()*R;};function E(O){if(m()){g();return}const T=()=>{const A=performance.now()-N,I=Math.min(A%R/R,1);l(I);};S()||(P()?(!_||performance.now()-_>=P())&&(_=performance.now(),T()):T()),p.current=requestAnimationFrame(E);}p.current=requestAnimationFrame(E);});return {onHotkeyPreviewAnimation:x,onStartPreviewAnimation:C,previewAnimationProgress:s}}const Sh="_video-grid_tu03i_9",WD="_limit-two-lines_tu03i_19",Qy="_internal-testing_tu03i_51",BD="_narrow-mode_tu03i_79";function VD({enabled:e,refresh:t,minIndex:r=0,maxIndex:n,containerRef:i,getScrollerRect:o,changeScrollY:a,videoCardRefs:s}){const[l,c]=f.useState(void 0),u=mt(()=>!(!e||Rc())),d=mt(()=>{var C;if(typeof l!="number"||!i.current)return !1;const x=o(),y=(C=i.current.querySelector(`.${bo.card}.${bo.cardActive}`))==null?void 0:C.getBoundingClientRect();return !(!x||!y||y.top-x.top<-(x.height+y.height)||y.top-x.top>x.height*2+y.height)}),h=x=>y=>{if(!u())return;y==null||y.preventDefault();let C=typeof x=="number"?x:x();const M=d()?l+C:m();if(Mn){S(n);return}c(M),S(M);};Xt("leftarrow",h(-1),{exactMatch:!0}),Xt("rightarrow",h(1),{exactMatch:!0});const v=()=>Ch(i.current);Xt("uparrow",h(()=>-v()),{exactMatch:!0}),Xt("downarrow",h(v),{exactMatch:!0});const p=()=>{u()&&c(void 0);};Xt("esc",p),Xt("enter",()=>{!u()||typeof l!="number"||$(l);}),Xt("backspace",()=>{var x;!u()||typeof l!="number"||(x=s[l])==null||x.onTriggerDislike();}),Xt(["s","w"],()=>{var x;!u()||typeof l!="number"||(x=s[l])==null||x.onToggleWatchLater();},{exactMatch:!0}),Xt(["period","p"],()=>{var x;!u()||typeof l!="number"||(x=s[l])==null||x.onHotkeyPreviewAnimation();},{exactMatch:!0});function m(){const x=o();if(!x)return 0;const y=b();for(let C=0;C=x.top)return C;return 0}const g=`.${bo.card}`;function b(){var x;return [...((x=i.current)==null?void 0:x.querySelectorAll(g))||[]]}function w(x){return b()[x]}function S(x){var R;const y=w(x);(R=y==null?void 0:y.scrollIntoViewIfNeeded)==null||R.call(y,!1);const C=o(),M=y.getBoundingClientRect();if(!(!C||!M)){if(M.top<=C.top){const P=-(C.top-M.top+10);a==null||a({offset:P});return}if(C.bottom-M.bottom<10){const P=10-(C.bottom-M.bottom);a==null||a({offset:P});return}}}function $(x){const y=w(x);if(!y)return;const C=y.querySelector(".bili-video-card__wrap > a");C==null||C.click();}return {activeIndex:l,clearActiveIndex:p}}const bm=new Map;function Ch(e,t=!0){if(t&&et.useNarrowMode)return 2;let r=bm.get(window.innerWidth);if(r)return r;if(e||(e=document.querySelector(`.${Sh}`)),!e)return 0;const n=window.getComputedStyle(e);return n.display!=="grid"?0:(r=n.gridTemplateColumns.split(" ").length,bm.set(window.innerWidth,r),r)}function Jy(){return et.filterMinDurationEnabled||et.filterMinPlayCountEnabled}function e1(e){return Jy()?e.filter(t=>{const{play:r,duration:n,recommendReason:i}=Zy(t);return !et.enableFilterForFollowed&&(i==="已关注"||(i==null?void 0:i.includes("关注")))?!0:!(typeof r=="number"&&et.filterMinPlayCountEnabled&&et.filterMinPlayCount&&r1)for(var r=1;r=i)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]),jc(t)?r.showHidden=t:t&&Oh(r,t),wn(r.showHidden)&&(r.showHidden=!1),wn(r.depth)&&(r.depth=2),wn(r.colors)&&(r.colors=!1),wn(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=XD),Al(r,e,r.depth)}xn.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]};xn.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function XD(e,t){var r=xn.styles[t];return r?"\x1B["+xn.colors[r][0]+"m"+e+"\x1B["+xn.colors[r][1]+"m":e}function YD(e,t){return e}function ZD(e){var t={};return e.forEach(function(r,n){t[r]=!0;}),t}function Al(e,t,r){if(e.customInspect&&t&&Ta(t.inspect)&&t.inspect!==xn&&!(t.constructor&&t.constructor.prototype===t)){var n=t.inspect(r,e);return ps(n)||(n=Al(e,n,r)),n}var i=QD(e,t);if(i)return i;var o=Object.keys(t),a=ZD(o);if(e.showHidden&&(o=Object.getOwnPropertyNames(t)),Oa(t)&&(o.indexOf("message")>=0||o.indexOf("description")>=0))return ku(t);if(o.length===0){if(Ta(t)){var s=t.name?": "+t.name:"";return e.stylize("[Function"+s+"]","special")}if(Pa(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(kl(t))return e.stylize(Date.prototype.toString.call(t),"date");if(Oa(t))return ku(t)}var l="",c=!1,u=["{","}"];if(Eh(t)&&(c=!0,u=["[","]"]),Ta(t)){var d=t.name?": "+t.name:"";l=" [Function"+d+"]";}if(Pa(t)&&(l=" "+RegExp.prototype.toString.call(t)),kl(t)&&(l=" "+Date.prototype.toUTCString.call(t)),Oa(t)&&(l=" "+ku(t)),o.length===0&&(!c||t.length==0))return u[0]+l+u[1];if(r<0)return Pa(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special");e.seen.push(t);var h;return c?h=JD(e,t,r,a,o):h=o.map(function(v){return rf(e,t,r,a,v,c)}),e.seen.pop(),e3(h,l,u)}function QD(e,t){if(wn(t))return e.stylize("undefined","undefined");if(ps(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(_h(t))return e.stylize(""+t,"number");if(jc(t))return e.stylize(""+t,"boolean");if(vs(t))return e.stylize("null","null")}function ku(e){return "["+Error.prototype.toString.call(e)+"]"}function JD(e,t,r,n,i){for(var o=[],a=0,s=t.length;a-1&&(o?s=s.split(` `).map(function(c){return " "+c}).join(` `).substr(2):s=` `+s.split(` `).map(function(c){return " "+c}).join(` `))):s=e.stylize("[Circular]","special")),wn(a)){if(o&&i.match(/^\d+$/))return s;a=JSON.stringify(""+i),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 e3(e,t,r){var n=e.reduce(function(i,o){return o.indexOf(` `)>=0,i+o.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 Eh(e){return Array.isArray(e)}function jc(e){return typeof e=="boolean"}function vs(e){return e===null}function s1(e){return e==null}function _h(e){return typeof e=="number"}function ps(e){return typeof e=="string"}function l1(e){return typeof e=="symbol"}function wn(e){return e===void 0}function Pa(e){return ji(e)&&Ph(e)==="[object RegExp]"}function ji(e){return typeof e=="object"&&e!==null}function kl(e){return ji(e)&&Ph(e)==="[object Date]"}function Oa(e){return ji(e)&&(Ph(e)==="[object Error]"||e instanceof Error)}function Ta(e){return typeof e=="function"}function c1(e){return e===null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="symbol"||typeof e>"u"}function u1(e){return Buffer.isBuffer(e)}function Ph(e){return Object.prototype.toString.call(e)}function Lu(e){return e<10?"0"+e.toString(10):e.toString(10)}var t3=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function r3(){var e=new Date,t=[Lu(e.getHours()),Lu(e.getMinutes()),Lu(e.getSeconds())].join(":");return [e.getDate(),t3[e.getMonth()],t].join(" ")}function d1(){console.log("%s - %s",r3(),No.apply(null,arguments));}function Oh(e,t){if(!t||!ji(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}function f1(e,t){return Object.prototype.hasOwnProperty.call(e,t)}const n3={inherits:o1,_extend:Oh,log:d1,isBuffer:u1,isPrimitive:c1,isFunction:Ta,isError:Oa,isDate:kl,isObject:ji,isRegExp:Pa,isUndefined:wn,isSymbol:l1,isString:ps,isNumber:_h,isNullOrUndefined:s1,isNull:vs,isBoolean:jc,isArray:Eh,inspect:xn,deprecate:$h,format:No,debuglog:a1},i3=Object.freeze(Object.defineProperty({__proto__:null,_extend:Oh,debuglog:a1,default:n3,deprecate:$h,format:No,inherits:o1,inspect:xn,isArray:Eh,isBoolean:jc,isBuffer:u1,isDate:kl,isError:Oa,isFunction:Ta,isNull:vs,isNullOrUndefined:s1,isNumber:_h,isObject:ji,isPrimitive:c1,isRegExp:Pa,isString:ps,isSymbol:l1,isUndefined:wn,log:d1},Symbol.toStringTag,{value:"Module"})),o3=K1(i3);var a3=o3.format;function s3(){(typeof AbortController>"u"||typeof AbortSignal>"u")&&console.error("[promise.timeout] need global AbortController & AbortSingal");}function l3(e,t){return function(){var r=this,n=[].slice.call(arguments);s3();var i=new AbortController;return n.push(i.signal),new Promise(function(o,a){var s=setTimeout(function(){var l=new h1(t);a(l),i.abort();},t);Promise.resolve(e.apply(r,n)).then(function(l){clearTimeout(s),o(l);},function(l){clearTimeout(s),a(l);});})}}let h1=class v1 extends Error{constructor(t){super(),this.timeout=t,this.message=a3("timeout of %sms exceed",t),Error.captureStackTrace(this,v1);}};xh.exports=l3;xh.exports.TimeoutError=h1;var c3=xh.exports;const p1=c3,u3=p1.TimeoutError;Dc.exports=function(t,r){const n=t;r=r||{};const i=r.times||5,o=r.timeout;o&&(t=p1(t,o));const a=r.onerror;return async function(){const s=this,l=[].slice.call(arguments),c=new Array(i);for(let u=0;u"} ${this.times} times`,this.timeout&&(this.message+=` with timeout = ${this.timeout}ms`),Error.captureStackTrace(this,this.constructor);}}class d3 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 f3=Dc.exports.RetryError=m1;Dc.exports.TimeoutError=u3;var h3=Dc.exports;const v3=Kn(h3);class Th extends Error{constructor(t){super(),Error.captureStackTrace(this,Th),this.json=t,this.message=t.message||JSON.stringify(t);}}const p3=10;async function m3(){var n;const t=(await Lc.get(Hy+"/x/v2/feed/index",{responseType:"json",params:{build:"1",mobi_app:"android",idx:(Date.now()/1e3).toFixed(0)+"0"+Math.trunc(Math.random()*1e3).toString().padStart(3,"0")}})).data;if(!t.data){if(t.code===-663)throw new Th(t);return Cr(`${ui}: 未知错误, 请联系开发者 code=${t.code} message=${t.message||""}`,5e3),[]}return ((n=t==null?void 0:t.data)==null?void 0:n.items)||[]}const g3=v3(m3,{times:5,timeout:2e3,onerror(e,t){console.info("[%s] tryGetRecommend onerror: index=%s",ui,t,e);}});async function ym(){try{return await g3()}catch(e){if(e instanceof f3){console.error(e.errors);const t=[No("请求出错, 已重试%s次:",e.times),...e.errors.map((r,n)=>No(" %s) %s",n+1,r.message)),"","请重新获取 access_key 后重试~"].join(` `);Cr(t,5e3);}throw e}}async function g1(e){let t=[];const r=async()=>{t=(await Promise.all(new Array(e).fill(0).map(()=>ym()))).flat();},n=async()=>{for(let i=1;i<=e;i++)t=t.concat(await ym());};return await(et.useParallelRequest?r:n)(),t=ic(t,i=>i.param),t.map(i=>({...i,api:"app",uniqId:i.param+"-"+crypto.randomUUID()}))}const b1=14;async function wm(e){const t=e.page++;return (await kc.get("/x/web-interface/index/top/rcmd",{baseURL:zy,withCredentials:!0,params:{fresh_type:3,version:1,ps:b1,fresh_idx:t,fresh_idx_1h:t,homepage_ver:1}})).data.data.item}async function y1(e,t){let r=[];const n=async()=>{r=(await Promise.all(new Array(e).fill(0).map(()=>wm(t)))).flat();},i=async()=>{for(let o=1;o<=e;o++)r=r.concat(await wm(t));};return await(et.useParallelRequest?n:i)(),r=ic(r,o=>o.id),r.forEach(o=>{var a,s;((a=o.rcmd_reason)==null?void 0:a.reason_type)===1&&((s=o.rcmd_reason).content||(s.content="已关注"));}),r.map(o=>({...o,uniqId:o.id+"-"+crypto.randomUUID(),api:"pc"}))}Xm.extend("service");const ul=e=>e.api==="pc"?e.id:e.param;function b3(e,t){const r=e.map(ul);return t=ic(t,ul),e.concat(t.filter(n=>!r.includes(ul(n))))}async function w1(e,t,r=5){let n=[],i=async o=>{const a=et.usePcDesktopApi?b1:p3,s=Jy()?r:1.2,l=Math.ceil(o*s/a);let c=et.usePcDesktopApi?await y1(l,t):await g1(l);c=e1(c),n=n.concat(c),n=ic(n,ul);};for(await i(e);n.length{this.scrollComponent=b,u&&u(b);};const g=[r];return i&&(s?a?g.unshift(s):g.push(s):this.defaultLoader&&(a?g.unshift(this.defaultLoader):g.push(this.defaultLoader))),f.createElement(n,m,g)}}Pt(nf,"propTypes",{children:Rr.node.isRequired,element:Rr.node,hasMore:Rr.bool,initialLoad:Rr.bool,isReverse:Rr.bool,loader:Rr.node,loadMore:Rr.func.isRequired,pageStart:Rr.number,ref:Rr.func,getScrollParent:Rr.func,threshold:Rr.number,useCapture:Rr.bool,useWindow:Rr.bool}),Pt(nf,"defaultProps",{element:"div",hasMore:!1,initialLoad:!0,pageStart:0,ref:null,threshold:250,useWindow:!0,isReverse:!1,useCapture:!1,loader:null,getScrollParent:null});const Bs=Xm.extend("components:RecGrid"),bo={card:fm` 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:fm` border-color: #fb7299; border-radius: 6px; overflow: hidden; `};var P3={name:"1uugokx",styles:"text-align:center;line-height:60px;font-size:120%"};const $1=f.forwardRef(({infiteScrollUseWindow:e,shortcutEnabled:t,onScrollToTop:r,className:n,scrollerRef:i},o)=>{const a=f.useRef({page:1}),[s,l,c]=nl(0),[u,d,h]=nl([]),[v,p]=f.useState(!1),[m,g,b]=nl(()=>Date.now()),w=mt(async()=>{const T=performance.now();Bs("call refresh()"),await(r==null?void 0:r()),p(!0),g(Date.now()),_(),d([]),a.current.page=1;try{d(await w3(a.current));}catch(I){throw p(!1),I}l(1),_(),p(!1);const A=performance.now()-T;Bs("refresh cost %s ms",A.toFixed(0)),x();});bh(w),f.useImperativeHandle(o,()=>({refresh:w}),[]);const S=f.useRef(!1),$=mt(async()=>{if(v||S.current)return;S.current=!0;const T=b();let A=u;try{for(;!(A.length>u.length);){const I=await S3(2,a.current);A=b3(A,I);}}catch(I){throw S.current=!1,I}if(T!==b()){Bs("fetchMore: skip update for mismatch refreshedAt, %s != %s",T,b()),S.current=!1;return}Bs("fetchMore: seq(%s) len %s -> %s",c()+1,u.length,A.length),d(A),l(I=>I+1),x(),S.current=!1;}),x=mt(()=>{setTimeout(()=>{const T=e?window:i==null?void 0:i.current;T==null||T.dispatchEvent(new CustomEvent("scroll"));});}),{useNarrowMode:y}=_n(),C=f.useRef(null),M=mt(()=>{var T;if(e){const A=Eg+50;return new DOMRect(0,A,window.innerWidth,window.innerHeight-A)}else return (T=i==null?void 0:i.current)==null?void 0:T.getBoundingClientRect()}),R=iD(),P=f.useMemo(()=>new Array(u.length).fill(void 0),[u.length]),{activeIndex:N,clearActiveIndex:_}=VD({enabled:t&&!R,refresh:w,maxIndex:u.length-1,containerRef:C,getScrollerRect:M,videoCardRefs:P,changeScrollY:e?function({offset:T,absolute:A}){const I=document.documentElement;if(typeof T=="number"){I.scrollTop+=T;return}if(typeof A=="number"){I.scrollTop=A;return}}:void 0}),E=Da(),{colorPrimary:O}=Ho();return F(nf,{pageStart:0,hasMore:!0,loadMore:$,initialLoad:!1,useWindow:e,threshold:window.innerHeight,style:{minHeight:"100%"},loader:F("div",{css:P3,children:"加载中..."},-1),children:F("div",{ref:C,className:K(Sh,{[Qy]:E},{[BD]:y},n),children:v?new Array(24).fill(void 0).map((T,A)=>F(Il,{loading:!0,className:bo.card},A)):u.map((T,A)=>{const I=A===N;return F(Il,{ref:L=>P[A]=L,className:K(bo.card,{[bo.cardActive]:I}),css:[I&&Ur("border-color:",O,";",""),"",""],item:T,active:I},T.uniqId)})})})}),Sm=F(an,{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 E1({style:e,className:t}){const{runAsync:r,loading:n}=Ny(LF,{manual:!0}),{accessKey:i}=_n();return F(rh,{size:"small",style:e,className:t,children:i?ee(nr,{children:[F(an,{onClick:r,disabled:n,children:F("span",{children:"重新获取 access_key"})}),F(an,{onClick:FF,children:F("span",{children:"删除 access_key"})}),Sm]}):ee(nr,{children:[F(an,{onClick:r,disabled:n,size:"middle",children:F("span",{children:"获取 access_key"})}),Sm]})})}function Vr({configKey:e,label:t,className:r,extraAction:n,tooltip:i}){const a=!!_n()[e],s=f.useCallback(c=>{const u=c.target.checked;Fa({[e]:u}),n==null||n(u);},[]);let l=t||e;return i&&(l=F(Vf,{title:i,zIndex:11100,overlayStyle:{width:"max-content",maxWidth:"50vw"},children:l})),F(jA,{className:r,checked:a,onChange:s,children:l})}var O3={name:"1qkltea",styles:"margin-left:5px"};const T3=function(){const e=O3;return ee(nr,{children:[F(Vr,{configKey:"initialShowMore",label:"自动查看更多",css:e}),F(Vr,{configKey:"useNarrowMode",label:"启用居中模式",css:e})]})},M3="_config-icon_1qntb_1",R3="_settings-group_1qntb_6",N3="_settings-group-title_1qntb_9",I3="_settings-group-sub-title_1qntb_14",A3="_settings-group-content_1qntb_20",k3="_row_1qntb_26",L3="_check_1qntb_34",F3="_setting-tabs_1qntb_39",D3="_tab-pane_1qntb_42",Re={configIcon:M3,settingsGroup:R3,settingsGroupTitle:N3,settingsGroupSubTitle:I3,settingsGroupContent:A3,row:k3,check:L3,settingTabs:F3,tabPane:D3};async function _1(){Cr("即将刷新网页"),await Mc(500),location.reload();}function j3(){if(window.confirm("确定?"))return JE(),_1()}function Fu(e,t,r){return Xt(e,n=>{if(Rc())return;et[t]=!et[t];const i=!et[t];Cr(`已${i?"禁用":"启用"}「${r}」`);},{exactMatch:!0})}function z3({show:e,onHide:t}){const{usePcDesktopApi:r,autoPreviewUpdateInterval:n,filterMinPlayCount:i,filterMinPlayCountEnabled:o,filterMinDuration:a,filterMinDurationEnabled:s}=_n();return Fu(["shift.p"],"autoPreviewWhenKeyboardSelect","键盘选中后自动开始预览"),Fu(["shift.m"],"autoPreviewWhenHover","鼠标悬浮后自动开始预览"),Fu(["shift.c"],"useNarrowMode","居中模式"),ee(yh,{show:e,onHide:t,hideWhenMaskOnClick:!0,hideWhenEsc:!0,styleModal:{width:800},children:[ee("div",{className:sn.modalHeader,children:[ee("div",{className:sn.modalTitle,children:[F(Bn,{name:"Config",className:Re.configIcon}),"设置项"]}),F("div",{className:"space",style:{flex:1}}),F(wh,{onClick:t})]}),F("main",{className:sn.modalBody,children:F(ty,{tabPosition:"left",size:"middle",defaultActiveKey:"normal",className:Re.settingTabs,items:[{label:"常规设置",key:"normal",children:ee("div",{className:Re.tabPane,children:[ee("div",{className:Re.settingsGroup,children:[F("div",{className:Re.settingsGroupTitle,children:"接口切换"}),ee("div",{className:K(Re.settingsGroupContent),children:[ee(xu.Group,{buttonStyle:"solid",value:r?"desktop":"app",onChange:l=>{const c=l.target.value;et.usePcDesktopApi=c==="desktop";},children:[F(xu.Button,{value:"desktop",children:"使用桌面端接口"}),F(xu.Button,{value:"app",children:"使用 App 端接口"})]}),!r&&F("div",{className:Re.row,style:{marginTop:5},children:F(E1,{})})]})]}),ee("div",{className:Re.settingsGroup,children:[F("div",{className:Re.settingsGroupTitle,children:"开关"}),ee("div",{className:K(Re.settingsGroupContent,Re.row),children:[F(Vr,{configKey:"pureRecommend",label:"开启纯推荐模式",tooltip:ee(nr,{children:["首页只保留推荐",F("br",{}),"P.S 需要刷新网页~"]}),className:Re.check,extraAction:_1}),F(Vr,{configKey:"initialShowMore",label:"自动查看更多",tooltip:"打开首页时默认打开推荐弹框",className:Re.check,extraAction:l=>{l&&Cr("已开启自动查看更多: 下次打开首页时将直接展示推荐弹框");}}),F(Vr,{configKey:"useNarrowMode",label:"启用居中模式",tooltip:ee(nr,{children:["居中两列",F("br",{}),"切换设置快捷键: ",F(oa,{color:"green",children:"shift+c"})]}),className:Re.check}),F(Vr,{configKey:"useParallelRequest",label:"批量请求时使用并行",tooltip:ee(nr,{children:["并行快但可能有重复",F("br",{}),"推荐视频大量重复时关闭这个试试~"]}),className:Re.check})]})]}),ee("div",{className:Re.settingsGroup,children:[F("div",{className:Re.settingsGroupTitle,children:"预览"}),ee("div",{className:K(Re.settingsGroupContent,Re.row),children:[F(Vr,{configKey:"autoPreviewWhenKeyboardSelect",label:"键盘选中后自动开始预览",className:Re.check,tooltip:ee(nr,{children:["手动预览快捷键: ",F(oa,{color:"green",children:"."})," or ",F(oa,{color:"green",children:"p"}),F("br",{}),"切换设置快捷键: ",F(oa,{color:"green",children:"shift+p"})]})}),F(Vr,{configKey:"autoPreviewWhenHover",label:"鼠标悬浮后自动开始预览",className:Re.check,tooltip:ee(nr,{children:["鼠标悬浮后自动开始预览, 预览不再跟随鼠标位置 ",F("br",{}),"切换设置快捷键: ",F(oa,{color:"green",children:"shift+m"})]})}),ee("div",{style:{width:"100%",display:"flex",alignItems:"center"},children:["预览更新间隔",F(Ek,{style:{flex:1,margin:"0 15px"},min:0,max:1e3,keyboard:!0,onChange:l=>et.autoPreviewUpdateInterval=l,value:n,tooltip:{open:!0}}),ee("span",{style:{width:"65px"},children:["(",n,"ms)"]})]})]})]}),ee("div",{className:Re.settingsGroup,children:[F("div",{className:Re.settingsGroupTitle,children:"帮助"}),F("div",{className:K(Re.settingsGroupContent),children:F("div",{className:Re.row,children:ee(rh,{size:"small",children:[F(an,{href:"https://github.com/magicdawn/bilibili-app-recommend",target:"_blank",children:"GitHub 主页"}),F(an,{href:"https://greasyfork.org/zh-CN/scripts/443530-bilibili-app-recommend",target:"_blank",children:"GreasyFork 主页"}),F(an,{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:"查看可用的快捷键"})]})})})]})]})},{label:"视频过滤",key:"filter",children:F("div",{className:Re.tabPane,children:ee("div",{className:Re.settingsGroup,children:[ee("div",{className:Re.settingsGroupTitle,children:["视频过滤",F(im,{title:F(nr,{children:"启用视频过滤会大幅降低加载速度, 谨慎开启!"}),children:F(Bn,{style:{marginLeft:4,cursor:"pointer"},name:"Info"})})]}),ee("div",{className:K(Re.settingsGroupContent),children:[F("div",{className:Re.settingsGroupSubTitle,children:"过滤范围"}),F(Vr,{configKey:"enableFilterForFollowed",label:"对推荐理由为「已关注」的视频启用过滤",tooltip:F(nr,{children:"默认不过滤「已关注」"})}),F("div",{className:Re.settingsGroupSubTitle,children:"过滤器"}),ee("div",{className:Re.row,children:[F(Vr,{configKey:"filterMinPlayCountEnabled",label:"按播放量过滤",tooltip:F(nr,{children:"不显示播放量很少的视频"})}),F(rm,{size:"small",min:1,step:1e3,value:i,onChange:l=>l&&Fa({filterMinPlayCount:l}),disabled:!o})]}),ee("div",{className:Re.row,style:{marginTop:8},children:[F(Vr,{configKey:"filterMinDurationEnabled",label:"按视频时长过滤",tooltip:F(nr,{children:"不显示短视频"})}),F(rm,{style:{width:150},size:"small",min:1,step:10,addonAfter:"单位:秒",value:a,onChange:l=>l&&Fa({filterMinDuration:l}),disabled:!s})]})]})]})})},{label:"外观设置",key:"UI",children:F("div",{className:Re.tabPane,children:ee("div",{className:Re.settingsGroup,children:[ee("div",{className:Re.settingsGroupTitle,style:{marginBottom:15},children:["主题选择",F(im,{title:ee(nr,{children:["提取自 https://github.com/lyswhut/lx-music-desktop/",F("br",{}),"Apache License 2.0"]}),children:F(Bn,{style:{marginLeft:4,cursor:"pointer"},name:"Info"})})]}),F("div",{className:K(Re.settingsGroupContent),children:F(Dk,{})})]})})},{label:"高级设置",key:"advance",children:F("div",{className:Re.tabPane,children:ee("div",{className:Re.settingsGroup,children:[F("div",{className:Re.settingsGroupTitle,children:"高级"}),ee("div",{className:K(Re.settingsGroupContent),children:[F("div",{className:Re.row,children:F(an,{onClick:j3,danger:!0,type:"primary",children:"恢复默认设置"})}),F("div",{className:Re.row,style:{marginTop:10},children:F(Vr,{configKey:"openInIINAWhenRightClick",label:"右键在 IINA 中打开",className:Re.check})})]})]})})}]})})]})}var Mh={};Object.defineProperty(Mh,"__esModule",{value:!0});var P1=Mh.useSticky=void 0;const Du=f;function H3(){const e=(0, Du.useRef)(null),[t,r]=(0, Du.useState)(!1);return (0, Du.useEffect)(()=>{function n(){if(!e.current)return;const i=e.current.getBoundingClientRect().top,o=parseInt(getComputedStyle(e.current).top),a=i<=o;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]}P1=Mh.useSticky=H3;const W3="_expand-btn_wdzp9_1",B3="_expanded_wdzp9_12",Cm={expandBtn:W3,expanded:B3},V3=f.forwardRef(function({children:t},r){const[n,i]=Iy(!1);f.useImperativeHandle(r,()=>i,[i]);const o=F("button",{className:K("primary-btn",Cm.expandBtn),onClick:i.toggle,children:F("svg",{className:K({[Cm.expanded]:n}),children:F("use",{href:"#widget-arrow"})})});return ee(nr,{children:[o,n&&t]})}),U3="_modal-mask_7bwzz_1",G3="_narrow-mode_7bwzz_1",K3="_modal_7bwzz_1",q3="_modal-header_7bwzz_18",X3="_modal-body_7bwzz_19",Y3="_btn-refresh_7bwzz_22",ca={modalMask:U3,narrowMode:G3,modal:K3,modalHeader:q3,modalBody:X3,btnRefresh:Y3};var Z3={name:"1q4vxyr",styles:"margin-left:8px"};const Q3=f.memo(function({show:t,onHide:r}){const n=f.useRef(null),i=f.useRef(null),{useNarrowMode:o}=_n(),a=f.useMemo(()=>({[ca.narrowMode]:o}),[o]),s=mt(()=>{var h;return (h=i.current)==null?void 0:h.refresh()}),l=mt(()=>{n.current&&(n.current.scrollTop=0);}),c=ac(),{colorPrimary:u}=Ho(),d=f.useMemo(()=>c?{border:`1px solid ${u}`}:void 0,[c,u]);return ee(yh,{show:t,onHide:r,clsModalMask:K(a),clsModal:K(ca.modal,a),styleModal:{...d},children:[ee("div",{className:K(sn.modalHeader,ca.modalHeader),children:[F("div",{className:sn.modalTitle,children:"推荐"}),F("div",{className:"space",style:{flex:1}}),F(V3,{children:F(T3,{})}),F(M1,{css:Z3,onClick:s,className:ca.btnRefresh,refreshHotkeyEnabled:t}),F(wh,{onClick:r})]}),F("div",{className:K(sn.modalBody,ca.modalBody),ref:n,children:F($1,{ref:i,shortcutEnabled:t,onScrollToTop:l,infiteScrollUseWindow:!1,scrollerRef:n})})]})}),Rh=Ur` display: flex; align-items: center; justify-content: center; `,xm={btn:Ur` padding: 0; width: 32px; height: 32px; border-radius: 50%; ${Rh} `,icon:Ur` svg { width: 14px; height: 14px; } `},ci=ts({modalFeedVisible:et.initialShowMore,modalConfigVisible:!1}),O1=function(){return ko(ci)},J3=()=>{ci.modalFeedVisible=!0;},ej=()=>{ci.modalFeedVisible=!1;},tj=()=>{ci.modalConfigVisible=!0;},rj=()=>{ci.modalConfigVisible=!1;};function T1({onRefresh:e,refreshHotkeyEnabled:t}){const{accessKey:r,pureRecommend:n,usePcDesktopApi:i}=_n(),{modalFeedVisible:o,modalConfigVisible:a}=ko(ci);Xt(["shift.comma"],c=>{Rc()||(ci.modalConfigVisible=!ci.modalConfigVisible);},{exactMatch:!0});const[s,l]=P1();return ee(nr,{children:[ee("div",{ref:s,className:"area-header",css:[Ur` margin-bottom: 0; height: 50px; `,n&&Ur` position: sticky; top: ${Eg}px; z-index: 1000; `,n&&l&&Ur` background-color: var(--bg1_float); box-shadow: 0 2px 4px rgb(0 0 0 / 8%); `,"",""],children:[ee("div",{className:"left",children:[F("a",{id:"影视",className:"the-world area-anchor","data-id":"25"}),F("svg",{className:"icon",children:F("use",{href:"#channel-cinephile"})}),F("a",{className:"title",href:"#",children:F("span",{children:"推荐"})})]}),F("div",{className:"right",children:ee(rh,{size:"small",children:[!i&&!r&&F(E1,{style:{marginLeft:5}}),F(an,{onClick:tj,css:xm.btn,children:F(Bn,{name:"Config",css:xm.icon})}),F(M1,{onClick:e,refreshHotkeyEnabled:t}),!n&&ee(an,{css:Rh,onClick:J3,children:[F("span",{children:"查看更多"}),F("svg",{css:Ur` width: 12px; height: 12px; margin-left: 2px; `,children:F("use",{href:"#widget-arrow"})})]})]})})]}),F(Q3,{show:o,onHide:ej}),F(z3,{show:a,onHide:rj})]})}const M1=f.forwardRef(function({onClick:e,className:t="",style:r,refreshHotkeyEnabled:n},i){n??(n=!0);const[o,a]=f.useState(0),s=mt(c=>(a(u=>u+360),e==null?void 0:e(c))),l=f.useRef(null);return f.useImperativeHandle(i,()=>({click(){var c;(c=l.current)==null||c.click();}}),[]),Xt("r",()=>{var c;n&&(Rc()||(c=l.current)==null||c.click());},{exactMatch:!0}),ee(an,{className:t,style:r,css:Ur` ${Rh} &.ant-btn:not(:disabled):focus-visible { outline: none; } `,ref:l,onClick:s,children:[F("svg",{style:{transform:`rotate(${o}deg)`,width:"10px",height:"10px",marginRight:5,transition:o===360?"transform .5s ease":"unset"},onTransitionEnd:()=>{a(0);},children:F("use",{href:"#widget-roll"})}),F("span",{children:"换一换"})]})}),nj={grid:Ur` /* card=299 col-gap=20 */ width: ${299*2+20}px; margin: 0 auto; `};function ij(){const{useNarrowMode:e}=_n(),{modalFeedVisible:t,modalConfigVisible:r}=O1(),n=f.useRef(null),i=mt(()=>{var a;return (a=n.current)==null?void 0:a.refresh()}),o=mt(()=>{document.documentElement.scrollTop=0;});return ee("section",{"data-area":"推荐",children:[F(T1,{onRefresh:i,refreshHotkeyEnabled:!(t||r)}),F($1,{ref:n,css:[e&&nj.grid,"",""],shortcutEnabled:!(t||r),infiteScrollUseWindow:!0,onScrollToTop:o})]})}function oj(){const e=f.useMemo(()=>new Array(20).fill(0).map(()=>crypto.randomUUID()),[]),t=Da(),r=f.useMemo(()=>({page:1}),[]),{data:n,loading:i,error:o,refresh:a}=Ny(()=>y3(r));o&&console.error(o.stack||o);const{modalConfigVisible:s,modalFeedVisible:l}=O1();return ee("section",{"data-area":"推荐",children:[F(T1,{onRefresh:a,refreshHotkeyEnabled:!(s||l)}),F("div",{className:K(Sh,WD,{[Qy]:t}),style:{marginBottom:t?30:0},children:i||o?e.map(c=>F(Il,{},c)):n.map(c=>F(Il,{item:c},c.uniqId))})]})}oc.extend(r_);(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==="/"||location.pathname==="/index.html")return aj()})();async function aj(){return Js(".adblock-tips"),py("html.gray",e=>e.classList.remove("gray")),et.pureRecommend?lj():sj()}async function sj(){const t=Date.now()+1e4;let r;for(;Date.now()<=t;){if(document.querySelector(".bili-layout > section.bili-grid")){const o=document.querySelector(".bili-layout > section.bili-grid");r=a=>o==null?void 0:o.insertAdjacentElement("afterend",a);break}if(Da()&&document.querySelector(".bili-feed4-layout")){r=o=>{var a;return (a=document.querySelector(".bili-feed4-layout"))==null?void 0:a.insertAdjacentElement("afterbegin",o)};break}await Mc(200);}if(!r){console.error(`[${ui}]: init fail`);return}const n=document.createElement("section");r(n),Nc(n).render(F(hy,{children:F(oj,{})}));}async function lj(){var i,o;Da()?((i=document.querySelector(".bili-feed4 .bili-feed4-layout"))==null||i.remove(),Js(".bili-feed4 .header-channel")):((o=document.querySelector(".bili-layout"))==null||o.remove(),Js(".bili-footer"),Js(".palette-button-wrap > .primary-btn",a=>a.innerText.includes("分区"),2e3).then(()=>{document.querySelectorAll(".palette-button-wrap .primary-btn").forEach(a=>{a.classList.remove("hidden"),a.classList.contains("top-btn")&&a.classList.remove("top-btn");});}));const e=document.createElement("div");e.classList.add(Da()?"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),Nc(r).render(F(hy,{children:F(ij,{})}));}});cj(); })(React, ReactDOM, axios, axiosGmxhrAdapter);