System.register(["./public-legacy.js?v=1763625242172","./vue-legacy.js?v=1763625242172","./page_layout-legacy.js?v=1763625242172","./site-legacy3.js?v=1763625242172","./naive-legacy.js?v=1763625242172","./common-legacy.js?v=1763625242172","./__commonjsHelpers__-legacy.js?v=1763625242172"],(function(e,a){"use strict";var l,t,i,n,s,u,c,o,r,d,m,f,g,p,y,x,_,v,j,N,C,b,S,h;return{setters:[e=>{l=e.c,t=e.f,i=e.h,n=e._},e=>{s=e.k,u=e.P,c=e.r,o=e.R,r=e.S,d=e.U,m=e.X,f=e.V,g=e.aj,p=e.ak,y=e.a3,x=e.j,_=e.a4},e=>{v=e.x,j=e.m},e=>{N=e.w,C=e.x,b=e.y},e=>{S=e.au,h=e.aC},null,null],execute:function(){const a={class:"p-20px"},k={class:"flex mb-16px"},w={class:"flex-1 mr-16px"},W="disable_ext";e("default",s({__name:"index",props:{siteName:{default:""}},setup(e){const s=e,{t:$}=u(),P=c(""),B=async()=>{""!==P.value.trim()?(await b({siteName:s.siteName,ruleName:W,ruleValue:P.value}),P.value="",D()):j.error($("Waf.Site.Config.index_65"))},{table:U,columns:V,setLoading:A}=l([{key:"rule",title:$("Waf.Site.Config.index_66")},t({width:80,options:(e,a)=>[{label:$("Public.Btn.Del"),onClick:async()=>{await N({index:a,siteName:s.siteName,ruleName:W}),D()}}]})]),D=async()=>{try{A(!0);const{siteName:e}=s,{message:a}=await C({siteName:e,ruleName:W});v(a)&&(U.data=a.map((e=>({rule:e}))))}finally{A(!1)}};return D(),(e,l)=>{const t=S,s=h,u=i,c=n;return o(),r("div",a,[d("div",k,[d("div",w,[m(t,{value:f(P),"onUpdate:value":l[0]||(l[0]=e=>g(P)?P.value=e:null),placeholder:e.$t("Waf.Site.Config.index_103"),onKeyup:p(B,["enter"])},null,8,["value","placeholder"])]),m(s,{type:"primary",onClick:B},{default:y((()=>[x(_(e.$t("Public.Btn.Add")),1)])),_:1})]),m(u,{"max-height":368,loading:f(U).loading,data:f(U).data,columns:f(V)},null,8,["loading","data","columns"]),m(c,{class:"mt-16px"},{default:y((()=>[d("li",null,_(e.$t("Waf.Site.Config.index_63")),1),d("li",null,_(e.$t("Waf.Site.Config.index_64")),1)])),_:1})])}}}))}}}));
