From df13a54f3702c911b9af7e546034b66a080028a4 Mon Sep 17 00:00:00 2001 From: Bohdan Triapitsyn Date: Sat, 18 Apr 2026 13:50:09 +0300 Subject: [PATCH] fix(vscode): hide Save-as-plan and Add-to-notes actions in VS Code runtime Both flows write into ~/.config/openchamber which isn't reachable from the VS Code webview, so the buttons were dead weight there. --- .../components/chat/message/MessageBody.tsx | 40 ++++++----- .../chat/message/TextSelectionMenu.tsx | 71 ++++++++++--------- 2 files changed, 60 insertions(+), 51 deletions(-) diff --git a/packages/ui/src/components/chat/message/MessageBody.tsx b/packages/ui/src/components/chat/message/MessageBody.tsx index 47081b2e..5f02c8bf 100644 --- a/packages/ui/src/components/chat/message/MessageBody.tsx +++ b/packages/ui/src/components/chat/message/MessageBody.tsx @@ -1498,25 +1498,27 @@ const AssistantMessageBody: React.FC> = ({ {isSharing ? 'Saving image...' : 'Save as image'} - - - - - Save as plan - + {!isVSCodeRuntime() ? ( + + + + + Save as plan + + ) : null} - + {!isVSCodeRuntime() ? ( + + ) : null} , document.body ); @@ -703,24 +706,28 @@ export const TextSelectionMenu: React.FC = ({ containerR New session -
+ {!isVSCodeRuntime() ? ( + <> +
- + + + ) : null}
, document.body