Add drag & drop for images and file references#201
Open
leonidasbarkas98-cpu wants to merge 2 commits into
Open
Add drag & drop for images and file references#201leonidasbarkas98-cpu wants to merge 2 commits into
leonidasbarkas98-cpu wants to merge 2 commits into
Conversation
Dropping image files from the OS reuses the existing createImageFile/ imageAttached paste pipeline; dropping files/tabs from the VS Code explorer inserts an @-file reference into the message input instead, since no file content is available for those drops. Adds a dashed drag-over highlight on the input container. Upstream andrepimenta#185, andrepimenta#80, andrepimenta#54, andrepimenta#119 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…edback Only react to drags that actually carry Files or text/uri-list (checked via dataTransfer.types) so native in-textarea text drag/drop keeps working instead of being swallowed. Add a shared resetDragState(), wired to window 'dragend'/'blur' as a safety net for cases where dragleave doesn't fire across webview/iframe boundaries (dropping outside the panel, aborting with Esc). Show a toast when a dropped uri-list contains no local file:// entries (e.g. untitled:, vscode-remote:// on SSH/WSL workspaces) instead of failing silently. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Dropping OS image files onto the chat reuses the existing image/paste pipeline; dropping files from the VS Code explorer inserts @-references. Includes type gating, drag-highlight reset on dragend/blur, and a toast for remote (non-file://) URIs.
Fixes #185
Fixes #80
Fixes #54
Fixes #119
Also helps with the drag & drop part of #166.
🤖 Generated with Claude Code