Repository navigation
feat: move MCP server sign-in to Agents settings and simplify the + menu - #31396
Conversation
… for MCP connections
- Shorten the footer count to "N not connected" so Manage connections fits the w-72 menu, and let the footer wrap instead of clipping. - Hide the Status column below sm on MCP connections; the action button already shows the state there. - Docs: a server that is on for a chat but not connected, including a default-on one, shows as disconnected.
…able width Beside the settings sidebar the table is much narrower than the viewport, so viewport breakpoints still let it scroll sideways and hide the action buttons. Use container queries on the table wrapper: below 32rem only the name (which fills and truncates) and the action show, the description comes back at 32rem and the status at 42rem.
# Conflicts: # site/src/pages/AgentsPage/components/AgentChatInput.test.tsx
Add a phone-width story for the MCP connections loading skeleton, hoist the footer's plural noun out of the JSX, and tighten two comments.
Docs previewCheck off each page once it's been reviewed. If a page changes in a later push, its checkbox clears automatically so it gets a fresh look. Pages not yet wired into the docs navigation aren't listed here. |
|
@codex review
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. What shall we delve into next? Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@codex review
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 26580671a2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
The MCP connections page looked up the signed-in server in the list of the organization shown when the popup reported success. If the user had switched organizations while signing in, the lookup missed and no confirmation toast appeared, and only the shown organization's list was refreshed. useMCPOAuthFlow now takes the server to connect and hands the same server back on success, so the page confirms the sign-in without a lookup. A completion refreshes every organization's MCP server list through the existing invalidateMCPServerConfigQueries helper, now exported.
…us menu submenus Below the md breakpoint, the plus menu swaps its main view for the MCP servers or workspace submenu. The swap unmounted the row a keyboard user had activated, and focus fell to the page. The submenu's Back button now takes focus when it mounts, and Back returns focus to the row that opened the submenu. Reopening the menu still focuses its first item.
… assertion Drop the JSDoc that restated getStateOrganizationId, shorten the MCPServersMenuContent JSDoc to its optional-handler contract, and drop the cancelled-disconnect test's dialog-absence check. The test still asserts that cancelling never calls the disconnect API.
Follow-up to the frontend review of the previous fixes: - Both below-md submenus render one PlusMenuBackButton, and a plusMenuRowRef helper picks the row that takes focus back. The focusOnMount comment names the below-md condition and records why a callback ref replaces autoFocus. - The submenu focus test also walks the workspace submenu after the MCP one, so Back has to return focus to the row that opened it. - The connections page test shares stubSignInPopup and completeSignIn helpers, and the hook test uses MockMCPServerConfig instead of a new local fixture. - invalidateMCPServerConfigQueries, now exported, gets a JSDoc.
…t and reuse MockWorkspace
|
@codex review
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c259aac2c6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…connections view contract
|
@codex review
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b6a706dfa3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review
|
|
Codex Review: Didn't find any major issues. Nice work! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…ctionsPage): drop arrow icon from Connect button
…uth rows in MCP connections
…ctionsPage): match No auth required to the row text size
… auth required rows
…ectionsPage): list no-auth servers after OAuth2 servers
…s with if statements The MCP connections table shows only the error alert when the first load fails, the plus menu's submenus share one panel component, and a test fixture gets the mock prefix.
…ConnectionsPage): resolve the starting organization once with if statements
…ectionsPage): split added and available connectors
…re the sign-in check
Signing in to MCP servers moves out of the chat's + menu to a new Agents > Settings > MCP connections page. The menu becomes an on/off list.
default_offrow notes that OAuth2 servers are listed once the user connects, and the Organization scope table gets an MCP server connections row.Screenshots
Known limitations
Review and validation
frontend-deep-review, eight roles) on the first commit and on each fix delta, plus the FE1 to FE10 audit; the last round has no open findings. Findings not taken are listed below with the reason. Not split into a stack: the menu, the settings page, and the removal only make sense together.doc-checkin author self-check mode (seven personas and per-finding verifiers): the six blocking findings are fixed in425c1a1978e. A confirmation round on the revised text found ten more (step structure, wording that pointed at screen positions, product terms, the access prerequisite, and read-only chats), fixed in26580671a23.@codex review) found no major issues on425c1a1978e. On26580671a23it raised six findings. Two were real defects, each now covered by a test that fails without the fix: the settings page did not confirm a sign-in that finished after the user switched organizations (dac62b6585b), and keyboard focus fell out of the menu when a phone drill-in opened or closed (a39e7a16fd1). Three asked for comment and assertion trims (b48471aa965). One is declined below. Round 3 onc259aac2c60asked for a JSDoc on the exported connections view (b6a706dfa37). Round 4 onb6a706dfa37found that a disconnected forced-on server no longer told screen readers it is always on, as main did with hidden text;593f8115ad8restores it, with a test that fails without it. Round 5 found no major issues on446d22e619d.08c8477ef22, and round 5, a smoke test after mergingmain, passed on82229eeb806with the server and frontend rebuilt from that SHA. Round 6 passed onc259aac2c60(keyboard focus in the phone drill-ins at 390 and 320 px, and a sign-in that finishes after an organization switch). Round 7 passed on446d22e619d: the footer stays on one line with Manage in all 18 cases checked (0, 1 and 2 servers not connected, on six menus at 1440, 390 and 320 px), and a signed-out always-on server reads as always on to screen readers. The rounds covered the footer at 1440, 390 and 320 px, the table from 320 to 1440 px, member organizations (two, one, and none), Connect and Disconnect against a mock OAuth server, and a real model turn whose tool list followed the switches.tsc, Biome, oxlint, knip, Vitest for the touched files, the Storybook Vitest project for the Agents page components, andmake pre-commit-light. CI'stest-jscaught one test that rendered the create form without a router, which the Manage button's navigation needs;d44a7628fe1wraps it inMemoryRouter. The pre-commit hook (make pre-commit) ran on every commit.MCPSubmenuMobile,UncheckSelectedWorkspaceFromPicker), because focus now moves to Back on entry. The MCP connections page stories show Connect without the arrow icon, status dots without text, and "No auth required" rows; theOneServerWithoutSignInstory is removed andEmptynow has no servers. The composer stories show one MCP pill.Review findings not taken
Object.defineProperty, because jsdom does not implementWindow.closed. It patches the test's own iframe window, not a shared global.LoadingMobilestory spells out its two args like the other stories in the file instead of reusingLoading.args.AgentChatInputinstead ofMCPServerIcon, whose bordered tile or circle would change how the menu looks. A compact variant can follow separately.lastPlusMenuSubmenuand its two handlers) stays inAgentChatInputcomponent state, because FE3 discourages a new single-use hook when component state can express the logic.MockMCPServerConfiginto per-scenario servers, as the existingAgentChatInputtests do, instead of importingMockGitHubMCPServerfrom the AI settings page's own fixtures.testHelpers.