import Link from "next/link"; import { observer } from "mobx-react-lite"; import { MoveLeft, Plus, UserPlus } from "lucide-react"; // mobx store import { useMobxStore } from "lib/mobx/store-provider"; // ui import { Tooltip } from "@plane/ui"; const SIDEBAR_LINKS = [ { key: "create-workspace", Icon: Plus, name: "Create workspace", href: "/create-workspace", }, { key: "invitations", Icon: UserPlus, name: "Invitations", href: "/invitations", }, ]; export const ProfileLayoutSidebar = observer(() => { const { theme: { sidebarCollapsed, toggleSidebar }, workspace: { workspaces }, } = useMobxStore(); return (
{SIDEBAR_LINKS.map((link) => (
{} {!sidebarCollapsed && link.name}
))}
{workspaces && workspaces.length > 0 && (
{!sidebarCollapsed && (
Your workspaces
)}
{workspaces.map((workspace) => ( {workspace?.logo && workspace.logo !== "" ? ( Workspace Logo ) : ( workspace?.name?.charAt(0) ?? "..." )} {!sidebarCollapsed && (

{workspace.name}

)}
))}
)}
); });