import{l as e,dj as a,t as s,x as l,ds as t}from"./utils-lib.js?v=20260328163632";import{B as p}from"./index85.js?v=20260328163632";import{u as r,aC as i}from"./index115.js?v=20260328163632";import{k as o,r as m,O as n,o as u,V as d,_ as c,Y as h}from"./base-lib.js?v=20260328163632";import"./naive-ui.js?v=20260328163632";import"./__commonjsHelpers__.js?v=20260328163632";import"./env-lib.js?v=20260328163632";import"./index88.js?v=20260328163632";const f=o({__name:"index",props:{compData:{default:{fileItem:{}}}},setup(o,{expose:f}){const v=o,{refreshFilesList:b}=r(),x=m({label:e("文件名"),children:[{type:"input",key:"filename",attrs:{disabled:!0,class:"!w-[280px]",placeholder:e("请输入文件名")}}]}),j=m({label:e("解压到"),ruleKey:"path",rules:[{required:!0,message:e("请选择解压到"),trigger:"blur"}],children:[{type:"custom",key:"path",render:()=>n(p,{modelValue:k.value.path,"onUpdate:modelValue":e=>k.value.path=e,onIconClick:()=>a({path:k.value.path,callback:e=>{k.value.path=e}}),placeholder:e("请选择解压到目录"),width:"240px",icon:"el-folder-opened"},null)}]}),y=m({label:e("密码"),children:[{type:"input",key:"password",attrs:{class:"!w-[280px]",placeholder:e("无密码则留空")}}]}),_=m({formAttrs:{labelWidth:"100px"},formItems:[x.value,j.value,y.value]}),[g,k,w]=s(_);return u((()=>{Object.assign(k.value,{filename:v.compData.fileItem.path,path:v.compData.fileItem.path.replace(v.compData.fileItem.name,""),password:""})})),f({onConfirm:async a=>{await w.value.validate(),setTimeout((()=>i()),10),l({loading:e("正在解压文件，请稍后..."),request:t(k.value),message:!0,success:e=>{e.status&&(b(),a())}})}}),(e,a)=>(d(),c(h(g),{class:"p-20px"}))}});export{f as default};
