import"./rolldown-runtime-BM3Ffeng.js";import{ot as e}from"./element-plus-vendor-BF9PNysW.js";import{A as t,D as n,E as r,N as i,P as a,Pt as o,Xt as s,et as c,ht as l,qt as u}from"./vue-vendor-DMUmTARL.js";import{Di as d}from"./icons-vendor-Db5MGAkr.js";var f={class:`mb-4 flex flex-col items-start gap-3 rounded border border-gray-100 bg-gray-50 px-4 py-3 dark:border-white/10 dark:bg-white/5 sm:flex-row sm:items-center sm:justify-between sm:gap-2`},p={class:`flex flex-wrap items-center gap-2 text-sm text-regular`},m={class:`flex items-center gap-1.5 font-bold`},h={key:0},g={key:1},_={__name:`AuditStatusBar`,props:{config:{type:Object,required:!0},options:{type:Object,required:!0}},emits:[`open-config`],setup(_){let v=_,y=r(()=>(v.config.auditLogDisabledTypes||[]).length),b=r(()=>(v.config.auditLogDisabledActions||[]).length),x=r(()=>y.value+b.value);return(r,v)=>{let S=e;return c(),t(`div`,f,[n(`div`,p,[n(`span`,m,[n(`span`,{class:u([`inline-block h-2 w-2 rounded-full`,_.config.auditLogEnabled?`bg-green-500`:`bg-gray-300`])},null,2),n(`span`,null,s(_.config.auditLogEnabled?`已启用`:`已关闭`),1)]),v[1]||=n(`span`,{class:`text-gray-300 dark:text-gray-600`},`·`,-1),n(`span`,null,`保留 `+s(_.config.auditLogRetentionDays||`-`)+` 天`,1),v[2]||=n(`span`,{class:`text-gray-300 dark:text-gray-600`},`·`,-1),o(x)===0?(c(),t(`span`,h,`无屏蔽`)):(c(),t(`span`,g,`已屏蔽 `+s(o(y))+` 类 / `+s(o(b))+` 动作`,1))]),a(S,{class:`w-full sm:w-auto`,size:`small`,icon:o(d),onClick:v[0]||=e=>r.$emit(`open-config`)},{default:l(()=>[...v[3]||=[i(` 审计设置 `,-1)]]),_:1},8,[`icon`])])}}};export{_ as default};