import{ap as m,g as c,aq as d,j as e,a4 as h,ar as x,as as o,ae as b,B as u,y as p}from"./index-CfKY7XrC.js";function j(){const{owner:s}=m.useParams(),{isAuthenticated:t,isReady:r}=c(),{isMember:i,isLoading:a}=d();return!r||a?e.jsx(l,{children:e.jsx(h,{label:"members"})}):t?i?e.jsx(x,{to:`/${s}/%24member`,replace:!0}):e.jsx(n,{owner:s,title:"Join to see members",body:"Emails and member details are only visible to members of this workspace. Use the banner above to join."}):e.jsx(n,{owner:s,title:"Sign in to see members",body:"The members of this workspace are only visible to people who have signed in.",ctaLabel:"Sign in",showCta:!0})}function l({children:s}){return e.jsxs("div",{className:"flex flex-1 flex-col gap-6 py-4 px-4 lg:px-6",children:[e.jsx("div",{className:"space-y-2",children:e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(o,{className:"h-7 w-7"}),e.jsx("h1",{className:"text-3xl font-semibold leading-tight",children:"Members"})]})}),s]})}function n({owner:s,title:t,body:r,ctaLabel:i,showCta:a}){return e.jsx(l,{children:e.jsx(b,{icon:o,title:t,description:r,children:i&&a?e.jsx(u,{asChild:!0,className:"mt-4",children:e.jsx(p,{to:"/auth/login",search:{callbackUrl:`/${s}/members`,mode:void 0,error:void 0,errorDescription:void 0,loginHint:void 0,invitationOrg:void 0,intent:"sign-in"},children:i})}):null})})}export{j as component};
