import{d as u,K as f,b as y,t as g,z as s,J as _}from"./registerWidgets.29e41a54.js";import{a as w}from"./asyncComputed.0126d7e4.js";import"./gateway.dfba55d6.js";import{M as i}from"./member.75a22a37.js";import{C as I}from"./CrudView.3bd8b7de.js";import"./passwordlessManager.88f105f1.js";import"./activeRecord.d63d0be1.js";import"./DropdownMenu.7bd7adf5.js";import"./CircularLoading.0d1cd4f5.js";import"./Modal.7746640d.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},a=new Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="7bbd1366-3c02-478b-9a3a-949bcb6ba3da",e._sentryDebugIdIdentifier="sentry-dbid-7bbd1366-3c02-478b-9a3a-949bcb6ba3da")}catch{}})();const R=u({__name:"Members",setup(e){const o=_().params.organizationId,m=[{key:"email",label:"Email"}],l=async t=>{await i.create(o,t.email),b()},{loading:d,result:c,refetch:b}=w(()=>i.list(o)),p=f(()=>{var t,r;return{columns:[{name:"Email"},{name:"Role"}],rows:(r=(t=c.value)==null?void 0:t.map(n=>({key:n.email,cells:[{text:n.email,classes:["title","centered"]},{text:n.role,classes:["centered"]}]})))!=null?r:[]}});return(t,r)=>(y(),g(I,{"entity-name":"members",loading:s(d),title:"Organization members",description:"List all organization members.","empty-title":"No members yet",table:s(p),"create-button-text":"Add members",fields:m,onCreate:l},null,8,["loading","table"]))}});export{R as default};
//# sourceMappingURL=Members.f9c44412.js.map
