import{E as e,G as t,V as n,_t as r,b as i,g as a,q as o,v as s,vt as c}from"./CcHu_7lQ.js";var l=[`type`,`disabled`],u={key:0,class:`loading loading-spinner`},d=Object.assign(e({__name:`Button`,props:{type:{default:`button`},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},icon:{},class:{}},emits:[`click`],setup(e){let d=e,f=a(()=>d.class||``),p=a(()=>f.value.includes(`btn-`));return(a,d)=>(n(),i(`button`,{type:e.type,class:c([`inline-flex items-center justify-center gap-2`,[r(p)&&`btn`,r(f),e.loading&&`btn-disabled cursor-wait`]]),disabled:e.disabled||e.loading,onClick:d[0]||=e=>a.$emit(`click`,e)},[e.loading?(n(),i(`div`,u)):e.icon?(n(),s(o(e.icon),{key:1})):t(a.$slots,`default`,{key:2})],10,l))}}),{__name:`Button`});export{d as t};