@kvasar/google-stitch 0.1.20 → 0.1.21
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/openclaw.plugin.json
CHANGED
package/package.json
CHANGED
|
@@ -7,7 +7,7 @@ import { Type } from "@sinclair/typebox";
|
|
|
7
7
|
import { StitchMCPClient } from "../services/stitch-mcp-client.js";
|
|
8
8
|
|
|
9
9
|
export interface CreateProjectParams {
|
|
10
|
-
|
|
10
|
+
title: string;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
export function createProjectTool(client: StitchMCPClient) {
|
|
@@ -20,7 +20,7 @@ export function createProjectTool(client: StitchMCPClient) {
|
|
|
20
20
|
),
|
|
21
21
|
}),
|
|
22
22
|
async execute(_id: string, params: CreateProjectParams) {
|
|
23
|
-
const result = await client.createProject(params.
|
|
23
|
+
const result = await client.createProject(params.title);
|
|
24
24
|
return {
|
|
25
25
|
content: [{ type: "text" as const, text: JSON.stringify(result, null, 2) }],
|
|
26
26
|
};
|
|
@@ -1,7 +1,16 @@
|
|
|
1
|
+
import { Type, Static } from "@sinclair/typebox";
|
|
2
|
+
|
|
3
|
+
const ListDesignSystemsSchema = Type.Object({
|
|
4
|
+
projectId: Type.Optional(Type.String({ description: "Optional. Project ID. If empty, lists global design systems." })),
|
|
5
|
+
});
|
|
6
|
+
|
|
7
|
+
type ListDesignSystemsParams = Static<typeof ListDesignSystemsSchema>;
|
|
8
|
+
|
|
1
9
|
export const listDesignSystemsTool = (client:any) => ({
|
|
2
10
|
name: "list_design_systems",
|
|
3
|
-
description: "
|
|
4
|
-
|
|
11
|
+
description: "Lists design systems accessible to the user, optionally filtered by project",
|
|
12
|
+
parameters: ListDesignSystemsSchema,
|
|
13
|
+
async execute(_: string, params: ListDesignSystemsParams) {
|
|
5
14
|
return await client.request?.("list_design_systems", params);
|
|
6
15
|
},
|
|
7
16
|
});
|
|
@@ -2,6 +2,7 @@ import { StitchMCPClient } from "../services/stitch-mcp-client.js";
|
|
|
2
2
|
import fs from "node:fs";
|
|
3
3
|
import os from "node:os";
|
|
4
4
|
import path from "node:path";
|
|
5
|
+
import { Type } from "@sinclair/typebox";
|
|
5
6
|
|
|
6
7
|
interface ListScreensParams {
|
|
7
8
|
projectId: string;
|
|
@@ -34,6 +35,10 @@ type Screen = {
|
|
|
34
35
|
export const listScreensTool = (client: StitchMCPClient) => ({
|
|
35
36
|
name: "list_screens",
|
|
36
37
|
description: "Lists all screens within a given Stitch project",
|
|
38
|
+
parameters: Type.Object({
|
|
39
|
+
projectId: Type.String({
|
|
40
|
+
description: "Required. Project ID (e.g., '4044680601076201931'), without `projects/` prefix."
|
|
41
|
+
})}),
|
|
37
42
|
|
|
38
43
|
async execute(_: string, params: ListScreensParams) {
|
|
39
44
|
if (!params?.projectId) {
|