summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorblackhao <13851610112@163.com>2025-12-11 01:28:42 -0600
committerblackhao <13851610112@163.com>2025-12-11 01:28:42 -0600
commit10732f49b0cf4379bc0270b45ab5525ee80eb584 (patch)
tree44233c221d1c4fab997cfb4855847a9fbb850673
parentf37c38ce077f0d1df086c213ef1e40a0d3402445 (diff)
fix traceHEADmain
-rw-r--r--frontend/src/components/Sidebar.tsx6
1 files changed, 3 insertions, 3 deletions
diff --git a/frontend/src/components/Sidebar.tsx b/frontend/src/components/Sidebar.tsx
index 700574a..4febe4f 100644
--- a/frontend/src/components/Sidebar.tsx
+++ b/frontend/src/components/Sidebar.tsx
@@ -627,9 +627,9 @@ const Sidebar: React.FC<SidebarProps> = ({ isOpen, onToggle, onInteract }) => {
setQuickChatMessages(fullMessages);
setQuickChatSentFiles(buildSentFilesFromMessages(fullMessages));
- // Set last node ID: if current node has response, start from here.
- // Otherwise start from trace source (which is the last completed node)
- setQuickChatLastNodeId(hasResponse ? selectedNode.id : trace.sourceNodeId);
+ // Always set last node ID to current selected node
+ // handleQuickChatSend will decide whether to overwrite (if empty) or create new node (if has response)
+ setQuickChatLastNodeId(selectedNode.id);
}
setQuickChatOpen(true);