Repository navigation
feat(navigation): drag project rows to reorder them - #360
Open
paradise-runner wants to merge 1 commit into
Open
paradise-runner wants to merge 1 commit into
paradise-runner wants to merge 1 commit into
Conversation
Pointer drag on a project row reports the neighbor it landed against and the parent persists it through the existing navigation order port, so the stored order, revision checks, and menu Up/Down moves stay the only write path. - listReorder: insertion-slot geometry, drop-target selection, and edge autoscroll velocity, unit tested - ProjectList: pointer candidate with a 4px threshold, accent insert line, Escape to cancel, and the click that ends a drag stays a click when it should - dragging near a list edge scrolls it and keeps the drop slot under the pointer; the loop stops at either end instead of spinning, and a pointer parked at the end of a scrollable list means "end of list" - a touch drag needs a 350ms press and cancels into a scroll if the finger moves first, then blocks the rest of that gesture's scrolling - a fixed ghost of the dragged row follows the pointer, so the project stays identifiable after autoscroll or outside the list - drags do not start from the row menu, and are ignored without an onReorder - browser fixture and specs cover reordering, the threshold, autoscroll, touch, and the ghost - add a minor changeset
paradise-runner
force-pushed
the
feat/project-row-drag
branch
from
October 26, 2026 00:35
aa67aac to
8bf3205
Compare
This branch has not been deployed
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.
What and why
Project rows render in the order they were added, and the only supported way to change that order is the row menu's Move up / Move down — one row and one click at a time. On a phone that menu is the only path, and once a machine has a dozen projects the order stops matching how the work is done.
This adds pointer drag to the project list. Drag a row and an accent line shows where it will land; near the top or bottom edge the list autoscrolls; on touch a short press lifts the row, and moving first scrolls the list instead. The row menu is unchanged, and both paths write through the same navigation order port, so stored order, revision checks, and concurrent browser sessions behave exactly as they do today.
Refs #211. That issue also asks for sort and pin controls, which this does not attempt.
Technical details — optional reading
listReorder.tsholds the pure parts:insertionSlot,dropTarget, andautoscrollStep, each unit tested. A drop reports a neighbor plus before/after rather than an index, so it composes with saved orders that contain entries this view is not showing.ProjectListadds a pointer candidate with a 4px mouse threshold, Escape to cancel, and swallows the click that ends a drag only when a drag actually started.touchmovelistener ends scrolling for that gesture only and is removed on drop or cancel.-webkit-touch-callout: noneis applied to.action-row, which covers machine, workspace, and session rows too — a wider change than the feature strictly needs, called out here deliberately.document.bodywith fixed positioning: inside the shadow root, the navigation panel'scontainer-typecaptures fixed descendants. It carries its own chrome (--pi-surface, border, radius, shadow) and copies only text metrics and layout, so themes do not need duplicating.typecheck, repositorylint,knip, andbuildare clean. 42 unit tests coverProjectList,listReorder, andnavigationOrder.npm run test:browserpasses in chromium, firefox, webkit, and the touch profile, including the newnavigation.spec.tsfixture.aria-liveannouncement for pointer reorders. Keyboard and the row menu remain the accessible path.Automatically generated by the user's AI workflow.