ui: Move Settings and MCP Servers routes to dialog-based views - #27744
Conversation
d373d41 to
4eb3851
Compare
There was a problem hiding this comment.
Pull request overview
This PR refactors the UI navigation so Settings and MCP Servers are opened as modal dialogs instead of dedicated #/settings and #/mcp-servers routes, simplifying navigation state and enabling in-place interactions (e.g., browsing MCP resources from server cards).
Changes:
- Replaces Settings and MCP Servers routes with dialog-based views (
DialogSettingsChat,DialogMcpServers) and removes now-unused settings navigation/referrer infrastructure. - Updates sidebar and chat-form entry points to open dialogs rather than navigating to hash routes.
- Enhances MCP server cards by making the “Resources” capability badge open the resources browser dialog.
Reviewed changes
Copilot reviewed 33 out of 33 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/ui/src/routes/settings/+layout.svelte | Removes settings route layout wrapper (route removed). |
| tools/ui/src/routes/settings/[[section]]/+page.svelte | Removes URL-driven settings page (route removed). |
| tools/ui/src/routes/mcp-servers/+page.svelte | Removes MCP servers route page (route removed). |
| tools/ui/src/lib/stores/settings/referrer.svelte.ts | Deletes settings referrer store (no longer needed with dialogs). |
| tools/ui/src/lib/stores/index.ts | Stops exporting removed settingsReferrer. |
| tools/ui/src/lib/services/router.service.ts | Removes RouterService.settings() (settings no longer URL-addressed). |
| tools/ui/src/lib/services/index.ts | Updates RouterService docs to remove settings route reference. |
| tools/ui/src/lib/hooks/use-settings-navigation.svelte.ts | Removes route/referrer-based settings navigation hook. |
| tools/ui/src/lib/enums/ui.enums.ts | Adds SidebarAction.SETTINGS for dialog opening from the sidebar. |
| tools/ui/src/lib/constants/ui.constants.ts | Updates sidebar settings item to use an action instead of a route. |
| tools/ui/src/lib/constants/routes.constants.ts | Removes settings route constants; MCP servers constant remains defined. |
| tools/ui/src/lib/components/app/settings/SettingsMcpServers.svelte | Adapts MCP servers UI for dialog use; adds resources browser opening hook. |
| tools/ui/src/lib/components/app/settings/SettingsFooter.svelte | Adjusts footer layout spacing for new dialog layout. |
| tools/ui/src/lib/components/app/settings/SettingsChatMobileHeader.svelte | Removes hash-link navigation and updates header/sticky behavior for dialog. |
| tools/ui/src/lib/components/app/settings/SettingsChatDesktopSidebar.svelte | Removes hash-link navigation and adjusts layout for dialog. |
| tools/ui/src/lib/components/app/settings/SettingsChat/SettingsChat.svelte | Converts settings section switching to in-app state; replaces route close behavior with onClose. |
| tools/ui/src/lib/components/app/settings/index.ts | Updates component docs to reflect in-app section switching. |
| tools/ui/src/lib/components/app/navigation/SidebarNavigation/SidebarNavigationActions.svelte | Adds onSettingsClick callback handling for sidebar actions. |
| tools/ui/src/lib/components/app/navigation/SidebarNavigation/SidebarNavigation.svelte | Wires sidebar Settings action to open DialogSettingsChat. |
| tools/ui/src/lib/components/app/mcp/McpServerCard/McpServerCardHeader.svelte | Plumbs optional onBrowseResources into capabilities badges. |
| tools/ui/src/lib/components/app/mcp/McpServerCard/McpServerCard.svelte | Accepts and forwards onBrowseResources; minor layout adjustment. |
| tools/ui/src/lib/components/app/mcp/McpCapabilitiesBadges.svelte | Makes “Resources” badge clickable/keyboard-accessible to open browser. |
| tools/ui/src/lib/components/app/dialogs/index.ts | Exports new settings/MCP servers dialogs. |
| tools/ui/src/lib/components/app/dialogs/DialogSettingsChat.svelte | New settings dialog wrapper around SettingsChat. |
| tools/ui/src/lib/components/app/dialogs/DialogMcpServers.svelte | New MCP servers dialog wrapper around SettingsMcpServers. |
| tools/ui/src/lib/components/app/dialogs/DialogMcpServerAddNew.svelte | Dialog sizing tweak. |
| tools/ui/src/lib/components/app/dialogs/DialogMcpResourcesBrowser.svelte | Dialog sizing tweak. |
| tools/ui/src/lib/components/app/chat/index.ts | Renames/updates export docs for MCP add-menu component. |
| tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActions.svelte | Changes MCP settings handler to be injected (dialog open) instead of route navigation. |
| tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActionAdd/ChatFormActionAddMcpSubmenu.svelte | Adds new MCP submenu UI (Servers/Prompts/Resources). |
| tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActionAdd/ChatFormActionAddMcpServersSubmenu.svelte | Removes old searchable/toggleable MCP servers submenu implementation. |
| tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActionAdd/ChatFormActionAddDropdown.svelte | Simplifies desktop “+” menu; currently does not use the new MCP submenu. |
| tools/ui/src/lib/components/app/chat/ChatForm/ChatForm.svelte | Adds and wires DialogMcpServers opened from chat form actions. |
Suppressed comments (2)
tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActionAdd/ChatFormActionAddDropdown.svelte:89
- Desktop add-actions dropdown no longer renders the reasoning submenu (only the mobile sheet does). This is a functional regression on non-mobile; re-add the reasoning submenu + separator at the top of the menu like before.
<DropdownMenu.Sub>
<DropdownMenu.SubTrigger class="flex cursor-pointer items-center gap-2">
<File class={ICON_CLASS_DEFAULT} />
tools/ui/src/lib/components/app/chat/ChatForm/ChatFormActions/ChatFormActionAdd/ChatFormActionAddDropdown.svelte:150
- The new
ChatFormActionAddMcpSubmenucomponent (Servers/Prompts/Resources) is added in this PR but not actually used here; instead the dropdown shows only a single "MCP Servers" item. Swap this block to render the submenu so prompts/resources entries can appear when supported.
<DropdownMenu.Item
class="flex cursor-pointer items-center gap-2"
onclick={chatFormActions.onMcpSettingsClick}
>
<McpLogo class={ICON_CLASS_DEFAULT} />
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| let activeSlug = $derived(initialSection ?? 'general'); | ||
|
|
||
| function handleSectionChange(section: SettingsSectionTitle) { |
| </Dialog.Title> | ||
| </Dialog.Header> | ||
|
|
||
| <SettingsChat {initialSection} onClose={() => (open = false)} onSectionChange={() => {}} /> |
| import { File, MessageSquare, Plus } from '@lucide/svelte'; | ||
| import { ChatFormActionAddToolsSubmenu, McpLogo } from '$lib/components/app'; |
| /** MCP servers. */ | ||
| MCP_SERVERS: '#/mcp-servers', | ||
| /** Search — mobile-only full-page conversation search. */ |
4eb3851 to
0ace5a2
Compare
Pull Request is not mergeable
Pull Request is not mergeable
Replace the MCP servers submenu with a single "MCP Servers" item that opens a new DialogMcpServers dialog instead of navigating to the /mcp-servers route. Assisted-by: pi
Make the Resources capability badge clickable so it opens the MCP resources browser dialog, and drop the page-only chrome from SettingsMcpServers. Assisted-by: pi
MCP servers are now managed in a dialog, so drop the dedicated route and the sidebar icon that navigated to it. Assisted-by: pi
The submenu was replaced by the MCP servers dialog, so delete the component and its export. Assisted-by: pi
0ace5a2 to
6358971
Compare
Open DialogMcpServers from the nav strip. Upstream ggml-org#27744 dropped the sidebar entry when MCP moved off the /mcp-servers route.
Open DialogMcpServers from the nav strip. Upstream ggml-org#27744 dropped the sidebar entry when MCP moved off the /mcp-servers route.
…org#27744) * ui : open MCP servers in a dialog from the chat form Replace the MCP servers submenu with a single "MCP Servers" item that opens a new DialogMcpServers dialog instead of navigating to the /mcp-servers route. Assisted-by: pi * ui : browse MCP resources from the server card Make the Resources capability badge clickable so it opens the MCP resources browser dialog, and drop the page-only chrome from SettingsMcpServers. Assisted-by: pi * ui : remove mcp-servers route and sidebar entry MCP servers are now managed in a dialog, so drop the dedicated route and the sidebar icon that navigated to it. Assisted-by: pi * ui : remove unused MCP servers submenu component The submenu was replaced by the MCP servers dialog, so delete the component and its export. Assisted-by: pi * feat(ui): add DialogSettingsChat dialog * refactor(ui): switch SettingsChat to in-app section navigation * feat(ui): open settings as dialog from sidebar * refactor(ui): remove settings route and URL-based settings navigation * fix(ui): adjust MCP dialogs for new base sizing * chore: Formatting & linting
…org#27744) * ui : open MCP servers in a dialog from the chat form Replace the MCP servers submenu with a single "MCP Servers" item that opens a new DialogMcpServers dialog instead of navigating to the /mcp-servers route. Assisted-by: pi * ui : browse MCP resources from the server card Make the Resources capability badge clickable so it opens the MCP resources browser dialog, and drop the page-only chrome from SettingsMcpServers. Assisted-by: pi * ui : remove mcp-servers route and sidebar entry MCP servers are now managed in a dialog, so drop the dedicated route and the sidebar icon that navigated to it. Assisted-by: pi * ui : remove unused MCP servers submenu component The submenu was replaced by the MCP servers dialog, so delete the component and its export. Assisted-by: pi * feat(ui): add DialogSettingsChat dialog * refactor(ui): switch SettingsChat to in-app section navigation * feat(ui): open settings as dialog from sidebar * refactor(ui): remove settings route and URL-based settings navigation * fix(ui): adjust MCP dialogs for new base sizing * chore: Formatting & linting
Match master after ggml-org#27744: MCP servers stay in the chat + dialog, not the nav strip.
Overview
Screen.Recording.2026-08-26.at.16.18.45.mp4
Moves Settings and MCP Servers out of dedicated routes and into modal dialogs: the sidebar Settings icon and the chat form's
+→ MCP menu now openDialogSettingsChat/DialogMcpServersinstead of navigating to#/settingsand#/mcp-servers.It consolidates the old in-dropdown MCP server list (with search + per-server toggles) into a simple MCP submenu (Servers/Prompts/Resources), makes the server-card "Resources" badge clickable to open the resources browser, and deletes all the now-unused route/referrer navigation machinery (
RouterService.settings,settingsReferrer,use-settings-navigation).Requirements