import{_ as C,r as b,$ as _,o as l,c as x,aa as a,v as t,y as p,q as n,p as i,C as m,t as u,n as V,s as B,ak as I,bv as S}from"./index.8d733f79.js";const $={class:"preview-content"},D=["src"],E={class:"preview-control"},N={class:"preview-modal"},P={class:"preview-modal-content"},R=["src"],T={__name:"index",props:{src:{type:String,default:""},preview:{type:Boolean,default:!0},remove:{type:Boolean,default:!1},modalTitle:{type:String,default:"\u56FE\u7247\u9884\u89C8"},modalWidth:{type:String,default:"900px"}},emits:["remove"],setup(r,{emit:v}){const e=r,o=b(!1),f=()=>{o.value=!0},w=()=>{v("remove")};return(s,c)=>{const g=_("ZoomIn"),d=I,h=_("Delete"),y=S;return l(),x("div",$,[a(s.$slots,"image",{},()=>[t("img",{class:"preview-container",src:r.src,alt:""},null,8,D)],!0),t("div",E,[e.preview?(l(),p(d,{key:0,class:"btn-control",onClick:m(f,["stop"])},{default:n(()=>[i(g)]),_:1},8,["onClick"])):u("",!0),e.remove?(l(),p(d,{key:1,class:"btn-control",onClick:m(w,["stop"])},{default:n(()=>[i(h)]),_:1},8,["onClick"])):u("",!0)]),i(y,{modelValue:V(o),"onUpdate:modelValue":c[0]||(c[0]=k=>B(o)?o.value=k:null),class:"preview-dialog","append-to-body":!0,title:e.modalTitle,width:e.modalWidth},{default:n(()=>[t("div",N,[a(s.$slots,"default",{src:e.src},()=>[t("div",P,[t("img",{src:e.src,alt:"Preview Image",class:"preview-img"},null,8,R)])],!0),a(s.$slots,"other",{},void 0,!0)])]),_:3},8,["modelValue","title","width"])])}}},Z=C(T,[["__scopeId","data-v-053d3a9b"]]);export{Z as p};
