The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
chore: update MCP server panel
Steven Enamakel9fa24361305e
diff --git a/app/src/components/settings/panels/McpServerPanel.tsx b/app/src/components/settings/panels/McpServerPanel.tsxindex 1f4257ecc9..8884831854 100644--- a/app/src/components/settings/panels/McpServerPanel.tsx+++ b/app/src/components/settings/panels/McpServerPanel.tsx@@ -173,107 +173,101 @@ const McpServerPanel = ({ embedded = false }: McpServerPanelProps = {}) => {{/* ----------------------------------------------------------------- */}{/* Section 1 — Available Tools */}{/* ----------------------------------------------------------------- */}- <div className="px-4 pt-4 pb-2">- <SettingsSection- title={t('settings.mcpServer.toolsSectionTitle')}- description={t('settings.mcpServer.toolsSectionDesc')}>- {MCP_TOOLS.map(tool => (- <div key={tool.name} className="flex items-start gap-3 px-4 py-3 bg-surface">- <span className="font-mono text-xs text-primary-700 dark:text-primary-400 mt-0.5 shrink-0">- {tool.name}- </span>- <span className="text-xs text-content-secondary dark:text-content-muted">- {t(tool.descriptionKey)}- </span>- </div>- ))}- </SettingsSection>- </div>+ <SettingsSection+ title={t('settings.mcpServer.toolsSectionTitle')}+ description={t('settings.mcpServer.toolsSectionDesc')}>+ {MCP_TOOLS.map(tool => (+ <div key={tool.name} className="flex items-start gap-3 px-4 py-3 bg-surface">+ <span className="font-mono text-xs text-primary-700 dark:text-primary-400 mt-0.5 shrink-0">+ {tool.name}+ </span>+ <span className="text-xs text-content-secondary dark:text-content-muted">+ {t(tool.descriptionKey)}+ </span>+ </div>+ ))}+ </SettingsSection>{/* ----------------------------------------------------------------- */}{/* Section 2 — Client Configuration */}{/* ----------------------------------------------------------------- */}- <div className="px-4 pt-4 pb-6">- <SettingsSection- title={t('settings.mcpServer.configSectionTitle')}- description={t('settings.mcpServer.configSectionDesc')}>- {/* Client selector tabs */}- <ChipTabs- ariaLabel={t('settings.mcpServer.clientSelectorAriaLabel')}- items={clients}- value={activeClient}- onChange={id => {- setActiveClient(id);- setOpenConfigError(null);- }}- />-- {/* Binary path error banner — resolved on mount, present before- the reader has done anything, so it must not interrupt with an- assertive announcement. */}- {binaryError && (- <Alert variant="destructive" density="compact" role={undefined} className="mx-4 mt-3">- <AlertDescription>{t('settings.mcpServer.binaryPathNotFound')}</AlertDescription>- </Alert>- )}-- {/* Config file path */}- <div className="px-4 mt-3 mb-2 flex items-center gap-2">- <span className="text-xs text-content-muted shrink-0">- {t('settings.mcpServer.configFilePath')}:- </span>- <span className="text-xs font-mono text-content-secondary truncate">{configPath}</span>- </div>-- {/* JSON snippet */}- <div className="mx-4 mb-3 rounded-xl overflow-hidden border border-line">- <pre className="bg-surface-muted dark:bg-surface/60 px-4 py-3 text-xs font-mono text-content overflow-x-auto whitespace-pre leading-relaxed">- {snippet}- </pre>- </div>-- {/* Action buttons */}- <div className="px-4 pb-4 flex items-center gap-2 flex-wrap">- <Button type="button" variant="secondary" size="xs" onClick={() => void handleCopy()}>- {copied ? t('settings.mcpServer.copied') : t('settings.mcpServer.copySnippet')}+ <SettingsSection+ title={t('settings.mcpServer.configSectionTitle')}+ description={t('settings.mcpServer.configSectionDesc')}>+ {/* Client selector tabs */}+ <ChipTabs+ ariaLabel={t('settings.mcpServer.clientSelectorAriaLabel')}+ items={clients}+ value={activeClient}+ onChange={id => {+ setActiveClient(id);+ setOpenConfigError(null);+ }}+ />++ {/* Binary path error banner — resolved on mount, present before+ the reader has done anything, so it must not interrupt with an+ assertive announcement. */}+ {binaryError && (+ <Alert variant="destructive" density="compact" role={undefined} className="mx-4 mt-3">+ <AlertDescription>{t('settings.mcpServer.binaryPathNotFound')}</AlertDescription>+ </Alert>+ )}++ {/* Config file path */}+ <div className="px-4 mt-3 mb-2 flex items-center gap-2">+ <span className="text-xs text-content-muted shrink-0">+ {t('settings.mcpServer.configFilePath')}:+ </span>+ <span className="text-xs font-mono text-content-secondary truncate">{configPath}</span>+ </div>++ {/* JSON snippet */}+ <div className="mx-4 mb-3 rounded-xl overflow-hidden border border-line">+ <pre className="bg-surface-muted dark:bg-surface/60 px-4 py-3 text-xs font-mono text-content overflow-x-auto whitespace-pre leading-relaxed">+ {snippet}+ </pre>+ </div>++ {/* Action buttons */}+ <div className="px-4 pb-4 flex items-center gap-2 flex-wrap">+ <Button type="button" variant="secondary" size="xs" onClick={() => void handleCopy()}>+ {copied ? t('settings.mcpServer.copied') : t('settings.mcpServer.copySnippet')}+ </Button>++ {isTauri() && (+ <Button+ type="button"+ variant="tertiary"+ size="xs"+ onClick={() => void handleOpenConfig()}>+ {t('settings.mcpServer.openConfigFile')}</Button>-- {isTauri() && (- <Button- type="button"- variant="tertiary"- size="xs"- onClick={() => void handleOpenConfig()}>- {t('settings.mcpServer.openConfigFile')}- </Button>- )}- </div>-- {/* Open config error — a result of the "Open config file" click- above, but not urgent enough to interrupt: polite, not- assertive. */}- {openConfigError && (- <Alert- variant="destructive"- density="compact"- role="status"- aria-live="polite"- className="mx-4 mb-3">- <AlertDescription>- {t('settings.mcpServer.openConfigError')}: {openConfigError}- </AlertDescription>- </Alert>)}- </SettingsSection>- </div>+ </div>++ {/* Open config error — a result of the "Open config file" click+ above, but not urgent enough to interrupt: polite, not+ assertive. */}+ {openConfigError && (+ <Alert+ variant="destructive"+ density="compact"+ role="status"+ aria-live="polite"+ className="mx-4 mb-3">+ <AlertDescription>+ {t('settings.mcpServer.openConfigError')}: {openConfigError}+ </AlertDescription>+ </Alert>+ )}+ </SettingsSection></>);if (embedded) {return (- <PanelPage className="z-10" contentClassName="">- {body}- </PanelPage>+ <PanelPage className="z-10">{body}</PanelPage>);}