diff --git a/luci-app-nekobox/htdocs/nekobox/ping.php b/luci-app-nekobox/htdocs/nekobox/ping.php index ff6f27c0f..8456ab7a2 100644 --- a/luci-app-nekobox/htdocs/nekobox/ping.php +++ b/luci-app-nekobox/htdocs/nekobox/ping.php @@ -724,6 +724,11 @@ let IP = { let timezone = data.timezone || ""; let asn = data.asn || ""; + let areaDisplay = [country, region, city].filter(Boolean).join(" "); + if (region === city) { + areaDisplay = `${country} ${region}`; + } + let ipSupport; const ipv4Regex = /^(\d{1,3}\.){3}\d{1,3}$/; const ipv6Regex = /^[a-fA-F0-9:]+$/; @@ -766,7 +771,7 @@ let IP = {
(X(),ae("div",WK,[$(Ql)?(X(),_t(VX,{key:0})):(X(),_t($K,{key:1})),N("dialog",{ref_key:"modalRef",ref:n,class:"modal"},[N("div",YK,[Se($(GK),{data:$(t)},null,8,["data"])]),i[0]||(i[0]=N("form",{method:"dialog",class:"modal-backdrop"},[N("button",null,"close")],-1))],512)]))}}),qK={class:"relative w-full flex-1"},Mx=lt({__name:"TextInput",props:{label:{type:String,required:!1},modelValue:{type:String,required:!0}},emits:["update:modelValue"],setup(e,{emit:t}){const r=Ie(e.modelValue),i=t;kt(r,a=>{i("update:modelValue",a)});const o=()=>{r.value=""};return(a,s)=>(X(),ae("div",qK,[At(N("input",{"onUpdate:modelValue":s[0]||(s[0]=l=>r.value=l),type:"text",class:"input input-sm join-item input-bordered w-full"},null,512),[[Kr,r.value]]),Se($(p0),{class:"absolute right-2 top-1/2 h-3 w-3 -translate-y-1/2 cursor-pointer",onClick:o})]))}}),XK=["value","label"],KK=["value","label"],xM=lt({__name:"SourceIPFilter",props:{horizontal:{type:Boolean}},setup(e){const t=Le(()=>kq.value.map(n=>({label:pm(n),value:n})));return(n,r)=>n.horizontal?mt("",!0):At((X(),ae("select",{key:0,class:"join-item select select-bordered select-sm","onUpdate:modelValue":r[0]||(r[0]=i=>Ze(Ca)?Ca.value=i:null)},[r[1]||(r[1]=N("option",{value:"",label:"all"},null,-1)),t.value.every(i=>i.value!==$(Ca))&&$(Ca)!==""?(X(),ae("option",{key:0,value:$(Ca),label:$(pm)($(Ca))},null,8,XK)):mt("",!0),(X(!0),ae(Ye,null,Gt(t.value,i=>(X(),ae("option",{key:i.value,value:i.value,label:i.label},null,8,KK))),128))],512)),[[wo,$(Ca)]])}}),ZK={class:"tabs-boxed tabs tabs-sm"},QK={class:"shrink-0"},JK=["value"],eZ={class:"shrink-0"},tZ=["data-tip"],nZ={class:"join w-full flex-1"},rZ=lt({__name:"ConnectionCtrl",props:{horizontal:{type:Boolean}},setup(e){const t=()=>{Ac.value.forEach(n=>{E0(n.id)})};return(n,r)=>(X(),ae("div",{class:ot($(hn)("flex flex-col gap-2 p-2 text-sm",n.horizontal&&"flex-row flex-wrap pb-0"))},[N("div",ZK,[N("a",{role:"tab",class:ot($(hn)("tab",$(zl)===$(Aa).ACTIVE&&"tab-active")),onClick:r[0]||(r[0]=()=>zl.value=$(Aa).ACTIVE)},[ut(de(n.$t("activeConnections"))+" ",1),$(zl)===$(Aa).ACTIVE?(X(),ae(Ye,{key:0},[ut(" ("+de($(Ac).length)+") ",1)],64)):mt("",!0)],2),N("a",{role:"tab",class:ot($(hn)("tab",$(zl)===$(Aa).CLOSED&&"tab-active")),onClick:r[1]||(r[1]=()=>zl.value=$(Aa).CLOSED)},[ut(de(n.$t("closedConnections"))+" ",1),$(zl)===$(Aa).CLOSED?(X(),ae(Ye,{key:0},[ut(" ("+de($(Ac).length)+") ",1)],64)):mt("",!0)],2)]),$(Ql)?(X(),ae("div",{key:0,class:ot($(hn)("flex w-full items-center gap-2",n.horizontal&&"sm:w-auto"))},[N("span",QK,de(n.$t("sortBy"))+":",1),At(N("select",{class:"select select-bordered select-sm w-full","onUpdate:modelValue":r[2]||(r[2]=i=>Ze(Mg)?Mg.value=i:null)},[(X(!0),ae(Ye,null,Gt(Object.values($(jr)),i=>(X(),ae("option",{key:i,value:i},de(n.$t(i)||i),9,JK))),128))],512),[[wo,$(Mg)]])],2)):mt("",!0),N("div",{class:ot($(hn)("flex w-full items-center gap-2",n.horizontal&&"sm:w-auto"))},[N("span",eZ,de(n.$t("quickFilter"))+": ",1),At(N("input",{type:"text",class:"input input-sm join-item input-bordered w-full","onUpdate:modelValue":r[3]||(r[3]=i=>Ze(Hh)?Hh.value=i:null)},null,512),[[Kr,$(Hh)]]),At(N("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":r[4]||(r[4]=i=>Ze(Ag)?Ag.value=i:null)},null,512),[[mi,$(Ag)]]),N("div",{class:ot(`tooltip ${n.horizontal?"tooltip-left sm:tooltip-bottom":"tooltip-left"}`),"data-tip":n.$t("quickFilterTip")},[Se($(oO),{class:"h-4 w-4"})],10,tZ)],2),n.horizontal?mt("",!0):(X(),_t(xM,{key:1})),N("div",nZ,[n.horizontal?(X(),_t(xM,{key:0})):mt("",!0),Se(Mx,{modelValue:$(Uh),"onUpdate:modelValue":r[5]||(r[5]=i=>Ze(Uh)?Uh.value=i:null),class:"join-item"},null,8,["modelValue"]),N("button",{class:"btn-bordered btn join-item btn-sm",onClick:r[6]||(r[6]=i=>Rg.value=!$(Rg))},[(X(),_t(Ua($(Rg)?$(rO):$(nO)),{class:"h-4 w-4"}))]),N("button",{class:"btn-bordered btn join-item btn-sm",onClick:t},[Se($(p0),{class:"h-4 w-4"})])])],2))}}),Rx=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},Ik=Rx(rZ,[["__scopeId","data-v-46c5b7bb"]]),ym=Ie([]),Dc=Ie(""),Ig=Ie(!1),Pg=Qt("config/log-level",Zl.Info);let gv,_m=[];const iZ=ea.throttle(()=>{ym.value=_m.concat(ym.value).slice(0,wg.value),_m=[]},500),wb=[],oZ=()=>{wb.length=0;for(const e in yi.value){if(e.startsWith("/"))continue;const t=new RegExp(e+":","ig");wb.push([t,`${e} (${yi.value[e]}) :`])}};kt(yi,()=>{oZ()},{immediate:!0});const bb=()=>{gv==null||gv(),ym.value=[],_m=[];let e=1;const t=Rq({level:Pg.value}),n=kt(t.data,r=>{if(r){if(Ig.value){e++;return}for(const[i,o]of wb)r.payload=r.payload.replace(i,o);_m.unshift({...r,time:new Date().valueOf(),seq:e++}),iZ()}});gv=()=>{n(),t.close()}},aZ=["value"],Pk=lt({__name:"LogsCtrl",props:{horizontal:{type:Boolean}},setup(e){return(t,n)=>(X(),ae("div",{class:ot($(hn)("join w-full p-2",t.horizontal&&"max-w-96 pb-0"))},[At(N("select",{class:"join-item select select-bordered select-sm","onUpdate:modelValue":n[0]||(n[0]=r=>Ze(Pg)?Pg.value=r:null),onChange:n[1]||(n[1]=(...r)=>$(bb)&&$(bb)(...r))},[(X(!0),ae(Ye,null,Gt(Object.values($(Zl)),r=>(X(),ae("option",{key:r,value:r},de(r),9,aZ))),128))],544),[[wo,$(Pg)]]),Se(Mx,{type:"text",modelValue:$(Dc),"onUpdate:modelValue":n[2]||(n[2]=r=>Ze(Dc)?Dc.value=r:null)},null,8,["modelValue"]),N("button",{class:"btn-bordered btn join-item btn-sm",onClick:n[3]||(n[3]=r=>Ig.value=!$(Ig))},[(X(),_t(Ua($(Ig)?$(rO):$(nO)),{class:"h-4 w-4"}))])],2))}}),Go=Ie(),Lk=async()=>{Go.value=(await Sq()).data},Ok=async e=>{await xq(e),Lk()},kk=Ie(pu.PROXIES),Nk=Le(()=>{var e;return kk.value===pu.PROVIDER?Mc.value.map(t=>t.name):Ia.value&&vg.value&&Wa.value[ql]?[...cb.value,ql]:!Ia.value&&((e=Go.value)==null?void 0:e.mode.toLocaleUpperCase())===ql&&Wa.value[ql]?[ql]:cb.value}),sZ=Le(()=>kh.value&&Nk.value.length>1),D0=()=>({proxiesTabShow:kk,renderGroups:Nk,hasTwoColumns:sZ}),lZ={key:0,role:"tablist",class:"tabs-boxed tabs tabs-sm"},uZ=["onClick"],cZ={key:1,class:"flex flex-col gap-2"},fZ=["value"],hZ=["label","value"],dZ=["label","value"],pZ={class:"shrink-0"},Fk=lt({__name:"ProxiesCtrl",props:{horizontal:{type:Boolean}},setup(e){const{proxiesTabShow:t}=D0(),n=Ie(!1),r=async()=>{if(!n.value){n.value=!0;try{await Promise.all(Mc.value.map(a=>ek(a.name))),await jc(),n.value=!1}catch{await jc(),n.value=!1}}},i=Le(()=>{var a,s;return((a=Go.value)==null?void 0:a["mode-list"])||((s=Go.value)==null?void 0:s.modes)||["direct","rule","global"]}),o=a=>{const s=a.target.value;Ok({mode:s})};return(a,s)=>$(Go)?(X(),ae("div",{key:0,class:ot($(hn)("flex flex-col gap-1 p-2 text-sm sm:gap-2",a.horizontal&&"flex-row flex-wrap pb-0"))},[$(Mc).length?(X(),ae(Ye,{key:0},[$(Mc).length?(X(),ae("div",lZ,[(X(!0),ae(Ye,null,Gt($(pu),l=>(X(),ae("a",{role:"tab",class:ot(["tab",{"tab-active":$(t)===l}]),key:l,onClick:u=>t.value=l},de(a.$t(l)),11,uZ))),128))])):mt("",!0),$(t)===$(pu).PROVIDER?(X(),ae("div",cZ,[N("button",{class:ot($(hn)("btn btn-sm",n.value?"animate-pulse":"")),onClick:r},de(a.$t("updateAllProviders")),3)])):mt("",!0)],64)):mt("",!0),s[2]||(s[2]=N("div",{class:"w-full sm:hidden"},null,-1)),N("div",{class:ot($(hn)("flex w-full items-center gap-2",a.horizontal&&"w-24"))},[N("select",{class:"select select-bordered select-sm w-1/2 flex-1",value:$(Go).mode,onChange:o},[(X(!0),ae(Ye,null,Gt(i.value,l=>(X(),ae("option",{key:l,label:a.$t(l.toLowerCase())||l,value:l},null,8,hZ))),128))],40,fZ)],2),N("div",{class:ot($(hn)("flex w-full items-center gap-2",a.horizontal&&"w-72 max-sm:flex-1"))},[At(N("select",{class:"select select-bordered select-sm w-1/2 flex-1","onUpdate:modelValue":s[0]||(s[0]=l=>Ze(gg)?gg.value=l:null)},[(X(!0),ae(Ye,null,Gt(Object.values($(Is)),l=>(X(),ae("option",{key:l,label:a.$t(l),value:l},null,8,dZ))),128))],512),[[wo,$(gg)]]),N("span",pZ,de(a.$t("hideUnavailable"))+": ",1),At(N("input",{class:"toggle",type:"checkbox","onUpdate:modelValue":s[1]||(s[1]=l=>Ze(yg)?yg.value=l:null)},null,512),[[mi,$(yg)]])],2)],2)):mt("",!0)}}),Gh=Ie(zc.RULES),$k=Ie([]),wm=Ie([]),bm=async()=>{const{data:e}=await wq(),{data:t}=await bq();$k.value=e.rules,wm.value=Object.values(t.providers)},vZ={role:"tablist",class:"tabs-boxed tabs tabs-sm"},gZ=["onClick"],mZ={key:0,class:"flex flex-col gap-2"},Bk=lt({__name:"RulesCtrl",props:{horizontal:{type:Boolean}},setup(e){const t=Ie(!1),n=async()=>{if(!t.value){t.value=!0;try{await Promise.all(wm.value.map(r=>tk(r.name))),await bm(),t.value=!1}catch{await bm(),t.value=!1}}};return(r,i)=>$(wm).length?(X(),ae("div",{key:0,class:ot($(hn)("flex flex-col gap-2 p-2",r.horizontal&&"flex-row pb-0"))},[N("div",vZ,[(X(!0),ae(Ye,null,Gt($(zc),o=>(X(),ae("a",{role:"tab",class:ot(["tab",{"tab-active":$(Gh)===o}]),key:o,onClick:a=>Gh.value=o},de(r.$t(o)),11,gZ))),128))]),$(Gh)===$(zc).PROVIDER?(X(),ae("div",mZ,[N("button",{class:ot($(hn)("btn btn-sm",t.value?"animate-pulse":"")),onClick:n},de(r.$t("updateAllProviders")),3)])):mt("",!0)],2)):mt("",!0)}}),yZ="data:image/jpeg;base64,/9j/2wCEAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDIBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIADAAMAMBIgACEQEDEQH/xAGiAAABBQEBAQEBAQAAAAAAAAAAAQIDBAUGBwgJCgsQAAIBAwMCBAMFBQQEAAABfQECAwAEEQUSITFBBhNRYQcicRQygZGhCCNCscEVUtHwJDNicoIJChYXGBkaJSYnKCkqNDU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6g4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2drh4uPk5ebn6Onq8fLz9PX29/j5+gEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoLEQACAQIEBAMEBwUEBAABAncAAQIDEQQFITEGEkFRB2FxEyIygQgUQpGhscEJIzNS8BVictEKFiQ04SXxFxgZGiYnKCkqNTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqCg4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2dri4+Tl5ufo6ery8/T19vf4+fr/2gAMAwEAAhEDEQA/APXaKKx/EfirRfCdmLjWL1YiwzFAnzTS/wC6vp7nA96ZJsgEkAAknsKCCCQQQR2NfPHiT4wax4jvI7DTFbStMkkCMsb/AL6VScfM46A+i4/Gl8N/GDWPDl5JYamrarpkchRFkf8AfRKDgbXPUD0bP1FIdj6ForH8O+KtE8V2ZudHvVlKjMkD/LNF/vL6e4yPetimIK8D+KniNrf4iajpupWcWpaWscGyCU7XhzChJikHKHPOOVJ6g175Xzl8W7E3PxP1aWSeK3t0jtg0kh7+QnCqOWP0H1wOaQ0YVt4ct9QuYrzw3dtepG6vJYyqFu4lByTtHEgHqmT6qKLnw5b6fcy3niS7aySR2eOxhAa7lUnIJU8RA+r8+imqui3trBr2mwafBjN3EGuZwDI3zj7o6IPpk/7WOKNavbafXdSg1CD7t3KFuYFAkX5z94cBx9cH/axxQM7T4a+I2uPGsGnabZxaZphtrktBEdzykQuQZZD8znPOOFB6AV78hzGpPoK+b/hdYm28f2ksc8Vxbva3QWSNu/kPwynlT9R9MjmvpCP/AFa/QUCY6ue8UeDNF8WwbdUtA0wXEdzFhJo/TDY5Hs2R9K6GimI+edQ+FGt+GvENhd2gOpacl3EWlhQiSJd45dOSB7jI9xUVr8L9X13X768vydM0+S7lKPKhaWYbz/q4+p+pwPevoojPqCOhBwR9DUUVtFE7SKpMjfed2LMfxPNIdzmfDXgjS/D1qYrC0FtvXbLO5D3Ew7hn6KD/AHVwK6wDAAHQUUUxH//Z",_Z="data:image/svg+xml,%3csvg%20width='1027'%20height='1109'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xml:space='preserve'%20overflow='hidden'%3e%3cdefs%3e%3cfilter%20id='fx0'%20x='-10%25'%20y='-10%25'%20width='120%25'%20height='120%25'%20filterUnits='userSpaceOnUse'%20primitiveUnits='userSpaceOnUse'%3e%3cfeComponentTransfer%20color-interpolation-filters='sRGB'%3e%3cfeFuncR%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncG%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncB%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncA%20type='linear'%20slope='0.4'%20intercept='0'%20/%3e%3c/feComponentTransfer%3e%3cfeGaussianBlur%20stdDeviation='4.58333%204.58333'%20/%3e%3c/filter%3e%3cclipPath%20id='clip1'%3e%3crect%20x='692'%20y='855'%20width='1027'%20height='1109'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clip2'%3e%3crect%20x='-2'%20y='-2'%20width='541'%20height='786'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clip3'%3e%3crect%20x='0'%20y='0'%20width='535'%20height='782'%20/%3e%3c/clipPath%3e%3c/defs%3e%3cg%20clip-path='url(%23clip1)'%20transform='translate(-692%20-855)'%3e%3cpath%20d='M692%201191%20692%201575.69C692%201640.41%20731.499%201651.19%20731.499%201651.19L1148.03%201931.62C1212.66%201974.77%201194.71%201881.29%201194.71%201881.29L1194.71%201528.96%20692%201191Z'%20fill='%2337474F'%20fill-rule='evenodd'%20/%3e%3cg%20clip-path='url(%23clip2)'%20filter='url(%23fx0)'%20transform='translate(1184%201182)'%3e%3cg%20clip-path='url(%23clip3)'%3e%3cpath%20d='M520.482%2015.4819%20520.482%20400.176C520.482%20464.89%20480.983%20475.676%20480.983%20475.676%20480.983%20475.676%20129.086%20712.963%2064.4523%20756.106-0.181814%20799.25%2017.7721%20705.773%2017.7721%20705.773L17.7721%20353.437%20520.482%2015.4819Z'%20fill='%23455A64'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3cpath%20d='M1698%201191%201698%201575.69C1698%201640.41%201658.5%201651.19%201658.5%201651.19%201658.5%201651.19%201306.6%201888.48%201241.97%201931.62%201177.34%201974.77%201195.29%201881.29%201195.29%201881.29L1195.29%201528.96%201698%201191Z'%20fill='%23455A64'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1241.71%20868.473C1212.96%20850.509%201169.85%20850.509%201144.7%20868.473L713.557%201163.07C684.814%201181.04%20684.814%201213.37%20713.557%201231.33L1144.7%201529.53C1173.44%201547.49%201216.56%201547.49%201241.71%201529.53L1676.44%201227.74C1705.19%201209.78%201705.19%201177.44%201676.44%201159.48L1241.71%20868.473Z'%20fill='%23546E7A'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1195%201949C1173.4%201949%201159%201935.19%201159%201917.92L1159%201531.08C1159%201513.82%201173.4%201500%201195%201500%201216.6%201500%201231%201513.82%201231%201531.08L1231%201914.46C1231%201935.19%201216.6%201949%201195%201949Z'%20fill='%23546E7A'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1553.92%201435.92C1553.92%201471.89%201557.5%201486.27%201518.03%201511.45L1428.32%201568.99C1388.85%201594.17%201374.5%201572.59%201374.5%201540.22L1374.5%201446.71C1374.5%201439.52%201374.5%201435.92%201363.73%201428.73%201270.43%201363.99%20911.591%201115.84%20847%201069.09L1012.07%20954C1058.72%20982.772%201399.61%201209.35%201539.56%201306.45%201546.74%201310.05%201550.33%201317.24%201550.33%201320.84L1550.33%201435.92Z'%20fill='%2399AAB5'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1543.41%201310.21C1399.82%201213.17%201058.79%20986.752%201015.72%20958L951.103%20997.534%20847%201069.41C911.615%201116.14%201270.59%201360.53%201363.92%201425.22%201371.1%201428.81%201371.1%201432.41%201371.1%201436L1547%201313.8C1547%201313.8%201547%201310.21%201543.41%201310.21Z'%20fill='%23CCD6DD'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1554.9%201435.48%201554.9%201324.19C1554.9%201317.01%201551.3%201313.42%201544.11%201309.83%201400.28%201212.89%201058.67%20986.721%201015.51%20958L940%201008.26C1062.26%201090.83%201389.49%201306.24%201475.79%201367.27%201486.58%201374.45%201486.58%201381.63%201486.58%201385.22L1486.58%201536%201522.54%201510.87C1558.5%201485.74%201554.9%201467.79%201554.9%201435.48Z'%20fill='%23CCD6DD'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1543.23%201309.95C1399.6%201212.98%201058.49%20986.731%201015.4%20958L940%201008.28C1062.08%201090.88%201388.83%201306.36%201475.01%201367.41%201475.01%201367.41%201478.6%201371%201478.6%201371L1554%201317.13C1546.82%201313.54%201546.82%201309.95%201543.23%201309.95Z'%20fill='%23E1E8ED'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/svg%3e",wZ={class:"join flex"},bZ=["value"],Vk=lt({__name:"BackendSwitch",setup(e){const t=Le(()=>Ys.value.map(r=>({label:`${r.protocol}://${r.host}:${r.port}`,value:r.uuid}))),n=()=>{xi.value=null,To.push({name:Bt.setup})};return(r,i)=>(X(),ae("div",wZ,[At(N("select",{class:"join-item select select-bordered select-xs w-48","onUpdate:modelValue":i[0]||(i[0]=o=>Ze(xi)?xi.value=o:null)},[(X(!0),ae(Ye,null,Gt(t.value,o=>(X(),ae("option",{key:o.value,value:o.value},de(o.label),9,bZ))),128))],512),[[wo,$(xi)]]),N("button",{class:"btn join-item btn-xs",onClick:n},[Se($(iO),{class:"h-4 w-4"})])]))}}),SZ={class:"grid grid-cols-2 gap-1"},Hk=lt({__name:"StatisticsInfo",setup(e){return(t,n)=>(X(),ae("div",SZ,[N("div",null,de(t.$t("connections"))+": "+de($(mo).length),1),N("div",null,de(t.$t("memoryUsage"))+": "+de($(mn)($(bx),{binary:!0})),1),N("div",null,de(t.$t("download"))+": "+de($(mn)($(hm))),1),N("div",null,de(t.$t("dlSpeed"))+": "+de($(mn)($(Sx)))+"/s",1),N("div",null,de(t.$t("upload"))+": "+de($(mn)($(dm))),1),N("div",null,de(t.$t("ulSpeed"))+": "+de($(mn)($(xx)))+"/s",1)]))}}),xZ={class:"flex flex-col gap-2 p-2 text-xs"},CZ={class:"flex gap-1"},TZ=["src"],EZ={class:"flex"},AZ=lt({__name:"CommonCtrl",setup(e){return(t,n)=>(X(),ae("div",xZ,[Se(Hk),N("div",CZ,[ut(de(t.$t("version"))+": ",1),N("img",{src:$(Ia)?$(_Z):$(yZ),class:"w-4"},null,8,TZ),ut(" "+de($(T0)),1)]),N("div",EZ,[N("button",{class:"btn btn-circle btn-ghost btn-xs",onClick:n[0]||(n[0]=r=>au.value=!0)},[Se($(O6),{class:"h-5 w-5"})]),n[1]||(n[1]=N("div",{class:"flex-1"},null,-1)),Se(Vk)])]))}});/*! *****************************************************************************
+ */function gv(){return!0}const DK=Symbol("merge-proxy"),IK={get(e,t,n){return t===DK?n:e.get(t)},has(e,t){return e.has(t)},set:gv,deleteProperty:gv,getOwnPropertyDescriptor(e,t){return{configurable:!0,enumerable:!0,get(){return e.get(t)},set:gv,deleteProperty:gv}},ownKeys(e){return e.keys()}};function e1(e){return"value"in e?e.value:e}function gh(){for(var e=arguments.length,t=new Array(e),n=0;n (X(),ae("div",WK,[$(Ql)?(X(),_t(VX,{key:0})):(X(),_t($K,{key:1})),F("dialog",{ref_key:"modalRef",ref:n,class:"modal"},[F("div",YK,[Se($(GK),{data:$(t)},null,8,["data"])]),i[0]||(i[0]=F("form",{method:"dialog",class:"modal-backdrop"},[F("button",null,"close")],-1))],512)]))}}),qK={class:"relative w-full flex-1"},Ax=lt({__name:"TextInput",props:{label:{type:String,required:!1},modelValue:{type:String,required:!0}},emits:["update:modelValue"],setup(e,{emit:t}){const r=Ie(e.modelValue),i=t;kt(r,a=>{i("update:modelValue",a)});const o=()=>{r.value=""};return(a,s)=>(X(),ae("div",qK,[It(F("input",{"onUpdate:modelValue":s[0]||(s[0]=l=>r.value=l),type:"text",class:"input input-sm join-item input-bordered w-full"},null,512),[[Kr,r.value]]),Se($(v0),{class:"absolute right-2 top-1/2 h-3 w-3 -translate-y-1/2 cursor-pointer",onClick:o})]))}}),XK=["value","label"],KK=["value","label"],SM=lt({__name:"SourceIPFilter",props:{horizontal:{type:Boolean}},setup(e){const t=Le(()=>kq.value.map(n=>({label:vm(n),value:n})));return(n,r)=>n.horizontal?mt("",!0):It((X(),ae("select",{key:0,class:"join-item select select-bordered select-sm","onUpdate:modelValue":r[0]||(r[0]=i=>Qe(Ca)?Ca.value=i:null)},[r[1]||(r[1]=F("option",{value:"",label:"all"},null,-1)),t.value.every(i=>i.value!==$(Ca))&&$(Ca)!==""?(X(),ae("option",{key:0,value:$(Ca),label:$(vm)($(Ca))},null,8,XK)):mt("",!0),(X(!0),ae(Ye,null,Gt(t.value,i=>(X(),ae("option",{key:i.value,value:i.value,label:i.label},null,8,KK))),128))],512)),[[wo,$(Ca)]])}}),ZK={class:"tabs-boxed tabs tabs-sm"},QK={class:"shrink-0"},JK=["value"],eZ={class:"shrink-0"},tZ=["data-tip"],nZ={class:"join w-full flex-1"},rZ=lt({__name:"ConnectionCtrl",props:{horizontal:{type:Boolean}},setup(e){const t=()=>{Ac.value.forEach(n=>{E0(n.id)})};return(n,r)=>(X(),ae("div",{class:ot($(hn)("flex flex-col gap-2 p-2 text-sm",n.horizontal&&"flex-row flex-wrap pb-0"))},[F("div",ZK,[F("a",{role:"tab",class:ot($(hn)("tab",$(zl)===$(Aa).ACTIVE&&"tab-active")),onClick:r[0]||(r[0]=()=>zl.value=$(Aa).ACTIVE)},[ut(de(n.$t("activeConnections"))+" ",1),$(zl)===$(Aa).ACTIVE?(X(),ae(Ye,{key:0},[ut(" ("+de($(Ac).length)+") ",1)],64)):mt("",!0)],2),F("a",{role:"tab",class:ot($(hn)("tab",$(zl)===$(Aa).CLOSED&&"tab-active")),onClick:r[1]||(r[1]=()=>zl.value=$(Aa).CLOSED)},[ut(de(n.$t("closedConnections"))+" ",1),$(zl)===$(Aa).CLOSED?(X(),ae(Ye,{key:0},[ut(" ("+de($(Ac).length)+") ",1)],64)):mt("",!0)],2)]),$(Ql)?(X(),ae("div",{key:0,class:ot($(hn)("flex w-full items-center gap-2",n.horizontal&&"sm:w-auto"))},[F("span",QK,de(n.$t("sortBy"))+":",1),It(F("select",{class:"select select-bordered select-sm w-full","onUpdate:modelValue":r[2]||(r[2]=i=>Qe(Rg)?Rg.value=i:null)},[(X(!0),ae(Ye,null,Gt(Object.values($(jr)),i=>(X(),ae("option",{key:i,value:i},de(n.$t(i)||i),9,JK))),128))],512),[[wo,$(Rg)]])],2)):mt("",!0),F("div",{class:ot($(hn)("flex w-full items-center gap-2",n.horizontal&&"sm:w-auto"))},[F("span",eZ,de(n.$t("quickFilter"))+": ",1),It(F("input",{type:"text",class:"input input-sm join-item input-bordered w-full","onUpdate:modelValue":r[3]||(r[3]=i=>Qe(Hh)?Hh.value=i:null)},null,512),[[Kr,$(Hh)]]),It(F("input",{type:"checkbox",class:"toggle","onUpdate:modelValue":r[4]||(r[4]=i=>Qe(Mg)?Mg.value=i:null)},null,512),[[uo,$(Mg)]]),F("div",{class:ot(`tooltip ${n.horizontal?"tooltip-left sm:tooltip-bottom":"tooltip-left"}`),"data-tip":n.$t("quickFilterTip")},[Se($(iO),{class:"h-4 w-4"})],10,tZ)],2),n.horizontal?mt("",!0):(X(),_t(SM,{key:1})),F("div",nZ,[n.horizontal?(X(),_t(SM,{key:0})):mt("",!0),Se(Ax,{modelValue:$(Uh),"onUpdate:modelValue":r[5]||(r[5]=i=>Qe(Uh)?Uh.value=i:null),class:"join-item"},null,8,["modelValue"]),F("button",{class:"btn-bordered btn join-item btn-sm",onClick:r[6]||(r[6]=i=>Dg.value=!$(Dg))},[(X(),_t(Ua($(Dg)?$(nO):$(tO)),{class:"h-4 w-4"}))]),F("button",{class:"btn-bordered btn join-item btn-sm",onClick:t},[Se($(v0),{class:"h-4 w-4"})])])],2))}}),Mx=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},Ik=Mx(rZ,[["__scopeId","data-v-46c5b7bb"]]),_m=Ie([]),Dc=Ie(""),Pg=Ie(!1),Lg=Qt("config/log-level",Zl.Info);let mv,wm=[];const iZ=ea.throttle(()=>{_m.value=wm.concat(_m.value).slice(0,bg.value),wm=[]},500),wb=[],oZ=()=>{wb.length=0;for(const e in mi.value){if(e.startsWith("/"))continue;const t=new RegExp(e+":","ig");wb.push([t,`${e} (${mi.value[e]}) :`])}};kt(mi,()=>{oZ()},{immediate:!0});const bb=()=>{mv==null||mv(),_m.value=[],wm=[];let e=1;const t=Rq({level:Lg.value}),n=kt(t.data,r=>{if(r){if(Pg.value){e++;return}for(const[i,o]of wb)r.payload=r.payload.replace(i,o);wm.unshift({...r,time:new Date().valueOf(),seq:e++}),iZ()}});mv=()=>{n(),t.close()}},aZ=["value"],Pk=lt({__name:"LogsCtrl",props:{horizontal:{type:Boolean}},setup(e){return(t,n)=>(X(),ae("div",{class:ot($(hn)("join w-full p-2",t.horizontal&&"max-w-96 pb-0"))},[It(F("select",{class:"join-item select select-bordered select-sm","onUpdate:modelValue":n[0]||(n[0]=r=>Qe(Lg)?Lg.value=r:null),onChange:n[1]||(n[1]=(...r)=>$(bb)&&$(bb)(...r))},[(X(!0),ae(Ye,null,Gt(Object.values($(Zl)),r=>(X(),ae("option",{key:r,value:r},de(r),9,aZ))),128))],544),[[wo,$(Lg)]]),Se(Ax,{type:"text",modelValue:$(Dc),"onUpdate:modelValue":n[2]||(n[2]=r=>Qe(Dc)?Dc.value=r:null)},null,8,["modelValue"]),F("button",{class:"btn-bordered btn join-item btn-sm",onClick:n[3]||(n[3]=r=>Pg.value=!$(Pg))},[(X(),_t(Ua($(Pg)?$(nO):$(tO)),{class:"h-4 w-4"}))])],2))}}),Go=Ie(),Lk=async()=>{Go.value=(await Sq()).data},Ok=async e=>{await xq(e),Lk()},kk=Ie(pu.PROXIES),Nk=Le(()=>{var e;return kk.value===pu.PROVIDER?Mc.value.map(t=>t.name):Ia.value&&gg.value&&Wa.value[ql]?[...cb.value,ql]:!Ia.value&&((e=Go.value)==null?void 0:e.mode.toLocaleUpperCase())===ql&&Wa.value[ql]?[ql]:cb.value}),sZ=Le(()=>kh.value&&Nk.value.length>1),D0=()=>({proxiesTabShow:kk,renderGroups:Nk,hasTwoColumns:sZ}),lZ={key:0,role:"tablist",class:"tabs-boxed tabs tabs-sm"},uZ=["onClick"],cZ={key:1,class:"flex flex-col gap-2"},fZ=["value"],hZ=["label","value"],dZ=["label","value"],pZ={class:"shrink-0"},Fk=lt({__name:"ProxiesCtrl",props:{horizontal:{type:Boolean}},setup(e){const{proxiesTabShow:t}=D0(),n=Ie(!1),r=async()=>{if(!n.value){n.value=!0;try{await Promise.all(Mc.value.map(a=>ek(a.name))),await jc(),n.value=!1}catch{await jc(),n.value=!1}}},i=Le(()=>{var a,s;return((a=Go.value)==null?void 0:a["mode-list"])||((s=Go.value)==null?void 0:s.modes)||["direct","rule","global"]}),o=a=>{const s=a.target.value;Ok({mode:s})};return(a,s)=>$(Go)?(X(),ae("div",{key:0,class:ot($(hn)("flex flex-col gap-1 p-2 text-sm sm:gap-2",a.horizontal&&"flex-row flex-wrap pb-0"))},[$(Mc).length?(X(),ae(Ye,{key:0},[$(Mc).length?(X(),ae("div",lZ,[(X(!0),ae(Ye,null,Gt($(pu),l=>(X(),ae("a",{role:"tab",class:ot(["tab",{"tab-active":$(t)===l}]),key:l,onClick:u=>t.value=l},de(a.$t(l)),11,uZ))),128))])):mt("",!0),$(t)===$(pu).PROVIDER?(X(),ae("div",cZ,[F("button",{class:ot($(hn)("btn btn-sm",n.value?"animate-pulse":"")),onClick:r},de(a.$t("updateAllProviders")),3)])):mt("",!0)],64)):mt("",!0),s[2]||(s[2]=F("div",{class:"w-full sm:hidden"},null,-1)),F("div",{class:ot($(hn)("flex w-full items-center gap-2",a.horizontal&&"w-24"))},[F("select",{class:"select select-bordered select-sm w-1/2 flex-1",value:$(Go).mode,onChange:o},[(X(!0),ae(Ye,null,Gt(i.value,l=>(X(),ae("option",{key:l,label:a.$t(l.toLowerCase())||l,value:l},null,8,hZ))),128))],40,fZ)],2),F("div",{class:ot($(hn)("flex w-full items-center gap-2",a.horizontal&&"w-72 max-sm:flex-1"))},[It(F("select",{class:"select select-bordered select-sm w-1/2 flex-1","onUpdate:modelValue":s[0]||(s[0]=l=>Qe(mg)?mg.value=l:null)},[(X(!0),ae(Ye,null,Gt(Object.values($(Is)),l=>(X(),ae("option",{key:l,label:a.$t(l),value:l},null,8,dZ))),128))],512),[[wo,$(mg)]]),F("span",pZ,de(a.$t("hideUnavailable"))+": ",1),It(F("input",{class:"toggle",type:"checkbox","onUpdate:modelValue":s[1]||(s[1]=l=>Qe(_g)?_g.value=l:null)},null,512),[[uo,$(_g)]])],2)],2)):mt("",!0)}}),Gh=Ie(zc.RULES),$k=Ie([]),bm=Ie([]),Sm=async()=>{const{data:e}=await wq(),{data:t}=await bq();$k.value=e.rules,bm.value=Object.values(t.providers)},vZ={role:"tablist",class:"tabs-boxed tabs tabs-sm"},gZ=["onClick"],mZ={key:0,class:"flex flex-col gap-2"},Bk=lt({__name:"RulesCtrl",props:{horizontal:{type:Boolean}},setup(e){const t=Ie(!1),n=async()=>{if(!t.value){t.value=!0;try{await Promise.all(bm.value.map(r=>tk(r.name))),await Sm(),t.value=!1}catch{await Sm(),t.value=!1}}};return(r,i)=>$(bm).length?(X(),ae("div",{key:0,class:ot($(hn)("flex flex-col gap-2 p-2",r.horizontal&&"flex-row pb-0"))},[F("div",vZ,[(X(!0),ae(Ye,null,Gt($(zc),o=>(X(),ae("a",{role:"tab",class:ot(["tab",{"tab-active":$(Gh)===o}]),key:o,onClick:a=>Gh.value=o},de(r.$t(o)),11,gZ))),128))]),$(Gh)===$(zc).PROVIDER?(X(),ae("div",mZ,[F("button",{class:ot($(hn)("btn btn-sm",t.value?"animate-pulse":"")),onClick:n},de(r.$t("updateAllProviders")),3)])):mt("",!0)],2)):mt("",!0)}}),yZ="data:image/jpeg;base64,/9j/2wCEAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDIBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIADAAMAMBIgACEQEDEQH/xAGiAAABBQEBAQEBAQAAAAAAAAAAAQIDBAUGBwgJCgsQAAIBAwMCBAMFBQQEAAABfQECAwAEEQUSITFBBhNRYQcicRQygZGhCCNCscEVUtHwJDNicoIJChYXGBkaJSYnKCkqNDU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6g4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2drh4uPk5ebn6Onq8fLz9PX29/j5+gEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoLEQACAQIEBAMEBwUEBAABAncAAQIDEQQFITEGEkFRB2FxEyIygQgUQpGhscEJIzNS8BVictEKFiQ04SXxFxgZGiYnKCkqNTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqCg4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2dri4+Tl5ufo6ery8/T19vf4+fr/2gAMAwEAAhEDEQA/APXaKKx/EfirRfCdmLjWL1YiwzFAnzTS/wC6vp7nA96ZJsgEkAAknsKCCCQQQR2NfPHiT4wax4jvI7DTFbStMkkCMsb/AL6VScfM46A+i4/Gl8N/GDWPDl5JYamrarpkchRFkf8AfRKDgbXPUD0bP1FIdj6ForH8O+KtE8V2ZudHvVlKjMkD/LNF/vL6e4yPetimIK8D+KniNrf4iajpupWcWpaWscGyCU7XhzChJikHKHPOOVJ6g175Xzl8W7E3PxP1aWSeK3t0jtg0kh7+QnCqOWP0H1wOaQ0YVt4ct9QuYrzw3dtepG6vJYyqFu4lByTtHEgHqmT6qKLnw5b6fcy3niS7aySR2eOxhAa7lUnIJU8RA+r8+imqui3trBr2mwafBjN3EGuZwDI3zj7o6IPpk/7WOKNavbafXdSg1CD7t3KFuYFAkX5z94cBx9cH/axxQM7T4a+I2uPGsGnabZxaZphtrktBEdzykQuQZZD8znPOOFB6AV78hzGpPoK+b/hdYm28f2ksc8Vxbva3QWSNu/kPwynlT9R9MjmvpCP/AFa/QUCY6ue8UeDNF8WwbdUtA0wXEdzFhJo/TDY5Hs2R9K6GimI+edQ+FGt+GvENhd2gOpacl3EWlhQiSJd45dOSB7jI9xUVr8L9X13X768vydM0+S7lKPKhaWYbz/q4+p+pwPevoojPqCOhBwR9DUUVtFE7SKpMjfed2LMfxPNIdzmfDXgjS/D1qYrC0FtvXbLO5D3Ew7hn6KD/AHVwK6wDAAHQUUUxH//Z",_Z="data:image/svg+xml,%3csvg%20width='1027'%20height='1109'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xml:space='preserve'%20overflow='hidden'%3e%3cdefs%3e%3cfilter%20id='fx0'%20x='-10%25'%20y='-10%25'%20width='120%25'%20height='120%25'%20filterUnits='userSpaceOnUse'%20primitiveUnits='userSpaceOnUse'%3e%3cfeComponentTransfer%20color-interpolation-filters='sRGB'%3e%3cfeFuncR%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncG%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncB%20type='discrete'%20tableValues='0%200'%20/%3e%3cfeFuncA%20type='linear'%20slope='0.4'%20intercept='0'%20/%3e%3c/feComponentTransfer%3e%3cfeGaussianBlur%20stdDeviation='4.58333%204.58333'%20/%3e%3c/filter%3e%3cclipPath%20id='clip1'%3e%3crect%20x='692'%20y='855'%20width='1027'%20height='1109'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clip2'%3e%3crect%20x='-2'%20y='-2'%20width='541'%20height='786'%20/%3e%3c/clipPath%3e%3cclipPath%20id='clip3'%3e%3crect%20x='0'%20y='0'%20width='535'%20height='782'%20/%3e%3c/clipPath%3e%3c/defs%3e%3cg%20clip-path='url(%23clip1)'%20transform='translate(-692%20-855)'%3e%3cpath%20d='M692%201191%20692%201575.69C692%201640.41%20731.499%201651.19%20731.499%201651.19L1148.03%201931.62C1212.66%201974.77%201194.71%201881.29%201194.71%201881.29L1194.71%201528.96%20692%201191Z'%20fill='%2337474F'%20fill-rule='evenodd'%20/%3e%3cg%20clip-path='url(%23clip2)'%20filter='url(%23fx0)'%20transform='translate(1184%201182)'%3e%3cg%20clip-path='url(%23clip3)'%3e%3cpath%20d='M520.482%2015.4819%20520.482%20400.176C520.482%20464.89%20480.983%20475.676%20480.983%20475.676%20480.983%20475.676%20129.086%20712.963%2064.4523%20756.106-0.181814%20799.25%2017.7721%20705.773%2017.7721%20705.773L17.7721%20353.437%20520.482%2015.4819Z'%20fill='%23455A64'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/g%3e%3cpath%20d='M1698%201191%201698%201575.69C1698%201640.41%201658.5%201651.19%201658.5%201651.19%201658.5%201651.19%201306.6%201888.48%201241.97%201931.62%201177.34%201974.77%201195.29%201881.29%201195.29%201881.29L1195.29%201528.96%201698%201191Z'%20fill='%23455A64'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1241.71%20868.473C1212.96%20850.509%201169.85%20850.509%201144.7%20868.473L713.557%201163.07C684.814%201181.04%20684.814%201213.37%20713.557%201231.33L1144.7%201529.53C1173.44%201547.49%201216.56%201547.49%201241.71%201529.53L1676.44%201227.74C1705.19%201209.78%201705.19%201177.44%201676.44%201159.48L1241.71%20868.473Z'%20fill='%23546E7A'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1195%201949C1173.4%201949%201159%201935.19%201159%201917.92L1159%201531.08C1159%201513.82%201173.4%201500%201195%201500%201216.6%201500%201231%201513.82%201231%201531.08L1231%201914.46C1231%201935.19%201216.6%201949%201195%201949Z'%20fill='%23546E7A'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1553.92%201435.92C1553.92%201471.89%201557.5%201486.27%201518.03%201511.45L1428.32%201568.99C1388.85%201594.17%201374.5%201572.59%201374.5%201540.22L1374.5%201446.71C1374.5%201439.52%201374.5%201435.92%201363.73%201428.73%201270.43%201363.99%20911.591%201115.84%20847%201069.09L1012.07%20954C1058.72%20982.772%201399.61%201209.35%201539.56%201306.45%201546.74%201310.05%201550.33%201317.24%201550.33%201320.84L1550.33%201435.92Z'%20fill='%2399AAB5'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1543.41%201310.21C1399.82%201213.17%201058.79%20986.752%201015.72%20958L951.103%20997.534%20847%201069.41C911.615%201116.14%201270.59%201360.53%201363.92%201425.22%201371.1%201428.81%201371.1%201432.41%201371.1%201436L1547%201313.8C1547%201313.8%201547%201310.21%201543.41%201310.21Z'%20fill='%23CCD6DD'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1554.9%201435.48%201554.9%201324.19C1554.9%201317.01%201551.3%201313.42%201544.11%201309.83%201400.28%201212.89%201058.67%20986.721%201015.51%20958L940%201008.26C1062.26%201090.83%201389.49%201306.24%201475.79%201367.27%201486.58%201374.45%201486.58%201381.63%201486.58%201385.22L1486.58%201536%201522.54%201510.87C1558.5%201485.74%201554.9%201467.79%201554.9%201435.48Z'%20fill='%23CCD6DD'%20fill-rule='evenodd'%20/%3e%3cpath%20d='M1543.23%201309.95C1399.6%201212.98%201058.49%20986.731%201015.4%20958L940%201008.28C1062.08%201090.88%201388.83%201306.36%201475.01%201367.41%201475.01%201367.41%201478.6%201371%201478.6%201371L1554%201317.13C1546.82%201313.54%201546.82%201309.95%201543.23%201309.95Z'%20fill='%23E1E8ED'%20fill-rule='evenodd'%20/%3e%3c/g%3e%3c/svg%3e",wZ={class:"join flex"},bZ=["value"],Vk=lt({__name:"BackendSwitch",setup(e){const t=Le(()=>Ys.value.map(r=>({label:`${r.protocol}://${r.host}:${r.port}`,value:r.uuid}))),n=()=>{Si.value=null,To.push({name:Bt.setup})};return(r,i)=>(X(),ae("div",wZ,[It(F("select",{class:"join-item select select-bordered select-xs w-48","onUpdate:modelValue":i[0]||(i[0]=o=>Qe(Si)?Si.value=o:null)},[(X(!0),ae(Ye,null,Gt(t.value,o=>(X(),ae("option",{key:o.value,value:o.value},de(o.label),9,bZ))),128))],512),[[wo,$(Si)]]),F("button",{class:"btn join-item btn-xs",onClick:n},[Se($(rO),{class:"h-4 w-4"})])]))}}),SZ={class:"grid grid-cols-2 gap-1"},Hk=lt({__name:"StatisticsInfo",setup(e){return(t,n)=>(X(),ae("div",SZ,[F("div",null,de(t.$t("connections"))+": "+de($(mo).length),1),F("div",null,de(t.$t("memoryUsage"))+": "+de($(mn)($(_x),{binary:!0})),1),F("div",null,de(t.$t("download"))+": "+de($(mn)($(dm))),1),F("div",null,de(t.$t("dlSpeed"))+": "+de($(mn)($(bx)))+"/s",1),F("div",null,de(t.$t("upload"))+": "+de($(mn)($(pm))),1),F("div",null,de(t.$t("ulSpeed"))+": "+de($(mn)($(Sx)))+"/s",1)]))}}),xZ={class:"flex flex-col gap-2 p-2 text-xs"},CZ={class:"flex gap-1"},TZ=["src"],EZ={class:"flex"},AZ=lt({__name:"CommonCtrl",setup(e){return(t,n)=>(X(),ae("div",xZ,[Se(Hk),F("div",CZ,[ut(de(t.$t("version"))+": ",1),F("img",{src:$(Ia)?$(_Z):$(yZ),class:"w-4"},null,8,TZ),ut(" "+de($(Td)),1)]),F("div",EZ,[F("button",{class:"btn btn-circle btn-ghost btn-xs",onClick:n[0]||(n[0]=r=>au.value=!0)},[Se($(O6),{class:"h-5 w-5"})]),n[1]||(n[1]=F("div",{class:"flex-1"},null,-1)),Se(Vk)])]))}});/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
@@ -111,20 +111,20 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
-***************************************************************************** */var Sb=function(e,t){return Sb=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},Sb(e,t)};function Ve(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Sb(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var Dx=12,MZ="sans-serif",gu=Dx+"px "+MZ,RZ=20,DZ=100,IZ="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function PZ(e){var t={};if(typeof JSON>"u")return t;for(var n=0;n=a;l++)s-=a;var u=Ti(n,t);return u>s&&(n="",u=0),s=e-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=s,i.containerWidth=e,i}function tN(e,t){var n=t.containerWidth,r=t.font,i=t.contentWidth;if(!n)return"";var o=Ti(e,r);if(o<=n)return e;for(var a=0;;a++){if(o<=i||a>=t.maxIterations){e+=t.ellipsis;break}var s=a===0?fQ(e,i,t.ascCharWidth,t.cnCharWidth):o>0?Math.floor(e.length*i/o):0;e=e.substr(0,s),o=Ti(e,r)}return e===""&&(e=t.placeholder),e}function fQ(e,t,n,r){for(var i=0,o=0,a=e.length;od&&u){var g=Math.floor(d/s);f=f.slice(0,g)}if(e&&o&&c!=null)for(var y=eN(c,i,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),_=0;_n);c++);c=p(c-1,s-2)}g=a[c+1],d=a[c]}if(d&&g){this._lastFr=c,this._lastFrP=n;var _=g.percent-d.percent,m=_===0?1:p((n-d.percent)/_,1);g.easingFunc&&(m=g.easingFunc(m));var b=r?this._additiveValue:u?Uf:t[l];if((Ev(o)||u)&&!b&&(b=this._additiveValue=[]),this.discrete)t[l]=m<1?d.rawValue:g.rawValue;else if(Ev(o))o===Ng?c1(b,d[i],g[i],m):FQ(b,d[i],g[i],m);else if(zM(o)){var S=d[i],x=g[i],E=o===Ib;t[l]={type:E?"linear":"radial",x:Ea(S.x,x.x,m),y:Ea(S.y,x.y,m),colorStops:ct(S.colorStops,function(A,D){var P=x.colorStops[D];return{offset:Ea(A.offset,P.offset,m),color:kg(c1([],A.color,P.color,m))}}),global:x.global},E?(t[l].x2=Ea(S.x2,x.x2,m),t[l].y2=Ea(S.y2,x.y2,m)):t[l].r=Ea(S.r,x.r,m)}else if(u)c1(b,d[i],g[i],m),r||(t[l]=kg(b));else{var T=Ea(d[i],g[i],m);r?this._additiveValue=T:t[l]=T}r&&this._addToTarget(t)}}},e.prototype._addToTarget=function(t){var n=this.valType,r=this.propName,i=this._additiveValue;n===Tv?t[r]=t[r]+i:n===yh?(Ba(t[r],Uf),Cv(Uf,Uf,i,1),t[r]=kg(Uf)):n===Ng?Cv(t[r],t[r],i,1):n===uN&&HM(t[r],t[r],i,1)},e}(),Ux=function(){function e(t,n,r,i){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=n,n&&i){Lx("Can' use additive animation on looped animation.");return}this._additiveAnimators=i,this._allowDiscrete=r}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(t){this._target=t},e.prototype.when=function(t,n,r){return this.whenWithKeys(t,n,Cn(n),r)},e.prototype.whenWithKeys=function(t,n,r,i){for(var o=this._tracks,a=0;a1e-4){s[0]=e-n,s[1]=t-r,l[0]=e+n,l[1]=t+r;return}if(Av[0]=y1(i)*n+e,Av[1]=m1(i)*r+t,Mv[0]=y1(o)*n+e,Mv[1]=m1(o)*r+t,u(s,Av,Mv),c(l,Av,Mv),i=i%Tl,i<0&&(i=i+Tl),o=o%Tl,o<0&&(o=o+Tl),i>o&&!a?o+=Tl:i0))},t.prototype.hasFill=function(){var n=this.style,r=n.fill;return r!=null&&r!=="none"},t.prototype.getBoundingRect=function(){var n=this._rect,r=this.style,i=!n;if(i){var o=!1;this.path||(o=!0,this.createPathProxy());var a=this.path;(o||this.__dirty&cc)&&(a.beginPath(),this.buildPath(a,this.shape,!1),this.pathUpdated()),n=a.getBoundingRect()}if(this._rect=n,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=n.clone());if(this.__dirty||i){s.copy(n);var l=r.strokeNoScale?this.getLineScale():1,u=r.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;u=Math.max(u,c??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return n},t.prototype.contain=function(n,r){var i=this.transformCoordToLocal(n,r),o=this.getBoundingRect(),a=this.style;if(n=i[0],r=i[1],o.contain(n,r)){var s=this.path;if(this.hasStroke()){var l=a.lineWidth,u=a.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),fJ(s,l/u,n,r)))return!0}if(this.hasFill())return cJ(s,n,r)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=cc,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(n){return this.animate("shape",n)},t.prototype.updateDuringAnimation=function(n){n==="style"?this.dirtyStyle():n==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(n,r){n==="shape"?this.setShape(r):e.prototype.attrKV.call(this,n,r)},t.prototype.setShape=function(n,r){var i=this.shape;return i||(i=this.shape={}),typeof n=="string"?i[n]=r:Pe(i,n),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&cc)},t.prototype.createStyle=function(n){return L0(dN,n)},t.prototype._innerSaveToNormal=function(n){e.prototype._innerSaveToNormal.call(this,n);var r=this._normalState;n.shape&&!r.shape&&(r.shape=Pe({},this.shape))},t.prototype._applyStateObj=function(n,r,i,o,a,s){e.prototype._applyStateObj.call(this,n,r,i,o,a,s);var l=!(r&&o),u;if(r&&r.shape?a?o?u=r.shape:(u=Pe({},i.shape),Pe(u,r.shape)):(u=Pe({},o?this.shape:i.shape),Pe(u,r.shape)):l&&(u=i.shape),u)if(a){this.shape=Pe({},this.shape);for(var c={},f=Cn(u),p=0;p
_[1]&&(_[1]=y)}return this._rawCount=this._count=l,{start:s,end:l}},e.prototype._initDataFromProvider=function(t,n,r){for(var i=this._provider,o=this._chunks,a=this._dimensions,s=a.length,l=this._rawExtent,u=ct(a,function(b){return b.property}),c=0;cm[1]&&(m[1]=_)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=n,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(t,n){if(!(n>=0&&n>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",r[l]+":0",i[u]+":0",r[1-l]+":auto",i[1-u]+":auto",""].join("!important;"),e.appendChild(a),n.push(a)}return n}function hne(e,t,n){for(var r=n?"invTrans":"trans",i=t[r],o=t.srcCoords,a=[],s=[],l=!0,u=0;u<4;u++){var c=e[u].getBoundingClientRect(),f=2*u,p=c.left,d=c.top;a.push(p,d),l=l&&o&&p===o[f]&&d===o[f+1],s.push(e[u].offsetLeft,e[u].offsetTop)}return l&&i?i:(t.srcCoords=a,t[r]=n?jR(s,a):jR(a,s))}function pF(e){return e.nodeName.toUpperCase()==="CANVAS"}var dne=/([&<>"'])/g,pne={"&":"&","<":"<",">":">",'"':""","'":"'"};function _i(e){return e==null?"":(e+"").replace(dne,function(t,n){return pne[n]})}const vne={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},gne={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var $m="ZH",hC="EN",kc=hC,Hg={},dC={},vF=vt.domSupported?function(){var e=(document.documentElement.lang||navigator.language||navigator.browserLanguage||kc).toUpperCase();return e.indexOf($m)>-1?$m:kc}():kc;function gF(e,t){e=e.toUpperCase(),dC[e]=new On(t),Hg[e]=t}function mne(e){if(qe(e)){var t=Hg[e.toUpperCase()]||{};return e===$m||e===hC?Nt(t):Kt(Nt(t),Nt(Hg[kc]),!1)}else return Kt(Nt(e),Nt(Hg[kc]),!1)}function yne(e){return dC[e]}function _ne(){return dC[kc]}gF(hC,vne);gF($m,gne);var pC=1e3,vC=pC*60,Jh=vC*60,qi=Jh*24,XR=qi*365,bh={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},$v="{yyyy}-{MM}-{dd}",KR={year:"{yyyy}",month:"{yyyy}-{MM}",day:$v,hour:$v+" "+bh.hour,minute:$v+" "+bh.minute,second:$v+" "+bh.second,millisecond:bh.none},B1=["year","month","day","hour","minute","second","millisecond"],mF=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function ms(e,t){return e+="","0000".substr(0,t-e.length)+e}function Nc(e){switch(e){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return e}}function wne(e){return e===Nc(e)}function bne(e){switch(e){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function X0(e,t,n,r){var i=ja(e),o=i[gC(n)](),a=i[Fc(n)]()+1,s=Math.floor((a-1)/3)+1,l=i[K0(n)](),u=i["get"+(n?"UTC":"")+"Day"](),c=i[Pd(n)](),f=(c-1)%12+1,p=i[Z0(n)](),d=i[Q0(n)](),g=i[J0(n)](),y=c>=12?"pm":"am",_=y.toUpperCase(),m=r instanceof On?r:yne(r||vF)||_ne(),b=m.getModel("time"),S=b.get("month"),x=b.get("monthAbbr"),E=b.get("dayOfWeek"),T=b.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,y+"").replace(/{A}/g,_+"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,ms(o%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,S[a-1]).replace(/{MMM}/g,x[a-1]).replace(/{MM}/g,ms(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,ms(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,E[u]).replace(/{ee}/g,T[u]).replace(/{e}/g,u+"").replace(/{HH}/g,ms(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,ms(f+"",2)).replace(/{h}/g,f+"").replace(/{mm}/g,ms(p,2)).replace(/{m}/g,p+"").replace(/{ss}/g,ms(d,2)).replace(/{s}/g,d+"").replace(/{SSS}/g,ms(g,3)).replace(/{S}/g,g+"")}function Sne(e,t,n,r,i){var o=null;if(qe(n))o=n;else if(wt(n))o=n(e.value,t,{level:e.level});else{var a=Pe({},bh);if(e.level>0)for(var s=0;sn);c++);c=p(c-1,s-2)}g=a[c+1],d=a[c]}if(d&&g){this._lastFr=c,this._lastFrP=n;var _=g.percent-d.percent,m=_===0?1:p((n-d.percent)/_,1);g.easingFunc&&(m=g.easingFunc(m));var b=r?this._additiveValue:u?Uf:t[l];if((Av(o)||u)&&!b&&(b=this._additiveValue=[]),this.discrete)t[l]=m<1?d.rawValue:g.rawValue;else if(Av(o))o===Fg?c1(b,d[i],g[i],m):FQ(b,d[i],g[i],m);else if(UM(o)){var S=d[i],x=g[i],E=o===Ib;t[l]={type:E?"linear":"radial",x:Ea(S.x,x.x,m),y:Ea(S.y,x.y,m),colorStops:ct(S.colorStops,function(A,D){var P=x.colorStops[D];return{offset:Ea(A.offset,P.offset,m),color:Ng(c1([],A.color,P.color,m))}}),global:x.global},E?(t[l].x2=Ea(S.x2,x.x2,m),t[l].y2=Ea(S.y2,x.y2,m)):t[l].r=Ea(S.r,x.r,m)}else if(u)c1(b,d[i],g[i],m),r||(t[l]=Ng(b));else{var T=Ea(d[i],g[i],m);r?this._additiveValue=T:t[l]=T}r&&this._addToTarget(t)}}},e.prototype._addToTarget=function(t){var n=this.valType,r=this.propName,i=this._additiveValue;n===Ev?t[r]=t[r]+i:n===yh?(Ba(t[r],Uf),Tv(Uf,Uf,i,1),t[r]=Ng(Uf)):n===Fg?Tv(t[r],t[r],i,1):n===uN&&VM(t[r],t[r],i,1)},e}(),Hx=function(){function e(t,n,r,i){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=n,n&&i){Px("Can' use additive animation on looped animation.");return}this._additiveAnimators=i,this._allowDiscrete=r}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(t){this._target=t},e.prototype.when=function(t,n,r){return this.whenWithKeys(t,n,Cn(n),r)},e.prototype.whenWithKeys=function(t,n,r,i){for(var o=this._tracks,a=0;a1e-4){s[0]=e-n,s[1]=t-r,l[0]=e+n,l[1]=t+r;return}if(Mv[0]=y1(i)*n+e,Mv[1]=m1(i)*r+t,Rv[0]=y1(o)*n+e,Rv[1]=m1(o)*r+t,u(s,Mv,Rv),c(l,Mv,Rv),i=i%Tl,i<0&&(i=i+Tl),o=o%Tl,o<0&&(o=o+Tl),i>o&&!a?o+=Tl:i0))},t.prototype.hasFill=function(){var n=this.style,r=n.fill;return r!=null&&r!=="none"},t.prototype.getBoundingRect=function(){var n=this._rect,r=this.style,i=!n;if(i){var o=!1;this.path||(o=!0,this.createPathProxy());var a=this.path;(o||this.__dirty&cc)&&(a.beginPath(),this.buildPath(a,this.shape,!1),this.pathUpdated()),n=a.getBoundingRect()}if(this._rect=n,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=n.clone());if(this.__dirty||i){s.copy(n);var l=r.strokeNoScale?this.getLineScale():1,u=r.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;u=Math.max(u,c??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return n},t.prototype.contain=function(n,r){var i=this.transformCoordToLocal(n,r),o=this.getBoundingRect(),a=this.style;if(n=i[0],r=i[1],o.contain(n,r)){var s=this.path;if(this.hasStroke()){var l=a.lineWidth,u=a.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),fJ(s,l/u,n,r)))return!0}if(this.hasFill())return cJ(s,n,r)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=cc,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(n){return this.animate("shape",n)},t.prototype.updateDuringAnimation=function(n){n==="style"?this.dirtyStyle():n==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(n,r){n==="shape"?this.setShape(r):e.prototype.attrKV.call(this,n,r)},t.prototype.setShape=function(n,r){var i=this.shape;return i||(i=this.shape={}),typeof n=="string"?i[n]=r:Pe(i,n),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&cc)},t.prototype.createStyle=function(n){return L0(dN,n)},t.prototype._innerSaveToNormal=function(n){e.prototype._innerSaveToNormal.call(this,n);var r=this._normalState;n.shape&&!r.shape&&(r.shape=Pe({},this.shape))},t.prototype._applyStateObj=function(n,r,i,o,a,s){e.prototype._applyStateObj.call(this,n,r,i,o,a,s);var l=!(r&&o),u;if(r&&r.shape?a?o?u=r.shape:(u=Pe({},i.shape),Pe(u,r.shape)):(u=Pe({},o?this.shape:i.shape),Pe(u,r.shape)):l&&(u=i.shape),u)if(a){this.shape=Pe({},this.shape);for(var c={},f=Cn(u),p=0;p
_[1]&&(_[1]=y)}return this._rawCount=this._count=l,{start:s,end:l}},e.prototype._initDataFromProvider=function(t,n,r){for(var i=this._provider,o=this._chunks,a=this._dimensions,s=a.length,l=this._rawExtent,u=ct(a,function(b){return b.property}),c=0;cm[1]&&(m[1]=_)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=n,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(t,n){if(!(n>=0&&n>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",r[l]+":0",i[u]+":0",r[1-l]+":auto",i[1-u]+":auto",""].join("!important;"),e.appendChild(a),n.push(a)}return n}function hne(e,t,n){for(var r=n?"invTrans":"trans",i=t[r],o=t.srcCoords,a=[],s=[],l=!0,u=0;u<4;u++){var c=e[u].getBoundingClientRect(),f=2*u,p=c.left,d=c.top;a.push(p,d),l=l&&o&&p===o[f]&&d===o[f+1],s.push(e[u].offsetLeft,e[u].offsetTop)}return l&&i?i:(t.srcCoords=a,t[r]=n?YR(s,a):YR(a,s))}function pF(e){return e.nodeName.toUpperCase()==="CANVAS"}var dne=/([&<>"'])/g,pne={"&":"&","<":"<",">":">",'"':""","'":"'"};function yi(e){return e==null?"":(e+"").replace(dne,function(t,n){return pne[n]})}const vne={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},gne={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var Bm="ZH",fC="EN",kc=fC,Ug={},hC={},vF=vt.domSupported?function(){var e=(document.documentElement.lang||navigator.language||navigator.browserLanguage||kc).toUpperCase();return e.indexOf(Bm)>-1?Bm:kc}():kc;function gF(e,t){e=e.toUpperCase(),hC[e]=new On(t),Ug[e]=t}function mne(e){if(qe(e)){var t=Ug[e.toUpperCase()]||{};return e===Bm||e===fC?Nt(t):Kt(Nt(t),Nt(Ug[kc]),!1)}else return Kt(Nt(e),Nt(Ug[kc]),!1)}function yne(e){return hC[e]}function _ne(){return hC[kc]}gF(fC,vne);gF(Bm,gne);var dC=1e3,pC=dC*60,Jh=pC*60,ji=Jh*24,qR=ji*365,bh={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},Bv="{yyyy}-{MM}-{dd}",XR={year:"{yyyy}",month:"{yyyy}-{MM}",day:Bv,hour:Bv+" "+bh.hour,minute:Bv+" "+bh.minute,second:Bv+" "+bh.second,millisecond:bh.none},B1=["year","month","day","hour","minute","second","millisecond"],mF=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function ms(e,t){return e+="","0000".substr(0,t-e.length)+e}function Nc(e){switch(e){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return e}}function wne(e){return e===Nc(e)}function bne(e){switch(e){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function X0(e,t,n,r){var i=ja(e),o=i[vC(n)](),a=i[Fc(n)]()+1,s=Math.floor((a-1)/3)+1,l=i[K0(n)](),u=i["get"+(n?"UTC":"")+"Day"](),c=i[Ld(n)](),f=(c-1)%12+1,p=i[Z0(n)](),d=i[Q0(n)](),g=i[J0(n)](),y=c>=12?"pm":"am",_=y.toUpperCase(),m=r instanceof On?r:yne(r||vF)||_ne(),b=m.getModel("time"),S=b.get("month"),x=b.get("monthAbbr"),E=b.get("dayOfWeek"),T=b.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,y+"").replace(/{A}/g,_+"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,ms(o%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,S[a-1]).replace(/{MMM}/g,x[a-1]).replace(/{MM}/g,ms(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,ms(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,E[u]).replace(/{ee}/g,T[u]).replace(/{e}/g,u+"").replace(/{HH}/g,ms(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,ms(f+"",2)).replace(/{h}/g,f+"").replace(/{mm}/g,ms(p,2)).replace(/{m}/g,p+"").replace(/{ss}/g,ms(d,2)).replace(/{s}/g,d+"").replace(/{SSS}/g,ms(g,3)).replace(/{S}/g,g+"")}function Sne(e,t,n,r,i){var o=null;if(qe(n))o=n;else if(wt(n))o=n(e.value,t,{level:e.level});else{var a=Pe({},bh);if(e.level>0)for(var s=0;s