import{u as e,l as s,x as a,M as t,A as i,a7 as o}from"./utils-lib.js?v=20260328163632";import{am as l}from"./site.js?v=20260328163632";import{u}from"./index.vue_vue_type_script_setup_true_lang9.js?v=20260328163632";import{B as p}from"./index118.js?v=20260328163632";import{k as r,i as m,a9 as n,r as c,o as _,b as d,V as j,W as v,O as x,Y as f}from"./base-lib.js?v=20260328163632";import"./naive-ui.js?v=20260328163632";import"./__commonjsHelpers__.js?v=20260328163632";import"./env-lib.js?v=20260328163632";import"./index84.js?v=20260328163632";import"./store4.js?v=20260328163632";import"./useMethod4.js?v=20260328163632";import"./index.vue_vue_type_script_setup_true_lang10.js?v=20260328163632";import"./index158.js?v=20260328163632";import"./ace.js?v=20260328163632";import"./index91.js?v=20260328163632";import"./index88.js?v=20260328163632";import"./logs.js?v=20260328163632";const g={class:"flex flex-col"},T=r({__name:"index",props:{compData:{default:()=>({log_file:"",uuid:""})}},setup(r){const T=r,y=m("popupClose",(()=>{})),{panel:b}=e(),{paths:D}=n(b.value),{isRefreshSSL:h}=u(),S=c(s("正在申请证书...")),R=c(),C=c({count:0,limit:999999,log_end:!0,maxPage:200,page:1}),E=async(e="")=>{clearTimeout(R.value);try{await a({request:l({path:T.compData.log_file||D.value.panel+"/logs/letsencrypt.log",limit:C.value.limit,orderby:!0,p:C.value.page}),success:async a=>{S.value=e+a.data.data.join("\n"),Object.assign(C.value,a.data.page),S.value.includes("Successfully")?(t.success(s("部署成功，2s后关闭日志")),setTimeout((()=>{h.value=!0,y()}),2e3)):S.value.includes("START_CHECK_DNS_RECORDS")?(await i({title:s("手动解析TXT记录"),component:()=>o((()=>import("./index235.js?v=20260328163632")),[],import.meta.url),area:700,compData:{uuid:T.compData.uuid}}),y()):R.value=setTimeout((()=>{E(e)}),2e3)}})}catch(u){}};return _((()=>{E()})),d((()=>{clearTimeout(R.value),S.value=s("正在申请证书，请稍候...")})),(e,s)=>(j(),v("div",g,[x(p,{content:f(S),isHtml:!0,class:"!h-410px"},null,8,["content"])]))}});export{T as default};
