import{r as e,a as t,R as n,c as r,b as o,d as a,u as c,C as i,h as l,B as u,e as s,f,g as d,i as p,j as m,A as v,k as g,t as b,I as h,l as y,m as O,n as w,D as E,M as j,o as P,Z as x,p as C,q as _,s as N,v as k}from"./vendor-s2rfM_Vj.js";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function S(e){return(S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function D(e){var t=function(e,t){if("object"!=S(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=S(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==S(t)?t:t+""}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function I(e,t,n){return(t=D(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */}function T(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.includes(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.includes(n)||{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var A="object"==S(R)&&R&&R.Object===Object&&R,M=A,L="object"==("undefined"==typeof self?"undefined":S(self))&&self&&self.Object===Object&&self,z=M||L||Function("return this")(),B=z.Symbol,F=B,V=Object.prototype,H=V.hasOwnProperty,W=V.toString,G=F?F.toStringTag:void 0;var U=function(e){var t=H.call(e,G),n=e[G];try{e[G]=void 0;var r=!0}catch(a){}var o=W.call(e);return r&&(t?e[G]=n:delete e[G]),o},K=Object.prototype.toString;var Z=U,$=function(e){return K.call(e)},X=B?B.toStringTag:void 0;var q=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":X&&X in Object(e)?Z(e):$(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Y=function(e){var t=S(e);return null!=e&&("object"==t||"function"==t)},J=q,Q=Y;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ee,te=function(e){if(!Q(e))return!1;var t=J(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},ne=z["__core-js_shared__"],re=(ee=/[^.]+$/.exec(ne&&ne.keys&&ne.keys.IE_PROTO||""))?"Symbol(src)_1."+ee:"";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var oe=function(e){return!!re&&re in e},ae=Function.prototype.toString;var ce=function(e){if(null!=e){try{return ae.call(e)}catch(t){}try{return e+""}catch(t){}}return""},ie=te,le=oe,ue=Y,se=ce,fe=/^\[object .+?Constructor\]$/,de=Function.prototype,pe=Object.prototype,me=de.toString,ve=pe.hasOwnProperty,ge=RegExp("^"+me.call(ve).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var be=function(e){return!(!ue(e)||le(e))&&(ie(e)?ge:fe).test(se(e))},he=function(e,t){return null==e?void 0:e[t]};var ye=function(e,t){var n=he(e,t);return be(n)?n:void 0},Oe=ye(z,"Map");var we=
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function(e,t){return e===t||e!=e&&t!=t};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Ee=function(){this.__data__=[],this.size=0},je=we;var Pe=function(e,t){for(var n=e.length;n--;)if(je(e[n][0],t))return n;return-1},xe=Pe,Ce=Array.prototype.splice;var _e=Pe;var Ne=Pe;var ke=Pe;var Se=Ee,De=function(e){var t=this.__data__,n=xe(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ce.call(t,n,1),--this.size,!0)},Ie=function(e){var t=this.__data__,n=_e(t,e);return n<0?void 0:t[n][1]},Te=function(e){return Ne(this.__data__,e)>-1},Re=function(e,t){var n=this.__data__,r=ke(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};function Ae(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Ae.prototype.clear=Se,Ae.prototype.delete=De,Ae.prototype.get=Ie,Ae.prototype.has=Te,Ae.prototype.set=Re;var Me=Ae,Le=ye(Object,"create"),ze=Le;var Be=function(){this.__data__=ze?ze(null):{},this.size=0};var Fe=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Ve=Le,He=Object.prototype.hasOwnProperty;var We=function(e){var t=this.__data__;if(Ve){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return He.call(t,e)?t[e]:void 0},Ge=Le,Ue=Object.prototype.hasOwnProperty;var Ke=Le;var Ze=Be,$e=Fe,Xe=We,qe=function(e){var t=this.__data__;return Ge?void 0!==t[e]:Ue.call(t,e)},Ye=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Ke&&void 0===t?"__lodash_hash_undefined__":t,this};function Je(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Je.prototype.clear=Ze,Je.prototype.delete=$e,Je.prototype.get=Xe,Je.prototype.has=qe,Je.prototype.set=Ye;var Qe=Je,et=Me,tt=Oe;var nt=function(e){var t=S(e);return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var rt=function(e,t){var n=e.__data__;return nt(t)?n["string"==typeof t?"string":"hash"]:n.map},ot=rt;var at=rt;var ct=rt;var it=rt;var lt=function(){this.size=0,this.__data__={hash:new Qe,map:new(tt||et),string:new Qe}},ut=function(e){var t=ot(this,e).delete(e);return this.size-=t?1:0,t},st=function(e){return at(this,e).get(e)},ft=function(e){return ct(this,e).has(e)},dt=function(e,t){var n=it(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function pt(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}pt.prototype.clear=lt,pt.prototype.delete=ut,pt.prototype.get=st,pt.prototype.has=ft,pt.prototype.set=dt;var mt=pt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var vt=function(e){return null!=e&&"object"==S(e)},gt=q,bt=vt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ht=function(e){return bt(e)&&"[object Arguments]"==gt(e)},yt=vt,Ot=Object.prototype,wt=Ot.hasOwnProperty,Et=Ot.propertyIsEnumerable,jt=ht(function(){return arguments}())?ht:function(e){return yt(e)&&wt.call(e,"callee")&&!Et.call(e,"callee")},Pt=Array.isArray;var xt=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991},Ct=te,_t=xt;var Nt=function(e){return null!=e&&_t(e.length)&&!Ct(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var kt=function(e){return function(t){return e(t)}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var St=function(e,t){return function(n){return e(t(n))}},Dt=Object.prototype;var It,Tt,Rt,At,Mt,Lt,zt,Bt,Ft=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Dt)},Vt={exports:{}};It=Vt,Rt=z,At=function(){return!1},Mt=(Tt=Vt.exports)&&!Tt.nodeType&&Tt,Lt=Mt&&It&&!It.nodeType&&It,zt=Lt&&Lt.exports===Mt?Rt.Buffer:void 0,Bt=(zt?zt.isBuffer:void 0)||At,It.exports=Bt;var Ht=q,Wt=xt,Gt=vt,Ut={};Ut["[object Float32Array]"]=Ut["[object Float64Array]"]=Ut["[object Int8Array]"]=Ut["[object Int16Array]"]=Ut["[object Int32Array]"]=Ut["[object Uint8Array]"]=Ut["[object Uint8ClampedArray]"]=Ut["[object Uint16Array]"]=Ut["[object Uint32Array]"]=!0,Ut["[object Arguments]"]=Ut["[object Array]"]=Ut["[object ArrayBuffer]"]=Ut["[object Boolean]"]=Ut["[object DataView]"]=Ut["[object Date]"]=Ut["[object Error]"]=Ut["[object Function]"]=Ut["[object Map]"]=Ut["[object Number]"]=Ut["[object Object]"]=Ut["[object RegExp]"]=Ut["[object Set]"]=Ut["[object String]"]=Ut["[object WeakMap]"]=!1;var Kt=function(e){return Gt(e)&&Wt(e.length)&&!!Ut[Ht(e)]},Zt={exports:{}};!function(e,t){var n=A,r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r&&n.process,c=function(){try{var e=o&&o.require&&o.require("util").types;return e||a&&a.binding&&a.binding("util")}catch(t){}}();e.exports=c}(Zt,Zt.exports);var $t=Kt,Xt=kt,qt=Zt.exports,Yt=qt&&qt.isTypedArray,Jt=Yt?Xt(Yt):$t,Qt=/^(?:0|[1-9]\d*)$/;var en=function(e,t){var n=S(e);return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&Qt.test(e))&&e>-1&&e%1==0&&e<t},tn=Me;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var nn=Me,rn=Oe,on=mt;var an=Me,cn=function(){this.__data__=new tn,this.size=0},ln=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},un=function(e){return this.__data__.get(e)},sn=function(e){return this.__data__.has(e)},fn=function(e,t){var n=this.__data__;if(n instanceof nn){var r=n.__data__;if(!rn||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new on(r)}return n.set(e,t),this.size=n.size,this};function dn(e){var t=this.__data__=new an(e);this.size=t.size}dn.prototype.clear=cn,dn.prototype.delete=ln,dn.prototype.get=un,dn.prototype.has=sn,dn.prototype.set=fn;var pn=dn,mn=z.Uint8Array;var vn=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r},gn=jt,bn=Pt,hn=Vt.exports,yn=en,On=Jt,wn=Object.prototype.hasOwnProperty;var En=function(e,t){var n=bn(e),r=!n&&gn(e),o=!n&&!r&&hn(e),a=!n&&!r&&!o&&On(e),c=n||r||o||a,i=c?vn(e.length,String):[],l=i.length;for(var u in e)!t&&!wn.call(e,u)||c&&("length"==u||o&&("offset"==u||"parent"==u)||a&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||yn(u,l))||i.push(u);return i},jn=ye,Pn=function(){try{var e=jn(Object,"defineProperty");return e({},"",{}),e}catch(t){}}(),xn=Pn;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Cn=function(e,t,n){"__proto__"==t&&xn?xn(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n},_n=Cn,Nn=we,kn=Object.prototype.hasOwnProperty;var Sn=function(e,t,n){var r=e[t];kn.call(e,t)&&Nn(r,n)&&(void 0!==n||t in e)||_n(e,t,n)},Dn={exports:{}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */!function(e,t){var n=z,r=t&&!t.nodeType&&t,o=r&&e&&!e.nodeType&&e,a=o&&o.exports===r?n.Buffer:void 0,c=a?a.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=c?c(n):new e.constructor(n);return e.copy(r),r}}(Dn,Dn.exports);var In=mn;var Tn=function(e){var t=new e.constructor(e.byteLength);return new In(t).set(new In(e)),t},Rn=Tn;var An=function(e,t){var n=t?Rn(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)};var Mn=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t},Ln=Y,zn=Object.create,Bn=function(){function e(){}return function(t){if(!Ln(t))return{};if(zn)return zn(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}(),Fn=St(Object.getPrototypeOf,Object),Vn=Bn,Hn=Fn,Wn=Ft;var Gn=function(e){return"function"!=typeof e.constructor||Wn(e)?{}:Vn(Hn(e))},Un=Sn,Kn=Cn;var Zn=function(e,t,n,r){var o=!n;n||(n={});for(var a=-1,c=t.length;++a<c;){var i=t[a],l=r?r(n[i],e[i],i,n,e):void 0;void 0===l&&(l=e[i]),o?Kn(n,i,l):Un(n,i,l)}return n};var $n=Y,Xn=Ft,qn=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t},Yn=Object.prototype.hasOwnProperty;var Jn=En,Qn=function(e){if(!$n(e))return qn(e);var t=Xn(e),n=[];for(var r in e)("constructor"!=r||!t&&Yn.call(e,r))&&n.push(r);return n},er=Nt;var tr=function(e){return er(e)?Jn(e,!0):Qn(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var nr=function(e){return e};var rr=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)},or=Math.max;var ar=function(e,t,n){return t=or(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,a=or(r.length-t,0),c=Array(a);++o<a;)c[o]=r[t+o];o=-1;for(var i=Array(t+1);++o<t;)i[o]=r[o];return i[t]=n(c),rr(e,this,i)}};var cr=function(e){return function(){return e}},ir=Pn,lr=ir?function(e,t){return ir(e,"toString",{configurable:!0,enumerable:!1,value:cr(t),writable:!0})}:nr,ur=Date.now;var sr=function(e){var t=0,n=0;return function(){var r=ur(),o=16-(r-n);if(n=r,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(lr),fr=Nt,dr=vt;var pr=function(e){return dr(e)&&fr(e)},mr=nr,vr=ar,gr=sr;var br=function(e,t){return gr(vr(e,t,mr),e+"")},hr=q,yr=Fn,Or=vt,wr=Function.prototype,Er=Object.prototype,jr=wr.toString,Pr=Er.hasOwnProperty,xr=jr.call(Object);
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Cr=function(e){if(!Or(e)||"[object Object]"!=hr(e))return!1;var t=yr(e);if(null===t)return!0;var n=Pr.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&jr.call(n)==xr},_r=we,Nr=Nt,kr=en,Sr=Y;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Dr=function(e,t,n){if(!Sr(n))return!1;var r=S(t);return!!("number"==r?Nr(n)&&kr(t,n.length):"string"==r&&t in n)&&_r(n[t],e)},Ir=Cn,Tr=we;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Rr=function(e,t,n){(void 0!==n&&!Tr(e[t],n)||void 0===n&&!(t in e))&&Ir(e,t,n)};var Ar=function(e){return function(t,n,r){for(var o=-1,a=Object(t),c=r(t),i=c.length;i--;){var l=c[e?i:++o];if(!1===n(a[l],l,a))break}return t}}();var Mr=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]},Lr=Zn,zr=tr;var Br=Rr,Fr=Dn.exports,Vr=An,Hr=Mn,Wr=Gn,Gr=jt,Ur=Pt,Kr=pr,Zr=Vt.exports,$r=te,Xr=Y,qr=Cr,Yr=Jt,Jr=Mr,Qr=function(e){return Lr(e,zr(e))};var eo=pn,to=Rr,no=Ar,ro=function(e,t,n,r,o,a,c){var i=Jr(e,n),l=Jr(t,n),u=c.get(l);if(u)Br(e,n,u);else{var s=a?a(i,l,n+"",e,t,c):void 0,f=void 0===s;if(f){var d=Ur(l),p=!d&&Zr(l),m=!d&&!p&&Yr(l);s=l,d||p||m?Ur(i)?s=i:Kr(i)?s=Hr(i):p?(f=!1,s=Fr(l,!0)):m?(f=!1,s=Vr(l,!0)):s=[]:qr(l)||Gr(l)?(s=i,Gr(i)?s=Qr(i):Xr(i)&&!$r(i)||(s=Wr(l))):f=!1}f&&(c.set(l,s),o(s,l,r,a,c),c.delete(l)),Br(e,n,s)}},oo=Y,ao=tr,co=Mr;var io=function e(t,n,r,o,a){t!==n&&no(n,(function(c,i){if(a||(a=new eo),oo(c))ro(t,n,i,r,e,o,a);else{var l=o?o(co(t,i),c,i+"",t,n,a):void 0;void 0===l&&(l=c),to(t,i,l)}}),ao)},lo=br,uo=Dr;var so=io,fo=function(e){return lo((function(t,n){var r=-1,o=n.length,a=o>1?n[o-1]:void 0,c=o>2?n[2]:void 0;for(a=e.length>3&&"function"==typeof a?(o--,a):void 0,c&&uo(n[0],n[1],c)&&(a=o<3?void 0:a,o=1),t=Object(t);++r<o;){var i=n[r];i&&e(t,i,r,a)}return t}))}((function(e,t,n){so(e,t,n)}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function po(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var mo=function(e){return e.ripple="ripple",e.expand="expand",e.fade="fade",e}(mo||{}),vo={globalConfig:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?po(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):po(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({animation:{include:["ripple","expand","fade"],exclude:[]},classPrefix:"t"},fo({},{pagination:{itemsPerPage:"{size} 条/页",jumpTo:"跳至",page:"页",total:"共 {total} 条数据"},cascader:{empty:"暂无数据",loadingText:"加载中",placeholder:"请选择"},calendar:{yearSelection:"{year} 年",monthSelection:"{month} 月",yearRadio:"年",monthRadio:"月",hideWeekend:"隐藏周末",showWeekend:"显示周末",today:"今天",thisMonth:"本月",week:"一,二,三,四,五,六,日",cellMonth:"1 月,2 月,3 月,4 月,5 月,6 月,7 月,8 月,9 月,10 月,11 月,12 月"},transfer:{title:"{checked} / {total} 项",empty:"暂无数据",placeholder:"请输入关键词搜索"},timePicker:{dayjsLocale:"zh-cn",now:"此刻",confirm:"确定",anteMeridiem:"上午",postMeridiem:"下午",placeholder:"选择时间"},dialog:{confirm:"确认",cancel:"取消"},drawer:{confirm:"确认",cancel:"取消"},popconfirm:{confirm:{content:"确定"},cancel:{content:"取消"}},table:{empty:"暂无数据",loadingText:"正在加载中，请稍后",loadingMoreText:"点击加载更多",filterInputPlaceholder:"请输入内容（无默认值）",sortAscendingOperationText:"点击升序",sortCancelOperationText:"点击取消排序",sortDescendingOperationText:"点击降序",clearFilterResultButtonText:"清空筛选",columnConfigButtonText:"列配置",columnConfigTitleText:"表格列配置",columnConfigDescriptionText:"请选择需要在表格中显示的数据列",confirmText:"确认",cancelText:"取消",resetText:"重置",selectAllText:"全选",searchResultText:"搜索“{result}”，找到 {count} 条结果"},select:{empty:"暂无数据",loadingText:"加载中",placeholder:"请选择"},tree:{empty:"暂无数据"},treeSelect:{empty:"暂无数据",loadingText:"加载中",placeholder:"请选择"},datePicker:{dayjsLocale:"zh-cn",placeholder:{date:"请选择日期",month:"请选择月份",year:"请选择年份",quarter:"请选择季度",week:"请选择周"},weekdays:["一","二","三","四","五","六","日"],months:["1 月","2 月","3 月","4 月","5 月","6 月","7 月","8 月","9 月","10 月","11 月","12 月"],quarters:["一季度","二季度","三季度","四季度"],rangeSeparator:" - ",direction:"ltr",format:"YYYY-MM-DD",dayAriaLabel:"日",weekAbbreviation:"周",yearAriaLabel:"年",monthAriaLabel:"月",confirm:"确定",selectTime:"选择时间",selectDate:"选择日期",nextYear:"下一年",preYear:"上一年",nextMonth:"下个月",preMonth:"上个月",preDecade:"上个十年",nextDecade:"下个十年",now:"当前"},upload:{sizeLimitMessage:"文件大小不能超过 {sizeLimit}",cancelUploadText:"取消上传",triggerUploadText:{fileInput:"选择文件",image:"点击上传图片",normal:"点击上传",reupload:"重新选择",continueUpload:"继续选择",delete:"删除",uploading:"上传中"},dragger:{dragDropText:"释放鼠标",draggingText:"拖拽到此区域",clickAndDragText:"点击上方“选择文件”或将文件拖拽到此区域"},file:{fileNameText:"文件名",fileSizeText:"文件大小",fileStatusText:"状态",fileOperationText:"操作",fileOperationDateText:"上传日期"},progress:{uploadingText:"上传中",waitingText:"待上传",failText:"上传失败",successText:"上传成功"}},form:{errorMessage:{date:"请输入正确的${name}",url:"请输入正确的${name}",required:"${name}必填",whitespace:"${name}不能为空",max:"${name}字符长度不能超过 ${validate} 个字符，一个中文等于两个字符",min:"${name}字符长度不能少于 ${validate} 个字符，一个中文等于两个字符",len:"${name}字符长度必须是 ${validate}",enum:"${name}只能是${validate}等",idcard:"请输入正确的${name}",telnumber:"请输入正确的${name}",pattern:"请输入正确的${name}",validator:"${name}不符合要求",boolean:"${name}数据类型必须是布尔类型",number:"${name}必须是数字"},colonText:"："},input:{placeholder:"请输入"},list:{loadingText:"正在加载中，请稍等",loadingMoreText:"点击加载更多"},alert:{expandText:"展开更多",collapseText:"收起"},anchor:{copySuccessText:"链接复制成功",copyText:"复制链接"},colorPicker:{swatchColorTitle:"系统预设颜色",recentColorTitle:"最近使用颜色",clearConfirmText:"确定清空最近使用的颜色吗？",singleColor:"单色",gradientColor:"渐变"},guide:{finishButtonProps:{content:"完成",theme:"primary"},nextButtonProps:{content:"下一步",theme:"primary"},skipButtonProps:{content:"跳过",theme:"default"},prevButtonProps:{content:"上一步",theme:"default"}},image:{errorText:"图片无法显示",loadingText:"图片加载中"},imageViewer:{errorText:"图片加载失败，可尝试重新加载",mirrorTipText:"镜像",rotateTipText:"旋转",originalSizeTipText:"原始大小"},typography:{expandText:"展开",collapseText:"收起",copiedText:"复制成功"},rate:{rateText:["极差","失望","一般","满意","惊喜"]},empty:{titleText:{maintenance:"建设中",success:"成功",fail:"失败",empty:"暂无数据",networkError:"网络错误"}},descriptions:{colonText:"："}},{classPrefix:"t",animation:{include:["ripple","expand","fade"],exclude:[]},calendar:{firstDayOfWeek:1,fillWithZero:!0,controllerConfig:void 0},icon:{},input:{autocomplete:""},dialog:{closeOnEscKeydown:!0,closeOnOverlayClick:!0,confirmBtnTheme:{default:"primary",info:"primary",warning:"primary",danger:"primary",success:"primary"}},message:{},popconfirm:{confirmBtnTheme:{default:"primary",warning:"primary",danger:"primary"}},table:{expandIcon:void 0,sortIcon:void 0,filterIcon:void 0,treeExpandAndFoldIcon:void 0,hideSortTips:!1,size:"medium"},select:{clearIcon:void 0,filterable:!1},drawer:{closeOnEscKeydown:!0,closeOnOverlayClick:!0,size:"small"},tree:{folderIcon:void 0},datePicker:{firstDayOfWeek:1},steps:{checkIcon:void 0,errorIcon:void 0},tag:{closeIcon:void 0},form:{requiredMark:void 0},empty:{titleText:{maintenance:void 0,success:void 0,fail:void 0,empty:void 0,networkError:void 0},image:{maintenance:void 0,success:void 0,fail:void 0,empty:void 0,networkError:void 0}}}))},go=e.createContext(vo),bo=function(){return e.useContext(go).globalConfig};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function ho(t,n){return e.useMemo((function(){var e=Object.assign({},t);return Object.keys(n).forEach((function(t){void 0===e[t]&&(e[t]=n[t])})),e}),[t,n])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function yo(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Oo(e,t){if(e){if("string"==typeof e)return yo(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?yo(e,t):void 0}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function wo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,c,i=[],l=!0,u=!1;try{if(a=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=a.call(n)).done)&&(i.push(r.value),i.length!==t);l=!0);}catch(s){u=!0,o=s}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(u)throw o}}return i}}(e,t)||Oo(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Eo=q,jo=Pt,Po=vt;var xo=function(e){return"string"==typeof e||!jo(e)&&Po(e)&&"[object String]"==Eo(e)},Co=!("undefined"==typeof window||!window.document||!window.document.createElement),_o=Co&&document.addEventListener?function(e,t,n){e&&t&&n&&e.addEventListener(t,n,!1)}:function(e,t,n){e&&t&&n&&e.attachEvent("on".concat(t),n)},No=Co&&document.removeEventListener?function(e,t,n){e&&t&&e.removeEventListener(t,n,!1)}:function(e,t,n){e&&t&&e.detachEvent("on".concat(t),n)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function ko(e,t){if(!e||!t)return!1;if(-1!==t.indexOf(" "))throw new Error("className should not contain space.");return e.classList?e.classList.contains(t):" ".concat(e.className," ").indexOf(" ".concat(t," "))>-1}var So=e.forwardRef((function(n,r){var o=n.attach,a=n.children,c=n.triggerNode,i=bo().classPrefix,l=e.useMemo((function(){if(!Co)return null;var e=document.createElement("div");return e.className="".concat(i,"-portal-wrapper"),e}),[i]);return e.useEffect((function(){var e,t=
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function(e,t){return Co?("string"==typeof e&&(n=document.querySelector(e)),"function"==typeof e&&(n=e(t)),"object"===S(e)&&e instanceof window.HTMLElement&&(n=e),n&&1===n.nodeType?n:document.body):null;var n}(o,c);return null==t||null===(e=t.appendChild)||void 0===e||e.call(t,l),function(){var e;null==t||null===(e=t.removeChild)||void 0===e||e.call(t,l)}}),[l,o,c]),e.useImperativeHandle(r,(function(){return l})),Co?t.createPortal(a,l):null}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Do(){var t=wo(e.useState(),2),n=t[0],r=t[1];return e.useCallback((function(e){e&&r(e)}),[]),[n,r]}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Io(e,t){Object.keys(t).forEach((function(n){e.style[n]=t[n]}))}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function To(e){return function(e){if(Array.isArray(e))return yo(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Oo(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */So.displayName="Portal";var Ro=function(e){return null===e};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Ao=function(e){return void 0===e},Mo=q,Lo=vt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var zo=function(e){return"number"==typeof e||Lo(e)&&"[object Number]"==Mo(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Bo(){if("undefined"==typeof navigator||!navigator)return Number.MAX_SAFE_INTEGER;var e=navigator.userAgent,t=e.indexOf("compatible")>-1&&e.indexOf("MSIE")>-1,n=e.indexOf("Trident")>-1&&e.indexOf("rv:11.0")>-1;if(t){var r=new RegExp("MSIE (\\d+\\.\\d+);"),o=e.match(r);if(!o)return-1;var a=parseFloat(o[1]);return a<7?6:a}return n?11:Number.MAX_SAFE_INTEGER}function Fo(e,t){var n=zo(t);if(!e||0===e.length)return n?{length:0,characters:e}:0;for(var r=0,o=0;o<e.length;o++){var a=0;if(a=e.charCodeAt(o)>127?2:1,n&&r+a>t)return{length:r,characters:e.slice(0,o)};r+=a}return n?{length:r,characters:e}:r}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Vo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ho(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vo(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Wo=function(){var t=bo().classPrefix,o=wo(Do(),2),a=o[0],c=o[1],i="".concat(t,"-loading__gradient");return e.useEffect((function(){!function(e){var t,n,r,o={};if(e&&"undefined"!=typeof window){var a=null===(t=window)||void 0===t||null===(n=t.getComputedStyle)||void 0===n?void 0:n.call(t,e),c=a.color,i=a.fontSize,l=null===(r=window)||void 0===r||null===(r=r.navigator)||void 0===r?void 0:r.userAgent,u=/Safari/.test(l)&&!/Chrome/.test(l),s=/(?=.*iPhone)[?=.*MicroMessenger]/.test(l)&&!/Chrome/.test(l);if((u||s)&&(o={transformOrigin:"0px 0px",transform:"scale(".concat(parseInt(i,10)/12,")")}),c&&Bo()>11){var f=c.match(/[\d.]+/g),d=f?"rgba(".concat(f[0],", ").concat(f[1],", ").concat(f[2],", 0)"):"";Io(e,Ho(Ho({},o),{},{background:"conic-gradient(from 90deg at 50% 50%,".concat(d," 0deg, ").concat(c," 360deg)")}))}else Io(e,Ho(Ho({},o),{},{background:""}))}}(a)}),[a]),n.createElement("svg",{className:r(i,"".concat(t,"-icon-loading")),viewBox:"0 0 12 12",version:"1.1",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg"},n.createElement("foreignObject",{x:"0",y:"0",width:"12",height:"12"},n.createElement("div",{className:"".concat(i,"-conic"),ref:c})))},Go={delay:0,fullscreen:!1,indicator:!0,inheritColor:!1,loading:!0,preventScrollThrough:!0,showOverlay:!0,size:"medium"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Uo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ko(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Uo(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Uo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Zo=function(t){var o=ho(t,Go),a=o.attach,c=o.indicator,i=o.text,l=o.loading,u=o.size,s=o.delay,f=o.fullscreen,d=o.preventScrollThrough,p=o.showOverlay,m=o.content,v=o.children,g=o.inheritColor,b=o.zIndex,h=o.className,y=o.style,O=wo(e.useState((function(){return!s&&l})),2),w=O[0],E=O[1],j=bo().classPrefix,P="".concat(j,"-loading"),x="".concat(j,"-loading--center"),C="".concat(j,"-loading--inherit-color"),_="".concat(j,"-loading--full"),N="".concat(j,"-loading__fullscreen"),k="".concat(j,"-loading--lock"),S="".concat(j,"-loading__overlay"),D="".concat(j,"-loading__parent"),T="".concat(j,"-loading__text");e.useEffect((function(){var e;return s&&l?e=setTimeout((function(){E(l)}),s):E(l),function(){clearTimeout(e)}}),[s,l]);var R=e.useMemo((function(){var e={};return void 0!==b&&(e.zIndex=b),["small","medium","large"].includes(u)||(e.fontSize=u),e}),[u,b]),A={large:"".concat(j,"-size-l"),small:"".concat(j,"-size-s"),medium:"".concat(j,"-size-m")},M=r(x,A[u],I({},C,g),h);e.useEffect((function(){return d&&f&&Co&&l&&function(e,t){if(e){for(var n=e.className,r=(t||"").split(" "),o=0,a=r.length;o<a;o++){var c=r[o];c&&(e.classList?e.classList.add(c):ko(e,c)||(n+=" ".concat(c)))}e.classList||(e.className=n)}}(document.body,k),function(){!function(e,t){if(e&&t){for(var n=t.split(" "),r=" ".concat(e.className," "),o=0,a=n.length;o<a;o++){var c=n[o];c&&(e.classList?e.classList.remove(c):ko(e,c)&&(r=r.replace(" ".concat(c," ")," ")))}e.classList||(e.className=(r||"").replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g,""))}}(document.body,k)}}),[l,d,f,k]);var L=function(){var e=n.createElement(Wo,null);return c&&"boolean"!=typeof c&&(e=c),n.createElement(n.Fragment,null,c?e:null,i?n.createElement("div",{className:T},i):null)};return f?l?n.createElement("div",{className:r(P,N,x,S),style:Ko(Ko({},R),y)},n.createElement("div",{className:M},L())):null:m||v?n.createElement("div",{className:D,style:y},m||v,w?n.createElement("div",{className:r(P,M,_,I({},S,p)),style:R},L()):null):a?n.createElement(So,{attach:a},l?n.createElement("div",{className:r(P,M,_,I({},S,p)),style:Ko(Ko({},R),y)},L()):null):l?n.createElement("div",{className:r(P,M),style:Ko(Ko({},R),y)},L()):null};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function $o(e,t,n,r,o,a,c){try{var i=e[a](c),l=i.value}catch(u){return void n(u)}i.done?t(l):Promise.resolve(l).then(r,o)}Zo.displayName="Loading";var Xo={exports:{}},qo={exports:{}};!function(e){function t(n){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports}(qo),function(e){var t=qo.exports.default;function n(){
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
e.exports=n=function(){return o},e.exports.__esModule=!0,e.exports.default=e.exports;var r,o={},a=Object.prototype,c=a.hasOwnProperty,i=Object.defineProperty||function(e,t,n){e[t]=n.value},l="function"==typeof Symbol?Symbol:{},u=l.iterator||"@@iterator",s=l.asyncIterator||"@@asyncIterator",f=l.toStringTag||"@@toStringTag";function d(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{d({},"")}catch(A){d=function(e,t,n){return e[t]=n}}function p(e,t,n,r){var o=t&&t.prototype instanceof O?t:O,a=Object.create(o.prototype),c=new T(r||[]);return i(a,"_invoke",{value:k(e,n,c)}),a}function m(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(r){return{type:"throw",arg:r}}}o.wrap=p;var v="suspendedStart",g="suspendedYield",b="executing",h="completed",y={};function O(){}function w(){}function E(){}var j={};d(j,u,(function(){return this}));var P=Object.getPrototypeOf,x=P&&P(P(R([])));x&&x!==a&&c.call(x,u)&&(j=x);var C=E.prototype=O.prototype=Object.create(j);function _(e){["next","throw","return"].forEach((function(t){d(e,t,(function(e){return this._invoke(t,e)}))}))}function N(e,n){function r(o,a,i,l){var u=m(e[o],e,a);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==t(f)&&c.call(f,"__await")?n.resolve(f.__await).then((function(e){r("next",e,i,l)}),(function(e){r("throw",e,i,l)})):n.resolve(f).then((function(e){s.value=e,i(s)}),(function(e){return r("throw",e,i,l)}))}l(u.arg)}var o;i(this,"_invoke",{value:function(e,t){function a(){return new n((function(n,o){r(e,t,n,o)}))}return o=o?o.then(a,a):a()}})}function k(e,t,n){var o=v;return function(a,c){if(o===b)throw Error("Generator is already running");if(o===h){if("throw"===a)throw c;return{value:r,done:!0}}for(n.method=a,n.arg=c;;){var i=n.delegate;if(i){var l=S(i,n);if(l){if(l===y)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===v)throw o=h,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=b;var u=m(e,t,n);if("normal"===u.type){if(o=n.done?h:g,u.arg===y)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(o=h,n.method="throw",n.arg=u.arg)}}}function S(e,t){var n=t.method,o=e.iterator[n];if(o===r)return t.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=r,S(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var a=m(o,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,y;var c=a.arg;return c?c.done?(t[e.resultName]=c.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=r),t.delegate=null,y):c:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,y)}function D(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function I(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function T(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(D,this),this.reset(!0)}function R(e){if(e||""===e){var n=e[u];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function t(){for(;++o<e.length;)if(c.call(e,o))return t.value=e[o],t.done=!1,t;return t.value=r,t.done=!0,t};return a.next=a}}throw new TypeError(t(e)+" is not iterable")}return w.prototype=E,i(C,"constructor",{value:E,configurable:!0}),i(E,"constructor",{value:w,configurable:!0}),w.displayName=d(E,f,"GeneratorFunction"),o.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},o.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,E):(e.__proto__=E,d(e,f,"GeneratorFunction")),e.prototype=Object.create(C),e},o.awrap=function(e){return{__await:e}},_(N.prototype),d(N.prototype,s,(function(){return this})),o.AsyncIterator=N,o.async=function(e,t,n,r,a){void 0===a&&(a=Promise);var c=new N(p(e,t,n,r),a);return o.isGeneratorFunction(t)?c:c.next().then((function(e){return e.done?e.value:c.next()}))},_(C),d(C,f,"Generator"),d(C,u,(function(){return this})),d(C,"toString",(function(){return"[object Generator]"})),o.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},o.values=R,T.prototype={constructor:T,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(I),!e)for(var t in this)"t"===t.charAt(0)&&c.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=r)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function n(n,o){return i.type="throw",i.arg=e,t.next=n,o&&(t.method="next",t.arg=r),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],i=a.completion;if("root"===a.tryLoc)return n("end");if(a.tryLoc<=this.prev){var l=c.call(a,"catchLoc"),u=c.call(a,"finallyLoc");if(l&&u){if(this.prev<a.catchLoc)return n(a.catchLoc,!0);if(this.prev<a.finallyLoc)return n(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return n(a.catchLoc,!0)}else{if(!u)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return n(a.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&c.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),y},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),I(n),y}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;I(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:R(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=r),y}},o}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports}(Xo),Xo.exports;var Yo=Xo.exports(),Jo=Yo;try{regeneratorRuntime=Yo}catch(Hy){"object"===("undefined"==typeof globalThis?"undefined":S(globalThis))?globalThis.regeneratorRuntime=Yo:Function("r","regeneratorRuntime = r")(Yo)}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Qo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var ea,ta=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qo(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},o),na=ta.version,ra=ta.render;ta.unmountComponentAtNode;try{Number((na||"").split(".")[0])>=18&&(ea=ta.createRoot)}catch(Wy){}function oa(e){var t=ta.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&"object"===S(t)&&(t.usingClientEntryPoint=e)}var aa="__td_react_root__";function ca(e,t){ea?function(e,t){oa(!0);var n=t[aa]||ea(t);oa(!1),n.render(e),t[aa]=n}(e,t):function(e,t){ra(e,t)}(e,t)}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ia=Zo,la=q,ua=vt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var sa=function(e){return"symbol"==S(e)||ua(e)&&"[object Symbol]"==la(e)},fa=/\s/;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var da=function(e){for(var t=e.length;t--&&fa.test(e.charAt(t)););return t},pa=/^\s+/;var ma=function(e){return e?e.slice(0,da(e)+1).replace(pa,""):e},va=Y,ga=sa,ba=/^[-+]0x[0-9a-f]+$/i,ha=/^0b[01]+$/i,ya=/^0o[0-7]+$/i,Oa=parseInt;var wa=z,Ea=Y,ja=function(){return wa.Date.now()},Pa=function(e){if("number"==typeof e)return e;if(ga(e))return NaN;if(va(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=va(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=ma(e);var n=ha.test(e);return n||ya.test(e)?Oa(e.slice(2),n?2:8):ba.test(e)?NaN:+e},xa=Math.max,Ca=Math.min;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var _a=function(e,t,n){var r,o,a,c,i,l,u=0,s=!1,f=!1,d=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function p(t){var n=r,a=o;return r=o=void 0,u=t,c=e.apply(a,n)}function m(e){var n=e-l;return void 0===l||n>=t||n<0||f&&e-u>=a}function v(){var e=ja();if(m(e))return g(e);i=setTimeout(v,function(e){var n=t-(e-l);return f?Ca(n,a-(e-u)):n}(e))}function g(e){return i=void 0,d&&r?p(e):(r=o=void 0,c)}function b(){var e=ja(),n=m(e);if(r=arguments,o=this,l=e,n){if(void 0===i)return function(e){return u=e,i=setTimeout(v,t),s?p(e):c}(l);if(f)return clearTimeout(i),i=setTimeout(v,t),p(l)}return void 0===i&&(i=setTimeout(v,t)),c}return t=Pa(t)||0,Ea(n)&&(s=!!n.leading,a=(f="maxWait"in n)?xa(Pa(n.maxWait)||0,t):a,d="trailing"in n?!!n.trailing:d),b.cancel=function(){void 0!==i&&clearTimeout(i),u=0,r=l=o=i=void 0},b.flush=function(){return void 0===i?c:g(ja())},b};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Na=function(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(o);++r<o;)a[r]=e[r+t];return a},ka=Na;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Sa=function(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:ka(e,t,n)},Da=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");var Ia=function(e){return Da.test(e)};var Ta=function(e){return e.split("")},Ra="\\ud800-\\udfff",Aa="["+Ra+"]",Ma="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",La="\\ud83c[\\udffb-\\udfff]",za="[^"+Ra+"]",Ba="(?:\\ud83c[\\udde6-\\uddff]){2}",Fa="[\\ud800-\\udbff][\\udc00-\\udfff]",Va="(?:"+Ma+"|"+La+")"+"?",Ha="[\\ufe0e\\ufe0f]?",Wa=Ha+Va+("(?:\\u200d(?:"+[za,Ba,Fa].join("|")+")"+Ha+Va+")*"),Ga="(?:"+[za+Ma+"?",Ma,Ba,Fa,Aa].join("|")+")",Ua=RegExp(La+"(?="+La+")|"+Ga+Wa,"g");var Ka=Ta,Za=Ia,$a=function(e){return e.match(Ua)||[]};var Xa=function(e){return Za(e)?$a(e):Ka(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var qa=function(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o},Ya=qa,Ja=Pt,Qa=sa,ec=B?B.prototype:void 0,tc=ec?ec.toString:void 0;var nc=function e(t){if("string"==typeof t)return t;if(Ja(t))return Ya(t,e)+"";if(Qa(t))return tc?tc.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n},rc=nc;var oc=function(e){return null==e?"":rc(e)},ac=Sa,cc=Ia,ic=Xa,lc=oc;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var uc=function(e){return function(t){t=lc(t);var n=cc(t)?ic(t):void 0,r=n?n[0]:t.charAt(0),o=n?ac(n,1).join(""):t.slice(1);return r[e]()+o}}("toUpperCase"),sc=function(){},fc=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=Reflect.has(t,n),c=t[n],i=o["default".concat(uc(n))]||t["default".concat(uc(n))],l=wo(e.useState(i),2),u=l[0],s=l[1];return a?[c,r||sc]:[u,function(e){s(e);for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];null==r||r.apply(void 0,[e].concat(n))}]};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function dc(){var t=bo().animation,n=mo.expand,r=mo.ripple,o=mo.fade,a=e.useCallback((function(e){var n,r;return t&&!(null!==(n=t.exclude)&&void 0!==n&&n.includes(e))&&(null===(r=t.include)||void 0===r?void 0:r.includes(e))}),[t]);return{keepExpand:a(n),keepRipple:a(r),keepFade:a(o)}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function pc(e){return e.current&&"object"===S(e.current)&&"currentElement"in e.current?e.current.currentElement:e.current}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function mc(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=0,r=t;n<r.length;n++){var o=r[n];"function"==typeof o?o(e):o&&(o.current=e)}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function vc(t){var o=t.content,c=t.disabled,i=t.trigger,l=t.visible,u=t.onVisibleChange,s=t.triggerRef,f=t.delay,d=e.useRef(!1),p=e.useRef(0),m=e.useRef(null),v=e.useRef("t-popup--".concat(Math.random().toFixed(10))),g=e.useRef(!1),b=e.useMemo((function(){return!c&&(!c&&0===o||o)}),[c,o]),h=wo(e.useMemo((function(){return Array.isArray(f)?f:[f,f]}),[f]),2),y=h[0],O=void 0===y?0:y,w=h[1],E=void 0===w?0:w;function j(e){var t=e.delay,n=e.callback;t?(clearTimeout(m.current),m.current=setTimeout(n,t)):n()}function P(e){if(!b)return{};var t,n,o,c,f={className:l?r(e.props.className,"t-popup-open"):e.props.className,onMouseDown:function(t){var n,r;"mousedown"===i&&j({delay:l?O:E,callback:function(){return u(!l,{e:t,trigger:"trigger-element-mousedown"})}}),null===(n=(r=e.props).onMouseDown)||void 0===n||n.call(r,t)},onClick:function(t){var n,r;"click"===i&&j({delay:l?O:E,callback:function(){return u(!l,{e:t,trigger:"trigger-element-click"})}}),null===(n=(r=e.props).onClick)||void 0===n||n.call(r,t)},onTouchStart:function(t){var n,r;"hover"!==i&&"mousedown"!==i||(g.current=!1,j({delay:O,callback:function(){return u(!0,{e:t,trigger:"trigger-element-hover"})}})),null===(n=(r=e.props).onTouchStart)||void 0===n||n.call(r,t)},onMouseEnter:function(t){var n,r;"hover"===i&&(g.current=!1,j({delay:O,callback:function(){return u(!0,{e:t,trigger:"trigger-element-hover"})}})),null===(n=(r=e.props).onMouseEnter)||void 0===n||n.call(r,t)},onMouseLeave:function(t){var n,r;"hover"===i&&(g.current=!1,j({delay:E,callback:function(){return u(!1,{e:t,trigger:"trigger-element-hover"})}})),null===(n=(r=e.props).onMouseLeave)||void 0===n||n.call(r,t)},onFocus:function(){var t,n;"focus"===i&&j({delay:O,callback:function(){return u(!0,{trigger:"trigger-element-focus"})}});for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];null===(t=(n=e.props).onFocus)||void 0===t||t.call.apply(t,[n].concat(o))},onBlur:function(){var t,n;"focus"===i&&j({delay:O,callback:function(){return u(!1,{trigger:"trigger-element-blur"})}});for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];null===(t=(n=e.props).onBlur)||void 0===t||t.call.apply(t,[n].concat(o))},onContextMenu:function(t){var n,r;"context-menu"===i&&(t.preventDefault(),j({delay:O,callback:function(){return u(!0,{e:t,trigger:"context-menu"})}})),null===(n=(r=e.props).onContextMenu)||void 0===n||n.call(r,t)},onKeyDown:function(t){var n,r;"Escape"===(null==t?void 0:t.key)&&j({delay:E,callback:function(){return u(!1,{e:t,trigger:"keydown-esc"})}}),null===(n=(r=e.props).onKeyDown)||void 0===n||n.call(r,t)}};return t=e,("function"!=typeof(c=a.isMemo(t)?t.type.type:t.type)||null!==(n=c.prototype)&&void 0!==n&&n.render)&&("function"!=typeof t||null!==(o=t.prototype)&&void 0!==o&&o.render)?f.ref=mc(s,e.ref):f["data-popup"]=v.current,f}return e.useEffect((function(){if(b){var e=function(e){var t,n;null!==(t=pc(s))&&void 0!==t&&null!==(n=t.contains)&&void 0!==n&&n.call(t,e.target)||d.current||l&&u(!1,{e:e,trigger:"document"})};return _o(document,"mousedown",e),_o(document,"touchend",e),function(){No(document,"mousedown",e),No(document,"touchend",e)}}}),[b,l,u,s]),{getTriggerNode:function(t){var r=e.isValidElement(t)&&!a.isFragment(t)?t:n.createElement("span",{className:"t-trigger"},t);return n.cloneElement(r,P(r))},getPopupProps:function(){return b?{onMouseEnter:function(e){"hover"!==i||g.current||(clearTimeout(m.current),u(!0,{e:e,trigger:"trigger-element-hover"}))},onMouseLeave:function(e){"hover"===i&&(g.current=!0,clearTimeout(m.current),u(!1,{e:e,trigger:"trigger-element-hover"}))},onMouseDown:function(){clearTimeout(p.current),d.current=!0,p.current=window.setTimeout((function(){d.current=!1}))},onTouchEnd:function(){clearTimeout(p.current),d.current=!0,p.current=window.setTimeout((function(){d.current=!1}))}}:{}},getTriggerDom:e.useCallback((function(){return"undefined"==typeof document?{}:document.querySelector('[data-popup="'.concat(v.current,'"]'))}),[])}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var gc=function(e){var t=e.classPrefix,n=e.expandAnimation;if(!e.fadeAnimation)return{};var r="".concat(t,n?"-popup--animation-expand":"-popup--animation");return{classNames:{appear:"".concat(r,"-enter ").concat(r,"-enter-active"),appearActive:"".concat(r,"-enter-active"),appearDone:"".concat(r,"-enter-active ").concat(r,"-enter-to"),enter:"".concat(r,"-enter ").concat(r,"-enter-active"),enterActive:"".concat(r,"-enter-active"),enterDone:"".concat(r,"-enter-active ").concat(r,"-enter-to"),exit:"".concat(r,"-leave ").concat(r,"-leave-active"),exitActive:"".concat(r,"-leave-active"),exitDone:"".concat(r,"-leave-active ").concat(r,"-leave-to")}}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var bc=mt,hc=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},yc=function(e){return this.__data__.has(e)};function Oc(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new bc;++t<n;)this.add(e[t])}Oc.prototype.add=Oc.prototype.push=hc,Oc.prototype.has=yc;var wc=Oc;var Ec=function(e,t){return e.has(t)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var jc=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Pc=function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var xc=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,a=[];++n<r;){var c=e[n];t(c,n,e)&&(a[o++]=c)}return a},Cc=St(Object.keys,Object),_c=Ft,Nc=Cc,kc=Object.prototype.hasOwnProperty;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Sc=En,Dc=function(e){if(!_c(e))return Nc(e);var t=[];for(var n in Object(e))kc.call(e,n)&&"constructor"!=n&&t.push(n);return t},Ic=Nt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Tc=function(e){return Ic(e)?Sc(e):Dc(e)},Rc=Pc,Ac=Pt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Mc=function(e,t,n){var r=t(e);return Ac(e)?r:Rc(r,n(e))};var Lc=function(){return[]},zc=xc,Bc=Lc,Fc=Object.prototype.propertyIsEnumerable,Vc=Object.getOwnPropertySymbols,Hc=Vc?function(e){return null==e?[]:(e=Object(e),zc(Vc(e),(function(t){return Fc.call(e,t)})))}:Bc,Wc=Mc,Gc=Hc,Uc=Tc;var Kc=function(e){return Wc(e,Uc,Gc)},Zc=ye(z,"Set"),$c=ye(z,"DataView"),Xc=Oe,qc=ye(z,"Promise"),Yc=Zc,Jc=ye(z,"WeakMap"),Qc=q,ei=ce,ti="[object Map]",ni="[object Promise]",ri="[object Set]",oi="[object WeakMap]",ai="[object DataView]",ci=ei($c),ii=ei(Xc),li=ei(qc),ui=ei(Yc),si=ei(Jc),fi=Qc;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */($c&&fi(new $c(new ArrayBuffer(1)))!=ai||Xc&&fi(new Xc)!=ti||qc&&fi(qc.resolve())!=ni||Yc&&fi(new Yc)!=ri||Jc&&fi(new Jc)!=oi)&&(fi=function(e){var t=Qc(e),n="[object Object]"==t?e.constructor:void 0,r=n?ei(n):"";if(r)switch(r){case ci:return ai;case ii:return ti;case li:return ni;case ui:return ri;case si:return oi}return t});var di=fi;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var pi=wc,mi=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1},vi=Ec;var gi=function(e,t,n,r,o,a){var c=1&n,i=e.length,l=t.length;if(i!=l&&!(c&&l>i))return!1;var u=a.get(e),s=a.get(t);if(u&&s)return u==t&&s==e;var f=-1,d=!0,p=2&n?new pi:void 0;for(a.set(e,t),a.set(t,e);++f<i;){var m=e[f],v=t[f];if(r)var g=c?r(v,m,f,t,e,a):r(m,v,f,e,t,a);if(void 0!==g){if(g)continue;d=!1;break}if(p){if(!mi(t,(function(e,t){if(!vi(p,t)&&(m===e||o(m,e,n,r,a)))return p.push(t)}))){d=!1;break}}else if(m!==v&&!o(m,v,n,r,a)){d=!1;break}}return a.delete(e),a.delete(t),d};var bi=mn,hi=we,yi=gi,Oi=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n},wi=jc,Ei=B?B.prototype:void 0,ji=Ei?Ei.valueOf:void 0;var Pi=function(e,t,n,r,o,a,c){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!a(new bi(e),new bi(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return hi(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var i=Oi;case"[object Set]":var l=1&r;if(i||(i=wi),e.size!=t.size&&!l)return!1;var u=c.get(e);if(u)return u==t;r|=2,c.set(e,t);var s=yi(i(e),i(t),r,o,a,c);return c.delete(e),s;case"[object Symbol]":if(ji)return ji.call(e)==ji.call(t)}return!1},xi=Kc,Ci=Object.prototype.hasOwnProperty;var _i=pn,Ni=gi,ki=Pi,Si=function(e,t,n,r,o,a){var c=1&n,i=xi(e),l=i.length;if(l!=xi(t).length&&!c)return!1;for(var u=l;u--;){var s=i[u];if(!(c?s in t:Ci.call(t,s)))return!1}var f=a.get(e),d=a.get(t);if(f&&d)return f==t&&d==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=c;++u<l;){var v=e[s=i[u]],g=t[s];if(r)var b=c?r(g,v,s,t,e,a):r(v,g,s,e,t,a);if(!(void 0===b?v===g||o(v,g,n,r,a):b)){p=!1;break}m||(m="constructor"==s)}if(p&&!m){var h=e.constructor,y=t.constructor;h==y||!("constructor"in e)||!("constructor"in t)||"function"==typeof h&&h instanceof h&&"function"==typeof y&&y instanceof y||(p=!1)}return a.delete(e),a.delete(t),p},Di=di,Ii=Pt,Ti=Vt.exports,Ri=Jt,Ai="[object Arguments]",Mi="[object Array]",Li="[object Object]",zi=Object.prototype.hasOwnProperty;var Bi=function(e,t,n,r,o,a){var c=Ii(e),i=Ii(t),l=c?Mi:Di(e),u=i?Mi:Di(t),s=(l=l==Ai?Li:l)==Li,f=(u=u==Ai?Li:u)==Li,d=l==u;if(d&&Ti(e)){if(!Ti(t))return!1;c=!0,s=!1}if(d&&!s)return a||(a=new _i),c||Ri(e)?Ni(e,t,n,r,o,a):ki(e,t,l,n,r,o,a);if(!(1&n)){var p=s&&zi.call(e,"__wrapped__"),m=f&&zi.call(t,"__wrapped__");if(p||m){var v=p?e.value():e,g=m?t.value():t;return a||(a=new _i),o(v,g,n,r,a)}}return!!d&&(a||(a=new _i),Si(e,t,n,r,o,a))},Fi=vt;var Vi=function e(t,n,r,o,a){return t===n||(null==t||null==n||!Fi(t)&&!Fi(n)?t!=t&&n!=n:Bi(t,n,r,o,e,a))},Hi=Vi;var Wi=function(e,t){return Hi(e,t)},Gi={debounceTime:0,config:{attributes:!0,childList:!0,characterData:!0,subtree:!0}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Ui(t,n){var r,o,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Gi,c=e.useRef(null),i=e.useRef(),l=e.useRef(0),u=(r=n,(o=e.useRef(r)).current=r,o);Wi(a,i.current)||(l.current+=1),i.current=a,e.useEffect((function(){if(t&&null!=t&&t.nodeType){try{var e=i.current,n=e.debounceTime,r=e.config,o=function(){u.current.apply(u,arguments)};c.current=new MutationObserver(n>0?_a(o,n):o),c.current.observe(t,r)}catch(Wy){console.error(Wy)}return function(){c.current&&(c.current.disconnect(),c.current=null)}}}),[t,l.current])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Ki={destroyOnClose:!1,hideEmptyPopup:!1,placement:"top",showArrow:!1,trigger:"hover"},Zi=function(t,n){var r=bo();return e.useMemo((function(){var e;return n||(null==r||null===(e=r.attach)||void 0===e?void 0:e[t])||(null==r?void 0:r.attach)||"body"}),[t,n,null==r?void 0:r.attach])};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function $i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Xi(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$i(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var qi=e.forwardRef((function(t,o){var a=ho(t,Ki),l=a.trigger,u=a.content,s=a.placement,f=a.attach,d=a.showArrow,p=a.destroyOnClose,m=a.overlayClassName,v=a.overlayInnerClassName,g=a.overlayStyle,b=a.overlayInnerStyle,h=a.triggerElement,y=a.children,O=void 0===y?h:y,w=a.disabled,E=a.zIndex,j=a.onScroll,P=a.onScrollToBottom,x=a.expandAnimation,C=a.delay,_=a.hideEmptyPopup,N=a.popperOptions,k=a.updateScrollTop,D=bo().classPrefix,T=Zi("popup",f),R=dc(),A=R.keepExpand,M=R.keepFade,L=function(){var t="object"===("undefined"==typeof window?"undefined":S(window)),n=e.useCallback((function(){return{width:t?window.innerWidth:void 0,height:t?window.innerHeight:void 0}}),[t]),r=wo(e.useState(n),2),o=r[0],a=r[1];return e.useEffect((function(){var e=_a((function(){a(n())}),400);if(t)return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e),e.cancel()}}),[n,t]),o}(),z=L.height,B=L.width,F=wo(fc(a,"visible",a.onVisibleChange),2),V=F[0],H=F[1],W=wo(e.useState(null),2),G=W[0],U=W[1],K=e.useRef(null),Z=e.useRef(null),$=e.useRef(null),X=e.useRef(null),q=e.useRef(null);e.useEffect((function(){!u&&_&&requestAnimationFrame((function(){return U(null)}))}),[u,_]);var Y=e.useMemo((function(){return!(_&&!u)&&(V||G)}),[_,u,V,G]),J=e.useMemo((function(){return s.replace(/-(left|top)$/,"-start").replace(/-(right|bottom)$/,"-end")}),[s]),Q=vc({triggerRef:K,content:u,disabled:w,trigger:l,visible:V,delay:C,onVisibleChange:H}),ee=Q.getTriggerNode,ne=Q.getPopupProps,re=Q.getTriggerDom;q.current=c(pc(K),G,Xi({placement:J},N));var oe=q.current,ae=oe.styles,ce=oe.attributes,ie=te(O)?ee(O({visible:V})):ee(O),le=e.useRef(null);function ue(e){return pc(K)&&Z.current&&"function"==typeof e?Xi({},e(pc(K),Z.current)):Xi({},e)}Ui(pc(K),(function(){var e="none"===function(e,t){if(Co){var n=t||document.documentElement;return getComputedStyle(n).getPropertyValue(e)}}("display",pc(K));V&&!e&&(clearTimeout(le.current),le.current=setTimeout((function(){var e,t;return null===(e=q.current)||void 0===e||null===(t=e.update)||void 0===t?void 0:t.call(e)}),0))})),e.useEffect((function(){return function(){return clearTimeout(le.current)}}),[]),e.useEffect((function(){V&&requestAnimationFrame((function(){var e,t;return null===(e=q.current)||void 0===e||null===(t=e.update)||void 0===t?void 0:t.call(e)}))}),[V,u,z,B]),e.useEffect((function(){K.current||(K.current=re()),V&&(null==k||k(X.current))}),[V,k,re]);var se=Y&&n.createElement(i,{appear:!0,in:V,timeout:180,nodeRef:$,unmountOnExit:p,onEnter:function(){!p&&G&&(G.style.display="block")},onExited:function(){!p&&G&&(G.style.display="none")}},n.createElement(So,{triggerNode:pc(K),attach:T,ref:$},n.createElement(i,Xi({appear:!0,timeout:0,in:V,nodeRef:Z},gc({classPrefix:D,fadeAnimation:M,expandAnimation:x&&A})),n.createElement("div",Xi(Xi({ref:function(e){e&&(Z.current=e,U(e))},style:Xi(Xi({},ae.popper),{},{zIndex:E},ue(g)),className:r("".concat(D,"-popup"),m)},ce.popper),ne()),n.createElement("div",{ref:X,className:r("".concat(D,"-popup__content"),I({},"".concat(D,"-popup__content--arrow"),d),v),style:ue(b),onScroll:function(e){null==j||j({e:e});var t=_a((function(e){return null==P?void 0:P({e:e})}),100),n=e.target,r=n.scrollTop,o=n.clientHeight,a=n.scrollHeight;o+Math.floor(r)===a&&t(e)}},u,d?n.createElement("div",{style:ae.arrow,className:"".concat(D,"-popup__arrow")}):null)))));return e.useImperativeHandle(o,(function(){return{getPopper:function(){return q.current},getPopupElement:function(){return Z.current},getPortalElement:function(){return $.current},getPopupContentElement:function(){return X.current},setVisible:function(e){return H(e,{trigger:"document"})}}})),n.createElement(n.Fragment,null,ie,se)}));qi.displayName="Popup";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Yi=qi;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Ji(e,t){Object.keys(t).forEach((function(n){e.style[n]=t[n]}))}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Qi(t,n){var r=bo().classPrefix,o=dc().keepRipple,a=e.useMemo((function(){if(!Co)return null;var e=document.createElement("div");return e.className="".concat(r,"-ripple"),e}),[r]),c=e.useCallback((function(e){var n=function(e){var t;if(null!=e&&null!==(t=e.dataset)&&void 0!==t&&t.ripple)return e.dataset.ripple;var n=getComputedStyle(e).getPropertyValue("--ripple-color");return n||"rgba(0, 0, 0, 0.35)"}(t);if(0===e.button&&t&&o&&!(t.classList.contains("".concat(r,"-is-active"))||t.classList.contains("".concat(r,"-is-disabled"))||t.classList.contains("".concat(r,"-is-checked"))||t.classList.contains("".concat(r,"-is-loading")))){var c=getComputedStyle(t),i=parseInt(c.borderWidth,10),l=i>0?i:0,u=t.offsetWidth,s=t.offsetHeight;null===a.parentNode&&(Ji(a,{position:"absolute",left:"".concat(0-l,"px"),top:"".concat(0-l,"px"),width:"".concat(u,"px"),height:"".concat(s,"px"),borderRadius:c.borderRadius,pointerEvents:"none",overflow:"hidden"}),t.appendChild(a));var f=document.createElement("div");f.className="".concat(r,"-ripple__inner"),Ji(f,{marginTop:"0",marginLeft:"0",right:"".concat(u,"px"),width:"".concat(u+20,"px"),height:"100%",transition:"transform ".concat(200,"ms cubic-bezier(.38, 0, .24, 1), background ").concat(400,"ms linear"),transform:"skewX(-8deg)",pointerEvents:"none",position:"absolute",zIndex:0,backgroundColor:n,opacity:"0.9"});for(var d=new WeakMap,p=t.children.length,m=0;m<p;++m){var v=t.children[m];""===v.style.zIndex&&v!==a&&(v.style.zIndex="1",d.set(v,!0))}var g=t.style.position?t.style.position:getComputedStyle(t).position;""!==g&&"static"!==g||(t.style.position="relative"),a.insertBefore(f,a.firstChild),setTimeout((function(){f.style.transform="translateX(".concat(u,"px)")}),0);var b=function(){f.style.backgroundColor="rgba(0, 0, 0, 0)",t&&(t.removeEventListener("pointerup",b,!1),t.removeEventListener("pointerleave",b,!1),setTimeout((function(){f.remove(),0===a.children.length&&a.remove()}),500))};t.addEventListener("pointerup",b,!1),t.addEventListener("pointerleave",b,!1)}}),[r,t,n,a,o]);e.useEffect((function(){if(t)return t.addEventListener("pointerdown",c,!1),function(){t.removeEventListener("pointerdown",c,!1)}}),[c,n,t])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var el={block:!1,disabled:!1,form:void 0,ghost:!1,loading:!1,shape:"rectangle",size:"medium",type:"button",variant:"base"},tl=function(e,t){console.warn("TDesign ".concat(e," Warn: ").concat(t))},nl=function(e,t){console.error("TDesign ".concat(e," Error: ").concat(t))};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function rl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ol(e,t,n){var r=null;return"function"==typeof e?r=e(t):!0===e?r=n:null!==e&&(r=null!=e?e:n),r}function al(e,t){if(te(e))return e(t);if(!e||["string","number","boolean"].includes(S(e)))return e;try{return n.cloneElement(e,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rl(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},t))}catch(Wy){return tl("parseContentTNode","".concat(e," is not a valid ReactNode")),null}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var cl=["type","theme","variant","icon","disabled","loading","size","block","ghost","shape","children","content","className","suffix","href","tag","onClick"];function il(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ll(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?il(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):il(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ul=e.forwardRef((function(t,o){var a=ho(t,el),c=a.type,i=a.theme,l=a.variant,u=a.icon,s=a.disabled,f=a.loading,d=a.size,p=a.block,m=a.ghost,v=a.shape,g=a.children,b=a.content,h=a.className,y=a.suffix,O=a.href,w=a.tag,E=a.onClick,j=T(a,cl),P=bo().classPrefix,x=wo(Do(),2),C=x[0],_=x[1];Qi((null==o?void 0:o.current)||C);var N=null!=b?b:g,k=u;f&&(k=n.createElement(ia,{loading:f,inheritColor:!0}));var S=e.useMemo((function(){return i||("base"===l?"primary":"default")}),[i,l]),D=e.useMemo((function(){return w||!O||s?!w&&s?"div":w||"button":"a"}),[w,O,s]);return n.createElement(D,ll(ll({},j),{},{href:O,type:c,ref:o||_,disabled:s||f,className:r(h,["".concat(P,"-button"),"".concat(P,"-button--theme-").concat(S),"".concat(P,"-button--variant-").concat(l)],I(I(I(I(I(I(I({},"".concat(P,"-button--shape-").concat(v),"rectangle"!==v),"".concat(P,"-button--ghost"),m),"".concat(P,"-is-loading"),f),"".concat(P,"-is-disabled"),s),"".concat(P,"-size-s"),"small"===d),"".concat(P,"-size-l"),"large"===d),"".concat(P,"-size-full-width"),p)),onClick:s||f?void 0:E}),n.createElement(n.Fragment,null,k,N&&n.createElement("span",{className:"".concat(P,"-button__text")},N),y&&n.createElement("span",{className:"".concat(P,"-button__suffix")},ol(y))))}));ul.displayName="Button";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var sl=ul,fl=Co?e.useLayoutEffect:e.useEffect;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function dl(t,n){return l(e.forwardRef(t),n)}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function pl(e){var t=bo().icon,n={};return Object.keys(e).forEach((function(r){n[r]=(null==t?void 0:t[r])||e[r]})),n}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ml=["separate","children","className"];function vl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var gl=e.forwardRef((function(e,t){var o=bo().classPrefix,a=e.separate,c=e.children,i=e.className,l=T(e,ml);return n.createElement("div",function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vl(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({ref:t,className:r("".concat(o,"-input-group"),i,I({},"".concat(o,"-input-group--separate"),a))},l),c)}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function bl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function hl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bl(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function yl(e,t){var r=n.useContext(go).globalConfig;return[n.useMemo((function(){var t={},n=r[e],o=e&&r?n:{};return hl(hl({},"function"==typeof t?t():t),o||{})}),[e,t,r]),function(e,t){var n=/\{\s*([\w-]+)\s*\}/g;return"string"==typeof e?t&&n.test(e)?e.replace(n,(function(e,n){return t?String(t[n]):""})):e:Array.isArray(e)?e.map((function(e,r){return e.replace(n,(function(e,n){return t?String(t[r][n]):""}))})):"function"==typeof e?e(t):""}]}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */gl.displayName="InputGroup";var Ol={align:"left",allowInputOverMax:!1,autoWidth:!1,autocomplete:void 0,autofocus:!1,borderless:!1,clearable:!1,placeholder:void 0,readonly:!1,showClearIconOnEmpty:!1,showLimitNumber:!1,size:"medium",spellCheck:!1,status:"default",type:"text",defaultValue:""};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function wl(t){var n=e.useMemo((function(){var e,n=t.maxlength,r=t.maxcharacter,o=t.value;if("number"==typeof o)return String(o);if(n&&r&&tl("Input","Pick one of maxlength and maxcharacter please."),n){var a=null!=o&&o.length?To(null!=(e=o)?e:"").length:0;return"".concat(a,"/").concat(n)}return r?"".concat(Fo(o||""),"/").concat(r):""}),[t.maxcharacter,t.maxlength,t.value]),r=e.useMemo((function(){if(n){var e=wo(n.split("/"),2),t=e[0],r=e[1];return Number(t)>Number(r)?"error":""}return""}),[n]),o=e.useMemo((function(){return t.status||r}),[t.status,r]);return e.useEffect((function(){var e;null===(e=t.onValidate)||void 0===e||e.call(t,{error:r?"exceed-maximum":void 0})}),[r]),{tStatus:o,limitNumber:n,getValueByLimitNumber:function(e){var n,r,o=t.allowInputOverMax,a=t.maxlength,c=t.maxcharacter;if(!a&&!c||o||!e)return e;if(a)return n=e,r=a,To("").slice().length===r?"":To(null!=n?n:"").slice(0,r).join("");if(c){var i=Fo(e,c);if("object"===S(i))return i.characters}}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var El=["type","autoWidth","borderless","placeholder","disabled","status","size","className","inputClass","style","prefixIcon","suffixIcon","clearable","tips","align","maxlength","maxcharacter","showClearIconOnEmpty","autofocus","autocomplete","readonly","label","suffix","showInput","keepWrapperWidth","showLimitNumber","allowInputOverMax","name","format","onClick","onClear","onEnter","onKeydown","onKeyup","onKeypress","onFocus","onBlur","onPaste","onMouseenter","onMouseleave","onWheel","onCompositionstart","onCompositionend","onValidate","onChange"];function jl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var Pl=function(e,t,r){var o=ol(r),a=r?"".concat(e,"-input__").concat(t,"-icon"):"";return o?n.createElement("span",{className:"".concat(e,"-input__").concat(t," ").concat(a)},o):null},xl=dl((function(t,o){var a,c=wo(yl("input"),2),i=c[0],l=c[1],d=pl({BrowseIcon:u,BrowseOffIcon:s,CloseCircleFilledIcon:f}),p=d.BrowseIcon,m=d.BrowseOffIcon,v=d.CloseCircleFilledIcon,g=ho(t,Ol),b=g.type,h=g.autoWidth,y=g.borderless,O=g.placeholder,w=void 0===O?l(i.placeholder):O,E=g.disabled,j=g.status,P=g.size,x=g.className,C=g.inputClass,_=g.style,N=g.prefixIcon,k=g.suffixIcon,S=g.clearable,D=g.tips,R=g.align,A=g.maxlength,M=g.maxcharacter,L=g.showClearIconOnEmpty,z=g.autofocus,B=g.autocomplete,F=g.readonly,V=g.label,H=g.suffix,W=g.showInput,G=void 0===W||W,U=g.keepWrapperWidth,K=g.showLimitNumber,Z=g.allowInputOverMax,$=g.name,X=g.format,q=g.onClick,Y=g.onClear,J=g.onEnter,Q=g.onKeydown,ee=g.onKeyup,ne=g.onKeypress,re=g.onFocus,oe=g.onBlur,ae=g.onPaste,ce=g.onMouseenter,ie=g.onMouseleave,le=g.onWheel,ue=g.onCompositionstart,se=g.onCompositionend,fe=g.onValidate,de=g.onChange,pe=T(g,El),me=wo(fc(g,"value",de),2),ve=me[0],ge=me[1],be=wl({value:void 0===ve?void 0:String(ve),status:j,maxlength:A,maxcharacter:M,allowInputOverMax:Z,onValidate:fe}),he=be.limitNumber,ye=be.getValueByLimitNumber,Oe=be.tStatus,we=bo().classPrefix,Ee=e.useRef(!1),je=e.useRef(),Pe=e.useRef(),xe=e.useRef(),Ce=wo(e.useState(!1),2),_e=Ce[0],Ne=Ce[1],ke=wo(e.useState(!1),2),Se=ke[0],De=ke[1],Ie=wo(e.useState(b),2),Te=Ie[0],Re=Ie[1],Ae=wo(e.useState(""),2),Me=Ae[0],Le=Ae[1],ze=(S&&ve&&!E||L)&&_e,Be=Pl(we,"prefix",ol(N)),Fe=k;ze&&(Fe=n.createElement(v,{className:"".concat(we,"-input__suffix-clear"),onMouseDown:function(e){e.stopPropagation(),e.nativeEvent.stopImmediatePropagation()},onClick:function(e){null==ge||ge("",{e:e,trigger:"clear"}),null==Y||Y({e:e})}})),"password"===b&&void 0===k&&("password"===Te?Fe=n.createElement(m,{className:"".concat(we,"-input__suffix-clear"),onClick:qe}):"text"===Te&&(Fe=n.createElement(p,{className:"".concat(we,"-input__suffix-clear"),onClick:qe})));var Ve=Pl(we,"suffix",ol(Fe)),He=te(V)?V():V,We=te(H)?H():H,Ge=he&&K?n.createElement("div",{className:r("".concat(we,"-input__limit-number"),I({},"".concat(we,"-is-disabled"),E))},he):null,Ue=function(){if(h&&je.current){var e=Pe.current.offsetWidth,t=Pe.current.getBoundingClientRect().width,n=t<e?e+1:t;je.current.style.width="".concat(n,"px")}};fl((function(){requestAnimationFrame((function(){Ue()}))}),[h,ve,w,je,Me]),e.useEffect((function(){var e=null;if(void 0!==window.ResizeObserver&&je.current)return(e=new window.ResizeObserver((function(){Ue()}))).observe(je.current),function(){var t,n;null===(t=(n=e).disconnect)||void 0===t||t.call(n),e=null}}),[je]),e.useEffect((function(){Re(b)}),[b]),e.useEffect((function(){if(ve){var e=ye(ve);e.length===ve.length||Z||null==ge||ge(e,{trigger:"initial"})}}),[]);var Ke=Ee.current?Me:null!=ve?ve:"",Ze=X&&!Se?X(Ke):Ke,$e=n.createElement("input",{ref:je,placeholder:w,type:Te,className:"".concat(we,"-input__inner"),value:Ze,readOnly:F,disabled:E,autoComplete:null!=B?B:i.autocomplete||void 0,autoFocus:z,onChange:Ye,onKeyDown:function(e){var t=e.key,n=e.currentTarget.value;"Enter"===t&&(null==J||J(n,{e:e})),null==Q||Q(n,{e:e})},onKeyUp:function(e){var t=e.currentTarget.value;null==ee||ee(t,{e:e})},onKeyPress:function(e){var t=e.currentTarget.value;null==ne||ne(t,{e:e})},onCompositionStart:function(e){Ee.current=!0;var t=e.currentTarget.value;null==ue||ue(t,{e:e})},onCompositionEnd:function(e){var t=e.currentTarget.value;Ee.current&&(Ee.current=!1,Ye(e));null==se||se(t,{e:e})},onFocus:function(e){if(F)return;var t=e.currentTarget.value;null==re||re(t,{e:e}),De(!0)},onBlur:function(e){if(F)return;var t=e.currentTarget.value;null==oe||oe(t,{e:e}),De(!1)},onPaste:function(e){var t=e.clipboardData,n=null==t?void 0:t.getData("text/plain");null==ae||ae({e:e,pasteValue:n})},name:$}),Xe=n.createElement("div",{className:r(C,"".concat(we,"-input"),(a={},I(I(I(I(I(I(I(I(I(I(a,"".concat(we,"-is-readonly"),F),"".concat(we,"-is-disabled"),E),"".concat(we,"-is-focused"),Se),"".concat(we,"-size-s"),"small"===P),"".concat(we,"-size-l"),"large"===P),"".concat(we,"-align-").concat(R),R),"".concat(we,"-is-").concat(Oe),Oe&&"default"!==Oe),"".concat(we,"-input--prefix"),N||He),"".concat(we,"-input--suffix"),Ve||We),"".concat(we,"-input--borderless"),y),I(a,"".concat(we,"-input--focused"),Se))),onMouseEnter:function(e){Ne(!0),null==ce||ce({e:e})},onMouseLeave:function(e){Ne(!1),null==ie||ie({e:e})},onWheel:function(e){return null==le?void 0:le({e:e})},onClick:function(e){var t;null===(t=je.current)||void 0===t||t.focus(),null==q||q({e:e})}},Be,He?n.createElement("div",{className:"".concat(we,"-input__prefix")},He):null,G&&$e,h&&n.createElement("span",{ref:Pe,className:"".concat(we,"-input__input-pre")},Ke||w),We||Ge?n.createElement("div",{className:"".concat(we,"-input__suffix")},We,Ge):null,Ve);function qe(){E||Re("password"===Te?"text":"password")}function Ye(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"input",n=e.currentTarget.value;Ee.current?Le(n):("number"!==g.type&&(n=ye(n)),Le(n),ge(n,{e:e,trigger:t}))}return e.useImperativeHandle(o,(function(){return{currentElement:xe.current,inputElement:je.current,focus:function(){var e;return null===(e=je.current)||void 0===e?void 0:e.focus()},blur:function(){var e;return null===(e=je.current)||void 0===e?void 0:e.blur()},select:function(){var e;return null===(e=je.current)||void 0===e?void 0:e.select()}}})),n.createElement("div",function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jl(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({ref:xe,style:_,className:r("".concat(we,"-input__wrap"),x,I({},"".concat(we,"-input--auto-width"),h&&!U))},pe),Xe,D&&n.createElement("div",{className:r("".concat(we,"-input__tips"),"".concat(we,"-input__tips--").concat(Oe||"default"))},D))}),{Group:gl});xl.displayName="Input";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Cl=xl,_l=["prepend","append","children","className","style"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Nl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function kl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Nl(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Nl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sl=e.forwardRef((function(e,t){var o=bo().classPrefix,a=e.prepend,c=e.append,i=e.children,l=e.className,u=e.style,s=T(e,_l),f=function(e,t,r){if(void 0===r)return null;var o,a=xo(r)||zo(r);return(o="function"==typeof r?n.createElement(r,null):a?n.createElement("span",{className:"".concat(t,"-input-adornment__text")},r):r)?n.createElement("span",{className:"".concat(t,"-input-adornment__").concat(e)},o):o};return n.createElement("div",{ref:t,style:u,className:r("".concat(o,"-input-adornment"),l)},f("prepend",o,a),n.Children.map(i,(function(e){return e?n.isValidElement(e)?n.cloneElement(e,kl(kl(kl({},s),e.props),{},{onChange:function(){for(var t,n,r,o,a=arguments.length,c=new Array(a),i=0;i<a;i++)c[i]=arguments[i];null==s||null===(t=s.onChange)||void 0===t||null===(n=t.call)||void 0===n||n.call.apply(n,[t,null].concat(c)),null===(r=e.props)||void 0===r||null===(r=r.onChange)||void 0===r||null===(o=r.call)||void 0===o||o.call.apply(o,[r,null].concat(c))}})):e:null})),f("append",o,c))}));Sl.displayName="InputAdornment";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Dl=Sl,Il=q,Tl=vt;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Rl=function(e){return!0===e||!1===e||Tl(e)&&"[object Boolean]"==Il(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Al=function(e,t,n,r){var o=-1,a=null==e?0:e.length;for(r&&a&&(n=e[++o]);++o<a;)n=t(n,e[o],o,e);return n};var Ml=function(e){return function(t){return null==e?void 0:e[t]}}({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","Ĳ":"IJ","ĳ":"ij","Œ":"Oe","œ":"oe","ŉ":"'n","ſ":"s"}),Ll=oc,zl=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Bl=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");var Fl=function(e){return(e=Ll(e))&&e.replace(zl,Ml).replace(Bl,"")},Vl=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var Hl=function(e){return e.match(Vl)||[]},Wl=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var Gl=function(e){return Wl.test(e)},Ul="\\ud800-\\udfff",Kl="\\u2700-\\u27bf",Zl="a-z\\xdf-\\xf6\\xf8-\\xff",$l="A-Z\\xc0-\\xd6\\xd8-\\xde",Xl="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",ql="["+Xl+"]",Yl="\\d+",Jl="["+Kl+"]",Ql="["+Zl+"]",eu="[^"+Ul+Xl+Yl+Kl+Zl+$l+"]",tu="(?:\\ud83c[\\udde6-\\uddff]){2}",nu="[\\ud800-\\udbff][\\udc00-\\udfff]",ru="["+$l+"]",ou="(?:"+Ql+"|"+eu+")",au="(?:"+ru+"|"+eu+")",cu="(?:['’](?:d|ll|m|re|s|t|ve))?",iu="(?:['’](?:D|LL|M|RE|S|T|VE))?",lu="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",uu="[\\ufe0e\\ufe0f]?",su=uu+lu+("(?:\\u200d(?:"+["[^"+Ul+"]",tu,nu].join("|")+")"+uu+lu+")*"),fu="(?:"+[Jl,tu,nu].join("|")+")"+su,du=RegExp([ru+"?"+Ql+"+"+cu+"(?="+[ql,ru,"$"].join("|")+")",au+"+"+iu+"(?="+[ql,ru+ou,"$"].join("|")+")",ru+"?"+ou+"+"+cu,ru+"+"+iu,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Yl,fu].join("|"),"g");var pu=Hl,mu=Gl,vu=oc,gu=function(e){return e.match(du)||[]};var bu=Al,hu=Fl,yu=function(e,t,n){return e=vu(e),void 0===(t=n?void 0:t)?mu(e)?gu(e):pu(e):e.match(t)||[]},Ou=RegExp("['’]","g");var wu=function(e){return function(t){return bu(yu(hu(t).replace(Ou,"")),e,"")}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Eu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ju(e,t){for(var n=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Eu(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Eu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e),r=0;r<t.length;r++){delete n[t[r]]}return n}function Pu(e){return"number"==typeof e?"".concat(e,"px"):e}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var xu=["allowUncheck","type","disabled","name","value","onChange","indeterminate","children","label","className","style","readonly","onClick"];function Cu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cu(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Nu=n.createContext(null),ku=e.forwardRef((function(t,o){var a=e.useContext(Nu),c=a?a.inject(t):t,i=c.allowUncheck,l=void 0!==i&&i,u=c.type,s=c.disabled,f=c.name,d=c.value,p=c.onChange,m=c.indeterminate,v=c.children,g=c.label,b=c.className,h=c.style,y=c.readonly,O=c.onClick,w=T(c,xu),E=bo().classPrefix,j=wo(fc(c,"checked",p),2),P=j[0],x=j[1],C=r("".concat(E,"-").concat(u),b,I(I(I({},"".concat(E,"-is-checked"),P),"".concat(E,"-is-disabled"),s),"".concat(E,"-is-indeterminate"),m)),_=s||y,N=n.createElement("input",{readOnly:y,type:"radio-button"===u?"radio":u,className:"".concat(E,"-").concat(u,"__former"),checked:P,disabled:s,name:f,tabIndex:-1,value:Rl(d)?Number(d):d,"data-value":"string"==typeof d?"'".concat(d,"'"):d,"data-allow-uncheck":l||void 0,onClick:function(e){e.stopPropagation(),("radio-button"===u||"radio"===u)&&l&&P&&x(!e.currentTarget.checked,{e:e})},onChange:function(e){_||x(e.currentTarget.checked,{e:e})}}),k=!(!v&&!g);return n.createElement("label",_u(_u({ref:o,tabIndex:s?void 0:0,className:C,title:c.title,style:h},ju(w,["checkAll","stopLabelTrigger"])),{},{onClick:function(e){_||null==O||O({e:e})}}),N,n.createElement("span",{className:"".concat(E,"-").concat(u,"__input")}),k&&n.createElement("span",{key:"label",className:"".concat(E,"-").concat(u,"__label"),onClick:function(e){c.stopLabelTrigger&&e.preventDefault()}},v||g))}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Su(){var t=bo().classPrefix;return e.useMemo((function(){var e={SIZE:{default:"",xs:"".concat(t,"-size-xs"),small:"".concat(t,"-size-s"),medium:"".concat(t,"-size-m"),large:"".concat(t,"-size-l"),xl:"".concat(t,"-size-xl"),block:"".concat(t,"-size-full-width")},STATUS:{loading:"".concat(t,"-is-loading"),disabled:"".concat(t,"-is-disabled"),focused:"".concat(t,"-is-focused"),success:"".concat(t,"-is-success"),error:"".concat(t,"-is-error"),warning:"".concat(t,"-is-warning"),selected:"".concat(t,"-is-selected"),active:"".concat(t,"-is-active"),checked:"".concat(t,"-is-checked"),current:"".concat(t,"-is-current"),hidden:"".concat(t,"-is-hidden"),visible:"".concat(t,"-is-visible"),expanded:"".concat(t,"-is-expanded"),indeterminate:"".concat(t,"-is-indeterminate")}};return{SIZE:e.SIZE,STATUS:e.STATUS,sizeClassNames:e.SIZE,statusClassNames:e.STATUS,classPrefix:t}}),[t])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */ku.displayName="Check";var Du={allowUncheck:!1,defaultChecked:!1,disabled:void 0,readonly:void 0,value:void 0},Iu={allowUncheck:!1,disabled:void 0,readonly:void 0,size:"medium",variant:"outline"},Tu=/^Space$/i,Ru=/^Enter$/i,Au=/^(Enter|Space)$/i;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Mu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Lu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Mu(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zu=function(t){var o=bo().classPrefix,a=ho(t,Iu),c=a.disabled,i=a.readonly,l=a.children,u=a.onChange,s=a.size,f=a.variant,d=a.options,p=void 0===d?[]:d,m=a.className,v=a.style,g=wo(fc(a,"value",u),2),b=g[0],h=g[1],y=wo(e.useState({}),2),O=y[0],w=y[1],E=e.useRef(null);!
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function(t,n){var r=function(e){if(Au.test(e.key)||Au.test(e.code)){var t=e.target.querySelector("input"),r=(null==t?void 0:t.dataset)||{};if(t.checked&&r.allowUncheck)n(void 0,{e:e});else{var o=isNaN(Number(r.value))?r.value:Number(r.value);o="string"==typeof(o="string"==typeof o&&{true:!0,false:!1}[o]||o)&&"'"===o[0]?o.replace(/'/g,""):o,n(o,{e:e})}}};e.useEffect((function(){return _o(t.current,"keydown",r),function(){No(t.current,"keydown",r)}}),[])}(E,h);var j=".".concat(o,"-radio-button.").concat(o,"-is-checked"),P=Su().SIZE,x={inject:function(e){if(void 0!==e.checked)return e;var t=e.value;return Lu(Lu({},e),{},{name:a.name,allowUncheck:e.allowUncheck||a.allowUncheck,checked:b===e.value,disabled:e.disabled||c,readonly:e.readonly||i,onChange:function(n,r){var o=r.e;"function"==typeof e.onChange&&e.onChange(n,{e:o}),h(n?t:void 0,{e:o,name:a.name})}})}},C=function(){var e,t;if(f.includes("filled")){var n=null===(e=(t=E.current).querySelector)||void 0===e?void 0:e.call(t,j);if(!n)return w({width:0});var r=n.offsetWidth,o=n.offsetHeight,a=n.offsetLeft,c=n.offsetTop;w({width:"".concat(r,"px"),height:"".concat(o,"px"),left:"".concat(a,"px"),top:"".concat(c,"px")})}};e.useEffect((function(){C()}),[E.current,b]),Ui(E.current,C);var _;return n.createElement(Nu.Provider,{value:x},n.createElement("div",{ref:E,style:v,className:r("".concat(o,"-radio-group"),P[s],m,I(I(I({},"".concat(o,"-radio-group__outline"),"outline"===f),"".concat(o,"-radio-group--filled"),f.includes("filled")),"".concat(o,"-radio-group--primary-filled"),"primary-filled"===f))},l||(_=f.includes("filled")?Hu.Button:Hu,p.map((function(e,t){var r,o,a;return"string"==typeof e||"number"==typeof e?(r=e,o=e):(r=e.label,o=e.value,a=e.disabled),n.createElement(_,{value:o,key:t,disabled:a},r)}))),f.includes("filled")?n.createElement("div",{style:O,className:"".concat(o,"-radio-group__bg-block")}):null))};function Bu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Fu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bu(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}zu.displayName="RadioGroup";var Vu=dl((function(e,t){return n.createElement(ku,Fu({ref:t,type:"radio"},ho(e,Du)))}),{Group:zu,Button:e.forwardRef((function(e,t){return n.createElement(ku,Fu({ref:t,type:"radio-button"},ho(e,Du)))}))});Vu.displayName="Radio";var Hu=Vu,Wu=Hu;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */Hu.Group;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Gu={checkAll:!1,defaultChecked:!1,disabled:void 0,indeterminate:!1,readonly:!1},Uu={max:void 0,defaultValue:[]};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Ku(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Zu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ku(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ku(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $u=function(t){var o=bo().classPrefix,a=ho(t,Uu),c=a.onChange,i=a.disabled,l=a.className,u=a.style,s=a.children,f=a.max,d=a.options,p=void 0===d?[]:d,m=(Array.isArray(p)&&p.length>0?p:n.Children.map(s,(function(e){var t;return(null==e||null===(t=e.type)||void 0===t?void 0:t.displayName)===Yu.displayName&&e.props}))||[]).filter((function(e){return"object"!==S(e)||!e.checkAll})),v=[];m.forEach((function(e){var t=function(e){switch(S(e)){case"number":case"string":return e;case"object":return e.value;default:return}}(e);v.push(t)}));var g=wo(fc(t,"value",c),2),b=g[0],h=g[1],y=wo(e.useState(f),2),O=y[0],w=y[1],E=e.useCallback((function(){return Array.isArray(b)?new Set([].concat(b)):new Set([])}),[b]),j=e.useMemo((function(){return E()}),[E]),P=e.useMemo((function(){var e=Array.from(j);return 0!==e.length&&e.length!==m.length}),[j,m]),x=e.useMemo((function(){return Array.from(j).length===m.length}),[j,m]);e.useEffect((function(){zo(f)&&(f<j.size?console.warn("[TDesign] max should be less than the length of value, change is invalid"):w(f))}),[f,j]);var C={inject:function(e){if(void 0!==e.checked)return e;var t=e.value;return Zu(Zu({},e),{},{checked:e.checkAll?x:j.has(t),indeterminate:e.checkAll?P:e.indeterminate,disabled:e.disabled||i||j.size>=O&&!j.has(t),onChange:function(n,r){var o=r.e;"function"==typeof e.onChange&&e.onChange(n,{e:o});var a=E();if(e.checkAll)a.clear(),n&&v.forEach((function(e){a.add(e)}));else if(n){if(a.size>=O&&zo(f))return;a.add(t)}else a.delete(t);h(Array.from(a),{e:o,current:e.checkAll?void 0:t,type:n?"check":"uncheck"})}})}},_=Array.isArray(p)&&0!==p.length;return n.createElement("div",{className:r("".concat(o,"-checkbox-group"),l),style:u},n.createElement(Nu.Provider,{value:C},_?p.map((function(e,t){switch(S(e)){case"string":return n.createElement(Yu,{key:t,label:e,value:e},e);case"number":return n.createElement(Yu,{key:t,label:e,value:e},String(e));case"object":var r=e;return r.checkAll?n.createElement(Yu,Zu(Zu({},r),{},{key:"checkAll_".concat(t),indeterminate:P})):n.createElement(Yu,Zu(Zu({},r),{},{key:t,disabled:r.disabled||i}));default:return null}})):s))};function Xu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}$u.displayName="CheckboxGroup";var qu=dl((function(e,t){return n.createElement(ku,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xu(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({ref:t,type:"checkbox"},ho(e,Gu)))}),{Group:$u});qu.displayName="Checkbox";var Yu=qu,Ju=Yu;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Qu(e){return new Array(e).fill(0).join("")}function es(e){if(!e)return!0;if(zo(e))return!Number.isNaN(e);if(!/^[0-9|e|E|-]+\.*[0-9|e|E|-]*$/.test(e))return!1;for(var t=0,n=0,r=0,o=0,a=e.length;o<a;o++){if("."===e[o]&&(r+=1)>1)return!1;if(/(e|E)+/.test(e[o])&&(t+=1)>1)return!1;if("-"===e[o]&&(n+=1)>2)return!1}return!0}function ts(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return-1!==e.indexOf(".")?(nl("InputNumber","num is not a integer number."),e):!e||"0"===e&&t?"":"0"===e?e:(t?e.replace(/0+$/,""):e.replace(/^0+/,""))||"0"}function ns(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=ts(e,n),o=ts(t,n),a=r.length>o.length,c=a?r:o,i=a?o:r,l=[],u=[],s=n?0:c.length-i.length,f=n?i.length:c.length,d=f-1;d>=0;d--){var p=d-s,m=Number(c[d])+(Number(i[p])||0)+(u[d]||0);m>=10&&(u[d-1]=1),l.unshift(String(m%10))}return u[-1]&&l.unshift("1"),n?l.concat(c.slice(f,c.length)).join(""):l.join("")}function rs(e,t){var n=wo(e.split("."),2),r=n[0],o=void 0===r?"0":r,a=n[1],c=void 0===a?"0":a,i=wo(t.split("."),2),l=i[0],u=void 0===l?"0":l,s=i[1],f=void 0===s?"0":s,d=ns(o,u);if("0"===c&&"0"===f)return d;var p=ts(c,!0),m=ts(f,!0),v=ns(p,m,!0),g=v.length;return g>p.length&&g>m.length?[ts(ns(d,"1")),ts(v.slice(1),!0)].filter((function(e){return e})).join("."):[ts(d),ts(v,!0)].filter((function(e){return e})).join(".")}function os(e,t){var n=ts(e),r=ts(t);if(n.length===r.length){for(var o=0,a=n.length;o<a;o++){if(n[o]>r[o])return 1;if(n[o]<r[o])return-1}return 0}return n.length>r.length?1:-1}function as(e,t){for(var n=e&&"0"!==e?e.replace(/0+$/,""):"0",r=t&&"0"!==t?t.replace(/0+$/,""):"0",o=0,a=Math.max(n.length,r.length);o<a;o++){if((n[o]||0)>(r[o]||0))return 1;if((n[o]||0)<(r[o]||0))return-1}return 0}function cs(e){var t=wo(e.split("e"),2),n=t[0],r=t[1];if(!r)return e;var o=wo(e.split("."),2),a=o[0],c=o[1],i=void 0===c?"":c,l=Number(r),u=wo(i.split("e"),1)[0];if(l>u.length){var s=Qu(l-u.length);return n.replace(/(^0+|\.)/g,"")+s}var f=a.replace(/^0+/,"")+u.slice(0,l),d=u.slice(l);return d?[f,d].join("."):f}function is(e){return[-1/0,1/0].includes(Number(e))}function ls(e){return Number(e)<Number.MAX_SAFE_INTEGER&&Number(e)>Number.MIN_SAFE_INTEGER}function us(e,t,n){var r=ls(e)&&ls(t)&&!n,o=is(e)||is(t);return r||o?Number(e)===Number(t)?0:Number(e)>Number(t)?1:-1:function(e,t){var n=wo(cs(e).split("."),2),r=n[0],o=n[1],a=wo(cs(t).split("."),2),c=a[0],i=a[1],l=os(r.replace("-",""),c.replace("-","")),u=r.includes("-"),s=c.includes("-");return u&&!s?-1:!u&&s?1:u&&s?0===l?0:l>0?-1:1:0===l?as(o,i):l}(String(e),String(t))}function ss(e,t,n){if(e===t)return"0";for(var r=n||{},o=r.decimal,a=r.stayZero,c=ts(e),i=ts(t),l=os(c,i)>0,u=l?c:i,s=l?i:c,f=[],d=[],p=o?0:u.length-s.length,m=o?s.length:u.length,v=m-1;v>=0;v--){var g=v-p,b=Number(u[v])-(Number(s[g])||0)-(d[v]||0);b<0&&(d[v-1]=1,b+=10),f.unshift(String(b))}if(o)return f.concat(u.slice(m,u.length)).join("");var h=f.join("");return a||(h=h.replace(/^0+/,"")),ts(l?h:"-".concat(h))}function fs(e,t){if(e===t)return"0";var n=us(e,t,!0)>0,r=n?t:e,o=wo((n?e:t).split("."),2),a=o[0],c=o[1],i=void 0===c?"0":c,l=wo(r.split("."),2),u=l[0],s=l[1],f=void 0===s?"0":s,d=ss(a,u);if("0"===i&&"0"===f)return n?d:"-".concat(d);var p="",m=i;i.length<f.length&&(m="".concat(i).concat(Qu(f.length-i.length))),as(m,f)>=0?p=ss(m,f,{decimal:!0}):(i.length<f.length||"0"===i?(p=ss("1".concat(m),f,{stayZero:!0}),p=Qu(f.length-p.length)+p):p=ss(i,f,{decimal:!0}),d=ss(d,"1"));var v=p?[d,p].join("."):d;return n?v:"-".concat(v)}function ds(e,t){if(!(arguments.length>2&&void 0!==arguments[2])||arguments[2])return e.toFixed(t);var n=wo(e.toString().split("."),2),r=n[0],o=n[1];if(0===t)return r;var a=o.slice(0,t);return o.length<t&&(a+=Qu(t-o.length)),[r,a].join(".")}function ps(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(Number.isNaN(Number(e)))return"";if(!r)return function(e,t){var n;return Y(t)?ds(e,t.places,null===(n=t.enableRound)||void 0===n||n):ds(e,t,!0)}(Number(e),n);var o=Y(n)?n.places:n,a=!Y(n)||(null===(t=n.enableRound)||void 0===t||t);if(!xo(e))return String(e);var c=wo(e.split("."),2),i=c[0],l=c[1];if(!l)return o>0&&a?[e,Qu(o)].join("."):e;if(0===o)return a&&Number(l[0])>=5?rs(i,"1"):i;var u=l.slice(0,o);if(l.length<o)u+=Qu(o-l.length);else if(a){var s,f=null===(s=u.match(/^0+/))||void 0===s?void 0:s[0].length,d=u.match(/^9+/),p=Number(l[o])>=5;u=p?rs(u,"1"):u,f&&p&&f+u.length>=o&&(u="".concat(Qu(o-u.length)).concat(u)),d&&u.length>o&&(i=(Number(i)+1).toString(),u=Qu(o))}return[i,u].join(".")}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function ms(e,t){var n,r;if(!e||!t)return(e||0)+(t||0);var o=(null===(n=e.toString().split(".")[1])||void 0===n?void 0:n.length)||0,a=(null===(r=t.toString().split(".")[1])||void 0===r?void 0:r.length)||0;if(!o&&!a)return e+t;var c=e,i=t,l=Math.abs(o-a),u=Math.pow(10,Math.max(o,a));if(l>0){var s=Math.pow(10,l);o>a?(c=Number(e.toString().replace(".","")),i=Number(t.toString().replace(".",""))*s):(c=Number(e.toString().replace(".",""))*s,i=Number(t.toString().replace(".","")))}else c=Number(e.toString().replace(".","")),i=Number(t.toString().replace(".",""));return(c+i)/u}function vs(e,t){var n,r;if(!e||!t)return(e||0)-(t||0);var o=(null===(n=e.toString().split(".")[1])||void 0===n?void 0:n.length)||0,a=(null===(r=t.toString().split(".")[1])||void 0===r?void 0:r.length)||0,c=Math.pow(10,Math.max(o,a));return Number(((e*c-t*c)/c).toFixed(o>=a?o:a))}function gs(e){var t=e.op,n=e.step,r=e.lastValue,o=e.max,a=e.min,c=e.largeNumber;if(Number(n)<=0)return nl("InputNumber","step must be larger than 0."),r;var i,l,u,s=zo(n)?String(n):n;return"add"===t?c&&xo(r)?i=function(e,t){var n="-"===e[0],r="-"===t[0];if(n&&!r)return fs(t,e.slice(1));if(n&&r){var o=rs(t.slice(1),e.slice(1));return"-".concat(o)}return!n&&r?fs(e,t.slice(1)):rs(e,t)}(String(r),String(s)):(l=Number(r||0),u=Number(n),i=l<0&&u>0?vs(u,Math.abs(l)):l<0&&u<0?-1*ms(Math.abs(l),Math.abs(u)):l>0&&u<0?vs(l,Math.abs(u)):ms(l,u)):"reduce"===t&&(i=c&&xo(r)?function(e,t){var n="-"===e[0],r="-"===t[0];if(n&&!r){var o=rs(e.slice(1),t);return"-".concat(o)}return n&&r?fs(t.slice(1),e.slice(1)):!n&&r?rs(e,t.slice(1)):fs(e,t)}(String(r),String(s)):function(e,t){return e<0&&t>0?-1*ms(Math.abs(e),t):e<0&&t<0?vs(Math.abs(t),Math.abs(e)):e>0&&t<0?ms(e,Math.abs(t)):vs(e,t)}(Number(r||0),Number(n))),Ao(r)&&(i=function(e,t){if(""!==e){var n=t.max,r=t.min,o=t.lastValue,a=t.largeNumber;return es(e)?!a||!xo(n)&&n!==1/0||!xo(r)&&r!==-1/0?Math.max(Number(r),Math.min(Number(n),Number(e))):us(n,e,a)<0?n:us(r,e,a)>0?r:e:o}}(i,{max:o,min:a,lastValue:r,largeNumber:c})),c?i:Number(i)}function bs(e){var t=e.largeNumber,n=e.value,r=e.max,o=e.min;if(!Ao(n)&&!Ao(t))return t&&zo(n)&&tl("InputNumber","largeNumber value must be a string."),us(n,r,t)>0?"exceed-maximum":us(n,o,t)<0?"below-minimum":void 0}var hs=["-",".","e","E","+"];function ys(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!["",null,void 0].includes(e)&&/\d+/.test(e)){var n=t.decimalPlaces,r=t.largeNumber,o=t.isToFixed,a=e.replace(/[.|+|\-|e]$/,"");return r&&(a=cs(a)),void 0!==n&&(a=ps(a,n,r)),r||o?a:parseFloat(a)}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Os(t){var n=Su(),o=n.SIZE,a=n.STATUS,c=bo().classPrefix,i=wo(fc(t,"value",t.onChange),2),l=i[0],u=i[1],s=wo(e.useState(""),2),f=s[0],d=s[1],p=wo(e.useState(""),2),m=p[0],v=p[1],g=wo(e.useState(),2),b=g[0],h=g[1],y=e.useRef(null),O=t.max,w=t.min,E=t.largeNumber,j=t.decimalPlaces,P=t.allowInputOverLimit,x=t.onValidate,C=t.disabled||!function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!e&&0!==e||(n&&xo(e)?us(e,t,n)>0:e>t)}(l,t.min,t.largeNumber),_=t.disabled||!function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!e&&0!==e||(n&&xo(e)?us(e,t,n)<0:e<t)}(l,t.max,t.largeNumber),N=r("".concat(c,"-input-number"),o[t.size],I(I(I(I({},a.disabled,t.disabled),"".concat(c,"-is-controls-right"),"column"===t.theme),"".concat(c,"-input-number--").concat(t.theme),t.theme),"".concat(c,"-input-number--auto-width"),t.autoWidth)),k=r("".concat(c,"-input-number__decrease"),I({},a.disabled,C)),S=r("".concat(c,"-input-number__increase"),I({},a.disabled,_)),D=function(e){var n,r;if(!e&&0!==e)return"";var o=e||0===e?String(e):"";if(null===(n=(r=y.current.currentElement).contains)||void 0===n||!n.call(r,document.activeElement)){var a=ys(o,{decimalPlaces:j,largeNumber:E,isToFixed:!0});o=a||0===a?String(a):"",t.format&&(o=String(t.format(e,{fixedNumber:o})))}return o};e.useEffect((function(){var e=[void 0,null].includes(l)?"":String(l);if(!E&&!Number.isNaN(f)){parseFloat(f)!==l&&d(D(e));var t=Number(ps(e,j,E));void 0===j||[void 0,null].includes(l)||Number(t)===Number(l)||u(t,{type:"props",e:void 0})}if(E){var n=D(e);d(n),void 0!==j&&ps(e,j,E)!==l&&u(n,{type:"props",e:void 0})}}),[l]),e.useEffect((function(){if(![void 0,"",null].includes(l)){var e=bs({value:l,max:O,min:w,largeNumber:E});h(e),null==x||x({error:e})}}),[l,O,w,E,x]);var T=function(e){var n=gs({op:e,step:t.step,max:t.max,min:t.min,lastValue:l,largeNumber:t.largeNumber});return{overLimit:bs({value:n,largeNumber:t.largeNumber,max:t.max,min:t.min}),newValue:n}},R=function(e){if(!C&&!t.readonly){var n=T("reduce");n.overLimit&&!P||u(n.newValue,{type:"reduce",e:e})}},A=function(e){if(!_&&!t.readonly){var n=T("add");n.overLimit&&!P||u(n.newValue,{type:"add",e:e})}},M=function(){y.current.focus()};return{classPrefix:c,wrapClasses:N,reduceClasses:k,addClasses:S,inputRef:y,listeners:{onBlur:function(e,n){var r;if(!t.allowInputOverLimit&&void 0!==e){var o=bs({value:l,largeNumber:E,max:O,min:w});if("below-minimum"===o)return void u(w,{type:"blur",e:n.e});if("exceed-maximum"===o)return void u(O,{type:"blur",e:n.e})}var a=ys(e,{decimalPlaces:j,largeNumber:E});d(D(a)),a!==l&&u(a,{type:"blur",e:n.e}),null===(r=t.onBlur)||void 0===r||r.call(t,a,n)},onFocus:function(e,n){var r;d(l),null===(r=t.onFocus)||void 0===r||r.call(t,l,n)},onKeydown:function(e,n){var r,o=n.e,a={ArrowUp:A,ArrowDown:R};void 0!==a[o.key]&&a[o.key](o),null===(r=t.onKeydown)||void 0===r||r.call(t,e,n)},onKeyup:function(e,n){var r;null===(r=t.onKeyup)||void 0===r||r.call(t,e,n)},onKeypress:function(e,n){var r;null===(r=t.onKeypress)||void 0===r||r.call(t,e,n)},onEnter:function(e,n){var r;d(D(e));var o=ys(e,{decimalPlaces:t.decimalPlaces,largeNumber:t.largeNumber});o!==e&&String(o)!==e&&u(o,{type:"enter",e:n.e}),null===(r=t.onEnter)||void 0===r||r.call(t,o,n)},onClick:M,onClear:function(e){var t=e.e;u(void 0,{type:"clear",e:t}),d("")}},displayValue:m,setDisplayValue:v,isError:b,setIsError:h,userInput:f,setUserInput:d,tValue:l,focus:M,blur:function(){y.current.blur()},onChange:u,handleReduce:R,handleAdd:A,onInnerInputChange:function(e,t){var n,r=t.e,o=/^[-+]?\d{1,3}(,\d{3})*(\.(\d*))?$/.test(n=e)?n.replace(/,/g,""):n;if(function(e,t){var n,r;if(["",null,void 0].includes(e))return!0;if("00"===e.slice(0,2))return!1;if(e.match(/\s/g))return!1;if((null===(n=e.match(/\./g))||void 0===n?void 0:n.length)>1)return!1;if((null===(r=e.match(/e/g))||void 0===r?void 0:r.length)>1)return!1;var o=e.slice(1);return!(/(\+|-)/.test(o)&&!/e+/i.test(o)||!(t&&es(e)||!Number.isNaN(Number(e))||hs.includes(e.slice(-1)))||/e/i.test(e)&&!/\de/i.test(e))}(o,E))if(d(o),E)u(o,{type:"input",e:r});else if(function(e,t){return parseFloat(e)!==t&&!Number.isNaN(Number(e))}(String(o),Number(l))){var a=""===o?void 0:Number(o);u(a,{type:"input",e:r})}}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ws={allowInputOverLimit:!0,autoWidth:!1,decimalPlaces:void 0,largeNumber:!1,max:1/0,min:-1/0,placeholder:void 0,readonly:!1,size:"medium",status:"default",step:1,theme:"row"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Es(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function js(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Es(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Es(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ps(t,o){var a=pl({ChevronDownIcon:d,RemoveIcon:p,ChevronUpIcon:m,AddIcon:v}),c=a.ChevronDownIcon,i=a.RemoveIcon,l=a.ChevronUpIcon,u=a.AddIcon,s=ho(t,ws),f=Os(s),g=f.classPrefix,b=f.wrapClasses,h=f.addClasses,y=f.reduceClasses,O=f.listeners,w=f.isError,E=f.inputRef,j=f.userInput,P=f.handleAdd,x=f.handleReduce,C=f.onInnerInputChange,_=e.useRef(null),N=w?"error":s.status,k="column"===s.theme?n.createElement(l,{size:s.size}):n.createElement(u,{size:s.size}),S="column"===s.theme?n.createElement(c,{size:s.size}):n.createElement(i,{size:s.size});return e.useImperativeHandle(o,(function(){return{currentElement:_.current,inputElement:E.current}})),n.createElement("div",{className:r(b,s.className),style:s.style,ref:_},"normal"!==s.theme&&n.createElement(sl,{className:y,disabled:s.disabled,onClick:x,variant:"outline",shape:"square",icon:S}),n.createElement(Cl,js(js({ref:E,autocomplete:"off",disabled:s.disabled,readonly:s.readonly,placeholder:s.placeholder,autoWidth:s.autoWidth,align:s.align||("row"===s.theme?"center":void 0),status:N,label:s.label,suffix:s.suffix,value:j,onChange:C,size:s.size},O),s.inputProps||{})),"normal"!==s.theme&&n.createElement(sl,{className:h,disabled:s.disabled,onClick:P,variant:"outline",shape:"square",icon:k}),s.tips&&n.createElement("div",{className:r("".concat(g,"-input__tips"),"".concat(g,"-input__tips--").concat(N))},s.tips))}var xs=e.forwardRef(Ps);xs.displayName="InputNumber";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Cs=xs;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function _s(t){var n=e.useRef(t);n.current=t;var r=e.useRef();return r.current||(r.current=function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return n.current.apply(this,t)}),r.current}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Ns=Pt,ks=sa,Ss=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Ds=/^\w*$/;var Is=function(e,t){if(Ns(e))return!1;var n=S(e);return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!ks(e))||(Ds.test(e)||!Ss.test(e)||null!=t&&e in Object(t))},Ts=mt;function Rs(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],a=n.cache;if(a.has(o))return a.get(o);var c=e.apply(this,r);return n.cache=a.set(o,c)||a,c};return n.cache=new(Rs.Cache||Ts),n}Rs.Cache=Ts;var As=Rs;var Ms=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ls=/\\(\\)?/g,zs=function(e){var t=As(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Ms,(function(e,n,r,o){t.push(r?o.replace(Ls,"$1"):n||e)})),t})),Bs=Pt,Fs=Is,Vs=zs,Hs=oc;var Ws=function(e,t){return Bs(e)?e:Fs(e,t)?[e]:Vs(Hs(e))},Gs=sa;var Us=function(e){if("string"==typeof e||Gs(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t},Ks=Ws,Zs=Us;var $s=function(e,t){for(var n=0,r=(t=Ks(t,e)).length;null!=e&&n<r;)e=e[Zs(t[n++])];return n&&n==r?e:void 0},Xs=Sn,qs=Ws,Ys=en,Js=Y,Qs=Us;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var ef=function(e,t,n,r){if(!Js(e))return e;for(var o=-1,a=(t=qs(t,e)).length,c=a-1,i=e;null!=i&&++o<a;){var l=Qs(t[o]),u=n;if("__proto__"===l||"constructor"===l||"prototype"===l)return e;if(o!=c){var s=i[l];void 0===(u=r?r(s,l,i):void 0)&&(u=Js(s)?s:Ys(t[o+1])?[]:{})}Xs(i,l,u),i=i[l]}return e},tf=Ws,nf=jt,rf=Pt,of=en,af=xt,cf=Us;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var lf=function(e,t,n){for(var r=-1,o=(t=tf(t,e)).length,a=!1;++r<o;){var c=cf(t[r]);if(!(a=null!=e&&n(e,c)))break;e=e[c]}return a||++r!=o?a:!!(o=null==e?0:e.length)&&af(o)&&of(c,o)&&(rf(e)||nf(e))},uf=jt,sf=Pt,ff=B?B.isConcatSpreadable:void 0;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var df=Pc,pf=function(e){return sf(e)||uf(e)||!!(ff&&e&&e[ff])};var mf=function e(t,n,r,o,a){var c=-1,i=t.length;for(r||(r=pf),a||(a=[]);++c<i;){var l=t[c];n>0&&r(l)?n>1?e(l,n-1,r,o,a):df(a,l):o||(a[a.length]=l)}return a},vf=mf;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var gf=function(e){return(null==e?0:e.length)?vf(e,1):[]},bf=ar,hf=sr;var yf=function(e){return hf(bf(e,void 0,gf),e+"")},Of=$s,wf=ef,Ef=Ws;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var jf=function(e,t){return null!=e&&t in Object(e)},Pf=lf;var xf=function(e,t,n){for(var r=-1,o=t.length,a={};++r<o;){var c=t[r],i=Of(e,c);n(i,c)&&wf(a,Ef(c,e),i)}return a},Cf=function(e,t){return null!=e&&Pf(e,t,jf)};var _f=function(e,t){return xf(e,t,(function(t,n){return Cf(e,n)}))},Nf=yf((function(e,t){return null==e?{}:_f(e,t)})),kf=$s;var Sf=function(e,t,n){var r=null==e?void 0:kf(e,t);return void 0===r?n:r};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Df=function(){};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var If=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Tf={destroyOnClose:!0,placement:"top",showArrow:!0,theme:"default",duration:0},Rf={placement:"top",showArrow:!0,showShadow:!0,theme:"default"},Af=["theme","showArrow","destroyOnClose","overlayClassName","children","duration","placement","onVisibleChange"];function Mf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Lf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Mf(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zf=e.forwardRef((function(t,o){var a=ho(t,Tf),c=a.theme,i=a.showArrow,l=a.destroyOnClose,u=a.overlayClassName,s=a.children,f=a.duration,d=a.placement,p=a.onVisibleChange,m=T(a,Af),v=bo().classPrefix,g=wo(e.useState(!1),2),b=g[0],h=g[1],y=e.useRef(null),O=e.useRef(null),w=r("".concat(v,"-tooltip"),I({},"".concat(v,"-tooltip--").concat(c),c),u);return e.useEffect((function(){var e,t;0===f||b||(null===(e=y.current)||void 0===e||null===(t=e.setVisible)||void 0===t||t.call(e,!0),O.current=window.setTimeout((function(){var e,t;null===(e=y.current)||void 0===e||null===(t=e.setVisible)||void 0===t||t.call(e,!1),h(!0)}),f));return function(){window.clearTimeout(O.current)}}),[f,b]),e.useImperativeHandle(o,(function(){return Lf({},y.current||{})})),n.createElement(Yi,Lf({ref:y,destroyOnClose:l,showArrow:i,overlayClassName:w,onVisibleChange:function(e,t){var n=t.e,r=t.trigger;h(!1),null==p||p(e,{e:n,trigger:r})},placement:d},m),s)}));zf.displayName="Tooltip";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Bf=_a,Ff=Y;var Vf=function(e,t,n){var r=!0,o=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return Ff(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),Bf(e,t,{leading:r,maxWait:t,trailing:o})};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Hf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Wf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Hf(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Gf=function(t){var o=ho(t,Rf),a=o.style,c=o.className,l=o.placement,u=o.showArrow,s=o.theme,f=o.children,d=o.triggerElement,p=o.content,m=o.showShadow,v=e.useRef(null),g=e.useRef(null),b=e.useRef(null),h=bo().classPrefix,y=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=wo(e.useState(t),2),r=n[0],o=n[1];return[r,{on:_s((function(){return o(!0)})),off:_s((function(){return o(!1)})),set:o}]}(),O=wo(y,2),w=O[0],E=O[1],j=wo(e.useState(0),2),P=j[0],x=j[1],C=wo(e.useState(0),2),_=C[0],N=C[1],k=wo(e.useState(null),2),S=k[0],D=k[1],T=dc().keepFade;e.useEffect((function(){v.current&&g.current&&D(function(e,t,n,r,o){var a=e.getBoundingClientRect(),c=t.getBoundingClientRect(),i={top:document.documentElement.scrollTop,left:document.documentElement.scrollLeft};if(a&&c){var l=a.width-c.width;switch(n){case"top":i.left+=a.left+l/2,i.top+=a.top-c.height-16;break;case"bottom":i.left+=a.left+l/2,i.top+=a.top+a.height;break;case"mouse":i.left+=Number(r),i.top+=void 0!==o?Number(o)+16:a.top+a.height+8}if("mouse"===n){var u={top:document.documentElement.scrollTop,left:document.documentElement.scrollLeft,right:document.documentElement.scrollLeft+document.documentElement.clientWidth,bottom:document.documentElement.scrollTop+document.documentElement.clientHeight};i.top>u.bottom-c.height&&(i.top=document.documentElement.scrollTop+a.top-c.height-8),i.left>u.right-c.width&&(i.left=u.right-c.width)}}return i}(v.current,g.current,l,P,_))}),[v.current,g.current,l,w,P,_]);var R,A,M=function(e){x(e.clientX),N(e.clientY)},L=function(e,t){M(t),E.set("on"===e)},z=u&&"mouse"!==l,B=e.useCallback(Vf((function(e){return M(e)}),16.7,{trailing:!0}),[]);return n.createElement("div",null,(R=f||d,A={ref:v,onMouseMove:B,onMouseEnter:function(e){return L("on",e)},onMouseLeave:function(e){return L("off",e)}},n.isValidElement(R)?n.cloneElement(R,Wf({},A)):n.cloneElement(n.createElement("div",null,R),Wf({},A))),w&&n.createElement(So,null,n.createElement(i,Wf({appear:!0,timeout:{appear:180},in:w,nodeRef:b},gc({classPrefix:h,fadeAnimation:T})),n.createElement("div",{className:r("".concat(h,"-popup"),"".concat(h,"-tooltip"),I(I({},"".concat(h,"-tooltip--").concat(s),s),"".concat(h,"-tooltip--noshadow"),!m),c),style:{position:"absolute",left:null==S?void 0:S.left,top:null==S?void 0:S.top},"data-popper-placement":l,ref:b},n.createElement("div",{className:r("".concat(h,"-popup__content"),I({},"".concat(h,"-popup__content--arrow"),z)),ref:g,style:a},p,z&&n.createElement("div",{className:"".concat(h,"-popup__arrow")}))))))};Gf.displayName="Tooltiplite";var Uf=zf,Kf=n.memo(Gf);
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Zf=
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e},$f=Zn,Xf=Tc;var qf=function(e,t){return e&&$f(t,Xf(t),e)},Yf=Zn,Jf=tr;var Qf=function(e,t){return e&&Yf(t,Jf(t),e)},ed=Zn,td=Hc;var nd=function(e,t){return ed(e,td(e),t)},rd=Pc,od=Fn,ad=Hc,cd=Lc,id=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)rd(t,ad(e)),e=od(e);return t}:cd,ld=Zn,ud=id;var sd=function(e,t){return ld(e,ud(e),t)},fd=Mc,dd=id,pd=tr;var md=function(e){return fd(e,pd,dd)},vd=Object.prototype.hasOwnProperty;var gd=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&vd.call(e,"index")&&(n.index=e.index,n.input=e.input),n},bd=Tn;var hd=function(e,t){var n=t?bd(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)},yd=/\w*$/;var Od=function(e){var t=new e.constructor(e.source,yd.exec(e));return t.lastIndex=e.lastIndex,t},wd=B?B.prototype:void 0,Ed=wd?wd.valueOf:void 0;var jd=Tn,Pd=hd,xd=Od,Cd=function(e){return Ed?Object(Ed.call(e)):{}},_d=An;var Nd=function(e,t,n){var r=e.constructor;switch(t){case"[object ArrayBuffer]":return jd(e);case"[object Boolean]":case"[object Date]":return new r(+e);case"[object DataView]":return Pd(e,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return _d(e,n);case"[object Map]":case"[object Set]":return new r;case"[object Number]":case"[object String]":return new r(e);case"[object RegExp]":return xd(e);case"[object Symbol]":return Cd(e)}},kd=di,Sd=vt;var Dd=function(e){return Sd(e)&&"[object Map]"==kd(e)},Id=kt,Td=Zt.exports,Rd=Td&&Td.isMap,Ad=Rd?Id(Rd):Dd,Md=di,Ld=vt;var zd=function(e){return Ld(e)&&"[object Set]"==Md(e)},Bd=kt,Fd=Zt.exports,Vd=Fd&&Fd.isSet,Hd=Vd?Bd(Vd):zd,Wd=pn,Gd=Zf,Ud=Sn,Kd=qf,Zd=Qf,$d=Dn.exports,Xd=Mn,qd=nd,Yd=sd,Jd=Kc,Qd=md,ep=di,tp=gd,np=Nd,rp=Gn,op=Pt,ap=Vt.exports,cp=Ad,ip=Y,lp=Hd,up=Tc,sp=tr,fp="[object Arguments]",dp="[object Function]",pp="[object Object]",mp={};mp[fp]=mp["[object Array]"]=mp["[object ArrayBuffer]"]=mp["[object DataView]"]=mp["[object Boolean]"]=mp["[object Date]"]=mp["[object Float32Array]"]=mp["[object Float64Array]"]=mp["[object Int8Array]"]=mp["[object Int16Array]"]=mp["[object Int32Array]"]=mp["[object Map]"]=mp["[object Number]"]=mp[pp]=mp["[object RegExp]"]=mp["[object Set]"]=mp["[object String]"]=mp["[object Symbol]"]=mp["[object Uint8Array]"]=mp["[object Uint8ClampedArray]"]=mp["[object Uint16Array]"]=mp["[object Uint32Array]"]=!0,mp["[object Error]"]=mp[dp]=mp["[object WeakMap]"]=!1;var vp=function e(t,n,r,o,a,c){var i,l=1&n,u=2&n,s=4&n;if(r&&(i=a?r(t,o,a,c):r(t)),void 0!==i)return i;if(!ip(t))return t;var f=op(t);if(f){if(i=tp(t),!l)return Xd(t,i)}else{var d=ep(t),p=d==dp||"[object GeneratorFunction]"==d;if(ap(t))return $d(t,l);if(d==pp||d==fp||p&&!a){if(i=u||p?{}:rp(t),!l)return u?Yd(t,Zd(i,t)):qd(t,Kd(i,t))}else{if(!mp[d])return a?t:{};i=np(t,d,l)}}c||(c=new Wd);var m=c.get(t);if(m)return m;c.set(t,i),lp(t)?t.forEach((function(o){i.add(e(o,n,r,o,t,c))})):cp(t)&&t.forEach((function(o,a){i.set(a,e(o,n,r,a,t,c))}));var v=f?void 0:(s?u?Qd:Jd:u?sp:up)(t);return Gd(v||t,(function(o,a){v&&(o=t[a=o]),Ud(i,a,e(o,n,r,a,t,c))})),i},gp=$s,bp=Na;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var hp=Ws,yp=If,Op=function(e,t){return t.length<2?e:gp(e,bp(t,0,-1))},wp=Us;var Ep=Cr;var jp=qa,Pp=vp,xp=function(e,t){return t=hp(t,e),null==(e=Op(e,t))||delete e[wp(yp(t))]},Cp=Ws,_p=Zn,Np=function(e){return Ep(e)?void 0:e},kp=md,Sp=yf((function(e,t){var n={};if(null==e)return n;var r=!1;t=jp(t,(function(t){return t=Cp(t,e),r||(r=t.length>1),t})),_p(e,kp(e),n),r&&(n=Pp(n,7,Np));for(var o=t.length;o--;)xp(n,t[o]);return n})),Dp={autoWidth:!1,autofocus:!1,borderless:!1,clearable:!1,creatable:!1,loading:!1,max:0,minCollapsedNum:0,multiple:!1,placeholder:void 0,readonly:!1,reserveKeyword:!1,showArrow:!0,size:"medium",status:"default",valueType:"value"},Ip={divider:!0};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Tp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var Rp=function(t){var o=ho(t,Ip),a=o.children,c=o.label,i=o.selectedValue,l=o.onSelect,u=o.divider,s=o.multiple,f=bo().classPrefix,d=e.Children.map(a,(function(t){if(e.isValidElement(t)){var n={selectedValue:i,onSelect:l,multiple:s};return e.cloneElement(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Tp(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Tp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},n))}return t}));return n.createElement("li",{className:r("".concat(f,"-select-option-group"),I({},"".concat(f,"-select-option-group__divider"),u))},n.createElement("ul",{className:"".concat(f,"-select-option-group__header")},c),n.createElement("ul",{className:"".concat(f,"-select__list")},d))},Ap=function(t){var o,a,c=t.disabled,i=t.label,l=t.title,u=t.selectedValue,s=t.checkAll,f=t.multiple,d=t.size,p=t.max,m=t.keys,v=t.value,g=t.onSelect,b=t.children,h=t.content,y=t.restData,O=t.style,w=t.className,E=t.isVirtual,j=i||v,P=c||f&&Array.isArray(u)&&p&&u.length>=p,x=e.useMemo((function(){return Reflect.has(t,"title")?l:"string"==typeof j?j:null}),[l,j]),C=bo().classPrefix,_=wo(Do(),2),N=_[0],k=_[1];e.useEffect((function(){var e;E&&N&&(null===(e=t.onRowMounted)||void 0===e||e.call(t,{ref:N,data:t}))}),[E,N]),Qi(N),f||(o=zo(u)||xo(u)?v===u:v===Sf(u,(null==m?void 0:m.value)||"value")),f&&Array.isArray(u)&&(o=u.some((function(e){return zo(e)||xo(e)?e===v:Sf(e,(null==m?void 0:m.value)||"value")===v})),t.checkAll&&(o=u.length===t.optionLength,a=u.length>0&&!o));var S;return n.createElement("li",{className:r(w,"".concat(C,"-").concat("select","-option"),I(I(I(I({},"".concat(C,"-is-disabled"),P),"".concat(C,"-is-selected"),o),"".concat(C,"-size-s"),"small"===d),"".concat(C,"-size-l"),"large"===d)),key:v,onClick:function(e){var n;(P||s||g(v,{label:String(j),selected:o,event:e,restData:y}),s)&&(null===(n=t.onCheckAllChange)||void 0===n||n.call(t,o,e))},ref:k,style:O},(S=b,f?n.createElement("label",{className:r("".concat(C,"-checkbox"),I(I(I({},"".concat(C,"-is-indeterminate"),a),"".concat(C,"-is-disabled"),P),"".concat(C,"-is-checked"),o)),title:x},n.createElement("input",{type:"checkbox",className:r("".concat(C,"-checkbox__former")),value:"",disabled:P&&!o,onClick:function(e){e.stopPropagation(),e.nativeEvent.stopImmediatePropagation()}}),n.createElement("span",{className:r("".concat(C,"-checkbox__input"))}),n.createElement("span",{className:r("".concat(C,"-checkbox__label"))},S||h||j)):n.createElement("span",{title:x},S||h||j)))};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Mp(e,t,n){var r=e.props,o=r.value,a=r.label,c=r.children;t[o]=I(I({},(null==n?void 0:n.value)||"value",o),(null==n?void 0:n.label)||"label",a||c||o)}var Lp=function(e,t,n,r,o,a){if(e=Array.isArray(e)?e:[],Array.isArray(e)){var c=To(e),i="object"===r;if(n)c=c.filter((function(e){return i?Cr(t)?Sf(e,(null==o?void 0:o.value)||"value")!==Sf(t,(null==o?void 0:o.value)||"value"):Sf(e,(null==o?void 0:o.value)||"value")!==t:e!==t}));else{var l=i?a:t;c.push(l)}return c}},zp=function(e,t,n,r,o,a){var c,i,l,u,s,f="object"===n,d=[];t?(d=f?e:null==o||null===(i=o.filter)||void 0===i?void 0:i.call(o,(function(t){var n;return null===(n=e.includes)||void 0===n?void 0:n.call(e,t[(null==r?void 0:r.value)||"value"])})).map((function(e){return e[(null==r?void 0:r.value)||"value"]})),c=f?e.find((function(e){return e[(null==r?void 0:r.value)||"value"]===a})):null===(l=d)||void 0===l?void 0:l.find((function(e){return e[(null==r?void 0:r.value)||"value"]===a}))):(d=f?[e]:(null==o||null===(u=o.filter)||void 0===u?void 0:u.call(o,(function(t){return e===t[(null==r?void 0:r.value)||"value"]})))||[],c=f?e:null===(s=d)||void 0===s?void 0:s.find((function(e){return e[(null==r?void 0:r.value)||"value"]===a})));return{currentSelectedOptions:d,currentOption:c}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Bp(e){var t=bo().classPrefix;return n.createElement("svg",{style:e.style,className:r("".concat(t,"-fake-arrow"),I({},"".concat(t,"-fake-arrow--active"),(null==e?void 0:e.isActive)&&!(null!=e&&e.disabled)),null==e?void 0:e.className),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},n.createElement("path",{d:"M3.75 5.7998L7.99274 10.0425L12.2361 5.79921",stroke:"black",strokeOpacity:"0.9",strokeWidth:"1.3"}))}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Fp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Vp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fp(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Hp=["status","clearable","disabled","label","placeholder","readonly","suffix","suffixIcon","onPaste","onEnter","onMouseenter","onMouseleave","size","prefixIcon"],Wp={label:"label",value:"value"};function Gp(t){var o=t.value,a=t.keys,c=t.loading,i=bo().classPrefix,l=e.useRef(),u=wo(fc(t,"inputValue",t.onInputChange),2),s=u[0],f=u[1],d=Vp(Vp({},Nf(t,Hp)),{},{suffixIcon:c?n.createElement(ia,{loading:!0,size:"small"}):t.suffixIcon}),p=function(e){var n,r;null==e||null===(n=e.e)||void 0===n||n.stopPropagation(),null===(r=t.onClear)||void 0===r||r.call(t,e),f("",{trigger:"clear"})},m=function(e,n){t.allowInput&&f(e,Vp(Vp({},n),{},{trigger:"input"}))},v=function(e,n){var r,o=n.e;null===(r=t.onBlur)||void 0===r||r.call(t,e,{e:o,inputValue:e})};return{inputRef:l,commonInputProps:d,singleInputValue:s,onInnerClear:p,renderSelectSingle:function(e){var c,u=t.multiple?null:t.valueDisplay,f=e&&t.allowInput?s:function(e,t){var n=t||Wp;return Y(e)?e[n.label]:e}(o,a);return n.createElement(Cl,Vp(Vp(Vp({ref:l},d),{},{autoWidth:t.autoWidth,placeholder:u?"":t.placeholder,value:u?" ":f,label:(t.label||u)&&n.createElement(n.Fragment,null,t.label,u),onChange:m,readonly:!t.allowInput,onClear:p,onFocus:function(e,n){var r;null===(r=t.onFocus)||void 0===r||r.call(t,o,Vp(Vp({},n),{},{inputValue:e}))},onEnter:function(e,n){var r;null===(r=t.onEnter)||void 0===r||r.call(t,o,Vp(Vp({},n),{},{inputValue:e}))},onBlur:t.panel?null:v},t.inputProps),{},{inputClass:r(null===(c=t.inputProps)||void 0===c?void 0:c.className,I(I({},"".concat(i,"-input--focused"),e),"".concat(i,"-is-focused"),e))}))}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Up="undefined"!=typeof window?n.useInsertionEffect||n.useLayoutEffect:sc;function Kp(){throw new Error("INVALID_USEEVENTCALLBACK_INVOCATION: the callback from useEventCallback cannot be invoked before the component has mounted.")}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Zp(t){var r=t.sortOnDraggable,o=t.onDragSort,a=t.onDragOverCheck,c=wo(e.useState(-1),2),i=c[0],l=c[1],u=wo(e.useState(null),2),s=u[0],f=u[1],d=wo(e.useState(null),2);d[0];var p=d[1],m=wo(e.useState({nodeX:0,nodeWidth:0,mouseX:0}),2),v=m[0],g=m[1],b=function(e){var t=n.useRef(Kp);Up((function(){t.current=e}),[e]);var r=n.useRef(null);return r.current||(r.current=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return t.current.apply(this,n)}),r.current}(o),h=e.useCallback((function(e,t,n){var r;if(e.preventDefault(),i!==t&&-1!==i&&(null==a||!a.targetClassNameRegExp||null!=a&&a.targetClassNameRegExp.test(null===(r=e.target)||void 0===r?void 0:r.className))){if(null!=a&&a.x){if(!v.nodeWidth)return;var o=e.target.getBoundingClientRect(),c=o.x,u=o.width,f=c+u/2,d=(e.clientX||0)-(v.mouseX-v.nodeX),p=d+v.nodeWidth;if(!(d>c&&d<c+u?d<f:p>f))return}b({currentIndex:i,current:s,target:n,targetIndex:t}),l(t)}}),[i,null==a?void 0:a.targetClassNameRegExp,null==a?void 0:a.x,s,v.nodeWidth,v.mouseX,v.nodeX,b]);if(!r)return{};function y(e,t,n){if(l(t),f(n),a){var r=e.target.getBoundingClientRect(),o=r.x,c=r.width;g({nodeX:o,nodeWidth:c,mouseX:e.clientX||0})}}function O(){p(!0)}function w(){p(!1),l(-1),f(null)}return{onDragStart:y,onDragOver:h,onDrop:O,onDragEnd:w,getDragProps:function(e,t){return r?{draggable:!0,onDragStart:function(n){y(n,e,t)},onDragOver:function(n){h(n,e,t)},onDrop:function(){O()},onDragEnd:function(){w()}}:{}},dragging:-1!==i}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var $p=null;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Xp={closable:!1,disabled:!1,icon:void 0,shape:"square",size:"medium",theme:"default",variant:"dark"},qp={disabled:!1,size:"medium"},Yp={multiple:!1,defaultValue:[]},Jp=["theme","size","shape","variant","closable","maxWidth","icon","content","onClick","onClose","className","style","disabled","children","color","title"];function Qp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function em(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qp(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var tm=function(t,o){var a=ho(t,Xp),c=a.theme,i=a.size,l=a.shape,u=a.variant,s=a.closable,f=a.maxWidth,d=a.icon,p=a.content,m=a.onClick,v=void 0===m?sc:m,h=a.onClose,y=void 0===h?sc:h,O=a.className,w=a.style,E=a.disabled,j=a.children,P=a.color,x=a.title,C=T(a,Jp),_=bo().classPrefix,N=pl({CloseIcon:g}).CloseIcon,k="".concat(_,"-tag"),S={large:"".concat(_,"-size-l"),small:"".concat(_,"-size-s")},D=r(k,"".concat(k,"--").concat(c),"".concat(k,"--").concat(u),I(I(I({},"".concat(k,"--").concat(l),"square"!==l),"".concat(k,"--ellipsis"),!!f),"".concat(k,"--disabled"),E),S[i],O),R=n.createElement(N,{onClick:function(e){E||y({e:e})},className:"".concat(k,"__icon-close")}),A=e.useMemo((function(){return Reflect.has(a,"title")?x:j&&"string"==typeof j?j:p&&"string"==typeof p?p:void 0}),[j,p,a,x]),M=A?{title:A}:void 0,L=e.useMemo((function(){if(!P)return w;var e,t,n,r,o=b(P).getLuminance(),a=w||{};if(a.color=o>.5?"black":"white","outline"!==u&&"light-outline"!==u||(a.borderColor=P),"outline"!==u){a.backgroundColor="dark"===u?P:(e=b(P).toRgb(),t=e.r,n=e.g,r=e.b,"rgba(".concat(t,", ").concat(n,", ").concat(r,", 0.1)"))}return"dark"!==u&&(a.color=P),a}),[P,u,w]),z=e.useMemo((function(){return f?{maxWidth:isNaN(Number(f))?String(f):"".concat(f,"px")}:{}}),[f]);return n.createElement("div",em({ref:o,className:D,onClick:function(e){E||v({e:e})},style:L},C),n.createElement(n.Fragment,null,d,n.createElement("span",em({className:f?"".concat(k,"--text"):void 0,style:z},M),null!=j?j:p),s&&!E&&R))},nm=e.forwardRef(tm);nm.displayName="Tag";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var rm=["value","content","onClick","disabled","children","size","checkedProps","uncheckedProps","onChange","className"];function om(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function am(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?om(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):om(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var cm=e.forwardRef((function(t,o){var a=ho(t,qp),c=a.value,i=a.content,l=a.onClick,u=void 0===l?sc:l,s=a.disabled,f=a.children,d=a.size,p=a.checkedProps,m=a.uncheckedProps,v=a.onChange,g=a.className,b=T(a,rm),h=wo(fc(a,"checked",v),2),y=h[0],O=h[1],w=bo().classPrefix,E="".concat(w,"-tag"),j=e.useMemo((function(){return["".concat(E),"".concat(E,"--check"),I(I(I(I({},"".concat(E,"--checked"),y),"".concat(E,"--disabled"),s),"".concat(w,"-size-s"),"small"===d),"".concat(w,"-size-l"),"large"===d),g]}),[y,s,w,E,d,g]),P=e.useMemo((function(){var e=am({theme:"primary"},p),t=am({},m);return y?e:t}),[y,p,m]),x=function(e){var t,n=e.code||(null===(t=e.key)||void 0===t?void 0:t.trim());(Tu.test(n)||Ru.test(n))&&(e.preventDefault(),O(!y,{e:e,value:c}))};return n.createElement(nm,am(am({ref:o,className:r(j),disabled:a.disabled,tabIndex:a.disabled?void 0:0,onFocus:function(e){e.currentTarget.addEventListener("keydown",x)},onBlur:function(e){e.currentTarget.removeEventListener("keydown",x)}},P),{},{onClick:function(e){var t=e.e;s||(null==u||u({e:t}),O(!y,{e:t,value:c}))}},b),i||f)}));cm.displayName="CheckTag";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var im=function(e){var t=ho(e,Yp),r=t.options,o=t.onChange,a=bo().classPrefix,c="".concat(a,"-check-tag-group"),i=wo(fc(t,"value",o),2),l=i[0],u=i[1],s=function(e,n){var r=n.value;if(e)t.multiple?u(l.concat(r),{e:n.e,type:"check",value:r}):u([r],{e:n.e,type:"check",value:r});else{var o=[];t.multiple&&(o=l.filter((function(e){return e!==r}))),u(o,{e:n.e,type:"uncheck",value:r})}};return n.createElement("div",{className:c},null==r?void 0:r.map((function(e){var r,o;return n.createElement(cm,{key:e.value,value:e.value,"data-value":e.value,checkedProps:t.checkedProps,uncheckedProps:t.uncheckedProps,checked:l.includes(e.value),onChange:s,disabled:e.disabled,size:e.size},null!==(r=null!==(o=e.content)&&void 0!==o?o:e.children)&&void 0!==r?r:e.label)})))};im.displayName="CheckTagGroup";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var lm=dl(tm,{CheckTag:cm,CheckTagGroup:im});lm.displayName="Tag";var um=cm;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function sm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function fm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var dm={autoWidth:!1,borderless:!1,clearable:!1,dragSort:!1,excessTagsDisplayType:"break-line",defaultInputValue:"",minCollapsedNum:0,placeholder:void 0,readonly:!1,size:"medium",defaultValue:[]};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function pm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function mm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var vm=e.forwardRef((function(t,o){var a=ho(t,dm),c=bo().classPrefix,i=pl({CloseCircleFilledIcon:f}).CloseCircleFilledIcon,l=a.excessTagsDisplayType,u=a.autoWidth,s=a.borderless,d=a.readonly,p=a.disabled,m=a.clearable,v=a.placeholder,g=a.valueDisplay,b=a.label,h=a.inputProps,y=a.size,O=a.tips,w=a.status,E=a.suffixIcon,j=a.suffix,P=a.prefixIcon,x=a.onClick,C=a.onPaste,_=a.onFocus,N=a.onBlur,k=wo(fc(a,"inputValue",a.onInputChange),2),S=k[0],D=k[1],T=
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function(t){var n=t.readonly,r=t.disabled,o=t.onMouseenter,a=t.onMouseleave,c=wo(e.useState(!1),2),i=c[0],l=c[1];return{isHover:i,addHover:function(e){n||r||(l(!0),null==o||o(e))},cancelHover:function(e){n||r||(l(!1),null==a||a(e))}}}(a),R=T.isHover,A=T.addHover,M=T.cancelHover,L=Zp(mm(mm({},a),{},{sortOnDraggable:a.dragSort,onDragOverCheck:{x:!0,targetClassNameRegExp:new RegExp("^".concat(c,"-tag"))}})).getDragProps,z=e.useRef(!1),B=function(t){var n=e.useRef(),r=t.excessTagsDisplayType,o=void 0===r?"scroll":r,a=t.readonly,c=t.disabled,i=wo(e.useState(0),2),l=i[0],u=i[1],s=wo(e.useState(),2),f=s[0],d=s[1],p=function(e){var t=e.children[0];d(t)},m=function(){f&&u(f.scrollWidth-f.clientWidth)},v=function(e){te(null==f?void 0:f.scroll)&&f.scroll({left:e,behavior:"smooth"})},g=function(){m(),v(l)},b=function(){clearTimeout($p)},h=function(e){e&&p(e)};return e.useEffect((function(){var e;return h(null==n||null===(e=n.current)||void 0===e?void 0:e.currentElement),b}),[]),{initScroll:h,clearScroll:b,tagInputRef:n,scrollElement:f,scrollDistance:l,scrollTo:v,scrollToRight:g,scrollToLeft:function(){v(0)},updateScrollElement:p,updateScrollDistance:m,onWheel:function(e){var t=e.e;if(!a&&!c&&f)if(t.deltaX>0){var n=Math.min(f.scrollLeft+120,l);v(n)}else{var r=Math.max(f.scrollLeft-120,0);v(r)}},scrollToRightOnEnter:function(){"scroll"===o&&($p=setTimeout((function(){g(),clearTimeout($p)}),100))},scrollToLeftOnLeave:function(){"scroll"===o&&(v(0),clearTimeout($p))}}}(a),F=B.scrollToRight,V=B.onWheel,H=B.scrollToRightOnEnter,W=B.scrollToLeftOnLeave,G=B.tagInputRef,U=function(t){var r=bo().classPrefix,o=t.onRemove,a=t.max,c=t.minCollapsedNum,i=t.size,l=t.disabled,u=t.readonly,s=t.tagProps,f=t.tag,d=t.collapsedItems,p=t.getDragProps,m=wo(fc(t,"value",t.onChange),2),v=m[0],g=m[1],b=wo(e.useState(),2);b[0];var h=b[1],y=function(e){var t=To(v),n=wo(t.splice(e.index,1),1)[0];g(t,fm(fm({trigger:"tag-remove"},e),{},{item:n})),null==o||o(fm(fm({},e),{},{item:n,trigger:"tag-remove",value:t}))};return{tagValue:v,clearAll:function(e){g([],{trigger:"clear",e:e.e})},onClose:y,onInnerEnter:function(e,n){var r,o=e?String(e).trim():"",c=v,i=a&&(null==v?void 0:v.length)>=a;o&&!i&&(c=v instanceof Array?v.concat(String(o)):[o],g(c,{trigger:"enter",index:c.length-1,item:o,e:n.e})),null==t||null===(r=t.onEnter)||void 0===r||r.call(t,c,fm(fm({},n),{},{inputValue:e}))},onInputBackspaceKeyDown:function(e,t){var n=t.e;if(v&&v.length&&!u&&!e&&["Backspace","NumpadDelete"].includes(n.key)){var r=v.length-1,a=v[r],c="backspace",i=v.slice(0,-1);g(i,{e:n,index:r,item:a,trigger:c}),null==o||o({e:n,index:r,item:a,trigger:c,value:i})}},onInputBackspaceKeyUp:function(e){v&&v.length&&h(e)},renderLabel:function(o){var a=o.displayNode,m=o.label,g=c?v.slice(0,c):v,b=a?[n.createElement(e.Fragment,{key:"display-node"},a)]:null==g?void 0:g.map((function(e,t){var r=te(f)?f({value:e}):f;return n.createElement(lm,fm(fm({key:t,size:i,disabled:l,onClose:function(e){return y({e:e.e,index:t})},closable:!u&&!l},null==p?void 0:p(t,e)),s),null!=r?r:e)}));if(m&&(null==b||b.unshift(n.createElement("div",{className:"".concat(r,"-tag-input__prefix"),key:"label"},m))),g.length!==v.length){var h=v.length-g.length,O=Array.isArray(null==t?void 0:t.options)?t.options:v,w={value:v,count:v.length-c,collapsedTags:v.slice(c,v.length),collapsedSelectedItems:O.slice(c,v.length),onClose:y},E=te(d)?d(w):d;b.push(n.createElement(e.Fragment,{key:"more"},null!=E?E:n.createElement(lm,fm({size:i},s),"+",h)))}return b}}}(mm(mm({},a),{},{getDragProps:L})),K=U.tagValue,Z=U.onClose,$=U.onInnerEnter,X=U.onInputBackspaceKeyUp,q=U.clearAll,Y=U.renderLabel,J=U.onInputBackspaceKeyDown,Q="".concat(c,"-tag-input"),ee="".concat(c,"-tag-input__with-suffix-icon"),ne="".concat(c,"-tag-input__suffix-clear"),re="".concat(c,"-tag-input--break-line"),oe=null!=K&&K.length?"":v,ae=Boolean(!d&&!p&&m&&R&&(null==K?void 0:K.length));e.useImperativeHandle(o,(function(){return mm({},G.current||{})}));var ce=ae?n.createElement(i,{className:ne,onClick:function(e){var t;q({e:e}),D("",{e:e,trigger:"clear"}),null===(t=a.onClear)||void 0===t||t.call(a,{e:e})}}):E,ie=te(g)?g({value:K,onClose:function(e){return Z({index:e})}}):g,le=!(Array.isArray(K)&&K.length),ue=[Q,I(I(I(I({},re,"break-line"===l),ee,!!ce),"".concat(c,"-is-empty"),le),"".concat(c,"-tag-input--with-tag"),!le),a.className];return n.createElement(Cl,mm({ref:G,value:S,onChange:function(e,t){D(e,mm(mm({},t),{},{trigger:"input"}))},autoWidth:!0,onWheel:V,size:y,borderless:s,readonly:d,disabled:p,label:Y({displayNode:ie,label:b}),className:r(ue),style:a.style,tips:O,status:w,placeholder:oe,suffix:j,prefixIcon:P,suffixIcon:ce,showInput:!(null!=h&&h.readonly&&K&&null!=K&&K.length),keepWrapperWidth:!u,onPaste:C,onClick:function(e){var t,n;a.disabled||a.readonly||(null===(t=G.current)||void 0===t||null===(t=t.inputElement)||void 0===t||null===(n=t.focus)||void 0===n||n.call(t));null==x||x(e)},onEnter:function(e,t){D("",{e:t.e,trigger:"enter"}),!z.current&&$(e,t),F()},onKeydown:J,onKeyup:X,onMouseenter:function(e){A(e),H()},onMouseleave:function(e){M(e),W()},onFocus:function(e,t){null==_||_(K,{e:t.e,inputValue:e})},onBlur:function(e,t){S&&D("",{e:t.e,trigger:"blur"}),null==N||N(K,{e:t.e,inputValue:""})},onCompositionstart:function(e,t){var n;z.current=!0,null==h||null===(n=h.onCompositionstart)||void 0===n||n.call(h,e,t)},onCompositionend:function(e,t){var n;z.current=!1,null==h||null===(n=h.onCompositionend)||void 0===n||n.call(h,e,t)}},h))}));vm.displayName="TagInput";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var gm=vm;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function bm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function hm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ym={label:"label",key:"key",children:"children"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Om(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function wm(t,n){var r=t.popupProps,o=t.autoWidth,a=t.readonly,c=t.disabled,i=t.onPopupVisibleChange,l=t.allowInput,u=wo(fc(t,"popupVisible",i),2),s=u[0],f=u[1],d=function(e,t){if(e&&t){t.style.display="";var n=t.offsetWidth-t.scrollWidth,o=t.offsetWidth-n>e.offsetWidth?t.scrollWidth:e.offsetWidth-n,a={};return r&&"object"===S(r.overlayInnerStyle)&&!r.overlayInnerStyle.width&&(a=r.overlayInnerStyle),function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Om(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Om(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({width:"".concat(Math.min(o,1e3),"px")},a)}};return{tOverlayInnerStyle:e.useMemo((function(){var e={},t=(null==r?void 0:r.overlayInnerStyle)||{};return te(t)||Y(t)&&t.width?e=t:o||(e=d),e}),[o,null==r?void 0:r.overlayInnerStyle]),innerPopupVisible:s,onInnerPopupVisibleChange:function(e,r){if(!c&&!a){var o,i=!("trigger-element-click"!==r.trigger||!l)||e;if(t.popupVisible!==i)if(f(i,r),!i)null==n||null===(o=n.afterHidePopup)||void 0===o||o.call(n,r)}}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Em={allowInput:!1,autoWidth:!1,autofocus:!1,borderless:!1,clearable:!1,loading:!1,minCollapsedNum:0,multiple:!1,readonly:!1,reserveKeyword:!1,status:"default"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function jm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Pm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var xm=n.forwardRef((function(t,o){var a=ho(t,Em),c=e.useRef(),i=e.useRef(null),l=bo().classPrefix,u=a.multiple,s=a.value,f=a.popupVisible,d=a.popupProps,p=a.borderless,m=a.disabled,v=Gp(a),g=v.commonInputProps,b=v.inputRef,h=v.singleInputValue,y=v.onInnerClear,O=v.renderSelectSingle,w=function(t){var o=t.value,a=bo().classPrefix,c=e.useRef(),i=wo(fc(t,"inputValue",t.onInputChange),2),l=i[0],u=i[1],s=hm(hm({},ym),t.keys),f=o instanceof Array?o.map((function(e){return Y(e)?e[s.label]:e})):["",null,void 0].includes(o)?[]:Y(o)?[o[s.label]]:[o],d=f&&f.length?"":t.placeholder,p=function(e,n){var r,o;"tag-remove"===n.trigger&&(null===(o=n.e)||void 0===o||o.stopPropagation()),null===(r=t.onTagChange)||void 0===r||r.call(t,e,n)};return{tags:f,tPlaceholder:d,tagInputRef:c,multipleInputValue:l,renderSelectMultiple:function(e){var o;return n.createElement(gm,hm(hm(hm({ref:c},e.commonInputProps),{},{autoWidth:t.autoWidth,readonly:t.readonly,minCollapsedNum:t.minCollapsedNum,collapsedItems:t.collapsedItems,tag:t.tag,valueDisplay:t.valueDisplay,placeholder:d,options:t.options,value:f,inputValue:e.popupVisible&&e.allowInput?l:"",onChange:p,onInputChange:function(e,t){"enter"!==(null==t?void 0:t.trigger)&&"blur"!==(null==t?void 0:t.trigger)&&u(e,{trigger:t.trigger,e:t.e})},tagProps:t.tagProps,onClear:e.onInnerClear,onFocus:function(e,n){var r;null===(r=t.onFocus)||void 0===r||r.call(t,t.value,hm(hm({},n),{},{tagInputValue:e}))},onBlur:t.panel?null:t.onBlur},t.tagInputProps),{},{inputProps:hm(hm({},t.inputProps),{},{readonly:!t.allowInput||t.readonly,inputClass:r(null===(o=t.tagInputProps)||void 0===o?void 0:o.className,I(I({},"".concat(a,"-input--focused"),e.popupVisible),"".concat(a,"-is-focused"),e.popupVisible))})}))}}}(a),E=w.tagInputRef,j=w.multipleInputValue,P=w.renderSelectMultiple,x=wm(a,{afterHidePopup:function(e){var t,n=a.multiple?j:h,r={e:e.e,inputValue:n};null===(t=a.onBlur)||void 0===t||t.call(a,a.value,r)}}),C=x.tOverlayInnerStyle,_=x.innerPopupVisible,N=x.onInnerPopupVisibleChange,k=r([a.className,"".concat(l,"-select-input"),I(I(I(I({},"".concat(l,"-select-input--borderless"),p),"".concat(l,"-select-input--multiple"),u),"".concat(l,"-select-input--popup-visible"),null!=f?f:_),"".concat(l,"-select-input--empty"),s instanceof Array?!s.length:!s)]);e.useImperativeHandle(o,(function(){return Pm(Pm(Pm({},c.current||{}),b.current||{}),E.current||{})}));var S={visible:null!=f?f:_};var D=n.createElement("div",{className:k,style:a.style},n.createElement(Yi,Pm(Pm(Pm({ref:c,trigger:(null==d?void 0:d.trigger)||"click",placement:"bottom-left",content:a.panel,hideEmptyPopup:!0,onVisibleChange:N,updateScrollTop:a.updateScrollTop},S),d),{},{disabled:m,overlayInnerStyle:C}),u?P({commonInputProps:g,onInnerClear:y,popupVisible:S.visible,allowInput:a.allowInput}):O(S.visible)));return a.tips?n.createElement("div",{ref:i,className:"".concat(l,"-select-input__wrap")},D,a.tips&&n.createElement("div",{className:"".concat(l,"-input__tips ").concat(l,"-input__tips--").concat(a.status||"normal")},a.tips)):D}));xm.displayName="SelectInput";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Cm=xm;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function _m(t,n){var r=null,o=function(){r&&t&&(r.unobserve(t),te(r.disconnect)&&r.disconnect(),r=null)};e.useLayoutEffect((function(){var e;if("undefined"!=typeof window&&window.ResizeObserver)return o(),t&&(e=t,(r=new ResizeObserver(n)).observe(e)),function(){o()}}),[t,r])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Nm="undefined"!=typeof window&&window.requestAnimationFrame||function(e){return setTimeout(e,16.6)},km=function(t){var n=t.popupContentRef,r=t.scroll,o=t.options,a=t.size,c=(null==r?void 0:r.threshold)||100,i=null==r?void 0:r.type,l=e.useMemo((function(){return"virtual"===i&&(null==o?void 0:o.length)>c}),[i,c,o]),u=e.useMemo((function(){var e={small:20,medium:28,large:36}[a]||28;return{type:"virtual",isFixedRowHeight:(null==r?void 0:r.isFixedRowHeight)||!1,rowHeight:(null==r?void 0:r.rowHeight)||e,bufferSize:(null==r?void 0:r.bufferSize)||20,threshold:c}}),[r,c,a]),s=function(t,n){var r=n.data,o=n.scroll,a=wo(e.useState([]),2),c=a[0],i=a[1],l=wo(e.useState((function(){return((null==r?void 0:r.length)||0)*((null==o?void 0:o.rowHeight)||50)})),2),u=l[0],s=l[1],f=wo(e.useState(0),2),d=f[0],p=f[1],m=e.useRef([]),v=wo(e.useState([]),2),g=v[0],b=v[1],h=e.useRef(0),y=e.useRef(0),O=wo(e.useState((function(){return[0,3*((null==o?void 0:o.bufferSize)||10)]})),2),w=O[0],E=O[1],j=e.useMemo((function(){var e;return o?{bufferSize:o.bufferSize||10,isFixedRowHeight:null!==(e=o.isFixedRowHeight)&&void 0!==e&&e,rowHeight:o.rowHeight||47,threshold:o.threshold||100,type:o.type}:{}}),[o]),P=e.useMemo((function(){return"virtual"===j.type&&j.threshold<r.length}),[j,r]),x=function(e){for(var t=[],n=0,o=r.length;n<o;n++)t[n]=(t[n-1]||0)+(e[n]||j.rowHeight);return t},C=function(e,n){for(var o=-1,a=0,c=e.length;a<c;a++)if(e[a]>=n){o=a;break}for(var l=e.length,u=n+(y.current||t.current.getBoundingClientRect().height),f=o,d=e.length;f<d;f++)if(e[f]>=u){l=f;break}if(!(o<0)){var p=Math.max(o-j.bufferSize,0),m=Math.min(l+j.bufferSize,e.length);if(w.join()!==[p,m].join()&&p>=0){var v=r.slice(p,m);i(v);var g=e[p-1];s(g>0?g:0),E([p,m])}}},_=function(){P&&C(m.current,t.current.scrollTop)},N=function(e){var n,r=e.index,o=e.top,a=void 0===o?0:o,c=e.behavior,i=m.current[r]-a;null===(n=t.current)||void 0===n||n.scrollTo({top:i,behavior:c||"auto"})};return _m(P?t.current:void 0,(function(e){var n=wo(e,1)[0].contentRect;Math.abs(n.width-h.current)>16&&(t.current.scrollTop=0,_()),h.current=n.width,y.current=n.height})),e.useEffect((function(){if(P){r.forEach((function(e,t){e.__VIRTUAL_SCROLL_INDEX=t})),p(r.length*j.rowHeight);var e=wo(w,2),n=e[0],o=e[1],a=r.slice(n,o);i(a);var c=setTimeout((function(){if(t.current){var e=t.current.getBoundingClientRect().height;y.current=e;var n=x(g);m.current=n,clearTimeout(c)}}),1)}else m.current=x(g)}),[t,r,j,P,w,g]),{visibleData:c,translateY:u,scrollHeight:d,isVirtualScroll:P,handleScroll:_,handleRowMounted:function(e){if(P&&e&&!j.isFixedRowHeight&&null!=t&&t.current){var n=e.ref.offsetHeight,r=e.data.__VIRTUAL_SCROLL_INDEX,o=g;if(o[r]!==n){o[r]=n,b(o);var a=x(o);m.current=a;var c=a.length-1;p(a[c]-y.current),C(a,t.current.scrollTop)}}},scrollToElement:function(e){N(e),j.isFixedRowHeight||Nm((function(){var t,n=null!==(t=e.time)&&void 0!==t?t:60,r=setTimeout((function(){N(e),clearTimeout(r)}),n)}))}}}(n,{data:o||[],scroll:u}),f=s.visibleData,d=void 0===f?null:f,p=s.handleScroll,m=void 0===p?null:p,v=s.scrollHeight,g=void 0===v?null:v,b=s.translateY,h=void 0===b?null:b,y=s.handleRowMounted,O=void 0===y?null:y,w=-1,E=e.useCallback((function(e){if(l){var t=e.target.scrollTop;Math.abs(w-t)>5?(m(),w=t):w=-1}}),[]);e.useEffect((function(){var e,t=null==n?void 0:n.current;l&&(null==t||null===(e=t.addEventListener)||void 0===e||e.call(t,"scroll",E));return function(){var e;l&&(null==t||null===(e=t.removeEventListener)||void 0===e||e.call(t,"scroll",E))}}),[l,E,n.current]);var j={position:"absolute",width:"1px",height:"1px",transition:"transform 0.2s",transform:"translate(0, ".concat(g,"px)"),MsTransform:"translate(0, ".concat(g,"px)"),MozTransform:"translate(0, ".concat(g,"px)"),WebkitTransform:"translate(0, ".concat(g,"px)")},P={transform:"translate(0, ".concat(h,"px)"),MsTransform:"translate(0, ".concat(h,"px)"),MozTransform:"translate(0, ".concat(h,"px)"),WebkitTransform:"translate(0, ".concat(h,"px)")};return{scrollHeight:g,translateY:h,visibleData:d,handleRowMounted:O,isVirtual:l,cursorStyle:j,panelStyle:P}},Sm=["value","label","disabled","content","children"];function Dm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Im(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Dm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Tm=n.forwardRef((function(t,o){var a=t.value,c=t.size,i=t.max,l=t.multiple,u=t.showPopup,s=t.setShowPopup,f=t.empty,d=t.loadingText,p=t.loading,m=t.valueType,v=t.children,g=t.keys,b=t.panelTopContent,h=t.panelBottomContent,y=t.onChange,O=t.onCheckAllChange,w=t.getPopupInstance,E=t.options,j=t.scroll,P=wo(yl("select"),2),x=P[0],C=(0,P[1])(x.empty),_=e.useRef(null);_.current=w();var N=km({popupContentRef:_,scroll:j,options:E,size:c}),k=N.visibleData,S=N.handleRowMounted,D=N.isVirtual,R=N.panelStyle,A=N.cursorStyle,M=bo().classPrefix;if(!v&&!E)return null;var L=function(e,t){var n=t.label,r=t.selected,o=t.event,c=t.restData,i={};if("object"===m&&(i=Im({},c),null!=g&&g.label||Object.assign(i,{label:n}),null!=g&&g.value||Object.assign(i,{value:e})),Object.keys(i).length||Object.assign(i,I(I({},(null==g?void 0:g.label)||"label",n),(null==g?void 0:g.value)||"value",e)),l){var f=Lp(a,e,r,m,g,i);y(f,{label:n,value:e,e:o,trigger:"check"})}else{var d="object"===m?i:e;y(d,{label:n,value:d,e:o,trigger:"check"}),s(!u)}},z=e.Children.map(v,(function(t){if(e.isValidElement(t)){var n={size:c,max:i,multiple:l,selectedValue:a,onSelect:L};return e.cloneElement(t,Im({},n))}return t})),B=Array.isArray(z)&&!z.length||E&&0===E.length,F=function(e,t){return n.createElement("div",{ref:o,className:r("".concat(M,"-select__dropdown-inner"),I(I(I({},"".concat(M,"-select__dropdown-inner--size-s"),"small"===c),"".concat(M,"-select__dropdown-inner--size-l"),"large"===c),"".concat(M,"-select__dropdown-inner--size-m"),"medium"===c)),style:t},p&&n.createElement("div",{className:"".concat(M,"-select__loading-tips")},d),!p&&B&&n.createElement("div",{className:"".concat(M,"-select__empty")},f||n.createElement("p",null,C)),!p&&!B&&function(e){if(e){var t=[];e.forEach((function(e){-1===t.findIndex((function(t){return t.label===e.label&&t.value===e.value}))&&t.push(e)}));var r=t.filter((function(e){return!e.disabled&&!e.checkAll}));return n.createElement("ul",{className:"".concat(M,"-select__list")},t.map((function(e,t){var o=e.value,u=e.label,s=e.disabled,f=e.content,d=e.children,p=T(e,Sm);return n.createElement(Ap,Im(Im({key:t,max:i,label:u,value:o,onSelect:L,selectedValue:a,optionLength:r.length,multiple:l,size:c,disabled:s,restData:p,keys:g,content:f,onCheckAllChange:O,onRowMounted:S},D?{isVirtual:D,bufferSize:null==j?void 0:j.bufferSize,scrollType:null==j?void 0:j.type}:{}),p),d)})))}return n.createElement("ul",{className:"".concat(M,"-select__list")},z)}(e))};return D?n.createElement(n.Fragment,null,b,n.createElement("div",null,n.createElement("div",{style:A}),F(k,R)),h):n.createElement(n.Fragment,null,b,F(E),h)}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Rm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Am(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Mm(t,r,o,a,c,i){var l=wo(e.useState({}),2),u=l[0],s=l[1],f=wo(e.useState([]),2),d=f[0],p=f[1],m=wo(e.useState([]),2),v=m[0],g=m[1],b=wo(e.useState([]),2),h=b[0],y=b[1];return e.useEffect((function(){var e=r,a=n.Children.toArray(o),c=a.filter((function(e){return e.type===Ap})),l=a.length>0&&c.length===a.length;if(!(i&&d.length&&l)){var u;if(l&&(e=null==a?void 0:a.map((function(e){return n.isValidElement(e)?Am(Am({},e.props),{},{label:e.props.label||e.props.children}):{label:e}}))),t)e=null===(u=e)||void 0===u?void 0:u.map((function(e){return Am(Am({},e),{},{value:Sf(e,(null==t?void 0:t.value)||"value"),label:Sf(e,(null==t?void 0:t.label)||"label")})}));p(e),g(e),s(function(e,t,n){var r={};if(Array.isArray(t))return t.forEach((function(e){r[Sf(e,(null==n?void 0:n.value)||"value")]=e})),r;if(Cr(e)){if(e.type===Ap)return Mp(e,r,n),r;if(e.type===Rp){var o=e.props.children;if(Array.isArray(o))return o.forEach((function(e){Mp(e,r,n)})),r}}return Array.isArray(e)&&e.forEach((function(e){if(e.type===Ap&&Mp(e,r,n),e.type===Rp){var t=e.props.children;Array.isArray(t)&&t.forEach((function(e){Mp(e,r,n)}))}})),r}(o,r,t)||{})}}),[r,t,o,i]),e.useEffect((function(){y((function(e){var n=(null==t?void 0:t.value)||"value",r=(null==t?void 0:t.label)||"label";return Array.isArray(c)?c.map((function(t){return"value"===a?u[t]||e.find((function(e){return Sf(e,n)===t}))||I(I({},n,t),r,t):t})).filter(Boolean):null!=c?"value"===a?[u[c]||e.find((function(e){return Sf(e,n)===c}))||I(I({},n,c),r,c)].filter(Boolean):[c]:[]}))}),[c,t,a,u,y]),{currentOptions:d,setCurrentOptions:p,tmpPropOptions:v,setTmpPropOptions:g,valueToOption:u,setValueToOption:s,selectedOptions:h,setSelectedOptions:y}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Lm=["overlayClassName","onScroll","onScrollToBottom"];function zm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Bm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Fm=dl((function(t,o){var a=ho(t,Dp),c=wo(yl("select"),2),i=c[0],l=c[1],u=l(i.loadingText),s=a.readonly,f=a.borderless,d=a.autoWidth,p=a.creatable,m=a.loadingText,v=void 0===m?u:m,g=a.max,b=a.popupProps,h=a.reserveKeyword,y=a.className,O=a.style,w=a.disabled,E=a.size,j=a.multiple,P=a.placeholder,x=a.clearable,C=a.prefixIcon,_=a.options,N=a.filterable,k=a.loading,S=a.empty,D=a.valueType,I=a.keys,R=a.children,A=a.collapsedItems,M=a.minCollapsedNum,L=a.valueDisplay,z=a.showArrow,B=a.inputProps,F=a.panelBottomContent,V=a.panelTopContent,H=a.selectInputProps,W=a.tagInputProps,G=a.tagProps,U=a.scroll,K=a.suffixIcon,Z=a.label,$=a.filter,X=a.onFocus,q=a.onBlur,Y=a.onClear,J=void 0===Y?sc:Y,Q=a.onCreate,ee=a.onRemove,ne=a.onSearch,re=a.onEnter,oe=a.onPopupVisibleChange,ae=wo(fc(a,"value",a.onChange),2),ce=ae[0],ie=ae[1],le=e.useRef(null),ue=bo().classPrefix,se=b||{},fe=se.overlayClassName,de=se.onScroll,pe=se.onScrollToBottom,me=T(se,Lm),ve=wo(e.useState(!1),2),ge=ve[0],be=ve[1],he="".concat(ue,"-select"),ye=wo(fc(a,"popupVisible",oe),2),Oe=ye[0],we=ye[1],Ee=wo(fc(a,"inputValue",a.onInputChange),2),je=Ee[0],Pe=Ee[1],xe=Mm(I,_,R,D,ce,h),Ce=xe.currentOptions,_e=xe.setCurrentOptions,Ne=xe.tmpPropOptions,ke=xe.valueToOption,Se=xe.selectedOptions,De=e.useMemo((function(){return j?Se.map((function(e){return Sf(e||{},(null==I?void 0:I.label)||"label")||""})):Sf(Se[0]||{},(null==I?void 0:I.label)||"label")||void 0}),[Se,I,j]),Ie=function(e,t){w||(e&&be(!1),!e&&Pe("",{trigger:"blur"}),we(e,t))},Te=function(e,t){var n;if(j){var r=Ce.filter((function(e){return!e.checkAll&&!e.disabled})).map((function(e){return"object"===D?e:e[(null==I?void 0:I.value)||"value"]})),o=zp(r,j,D,I,Ne).currentSelectedOptions,c=e||o.length===(null===(n=a.value)||void 0===n?void 0:n.length)?[]:o;null==ie||ie(c,{e:t,trigger:e?"check":"uncheck",selectedOptions:c})}},Re=function(e,t){j&&!h&&je&&Pe("",{e:t.e,trigger:"change"}),p&&te(Q)&&0===_.filter((function(t){return t.value===e})).length&&Q(e);var n=j?t.value:e,r=zp(e,j,D,I,Ne,n),o=r.currentSelectedOptions,a=r.currentOption;null==ie||ie(e,{e:t.e,trigger:t.trigger,selectedOptions:o,option:a})};e.useEffect((function(){void 0!==je&&function(e){var t=[];if(!N||!te(ne))if(e){if($&&te($))Array.isArray(Ne)?t=Ne.filter((function(t){return $(e,t)})):Array.isArray(Object.values(ke))&&(t=Object.values(ke).filter((function(t){return $(e,t)})));else if(Array.isArray(Ne)){var n=e.toUpperCase();t=Ne.filter((function(e){return((null==e?void 0:e.label)||"").toUpperCase().includes(n)}))}var r=t.find((function(t){return t.label===e}));p&&!r&&(t=t.concat([{label:e,value:e}])),_e(t)}else _e(Ne)}(String(je))}),[je,Ne]);var Ae,Me=e.useCallback((function(){var e;return null===(e=le.current)||void 0===e?void 0:e.getPopupContentElement()}),[]),Le=e.Children.map(R,(function(t){if(e.isValidElement(t)){var n={multiple:j};return e.cloneElement(t,Bm({},n))}return t})),ze=a.onMouseEnter,Be=a.onMouseLeave;return n.createElement("div",{className:r("".concat(he,"__wrap"),y),style:O,onMouseEnter:ze,onMouseLeave:Be},n.createElement(Cm,Bm({autoWidth:!(null!=O&&O.width)&&d,ref:mc(o,le),className:he,readonly:s,autofocus:a.autofocus,allowInput:(null!=N?N:i.filterable)||te($),multiple:j,value:De,options:Se,valueDisplay:L?"string"==typeof L?L:j?function(e){var t=e.onClose;return al(L,{value:Se,onClose:t})}:al(L,{value:De,onClose:sc}):j?function(e){var t=e.value;return t.slice(0,M||t.length).map((function(e,t){var r=null==_?void 0:_.find((function(t){return t.label===e}));return n.createElement(lm,Bm(Bm({key:t,closable:!(null!=r&&r.disabled||w||s),size:E},G),{},{onClose:function(n){var r,o=n.e;o.stopPropagation();var a=Lp(ce,ce[t],!0,D,I),c=zp(a,j,D,I,Ne,ce).currentSelectedOptions;ie(a,{e:o,selectedOptions:c,trigger:"uncheck"}),null==G||null===(r=G.onClose)||void 0===r||r.call(G,{e:o}),null==ee||ee({value:ce[t],data:{label:e,value:ce[t]},e:o})}}),e)}))}:"string"!=typeof De?De:"",clearable:x,disabled:w,status:a.status,tips:a.tips,borderless:f,label:Z,suffix:a.suffix,prefixIcon:C,suffixIcon:K||(k?n.createElement(ia,{className:r("".concat(he,"__right-icon"),"".concat(he,"__active-icon")),loading:!0,size:"small"}):z&&n.createElement(Bp,{className:"".concat(he,"__right-icon"),isActive:Oe,disabled:w})),panel:(Ae={onChange:Re,value:ce,className:y,size:E,multiple:j,showPopup:Oe,setShowPopup:function(e){return Ie(e,{})},options:Ce,empty:S,max:g,loadingText:v,loading:k,valueType:D,keys:I,panelBottomContent:F,panelTopContent:V,onCheckAllChange:Te,getPopupInstance:Me,scroll:U},n.createElement(Tm,Bm({},Ae),Le)),placeholder:!j&&Oe&&De?De:P||l(i.placeholder),inputValue:je,tagInputProps:Bm({size:E},W),tagProps:Bm({size:E},G),inputProps:Bm({size:E},B),minCollapsedNum:M,collapsedItems:A,updateScrollTop:function(e){if(e&&!ge){var t=e.querySelector(".".concat(ue,"-is-selected"));if(!j&&t){var n=getComputedStyle(t).paddingBottom,r=getComputedStyle(e).marginBottom,o=parseInt(n,10)+parseInt(r,10),a=function(e,t){for(var n=e.offsetTop,r=e.offsetParent;r&&r!==t;)n+=r.offsetTop,r=r.offsetParent;return n}(t,e)-e.offsetTop-(e.clientHeight-t.clientHeight)+o;setTimeout((function(){e.scrollTop=a}))}}},popupProps:Bm({overlayClassName:["".concat(he,"__dropdown"),fe],onScroll:function(e){var t=e.e;if(be(!0),null==de||de({e:t}),pe){var n=_a((function(e){return pe({e:e})}),100),r=t.target,o=r.scrollTop,a=r.clientHeight,c=r.scrollHeight;a+Math.floor(o)===c&&n(t)}}},me),popupVisible:Oe,onPopupVisibleChange:Ie,onTagChange:function(e,t){var n=t.trigger,r=t.index,o=t.item,a=t.e;if("backspace"!==n){if("clear"===n)return a.stopPropagation(),void ie([],{e:a,trigger:n,selectedOptions:[]});if("tag-remove"===n){var c;null==a||null===(c=a.stopPropagation)||void 0===c||c.call(a);var i=Lp(ce,ce[r],!0,D,I),l=zp(i,j,D,I,Ne).currentSelectedOptions;ie(i,{e:a,trigger:n,selectedOptions:l}),te(ee)&&ee({value:ce[r],data:{label:o,value:ce[r]},e:a})}}else{a.stopPropagation();for(var u=-1,s=r;s>=0;){var f;if(null===(f=Se[s])||void 0===f||!f.disabled){u=s;break}s-=1}if(u<0)return;var d=Lp(ce,ce[u],!0,D,I),p=zp(d,j,D,I,Ne).currentSelectedOptions;ie(d,{e:a,trigger:n,selectedOptions:p})}},onInputChange:function(e,t){"clear"!==t.trigger&&Pe(e,{e:t.e,trigger:"input"}),void 0!==e&&te(ne)&&ne(e,{e:t.e})},onFocus:X,onEnter:function(e,t){null==re||re(Bm(Bm({},t),{},{value:ce}))},onBlur:function(e,t){null==q||q({value:ce,e:t.e})},onClear:function(e){e.e.stopPropagation(),Array.isArray(ce)?ie([],Bm(Bm({},e),{},{selectedOptions:[]})):ie(null,Bm(Bm({},e),{},{selectedOptions:[]})),J(e)}},H)))}),{Option:Ap,OptionGroup:Rp});Fm.displayName="Select";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Vm=Fm;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Hm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Wm(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Hm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Gm={closeBtn:!0,footer:!0,header:!0,theme:"default"},Um={closeOnEscKeydown:void 0,closeOnOverlayClick:void 0,destroyOnClose:!1,draggable:!1,mode:"modal",placement:"top",preventScrollThrough:!0,showInAttachedElement:!1,showOverlay:!0},Km=["theme","header","closeBtn","footer","body","children","className","onCancel","onConfirm","onCloseBtnClick","cancelBtn","confirmBtn","confirmLoading"];function Zm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Zm(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zm(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Xm=function(t,r){var o=null;return xo(t)?o=n.createElement(sl,$m({},r),t):e.isValidElement(t)?o=t:Y(t)?o=n.createElement(sl,$m($m({},r),t)):te(t)&&(o=t()),o},qm=e.forwardRef((function(e,t){var o,a,c,i=bo().classPrefix,l="".concat(i,"-dialog"),u=pl({CloseIcon:g,InfoCircleFilledIcon:h,CheckCircleFilledIcon:y}),s=u.CloseIcon,f=u.InfoCircleFilledIcon,d=u.CheckCircleFilledIcon,p=wo(yl("dialog"),2),m=p[0],v=p[1],b=v(m.confirm),O=v(m.cancel),w=ho(e,Gm),E=w.theme,j=w.header,P=w.closeBtn,x=w.footer,C=w.body,_=w.children,N=w.className,k=w.onCancel,S=w.onConfirm,D=w.onCloseBtnClick,I=w.cancelBtn,R=void 0===I?O:I,A=w.confirmBtn,M=void 0===A?b:A,L=w.confirmLoading,z=T(w,Km);return n.createElement("div",$m($m({ref:t},z),{},{className:r(l,"".concat(l,"--default"),N)}),!!j&&n.createElement("div",{className:r("".concat(l,"__header"))},(c={info:n.createElement(f,{className:"".concat(i,"-is-info")}),warning:n.createElement(f,{className:"".concat(i,"-is-warning")}),error:n.createElement(f,{className:"".concat(i,"-is-error")}),danger:n.createElement(f,{className:"".concat(i,"-is-error")}),success:n.createElement(d,{className:"".concat(i,"-is-success")})},n.createElement("div",{className:"".concat(l,"__header-content")},c[E],j)),P?n.createElement("span",{className:"".concat(l,"__close"),style:{marginLeft:"auto"},onClick:function(e){return null==D?void 0:D({e:e})}},!0===P?n.createElement(s,null):P):null),n.createElement("div",{className:"".concat(l,"__body")},C||_),!!x&&n.createElement("div",{className:"".concat(l,"__footer")},ol(x,null,(o=Xm(R,{variant:"outline",onClick:function(e){return null==k?void 0:k({e:e})}}),a=Xm(M,{theme:"primary",loading:L,onClick:function(e){return null==S?void 0:S({e:e})}}),n.createElement(n.Fragment,null,o,a)))))}));qm.displayName="DialogCard";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Ym=new Set,Jm=1;function Qm(t){var n=t.preventScrollThrough,r=t.visible,o=t.mode,a=t.showInAttachedElement,c=e.useRef(null),i=e.useRef(null),l=e.useCallback((function(){clearTimeout(i.current),i.current=setTimeout((function(){var e,t;null===(e=c.current.parentNode)||void 0===e||null===(t=e.removeChild)||void 0===t||t.call(e,c.current)}),150)}),[]);fl((function(){if("undefined"!=typeof document){c.current||(c.current=document.createElement("style"));var e=document.documentElement.scrollHeight>document.documentElement.clientHeight?function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return e===document.body?window.innerWidth-document.documentElement.clientWidth:e.offsetWidth-e.clientWidth}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */():0;return c.current.dataset.id="td_dialog_".concat(+new Date,"_").concat(Jm+=1),c.current.innerHTML="\n      html body {\n        overflow-y: hidden;\n        width: calc(100% - ".concat(e,"px);\n      }\n    "),l}}),[l]),fl((function(){"undefined"!=typeof document&&"modal"===o&&n&&!a&&(r?document.head.appendChild(c.current):l())}),[n,r,o,a,l])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function ev(e){return"number"==typeof e?"".concat(e,"px"):e}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var tv=["children"],nv=["className","dialogClassName","style","width","mode","zIndex","visible","attach","onBeforeOpen","onBeforeClose","onOpened","onCancel","onConfirm","onClose","onClosed","isPlugin","draggable","onOverlayClick","onEscKeydown","closeOnEscKeydown","confirmOnEnter","showOverlay","showInAttachedElement","closeOnOverlayClick","destroyOnClose","preventScrollThrough","onCloseBtnClick","forceRender"];function rv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ov(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var av=e.forwardRef((function(t,o){var a=ho(t,Um),c=a.children,l=T(a,tv),u=bo().classPrefix,s="".concat(u,"-dialog"),f=e.useRef(),d=e.useRef(),p=e.useRef(!1),m=e.useRef(),v=e.useRef(),g=e.useRef(),b=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=wo(e.useState(t),2),r=n[0],o=n[1];return[r,e.useCallback((function(e){o((function(t){return Wm(Wm({},t),"function"==typeof e?e(t):e)}))}),[])]}(ov({isPlugin:!1},l)),h=wo(b,2),y=h[0],O=h[1],w=wo(yl("dialog"),1)[0],E=y.className,j=y.dialogClassName,P=y.style,x=y.width,C=y.mode,_=y.zIndex,N=y.visible,k=y.attach,D=y.onBeforeOpen,R=y.onBeforeClose,A=y.onOpened,M=y.onCancel,L=y.onConfirm,z=y.onClose,B=y.onClosed,F=y.isPlugin,V=y.draggable,H=y.onOverlayClick,W=y.onEscKeydown,G=y.closeOnEscKeydown,U=y.confirmOnEnter,K=y.showOverlay,Z=y.showInAttachedElement,$=y.closeOnOverlayClick,X=y.destroyOnClose,q=y.preventScrollThrough,Y=y.onCloseBtnClick,J=y.forceRender,Q=void 0!==J&&J,ee=T(y,nv),te=Zi("dialog",k);Qm({preventScrollThrough:q,visible:N,mode:C,showInAttachedElement:Z}),function(t,n){e.useEffect((function(){var e;if(t)null!=n&&n.current&&(Ym.add(n),null==n||null===(e=n.current)||void 0===e||e.focus());else if(Ym.has(n)){var r;Ym.delete(n);var o=To(Ym);null===(r=o[o.length-1])||void 0===r||null===(r=r.current)||void 0===r||r.focus()}return function(){Ym.forEach((function(e){null===e.current&&Ym.delete(e)}))}}),[t,n])}(N,f),function(t,n){var r=e.useRef(null),o=function(e){r.current={x:e.clientX,y:e.clientY},setTimeout((function(){r.current=null}),100)};fl((function(){return document.addEventListener("click",o,!0),function(){document.removeEventListener("click",o,!0)}}),[]),e.useEffect((function(){t&&r.current&&n.current&&(n.current.style.transformOrigin="".concat(r.current.x-n.current.offsetLeft,"px ").concat(r.current.y-n.current.offsetTop,"px"))}),[t,n])}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */(N,m);var ne=function(e){var t=e.contentClickRef,n=e.dialogCardRef,r=e.canDraggable,o="object"===("undefined"==typeof window?"undefined":S(window)),a=o?window.innerHeight||document.documentElement.clientHeight:void 0,c=o?window.innerWidth||document.documentElement.clientWidth:void 0,i={x:0,y:0},l=function(e){var t=n.current,r=t.style,o=t.offsetWidth,l=t.offsetHeight,u=e.clientX-i.x,s=e.clientY-i.y;u<0&&(u=0),s<0&&(s=0),c-o-u<0&&(u=c-o),a-l-s<0&&(s=a-l),r.position="absolute",r.left="".concat(u,"px"),r.top="".concat(s,"px")},u=function(){n.current.style.cursor="default",document.removeEventListener("mousemove",l),document.removeEventListener("mouseup",u)};return{onDialogMoveStart:function(e){if(t.current=!0,r&&e.currentTarget===e.target){var o=n.current,s=o.offsetLeft,f=o.offsetTop,d=o.offsetHeight;if(o.offsetWidth>c||d>a)return;n.current.style.cursor="move";var p=e.clientX-s,m=e.clientY-f;i={x:p,y:m},document.addEventListener("mousemove",l),document.addEventListener("mouseup",u)}},onDialogMove:l,onDialogMoveEnd:u}}({dialogCardRef:m,contentClickRef:p,canDraggable:V&&"modeless"===C}),re=ne.onDialogMoveStart;if(e.useEffect((function(){F||O((function(e){return ov(ov({},e),a)}))}),[a,O,F]),e.useImperativeHandle(o,(function(){return{show:function(){O({visible:!0})},hide:function(){O({visible:!1})},setConfirmLoading:function(e){O({confirmLoading:e})},destroy:function(){O({visible:!1,destroyOnClose:!0})},update:function(e){O((function(t){return ov(ov({},t),e)}))}}})),"normal"===a.mode)return nl("Dialog",'mode="normal" is not supported, please use DialogCard.'),n.createElement(qm,ov({},a));return n.createElement(i,{in:N,appear:!0,timeout:300,mountOnEnter:!Q,unmountOnExit:X,nodeRef:g,onEnter:function(){f.current&&(null==D||D(),f.current.style.display="block")},onEntered:A,onExit:function(){return null==R?void 0:R()},onExited:function(){null==B||B(),f.current&&(f.current.style.display="none")}},n.createElement(So,{attach:te,ref:g},n.createElement("div",{ref:f,className:r(E,"".concat(s,"__ctx"),"".concat(s,"__").concat(C),I(I({},"".concat(s,"__ctx--fixed"),!Z),"".concat(s,"__ctx--absolute"),Z)),style:{zIndex:_,display:"none"},onKeyDown:function(e){"Escape"===e.key?(e.stopPropagation(),null==W||W({e:e}),(null!=G?G:w.closeOnEscKeydown)&&(null==z||z({e:e,trigger:"esc"}))):"Enter"!==e.key&&"NumpadEnter"!==e.key||(e.stopPropagation(),U&&(null==L||L({e:e})))},tabIndex:0},"modal"!==C?null:K?n.createElement(i,{in:N,appear:!0,timeout:300,classNames:"".concat(s,"-fade"),mountOnEnter:!0,unmountOnExit:!0,nodeRef:d},n.createElement("div",{ref:d,className:"".concat(s,"__mask")})):null,n.createElement("div",{className:"".concat(s,"__wrap")},n.createElement("div",{ref:v,className:r("".concat(s,"__position"),I(I({},"".concat(s,"--top"),!!a.top||"top"===a.placement),"".concat(s,"--center"),"center"===a.placement&&!a.top)),style:{paddingTop:ev(a.top)},onClick:function(e){K&&(null!=$?$:w.closeOnOverlayClick)&&(p.current?p.current=!1:e.target===v.current&&(null==H||H({e:e}),null==z||z({e:e,trigger:"overlay"})))}},n.createElement(i,{in:N,appear:!0,timeout:300,classNames:"".concat(s,"-zoom"),nodeRef:m,onEnter:function(){m.current&&(m.current.style.display="block")},onExited:function(){m.current&&(m.current.style.display="none")}},n.createElement(qm,ov(ov({ref:m},ee),{},{className:j,style:ov(ov({},P),{},{width:ev(x||(null==P?void 0:P.width))}),onConfirm:L,onCancel:function(e){var t=e.e;null==M||M({e:t}),null==z||z({e:t,trigger:"cancel"})},onCloseBtnClick:function(e){var t=e.e;null==Y||Y({e:t}),null==z||z({e:t,trigger:"close-btn"})},onMouseDown:re}),c)))))))}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function cv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function iv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}av.displayName="Dialog";var lv=function(e){var t=n.createRef(),r=iv({},e),o=r.visible,a=void 0===o||o,c=document.createDocumentFragment();ca(n.createElement(av,iv(iv({},r),{},{visible:a,ref:t,isPlugin:!0})),c);var i,l,u=(i=r.attach,(l="function"==typeof i?i():i)?xo(l)?document.querySelector(l):l instanceof HTMLElement?l:document.body:document.body);return u?u.appendChild(c):nl("Dialog","attach is not exist"),{show:function(){requestAnimationFrame((function(){var e;u.appendChild(c),null===(e=t.current)||void 0===e||e.show()}))},hide:function(){requestAnimationFrame((function(){var e;null===(e=t.current)||void 0===e||e.destroy()}))},setConfirmLoading:function(e){requestAnimationFrame((function(){var n;null===(n=t.current)||void 0===n||n.setConfirmLoading(e)}))},update:function(e){requestAnimationFrame((function(){var n;null===(n=t.current)||void 0===n||n.update(e)}))},destroy:function(){requestAnimationFrame((function(){var e;null===(e=t.current)||void 0===e||e.destroy()}))}}};lv.alert=function(e){var t=iv({},e);return t.cancelBtn=null,lv(t)},lv.confirm=function(e){return lv(e)};var uv=lv,sv=vp;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var fv=function(e){return sv(e,5)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function dv(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,D(r.key),r)}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var pv=e.forwardRef((function(e,t){var o=e.children,a=e.className,c=e.style,i=e.action,l=e.content,u=bo().classPrefix,s=i&&n.createElement("ul",{className:"".concat(u,"-list-item__action")},i);return n.createElement("li",{ref:t,className:r("".concat(u,"-list-item"),a),style:c},n.createElement("div",{className:"".concat(u,"-list-item-main")},o||l,s))}));pv.displayName="ListItem";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var mv=e.forwardRef((function(e,t){var o=e.title,a=e.image,c=e.description,i=e.className,l=e.style,u=bo().classPrefix;return n.createElement("div",{ref:t,className:r("".concat(u,"-list-item__meta"),i),style:l},a&&(a&&"string"==typeof a?n.createElement("div",{className:"".concat(u,"-list-item__meta-avatar")},n.createElement("img",{src:a,alt:""})):n.createElement("div",{className:"".concat(u,"-list-item__meta-avatar")},a)),n.createElement("div",{className:"".concat(u,"-list-item__meta-content")},n.createElement("h3",{className:"".concat(u,"-list-item__meta-title")},o),n.createElement("div",{className:"".concat(u,"-list-item__meta-description")},"string"==typeof c?n.createElement("p",null,c):c)))}));mv.displayName="ListItemMeta";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var vv={layout:"horizontal",size:"medium",split:!1,stripe:!1},gv=dl((function(e,t){var o=ho(e,vv),a=o.header,c=o.footer,i=o.asyncLoading,l=o.size,u=o.split,s=o.stripe,f=o.layout,d=o.children,p=o.className,m=o.onLoadMore,v=void 0===m?sc:m,g=o.onScroll,b=void 0===g?sc:g,h=o.style,y=bo().classPrefix,O=wo(yl("list"),2),w=O[0],E=O[1],j=xo(i)?n.createElement("div",{className:r("".concat(y,"-list__load"),I(I({},"".concat(y,"-list__load--loading"),"loading"===i),"".concat(y,"-list__load--load-more"),"load-more"===i)),onClick:function(e){"load-more"===i&&v({e:e})}},"loading"===i&&n.createElement("div",null,n.createElement(ia,{loading:!0}),n.createElement("span",null,E(w.loadingText))),"load-more"===i&&n.createElement("span",null,E(w.loadingMoreText))):i;return n.createElement("div",{ref:t,style:h,onScroll:function(e){var t=e.currentTarget,n=t.scrollTop,r=t.offsetHeight,o=t.scrollHeight;b({e:e,scrollTop:n,scrollBottom:o-n-r})},className:r("".concat(y,"-list"),p,I(I(I(I(I({},"".concat(y,"-list--split"),u),"".concat(y,"-list--stripe"),s),"".concat(y,"-list--vertical-action"),"vertical"===f),"".concat(y,"-size-s"),"small"===l),"".concat(y,"-size-l"),"large"===l))},a&&n.createElement("div",{className:"".concat(y,"-list__header")},a),n.createElement("ul",{className:"".concat(y,"-list__inner")},d),i&&j,c&&n.createElement("div",{className:"".concat(y,"-list__footer")},c))}),{ListItem:pv,ListItemMeta:mv});
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */gv.displayName="List";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var bv=gv,hv=function(){var e=bo().classPrefix,t="".concat(e,"-tabs"),n="".concat(e,"-tab-panel");return{tdTabsClassPrefix:t,tdTabPanelClassPrefix:n,tdClassGenerator:function(t){return"".concat(e,"-").concat(t)},tdTabsClassGenerator:function(e){return"".concat(t,"__").concat(e)},tdTabPanelClassGenerator:function(e){return"".concat(n,"__").concat(e)},tdSizeClassGenerator:function(t){return"".concat(e,"-size-").concat("large"===t?"l":"m")}}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function yv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ov(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var wv=function(e){var t=e.label,o=e.removable,a=e.isActive,c=e.onClick,i=void 0===c?sc:c,l=e.theme,u=e.placement,s=e.onRemove,f=void 0===s?sc:s,d=e.value,p=e.size,m=void 0===p?"medium":p,v=e.disabled,b=void 0!==v&&v,h=e.index,y=e.onTabRemove,O=void 0===y?sc:y,w=e.innerRef,E=e.dragProps,j=pl({CloseIcon:g}).CloseIcon,P="card"===l,x=hv(),C=x.tdTabsClassGenerator,_=x.tdClassGenerator,N=x.tdSizeClassGenerator,k=wo(Do(),2),S=k[0],D=k[1];return Qi(S),n.createElement("div",Ov(Ov({},E),{},{ref:w,onClick:b?sc:i,className:r(C("nav-item"),P?C("nav--card"):"",N(m),a?_("is-active"):"",_("is-".concat(u)),b?_("is-disabled"):"",e.className)}),P?n.createElement("span",{className:r(C("nav-item-text-wrapper"))},t):n.createElement("div",{ref:D,className:r(C("nav-item-wrapper"))},n.createElement("span",{className:r(C("nav-item-text-wrapper"))},t)),o?n.createElement(j,{className:r("remove-btn"),onClick:function(e){b||(e.stopPropagation(),f({value:d,e:e}),O({value:d,e:e,index:h}))}}):null)},Ev=function(t){var o=t.tabPosition,a=t.activeId,c=t.containerRef,i=t.navsWrapRef,l=bo().classPrefix,u=wo(e.useState({}),2),s=u[0],f=u[1],d="".concat(l,"-tabs"),p=e.useRef(a);e.useEffect((function(){p.current=a}),[a]);var m=n.useCallback((function(){var e=["bottom","top"].includes(o),t=e?"translateX":"translateY",n=e?"width":"height",r=e?"width":"height",a=0;if(c.current){var i,l=null===(i=c.current)||void 0===i?void 0:i.querySelectorAll(".".concat(d,"__nav-item"));if(l.length-1>=p.current){l.forEach((function(e,t){t<p.current&&(a+=Number(getComputedStyle(e)[n].replace("px","")))}));var u=l[p.current];if(!u)return void f(I({transform:"".concat(t,"(",0,"px)")},r,0));var s=getComputedStyle(u)[n];f(I({transform:"".concat(t,"(").concat(a,"px)")},r,s||0))}}}),[p,c,o,d]);e.useEffect((function(){c.current&&setTimeout((function(){return m()}))}),[o,a,c.current]);var v=n.useCallback((function(e){e.forEach((function(e){"characterData"===e.type&&m()}))}),[m]);return Ui(c.current,v),_m(i.current,m),n.createElement("div",{className:r(I(I({},"".concat(d,"__bar"),!0),"".concat(l,"-is-").concat(o),!0)),style:s})};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */Ev.displayName="TabBar";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var jv=function(e){return(null==e?void 0:e.offsetWidth)||0};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Pv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function xv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Cv=function(t){var o=t.placement,a=void 0===o?"top":o,c=t.itemList,i=void 0===c?[]:c,l=t.tabClick,u=void 0===l?sc:l,s=t.theme,f=t.addable,d=t.onAdd,p=t.scrollPosition,m=void 0===p?"auto":p,g=t.size,b=void 0===g?"medium":g,h=t.disabled,y=void 0!==h&&h,E=t.onRemove,j=void 0===E?sc:E,P=t.onChange,x=void 0===P?sc:P,C=t.activeValue,_=t.children,N=t.action,k=t.getDragProps,S=pl({AddIcon:v,ChevronLeftIcon:O,ChevronRightIcon:w}),D=S.AddIcon,I=S.ChevronLeftIcon,T=S.ChevronRightIcon,R="card"===s,A=hv(),M=A.tdTabsClassGenerator,L=A.tdClassGenerator,z=A.tdSizeClassGenerator,B=e.useRef(null),F=e.useRef(null),V=e.useCallback((function(e){var t=i.findIndex((function(t){return t.value===e}));return t>-1?t:-1}),[i])(C),H=wo(e.useState(!1),2),W=H[0],G=H[1],U=wo(e.useState(!1),2),K=U[0],Z=U[1],$=e.useRef(null),X=e.useRef(null),q=e.useRef(null),Y=e.useRef(null),J=e.useRef(null),Q=wo(e.useState(0),2),ee=Q[0],te=Q[1],ne=wo(e.useState(0),2),re=ne[0],oe=ne[1],ae=wo(e.useState(null),2),ce=ae[0],ie=ae[1],le=function(e){te(function(e,t){return Math.max(0,Math.min(e,t))}(e,re))},ue=e.useCallback((function(){if(["top","bottom"].includes(a.toLowerCase())){var e=(t={navsWrap:F.current,navsContainer:B.current,rightOperations:q.current,toRightBtn:J.current},n=t.navsWrap,r=t.navsContainer,o=t.rightOperations,c=t.toRightBtn,jv(n)-jv(r)+jv(o)-jv(c));oe(e)}var t,n,r,o,c}),[a]),se=function(){var e=function(e,t,n){var r,o=e.navsContainer,a=e.activeTab,c=e.rightOperations,i=e.leftOperations,l=jv(a),u=jv(o),s=(null==(r=a)?void 0:r.offsetLeft)||0,f=jv(c),d=jv(i);if("auto"===n){if(s-d<t)return s-d;if(s+l>t+u-f)return s+l-u+f}else{if("start"===n)return s-d;if("center"===n)return s+(l-u)/2;if("end"===n)return s+l-u+f}return t}({activeTab:ce,navsContainer:B.current,leftOperations:X.current,rightOperations:q.current},ee,m);le(e)};e.useEffect((function(){var e=setTimeout((function(){se()}),100);return function(){return clearTimeout(e)}}),[ce,re,m]),e.useEffect((function(){if(["top","bottom"].includes(a.toLowerCase())){var e=ee<re-1;G(ee>1),Z(e)}}),[a,ee,re]);var fe=function(e){var t=function(e,t,n){var r=e.navsContainer,o=e.activeTab,a=jv(r),c=jv(o);return"next"===n?t+a-c:t-a+c}({activeTab:ce,navsContainer:B.current},ee,e);le(t)};e.useEffect((function(){var e=$.current;if(e){var t=function(e){if(W||K){e.preventDefault();var t=e.deltaX,n=e.deltaY;Math.abs(t)>Math.abs(n)?le(ee+t):le(ee+n)}};return e.addEventListener("wheel",t,{passive:!1}),function(){null==e||e.removeEventListener("wheel",t)}}})),e.useEffect((function(){var e=_a(ue,300);return window.addEventListener("resize",e),function(){window.removeEventListener("resize",e),e.cancel()}})),e.useEffect((function(){ue()}),[i.length,_,ue]);var de=R?null:n.createElement(Ev,{tabPosition:a,activeId:V,containerRef:F,navsWrapRef:F}),pe=function(e){var t,n=e.value,r=e.index;n===C&&x(0===r?null===(t=i[r+1])||void 0===t?void 0:t.value:i[r-1].value);j(e)};return n.createElement("div",{ref:B,className:r(M("nav")),style:{minHeight:48}},n.createElement("div",{ref:X,className:r(M("operations"),M("operations--left"))},W?n.createElement("div",{onClick:function(){fe("prev")},className:r(M("btn"),M("btn--left"),z(b)),ref:Y},n.createElement(I,null)):null),n.createElement("div",{ref:q,className:r(M("operations"),M("operations--right"))},K?n.createElement("div",{onClick:function(){fe("next")},className:r(M("btn"),M("btn--right"),z(b)),ref:J},n.createElement(T,null)):null,f?n.createElement("div",{className:r(M("add-btn"),M("btn"),z(b)),onClick:function(e){d({e:e})}},n.createElement(D,null)):null,N?n.createElement("div",{className:r(M("btn"),M("nav-action"),z(b))},ol(N)):null),n.createElement("div",{className:r(M("nav-container"),R?M("nav--card"):"",L("is-".concat(a)),f?L("is-addable"):"")},n.createElement("div",{className:r(M("nav-scroll"),W||K?L("is-scrollable"):""),ref:$},n.createElement("div",{className:r(M("nav-wrap"),["left","right"].includes(a)?L("is-vertical"):"",L("is-smooth")),style:{transform:"translate(".concat(-ee,"px, 0)")},ref:F},"bottom"!==a?de:null,!R&&n.createElement("div",{className:r(M("bar"),L("is-".concat(a)))}),i.map((function(e,r){return n.createElement(wv,xv(xv(xv({},Sp(t,["className","style"])),e),{},{dragProps:xv({},null==k?void 0:k(r,e)),onRemove:e.onRemove,key:e.value,label:e.label,isActive:C===e.value,theme:s,placement:a,index:r,disabled:y||e.disabled,onClick:function(){return u((t=e).value),C!==t.value&&x(t.value),void(null==t||null===(n=t.onClick)||void 0===n||n.call(t,t.value));var t,n},onTabRemove:pe,innerRef:function(t){C===e.value&&ie(t)}}))})),"bottom"===a?de:null))))};Cv.displayName="TabNav";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var _v={addable:!1,disabled:!1,dragSort:!1,placement:"top",scrollPosition:"auto",size:"medium",theme:"normal"},Nv={destroyOnHide:!0,disabled:!1,draggable:!0,lazy:!1,removable:!1},kv=function(e){var t=hv().tdTabPanelClassPrefix,o=ho(e,Nv),a=o.className,c=o.style;return n.createElement("div",{className:r(t,a),style:c},e.children||e.panel)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Sv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Dv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Sv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Sv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}kv.displayName="TabPanel";var Iv=dl((function(t,o){var a=ho(t,_v),c=a.defaultValue,i=a.children,l=a.list,u=a.placement,s=a.value,f=a.dragSort,d=a.className,p=a.style,m=a.onRemove,v=a.onChange,g=hv(),b=g.tdTabsClassPrefix,h=g.tdTabsClassGenerator,y=g.tdClassGenerator,O="^".concat(b,"(__nav-item|__nav-item-wrapper|__nav-item-text-wrapper)"),w=Zp(Dv(Dv({},a),{},{sortOnDraggable:f,onDragOverCheck:{x:!0,targetClassNameRegExp:new RegExp(O)}})).getDragProps,E=n.useMemo((function(){return l&&0!==l.length?l.map((function(e){return n.createElement(kv,Dv({key:e.value},e))})):i}),[i,l]),j=n.Children.map(E,(function(e){return e&&e.type===kv?e.props:null})),P=wo(n.useState((function(){return void 0===c&&Array.isArray(j)&&0!==j.length?j[0].value:c})),2),x=P[0],C=P[1];e.useEffect((function(){void 0!==s&&C(s)}),[s]);var _=n.useCallback((function(e){void 0===s&&C(e),null==v||v(e)}),[s,v]),N=n.useCallback((function(e){void 0===s&&C(e)}),[s]),k=n.useMemo((function(){return n.createElement("div",{className:r(h("header"),y("is-".concat(u)))},n.createElement(Cv,Dv(Dv({},a),{},{getDragProps:w,activeValue:x,onRemove:m,itemList:j,tabClick:N,onChange:_})))}),[a,w,x,m,j,N,_,u,h,y]);return n.createElement("div",{ref:o,className:r(b,d),style:p},"bottom"!==u?k:null,n.createElement("div",{className:r(h("content"),y("is-".concat(u)))},n.Children.map(E,(function(e){if(e&&e.type===kv){if(e.props.value===x)return e;if(!1===e.props.destroyOnHide)return n.createElement(kv,Dv(Dv({},e.props),{},{style:{display:"none"}}))}return null}))),"bottom"===u?k:null)}),{TabPanel:kv});Iv.displayName="Tabs";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Tv=Iv,Rv={closeBtn:void 0,duration:3e3,icon:!0,theme:"info"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Av(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Av(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Av(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Lv=0,zv=new Map,Bv=n.createContext(sc),Fv=e.forwardRef((function(t,r){var o=t.placement,a=t.zIndex,c=t.renderCallback,i=bo().classPrefix,l=wo(e.useState([]),2),u=l[0],s=l[1],f=function(e){s((function(t){var n=t.findIndex((function(t){return t.key===e}));if(-1!==n){var r=To(t);return r.splice(n,1),To(r)}return t}))},d=function(e){return isNaN(Number(e))?e:"".concat(e,"px")},p=function(e,t){var r=String(Lv+=1),o=To(t.offset),a=o[0],c=o[1],i=d(a),l={top:d(c),left:i,marginBottom:16,position:"relative"},u=n.createRef();return s((function(n){return[].concat(To(n),[Mv(Mv({},t),{},{key:r,theme:e,style:l,ref:u,id:r})])})),new Promise((function(e){setTimeout((function(){e(u.current)}),1e3/60)}))},m=function(){return s([])};return e.useImperativeHandle(r,(function(){return{push:p,remove:f,removeAll:m}})),e.useEffect((function(){c({push:p,remove:f,removeAll:m})}),[]),n.createElement(Bv.Provider,{value:f},n.createElement("div",{className:"".concat(i,"-notification__show--").concat(o),style:{zIndex:a}},u.map((function(e){var t=e.onDurationEnd,r=void 0===t?sc:t,o=e.onCloseBtnClick,a=void 0===o?sc:o;return n.createElement(Wv,Mv(Mv({ref:e.ref,key:e.key},e),{},{onDurationEnd:function(){f(e.key),r()},onCloseBtnClick:function(t){f(e.key),a(t)}}))}))))})),Vv=!1,Hv=e.forwardRef((function(t,o){var a=ho(t,Rv),c=a.title,i=a.content,l=a.theme,u=a.icon,s=a.closeBtn,f=a.footer,d=a.duration,p=a.onCloseBtnClick,m=void 0===p?sc:p,v=a.onDurationEnd,b=void 0===v?sc:v,O=a.style,w=a.className,E=a.id,j=bo().classPrefix,P="".concat(j,"-notification"),x=pl({CloseIcon:g,InfoCircleFilledIcon:h,CheckCircleFilledIcon:y}),C=x.CloseIcon,_=x.InfoCircleFilledIcon,N=x.CheckCircleFilledIcon,k=e.useContext(Bv);n.useImperativeHandle(o,(function(){return{close:function(){return k(E)}}})),n.useEffect((function(){var e;return d>0&&(e=setTimeout((function(){clearTimeout(e),b()}),d)),function(){e&&clearTimeout(e)}}),[]);return n.createElement("div",{className:r(w,P,I({},"".concat(P,"-is-").concat(l),l)),style:O},function(){if("boolean"==typeof u&&!u)return null;var e=function(e){var t=e.children;return n.createElement("div",{className:"".concat(P,"__icon")},t)};return n.isValidElement(u)?n.createElement(e,null,u):l&&"success"===l?n.createElement(e,null,n.createElement(N,{className:"".concat(j,"-is-success")})):l&&["info","warning","error"].indexOf(l)>=0?n.createElement(e,null,n.createElement(_,{className:"".concat(j,"-is-").concat(l)})):null}(),n.createElement("div",{className:"".concat(P,"__main")},n.createElement("div",{className:"".concat(P,"__title__wrap")},n.createElement("span",{className:"".concat(P,"__title")},c),"boolean"==typeof s?s&&n.createElement(C,{className:"".concat(P,"-icon-close"),onClick:function(e){m({e:e})}}):n.createElement("div",{className:"".concat(P,"-close"),onClick:function(e){m({e:e})}},ol(s))),i&&n.createElement("div",{className:"".concat(P,"__content")},ol(i)),f&&n.createElement("div",{className:"".concat(P,"__detail")},ol(f))))}));Hv.displayName="Notification";var Wv=Hv;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Gv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Uv(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Gv(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Gv(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Kv=Uv(Uv({},Rv),{},{zIndex:6e3,placement:"top-right",offset:["-16px","16px"]}),Zv=function(e){var t=Uv({},e);for(var n in t)void 0===t[n]&&delete t[n];return("number"!=typeof t.duration||t.duration<0)&&delete t.duration,["top-left","top-right","bottom-left","bottom-right"].indexOf(t.placement)<0&&delete t.placement,["info","success","warning","error"].indexOf(t.theme)<0&&delete t.theme,Array.isArray(t.offset)||delete t.offset,Uv(Uv({},Kv),t)},$v=function(e,t){if("object"===S(t)){var r=Zv(t),o=r.placement,a=function(){if(t.attach&&"string"==typeof t.attach){var e=document.querySelector(t.attach);if(e instanceof HTMLElement)return e}if(t.attach instanceof HTMLElement)return t.attach;var n="tdesign-notification-".concat(o),r=document.querySelector("#".concat(n));if(r&&r instanceof HTMLElement)return r;var a=document.createElement("div");return a.setAttribute("id",n),document.body.appendChild(a),a}();return function(e,t,r){return new Promise((function(o){!function a(){if(!zv.has(e))return Vv?void setTimeout(a,1e3/60):(Vv=!0,void ca(n.createElement(Fv,{attach:t,placement:e,zIndex:Number(r),renderCallback:function(t){Vv=!1,zv.set(e,t),o(t)}}),t));o(zv.get(e))}()}))}(o,a,r.zIndex).then((function(t){return t.push(e,r)}))}},Xv=function(e,t){return $v(e,t)};Xv.info=function(e){return $v("info",e)},Xv.success=function(e){return $v("success",e)},Xv.warning=function(e){return $v("warning",e)},Xv.error=function(e){return $v("error",e)},Xv.close=function(e){return e.then((function(e){return e.close()}))},Xv.closeAll=function(){return To(zv.values()).forEach((function(e){return e.removeAll()}))},Xv.config=function(e){return function(e){Kv=Uv({},Zv(e))}(e)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var qv=Xv,Yv=e.createContext({setState:sc,onExpand:sc}),Jv=[232,64],Qv=function(e){return e.MenuItem="MenuItem",e.SubMenu="SubMenu",e.MenuItemGroup="MenuItemGroup",e.MenuGroup="MenuGroup",e}(Qv||{});
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function eg(e,t,r){var o,a,c=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],i=n.Children.map(e,(function(e){return e.props.value})),l=i.indexOf(r),u=e[l];if(l>-1&&(null==u||null===(o=u.type)||void 0===o?void 0:o.displayName)===Qv.SubMenu)return[].concat(To(c),[r]);var s=i.indexOf(t[0]),f=e[s];return s>-1&&(null==f||null===(a=f.type)||void 0===a?void 0:a.displayName)===Qv.SubMenu?eg(f.props.children,t.slice(1),r,[].concat(To(c),[t[0]])):[r]}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function tg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ng(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function rg(t){var n=t.defaultValue,r=t.defaultExpanded,o=t.expandMutex,a=t.children,c=t.onExpand,i=void 0===c?Df:c,l=t.onChange,u=void 0===l?Df:l,s=t.value,f=t.expanded,d=t.collapsed,p=t.expandType,m=t.theme,v=t.mode,g=wo(e.useState({active:n,expanded:r}),2),b=g[0],h=g[1];return{value:{onExpand:function(e,t){var n=[],r=t.indexOf(e);n=r>-1?o?t.slice(0,r):t.filter((function(t){return t!==e})):o?eg(a,t,e):[].concat(To(t),[e]),i(n),h({expanded:n})},onChange:u,active:s||b.active,expanded:f||b.expanded,collapsed:d||b.collapsed,setState:function(e){return h(ng(ng({},b),e))},expandMutex:o,expandType:d?"popup":p,mode:v,theme:m}}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var og={collapsed:!1,expandMutex:!1,expandType:"normal",theme:"light",width:"232px"},ag=function(e){return!!e&&e.type.displayName===Qv.SubMenu},cg=function(e){return!!e&&e.type.displayName===Qv.MenuGroup},ig=function(e,t){var r=!1;return n.Children.forEach(e,(function(e){r||(ag(e)?r=ig(e.props.children,t):function(e){return!!e&&e.type.displayName===Qv.MenuItem}(e)&&(r=t===e.props.value||r))})),r},lg=["children"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function ug(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function sg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ug(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ug(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var fg=Tv.TabPanel,dg=function(e){var t=0;return n.Children.forEach(e,(function(e){ag(e)||cg(e)?t+=dg(e.props.children)+1:t+=1})),t},pg=function(e){return 50*dg(e)},mg=function(e){return 44+16*e},vg=["overlayClassName","overlayInnerClassName"],gg=["overlayClassName","overlayInnerClassName"];function bg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function hg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var yg=function(t){var o=t.content,a=t.children,c=void 0===a?o:a,i=t.disabled,l=t.icon,u=t.title,s=t.value,f=t.className,d=t.style,p=t.level,m=void 0===p?1:p,v=t.popupProps||{},g=v.overlayClassName,b=v.overlayInnerClassName,h=T(v,vg),y=bo().classPrefix,O=wo(e.useState(!1),2),w=O[0],E=O[1],j=e.useContext(Yv),P=j.expanded,x=void 0===P?[]:P,C=j.onExpand,_=j.active,N=j.expandType,k=j.theme,S=void 0===k?"light":k,D="popup"===N,R=x.includes(s)&&!i&&!D,A=function(e){D&&("enter"===e?E(!0):"leave"===e&&E(!1))},M=n.Children.map(c,(function(e){var t;return n.cloneElement(e,{className:r("".concat(y,"-menu__item--plain"),"".concat(y,"-submenu__item"),"".concat(y,"-submenu__item--icon"),null===(t=e.props)||void 0===t?void 0:t.className)})})),L={maxHeight:R||w&&D?pg(c):0},z=e.useMemo((function(){return!i&&(D?w:R)}),[i,D,w,R]),B=mg(m-1),F=D&&m>1?{transform:"rotate(-90deg)"}:{},V=n.createElement("ul",{className:r("".concat(y,"-menu__popup-wrapper"),I({},"".concat(y,"-is-opened"),z)),key:"popup",style:L},M),H=n.createElement("li",{className:r("".concat(y,"-submenu"),f,I(I({},"".concat(y,"-is-disabled"),i),"".concat(y,"-is-opened"),z)),style:d,onMouseEnter:function(){return A("enter")},onMouseLeave:function(){return A("leave")}},n.createElement("div",{className:r("".concat(y,"-menu__item"),I(I({},"".concat(y,"-is-opened"),z),"".concat(y,"-is-active"),ig(c,_))),onClick:function(e){e.stopPropagation(),C(s,x),E(!1)}},l," ",n.createElement("span",{className:"".concat(y,"-menu__content")},u),n.createElement(Bp,{style:F,isActive:z,disabled:i})),!D&&n.createElement("ul",{key:"normal",style:hg(hg({},L),{},{"--padding-left":"".concat(B,"px")}),className:"".concat(y,"-menu__sub")},M));return D?n.createElement(Yi,hg(hg({},h),{},{overlayInnerClassName:["".concat(y,"-menu__popup"),"".concat(y,"-is-vertical"),I({},"".concat(y,"-is-opened"),z),b],overlayClassName:["".concat(y,"-menu--").concat(S),I({},"".concat(y,"-menu-is-nested"),m>1),g],visible:w,placement:"right-top",content:V,onVisibleChange:function(e){E(e)}}),H):H},Og=function(t){var o=t.className,a=t.style,c=t.children,i=t.disabled,l=t.title,u=t.value,s=t.level,f=void 0===s?1:s,d=t.popupProps||{},p=d.overlayClassName,m=d.overlayInnerClassName,v=T(d,gg),g=e.useContext(Yv),b=g.active,h=g.onChange,y=g.expandType,O=g.theme,w=void 0===O?"light":O,E=bo().classPrefix,j=wo(e.useState(!1),2),P=j[0],x=j[1],C=wo(Do(),2),_=C[0],N=C[1];Qi(_);var k="popup"===y,S=ig(c,b)||b===u,D=function(e){k&&("enter"===e?x(!0):"leave"===e&&x(!1))},R=e.useMemo((function(){return!i&&(!!k&&P)}),[i,k,P]),A=f>1?{transform:"rotate(-90deg)"}:{},M=n.createElement("ul",{className:r("".concat(E,"-menu__popup-wrapper"),I({},"".concat(E,"-is-opened"),R))},c),L="right-top";f<2&&(L="bottom-left");var z=n.createElement("li",{className:r("".concat(E,"-submenu"),o,I({},"".concat(E,"-is-opened"),P)),onMouseEnter:function(){return D("enter")},onMouseLeave:function(){return D("leave")}},n.createElement("div",{ref:N,className:r("".concat(E,"-menu__item"),I(I({},"".concat(E,"-is-active"),S),"".concat(E,"-is-opened"),P)),onClick:function(){return h(u)},style:a},n.createElement("span",null,l),k&&n.createElement(Bp,{style:A,isActive:1===f&&P})));return k?n.createElement(Yi,hg(hg({},v),{},{overlayInnerClassName:["".concat(E,"-menu__popup"),"".concat(E,"-is-vertical"),I({},"".concat(E,"-is-opened"),R),m],overlayClassName:["".concat(E,"-menu--").concat(w),"".concat(E,"-is-head-menu"),I({},"".concat(E,"-menu-is-nested"),f>1),p],visible:P,placement:L,content:M,onVisibleChange:function(e){x(e)}}),z):z},wg=function(t){var r=e.useContext(Yv).mode,o=t.children,a=t.level,c=void 0===a?1:a,i=function(e){if(ag(e))return n.cloneElement(e,{level:c+1});if(cg(e)){var t=n.Children.map(e.props.children,(function(e){return i(e)}));return n.cloneElement(e,{level:c+1},t)}return e},l=n.Children.map(o,(function(e){return i(e)}));return"accordion"===r?n.createElement(yg,hg({},t),l):"title"===r?n.createElement(Og,hg({},t),l):null};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Eg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function jg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Eg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Eg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}wg.displayName="SubMenu";var Pg=function(t){var o=t.content,a=t.children,c=void 0===a?o:a,i=t.disabled,l=t.href,u=t.target,s=void 0===u?"_self":u,f=t.value,d=t.className,p=t.style,m=t.icon,v=t.onClick,g=bo().classPrefix,b=wo(Do(),2),h=b[0],y=b[1];Qi(h);var O=e.useContext(Yv),w=O.onChange,E=O.setState,j=O.active,P=O.collapsed,x=n.createElement("li",{ref:y,className:r("".concat(g,"-menu__item"),d,I(I(I({},"".concat(g,"-is-disabled"),i),"".concat(g,"-is-active"),f===j),"".concat(g,"-menu__item--plain"),!m)),style:jg({},p),onClick:function(e){e.stopPropagation(),i||(v&&v({e:e,value:f}),f!==j&&w(f),E({active:f}))}},n.createElement(n.Fragment,null,m,l?n.createElement("a",{href:l,target:s,className:r("".concat(g,"-menu__item-link"))},n.createElement("span",{className:"".concat(g,"-menu__content")},c)):n.createElement("span",{className:"".concat(g,"-menu__content")},c)));return!P||i||/submenu/i.test(d)?x:n.createElement(Uf,jg({content:c,placement:"right"},t.tooltipProps),x)};Pg.displayName="MenuItem";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var xg=function(e){var t=e.title,o=e.children,a=e.level,c=void 0===a?1:a,i=bo().classPrefix,l=mg(c-1)-28;return n.createElement("div",{className:r("".concat(i,"-menu-group"))},n.createElement("div",{className:r("".concat(i,"-menu-group__title")),style:{paddingLeft:"".concat(l,"px")}},t),o)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Cg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}xg.displayName="MenuGroup";var Ng=dl((function(e,t){var o=ho(e,og),a=o.className,c=o.width,i=void 0===c?Jv:c,l=o.children,u=o.theme,s=o.logo,f=o.operations,d=o.style,p=bo().classPrefix,m=rg(_g(_g({},o),{},{children:l,mode:"accordion"})).value,v=Array.isArray(i)?i:[i,Jv[1]],g=m.collapsed;return n.createElement(Yv.Provider,{value:m},n.createElement("div",{ref:t,className:r("".concat(p,"-default-menu"),a,I(I({},"".concat(p,"-is-collapsed"),g),"".concat(p,"-menu--dark"),"dark"===u)),style:_g({width:g?v[1]:v[0]},d)},n.createElement("div",{className:"".concat(p,"-default-menu__inner")},s&&n.createElement("div",{className:"".concat(p,"-menu__logo")},s),n.createElement("ul",{className:r("".concat(p,"-menu"),"".concat(p,"-menu--scroll"))},l),f&&n.createElement("div",{className:"".concat(p,"-menu__operations")},f))))}),{HeadMenu:function(t){var o=t.children,a=t.className,c=t.theme,i=void 0===c?"light":c,l=t.style,u=t.logo,s=t.operations,f=bo().classPrefix,d=rg(sg(sg({},t),{},{children:o,mode:"title"})).value,p=e.useMemo((function(){if("popup"===d.expandType)return null;var e=function(e,t){return n.Children.toArray(e).find((function(e){return ag(e)&&(e.props.value===t||ig(e.props.children,t))}))}(o,d.active);if(!e)return null;var t=e.props.children;return Array.isArray(t)?t:Y(t)?[t]:e.props.children}),[o,d.expandType,d.active]),m=(null==p?void 0:p.length)>0?p.map((function(e){return e.props.value})):[];return n.createElement(Yv.Provider,{value:d},n.createElement("div",{className:r("".concat(f,"-head-menu"),"".concat(f,"-menu--").concat(i),a),style:sg({},l)},n.createElement("div",{className:"".concat(f,"-head-menu__inner")},u&&n.createElement("div",{className:"".concat(f,"-menu__logo")},u),n.createElement("ul",{className:"".concat(f,"-menu")},o),s&&n.createElement("div",{className:"".concat(f,"-menu__operations")},s)),(null==p?void 0:p.length)>0&&n.createElement("ul",{className:"".concat(f,"-head-menu__submenu ").concat(f,"-submenu")},n.createElement(Tv,{value:m.includes(d.active)?d.active:m[0],onChange:d.onChange},p.map((function(e){var r=e.props,o=r.children,a=T(r,lg);return n.createElement(fg,sg(sg({key:t.value},a),{},{label:o}))}))))))},SubMenu:wg,MenuItem:Pg,MenuGroup:xg});Ng.displayName="Menu";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var kg=Ng,Sg=av,Dg=uv,Ig={align:"center",dashed:!1,layout:"horizontal"},Tg=["layout","dashed","align","className","style","children","content"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Rg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ag(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Mg=function(e){var t=ho(e,Ig),o=t.layout,a=t.dashed,c=t.align,i=t.className,l=t.style,u=t.children,s=t.content,f=T(t,Tg),d=bo().classPrefix,p=s||u,m="vertical"!==o&&!!p,v=r("".concat(d,"-divider"),i,I(I(I(I({},"".concat(d,"-divider--").concat(o),o),"".concat(d,"-divider--dashed"),!!a),"".concat(d,"-divider--with-text"),m),"".concat(d,"-divider--with-text-").concat(c),m));return n.createElement("div",Ag(Ag({},f),{},{className:v,style:l}),m?n.createElement("span",{className:"".concat(d,"-divider__inner-text")},p):null)};Mg.displayName="Divider";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Lg=Mg,zg={label:[],loading:!1,size:"medium"},Bg=["className","value","defaultValue","disabled","loading","size","label","customValue","onChange","beforeChange"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Fg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Vg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Hg=n.forwardRef((function(t,o){var a=bo().classPrefix,c=ho(t,zg),i=c.className,l=c.value,u=c.defaultValue,s=c.disabled,f=c.loading,d=c.size,p=c.label,m=c.customValue,v=c.onChange,g=c.beforeChange,b=T(c,Bg),h=wo(m||[],2),y=h[0],O=void 0===y||y,w=h[1],E=void 0!==w&&w,j=void 0!==l,P=u===O||l===O,x=wo(e.useState(P),2),C=x[0],_=x[1],N=n.useMemo((function(){if(Array.isArray(p)){var e=wo(p,2),t=e[0],n=void 0===t?"":t,r=e[1];return ol(C?n:void 0===r?"":r,{value:l})}return ol(p,{value:l})}),[p,C,l]),k=function(e){!j&&_(!C),null==v||v(C?E:O,{e:e})};e.useEffect((function(){Array.isArray(m)&&!m.includes(l)&&nl("Switch","value is not in customValue: ".concat(JSON.stringify(m))),j&&_(l===O)}),[l,m,O,j]);var S=Su(),D=S.SIZE,R=S.STATUS,A=r("".concat(a,"-switch"),i,I(I(I({},R.checked,C),R.disabled,s),R.loading,f),D[d]);return n.createElement("button",Vg(Vg({},b),{},{type:"button",role:"switch",disabled:s||f,className:A,ref:o,onClick:function(e){s||(g?Promise.resolve(g()).then((function(t){t&&k(e)})).catch((function(e){nl("Switch","some error occurred: ".concat(e))})):k(e))}}),n.createElement("span",{className:"".concat(a,"-switch__handle")},f&&n.createElement(ia,{loading:!0,size:"small"})),n.createElement("div",{className:"".concat(a,"-switch__content")},N))}));Hg.displayName="Switch";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Wg=Hg,Gg={hover:"underline",size:"medium",theme:"default"},Ug=["children","content","className","underline","prefixIcon","suffixIcon","theme","disabled","hover","onClick","href","size"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Kg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Zg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Kg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $g=n.forwardRef((function(e,t){var o=ho(e,Gg),a=o.children,c=o.content,i=o.className,l=o.underline,u=o.prefixIcon,s=o.suffixIcon,f=o.theme,d=o.disabled,p=o.hover,m=o.onClick,v=o.href,g=o.size,b=T(o,Ug),h=bo().classPrefix,y=c||a;return n.createElement("a",Zg(Zg({},b),{},{href:d||!v?void 0:v,ref:t,className:r(i,["".concat(h,"-link"),"".concat(h,"-link--theme-").concat(f)],I(I(I(I(I({},"".concat(h,"-size-s"),"small"===g),"".concat(h,"-size-l"),"large"===g),"".concat(h,"-is-disabled"),!!d),"".concat(h,"-is-underline"),!!l),"".concat(h,"-link--hover-").concat(p),!d)),onClick:function(e){d||null==m||m(e)}}),u&&n.createElement("span",{className:r(["".concat(h,"-link__prefix-icon")])},ol(u)),y,s&&n.createElement("span",{className:r(["".concat(h,"-link__suffix-icon")])},ol(s)))}));$g.displayName="Link";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Xg=$g;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function qg(t){var n=wo(e.useState(""),2),r=n[0],o=n[1];return e.useEffect((function(){var e;t&&("string"!=typeof t?(e=t,new Promise((function(t){if(e){var n=new FileReader;n.readAsDataURL(e),n.onload=function(e){var n;t(null===(n=e.target)||void 0===n?void 0:n.result)}}else t("")}))).then((function(e){o(e)}),(function(){nl("Image","Image.src is not a valid file")})):o(t))}),[t]),{previewUrl:r}}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var Yg={fit:"fill",gallery:!1,lazy:!1,overlayTrigger:"always",position:"center",shape:"square"},Jg={breakLine:!1,direction:"horizontal",size:"medium"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Qg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var eb={small:"8px",medium:"16px",large:"24px"},tb=function(){var e,t,n;if("undefined"==typeof navigator||!navigator)return!1;var r=navigator.userAgent,o=r.match(/AppleWebKit.+Chrome\/(.+) Safari\/.+/i);if(Number(null==o||null===(e=o[1])||void 0===e?void 0:e.split(".")[0])<100)return!0;var a=r.match(/AppleWebKit.+Version\/(.+) Safari\/.+/i);if(Number(null==a||null===(t=a[1])||void 0===t?void 0:t.split(".")[0])<12)return!0;if(Bo()<=11)return!0;var c=r.match(/Firefox\/(.+)/i);return Number(null==c||null===(n=c[1])||void 0===n?void 0:n.split(".")[0])<100}(),nb=function(e){var t=[];return n.Children.forEach(e,(function(e){null!=e&&(Array.isArray(e)?t=t.concat(nb(e)):a.isFragment(e)&&e.props?t=t.concat(nb(e.props.children)):t.push(e))})),t},rb=["",!1,null,void 0],ob=n.forwardRef((function(t,o){var a=ho(t,Jg),c=a.className,i=a.style,l=a.align,u=a.direction,s=a.size,f=a.breakLine,d=a.separator,p=a.forceFlexGapPolyfill,m=bo().classPrefix,v=Boolean(p||tb),g=e.useMemo((function(){var e="";Array.isArray(s)?e=s.map((function(e){return"number"==typeof e?"".concat(e,"px"):"string"==typeof e&&eb[e]||e})).join(" "):"string"==typeof s?e=eb[s]||s:"number"==typeof s&&(e="".concat(s,"px"));var t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qg(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qg(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},i);if(v){var n=wo(e.split(" "),2),r=n[0],o=n[1];t["--td-space-column-gap"]=r,t["--td-space-row-gap"]=o||r}else t.gap=e;return t}),[i,s,v]),b=n.useMemo((function(){var e=nb(a.children),t=n.Children.count(e);return n.Children.map(e,(function(e,r){var o=r+1!==t&&d;return n.createElement(n.Fragment,null,rb.includes(e)?null:n.createElement("div",{className:"".concat(m,"-space-item")},e),o&&n.createElement("div",{className:"".concat(m,"-space-item-separator")},d))}))}),[a.children,m,d]);return n.createElement("div",{ref:o,style:g,className:r("".concat(m,"-space"),c,I(I(I(I({},"".concat(m,"-space-align-").concat(l),l),"".concat(m,"-space-").concat(u),u),"".concat(m,"-space--break-line"),f),"".concat(m,"-space--polyfill"),v))},b)}));ob.displayName="Space";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var ab=ob,cb=["className","src","style","fit","position","shape","placeholder","loading","error","overlayTrigger","lazy","gallery","overlayContent","srcset","fallback","onLoad","onError"],ib=["alt","referrerpolicy"];
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function lb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ub(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?lb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):lb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var sb=function(t,o){var a=ho(t,Yg),c=a.className,i=a.src,l=a.style,u=a.fit,s=a.position,f=a.shape,d=a.placeholder,p=a.loading,m=a.error,v=a.overlayTrigger,g=a.lazy,b=a.gallery,h=a.overlayContent,y=a.srcset,O=a.fallback,w=a.onLoad,E=a.onError,j=T(a,cb),P=j.alt,x=j.referrerpolicy,C=T(j,ib),k=bo().classPrefix,S=e.useRef(null),D=wo(yl("image"),2),I=D[0],R=D[1],A=pl({ImageErrorIcon:_,ImageIcon:N}),M=A.ImageErrorIcon,L=A.ImageIcon;n.useImperativeHandle(o,(function(){return S.current}));var z=wo(e.useState(i),2),B=z[0],F=z[1];e.useEffect((function(){var e=te(I.replaceImageSrc)?I.replaceImageSrc(a):i;e===B&&B||F(e)}),[i,I,a]);var V=qg(B).previewUrl,H=wo(e.useState(!g),2),W=H[0],G=H[1],U=function(){G(!0)},K=wo(e.useState(!1),2),Z=K[0],$=K[1],X=function(e){$(!0),null==w||w({e:e})};e.useEffect((function(){if(g&&null!=S&&S.current){var e,t=function(e,t,n,r){if("undefined"==typeof window)return null;if(!window||!window.IntersectionObserver)return n(),null;var o=null;try{(o=new window.IntersectionObserver((function(t){t[0].isIntersecting&&(n(),o.unobserve(e))}),{rootMargin:"0px 0px ".concat(r,"px 0px"),root:t})).observe(e)}catch(Wy){console.error(Wy),n()}return o}(S.current,null,U,0);return e=S.current,function(){e&&t&&t.unobserve(e)}}}),[g,S]);var q=wo(e.useState(!1),2),Y=q[0],J=q[1],Q=e.useRef(!1),ee=function(e){Q.current=!0,J(!0),O&&(F(O),J(!1)),null==E||E({e:e})},ne=e.useRef();e.useEffect((function(){Y&&V&&J(!1),V&&function(e){return new Promise((function(t){var n=document.createElement("img");n.onerror=function(){return t(!1)},n.onload=function(){return t(!0)},n.src=e}))}(V).then((function(e){setTimeout((function(){e||Q.current||ee(ne.current)}),0)}))}),[V]),e.useEffect((function(){if(ne.current){var e=ne.current,t=e.complete,n=e.naturalWidth,r=e.naturalHeight;t&&0!==n&&0!==r&&X(ne.current)}}),[]);var re="hover"===v,oe=wo(e.useState(!re),2),ae=oe[0],ce=oe[1],ie=function(e){ce(e)},le=function(){var e="string"==typeof B?B:V;return n.createElement("img",{ref:ne,src:e,onError:ee,onLoad:X,className:r("".concat(k,"-image"),"".concat(k,"-image--fit-").concat(u),"".concat(k,"-image--position-").concat(s)),alt:P,referrerPolicy:x})};return n.createElement("div",ub(ub({ref:S,className:r("".concat(k,"-image__wrapper"),"".concat(k,"-image__wrapper--shape-").concat(f),b&&"".concat(k,"-image__wrapper--gallery"),re&&"".concat(k,"-image__wrapper--need-hover"),c),style:l},re?{onMouseEnter:function(){return ie(!0)},onMouseLeave:function(){return ie(!1)}}:null),C),d?n.createElement("div",{className:"".concat(k,"-image__placeholder")},d):null,b?n.createElement("div",{className:"".concat(k,"-image__gallery-shadow")}):null,!(Y||!W)&&n.createElement(e.Fragment,null,y&&Object.keys(y).length?n.createElement("picture",null,Object.entries(a.srcset).map((function(e){var t=wo(e,2),r=t[0],o=t[1];return n.createElement("source",{key:o,type:r,srcSet:o})})),a.src&&le()):le(),!(Y||!W)&&!Z&&n.createElement("div",{className:"".concat(k,"-image__loading")},p||n.createElement(ab,{direction:"vertical",size:8,align:"center"},n.createElement(L,{size:24}),"string"==typeof p?p:R(I.loadingText)))),Y&&n.createElement("div",{className:"".concat(k,"-image__error")},m||n.createElement(ab,{direction:"vertical",size:8,align:"center"},n.createElement(M,{size:24}),"string"==typeof m?m:R(I.errorText))),h?n.createElement("div",{className:r("".concat(k,"-image__overlay-content"),!ae&&"".concat(k,"-image__overlay-content--hidden"))},h):null)},fb=n.forwardRef(sb);fb.displayName="Image";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var db=fb;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function pb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var mb=function(e){var t=bo().classPrefix;return n.createElement("div",{className:"".concat(t,"-image-viewer-mini__content")},n.createElement(hb,{rotateZ:e.rotateZ,scale:e.scale,mirror:e.mirror,src:e.currentImage.mainImage,preSrc:e.currentImage.thumbnail,errorText:e.errorText,imageReferrerpolicy:e.imageReferrerpolicy,isSvg:e.currentImage.isSvg}))},vb=function(e){var t=e.visible,r=e.title,o=e.scale,a=e.currentImage,c=e.draggable,i=e.onZoomOut,l=e.onZoom,u=e.onClose,s=e.onRotate,f=e.onMirror,d=e.onReset,p=e.tipText,m=bo().classPrefix,v=n.createElement("div",{className:"".concat(m,"-image-viewer-mini__footer")},n.createElement(Ob,{onZoom:l,onZoomOut:i,scale:o,currentImage:a,onRotate:s,onMirror:f,onReset:d,tipText:p}));return n.createElement(Sg,{className:"".concat(m,"-image-viewer__dialog"),draggable:c,visible:t,width:"min(90vw, 1000px)",placement:"center",mode:"modeless",closeOnOverlayClick:!1,cancelBtn:null,confirmBtn:null,header:n.createElement("span",{className:"".concat(m,"-image-viewer__dialog-title")},r),footer:v,onClose:u},n.createElement(mb,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e)))},gb=["closeOnOverlay","showOverlay","zIndex","images","isMini","imageScale","viewerScale","closeBtn","draggable","onOpen","onClose","visible","title","closeOnEscKeydown","imageReferrerpolicy"],bb=function(e){var t=e.errorText,r=bo().classPrefix,o=pl({ImageErrorIcon:_}).ImageErrorIcon;return n.createElement("div",{className:"".concat(r,"-image-viewer__img-error")},n.createElement("div",{className:"".concat(r,"-image-viewer__img-error-content")},n.createElement(o,{size:"4em"}),n.createElement("div",{className:"".concat(r,"-image-viewer__img-error-text")},t)))},hb=function(t){var r=t.rotateZ,o=t.scale,a=t.src,c=t.preSrc,i=t.mirror,l=t.errorText,u=t.imageReferrerpolicy,s=t.isSvg,f=bo().classPrefix,d=function(t,n){var r=t.initPosition,o=t.move,a=void 0===o||o,c=t.onMouseUp,i=t.onMouseMove,l=t.onMouseDown,u=wo(e.useState(r),2),s=u[0],f=u[1],d=e.useRef(null),p=e.useCallback((function(){d.current&&(d.current=null,a&&te(c)&&c())}),[a,c]),m=e.useCallback((function(e){if(e.buttons||(d.current=null),d.current&&!d.current.updating&&a){d.current.updating=!0;var t=d.current,n=t.screenX,r=t.screenY,o=e.screenX,c=e.screenY;requestAnimationFrame((function(){d.current&&(f((function(e){var t=wo(e,2),a=t[0],i=t[1];return[a+o-n,i+c-r]})),d.current.screenX=o,d.current.screenY=c,d.current.updating=!1,te(i)&&i())}))}}),[a,i]),v=e.useCallback((function(e){var t=e.screenX,n=e.screenY;d.current={screenX:t,screenY:n},a&&te(l)&&l()}),[a,l]);return e.useEffect((function(){var e=document;return e.addEventListener("mousemove",m),document.addEventListener("mouseup",p),function(){e.removeEventListener("mousemove",m),document.removeEventListener("mouseup",p)}}),[n,a,m,p]),[s,v]}({initPosition:[0,0]}),p=wo(d,2),m=p[0],v=p[1],g=wo(e.useState(!1),2),b=g[0],h=g[1],y=wo(e.useState(!1),2),O=y[0],w=y[1],E=e.useRef(null),j={transform:"rotateZ(".concat(r,"deg) scale(").concat(o,")"),display:!c||b?"block":"none"},P={transform:"rotateZ(".concat(r,"deg) scale(").concat(o,")"),display:b?"none":"block"},x={transform:"translate(".concat(m[0],"px, ").concat(m[1],"px) scale(").concat(i,", 1)")},C=qg(c).previewUrl,_=qg(a).previewUrl,N=function(){var e,t=(e=Jo.mark((function e(t){var n,r,o,a,c,i,l,u,s,d,p,m,v;return Jo.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch(t);case 2:if((r=e.sent).ok){e.next=6;break}throw w(!0),new Error("Failed to fetch SVG: ".concat(r.statusText));case 6:return e.next=8,r.text();case 8:o=e.sent,(a=E.current).innerHTML="",null===(n=a.classList)||void 0===n||n.add("".concat(f,"-image-viewer__modal-image-svg")),c=a.attachShadow({mode:"closed"}),(i=document.createElement("div")).style.background="transparent",i.innerHTML=o,c.appendChild(i),(l=i.querySelector("svg"))&&((u=l.getAttribute("viewBox"))?(s=u.split(/[\s,]/).filter((function(e){return e})).map(parseFloat),d=s[2],p=s[3],i.style.width="".concat(d,"px"),i.style.height="".concat(p,"px")):(m=l.getBBox(),v="".concat(m.x," ").concat(m.y," ").concat(m.width," ").concat(m.height),l.setAttribute("viewBox",v),i.style.width="".concat(m.width,"px"),i.style.height="".concat(m.height,"px"))),h(!0);case 20:case"end":return e.stop()}}),e)})),function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function c(e){$o(a,r,o,c,i,"next",e)}function i(e){$o(a,r,o,c,i,"throw",e)}c(void 0)}))});return function(e){return t.apply(this,arguments)}}();return e.useEffect((function(){w(!1)}),[C,_]),e.useEffect((function(){s&&_&&N(_)}),[_]),n.createElement("div",{className:"".concat(f,"-image-viewer__modal-pic")},n.createElement("div",{className:"".concat(f,"-image-viewer__modal-box"),style:x},O&&n.createElement(bb,{errorText:l}),!O&&!!c&&C&&n.createElement("img",{className:"".concat(f,"-image-viewer__modal-image"),onMouseDown:function(e){e.stopPropagation(),v(e)},src:C,style:P,referrerPolicy:u,alt:"image",draggable:"false"}),!O&&_&&!s&&n.createElement("img",{className:"".concat(f,"-image-viewer__modal-image"),onMouseDown:function(e){e.stopPropagation(),v(e)},src:_,style:j,onLoad:function(){return h(!0)},onError:function(){return w(!0)},referrerPolicy:u,alt:"image",draggable:"false"}),!O&&!!_&&s&&n.createElement("div",{ref:E,className:"".concat(f,"-image-viewer__modal-image"),onMouseDown:function(e){e.stopPropagation(),v(e)},style:j,"data-alt":"svg",draggable:"false"})))},yb=function(e){var t=e.onClick,o=e.className,a=e.disabled,c=e.isRange,i=e.name,l=e.label,u=e.size,s=void 0===u?"16px":u,f=bo().classPrefix,p=function(){var e=pl({ChevronDownIcon:d,ChevronLeftIcon:O,ChevronRightIcon:w,CloseIcon:g,DownloadIcon:E,MirrorIcon:j,RotationIcon:P,ZoomInIcon:x,ZoomOutIcon:C});return{rotation:e.RotationIcon,"zoom-in":e.ZoomInIcon,mirror:e.MirrorIcon,"zoom-out":e.ZoomOutIcon,download:e.DownloadIcon,"chevron-left":e.ChevronLeftIcon,"chevron-right":e.ChevronRightIcon,"chevron-down":e.ChevronDownIcon,close:e.CloseIcon}}()[i];return n.createElement("div",{className:r("".concat(f,"-image-viewer__modal-icon"),o,I({},"".concat(f,"-is-disabled"),a)),onClick:t},i&&n.createElement(p,{size:s,className:c?"is-range":null}),l&&n.createElement("span",{className:"".concat(f,"-image-viewer__modal-icon-label")},l))},Ob=function(e){var t=e.onZoom,r=e.scale,o=e.onZoomOut,a=e.currentImage,c=e.onRotate,i=e.onMirror,l=e.onReset,u=e.tipText,s=bo().classPrefix,f=pl({MirrorIcon:j,RotationIcon:P,ImageIcon:N}),d=f.MirrorIcon,p=f.RotationIcon,m=f.ImageIcon;return n.createElement("div",{className:"".concat(s,"-image-viewer__utils")},n.createElement("div",{className:"".concat(s,"-image-viewer__utils-content")},n.createElement(Kf,{className:"".concat(s,"-image-viewer__utils--tip"),content:u.mirror,showShadow:!1},n.createElement("div",{className:"".concat(s,"-image-viewer__modal-icon")},n.createElement(d,{size:"medium",onClick:i}))),n.createElement(Kf,{className:"".concat(s,"-image-viewer__utils--tip"),content:u.rotate,showShadow:!1},n.createElement("div",{className:"".concat(s,"-image-viewer__modal-icon")},n.createElement(p,{size:"medium",onClick:function(){return c(-90)}}))),n.createElement(yb,{size:"medium",name:"zoom-out",onClick:o}),n.createElement(yb,{className:"".concat(s,"-image-viewer__utils-scale"),size:"medium",label:"".concat(100*r,"%")}),n.createElement(yb,{size:"medium",name:"zoom-in",onClick:t}),n.createElement(Kf,{className:"".concat(s,"-image-viewer__utils--tip"),content:u.originsize,showShadow:!1},n.createElement("div",{className:"".concat(s,"-image-viewer__modal-icon")},n.createElement(m,{size:"medium",name:"image",onClick:function(){l()}}))),a.download&&n.createElement(yb,{size:"medium",name:"download",onClick:function(){var e,t,n,r;e=a.mainImage,n=new Image,r=(null==e||null===(t=e.split)||void 0===t?void 0:t.call(e,"/").pop())||Math.random().toString(32).slice(2),n.setAttribute("crossOrigin","anonymous"),n.onload=function(){var e=document.createElement("canvas");e.width=n.width,e.height=n.height,e.getContext("2d").drawImage(n,0,0,n.width,n.height),e.toBlob((function(e){var t=URL.createObjectURL(e),n=document.createElement("a");n.download=r,n.href=t,n.click(),n.remove(),URL.revokeObjectURL(t)}))},n.src=e}})))};function wb(e){var t=e.image,r=e.classPrefix,o=e.imageReferrerpolicy,a=qg(t.thumbnail||t.mainImage).previewUrl;return n.createElement(db,{alt:"",error:"",src:a,className:"".concat(r,"-image-viewer__header-img"),referrerpolicy:o})}var Eb=function(t){var o=bo().classPrefix,a=t.images,c=t.currentIndex,i=t.onImgClick,l=t.imageReferrerpolicy,u=wo(e.useState(!0),2),s=u[0],f=u[1],d={transform:"translateX(calc(-".concat(c," * (40px / 9 * 16 + 4px)))")};return n.createElement("div",{className:r("".concat(o,"-image-viewer__modal-header"),I({},"".concat(o,"-is-show"),s))},n.createElement(yb,{name:"chevron-down",className:"".concat(o,"-image-viewer__header-pre-bt"),onClick:function(){return f(!s)}}),n.createElement("div",{className:"".concat(o,"-image-viewer__header-prev")},n.createElement("div",{className:"".concat(o,"-image-viewer__header-trans"),style:d},a.map((function(e,t){return n.createElement("div",{key:t,className:r("".concat(o,"-image-viewer__header-box"),I({},"".concat(o,"-is-active"),t===c)),onClick:function(){return i(t,{trigger:"current"})}},n.createElement(wb,{image:e,classPrefix:o,imageReferrerpolicy:l}))})))))},jb=function(t){var o=t.closeOnOverlay,a=t.showOverlay,c=void 0===a||a,i=t.zIndex,l=t.images,u=t.isMini,s=t.imageScale,f=t.viewerScale,d=t.closeBtn,p=t.draggable,m=t.onOpen,v=t.onClose,g=t.visible,b=t.title,h=t.closeOnEscKeydown,y=t.imageReferrerpolicy,O=T(t,gb),w=bo().classPrefix,E=wo(yl("imageViewer"),2),j=E[0],P=E[1];void 0===O.index&&delete O.index;var x=function(t,n){var r=wo(fc(t,"index",t.onIndexChange),2),o=r[0],a=r[1],c=e.useCallback((function(){var e=o+1;if(e>=n.length)return o;a(e,{trigger:"next"})}),[a,o,n.length]),i=e.useCallback((function(){a(o-1>0?o-1:0,{trigger:"prev"})}),[o,a]);return{index:o,next:c,prev:i,setIndex:a}}(O,l),C=x.index,_=x.next,N=x.prev,k=x.setIndex,S=function(){var t=e.useRef(0),n=wo(e.useState(0),2),r=n[0],o=n[1],a=e.useCallback((function(e){o((function(n){return t.current=n+e,n+e}))}),[]);return{rotateZ:r,onResetRotate:e.useCallback((function(){var e=t.current%360;Math.abs(e)>180&&(e=(e+360)%360),0!==e&&o((function(n){return t.current=n-e,n-e}))}),[]),onRotate:a}}(),D=S.rotateZ,R=S.onResetRotate,A=S.onRotate,M=function(t){var n=wo(e.useState((function(){var e;return null!==(e=t.defaultScale)&&void 0!==e?e:1})),2),r=n[0],o=n[1];return{scale:r,onZoom:e.useCallback((function(){o((function(e){var n=e+t.step;return n<t.min?t.min:n>t.max?t.max:n}))}),[t]),onZoomOut:e.useCallback((function(){o((function(e){var n=e-t.step;return n<t.min?t.min:n>t.max?t.max:n}))}),[t]),onResetScale:e.useCallback((function(){var e;return o(null!==(e=t.defaultScale)&&void 0!==e?e:1)}),[t])}}(s),L=M.scale,z=M.onZoom,B=M.onZoomOut,F=M.onResetScale,V=function(){var t=wo(e.useState(1),2),n=t[0],r=t[1],o=e.useCallback((function(){r((function(e){return e>0?-1:1}))}),[]);return{mirror:n,onResetMirror:e.useCallback((function(){return r(1)}),[]),onMirror:o}}(),H=V.mirror,W=V.onResetMirror,G=V.onMirror,U=e.useCallback((function(){F(),R(),W()}),[W,F,R]),K=e.useCallback((function(e){e.preventDefault(),e.deltaY<0?z():B()}),[z,B]);e.useEffect((function(){return g?document.addEventListener("wheel",K,{passive:!1}):document.removeEventListener("wheel",K),function(){document.removeEventListener("wheel",K)}}),[g,K]);var Z=e.useCallback((function(e){switch(e.key){case"ArrowRight":return _();case"ArrowLeft":return N();case"ArrowUp":return z();case"ArrowDown":return B();case"Escape":return h&&(null==v?void 0:v({trigger:"esc",e:e}))}}),[_,v,N,z,B,h]);if(e.useEffect((function(){return document.addEventListener("keydown",Z),function(){return document.removeEventListener("keydown",Z)}}),[Z]),e.useEffect((function(){U()}),[C,U]),!Pt(l)||l.length<1)return null;var $=l[C],X={mirror:P(j.mirrorTipText),rotate:P(j.rotateTipText),originsize:P(j.originalSizeTipText)},q=P(j.errorText);if(u)return n.createElement(vb,{visible:g,draggable:p,index:C,images:l,imageScale:s,viewerScale:f,rotateZ:D,zIndex:i,currentImage:$,prev:N,next:_,mirror:H,scale:L,title:b,onMirror:G,onZoom:z,onClose:v,onZoomOut:B,onReset:U,onRotate:A,errorText:q,tipText:X,imageReferrerpolicy:y});var Y=d;return!0===d?Y=n.createElement(yb,{name:"close",size:"24px",className:"".concat(w,"-image-viewer__modal-close-bt "),onClick:function(e){return v&&v({trigger:"close-btn",e:e})}}):te(d)&&(Y=d({onClose:v,onOpen:m})),n.createElement("div",{className:r("".concat(w,"-image-viewer-preview-image"),I({},"".concat(w,"-is-hide"),!g)),style:{zIndex:i}},!!c&&n.createElement("div",{className:"".concat(w,"-image-viewer__modal-mask"),onClick:function(e){return o&&(null==v?void 0:v({trigger:"overlay",e:e}))}}),l.length>1&&n.createElement(n.Fragment,null,n.createElement(Eb,{images:l,currentIndex:C,onImgClick:k,imageReferrerpolicy:y}),n.createElement("div",{className:"".concat(w,"-image-viewer__modal-index")},n.createElement("span",null,b),"".concat(C+1,"/").concat(l.length)),n.createElement(yb,{size:"24px",name:"chevron-left",className:"".concat(w,"-image-viewer__modal-prev-bt"),onClick:N,disabled:C<=0}),n.createElement(yb,{size:"24px",name:"chevron-right",className:"".concat(w,"-image-viewer__modal-next-bt"),onClick:_,disabled:C>=l.length-1})),n.createElement(Ob,{onZoom:z,onZoomOut:B,scale:L,currentImage:$,onRotate:A,onMirror:G,onReset:U,tipText:X}),Y,n.createElement(hb,{scale:L,rotateZ:D,mirror:H,preSrc:$.thumbnail,src:$.mainImage,errorText:q,imageReferrerpolicy:y,isSvg:$.isSvg}))},Pb={closeBtn:!0,closeOnEscKeydown:!0,draggable:void 0,images:[],defaultIndex:0,mode:"modal",navigationArrow:!0,showOverlay:void 0,defaultVisible:!1};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function xb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Cb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?xb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function _b(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var Nb=function(e){return Pt(e)?e.map((function(e){return!(t=e)||xo(t)||t instanceof File?{mainImage:e,thumbnail:e,download:!0}:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_b(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({download:!0,thumbnail:e.mainImage},e);var t})):[]},kb=function(r){var o=ho(r,Pb),a=o.attach,c=o.mode,i=o.trigger,l=o.images,u=o.title,s=o.imageScale,f=o.viewerScale,d=Zi("imageViewer",a),p=wo(fc(o,"visible",(function(e,t){var n;!e&&(null==o||null===(n=o.onClose)||void 0===n||n.call(o,t))})),2),m=p[0],v=p[1],g=wo(e.useState(!1),2),b=g[0],h=g[1],y=function(t){return e.useMemo((function(){return Nb(t)}),[t])}(l),O=function(e){var t=Cb(Cb({},e),{},{max:2,min:.5,step:.5});return void 0!==(null==e?void 0:e.min)&&(t.min=e.min),void 0!==(null==e?void 0:e.max)&&(t.max=e.max),void 0!==(null==e?void 0:e.step)&&(t.step=e.step),void 0!==(null==e?void 0:e.defaultScale)&&(e.defaultScale>t.max&&(t.defaultScale=t.max),e.defaultScale<t.min&&(t.defaultScale=t.min)),t}(s),w=function(e){var t={minWidth:1e3,minHeight:1e3};return void 0!==(null==e?void 0:e.minWidth)&&(t.minWidth=e.minWidth),void 0!==(null==e?void 0:e.minHeight)&&(t.minHeight=e.minHeight),t}(f),E="modeless"===c,j=function(e){v(!1,e),setTimeout((function(){return h(!1)}),196)},P=function(){l&&(v(!0,null),h(!0))},x=te(i)?i({open:P,close:j,onOpen:P,onClose:j}):i,C=e.useMemo((function(){return Co&&d?"string"==typeof d?document.querySelector(d):te(d)?d():void 0:null}),[d]);return n.createElement(n.Fragment,null,x,(b||m)&&t.createPortal(n.createElement(jb,{title:u,visible:m,images:y,isMini:E,imageScale:O,viewerScale:w,zIndex:o.zIndex,defaultIndex:o.defaultIndex,index:o.index,onIndexChange:o.onIndexChange,draggable:o.draggable,closeOnOverlay:o.closeOnOverlay,closeBtn:o.closeBtn,showOverlay:o.showOverlay,closeOnEscKeydown:o.closeOnEscKeydown,onClose:j,onOpen:P,imageReferrerpolicy:o.imageReferrerpolicy}),C))};kb.displayName="ImageViewer";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Sb=kb;
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Db(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ib(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Db(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Db(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Tb=function(e){var t=e.content,o=e.cancelBtn,a=e.confirmBtn,c=e.icon,i=e.theme,l=e.onCancel,u=void 0===l?sc:l,s=e.onConfirm,f=void 0===s?sc:s,d=e.onClose,p=void 0===d?sc:d,m=bo().classPrefix,v=pl({InfoCircleFilledIcon:h}).InfoCircleFilledIcon,g=null==o,b=null==a;return n.createElement("div",{className:"".concat(m,"-popconfirm__content ").concat(e.className),style:e.style},n.createElement("div",{className:"".concat(m,"-popconfirm__body")},function(){var e="#0052D9",t=n.createElement(v,null);switch(i){case"warning":e="#FFAA00";break;case"danger":e="#FF3E00"}var r=null;return n.isValidElement(c)?r=n.cloneElement(c,Ib({style:{color:e}},c.props)):t&&(r=n.cloneElement(t,{style:{color:e}})),r}(),n.createElement("div",{className:"".concat(m,"-popconfirm__inner")},t)),n.createElement("div",{className:"".concat(m,"-popconfirm__buttons")},n.createElement("span",{className:r("".concat(m,"-popconfirm__cancel"))},n.isValidElement(o)?n.cloneElement(o,{onClick:function(e){var t,n;p({e:e,trigger:"cancel"}),null===(t=o.props)||void 0===t||null===(n=t.onClick)||void 0===n||n.call(t,e)}}):g?null:n.createElement(sl,Ib({size:"small",theme:"default",variant:"base",onClick:function(e){p({e:e,trigger:"cancel"}),u({e:e})}},"object"===S(o)?Ib({},o):{}),xo(o)&&o)),n.createElement("span",{className:r("".concat(m,"-popconfirm__confirm"))},n.isValidElement(a)?n.cloneElement(a,{onClick:function(e){var t,n;p({e:e,trigger:"confirm"}),null===(t=a.props)||void 0===t||null===(n=t.onClick)||void 0===n||n.call(t,e)}}):b?null:n.createElement(sl,Ib({size:"small",theme:"primary",onClick:function(e){p({e:e,trigger:"confirm"}),f({e:e})}},"object"===S(a)?Ib({},a):{}),xo(a)&&a))))};Tb.displayName="Popcontent";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Rb={destroyOnClose:!0,placement:"top",showArrow:!0,theme:"default"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Ab(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Mb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ab(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ab(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Lb=e.forwardRef((function(e,t){var o=bo().classPrefix,a=wo(yl("popconfirm"),2),c=a[0],i=a[1],l="string"==typeof c.cancel?c.cancel:c.cancel.content,u="string"==typeof c.confirm?c.confirm:c.confirm.content,s=ho(e,Rb),f=s.cancelBtn,d=void 0===f?i(l):f,p=s.confirmBtn,m=void 0===p?i(u):p,v=wo(fc(s,"visible",s.onVisibleChange),2),g=v[0],b=v[1];return n.createElement(Yi,Mb(Mb({ref:t},s),{},{visible:g,trigger:"click",onVisibleChange:function(e){return b(e)},overlayClassName:r("".concat(o,"-popconfirm")),content:n.createElement(Tb,Mb(Mb({cancelBtn:d,confirmBtn:m},s),{},{onClose:function(e){return b(!1,e)}}))},s.popupProps))}));Lb.displayName="Popconfirm";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var zb=Lb,Bb={direction:"right",hideAfterItemClick:!0,maxColumnWidth:100,maxHeight:300,minColumnWidth:10,placement:"bottom-left",trigger:"hover"},Fb={active:!1,disabled:!1,divider:!1,theme:"default"};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Vb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Hb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Wb=e.forwardRef((function(e,t){var o=ho(e,Fb),a=o.children,c=o.className,i=o.active,l=o.disabled,u=o.value,s=o.theme,f=o.prefixIcon,d=o.maxColumnWidth,p=o.minColumnWidth,m=o.onClick,v=o.style,g=o.isSubmenu,b=bo().classPrefix,h=wo(Do(),2),y=h[0],O=h[1];Qi(g||l?null:(null==t?void 0:t.current)||y);return n.createElement(n.Fragment,null,n.createElement("li",{className:r(c,"".concat(b,"-dropdown__item--theme-").concat(s),I(I({},"".concat(b,"-dropdown__item--active"),i),"".concat(b,"-dropdown__item--disabled"),l)),onClick:function(e){l||null==m||m(u,e)},style:Hb({maxWidth:Pu(d),minWidth:Pu(p)},v),ref:t||O},f?n.createElement("div",{className:"".concat(b,"-dropdown__item-icon")},f):null,a))}));
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Gb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ub(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Gb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Gb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}Wb.displayName="DropdownItem";var Kb=function(t){var o=t.options,a=void 0===o?[]:o,c=t.maxHeight,i=void 0===c?300:c,l=t.minColumnWidth,u=void 0===l?10:l,s=t.maxColumnWidth,f=void 0===s?160:s,d=t.direction,p=t.panelTopContent,m=t.panelBottomContent,v=bo().classPrefix,g="".concat(v,"-dropdown"),b="".concat(g,"__menu"),h=wo(e.useState(null),2),y=h[0],O=h[1],E=pl({ChevronRightIcon:w}).ChevronRightIcon,j=e.useRef(),P=wo(e.useState(!1),2),x=P[0],C=P[1],_=wo(e.useState({}),2),N=_[0],k=_[1];e.useEffect((function(){if(j.current){var e,t=30*(null===(e=j.current.childNodes)||void 0===e?void 0:e.length);setTimeout((function(){if(p){var e,t,n=parseInt(null===(e=getComputedStyle(null===(t=j.current.childNodes)||void 0===t?void 0:t[0]))||void 0===e?void 0:e.height,10)||0;O(n)}})),t>=i&&C(!0)}}),[i,p]);var S=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=e.target.scrollTop;k(Ub(Ub({},N),{},I({},t,n)))},D=Vf(S,100),T=function(e,o){var a,c,i=[];return null===(a=e.forEach)||void 0===a||a.call(e,(function(e,a){var l=Ub({},e),s=Math.ceil(N[o]/30),d=p&&o>0,m=a>=s?a-s:a;l.children?(l.children=T(l.children,o+1),c=n.createElement("div",{key:a},n.createElement(Wb,{className:r(l.className,"".concat(g,"__item"),"".concat(g,"__item--suffix")),style:l.style,value:l.value,theme:l.theme,active:l.active,prefixIcon:l.prefixIcon,disabled:l.disabled,minColumnWidth:u,maxColumnWidth:f,isSubmenu:!0},n.createElement("div",{className:"".concat(g,"__item-content")},n.createElement("span",{className:"".concat(g,"__item-text")},l.content),n.createElement(E,{className:"".concat(g,"__item-direction"),size:"16"})),n.createElement("div",{className:r("".concat(g,"__submenu-wrapper"),I({},"".concat(g,"__submenu-wrapper--").concat(t.direction),t.direction)),style:{position:"absolute",top:"".concat(30*m+(d?0:y),"px")}},n.createElement("div",{className:r("".concat(g,"__submenu"),I({},"".concat(g,"__submenu--disabled"),l.disabled)),style:{position:"static",maxHeight:"".concat(t.maxHeight,"px")},onScroll:function(e){return S(e,o+1)}},n.createElement("ul",null,l.children)))),l.divider?n.createElement(Lg,null):null)):c=n.createElement("div",{key:a},n.createElement(Wb,{className:r(l.className,"".concat(g,"__item")),style:l.style,value:l.value,theme:l.theme,active:l.active,prefixIcon:l.prefixIcon,disabled:l.disabled,minColumnWidth:u,maxColumnWidth:f,onClick:l.disabled||l.children?function(){return null}:function(e,n){return function(e){var n,r,o=e.data,a=e.context;null==o||null===(n=o.onClick)||void 0===n||n.call(o,o,a),null===(r=t.onClick)||void 0===r||r.call(t,o,a)}({data:l,context:n})}},n.createElement("span",{className:"".concat(g,"__item-text")},l.content)),l.divider?n.createElement(Lg,null):null),i.push(c)})),i};return n.createElement("div",{className:r(b,"".concat(b,"--").concat(d),I({},"".concat(b,"--overflow"),x)),style:{maxHeight:"".concat(i,"px")},ref:j,onScroll:D},p?n.createElement("div",{className:"".concat(g,"__top-content")},p):null,T(a,0),m?n.createElement("div",{className:"".concat(g,"__bottom-content")},m):null)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Zb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $b(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Zb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}Kb.displayName="DropdownMenu";var Xb=function(e){if(!e)return[];if(e.type===Kb){var t=e.props.children;if(Array.isArray(t))return Xb(t)}return n.Children.toArray(e).map((function(e){var t,n,r=null===(t=e.props)||void 0===t?void 0:t.children,o=null===(n=e.props)||void 0===n?void 0:n.content;if(Array.isArray(r)){var a,c,i=null==r||null===(a=r.filter)||void 0===a?void 0:a.call(r,(function(e){return![Wb,Kb].includes(e.type)})),l=null==r||null===(c=r.filter)||void 0===c?void 0:c.call(r,(function(e){return[Wb,Kb].includes(e.type)}));return $b($b({},e.props),{},{content:i||r,children:l.length>0?Xb(r[1]):null})}return $b($b({},e.props),{},{content:r||o,children:null})})).filter((function(e){return!!e.content}))};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function qb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Yb(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qb(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qb(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Jb=function(t){var o=ho(t,Bb),a=o.popupProps,c=void 0===a?{}:a,i=o.disabled,l=o.placement,u=o.trigger,s=o.className,f=o.children,d=o.hideAfterItemClick,p=o.options,m=o.style,v=n.Children.toArray(f),g=bo().classPrefix,b=wo(e.useState(!1),2),h=b[0],y=b[1],O="".concat(g,"-dropdown"),w=function(t,r){return e.useMemo((function(){return r&&r.length>0?r:(n.Children.forEach(t,(function(t){n.isValidElement(t)&&t.type===Kb&&t.props.children&&(e=t.props.children)})),Xb(e));var e}),[r,t])}(v,p),E=n.createElement(Kb,Yb(Yb({},o),{},{options:w,onClick:function(e,t){var n,r;d&&(y(!1),null==c||null===(r=c.onVisibleChange)||void 0===r||r.call(c,!1,t));null===(n=o.onClick)||void 0===n||n.call(o,e,t)}})),j=Yb(Yb({disabled:i,placement:l,trigger:u,showArrow:!1,content:E},Sp(c,"onVisibleChange")),{},{overlayInnerClassName:r(O,s,null==c?void 0:c.overlayInnerClassName),overlayInnerStyle:m}),P=null==v?void 0:v[0],x=e.isValidElement(P)?n.cloneElement(P,{disabled:i}):P;return n.createElement(Yi,Yb({expandAnimation:!0,destroyOnClose:!0,visible:h,onVisibleChange:function(e,t){var n;!i&&w.length&&(y(e),null==c||null===(n=c.onVisibleChange)||void 0===n||n.call(c,e,t))}},j),x)};Jb.DropdownItem=Wb,Jb.DropdownMenu=Kb,Jb.displayName="Dropdown";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Qb=Jb,eh=function(e){return"".concat(100*e,"%")};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function th(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var nh=function(t){var o=t.onChange,a=t.style,c=t.classPrefix,i=t.toolTipProps,l=t.hideTips,u=wo(e.useState(!1),2),s=u[0],f=u[1],d=wo(e.useState(!1),2),p=d[0],m=d[1],v=function(e){m(!0),o(e)},g=function(){m(!1),window.removeEventListener("mousemove",v),window.removeEventListener("mouseup",g),window.removeEventListener("touchmove",v),window.removeEventListener("touchend",g)},b=n.createElement("div",{style:a,className:"".concat(c,"-slider__button-wrapper"),onMouseDown:function(e){return function(e){e.stopPropagation(),f(!0),window.addEventListener("mousemove",v),window.addEventListener("mouseup",g),window.addEventListener("touchmove",v),window.addEventListener("touchend",g)}(e)},onMouseEnter:function(e){return e.stopPropagation(),void f(!0)},onMouseLeave:function(e){return e.stopPropagation(),void f(!1)}},n.createElement("div",{className:r("".concat(c,"-slider__button"),I({},"".concat(c,"-slider__button--dragging"),p))}));return l?b:n.createElement(zf,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?th(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):th(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({visible:s,placement:"top"},i),b)};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function rh(e,t){var n=function(e){return"number"==typeof e&&!Number.isInteger(e)};if(n(e)&&n(t)){var r=wo(String(e).split("."),2),o=r[0],a=r[1],c=wo(String(t).split("."),2),i=c[0],l=c[1],u=Math.max(a.length,l.length),s=(Number(a.padEnd(u,"0"))+Number(l.padEnd(u,"0")))/Math.pow(10,u);return Number(o)+Number(i)+s}return e+t}
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */var oh={inputNumberProps:!1,label:!0,layout:"horizontal",max:100,min:0,range:!1,step:1};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function ah(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ch(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ah(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ah(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ih=n.forwardRef((function(t,o){var a=bo().classPrefix,c=ho(t,oh),i=c.disabled,l=c.inputNumberProps,u=c.label,s=c.layout,f=c.marks,d=c.max,p=c.min,m=c.range,v=c.step,g=c.tooltipProps,b=c.className,h=c.style,y=c.onChange,O=e.useRef(null),w=wo(fc(c,"value",y),2),E=w[0],j=w[1],P="vertical"===s,x=Array.isArray(E)?E:[p,E],C=(x[0]-p)/(d-p),_=(x[1]-x[0])/(d-p),N=C+_,k=e.useMemo((function(){if(Array.isArray(f))return f.some((function(e){return"number"!=typeof e}))?(console.warn('The props "marks" only support number!'),[]):f.map((function(e){return{value:e,position:(e-p)/(d-p),label:e}}));if(f&&"object"===S(f)){var e=[];return Object.keys(f).forEach((function(t){var n=Number(t);"number"!=typeof n?console.warn('The props "marks" key only support number!'):e.push({value:n,label:f[n],position:(n-p)/(d-p)})})),e}return[]}),[d,p,f]),D=e.useMemo((function(){for(var e=[],t=p;t<=d;t=rh(t,v))e.push({value:t,position:(t-p)/(d-p)});return e}),[d,p,v]),T=P?"bottom":"left",R=P?"top":"left",A=P?"height":"width",M=P?k.map((function(e){return ch(ch({},e),{},{position:1-e.position})})):k,L=function(e,t){var n=Number(e.toFixed(32)),r=Math.max(Math.min(d,n),p);if(0===t&&E&&n>E[1]&&(r=E[1]),1===t&&E&&n<E[0]&&(r=E[0]),Array.isArray(E)){var o=E.slice();o[t]=r,j(o)}else j(r)},z=function(e){var t="object"===S(l)?l:{},o=x[e];return n.createElement(xs,ch({value:o,onChange:function(t){void 0!==t&&L(Number(t),e)},className:r("".concat(a,"-slider-input"),{"is-vertical":P}),disabled:i,theme:"column"},t))},B=function(e){var t=Math.abs(e-x[0])>Math.abs(e-x[1])?1:0;L(e,t)},F=function(e,t){if(!i&&O.current){var n=P?"clientY":"clientX",r=O.current.getBoundingClientRect(),o=r[T];!function(e,t){for(var n=0,r=1,o=0;o<D.length;o++){var a=Math.abs(D[o].position-e);r>a&&(n=o,r=a)}var c=D[n].value;void 0===t&&m?B(c):L(c,t)}((e[n]-o)/r[A]*(P?-1:1),t)}},V=function(e,t){var r=x[e],o=r;return te(u)&&(o=u({value:r,position:0===e?"start":"end"})),xo(u)&&(o=u.replace(/\$\{value\}/g,r.toString())),n.createElement(nh,{toolTipProps:ch({content:o},g),hideTips:!1===u,classPrefix:a,style:t,onChange:function(t){return F(t,e)}})};return n.createElement("div",{style:ch({},h),className:r("".concat(a,"-slider__container"),{"is-vertical":P}),ref:o},n.createElement("div",{ref:O,className:r("".concat(a,"-slider"),b,I(I(I({},"".concat(a,"-is-disabled"),i),"".concat(a,"-slider--vertical"),P),"".concat(a,"-slider--with-input"),l)),onClick:F},n.createElement("div",{className:r("".concat(a,"-slider__rail"))},n.createElement("div",{style:I(I({},T,eh(C)),A,eh(_)),className:r("".concat(a,"-slider__track"))}),m?V(0,I({},T,eh(C))):null,V(1,I({},T,eh(N))),n.createElement("div",{className:"".concat(a,"-slider__stops")},M.map((function(e){var t=e.position,o=e.value;return 0===t||1===t?null:n.createElement("div",{key:o,style:I({},R,eh(t)),className:r("".concat(a,"-slider__stop"))})}))),n.createElement("div",{className:r("".concat(a,"-slider__mark"))},M.map((function(e){var t=e.position,o=e.value,c=e.label;return n.createElement("div",{key:o,onClick:function(e){return function(e,t){e.stopPropagation(),B(t)}(e,o)},style:I({},R,eh(t)),className:r("".concat(a,"-slider__mark-text"))},c)}))))),l?n.createElement("div",{className:r("".concat(a,"-slider__input-container"),{"is-vertical":P})},m&&z(0),m&&n.createElement("div",{className:"".concat(a,"-slider__center-line")}),z(1)):null)}));ih.displayName="Slider";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var lh,uh,sh,fh,dh,ph,mh,vh=ih,gh=function(){var e=bo().classPrefix;return"".concat(e,"-color-picker")},bh={monochrome:"singleColor","linear-gradient":"gradientColor"},hh="#001F97",yh="linear-gradient(90deg, rgba(241,29,0,1) 0%, rgba(73,106,220,1) 100%);",Oh=["#ECF2FE","#D4E3FC","#BBD3FB","#96BBF8","#699EF5","#4787F0","#266FE8","#0052D9","#0034B5","#001F97","#FDECEE","#F9D7D9","#F8B9BE","#F78D94","#F36D78","#E34D59","#C9353F","#B11F26","#951114","#680506","#FEF3E6","#F9E0C7","#F7C797","#F2995F","#ED7B2F","#D35A21","#BA431B","#9E3610","#842B0B","#5A1907","#E8F8F2","#BCEBDC","#85DBBE","#48C79C","#00A870","#078D5C","#067945","#056334","#044F2A","#033017"],wh=["HEX","RGB","HSL","HSV","CMYK","CSS"],Eh=function(e){var t=wo(yl("colorPicker"),2),r=t[0],o=t[1],a=e.baseClassName,c=e.mode,i=void 0===c?"monochrome":c,l=e.colorModes,u=e.onModeChange;return 1===(null==l?void 0:l.length)?null:n.createElement("div",{className:"".concat(a,"__head")},n.createElement("div",{className:"".concat(a,"__mode")},n.createElement(Wu.Group,{variant:"default-filled",size:"small",value:i,onChange:u},Object.keys(bh).map((function(e){return n.createElement(Wu.Button,{key:e,value:e},o(r[bh[e]]))})))))},jh=n.memo(Eh),Ph=/cmyk\((\d+%?),(\d+%?),(\d+%?),(\d+%?)\)/,xh=function(e){return Math.max(0,Math.min(255,parseInt(e,10)))},Ch=function(e){if(/cmyk/i.test(e)){var t=e.replace(/\s/g,"").match(Ph),n=function(e,t,n,r){var o=e/100,a=t/100,c=n/100,i=r/100,l=1-(o=o*(1-i)+i),u=1-(a=a*(1-i)+i),s=1-(c=c*(1-i)+i);return{r:l=Math.round(255*l),g:u=Math.round(255*u),b:s=Math.round(255*s)}}(xh(t[1]),xh(t[2]),xh(t[3]),xh(t[4])),r=n.r,o=n.g,a=n.b;return"rgb(".concat(r,", ").concat(o,", ").concat(a,")")}return e},_h=function(e,t){for(var n="",r=0;r<e.length;r++)xo(e[r])?n+=e[r]:n+=e[r].source;return new RegExp(n,t)},Nh=(lh=/\s*,\s*/,uh=/(?:[+-]?\d*\.?\d+)(?:%|[a-z]+)?/,sh=_h(["(?:",/#(?:[a-f0-9]{6}|[a-f0-9]{3})/,"|","(?:rgb|hsl)",/\(\s*(?:\d{1,3}\s*,\s*){2}\d{1,3}\s*\)/,"|","(?:rgba|hsla)",/\(\s*(?:\d{1,3}\s*,\s*){2}\d{1,3}\s*,\s*\d*\.?\d+\)/,"|",/[_a-z-][_a-z0-9-]*/,")"],""),fh=_h([sh,"(?:\\s+",uh,"(?:\\s+",uh,")?)?"],""),dh=_h(["(?:",fh,lh,")*",fh],""),ph=_h(["(?:(",/(?:[+-]?\d*\.?\d+)(?:deg|grad|rad|turn)/,")|",/to\s+((?:(?:left|right|top|bottom)(?:\s+(?:top|bottom|left|right))?))/,")"],""),{gradientSearch:_h(["(?:(",ph,")",lh,")?(",dh,")"],"gi"),colorStopSearch:_h(["\\s*(",sh,")","(?:\\s+","(",uh,"))?","(?:",lh,"\\s*)?"],"gi")}),kh=/.*gradient\s*\(((?:\([^)]*\)|[^)(]*)*)\)/gim,Sh=function(e){return kh.lastIndex=0,kh.exec(e)},Dh={top:0,right:90,bottom:180,left:270,"top left":225,"left top":225,"top right":135,"right top":135,"bottom left":315,"left bottom":315,"bottom right":45,"right bottom":45},Ih=function(e){var t=Sh(e);if(!t)return!1;var n={points:[],degree:0},r=function(e,t){var n,r,o;e.gradientSearch.lastIndex=0;var a=e.gradientSearch.exec(t);if(!Ro(a))for(n={original:a[0],colorStopList:[]},a[1]&&(n.line=a[1]),a[2]&&(n.angle=a[2]),a[3]&&(n.sideCorner=a[3]),e.colorStopSearch.lastIndex=0,r=e.colorStopSearch.exec(a[4]);!Ro(r);)o={color:r[1]},r[2]&&(o.position=r[2]),n.colorStopList.push(o),r=e.colorStopSearch.exec(a[4]);return n}(Nh,t[1]);if(r.original.trim()!==t[1].trim())return!1;var o=r.colorStopList.map((function(e){var t=e.color,n=e.position,r=Object.create(null);return r.color=b(t).toRgbString(),r.left=parseFloat(n),r}));n.points=o;var a=parseInt(r.angle,10);return Number.isNaN(a)&&(a=Dh[r.sideCorner]||90),n.degree=a,n};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */function Th(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Rh(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Th(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Th(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ah=Math.round,Mh=function(e){return b(e).toRgb()},Lh=function(e){var t=e.points,n=e.degree,r=t.sort((function(e,t){return e.left-t.left})).map((function(e){return"".concat(e.color," ").concat(Math.round(100*e.left)/100,"%")}));return"linear-gradient(".concat(n,"deg,").concat(r.join(","),")")},zh=function(e,t){return{id:(1+4294967295*Math.random()).toString(16),left:e,color:t}},Bh=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),I(this,"states",{s:100,v:100,h:100,a:1}),I(this,"gradientStates",{colors:[],degree:0,selectedId:null,css:""}),this.update(t)},t=[{key:"update",value:function(e){if(e!==this.originColor){var t=Ih(e);if(this.isGradient&&!t){var n=b(e).toHsv();return this.states=n,void this.updateCurrentGradientColor()}this.originColor=e,this.isGradient=!1;var r=e;if(t){var o,a;this.isGradient=!0;var c=t,i=c.points.map((function(e){return zh(e.left,e.color)}));this.gradientStates={colors:i,degree:c.degree,selectedId:(null===(o=i[0])||void 0===o?void 0:o.id)||null},this.gradientStates.css=this.linearGradient,r=null===(a=this.gradientSelectedPoint)||void 0===a?void 0:a.color}this.updateStates(r)}}},{key:"saturation",get:function(){return this.states.s},set:function(e){this.states.s=Math.max(0,Math.min(100,e)),this.updateCurrentGradientColor()}},{key:"value",get:function(){return this.states.v},set:function(e){this.states.v=Math.max(0,Math.min(100,e)),this.updateCurrentGradientColor()}},{key:"hue",get:function(){return this.states.h},set:function(e){this.states.h=Math.max(0,Math.min(360,e)),this.updateCurrentGradientColor()}},{key:"alpha",get:function(){return this.states.a},set:function(e){this.states.a=Math.max(0,Math.min(1,Math.round(100*e)/100)),this.updateCurrentGradientColor()}},{key:"rgb",get:function(){var e=Mh(this.states),t=e.r,n=e.g,r=e.b;return"rgb(".concat(Ah(t),", ").concat(Ah(n),", ").concat(Ah(r),")")}},{key:"rgba",get:function(){var e=Mh(this.states),t=e.r,n=e.g,r=e.b,o=e.a;return"rgba(".concat(Ah(t),", ").concat(Ah(n),", ").concat(Ah(r),", ").concat(o,")")}},{key:"hsv",get:function(){var e=this.getHsva(),t=e.h,n=e.s,r=e.v;return"hsv(".concat(t,", ").concat(n,"%, ").concat(r,"%)")}},{key:"hsva",get:function(){var e=this.getHsva(),t=e.h,n=e.s,r=e.v,o=e.a;return"hsva(".concat(t,", ").concat(n,"%, ").concat(r,"%, ").concat(o,")")}},{key:"hsl",get:function(){var e=this.getHsla(),t=e.h,n=e.s,r=e.l;return"hsl(".concat(t,", ").concat(n,"%, ").concat(r,"%)")}},{key:"hsla",get:function(){var e=this.getHsla(),t=e.h,n=e.s,r=e.l,o=e.a;return"hsla(".concat(t,", ").concat(n,"%, ").concat(r,"%, ").concat(o,")")}},{key:"hex",get:function(){return b(this.states).toHexString()}},{key:"hex8",get:function(){return b(this.states).toHex8String()}},{key:"cmyk",get:function(){var e=this.getCmyk(),t=e.c,n=e.m,r=e.y,o=e.k;return"cmyk(".concat(t,", ").concat(n,", ").concat(r,", ").concat(o,")")}},{key:"css",get:function(){return this.isGradient?this.linearGradient:this.rgba}},{key:"linearGradient",get:function(){var e=this.gradientColors,t=this.gradientDegree;return Lh({points:e,degree:t})}},{key:"gradientColors",get:function(){return this.gradientStates.colors},set:function(e){this.gradientStates.colors=e,this.gradientStates.css=this.linearGradient}},{key:"gradientSelectedId",get:function(){return this.gradientStates.selectedId},set:function(e){var t;e!==this.gradientSelectedId&&(this.gradientStates.selectedId=e,this.updateStates(null===(t=this.gradientSelectedPoint)||void 0===t?void 0:t.color))}},{key:"gradientDegree",get:function(){return this.gradientStates.degree},set:function(e){this.gradientStates.degree=Math.max(0,Math.min(360,e)),this.gradientStates.css=this.linearGradient}},{key:"gradientSelectedPoint",get:function(){var e=this.gradientColors,t=this.gradientSelectedId;return e.find((function(e){return e.id===t}))}},{key:"getFormatsColorMap",value:function(){return{HEX:this.hex,CMYK:this.cmyk,RGB:this.rgb,RGBA:this.rgba,HSL:this.hsl,HSLA:this.hsla,HSV:this.hsv,HSVA:this.hsva,CSS:this.css,HEX8:this.hex8}}},{key:"updateCurrentGradientColor",value:function(){var e=this.isGradient,t=this.gradientColors,n=this.gradientSelectedId,r=t.length,o=this.gradientSelectedPoint;if(!e||0===r||!o)return!1;var a=t.findIndex((function(e){return e.id===n})),c=Rh(Rh({},o),{},{color:this.rgba});return t.splice(a,1,c),this.gradientColors=t.slice(),this}},{key:"updateStates",value:function(e){var t=b(Ch(e)).toHsv();this.states=t}},{key:"getRgba",value:function(){var e=Mh(this.states),t=e.r,n=e.g,r=e.b,o=e.a;return{r:Ah(t),g:Ah(n),b:Ah(r),a:o}}},{key:"getCmyk",value:function(){var e=this.getRgba(),t=function(e,t,n){var r=0,o=0,a=0,c=parseInt("".concat(e).replace(/\s/g,""),10),i=parseInt("".concat(t).replace(/\s/g,""),10),l=parseInt("".concat(n).replace(/\s/g,""),10);if(0===c&&0===i&&0===l)return[0,0,0,1];r=1-c/255,o=1-i/255,a=1-l/255;var u=Math.min(r,Math.min(o,a));return[r=(r-u)/(1-u),o=(o-u)/(1-u),a=(a-u)/(1-u),u]}(e.r,e.g,e.b),n=wo(t,4),r=n[0],o=n[1],a=n[2],c=n[3];return{c:Ah(100*r),m:Ah(100*o),y:Ah(100*a),k:Ah(100*c)}}},{key:"getHsva",value:function(){var e,t=(e=this.states,b(e).toHsv()),n=t.h,r=t.s,o=t.v,a=t.a;return{h:n=Ah(n),s:r=Ah(100*r),v:o=Ah(100*o),a:a*=1}}},{key:"getHsla",value:function(){var e,t=(e=this.states,b(e).toHsl()),n=t.h,r=t.s,o=t.l,a=t.a;return{h:n=Ah(n),s:r=Ah(100*r),l:o=Ah(100*o),a:a*=1}}},{key:"equals",value:function(e){return b.equals(this.rgba,e)}}],n=[{key:"isValid",value:function(e){return!!Ih(e)||b(e).isValid()}},{key:"hsva2color",value:function(e,t,n,r){return b({h:e,s:t,v:n,a:r}).toHsvString()}},{key:"hsla2color",value:function(e,t,n,r){return b({h:e,s:t,l:n,a:r}).toHslString()}},{key:"rgba2color",value:function(e,t,n,r){return b({r:e,g:t,b:n,a:r}).toHsvString()}},{key:"hex2color",value:function(e,t){var n=b(e);return n.setAlpha(t),n.toHexString()}},{key:"object2color",value:function(e,t){if("CMYK"===t){var n=e.c,r=e.m,o=e.y,a=e.k;return"cmyk(".concat(n,", ").concat(r,", ").concat(o,", ").concat(a,")")}return b(e,{format:t}).toRgbString()}}],dv(e.prototype,t),dv(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n}();mh=Bh,I(Bh,"isGradientColor",(function(e){return!!Sh(e)})),I(Bh,"compare",(function(e,t){var n=mh.isGradientColor(e),r=mh.isGradientColor(t);return n&&r?Lh(Ih(e))===Lh(Ih(t)):!n&&!r&&b.equals(e,t)}));var Fh=["alpha","css","hex","hex8","hsl","hsla","hsv","hsva","rgb","rgba","saturation","value","isGradient"],Vh=function(e){if(!e)return null;var t=Object.create(null);return Fh.forEach((function(n){return t[n]=e[n]})),e.isGradient&&(t.linearGradient=e.linearGradient),t},Hh={borderless:!1,closeBtn:!0,colorModes:["monochrome","linear-gradient"],enableAlpha:!1,format:"RGB",multiple:!1,defaultRecentColors:[],showPrimaryColorPreview:!0},Wh=["delete","backspace"],Gh=function(t){var o,a,c=t.onChange,i=t.color,l=t.disabled,u=gh(),s=Su().STATUS,f=e.useRef(null),d=e.useRef({left:0,width:176}),p=e.useRef(!1),m=e.useRef(!1),v=e.useRef(t.color.gradientDegree),g=wo(e.useState(t.color.gradientSelectedId),2),b=g[0],h=g[1],y=e.useRef(t.color.gradientSelectedId),O=e.useRef(fv(i.gradientColors)),w=wo(e.useState(O.current),2),E=w[0],j=w[1];e.useEffect((function(){v.current=null==i?void 0:i.gradientDegree,h(i.gradientSelectedId),y.current=i.gradientSelectedId,O.current=fv(i.gradientColors),j(O.current)}),[i.gradientColors,null==i?void 0:i.gradientDegree,i.gradientSelectedId,i.value,i.saturation]);var P=function(){var e=f.current.getBoundingClientRect();d.current={left:e.left,width:e.width||176}},x=e.useCallback((function(e,t,n){l||c({key:e,payload:t,addUsedColor:n})}),[c,l]),C=function(e){t.disabled||e===t.color.gradientDegree||(v.current=e,x("degree",e,!0))},_=function(e){t.disabled||(h(e),y.current=e,x("selectedId",e))},N=e.useCallback((function(e,n){t.disabled||(O.current=e,j(e),x("colors",e,n))}),[t.disabled,x]),k=e.useCallback((function(e){var t=O.current.findIndex((function(e){return e.id===y.current}));if(-1!==t){var n=O.current[t],r=Math.max(0,Math.min(d.current.width,e))/d.current.width*100,o=O.current.map((function(e,o){return t!==o?e:{color:n.color,left:r,id:n.id}}));N(o)}}),[N]),S=e.useCallback((function(e){if(p.current&&!l){var t=f.current.getBoundingClientRect(),n=e.clientX-t.x;m.current=!0,k(n)}}),[l,k]),D=e.useCallback((function(){p.current&&(setTimeout((function(){p.current=!1}),0),m.current&&(N(O.current,!0),m.current=!1))}),[N]);e.useEffect((function(){return P(),window.addEventListener("mousemove",S,!1),window.addEventListener("mouseup",D,!1),window.addEventListener("contextmenu",D,!1),function(){window.removeEventListener("mousemove",S,!1),window.removeEventListener("mouseup",D,!1),window.removeEventListener("contextmenu",D,!1)}}),[]);var I=t.color.gradientColors,T=Lh({points:I,degree:90}),R=To(E),A=zh(0,null===(o=R[0])||void 0===o?void 0:o.color).color,M=zh(100,null===(a=R[R.length-1])||void 0===a?void 0:a.color).color;return n.createElement("div",{className:"".concat(u,"__gradient")},n.createElement("div",{className:"".concat(u,"__gradient-slider"),style:{background:"linear-gradient(90deg, ".concat(A," 0%, ").concat(A," 50%, ").concat(M," 50%, ").concat(M," 100%)")}},n.createElement("div",{className:r("".concat(u,"__slider"),"".concat(u,"--bg-alpha")),onKeyUp:function(e){if(!t.disabled){var n=To(O.current),r=n.findIndex((function(e){return e.id===y.current})),o=n.length;if(Wh.includes(e.key.toLocaleLowerCase())&&o>2&&r>=0&&r<=o-1){n.splice(r,1),n[r]||(r=n[r+1]?r+1:n[r-1]?r-1:0);var a=n[r];N(n,!0),_(null==a?void 0:a.id)}}},tabIndex:0,ref:f},n.createElement("ul",{className:"gradient-thumbs",onClick:function(e){if(!t.disabled){P();var n=e.clientX-d.current.left,r=(n=Math.max(0,Math.min(d.current.width,n)))/d.current.width*100,o=zh(r,t.color.rgba),a=To(O.current);a.push(o),N(a,!0),_(o.id)}},style:{background:T}},E.map((function(e){var o="".concat(Math.round(100*e.left)/100,"%");return n.createElement("li",{className:r(["".concat(u,"__thumb"),"gradient-thumbs__item",b===e.id?s.active:""]),key:e.id,title:"".concat(e.color," ").concat(o),style:{color:e.color,left:o},onClick:function(t){return function(e,t){_(t.id),e.stopPropagation()}(t,e)},onMouseDown:function(n){return function(e,n){p.current||t.disabled||(y.current=e,h(e),m.current=!1,p.current=!0,n.preventDefault(),n.stopPropagation(),f.current.focus())}(e.id,n)}},n.createElement("span",{className:r(["gradient-thumbs__item-inner","".concat(u,"--bg-alpha")])}))}))))),n.createElement("div",{className:"".concat(u,"__gradient-degree"),title:"".concat(v,"deg")},n.createElement(Cs,{theme:"normal",min:0,max:360,step:1,size:"small",format:function(e){return"".concat(e,"°")},value:v.current,onBlur:C,onEnter:C,onChange:C,disabled:t.disabled})))},Uh=n.memo(Gh),Kh=function(t,n){var r=n.start,o=n.end,a=n.drag,c=e.useRef(!1),i=function(e){try{var n,r=null===(n=t.current)||void 0===n?void 0:n.getBoundingClientRect(),o=e.clientX-r.left,a=e.clientY-r.top;return{y:Math.min(Math.max(0,a),r.height),x:Math.min(Math.max(0,o),r.width)}}catch(c){return{y:null,x:null}}},l=function(e){c.current&&a(i(e),e)},u=function(e){c.current=!1,o(i(e),e),document.removeEventListener("mouseup",u),document.removeEventListener("mousemove",l)},s=function(e){c.current=!0,r(i(e),e),document.addEventListener("mouseup",u),document.addEventListener("mousemove",l)};return e.useEffect((function(){var e=t.current;return e&&e.addEventListener("mousedown",s),function(){e&&e.removeEventListener("mousedown",s)}}),[]),{isDragging:c.current}};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Zh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Zh(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zh(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Xh=function(t){var r,o,a,c,i,l,u,s,f=t.color,d=t.disabled,p=t.onChange,m=t.baseClassName,v=e.useRef(null),g=e.useRef(null),b=e.useRef({width:230,height:168}),h=e.useRef(!1),y=e.useCallback((function(e,t){var n=e.x,r=e.y;if(!d){h.current=!0;var o=function(e){var t=b.current,n=t.width,r=t.height,o=e.x,a=e.y;return{saturation:Math.round(o/n*100),value:Math.round(100*(1-a/r))}}({x:n,y:r}),a=o.saturation,c=o.value;p({saturation:a/100,value:c/100,addUsedColor:t})}}),[d,p]),O=e.useCallback((function(e){d||(h.current=!1,y(e,!0))}),[]);return Kh(v,{start:function(){b.current.width=v.current.offsetWidth,b.current.height=v.current.offsetHeight},end:function(e){O(e)},drag:function(e){y(e)}}),e.useEffect((function(){b.current.width=v.current.offsetWidth||230,b.current.height=v.current.offsetHeight||168}),[y,O]),n.createElement("div",{className:"".concat(m,"__saturation"),ref:v,style:{background:"hsl(".concat(f.hue,", 100%, 50%)")}},n.createElement("span",{className:"".concat(m,"__thumb"),role:"slider",tabIndex:0,ref:g,style:$h({},(r=f.saturation,o=f.value,a=f.rgb,c=b.current,i=c.width,l=c.height,u=Math.round((1-o)*l),s=Math.round(r*i),{color:a,left:"".concat(s,"px"),top:"".concat(u,"px")}))}))},qh=n.memo(Xh),Yh=function(t){var o=t.color,a=t.className,c=void 0===a?"":a,i=t.value,l=void 0===i?0:i,u=t.railStyle,s=void 0===u?{}:u,f=t.maxValue,d=void 0===f?360:f,p=t.baseClassName,m=t.disabled,v=t.onChange,g=t.type,b=e.useRef(null),h=e.useRef(null),y=e.useRef(!1),O=e.useRef({width:186}),w=function(t,n){var r=t.color,o=t.value,a=t.maxValue,c=wo(e.useState({left:"",color:""}),2),i=c[0],l=c[1];return e.useEffect((function(){if(n.current.width){var e=Math.round(Number(o)/Number(a)*100);l({left:"".concat(e,"%"),color:r.rgb})}}),[r.rgb,o]),{styles:i}}({color:o,value:l,maxValue:d},O),E=w.styles,j=function(e,t){if(!m){var n=O.current.width,r=e.x,o=Math.round(r/n*Number(d)*100)/100;y.current=!0,v(o,t)}};Kh(b,{start:function(e){O.current.width=b.current.offsetWidth,y.current=!1,j(e)},end:function(e){!function(e){!m&&y.current&&(j(e,!0),y.current=!1)}(e)},drag:function(e){j(e)}}),e.useEffect((function(){O.current.width=b.current.offsetWidth||186}),[]);var P={background:"linear-gradient(90deg, rgba(0,0,0,.0) 0%, rgba(0,0,0,.0) 93%, ".concat(t.color.rgb," 93%, ").concat(t.color.rgb," 100%)")};return n.createElement("div",{className:r("".concat(p,"__slider-wrapper"),"".concat(p,"__slider-wrapper--").concat(g,"-type"))},"alpha"===g&&n.createElement("div",{className:"".concat(p,"__slider-padding"),style:P}),n.createElement("div",{className:r("".concat(p,"__slider"),c),ref:b},n.createElement("div",{className:"".concat(p,"__rail"),style:s}),n.createElement("span",{className:"".concat(p,"__thumb"),role:"slider",tabIndex:0,ref:h,style:E})))},Jh=n.memo(Yh),Qh=function(e){var t=e.color,r=e.baseClassName,o=e.disabled,a=e.onChange;return n.createElement(Jh,{disabled:o,baseClassName:r,className:"".concat(r,"__hue"),color:t,value:t.hue,type:"hue",onChange:a})},ey=n.memo(Qh),ty=["color","baseClassName","onChange"];function ny(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var ry=function(e){var t=e.color,o=e.baseClassName,a=e.onChange,c=T(e,ty),i={background:"linear-gradient(to right, rgba(0, 0, 0, 0), ".concat(e.color.rgb,")")};return n.createElement(Jh,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ny(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ny(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({baseClassName:o,className:r(["".concat(o,"__alpha"),"".concat(o,"--bg-alpha")]),color:t,value:100*t.alpha,onChange:function(e,t){a(e/100,t)},railStyle:i,type:"alpha",maxValue:100},c))},oy=n.memo(ry),ay={RGB:[{key:"r",min:0,max:255,type:"inputNumber"},{key:"g",min:0,max:255,type:"inputNumber"},{key:"b",min:0,max:255,type:"inputNumber"}],HSV:[{key:"h",min:0,max:360,type:"inputNumber"},{key:"s",min:0,max:100,type:"inputNumber"},{key:"v",min:0,max:100,type:"inputNumber"}],HSL:[{key:"h",min:0,max:360,type:"inputNumber"},{key:"s",min:0,max:100,type:"inputNumber"},{key:"l",min:0,max:100,type:"inputNumber"}],CMYK:[{key:"c",min:0,max:255,type:"inputNumber"},{key:"m",min:0,max:255,type:"inputNumber"},{key:"y",min:0,max:255,type:"inputNumber"},{key:"k",min:0,max:255,type:"inputNumber"}],CSS:[{key:"css",type:"input",flex:3}],HEX:[{key:"hex",type:"input",flex:3}]};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function cy(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function iy(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?cy(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cy(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ly=function(t){var r=t.format,o=t.enableAlpha,a=t.inputProps,c=t.disabled,i=t.onInputChange,l=t.color,u=e.useRef({}),s=e.useRef({}),f=function(e){return Bh.object2color(s.current,e)},d=function(e){return"encode"===e?{HSV:l.getHsva(),HSL:l.getHsla(),RGB:l.getRgba(),CMYK:l.getCmyk(),CSS:{css:l.css},HEX:{hex:l.hex}}:{HSV:f("HSV"),HSL:f("HSL"),RGB:f("RGB"),CMYK:f("CMYK"),CSS:s.current.css,HEX:s.current.hex}},p=function(){var e=d("encode")[r];e.a=Math.round(100*l.alpha);var t={};Object.keys(e).forEach((function(n){e[n]!==s.current[n]&&(t[n]=e[n]),u.current[n]=e[n]})),Object.keys(t).length>0&&(s.current=e)};p();var m,v=Vf(p,100),g=function(e,t){if(t!==u.current[e]){var n=iy(iy({},s.current),{},I({},e,t));s.current=n,u.current[e]=t;var o=d("decode")[r];i(o,s.current.a/100,e,t)}};return e.useEffect((function(){v()}),[l.saturation,l.hue,l.value,l.alpha,r]),n.createElement("div",{className:"input-group"},(m=To(ay[r]),o&&m.push({type:"inputNumber",key:"a",min:0,max:100,format:function(e){return"".concat(e,"%")},flex:1.15}),m).map((function(e){var t=iy(iy({},a),{},I(I(I(I(I(I(I({title:s.current[e.key]},"input"===e.type?"defaultValue":"value",s.current[e.key]),"align","center"),"disabled",c),"size","small"),"onChange","input"===e.type?Function.prototype:function(t){return g(e.key,t||e.min)}),"onBlur",(function(t){return g(e.key,t)})),"onEnter",(function(t){return g(e.key,t)})));return n.createElement("div",{className:"input-group__item",key:e.key,style:{flex:e.flex||1}},"input"===e.type?n.createElement(Cl,iy(iy({},t),{},{key:t.defaultValue,maxlength:"HEX"===r?9:void 0})):n.createElement(Cs,iy(iy({},t),{},{min:e.min,max:e.max,step:1,format:e.format,theme:"normal"})))})))},uy=n.memo(ly),sy=wu((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}));function fy(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function dy(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?fy(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fy(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var py=function(t){var r=t.baseClassName,o=t.format,a=t.onModeChange,c=t.selectInputProps,i=wo(e.useState(o),2),l=i[0],u=i[1];return n.createElement("div",{className:"".concat(r,"__format")},n.createElement("div",{className:"".concat(r,"__format--item")},n.createElement(Vm,{size:"small",className:"".concat(r,"__format-mode-select"),popupProps:dy({overlayClassName:"".concat(r,"__select-options")},null==c?void 0:c.popupProps),autoWidth:!0,value:l,onChange:function(e){u(e),a(e)}},wh.map((function(e){return n.createElement(Vm.Option,{key:e,value:e,label:sy(e),style:{fontSize:"12px"}})})))),n.createElement("div",{className:"".concat(r,"__format--item")},n.createElement(uy,dy(dy({},t),{},{format:l}))))},my=n.memo(py),vy=function(e){var t=e.baseClassName,o=e.colors,a=void 0===o?[]:o,c=e.editable,i=void 0!==c&&c,l=e.title,u=e.onChange,s=e.disabled,f=e.onSetColor,d=e.handleAddColor,p=pl({DeleteIcon:k,AddIcon:v}),m=p.DeleteIcon,g=p.AddIcon,b="".concat(t,"__swatches"),h=Su().STATUS,y=function(t){return Bh.compare(t,e.color.css)},O=function(){var e=a.findIndex((function(e){return y(e)}));if(e>-1){var t=a.filter((function(t,n){return n!==e}));u(t)}};return n.createElement("div",{className:b},l?n.createElement("h3",{className:"".concat(b,"--title")},n.createElement("span",null,l),i&&n.createElement("div",{className:"".concat(b,"--actions")},n.createElement("span",{role:"button",className:"".concat(t,"__icon"),onClick:function(){return d()}},n.createElement(g,null)),a.length>0?n.createElement("span",{role:"button",className:"".concat(t,"__icon"),onClick:function(){return O()}},n.createElement(m,null)):null)):n.createElement(n.Fragment,null),n.createElement("ul",{className:r("".concat(b,"--items"),"narrow-scrollbar")},a.map((function(e){return n.createElement("li",{className:r("".concat(b,"--item"),y(e)&&i?h.active:""),key:e,onClick:function(){s||function(e){f(e)}(e)}},n.createElement("div",{className:r("".concat(b,"--item__color"),"".concat(t,"--bg-alpha"))},n.createElement("span",{className:"".concat(b,"--item__inner"),style:{background:e}})))}))))},gy=n.memo(vy);
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function by(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function hy(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?by(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):by(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var yy=Math.round,Oy=e.forwardRef((function(t,o){var a=gh(),c=Su().STATUS,i=wo(yl("colorPicker"),2),l=i[0],u=i[1],s=t.value,f=t.disabled,d=t.onChange,p=t.enableAlpha,m=void 0!==p&&p,v=t.format,g=t.onPaletteBarChange,h=t.swatchColors,y=t.className,O=t.style,w=void 0===O?{}:O,E=t.togglePopup,j=t.closeBtn,P=t.colorModes,x=void 0===P?["linear-gradient","monochrome"]:P,C=t.showPrimaryColorPreview,_=void 0===C||C,N=t.onRecentColorsChange,k=wo(fc(t,"value",d),2),S=k[0],D=k[1],I=wo(e.useState((function(){return 1===(null==x?void 0:x.length)?x[0]:"monochrome"})),2),T=I[0],R=I[1],A=wo(e.useState(0),2),M=A[0],L=A[1],z="linear-gradient"===T,B=z?yh:hh,F=wo(fc(t,"recentColors",N,{defaultRecentColors:Hh.recentColors}),2),V=F[0],H=F[1],W=e.useRef(new Bh(S||B)),G=W.current.isGradient?"linear-gradient":"monochrome",U=e.useRef(W.current.isGradient?"CSS":null!=v?v:"RGB"),K=e.useCallback((function(e){W.current.update(e),L(M+1)}),[M]),Z=e.useCallback((function(){if("linear-gradient"===T)return W.current.linearGradient;var e="HEX"===v&&m?"HEX8":v;return W.current.getFormatsColorMap()[e]||W.current.css}),[v,m,T]),$=e.useCallback((function(e){D(Z(),{color:Vh(W.current),trigger:e||"palette-saturation-brightness"})}),[Z,D]);e.useEffect((function(){if(void 0!==s&&"linear-gradient"!==T){var e=b(s).toRgb(),t=e.r,n=e.g,r=e.b,o=e.a,a="rgba(".concat(yy(t),", ").concat(yy(n),", ").concat(yy(r),", ").concat(o,")"),c=new Bh(s),i=a||hh,l=W.current.rgba,u="monochrome"===T&&!c.isGradient;i!==l&&u&&(K(s),R(c.isGradient?"linear-gradient":"monochrome"))}}),[s,Z,D,T,K]),e.useEffect((function(){1===x.length?R(x[0]):R(G)}),[x,G]);var X={color:W.current,disabled:f,baseClassName:a},q=function(e){H(e)},Y=function(){var e=To(V||[]),t=W.current,n=t.isGradient,r=t.linearGradient,o=t.rgba,a=n?r:o,c=e.indexOf(a);c>-1&&e.splice(c,1),e.unshift(a),e.length>100&&(e.length=100),q(e)},J=e.useCallback((function(e){return U.current=e}),[]),Q=e.useCallback((function(e,t){K(e),W.current.alpha=t,$("input")}),[$,K]),ee=n.memo((function(){var e,t=null!==V&&!1!==V,r=h;void 0===r&&(r=To(Oh));var o=(null===(e=r)||void 0===e?void 0:e.length)>0;if(!o&&!t)return null;var c=function(e,t){var n=Bh.isGradientColor(e),r=W.current;n?x.includes("linear-gradient")?(R("linear-gradient"),r.update(e),r.updateCurrentGradientColor()):console.warn("linear-gradient is not supported in this mode"):"linear-gradient"===T?(R("monochrome"),r.update(e)):r.update(e),$(t)};return n.createElement(n.Fragment,null,n.createElement("div",{className:"".concat(a,"__swatches-wrap")},t&&n.createElement(gy,hy(hy({},X),{},{title:u(l.recentColorTitle),editable:!0,handleAddColor:Y,colors:V,onSetColor:function(e){return c(e,"recent")},onChange:q})),o&&n.createElement(gy,hy(hy({},X),{},{title:u(l.swatchColorTitle),colors:r,onSetColor:function(e){return c(e,"preset")}}))))}));return n.createElement("div",{className:r("".concat(a,"__panel"),!!f&&c.disabled,y),onClick:function(e){return e.stopPropagation()},style:hy({},w),ref:o},n.createElement(jh,{baseClassName:a,mode:T,colorModes:x,closeBtn:j,togglePopup:E,onModeChange:function(e){R(e);var t=W.current,n=t.rgba,r=t.gradientColors,o=t.linearGradient;W.current=new Bh("linear-gradient"!==e?n:r.length>0?o:yh)}}),n.createElement("div",{className:"".concat(a,"__body")},z&&n.createElement(Uh,hy(hy({},X),{},{onChange:function(e){var t=e.key,n=e.payload,r="palette-saturation-brightness";switch(t){case"degree":W.current.gradientDegree=n,r="input";break;case"selectedId":W.current.gradientSelectedId=n,L((function(e){return e+1}));break;case"colors":W.current.gradientColors=n}$(r)}})),n.createElement(qh,hy(hy({},X),{},{onChange:function(e){var t=e.saturation,n=e.value,r=W.current,o=r.saturation,a=r.value,c="palette-saturation-brightness";if(n!==a&&t!==o)c="palette-saturation-brightness",W.current.saturation=t,W.current.value=n;else if(t!==o)c="palette-saturation",W.current.saturation=t;else{if(n===a)return;c="palette-brightness",W.current.value=n}$(c)}})),n.createElement("div",{className:"".concat(a,"__sliders-wrapper")},n.createElement("div",{className:"".concat(a,"__sliders")},n.createElement(ey,hy(hy({},X),{},{onChange:function(e){W.current.hue=e,$("palette-hue-bar"),null==g||g({color:Vh(W.current)})}})),m&&n.createElement(oy,hy(hy({},X),{},{onChange:function(e){W.current.alpha=e,$("palette-alpha-bar"),null==g||g({color:Vh(W.current)})}}))),_?n.createElement("div",{className:r(["".concat(a,"__sliders-preview"),"".concat(a,"--bg-alpha")])},n.createElement("span",{className:"".concat(a,"__sliders-preview-inner"),style:{background:z?W.current.linearGradient:W.current.rgba}})):null),n.createElement(my,hy(hy(hy({},t),X),{},{format:U.current,onModeChange:J,onInputChange:Q})),n.createElement(ee,null)))})),wy=n.memo(Oy);
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Ey(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function jy(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ey(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ey(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Py=function(e){var t=gh(),o=e.disabled,a=void 0!==o&&o,c=e.borderless,i=void 0!==c&&c,l=e.inputProps,u=void 0===l?{autoWidth:!0}:l,s=wo(fc(e,"value",e.onChange),2),f=s[0],d=s[1];return n.createElement("div",{className:"".concat(t,"__trigger--default")},n.createElement(Cl,jy(jy({borderless:i},u),{},{value:f,disabled:a,label:n.createElement("div",{className:r("".concat(t,"__trigger--default__color"),"".concat(t,"--bg-alpha"))},n.createElement("span",{className:"color-inner",style:{background:f}})),onBlur:function(e,t){Bh.isValid(e)&&d(e,t)},onChange:function(e){return d(e)}})))},xy=n.memo(Py),Cy=["popupProps","disabled","borderless","inputProps","onChange","colorModes"],_y=["overlayClassName","overlayInnerStyle"];function Ny(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ky(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ny(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ny(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Sy=function(t){var r=gh(),o=ho(t,Hh),a=o.popupProps,c=o.disabled,i=o.borderless,l=o.inputProps,u=o.onChange,s=o.colorModes,f=T(o,Cy),d=a||{},p=d.overlayClassName,m=d.overlayInnerStyle,v=void 0===m?{}:m,g=T(d,_y),b=wo(fc(t,"value",u),2),h=b[0],y=b[1],O=e.useRef(),w=e.useRef(),E=ky(ky({placement:"bottom-left",expandAnimation:!0,trigger:"click"},g),{},{overlayClassName:[r,p],overlayInnerStyle:ky({padding:0},v)});return n.createElement(Yi,ky(ky({},E),{},{content:!c&&n.createElement(wy,ky(ky({},f),{},{disabled:c,value:h,colorModes:s,onChange:function(e,t){return y(e,t)},ref:w}))}),n.createElement("div",{className:"".concat(r,"__trigger"),ref:O},n.createElement(xy,{disabled:c,borderless:i,inputProps:l,value:h,onChange:y})))};Sy.displayName="ColorPicker";var Dy=n.memo(Sy),Iy=n.createContext({defaultExpandAll:!1,disabled:!1,expandIconPlacement:"left",expandOnRowClick:!0,expandIcon:!0}),Ty={borderless:!1,defaultExpandAll:!1,expandIcon:!0,expandIconPlacement:"left",expandMutex:!1,expandOnRowClick:!0},Ry={destroyOnCollapse:!1,disabled:void 0,expandIcon:void 0};
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
function Ay(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function My(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ay(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ay(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ly=function(t){var o=ho(t,Ry),a=o.value,c=o.disabled,l=o.destroyOnCollapse,u=o.expandIcon,s=o.className,f=o.style,d=o.header,p=o.headerRightContent,m=o.children,v=o.index,g=n.useContext(Iy),b=g.disabled,h=g.defaultExpandAll,y=g.expandIconPlacement,O=g.expandOnRowClick,w=g.expandIcon,E=g.updateCollapseValue,j=g.collapseValue,P=bo().classPrefix,x="".concat(P,"-collapse-panel"),C=a||v,_=(void 0===u?w:u)||null,N=e.useRef(),k=e.useRef(),S=e.useRef(),D=e.useRef(),T=c||!!b;e.useEffect((function(){h&&E(C)}),[]);var R,A,M=Array.isArray(j)?j.includes(C):j===C,L=r(x,I({},"".concat(P,"-is-disabled"),T),s),z=function(e){(O&&e.currentTarget===N.current||e.currentTarget===k.current)&&!T&&E(C,{e:e}),e.stopPropagation()},B=function(){var e=null;return n.isValidElement(_)?e=_:_&&(e=n.createElement(Bp,{className:r("".concat(x,"__icon--default"))})),e&&n.createElement("div",{className:"".concat(x,"__icon ").concat(x,"__icon--").concat(y," ").concat(M?"".concat(x,"__icon--active"):""),ref:k,onClick:z},e)};return n.createElement("div",{className:L,style:My({},f)},n.createElement("div",{className:"".concat(x,"__wrapper")},(A=["".concat(x,"__header"),I({},"".concat(P,"-is-clickable"),O&&!T)],n.createElement("div",{ref:N,className:r(A),onClick:z},"left"===y&&B(),d,n.createElement("div",{className:"".concat(x,"__header--blank")}),p,"right"===y&&B())),(R={onEnter:function(){D.current.style.height="".concat(null==S?void 0:S.current.clientHeight,"px")},onEntered:function(){D.current.style.height="auto"},onExit:function(){D.current.style.height="".concat(null==S?void 0:S.current.clientHeight,"px")},onExiting:function(){D.current.style.height="0px"}},n.createElement(i,My({in:M,appear:!0,timeout:300,nodeRef:D,unmountOnExit:l},R),n.createElement("div",{style:{height:0},className:r("".concat(x,"__body"),"".concat(P,"-slide-down-enter-active"),I({},"".concat(x,"__body--collapsed"),!M)),ref:D},n.createElement("div",{className:"".concat(x,"__content"),ref:S},m))))))};Ly.displayName="CollapsePanel";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var zy=["defaultExpandAll","disabled","expandIconPlacement","expandOnRowClick","expandIcon"];function By(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var Fy=dl((function(t,o){var a=ho(t,Ty),c=bo().classPrefix,i="".concat(c,"-collapse"),l="".concat(c,"--border-less"),u=a.defaultExpandAll,s=a.disabled,f=a.expandIconPlacement,d=a.expandOnRowClick,p=a.expandIcon,m=T(a,zy),v=m.children,g=m.className,b=m.style,h=m.expandMutex,y=m.borderless,O=m.onChange,w=wo(fc(a,"value",O),2),E=w[0],j=w[1],P=e.useRef(E);e.useEffect((function(){P.current=E}),[E]);var x=[i,I({},l,!!y),g],C=n.Children.toArray(v).filter((function(e){return e.type.displayName===Ly.displayName}));return n.createElement(Iy.Provider,{value:{defaultExpandAll:u,disabled:s,expandIconPlacement:f,expandOnRowClick:d,expandIcon:p,updateCollapseValue:function(e,t){var n=[].concat(P.current||[]),r=n.indexOf(e);r>=0?n.splice(r,1):h?n=[e]:n.push(e),P.current=To(n),j(n,t)},collapseValue:E}},n.createElement("div",{className:r(x),style:b,ref:o},C.map((function(e,t){var r=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?By(Object(n),!0).forEach((function(t){I(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):By(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({key:e.key||String(t),index:t+1},e.props);return n.cloneElement(e,r)}))))}),{Panel:Ly});Fy.displayName="Collapse";
/**
 * tdesign v1.10.4
 * (c) 2024 tdesign
 * @license MIT
 */
var Vy=Fy;export{sl as B,Dy as C,Sg as D,Cl as I,ia as L,kg as M,qv as N,Yi as P,Wu as R,Vm as S,Tv as T,Xg as a,Dg as b,Sb as c,db as d,Lg as e,bv as f,zb as g,vh as h,Wg as i,Qb as j,Uf as k,Dl as l,Vy as m,Ju as n,um as o};
