@storybook/mcp 0.0.5 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -80,11 +80,11 @@ type ComponentManifestMap = v.InferOutput<typeof ComponentManifestMap>;
80
80
  //#endregion
81
81
  //#region src/tools/list-all-components.d.ts
82
82
  declare const LIST_TOOL_NAME = "list-all-components";
83
- declare function addListAllComponentsTool(server: McpServer<any, StorybookContext>): Promise<void>;
83
+ declare function addListAllComponentsTool(server: McpServer<any, StorybookContext>, enabled?: Parameters<McpServer<any, StorybookContext>['tool']>[0]['enabled']): Promise<void>;
84
84
  //#endregion
85
85
  //#region src/tools/get-component-documentation.d.ts
86
86
  declare const GET_TOOL_NAME = "get-component-documentation";
87
- declare function addGetComponentDocumentationTool(server: McpServer<any, StorybookContext>): Promise<void>;
87
+ declare function addGetComponentDocumentationTool(server: McpServer<any, StorybookContext>, enabled?: Parameters<McpServer<any, StorybookContext>['tool']>[0]['enabled']): Promise<void>;
88
88
  //#endregion
89
89
  //#region src/index.d.ts
90
90
  type InitializeRequestParams = {
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import * as v from "valibot";
5
5
 
6
6
  //#region package.json
7
7
  var name = "@storybook/mcp";
8
- var version = "0.0.5";
8
+ var version = "0.0.6";
9
9
  var description = "MCP server that serves knowledge about your components based on your Storybook stories and documentation";
10
10
 
11
11
  //#endregion
@@ -241,11 +241,12 @@ function formatComponentManifestMapToList(manifest) {
241
241
  //#endregion
242
242
  //#region src/tools/list-all-components.ts
243
243
  const LIST_TOOL_NAME = "list-all-components";
244
- async function addListAllComponentsTool(server) {
244
+ async function addListAllComponentsTool(server, enabled) {
245
245
  server.tool({
246
246
  name: LIST_TOOL_NAME,
247
247
  title: "List All Components",
248
- description: "List all available UI components from the component library"
248
+ description: "List all available UI components from the component library",
249
+ enabled
249
250
  }, async () => {
250
251
  try {
251
252
  const manifest = await getManifest(server.ctx.custom?.source, server.ctx.custom?.manifestProvider);
@@ -268,12 +269,13 @@ async function addListAllComponentsTool(server) {
268
269
  //#region src/tools/get-component-documentation.ts
269
270
  const GET_TOOL_NAME = "get-component-documentation";
270
271
  const GetComponentDocumentationInput = v.object({ componentIds: v.pipe(v.array(v.string()), v.minLength(1, "At least one component ID is required")) });
271
- async function addGetComponentDocumentationTool(server) {
272
+ async function addGetComponentDocumentationTool(server, enabled) {
272
273
  server.tool({
273
274
  name: GET_TOOL_NAME,
274
275
  title: "Get Documentation for Components",
275
276
  description: "Get detailed documentation for specific UI components",
276
- schema: GetComponentDocumentationInput
277
+ schema: GetComponentDocumentationInput,
278
+ enabled
277
279
  }, async (input) => {
278
280
  try {
279
281
  const manifest = await getManifest(server.ctx.custom?.source, server.ctx.custom?.manifestProvider);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/mcp",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "description": "MCP server that serves knowledge about your components based on your Storybook stories and documentation",
5
5
  "keywords": [
6
6
  "storybook",
@@ -27,8 +27,8 @@
27
27
  ],
28
28
  "dependencies": {
29
29
  "@tmcp/adapter-valibot": "^0.1.4",
30
- "@tmcp/transport-http": "^0.7.0",
31
- "tmcp": "^1.15.2",
30
+ "@tmcp/transport-http": "^0.8.0",
31
+ "tmcp": "^1.16.0",
32
32
  "valibot": "^1.1.0"
33
33
  },
34
34
  "devDependencies": {