import{d as p,J as u,K as b,b as y,t as g,z as _}from"./registerWidgets.cecc7add.js";import{a as w}from"./asyncComputed.08fdcc30.js";import"./gateway.c00982e9.js";import{M as s}from"./member.dedd26d1.js";import"./index.d9da78e8.js";import{C as I}from"./CrudView.48449181.js";import"./passwordlessManager.8b0c672e.js";import"./pubsub.a43e35aa.js";import"./activeRecord.2a9ab687.js";import"./DropdownMenu.4df8c96d.js";import"./Modal.4485a18b.js";import"./LoadingIndicator.06d4594a.js";import"./lottie.79ce2fdf.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]="c5e1933b-c897-405c-afae-d2f7766fefc3",e._sentryDebugIdIdentifier="sentry-dbid-c5e1933b-c897-405c-afae-d2f7766fefc3")}catch{}})();const K=p({__name:"Members",setup(e){const o=u().params.organizationId,i=[{key:"email",label:"Email"}],m=async t=>{await s.create(o,t.email),d()},{loading:l,result:c,refetch:d}=w(()=>s.list(o)),f=b(()=>{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:_(l),title:"Organization members",description:"List all organization members.","empty-title":"No members yet",table:f.value,"create-button-text":"Add members",fields:i,onCreate:m},null,8,["loading","table"]))}});export{K as default};
//# sourceMappingURL=Members.a6f34ee7.js.map
