Repository navigation
feat(sidebar): pin dragged folders without blocking hover - #1692
Conversation
Accept verified internal Move-only offers without requesting deletion from foreign sources. Route existing pin drags through the insertion gaps using provider-matched locations and current bookmark anchors. Preserve folder-row transfers, labels and persisted order while reducing gap spacing. Refs #1690
Review findings (checked against 75a74f8)Thanks for this, the drop protocol handling is careful. Below are the issues worth fixing before merge. Each one was confirmed by tracing the code paths at Bugs1. Trashed folders can be pinned by dragging (window.rs#L2990) 2. Hovering a web link over a gap makes a network request (pinned_drop.rs#L243, #L140-L147) 3. Drag-pinned folders are labelled with the URI basename (window.rs#L2992) 4. A gap whose pin was removed elsewhere drops at the end (window.rs#L1844, #L1863) Tests5. 6. The last drop in the pinning E2E is never awaited (test_sidebar_pinning.py#L66-L69) Smaller issues7. A sidebar rebuild while an external drop is pending rejects it (window.rs#L1664, pinned_drop.rs#L112, #L281) 8. Shortcut/Mountable items pin from Strata but not from other apps (directory_validation.rs#L24) 9. Large or slow external selections time out (directory_validation.rs#L16, pinned_drop.rs#L153) 10. In rail mode, an empty Pinned section leaves two separators with nothing between them (window.rs#L1657, #L1415) 11. Pinned rows sit 8 px apart while other sections use 2 px (style.css#L2306, sidebar.rs#L92) 12. Each gap is an empty accessible group named "PINNED" (pinned_drop.rs#L232-L235) 13. No-op drops report success (window.rs#L1885) 14. Hand-rolled timeout (pinned_drop.rs#L65, #L153) |
Drag pins now use entry display names, refuse trash and http(s) locations before probing, resolve a gap through either neighbour so a pin unpinned elsewhere cannot send a drop to the end, and finish no-op drops as rejected.
Review follow-upI merged Fixed
Not changed (non-blocking): #7 (a rebuild mid-validation rejects a pending external drop, which needs a sidebar rebuild inside a validation window of milliseconds), #8 (Mountable/Shortcut from foreign apps), #9 (serial validation, documented as intended), #10/#11 (rail-mode separators and pinned row spacing are visual polish and are best judged against the owner's screenshots), #12 (gap accessible groups, which the E2E uses to locate targets; worth a follow-up). Verification: the targeted Rust tests for |
|
Found 1 test failure on Blacksmith runners: Failure
|
Description
Pin folders or reorder existing pins through compact sidebar insertion gaps, without changing folder-row transfers. Preserve selection order, skip duplicate new pins, and persist the resulting bookmarks and labels.
Internal folder and pin drags use provider-matched metadata without filesystem probes. Move-only internal offers are supported; external Move-only offers are rejected to avoid requesting source deletion. External folder validation remains asynchronous and bounded, and pending pin drops never fall through to file transfers. Remote pins and directory symlinks are supported without canonicalizing aliases.
Visual evidence
screenrecording-2026-10-15_21-27-44.mp4
How to test
Expected result: New folders pin in selection order and survive restart. Existing sidebar pins reorder through the insertion gaps without changing their labels or folder contents. Dragging an already-pinned folder from the main pane neither duplicates nor reorders it. Files/mixed selections do not pin or transfer through gaps; folder rows retain their transfer behavior.
Related issue
Closes #1690