import e from"./Modal.mjs";import t from"./destroyFns.mjs";import n,{withConfirm as r,withError as i,withInfo as a,withSuccess as o,withWarn as s}from"./confirm.mjs";import c from"./useModal/index.mjs";function l(e){return n(s(e))}e.useModal=c,e.info=function(e){return n(a(e))},e.success=function(e){return n(o(e))},e.error=function(e){return n(i(e))},e.warning=l,e.warn=l,e.confirm=function(e){return n(r(e))},e.addDestroyFn=e=>{t.push(e)},e.delDestroyFn=e=>{for(let n=t.length-1;n>=0;n--)t[n]===e&&t.splice(n,1)},e.destroyAll=function(){for(;t.length;){let e=t.pop();e&&e()}},e.install=function(t){return t.component(e.name,e),t};var u=e;export{u as default};