Skip to content

feat(chat): make file paths in agent replies clickable to open in editor#7

Merged
Zhang-Henry merged 1 commit intomainfrom
feat/file-panel-resize
Feb 28, 2026
Merged

feat(chat): make file paths in agent replies clickable to open in editor#7
Zhang-Henry merged 1 commit intomainfrom
feat/file-panel-resize

Conversation

@MarkSiqiZhang
Copy link
Copy Markdown
Collaborator

Summary

  • File paths in agent markdown replies (bold text or inline code) are now clickable, opening the file in the right-side editor panel
  • Supports common patterns like src/lib.rs:36, README.md, package.json, etc.
  • Previously, when agents returned file references as plain text, users had no way to click through to view the file

Changes

  • Markdown.tsx: Add onFileOpen prop and file path regex detection; render matching bold/inline code as clickable links
  • MessageComponent.tsx: Pass onFileOpen to Markdown components for assistant messages

   File paths appearing as bold text or inline code in assistant markdown
   responses are now detected and rendered as clickable links. Clicking
   opens the file in the right-side editor panel via onFileOpen.
@Zhang-Henry Zhang-Henry merged commit 8bcfa42 into main Feb 28, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants