import{ab as e,d5 as t,_ as a,d8 as s}from"./page_layout.js?v=1753954525509";import{u as l}from"./public.js?v=1753954525509";import{a as o,_ as i}from"./index.vue_vue_type_script_setup_true_lang13.js?v=1753954525509";import{k as n,P as r,r as d,U as p,V as u,W as m,Q as c,a3 as x,X as _,a2 as v,ah as f,I as w,an as h}from"./vue.js?v=1753954525509";import{aq as g,c3 as j}from"./naive.js?v=1753954525509";import"./common.js?v=1753954525509";import"./__commonjsHelpers__.js?v=1753954525509";const y={class:"p-24px"},S={class:"flex items-center pl-12px"},b={class:"flex-1 ml-14px"},C={class:"text-16px font-bold text-#111"},N={class:"p-10px mt-24px mx-12px bg-#f0f0f0 text-14px"},k={class:"mt-10px"},R=n({__name:"index",props:{data:{}},setup(n,{expose:R}){const{t:T}=r(),U=n,{rows:z}=U.data,D=e(),$=t(),q=d(null),H=d(""),I=d(!1),P=d("");let Q=null;const V=e=>{h((()=>{(e=>{var t;P.value=e,I.value=!0,null==(t=q.value)||t.focus(),Q&&clearTimeout(Q),Q=window.setTimeout((()=>{I.value=!1}),3e3)})(e)}))()},W=async(e,t=!1)=>await s({project_name:e.name},t),X=e=>{l({title:T("Site.Cert.index_56"),hideClose:!0,component:o,data:{title:T("Site.Cert.index_56"),api:W,data:z,callback:t=>{e(),A(t)}}})},A=e=>{$.setRefresh(!0),l({title:T("Site.DelSite.index_11"),width:440,footer:!0,component:i,data:{title:T("Site.Cert.index_56"),data:e,status:"done",columns:[{key:"name",title:T("Site.TableRow.index_1"),ellipsis:{tooltip:{width:"trigger"}}}]}})};return R({onConfirm:async({hide:e})=>""==H.value?(V(T("Site.DelSite.ContentText5")),!1):H.value!==T("Node.index_41")?(V(T("Node.index_38")),!1):(await(async e=>{1===z.length?(await W(z[0],!0),$.setRefresh(!0),null==e||e()):X(e)})(e),void e())}),(e,t)=>{const s=a,l=g,o=j;return p(),u("div",y,[m("div",S,[c(s,{name:"base-warning",size:"34",color:"#f0a020"}),m("div",b,[m("div",C,[m("div",null,x(e.$t("Node.index_39")),1)])])]),m("div",N,[m("div",null,x(e.$t("Node.index_40",[_(T)("Node.index_41")])),1),m("div",k,[c(o,{show:_(I),"onUpdate:show":t[1]||(t[1]=e=>f(I)?I.value=e:null),trigger:"manual",placement:"top-start","arrow-point-to-center":!0,style:w({"--n-color":_(D).errorColor,"--n-text-color":"#fff"})},{trigger:v((()=>[c(l,{ref_key:"inputRef",ref:q,value:_(H),"onUpdate:value":t[0]||(t[0]=e=>f(H)?H.value=e:null),size:"small",placeholder:""},null,8,["value"])])),default:v((()=>[m("div",null,x(_(P)),1)])),_:1},8,["show","style"])])])])}}});export{R as default};
