mirror of
https://github.com/urbit/shrub.git
synced 2024-11-24 13:06:09 +03:00
parent
bef97699e2
commit
5c84ba514f
@ -77,7 +77,7 @@ export function GroupSwitcher(props: {
|
||||
baseUrl: string;
|
||||
recentGroups: string[];
|
||||
}) {
|
||||
const { associations, workspace } = props;
|
||||
const { associations, workspace, isAdmin } = props;
|
||||
const title = getTitleFromWorkspace(associations, workspace);
|
||||
const navTo = (to: string) => `${props.baseUrl}${to}`;
|
||||
return (
|
||||
@ -152,14 +152,14 @@ export function GroupSwitcher(props: {
|
||||
/>
|
||||
<Text> Group Settings</Text>
|
||||
</GroupSwitcherItem>
|
||||
<GroupSwitcherItem bottom to={navTo("/invites")}>
|
||||
{isAdmin && (<GroupSwitcherItem bottom to={navTo("/invites")}>
|
||||
<Icon
|
||||
mr={2}
|
||||
color="blue"
|
||||
icon="Users"
|
||||
/>
|
||||
<Text color="blue">Invite to group</Text>
|
||||
</GroupSwitcherItem>
|
||||
</GroupSwitcherItem>)}
|
||||
</>
|
||||
)}
|
||||
</Col>
|
||||
@ -173,15 +173,15 @@ export function GroupSwitcher(props: {
|
||||
</Row>
|
||||
</Dropdown>
|
||||
<Row pr={1} justifyContent="flex-end" alignItems="center">
|
||||
{workspace.type === "group" && (
|
||||
{(workspace.type === "group") && (
|
||||
<>
|
||||
<Link to={navTo("/invites")}>
|
||||
{isAdmin && (<Link to={navTo("/invites")}>
|
||||
<Icon
|
||||
display="block"
|
||||
color='blue'
|
||||
icon="Users"
|
||||
/>
|
||||
</Link>
|
||||
</Link>)}
|
||||
<Link to={navTo("/popover/settings")}>
|
||||
<Icon color='gray' display="block" m={2} icon="Gear" />
|
||||
</Link>
|
||||
|
@ -119,6 +119,7 @@ export function Sidebar(props: SidebarProps) {
|
||||
associations={associations}
|
||||
recentGroups={props.recentGroups}
|
||||
baseUrl={props.baseUrl}
|
||||
isAdmin={isAdmin}
|
||||
workspace={props.workspace}
|
||||
/>
|
||||
<SidebarListHeader
|
||||
|
Loading…
Reference in New Issue
Block a user