Address PR #1221 code review feedback

- Fix getCapabilityEntries to iterate fixed key sets so unsupported
  capabilities render red X (was only showing present/supported ones)
- Merge duplicate @mantine/core import in ViewHeader
- Move ConnectionState from ServerCard to core/mcp/types.ts
- Narrow onConnectionModeChange to "proxy" | "direct" instead of string

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
cliffhall 2026-04-21 16:24:27 -04:00
commit cc9be5e930
2 changed files with 44 additions and 17 deletions

View file

@ -1,7 +1,9 @@
import type { MCPServerConfig } from "@inspector/core/mcp/types.js";
import type {
ConnectionState,
MCPServerConfig,
} from "@inspector/core/mcp/types.js";
import type { Meta, StoryObj } from "@storybook/react-vite";
import { fn } from "storybook/test";
import type { ConnectionState } from "./ServerCard";
import { ServerCard } from "./ServerCard";
const stdioConfig: MCPServerConfig = {

View file

@ -1,7 +1,7 @@
import { Badge, Button, Card, Group, Menu, Stack, Text } from "@mantine/core";
import type { Implementation } from "@modelcontextprotocol/sdk/types.js";
import type {
ConnectionStatus,
ConnectionState,
MCPServerConfig,
ServerType,
} from "@inspector/core/mcp/types.js";
@ -11,12 +11,6 @@ import { ConnectionToggle } from "../../elements/ConnectionToggle/ConnectionTogg
import { ContentViewer } from "../../elements/ContentViewer/ContentViewer";
import { InlineError } from "../../elements/InlineError/InlineError";
export interface ConnectionState {
status: ConnectionStatus;
retryCount?: number;
error?: { message: string; details?: string };
}
export interface ServerCardProps {
name: string;
config: MCPServerConfig;