diff --git a/ui/litellm-dashboard/src/components/navbar.test.tsx b/ui/litellm-dashboard/src/components/navbar.test.tsx index 9d80a89f83e..4ea2f665fbd 100644 --- a/ui/litellm-dashboard/src/components/navbar.test.tsx +++ b/ui/litellm-dashboard/src/components/navbar.test.tsx @@ -269,6 +269,13 @@ describe("Navbar", () => { expect(screen.queryByRole("button", { name: /^notifications$/i })).not.toBeInTheDocument(); }); + it("should keep the theme toggle on public pages", () => { + const publicPageProps = { ...defaultProps, isPublicPage: true }; + renderWithProviders(); + + expect(screen.getByRole("button", { name: /^theme$/i })).toBeInTheDocument(); + }); + it("should handle hide new feature indicators toggle", async () => { const user = userEvent.setup(); diff --git a/ui/litellm-dashboard/src/components/navbar.tsx b/ui/litellm-dashboard/src/components/navbar.tsx index 8bc9b06969e..7c823301a87 100644 --- a/ui/litellm-dashboard/src/components/navbar.tsx +++ b/ui/litellm-dashboard/src/components/navbar.tsx @@ -123,7 +123,7 @@ const Navbar: React.FC = ({ )} - + {showWorkerSwitch && ( @@ -144,17 +144,19 @@ const Navbar: React.FC = ({ )} - {!isPublicPage && ( - - - - - - - - + + + + {!isPublicPage && ( + <> + + + + + > + )} - )} +