feat: add @-mention file attachment in agent chat composer (Refs: beans-uk55)#172
Merged
feat: add @-mention file attachment in agent chat composer (Refs: beans-uk55)#172
Conversation
…ns-uk55) - Add `listFiles` GraphQL query with case-insensitive substring matching across all git-tracked files (space-separated terms, all must match) - Extend `sendAgentMessage` mutation with optional `attachments` parameter; attached paths are prepended as context hints in the user message - Add @-detection in composer textarea with debounced autocomplete dropdown - Keyboard navigation (arrows, Enter/Tab to select, Escape to close) with scroll-into-view for selected items - Selected files shown as removable pills below the textarea - Add `FileEntry` type, `FileAttachmentInput` input, and `ListFiles` query to GraphQL schema with codegen - Add unit tests for ListFiles resolver
6415b77 to
1ac5fe2
Compare
…efs: beans-uk55)
- Replace prefix-only directory browsing with fuzzy substring matching
across all git-tracked files (space-separated terms, case-insensitive)
- Add FileMention TipTap node extension for inline atom pills in the
composer (non-editable, deletable via backspace)
- Serialize mentions as {{file:path}} markers in message text so they
render inline at the correct position in the chat history
- Add attachments field to Message struct, JSONL persistence, and
GraphQL AgentMessage type for structured attachment data
- Move context prefix injection from resolver to agent manager so the
stored/displayed message stays clean (prefix only goes to Claude stdin)
- Share .file-mention-pill CSS class between composer and message display
- Add scroll-into-view on keyboard navigation in autocomplete dropdown
- Use smaller font (text-xs) for dropdown items and pills
…s: beans-uk55) - Update listFiles query description to reflect substring matching behavior - Remove isDir from FileEntry type (always false after directory browsing removal) - Remove isDir references from frontend composer and operations
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
@-mention file attachment in the agent chat composer — type@+ 2 characters to fuzzy-search project files (viagit ls-files), select to insert an inline pill{{file:path}}markers)listFilesGraphQL query with case-insensitive multi-term substring matchingattachmentsfield toAgentMessagefor persistence and display@session, then filtered client-side for instant resultsTest plan
TestListFilessuite)@in agent chat, verify dropdown appears after 2 chars