From d661a959a778c12e47678ee43234ad55e0007c3b Mon Sep 17 00:00:00 2001 From: alex-mcgovern Date: Wed, 22 Jan 2025 09:19:33 +0000 Subject: [PATCH] fix: buttons in workspace page --- .../__tests__/system-prompt-editor.test.tsx | 2 +- .../components/system-prompt-editor.tsx | 6 +---- .../components/archive-workspace.tsx | 24 ++++++++++--------- 3 files changed, 15 insertions(+), 17 deletions(-) diff --git a/src/features/workspace-system-prompt/components/__tests__/system-prompt-editor.test.tsx b/src/features/workspace-system-prompt/components/__tests__/system-prompt-editor.test.tsx index c5443804..c05a09c1 100644 --- a/src/features/workspace-system-prompt/components/__tests__/system-prompt-editor.test.tsx +++ b/src/features/workspace-system-prompt/components/__tests__/system-prompt-editor.test.tsx @@ -43,7 +43,7 @@ test("can update system prompt", async () => { await userEvent.type(input, "new prompt from test"); expect(input).toHaveTextContent("new prompt from test"); - await userEvent.click(getByRole("button", { name: /save changes/i })); + await userEvent.click(getByRole("button", { name: /Save/i })); server.use( http.get("*/api/v1/workspaces/:name/system-prompt", () => { diff --git a/src/features/workspace-system-prompt/components/system-prompt-editor.tsx b/src/features/workspace-system-prompt/components/system-prompt-editor.tsx index a92cb3b8..1ae7d08a 100644 --- a/src/features/workspace-system-prompt/components/system-prompt-editor.tsx +++ b/src/features/workspace-system-prompt/components/system-prompt-editor.tsx @@ -5,7 +5,6 @@ import { CardBody, CardFooter, DarkModeContext, - LinkButton, Loader, Text, } from "@stacklok/ui-kit"; @@ -207,9 +206,6 @@ export function SystemPromptEditor({ - - Cancel - diff --git a/src/features/workspace/components/archive-workspace.tsx b/src/features/workspace/components/archive-workspace.tsx index 5f8f1402..16b5f513 100644 --- a/src/features/workspace/components/archive-workspace.tsx +++ b/src/features/workspace/components/archive-workspace.tsx @@ -13,22 +13,24 @@ export function ArchiveWorkspace({ return ( - - Archive Workspace -
+ +
+ Archive Workspace Archiving this workspace removes it from the main workspaces list, though it can be restored if needed. -
+ +
);