import{E as e,Tt as t,n}from"./vue-vendor-DMUmTARL.js";import{O as r,f as i}from"./admin-setting-Cf6ZvkT2.js";import{t as a}from"./dns-CGv0i6_J.js";var o=n(`dns-health`,()=>{let n=t(null),o=t(!1),s=t(!1);return{dnsStatus:n,loaded:o,hasWarning:e(()=>n.value?[`fail`,`warn`].includes(n.value.lastCheckStatus):!1),loginNotifyDisabled:e(()=>n.value?.loginNotifyDisabled===!0),notifiedThisSession:s,fetchStatus:()=>i().then(e=>{n.value=a(e.data),o.value=!0}).catch(e=>{console.error(`获取系统设置中的 DNS 状态失败:`,e)}),updateStatus:e=>{n.value=a(e),o.value=!0},setLoginNotifyDisabled:e=>r(e).then(e=>{n.value=a(e.data),o.value=!0}).catch(e=>{throw console.error(`更新 DNS 登录提醒开关失败:`,e),e})}});export{o as t};