System.register(["./index-legacy107.js?v=1763625242172","./index.vue_vue_type_script_setup_true_lang-legacy24.js?v=1763625242172","./public-legacy.js?v=1763625242172","./index.vue_vue_type_script_setup_true_lang-legacy10.js?v=1763625242172","./page_layout-legacy.js?v=1763625242172","./naive-legacy.js?v=1763625242172","./vue-legacy.js?v=1763625242172","./index.vue_vue_type_script_setup_true_lang-legacy.js?v=1763625242172","./index-legacy100.js?v=1763625242172","./theme-monokai-legacy.js?v=1763625242172","./__commonjsHelpers__-legacy.js?v=1763625242172","./file-legacy.js?v=1763625242172","./common-legacy.js?v=1763625242172","./index-legacy98.js?v=1763625242172"],(function(e,a){"use strict";var l,t,n,c,s,d,r,o,i,u,p,_,m,y,k,x,h,v,f,g,j,D,T,b,w,C,R;return{setters:[e=>{l=e._},e=>{t=e._},e=>{n=e.c,c=e.d,s=e.h,d=e._},e=>{r=e._},e=>{o=e.m,i=e.hB,u=e.x,p=e.hC},e=>{_=e._,m=e.aC},e=>{y=e.k,k=e.P,x=e.e,h=e.r,v=e.R,f=e.S,g=e.U,j=e.X,D=e.a3,T=e.V,b=e.j,w=e.a4,C=e.aj,R=e.N},null,null,null,null,null,null,null],execute:function(){const a={class:"px-16px"},U={class:"flex mb-10px"},$={class:"flex-1"},L={class:"ml-16px"},S={class:"text-error"},z=y({__name:"index",setup(e,{expose:l}){const{t:t}=k(),y=x({path:"",checked:!1}),z=h([]),{keys:B,table:P,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(),V=async()=>{if(""!==y.path.trim())try{N(!0);const{message:e}=await i({path:y.path,sub_dir:y.checked?"1":"0"});P.data=u(e)?e:[]}finally{B.value=[],z.value=[],N(!1)}else o.error(t("Docker.Template.add.index_11"))},X=(e,a)=>{z.value=a};return l({onConfirm:async()=>{0!==z.value.length?await p({template_list:R(z.value)}):o.error(t("Docker.Template.add.index_12"))}}),(e,l)=>{const t=_,n=r,c=m,o=s,i=d;return v(),f("div",a,[g("div",U,[g("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"])]),g("div",L,[j(c,{type:"primary",onClick:V},{default:D((()=>[b(w(e.$t("Public.Btn.Search")),1)])),_:1})])]),j(o,{"checked-row-keys":T(B),"onUpdate:checkedRowKeys":[l[2]||(l[2]=e=>C(B)?B.value=e:null),X],"row-key":"project_name",loading:T(K),"loading-num":7,columns:T(H),data:T(P).data},null,8,["checked-row-keys","loading","columns","data"]),j(i,{class:"mt-20px"},{default:D((()=>[g("li",S,w(e.$t("Docker.Template.add.index_8",[T(B).length])),1)])),_:1})])}}}),B={class:"p-16px"};e("default",y({__name:"index",emits:["refresh"],setup(e,{expose:a,emit:n}){const c=n,{t:s}=k(),d=h(),r=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:z}];return a({onConfirm:async()=>{await(d.value?.onConfirm()),c("refresh")}}),(e,a)=>{const t=l;return v(),f("div",B,[j(t,{ref_key:"tabsRef",ref:d,value:T(r),"onUpdate:value":a[0]||(a[0]=e=>C(r)?r.value=e:null),options:o},null,8,["value"])])}}}))}}}));
