System.register(["./index-legacy102.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy25.js?v=1753954525509","./public-legacy.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy9.js?v=1753954525509","./page_layout-legacy.js?v=1753954525509","./naive-legacy.js?v=1753954525509","./vue-legacy.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy.js?v=1753954525509","./index.vue_vue_type_script_setup_true_lang-legacy14.js?v=1753954525509","./theme-chrome-legacy.js?v=1753954525509","./__commonjsHelpers__-legacy.js?v=1753954525509","./file-legacy2.js?v=1753954525509","./common-legacy.js?v=1753954525509","./index-legacy96.js?v=1753954525509"],(function(e,a){"use strict";var l,t,n,c,s,r,d,o,u,i,p,_,m,y,k,x,h,v,g,f,j,D,T,b,w,U,C;return{setters:[e=>{l=e._},e=>{t=e._},e=>{n=e.b,c=e.c,s=e.f,r=e._},e=>{d=e._},e=>{o=e.m,u=e.gu,i=e.w,p=e.gv},e=>{_=e._,m=e.ay},e=>{y=e.k,k=e.P,x=e.e,h=e.r,v=e.U,g=e.V,f=e.W,j=e.Q,D=e.a2,T=e.X,b=e.j,w=e.a3,U=e.ah,C=e.N},null,null,null,null,null,null,null],execute:function(){const a={class:"px-16px"},R={class:"flex mb-10px"},$={class:"flex-1"},L={class:"ml-16px"},z={class:"text-error"},P=y({__name:"index",setup(e,{expose:l}){const{t:t}=k(),y=x({path:"",checked:!1}),P=h([]),{keys:S,table:B,columns:H}=n([{type:"selection",width:40},{key:"project_name",title:t("Docker.Template.add.index_9")},{key:"conf_file",title:t("Docker.Template.add.index_10")},{key:"remark",title:t("Docker.Template.add.index_3")}]),{loading:K,setLoading:N}=c(),Q=async()=>{if(""!==y.path.trim())try{N(!0);const{message:e}=await u({path:y.path,sub_dir:y.checked?"1":"0"});B.data=i(e)?e:[]}finally{S.value=[],P.value=[],N(!1)}else o.error(t("Docker.Template.add.index_11"))},V=(e,a)=>{P.value=a};return l({onConfirm:async()=>{0!==P.value.length?await p({template_list:C(P.value)}):o.error(t("Docker.Template.add.index_12"))}}),(e,l)=>{const t=_,n=d,c=m,o=s,u=r;return v(),g("div",a,[f("div",R,[f("div",$,[j(n,{value:T(y).path,"onUpdate:value":l[1]||(l[1]=e=>T(y).path=e),placeholder:e.$t("Docker.Template.add.index_5")},{suffix:D((()=>[j(t,{checked:T(y).checked,"onUpdate:checked":l[0]||(l[0]=e=>T(y).checked=e),class:"mr-8px"},{default:D((()=>[b(w(e.$t("Docker.Template.add.index_6")),1)])),_:1},8,["checked"])])),_:1},8,["value","placeholder"])]),f("div",L,[j(c,{type:"primary",onClick:Q},{default:D((()=>[b(w(e.$t("Public.Btn.Search")),1)])),_:1})])]),j(o,{"checked-row-keys":T(S),"onUpdate:checkedRowKeys":[l[2]||(l[2]=e=>U(S)?S.value=e:null),V],"row-key":"project_name",loading:T(K),"loading-num":7,columns:T(H),data:T(B).data},null,8,["checked-row-keys","loading","columns","data"]),j(u,{class:"mt-20px"},{default:D((()=>[f("li",z,w(e.$t("Docker.Template.add.index_8",[T(S).length])),1)])),_:1})])}}}),S={class:"p-16px"};e("default",y({__name:"index",emits:["refresh"],setup(e,{expose:a,emit:n}){const c=n,{t:s}=k(),r=h(),d=h("normal"),o=[{key:"normal",label:s("Docker.Template.add.index_13"),isLazy:!0,data:{onRefresh:()=>{c("refresh")}},component:t},{key:"command",label:s("Docker.Template.add.index_14"),isLazy:!0,data:{onRefresh:()=>{c("refresh")}},component:P}];return a({onConfirm:async()=>{await(r.value?.onConfirm()),c("refresh")}}),(e,a)=>{const t=l;return v(),g("div",S,[j(t,{ref_key:"tabsRef",ref:r,value:T(d),"onUpdate:value":a[0]||(a[0]=e=>U(d)?d.value=e:null),options:o},null,8,["value"])])}}}))}}}));
