import{c as e,s,g as t,r as l,q as o,a6 as a,v as i,x as n,z as r,e as d,B as u,K as p,F as c,b0 as f,N as m,y as v,A as h,L as x,C as b,az as g,bc as w,b5 as j,bd as y}from"./base-lib.js?v=1761009159";import{a as _,b as k}from"./index48.js?v=1761009159";import{u as N,_ as S}from"./utils-lib.js?v=1761009159";import"./__commonjsHelpers__.js?v=1761009159";import"./validator.js?v=1761009159";import"./index106.js?v=1761009159";import"./column.js?v=1761009159";import"./index112.js?v=1761009159";import"./index107.js?v=1761009159";import"./store3.js?v=1761009159";import"./store4.js?v=1761009159";import"./config.js?v=1761009159";import"./store5.js?v=1761009159";import"./hooks.js?v=1761009159";const H={class:"module-ui flex"},T={class:"flex flex-row items-end justify-between w-full"},z={class:"pb-[.2rem] text-base truncate block disk-list-title"},q={class:"text-base text-darkTertiary font-400 font-alibaba-bold disk-list-desc"},A={class:"flex flex-col justify-center items-center h-full"},B=S(e({__name:"disk-main-tile",props:{list:{default:()=>[]}},emits:["update:visible","openPopover","show","hide"],setup(e,{emit:S}){const{mainWidth:B}=N(),C=_();s(C);const F=t(()=>B.value<=1600?130:144),I=l(12),K=t(()=>I.value+4),L=l(null);let P=null;function W(e,s=120){P&&clearTimeout(P),P=setTimeout(()=>{L.value=e},s)}o(()=>{});const $=(e,s)=>{if(null!==L.value&&L.value!==s)return"#eaeaea";const{range:t}=e.info;return Number(t)>90?"#ef0808":Number(t)>80?"#ff9900":"#20a53a"},D=e=>F.value-e*K.value*2,E=e=>{const s=D(e);return{left:(F.value-s)/2+"px",top:(F.value-s)/2+"px"}};return o(()=>{C.init()}),a(C.$reset),(e,s)=>{const t=g,l=w,o=j,a=y;return i(),n("div",H,[r("div",T,[d(a,{span:24,class:"w-full"},{default:u(()=>[d(l,{span:16,xl:16},{default:u(()=>[r("div",{class:p(["h-full flex-2 gap-y-[10px]",2===e.list.length?"grid grid-cols-1 grid-rows-2":"grid grid-cols-2 grid-rows-2"])},[(i(!0),n(c,null,f(e.list,(e,l)=>(i(),m(t,{key:e.info.title+"-"+l,trigger:"hover",width:400,placement:"bottom-start",teleported:!1,"popper-class":"el-popover-shadow","hide-after":0,onShow:e=>W(l),onHide:s[0]||(s[0]=e=>W(null))},{reference:u(()=>{var t,o,a,d;return[r("div",{class:p(["flex flex-col justify-end cursor-pointer",{"is-inactive":null!==v(L)&&v(L)!==l}])},[r("span",z,h(e.info.title),1),r("span",{class:"text-[2.6rem] font-700 leading-[1.2] disk-list-range",style:x({color:$(e,l)})},h(e.info.range)+"%",5),r("span",q,["object"==typeof e.info.desc&&"disk"===e.info.type?(i(),n(c,{key:0},[r("span",{style:x({color:e.info.color})},[r("span",null,h(null==(t=e.info.desc)?void 0:t.used)+h(null==(o=e.info.desc)?void 0:o.used_unit),1)],4),s[2]||(s[2]=r("span",null,"/",-1)),r("span",null,h(null==(a=e.info.desc)?void 0:a.total)+h(null==(d=e.info.desc)?void 0:d.total_unit),1)],64)):(i(),n(c,{key:1},[b(h(e.info.desc),1)],64))])],2)]}),default:u(()=>[d(k,{item:e},null,8,["item"])]),_:2},1032,["onShow"]))),128))],2)]),_:1}),d(l,{span:8,xl:8},{default:u(()=>[r("div",A,[r("div",{class:"flex relative",style:x({width:v(F)+"px",height:v(F)+"px"})},[(i(!0),n(c,null,f(e.list,(e,l)=>(i(),m(t,{key:e.info.title,trigger:"hover",width:400,placement:"bottom-start",teleported:!1,"popper-class":"el-popover-shadow","show-after":100,"hide-after":0,transition:"none",onShow:e=>W(l),onHide:s[1]||(s[1]=e=>W(null))},{reference:u(()=>[r("div",{class:"flex absolute",style:x(E(l))},[d(o,{class:p(["cursor-pointer",{"mount-progress":"None"===e.data.path}]),type:"circle","show-text":!1,width:D(l),"stroke-width":v(I),color:$(e,l),percentage:e.info.range||0},null,8,["class","width","stroke-width","color","percentage"])],4)]),default:u(()=>[d(k,{item:e},null,8,["item"])]),_:2},1032,["onShow"]))),128))],4)])]),_:1})]),_:1})])])}}}),[["__scopeId","data-v-3347a55f"]]);export{B as default};
