import{b as f,c as l,L as c,r as m}from"./index-D92x6h1h.js";function p(t){const i=m(!1),a=f(),n=l();async function s(o,u){const e=o.map(r=>r.uuid).filter(r=>!!r);if(e.length!==0&&!(t.confirmText&&!await a.ask(t.confirmText,{severity:t.confirmSeverity}))){i.value=!0;try{await c(t.endpoint,{uuid:JSON.stringify(e)}),u()}catch(r){n.error(`${t.failPrefix}: ${r instanceof Error?r.message:String(r)}`)}finally{i.value=!1}}}return{inflight:i,run:s}}export{p as u};
