[WEB-1529] chore: workspace sidebar updates. (#4710)

This commit is contained in:
Prateek Shourya 2024-06-07 12:22:30 +05:30 committed by GitHub
parent 9af9268be6
commit d31aaee32c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -16,22 +16,16 @@ import { GOD_MODE_URL } from "@/helpers/common.helper";
import { useAppTheme, useUser, useUserProfile, useWorkspace } from "@/hooks/store";
import { WorkspaceLogo } from "./logo";
// Static Data
const userLinks = (workspaceSlug: string, userId: string) => [
const userLinks = (workspaceSlug: string) => [
{
key: "workspace_invites",
name: "Workspace invites",
href: "/invitations",
icon: Mails,
},
{
key: "my_activity",
name: "My activity",
href: `/${workspaceSlug}/profile/${userId}`,
icon: Activity,
},
{
key: "settings",
name: "Settings",
name: "Workspace settings",
href: `/${workspaceSlug}/settings`,
icon: Settings,
},
@ -211,7 +205,7 @@ export const WorkspaceSidebarDropdown = observer(() => {
Create workspace
</Menu.Item>
</Link>
{userLinks(workspaceSlug?.toString() ?? "", currentUser?.id ?? "").map((link, index) => (
{userLinks(workspaceSlug?.toString() ?? "").map((link, index) => (
<Link
key={link.key}
href={link.href}