From 410cb547d28a1e1df723881e36d5226271d07c33 Mon Sep 17 00:00:00 2001 From: Codex Date: Wed, 26 Aug 2026 20:08:25 +0200 Subject: [PATCH] fix(frontend): show database management entry to local users --- .../AppShell.database-management.test.tsx | 4 +-- frontend/src/shell/AppShell.tsx | 30 +++++++++---------- 2 files changed, 16 insertions(+), 18 deletions(-) diff --git a/frontend/src/shell/AppShell.database-management.test.tsx b/frontend/src/shell/AppShell.database-management.test.tsx index 1ccb08bc..986b3c28 100644 --- a/frontend/src/shell/AppShell.database-management.test.tsx +++ b/frontend/src/shell/AppShell.database-management.test.tsx @@ -121,7 +121,7 @@ test("keeps a live core session connected and returns when that session is opene expect(FakeEventSource.instances).toHaveLength(1); }); -test("hides database management from users without workspace management permission", () => { +test("shows database management entry to authenticated users without workspace management permission", () => { clearAuthState(); setAuthState({ issuer: "test", @@ -135,5 +135,5 @@ test("hides database management from users without workspace management permissi renderShell(); - expect(screen.queryByRole("button", { name: "Database management" })).not.toBeInTheDocument(); + expect(screen.getByRole("button", { name: "Database management" })).toBeInTheDocument(); }); diff --git a/frontend/src/shell/AppShell.tsx b/frontend/src/shell/AppShell.tsx index 17bcd602..71d43a93 100644 --- a/frontend/src/shell/AppShell.tsx +++ b/frontend/src/shell/AppShell.tsx @@ -745,22 +745,20 @@ export function AppShell({ canLogout }: AppShellProps) { > Workspace management - {canManageWorkspace && ( - - )} + {canManagePi && (