File tree Expand file tree Collapse file tree 6 files changed +10
-10
lines changed Expand file tree Collapse file tree 6 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -3,3 +3,4 @@ node_modules
3
3
server /build
4
4
client /dist
5
5
client /tsconfig.app.tsbuildinfo
6
+ client /tsconfig.node.tsbuildinfo
Original file line number Diff line number Diff line change 22
22
"react" : " ^18.3.1" ,
23
23
"react-dom" : " ^18.3.1" ,
24
24
"tailwind-merge" : " ^2.5.3" ,
25
- "tailwindcss-animate" : " ^1.0.7"
25
+ "tailwindcss-animate" : " ^1.0.7" ,
26
+ "zod" : " ^3.23.8"
26
27
},
27
28
"devDependencies" : {
28
29
"@eslint/js" : " ^9.11.1" ,
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ import NotificationsTab from "./components/NotificationsTab";
40
40
import PromptsTab , { Prompt } from "./components/PromptsTab" ;
41
41
import ToolsTab from "./components/ToolsTab" ;
42
42
import History from "./components/History" ;
43
- import { AnyZodObject } from "node_modules/ zod/lib " ;
43
+ import { AnyZodObject } from "zod" ;
44
44
45
45
const App = ( ) => {
46
46
const [ connectionStatus , setConnectionStatus ] = useState <
Original file line number Diff line number Diff line change @@ -5,11 +5,6 @@ import { TabsContent } from "@/components/ui/tabs";
5
5
import { Resource } from "mcp-typescript/types.js" ;
6
6
import ListPane from "./ListPane" ;
7
7
8
- export type Resource = {
9
- uri : string ;
10
- name : string ;
11
- } ;
12
-
13
8
const ResourcesTab = ( {
14
9
resources,
15
10
listResources,
@@ -38,7 +33,7 @@ const ResourcesTab = ({
38
33
renderItem = { ( resource ) => (
39
34
< div className = "flex items-center w-full" >
40
35
< FileText className = "w-4 h-4 mr-2 flex-shrink-0 text-gray-500" />
41
- < span className = "flex-1 truncate" title = { resource . uri } >
36
+ < span className = "flex-1 truncate" title = { resource . uri . toString ( ) } >
42
37
{ resource . name }
43
38
</ span >
44
39
< ChevronRight className = "w-4 h-4 flex-shrink-0 text-gray-400" />
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ const ToolsTab = ({
61
61
< p className = "text-sm text-gray-600" >
62
62
{ selectedTool . description }
63
63
</ p >
64
- { Object . entries ( selectedTool . inputSchema . properties ) . map (
64
+ { Object . entries ( selectedTool . inputSchema . properties ?? [ ] ) . map (
65
65
( [ key , value ] ) => (
66
66
< div key = { key } >
67
67
< Label
@@ -71,14 +71,17 @@ const ToolsTab = ({
71
71
{ key }
72
72
</ Label >
73
73
< Input
74
+ // @ts -expect-error value type is currently unknown
74
75
type = { value . type === "number" ? "number" : "text" }
75
76
id = { key }
76
77
name = { key }
78
+ // @ts -expect-error value type is currently unknown
77
79
placeholder = { value . description }
78
80
onChange = { ( e ) =>
79
81
setParams ( {
80
82
...params ,
81
83
[ key ] :
84
+ // @ts -expect-error value type is currently unknown
82
85
value . type === "number"
83
86
? Number ( e . target . value )
84
87
: e . target . value ,
Original file line number Diff line number Diff line change 1
- {"root":["./vite.config.ts"],"version":"5.6.2 "}
1
+ {"root":["./vite.config.ts"],"version":"5.6.3 "}
You can’t perform that action at this time.
0 commit comments