import{_ as a}from"./index.vue_vue_type_script_setup_true_lang.js?v=1764233927359";import{_ as e}from"./index99.js?v=1764233927359";import{_ as t}from"./index.vue_vue_type_script_setup_true_lang10.js?v=1764233927359";import{k as l,P as o,r,e as p,R as s,V as i,W as u,a3 as d,l as m,S as n,U as c,v as _}from"./vue.js?v=1764233927359";import{bU as v,go as h}from"./page_layout.js?v=1764233927359";import"./public.js?v=1764233927359";import g from"./index100.js?v=1764233927359";import{dR as b,dV as f}from"./naive.js?v=1764233927359";import"./index98.js?v=1764233927359";import"./__commonjsHelpers__.js?v=1764233927359";import"./common.js?v=1764233927359";import"./theme-monokai.js?v=1764233927359";import"./file.js?v=1764233927359";const j={class:"p-20px"},x={class:"w-100px mr-10px"},k={class:"w-240px"},y={class:"w-350px"},w={class:"w-350px"},D=l({__name:"index",setup(l,{expose:D}){const{t:I}=o(),L=v(),U=r(null),R=p({type:"path",path:"",data:"",tag:""}),$=[{label:I("Docker.LocalImage.build_1"),value:"path"},{label:I("Docker.LocalImage.build_5"),value:"data"}],E={path:{trigger:["blur","input"],validator:()=>"path"!==R.type||""!==R.path.trim()||new Error(I("Docker.LocalImage.build_6"))},data:{trigger:["blur","input"],validator:()=>"data"!==R.type||""!==R.data.trim()||new Error(I("Docker.LocalImage.build_7"))}};return D({onConfirm:async()=>{var a;await(null==(a=U.value)?void 0:a.validate());const e="path"===R.type?{path:R.path,tag:R.tag}:{data:R.data,tag:R.tag};await h(e),L.setRefresh(!0)}}),(l,o)=>{const r=f,p=t,v=b,h=e,D=a;return i(),s("div",j,[u(D,{ref_key:"formRef",ref:U,model:c(R),rules:E},{default:d(()=>[u(v,{label:l.$t("Docker.LocalImage.build_1"),path:"path"},{default:d(()=>[n("div",x,[u(r,{value:c(R).type,"onUpdate:value":o[0]||(o[0]=a=>c(R).type=a),options:$},null,8,["value"])]),m(n("div",k,[u(p,{value:c(R).path,"onUpdate:value":o[1]||(o[1]=a=>c(R).path=a),placeholder:l.$t("Docker.LocalImage.build_2")},null,8,["value","placeholder"])],512),[[_,"path"===c(R).type]])]),_:1},8,["label"]),m(u(v,{label:" ",path:"data"},{default:d(()=>[n("div",y,[u(g,{value:c(R).data,"onUpdate:value":o[2]||(o[2]=a=>c(R).data=a),lang:"json",theme:"monokai",height:"290","show-tips":!1},null,8,["value"])])]),_:1},512),[[_,"data"===c(R).type]]),u(v,{label:l.$t("Docker.LocalImage.build_3"),"show-feedback":!1},{default:d(()=>[n("div",w,[u(h,{value:c(R).tag,"onUpdate:value":o[3]||(o[3]=a=>c(R).tag=a),rows:3,placeholder:l.$t("Docker.LocalImage.build_4")},null,8,["value","placeholder"])])]),_:1},8,["label"])]),_:1},8,["model"])])}}});export{D as default};
