Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
51d076f
feat(site): expose workspace apps in chat workspace pill
DanielleMaywood Apr 13, 2026
057ac8d
test(site): add storybook stories for WorkspacePill
DanielleMaywood Apr 13, 2026
dd3f0be
refactor(site): drop appendChatIdToHref, match AgentRow pattern
DanielleMaywood Apr 13, 2026
da60ae8
chore(site): remove stale-prone comments from WorkspacePill
DanielleMaywood Apr 13, 2026
fd165c9
refactor(site): WorkspacePill owns its status display, eliminate Reac…
DanielleMaywood Apr 13, 2026
f366b30
fix(site): remove stray whitespace expression in ChatTopBar
DanielleMaywood Apr 13, 2026
ba6fda9
fix(site): update AgentChatPage story for meatball menu changes
DanielleMaywood Apr 13, 2026
3441075
refactor(site): use Popover styling from #24308 for WorkspacePill
DanielleMaywood Apr 13, 2026
9689199
refactor(site): move Copy SSH and View Workspace from meatball to pill
DanielleMaywood Apr 13, 2026
6610110
fix(site): flip chevron direction for top popover, suppress tooltip w…
DanielleMaywood Apr 13, 2026
20de227
fix(site): show all workspace apps in pill, not just external ones
DanielleMaywood Apr 13, 2026
9c4be48
fix(site): address self-review findings (separator, overflow, story)
DanielleMaywood Apr 13, 2026
29ae400
fix(site): address review feedback (folder, status indicator, null gu…
DanielleMaywood Apr 13, 2026
0dcd9bd
fix(site): address panel review feedback (dropdown, token guard, stor…
DanielleMaywood Apr 13, 2026
5d6aa30
fix(site): address self-review findings (mutation unmount, disabled s…
DanielleMaywood Apr 13, 2026
559e05b
fix(site): address self-review round 2 (tooltip, alt, folder fallback…
DanielleMaywood Apr 13, 2026
1b186da
refactor(site): inline cls variables and remove workspaceStatusDisplay
DanielleMaywood Apr 13, 2026
19ba116
refactor(site): extract StatusIcon component to deduplicate status ic…
DanielleMaywood Apr 13, 2026
a95bf52
fix(site): address R3 review feedback (shared status, mutation lift, …
DanielleMaywood Apr 14, 2026
831572d
fix(site/src/pages/AgentsPage): add external app disabled assertions,…
DanielleMaywood Apr 14, 2026
6373d75
fix(site/src/pages/AgentsPage): fix WithWorkspace story props, add en…
DanielleMaywood Apr 14, 2026
ef908e8
fix(site/src/pages/AgentsPage): useClipboard, restore Cursor, fix fak…
DanielleMaywood Apr 14, 2026
95d78c5
fix(site/src/pages/AgentsPage): remove builtin Cursor, fix clipboard/…
DanielleMaywood Apr 14, 2026
cff4e04
fix(site/src/pages/AgentsPage): assert href absence on disabled exter…
DanielleMaywood Apr 14, 2026
aedb81c
fix(site/src/pages/AgentsPage): group launch items above separator
DanielleMaywood Apr 14, 2026
ed94b48
fix(site/src/pages/AgentsPage): use consistent app names without Open…
DanielleMaywood Apr 14, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(site): address panel review feedback (dropdown, token guard, stor…
…ies, tests)

- Migrate WorkspacePill from Popover to DropdownMenu for proper a11y
  (role=menu, role=menuitem, arrow-key navigation) (C010)
- Add session token guard to AppMenuItem — disable href until API key
  resolves for apps with $SESSION_TOKEN (C007)
- Remove onDone callbacks — DropdownMenu auto-closes on select (C008)
- Add disabled={isPending} to VSCodeMenuItem button (C009)
- Rename stale WithWorkspaceActions story to WithWorkspace (C011)
- Add play function to NoApps story verifying View Workspace (C012)
- Add hidden app fixture and WithHiddenApp story (C013)
- Add sshCommand to WithAllApps story and assertion (C014)
- Remove unused effectiveType from getWorkspaceStatusDisplay (C015)
- Add vitest for getWorkspaceStatusDisplay branches (C016)
- Conditionally render DropdownMenuSeparator (C017)
- Move badgeCls to module level (C018)
- Rename WorkspaceStatusIndicator.tsx to workspaceStatusDisplay.tsx (C019)
- Align chevron rotation to convention with comment (C020)
- Fix ExternalAppMenuItem typo in story comment (C021)
  • Loading branch information
DanielleMaywood committed Apr 13, 2026
commit 0dcd9bdf762b35a392c88e69b99fbb4144e0d080
11 changes: 0 additions & 11 deletions docs/reference/cli/server.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions site/src/pages/AgentsPage/AgentChatPageView.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,8 @@ export const NoModelOptions: Story = {
),
};

/** Top bar has workspace action buttons visible. */
export const WithWorkspaceActions: Story = {
/** Chat with an attached workspace. */
export const WithWorkspace: Story = {
Comment thread
DanielleMaywood marked this conversation as resolved.
render: () => <StoryAgentChatPageView sshCommand="ssh coder.workspace" />,
};

Expand Down
2 changes: 1 addition & 1 deletion site/src/pages/AgentsPage/AgentChatPageView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import { GitPanel } from "./components/GitPanel/GitPanel";
import { RightPanel } from "./components/RightPanel/RightPanel";
import { SidebarTabView } from "./components/Sidebar/SidebarTabView";
import { TerminalPanel } from "./components/TerminalPanel";
import { getWorkspaceStatusDisplay } from "./components/WorkspaceStatusIndicator";
import { getWorkspaceStatusDisplay } from "./components/workspaceStatusDisplay";
import { ChatWorkspaceContext } from "./context/ChatWorkspaceContext";
import { chatWidthClass, useChatFullWidth } from "./hooks/useChatFullWidth";
import type { ChatDetailError } from "./utils/usageLimitMessage";
Expand Down
64 changes: 60 additions & 4 deletions site/src/pages/AgentsPage/components/WorkspacePill.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,20 @@ const cursorApp: WorkspaceApp = {
icon: "/icon/cursor.svg",
};

const hiddenApp: WorkspaceApp = {
id: "hidden-app",
slug: "hidden-internal",
display_name: "Hidden Internal Tool",
external: false,
url: "",
subdomain: false,
health: "disabled",
sharing_level: "owner",
hidden: true,
open_in: "slim-window",
statuses: [],
};

/** Agent with all built-in display apps and user-configured external apps. */
const agentWithApps = {
...MockWorkspaceAgent,
Expand Down Expand Up @@ -70,6 +84,13 @@ const agentWithExternalOnly = {
apps: [externalApp, cursorApp],
};

/** Agent with a hidden app mixed in to verify filtering. */
const agentWithHiddenApp = {
...MockWorkspaceAgent,
display_apps: ["vscode"] as const,
apps: [externalApp, hiddenApp],
};

// ---------------------------------------------------------------------------
// Meta
// ---------------------------------------------------------------------------
Expand All @@ -78,7 +99,7 @@ const meta: Meta<typeof WorkspacePill> = {
title: "pages/AgentsPage/WorkspacePill",
component: WorkspacePill,
// useAppLink calls useProxy(), so we need the proxy provider for
// stories that render ExternalAppMenuItem.
// stories that render AppMenuItem.
decorators: [withProxyProvider()],
parameters: {
layout: "centered",
Expand All @@ -92,13 +113,14 @@ type Story = StoryObj<typeof WorkspacePill>;
// ---------------------------------------------------------------------------

/** Pill with all app types: built-in VS Code, VS Code Insiders, external
* apps (JetBrains, Cursor), and terminal. Clicking the pill opens the
* dropdown. */
* apps (JetBrains, Cursor), terminal, and SSH command. Clicking the pill
* opens the dropdown. */
export const WithAllApps: Story = {
Comment thread
DanielleMaywood marked this conversation as resolved.
Comment thread
DanielleMaywood marked this conversation as resolved.
args: {
...defaultProps,
workspace: MockWorkspace,
agent: agentWithApps,
sshCommand: "ssh coder.test-workspace",
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
Expand All @@ -112,6 +134,7 @@ export const WithAllApps: Story = {
expect(body.getByText("JetBrains Gateway")).toBeInTheDocument();
expect(body.getByText("Cursor")).toBeInTheDocument();
expect(body.getByText("Open Terminal")).toBeInTheDocument();
expect(body.getByText("Copy SSH Command")).toBeInTheDocument();
expect(body.getByText("View Workspace")).toBeInTheDocument();
});
},
Expand Down Expand Up @@ -168,11 +191,44 @@ export const WithExternalAppsOnly: Story = {
};

/** When the agent has no apps at all, the pill still renders with
* a "View Workspace" link in the popover. */
* a "View Workspace" link in the dropdown. */
export const NoApps: Story = {
Comment thread
DanielleMaywood marked this conversation as resolved.
args: {
...defaultProps,
workspace: MockWorkspace,
agent: agentWithNoApps,
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
const pill = canvas.getByText("Test-Workspace");
await userEvent.click(pill);

await waitFor(() => {
const body = within(document.body);
expect(body.getByText("View Workspace")).toBeInTheDocument();
});
},
};

/** Hidden apps should be filtered out and not appear in the dropdown. */
export const WithHiddenApp: Story = {
args: {
...defaultProps,
workspace: MockWorkspace,
agent: agentWithHiddenApp,
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
const pill = canvas.getByText("Test-Workspace");
await userEvent.click(pill);

await waitFor(() => {
const body = within(document.body);
// Visible apps should appear.
expect(body.getByText("Open in VS Code")).toBeInTheDocument();
expect(body.getByText("JetBrains Gateway")).toBeInTheDocument();
// Hidden app should NOT appear.
expect(body.queryByText("Hidden Internal Tool")).not.toBeInTheDocument();
});
},
};
Loading