import{_ as s}from"./index119.js?v=1761009159";import{_ as e}from"./index401.js?v=1761009159";import{ak as l,x as a,e as t,_ as o}from"./utils-lib.js?v=1761009159";import{c as i,s as n,g as r,q as c,a6 as m,v as d,x as p,y as u,F as v,z as x,A as g,e as _,B as f,C as j,b0 as k,D as h}from"./base-lib.js?v=1761009159";import{X as b}from"./store.js?v=1761009159";import"./__commonjsHelpers__.js?v=1761009159";import"./files.js?v=1761009159";import"./validator.js?v=1761009159";import"./index106.js?v=1761009159";import"./column.js?v=1761009159";import"./store2.js?v=1761009159";import"./index103.js?v=1761009159";const w={class:"p-16px realTaskDialog"},y={class:"title"},C=["title"],D={class:"p-[1rem]"},H={class:"mt-[4px] flex justify-between items-center"},T={class:"flex"},q={class:"mr-[25px]"},z={class:"title"},A={class:"truncate max-w-[36rem]"},B={key:2,class:"wait"},F={class:"truncate"},I=["onClick"],L=o(i({__name:"index",emits:["close"],setup(o,{emit:i}){const L=b(),{taskData:N}=n(L),{getLog:W,cancel:X,$reset:$}=L,E=r(()=>N.value[0]||{log:"",name:"",shell:""});return c(()=>{W()}),m(()=>{$()}),(o,i)=>{var n,r,c,m,b;const L=t,W=e,$=s;return d(),p("div",w,[u(l)(u(E).log)?(d(),p(v,{key:0},[x("div",y,[x("span",{class:"truncate max-w-[36rem]",title:u(E).shell},"正在下载:"+g(u(E).shell),9,C),_(L,{onClick:i[0]||(i[0]=s=>u(X)(u(E)))},{default:f(()=>i[2]||(i[2]=[j("取消",-1)])),_:1,__:[2]})]),x("div",D,[_(W,{strokeWidth:3,percentage:Number((null==(n=u(E).log)?void 0:n.pre)||0),showText:!1},null,8,["percentage"]),x("div",H,[x("div",T,[x("span",q,g(null==(r=u(E).log)?void 0:r.used)+" / "+g(u(a)(null==(c=u(E).log)?void 0:c.total)),1),x("span",null,"预计还要:"+g(null==(m=u(E).log)?void 0:m.time),1)]),x("span",null,g(null==(b=u(E).log)?void 0:b.speed)+"/s",1)])])],64)):(d(),p(v,{key:1},[x("div",z,[x("span",A,g("".concat(u(E).name,":").concat(u(E).shell)),1),_(L,{onClick:i[1]||(i[1]=s=>u(X)(u(E)))},{default:f(()=>i[3]||(i[3]=[j("取消",-1)])),_:1,__:[3]})]),_($,{content:u(E).log,isHtml:!0,class:"max-h-[18rem] h-[18rem]"},null,8,["content"])],64)),u(N).length>1?(d(),p("div",B,[i[4]||(i[4]=x("div",{class:"title"},"等待执行任务",-1)),(d(!0),p(v,null,k(u(N).slice(1),s=>(d(),p("div",{class:"title item w-full !text-disabled items-center",key:s.id},[x("span",F,g("".concat(s.name,":").concat(s.shell)),1),x("span",{class:"svgtofont-el-close-bold text-danger cursor-pointer ml-1rem",onClick:e=>u(X)(s)},null,8,I)]))),128))])):h("",!0)])}}}),[["__scopeId","data-v-9a275a22"]]);export{L as default};
