diff --git a/clients/web/src/components/screens/ToolsScreen/ToolsScreen.stories.tsx b/clients/web/src/components/screens/ToolsScreen/ToolsScreen.stories.tsx index 768961b0..935fc684 100644 --- a/clients/web/src/components/screens/ToolsScreen/ToolsScreen.stories.tsx +++ b/clients/web/src/components/screens/ToolsScreen/ToolsScreen.stories.tsx @@ -1,8 +1,14 @@ import type { Meta, StoryObj } from "@storybook/react-vite"; -import type { Tool } from "@modelcontextprotocol/sdk/types.js"; +import type { ElicitRequest, Tool } from "@modelcontextprotocol/sdk/types.js"; +import { Modal } from "@mantine/core"; import { fn } from "storybook/test"; import { ToolsScreen } from "./ToolsScreen"; import type { ToolCallState } from "./ToolsScreen"; +import { SamplingRequestPanel } from "../../groups/SamplingRequestPanel/SamplingRequestPanel"; +import { ElicitationFormPanel } from "../../groups/ElicitationFormPanel/ElicitationFormPanel"; +import { PendingClientRequests } from "../../groups/PendingClientRequests/PendingClientRequests"; +import { InlineSamplingRequest } from "../../groups/InlineSamplingRequest/InlineSamplingRequest"; +import { InlineElicitationRequest } from "../../groups/InlineElicitationRequest/InlineElicitationRequest"; const meta: Meta = { title: "Screens/ToolsScreen", @@ -154,3 +160,129 @@ export const WithListChanged: Story = { listChanged: true, }, }; + +const elicitFormRequest = { + message: "Please provide the database credentials for this operation.", + requestedSchema: { + type: "object" as const, + properties: { + host: { type: "string" as const, title: "Host" }, + port: { type: "string" as const, title: "Port" }, + password: { type: "string" as const, title: "Password" }, + }, + }, +} satisfies ElicitRequest["params"]; + +export const WithSamplingModal: Story = { + args: { + tools: sampleTools, + selectedToolName: "create_record", + callState: { status: "pending" }, + }, + render: (args) => ( + <> + + + + + + ), +}; + +export const WithElicitationModal: Story = { + args: { + tools: sampleTools, + selectedToolName: "create_record", + callState: { status: "pending" }, + }, + render: (args) => ( + <> + + + + + + ), +}; + +export const WithPendingRequests: Story = { + args: { + tools: sampleTools, + selectedToolName: "create_record", + callState: { status: "pending" }, + }, + render: (args) => ( + <> + + + + + + + + + ), +};