import{l as V,b1 as j,cZ as k,p as h}from"./index-BTglIPU2.js?v=1773287522785";import{u as M}from"./new-BrUBzLDd.js?v=1773287522785";import{a as U,_ as Z}from"./index.vue_vue_type_script_setup_true_lang-zxYX_mVh.js?v=1773287522785";import{k as A,R as E,r,$ as F,Z as H,_ as n,a0 as u,aa as c,S as a,a9 as w,X as S,H as I}from"./vue-core-DJjvd5ZC.js?v=1773287522785";import{u as P,b as X,a5 as q}from"./naive-ui--dJnpVcV.js?v=1773287522785";import"./prismjs-BZPoR7_J.js?v=1773287522785";import"./index-COOnaZWq.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-DgjjuUjT.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-B7YvCBmY.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-C5hb-Th7.js?v=1773287522785";import"./data-BVsViUMm.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-HxsqzSKU.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-BeO8Hyma.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-D2Bk83Ev.js?v=1773287522785";import"./useLoading-CZ2gSAW7.js?v=1773287522785";import"./useTableData-BmkIKQ_R.js?v=1773287522785";import"./useTableColumns-DDeyYvje.js?v=1773287522785";import"./index-S15tYq5l.js?v=1773287522785";import"./copy-D-wIKr0q.js?v=1773287522785";import"./index-DIKmrNCq.js?v=1773287522785";import"./index.vue_vue_type_script_setup_true_lang-DeTfbeeM.js?v=1773287522785";import"./index-Cg6fMjw6.js?v=1773287522785";import"./php-D3q5Oj7O.js?v=1773287522785";const G={class:"p-24px"},J={class:"flex items-center pl-12px"},K={class:"flex-1 ml-14px"},L={class:"text-16px font-bold text-font1"},O={class:"p-10px mt-24px mx-12px text-14px",style:{backgroundColor:"var(--site-confirm-calc-box-bg)"}},Q={class:"mt-10px"},Ce=A({__name:"index",props:{data:{}},setup(g,{expose:C}){const{t:o}=E(),y=g,{rows:l}=y.data,N=P(),d=M(),_=r(null),s=r(""),i=r(!1),f=r("");let p=null;const D=e=>{var t;f.value=e,i.value=!0,(t=_.value)==null||t.focus(),p&&clearTimeout(p),p=window.setTimeout(()=>{i.value=!1},3e3)},x=e=>{j(()=>{D(e)})()},b=async e=>{l.length===1?(await v(l[0],!0),d.setRefresh(!0),e==null||e()):R(e)},v=async(e,t=!1)=>await k({project_name:e.name},t),R=e=>{h({title:o("Site.Cert.index_56"),hideClose:!0,component:U,data:{title:o("Site.Cert.index_56"),api:v,data:l,callback:t=>{e(),T(t)}}})},T=e=>{d.setRefresh(!0),h({title:o("Site.DelSite.index_11"),width:440,footer:!0,component:Z,data:{title:o("Site.Cert.index_56"),data:e,status:"done",columns:[{key:"name",title:o("Site.TableRow.index_1"),ellipsis:{tooltip:{width:"trigger"}}}]}})};return C({onConfirm:async({hide:e})=>{if(s.value=="")return x(o("Site.DelSite.ContentText5")),!1;if(s.value!==o("Node.index_41"))return x(o("Node.index_38")),!1;await b(e),e()}}),(e,t)=>{const $=V,B=X,z=q;return F(),H("div",G,[n("div",J,[u($,{name:"base-warning",size:"34",color:"#f0a020"}),n("div",K,[n("div",L,[n("div",null,c(e.$t("Node.index_39")),1)])])]),n("div",O,[n("div",null,c(e.$t("Node.index_40",[a(o)("Node.index_41")])),1),n("div",Q,[u(z,{show:a(i),"onUpdate:show":t[1]||(t[1]=m=>S(i)?i.value=m:null),trigger:"manual",placement:"top-start","arrow-point-to-center":!0,style:I({"--n-color":a(N).errorColor,"--n-text-color":"#fff"})},{trigger:w(()=>[u(B,{ref_key:"inputRef",ref:_,value:a(s),"onUpdate:value":t[0]||(t[0]=m=>S(s)?s.value=m:null),size:"small",placeholder:""},null,8,["value"])]),default:w(()=>[n("div",null,c(a(f)),1)]),_:1},8,["show","style"])])])])}}});export{Ce as default};
