diff --git a/ui/litellm-dashboard/src/components/navbar.test.tsx b/ui/litellm-dashboard/src/components/navbar.test.tsx index 7b1c4451d7a..5d3c7254ff9 100644 --- a/ui/litellm-dashboard/src/components/navbar.test.tsx +++ b/ui/litellm-dashboard/src/components/navbar.test.tsx @@ -61,6 +61,26 @@ describe("Navbar", () => { expect(screen.getByText("User")).toBeInTheDocument(); }); + it("should render Join Slack button with correct link", () => { + renderWithProviders(); + + const joinSlackLink = screen.getByRole("link", { name: /join slack/i }); + expect(joinSlackLink).toBeInTheDocument(); + expect(joinSlackLink).toHaveAttribute("href", "https://www.litellm.ai/support"); + expect(joinSlackLink).toHaveAttribute("target", "_blank"); + expect(joinSlackLink).toHaveAttribute("rel", "noopener noreferrer"); + }); + + it("should render Star us on GitHub button with correct link", () => { + renderWithProviders(); + + const starOnGithubLink = screen.getByRole("link", { name: /star us on github/i }); + expect(starOnGithubLink).toBeInTheDocument(); + expect(starOnGithubLink).toHaveAttribute("href", "https://github.com/BerriAI/litellm"); + expect(starOnGithubLink).toHaveAttribute("target", "_blank"); + expect(starOnGithubLink).toHaveAttribute("rel", "noopener noreferrer"); + }); + it("should display user information in dropdown", async () => { const user = userEvent.setup(); renderWithProviders(); diff --git a/ui/litellm-dashboard/src/components/navbar.tsx b/ui/litellm-dashboard/src/components/navbar.tsx index 0ef8a505257..6dac073b3a6 100644 --- a/ui/litellm-dashboard/src/components/navbar.tsx +++ b/ui/litellm-dashboard/src/components/navbar.tsx @@ -11,15 +11,17 @@ import { import { fetchProxySettings } from "@/utils/proxyUtils"; import { CrownOutlined, + GithubOutlined, LogoutOutlined, MailOutlined, MenuFoldOutlined, MenuUnfoldOutlined, SafetyOutlined, + SlackOutlined, UserOutlined, } from "@ant-design/icons"; import type { MenuProps } from "antd"; -import { Dropdown, Switch, Tooltip } from "antd"; +import { Button, Dropdown, Switch, Tooltip } from "antd"; import Link from "next/link"; import React, { useEffect, useState } from "react"; @@ -207,6 +209,24 @@ const Navbar: React.FC = ({ {/* Right side nav items */} + } + className="shadow-md shadow-indigo-500/20 hover:shadow-indigo-500/50 transition-shadow" + > + Join Slack + + } + > + Star us on GitHub +