Skip to content

feat(desktop): drag workspace files into composer - #786

Open
Blue-Berrys wants to merge 1 commit into
vastsa:mainfrom
Blue-Berrys:feat/issue-745-file-tree-drag
Open

Blue-Berrys wants to merge 1 commit into
vastsa:mainfrom
Blue-Berrys:feat/issue-745-file-tree-drag

Conversation

@Blue-Berrys

Copy link
Copy Markdown
Contributor

Problem

Files shown in the bundled File Manager could not be dragged into the Composer, so users had to type a path or use the file picker instead.

Result

Regular, non-symlink file rows can now be dragged from the work panel into the Composer. A drop inserts one removable file chip using the workspace-relative path and leaves the source file in place. Direct and cross-WebContents delivery are deduplicated so one gesture creates one chip; directories remain navigation-only.

Closes #745

Validation

  • Manually verified on macOS with the bundled File Manager: drag a file row into the Composer and confirm exactly one chip is inserted
  • pnpm --filter @pi-desktop/shared build
  • pnpm --filter @pi-desktop/desktop typecheck
  • node --experimental-strip-types --test test/composer-drag-drop.test.mjs (6 passed)
  • node --test test/bundled-plugins.test.mjs (10 passed)
  • pnpm lint
  • pnpm docs:check
  • pnpm build:js

@vastsa

vastsa commented Sep 21, 2026

Copy link
Copy Markdown
Owner

感谢时间,最近pr 有点多,我慢慢理!

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.

[Feature] 希望增加从右侧文件管理器拖动文件到对话框的功能

2 participants