Skip to content

[6.x] Drag assets and folders onto breadcrumbs - #15677

Open
jaygeorge wants to merge 2 commits into
15675-list-view-folder-dropfrom
15677-drag-to-breadcrumbs
Open

jaygeorge wants to merge 2 commits into
15675-list-view-folder-dropfrom
15677-drag-to-breadcrumbs

Conversation

@jaygeorge

@jaygeorge jaygeorge commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Depends on #15676.

Description of the Problem

You can drag assets deeper into subfolders, but there's no way to drag one back up. To move an asset into a parent folder, or back to the top, you have to use the Move action instead.

What this PR Does

The breadcrumbs above the asset browser are now drop targets, so you can drag an asset or folder onto any parent folder, including "All".

  • The breadcrumb you're over gets the same blue ring as a folder in grid view. In list view, folders now get the ring around their icon and name too, instead of the faint row background.
  • While a move is running, the items show a spinner and can't be clicked. Then a "Moved to …" toast appears and the listing refreshes.
  • Only items you're allowed to move light up a drop target. A folder can't be dropped onto itself, and anything already in the destination is skipped.
  • While searching, results can come from anywhere, so the current folder's breadcrumb accepts drops too.

The move itself lives in Browser rather than in the grid and list components, so it carries on correctly if you switch views mid-move. Each move's spinners stay until the refreshed listing comes back, and the selection is updated in that same render. Moved assets get new IDs, so the action's own replaceInSelections callback keeps them selected rather than them silently dropping out (which matters in the asset picker, where the selection is what you're picking).

drag-to-breadcrumbs.mp4

How to Reproduce

  1. Go to Assets and open a folder at least two levels deep.
  2. Drag an asset onto "All" or a parent folder in the breadcrumbs.
  3. It moves there.

@jaygeorge
jaygeorge added this pull request to stack #15680 October 19, 2026 14:24
jaygeorge and others added 2 commits October 20, 2026 16:41
- Parent breadcrumbs accept drops when the dragged item can be moved (and the current folder too while searching)
- Browser owns the move: spinners on the moving items, a "Moved to :folder" toast, and the progress bar until every move has settled
- Moved assets stay selected under their new IDs, via the action's replaceInSelections callback, applied with the refreshed listing
- Folders only accept movable items, can't be dropped onto themselves, and items already in the destination are skipped
- List view outlines the hovered folder's icon and name, like the breadcrumbs
Rendering the overlay on dragstart changed the DOM under the drag source, which made the browser cancel the drag. Only show it while moving, and dim the tile during the drag instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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