Skip to content

feat(workspace): file-manager drag-and-drop — move within tree + import from OS into workspace #3402

@pamnard

Description

@pamnard

Summary

The workspace file tree panel supports drag-and-drop, but only for referencing paths in the chat composer (#1097, closed). It does not behave like a desktop file manager for:

  1. Moving existing files/folders within the workspace tree (drag item → drop on folder).
  2. Importing files/folders dragged from the OS (Finder/Explorer) into the workspace panel (current directory), as opposed to attaching them to the chat.

Users often expect both because the panel looks like a file tree. Today that expectation is unmet by design of #1097, not by an obvious bug — but the gap is undocumented in-product and was deferred from #1104 (“Move/copy — lower priority, complex UX”).

Current behavior (intentional)

Action What happens
Drag file/folder in workspace tree draggable=true, effectAllowed='copy', sets application/ws-path
Drop on composer Inserts @<workspace-relative-path> into the message textarea
Drag files from OS onto page Global drop on composerWrap: addFiles() → chat attachments (session inbox), not workspace import
Drag in Settings → Workspaces list Reorder registered workspaces (/api/workspaces/reorder) — unrelated to in-tree file ops

Backend: create, delete, rename in place only (/api/file/rename rejects / in new_name — no cross-directory move). No /api/file/move or workspace-panel drop target.

Requested behavior

A. Internal move (tree → tree)

  • Drag file or folder onto another folder (or breadcrumb) to move within the workspace root.
  • Visual drop targets, move effect, confirm on overwrite if needed.
  • API: cross-directory move (POST /api/file/move or extend rename with validated to path).

B. OS import (OS → workspace panel)

C. UX clarity (optional)

Related

Acceptance criteria (draft)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestworkspaceWorkspace panel, file browser, preview

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions