import{o as i,i as f,g as t,f as s,u as a,a as e,k as m,t as v,c as h,b as x,J as g}from"./app-a39c937f.js";import{h as r,G as w,V as y,U as _,S as b}from"./transition-37a067aa.js";const k={class:"fixed inset-0 overflow-y-auto"},B={class:"flex min-h-full items-center justify-center p-4 text-center"},V={class:"flex justify-between items-center bg-gray-50 px-4 py-3"},S={class:"px-4 pb-4"},j={__name:"Modal",props:{label:String,isOpen:Boolean,closeBtn:Boolean},emits:["close"],setup(l,{emit:c}){const n=l,d=c;function p(){d("close",!0)}return(u,o)=>(i(),f(a(b),{appear:"",show:n.isOpen,as:"template"},{default:t(()=>[s(a(_),{as:"div",class:"relative z-10"},{default:t(()=>[s(a(r),{as:"template",enter:"duration-300 ease-out","enter-from":"opacity-0","enter-to":"opacity-100",leave:"duration-200 ease-in","leave-from":"opacity-100","leave-to":"opacity-0"},{default:t(()=>o[0]||(o[0]=[e("div",{class:"fixed inset-0 bg-black bg-opacity-25"},null,-1)])),_:1}),e("div",k,[e("div",B,[s(a(r),{as:"template",enter:"duration-300 ease-out","enter-from":"opacity-0 scale-95","enter-to":"opacity-100 scale-100",leave:"duration-200 ease-in","leave-from":"opacity-100 scale-100","leave-to":"opacity-0 scale-95"},{default:t(()=>[s(a(w),{class:"w-full max-w-md transform overflow-hidden rounded-2xl bg-white text-left align-middle shadow-xl transition-all"},{default:t(()=>[e("div",V,[s(a(y),{as:"h3",class:"text-lg font-medium leading-6 text-gray-900"},{default:t(()=>[m(v(n.label),1)]),_:1}),l.closeBtn===!0?(i(),h("span",{key:0,onClick:p,class:"bg-slate-100 rounded-full p-1 hover:shadow cursor-pointer"},o[1]||(o[1]=[e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},[e("path",{fill:"none",stroke:"black","stroke-linecap":"round","stroke-linejoin":"round",d:"M17 7L7 17M7 7l10 10"})],-1)]))):x("",!0)]),e("div",S,[g(u.$slots,"default")])]),_:3})]),_:3})])])]),_:3})]),_:3},8,["show"]))}};export{j as _};
