diff --git a/AgentCompany-New/src/renderer/src/pages/ChatPage.tsx b/AgentCompany-New/src/renderer/src/pages/ChatPage.tsx index 7e045bc2..8401d4cd 100644 --- a/AgentCompany-New/src/renderer/src/pages/ChatPage.tsx +++ b/AgentCompany-New/src/renderer/src/pages/ChatPage.tsx @@ -231,6 +231,12 @@ export function ChatPage({ snapshot, actions }: PageProps) { }); }; + const openFile = (fileId: string) => { + void window.agentCompany.openFile({ orgId, fileId }).then((result) => { + if (!result.ok) throw new Error(result.error.message); + }); + }; + return (