const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["js/set-ttl.js?v=1764233927359","js/index.vue_vue_type_script_setup_true_lang.js?v=1764233927359","js/vue.js?v=1764233927359","js/__commonjsHelpers__.js?v=1764233927359","js/naive.js?v=1764233927359","js/common.js?v=1764233927359","js/utils3.js?v=1764233927359","js/page_layout.js?v=1764233927359","js/public.js?v=1764233927359","css/public.css?v=1764233927359","css/page_layout.css?v=1764233927359"])))=>i.map(i=>d[i]);
import{t as e,d as a,m as t,i as s,a as l,dp as n,dq as o,dr as r,ds as i,da as c}from"./page_layout.js?v=1764233927359";import{u,a as p}from"./public.js?v=1764233927359";import{a as d}from"./soft.js?v=1764233927359";import{k as f,r as m,P as w,w as h,o as y,G as v,R as g,V as x,U as b,n as D,_ as S,W as C,F as P,j,u as _}from"./vue.js?v=1764233927359";import{da as T,dV as M,dT as k,dU as A}from"./naive.js?v=1764233927359";const I=["innerHTML"],R=f({__name:"index",props:{path:{type:String,default:"/www/server/panel/logs/letsencrypt.log"},callBack:{type:Function,default:()=>{}}},emits:["close"],setup(s,{emit:l}){const n=m("Please wait..."),o=m(null),{t:r}=w(),i=s,c=l,u=async()=>{const{message:s}=await e({path:i.path});a(s)&&(n.value=s.data?s.data:"None",s.data.includes("aaPanelDns Service Success!")&&(t.success(r("Waf.Block.index_75")),i.callBack(),c("close")))};u();h(n,async()=>{await D(),(()=>{const e=o.value;e&&(e.scrollTop=e.scrollHeight)})()});let p=null;return y(()=>{p=setInterval(()=>{u()},1e3)}),v(()=>{p&&clearInterval(p)}),(e,a)=>(x(),g("pre",{ref_key:"logRef",ref:o,innerHTML:b(n),class:"h-full overflow-auto bg-black text-white p-10px whitespace-pre-wrap"},null,8,I))}});const{t:L}=s.global,N=async()=>{const e=m("none"),a=[{label:L("Accept all emails"),value:"none"},{label:L("Reject all emails"),value:"reject"}];p({width:500,title:L("Confirm Applying DMARC Policy?"),content:()=>C(P,null,[C("p",null,[L("Enabling this feature will create DMARCDNS records for all domains. If a domain already has a DMARC record, the system will not modify the existing record.")]),C(T,{class:"items-center flex-nowrap! mt-10px"},{default:()=>[C("span",{class:"whitespace-nowrap"},[L("Policy:")]),C(M,{class:"w-320px",value:e.value,"onUpdate:value":a=>e.value=a,options:a,placeholder:L("Select DMARC Policy"),consistentMenuWidth:!1},null)]})]),onConfirm:async()=>{await n({policy:e.value})}})},B=async()=>{p({width:400,title:L("Confirm DKIM/SPF Enabled?"),content:L("After enabling this feature, the system will create DKIM and SPF DNS records for the selected domain. If an SPF record already exists for a domain, the system will appropriately append the servers IP address to the existing record. However, the system will not modify any existing DKIM records. During this process, please do not edit any nameserver configuration files."),onConfirm:async()=>{await o()}})},F=async()=>{p({width:400,title:L("DNS Clear"),content:L("This program will clean up your name server configuration files and remove all duplicate entries. Please ensure that you do not edit any name server configuration files during the cleanup process."),onConfirm:async()=>{await r()}})},H=async()=>{d({title:()=>C(T,{class:"items-center flex-nowrap!",size:5},{default:()=>[C("span",{class:"bg-#4caf50 inline-block w-25px h-25px flex items-center justify-center rounded-5px"},[C("i",{class:"i-soft-dns-icon text-18px text-white"},null)]),C("span",null,[L("DNS Manager")])]}),name:"dnscustom",admin:!0})},U=async(e,a)=>{const t=e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()+" "+L("Self-Built DNS"),s=L("Are you sure you want to {0} a self-built DNS server?",[e]),l=m(0);p({width:400,title:t,content:()=>{let a;return"install"===e?s:C(P,null,[C("p",null,[s]),C(T,{class:"items-center flex-nowrap! mt-10px"},{default:()=>[C("span",null,[L("Preserve config")]),C(k,{value:l.value,"onUpdate:value":e=>l.value=e},{default:()=>{return[C(A,{value:0},(e=a=L("Preserve"),"function"==typeof e||"[object Object]"===Object.prototype.toString.call(e)&&!_(e)?a:{default:()=>[a]})),C(A,{value:1},{default:()=>[j("Don't preserve")]})];var e}})]})])},onConfirm:async()=>{await i({act:e,clean:l.value}),u({title:t,width:500,height:300,hideClose:!0,data:{path:"/www/server/panel/logs/install_pdns.log",callBack:()=>{null==a||a()}},component:R})}})},E=m(!0),K=async()=>{const{message:e}=await c({act:"status"});a(e)&&(E.value=0===e.checker_status)},O=e=>[{key:"setTTL",label:L("Set TTL"),onBatch:a=>{u({title:L("Set TTL"),width:500,minHeight:100,footer:!0,data:{rows:a,refresh:e},component:S(()=>l(()=>import("./set-ttl.js?v=1764233927359"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10])))})}}];export{K as a,N as b,E as c,B as d,F as e,U as f,H as o,O as u};
