"use strict";(self.webpackChunkweb_app=self.webpackChunkweb_app||[]).push([[5851],{85851:(e,t,n)=>{n.r(t),n.d(t,{default:()=>p});var o=n(65043),l=n(89923),s=n(64159),r=n(20554),c=n(58661),a=n(56629),i=n(53518),u=n(70579);const p=e=>{let{selectedGroups:t,deleteOpen:n,closeDeleteModalAndRefresh:p}=e;const h=(0,r.jL)(),[d,f]=(0,o.useState)(!1);if(!t)return null;const g=t.map((e=>(0,u.jsx)("div",{children:(0,u.jsx)("b",{children:e})},e)));return(0,u.jsx)(c.A,{title:"Delete Group".concat(t.length>1?"s":""),confirmText:"Delete",isOpen:n,titleIcon:(0,u.jsx)(l.xWY,{}),isLoading:d,onConfirm:()=>{for(let e of t)f(!0),a.F.group.removeGroup(e).then((e=>{p(!0)})).catch((async e=>{const t=await e.json();h((0,s.C9)((0,i.S)(t))),p(!1)})).finally((()=>f(!1)))},onClose:()=>p(!1),confirmationContent:(0,u.jsxs)(o.Fragment,{children:["Are you sure you want to delete the following"," ",1===t.length?"":t.length," group",t.length>1?"s?":"?",g]})})}}}]);
//# sourceMappingURL=5851.9aeea951.chunk.js.map