Skip to content

feat(solo): drag to reorder workspaces - #3221

Draft
aaronstressfree wants to merge 4 commits into
block:mainfrom
aaronstressfree:aaronstevens/solo-workspace-reorder
Draft

aaronstressfree wants to merge 4 commits into
block:mainfrom
aaronstressfree:aaronstevens/solo-workspace-reorder

Conversation

@aaronstressfree

@aaronstressfree aaronstressfree commented Nov 10, 2026 •

Copy link
Copy Markdown

In one line: you can now drag your Solo workspaces into the order you want, and the order follows you to your other devices.

Solo workspaces can now be reordered. Drag a workspace heading up or down in the sidebar, or use Move up and Move down in its actions menu. The order saves to your existing Solo groups record, so it syncs to your other devices. Chats stays last.

Before this, Solo workspaces kept their creation order with no way to change it. The Solo sidebar already used the Team sidebar's drag wrapper for moving chats, but workspace reordering was stubbed out (onReorder={() => {}}). The shared preferences store already supported optimistic section reordering; Solo just never supplied a writer for it.

What changed

  • Shared drag hook. The Team sidebar's section drag (drop target, header drag, drop line, and the guard that stops a drag from also toggling the section) moves out of DroppableSidebarSection into useSidebarGroup. Team sections render exactly as before; Solo workspaces now use the same hook.
  • Solo writer. createSoloPreferences gains writeOrder. It re-reads the Solo groups record and sorts its workspaces by the requested order. Workspaces added on another device in the meantime keep their order after the ones the request places.
  • Same-second saves. The Solo groups record is replaceable and refuses a second save within the same wall-clock second. Quick runs of moves (Move down twice, or a drag followed by a chat move) used to fail and snap back. Every fresh read before a Solo write now waits for the next second when the last save was in the same second.
  • Failure notice. A failed reorder shows "Couldn't save the workspace order" with Retry move and Dismiss, matching the Team section notice. Focus stays on the workspace heading.
  • Menu items. Move up and Move down sit in the workspace actions menu and are hidden when the order can't be saved, matching Team sections. The first and last workspaces disable the direction they can't move.
  • Help guide. docs/buzz-help.md describes reordering under Workspaces.

Screenshots

Headless WebKit, from the browser test fixture.

Before the drag: Work, then Home.

Before: Work then Home

Dragging Home above Work: the drag preview shows "Home", the shared drop line sits above Work, and the dragged section dims.

Dragging Home above Work

After the drop: Home, then Work. The order is saved and survives a reload.

After: Home then Work

Workspace menu: Move up and Move down; Move down is disabled on the last workspace.

Workspace menu with Move up and Move down

Testing

  • pnpm typecheck passes. Biome is clean on the changed files.
  • Vitest on src/bundled/channels, src/features/channel-navigation, src/features/relay and src/features/solo: 239 files, 5,139 tests pass. New cases:
    • the reorder saves as the Solo groups order and keeps unplaced workspaces after;
    • back-to-back reorders both save (fails on the pre-fix code with "Please wait a second before saving this recipe again");
    • Move up and Move down reorder, keep Chats last, keep focus, and disable at the ends;
    • a failed move shows the notice, and Retry saves it and keeps focus.
  • Playwright WebKit, solo-chats.spec.mjs (new test: a real pointer drag shows the drop line, saves, keeps the workspace expanded, survives a reload, and a drop on Chats does nothing), plus solo-workspace.spec.mjs and the sidebar contribution, section creation, removal, headings and collapsed-unread specs. All pass. Chromium was not run locally: a local tool on this machine kills headless Chromium, so CI's Chromium shards are the check there.
  • Not checked: the native desktop build (just desktop) and touch devices.

Review FAQ

  • Why wait instead of failing on a same-second save? The record's created_at is in seconds, and the kit refuses an equal-second replacement on purpose. A second move is a normal user action, so the store waits up to one second instead of showing an error. The wait is abortable through the same signals as the rest of the write.
  • Why not reorder Chats? It is the unfiled bucket, not a saved workspace. It has no entry in the groups record to order.
  • Why hide Move up and Move down when the order can't be saved? Team sections do the same.

Pre-merge checklist

  • Manual review still pending from Aaron Stevens

🤖 Generated with Claude Code

Aaron Stevens and others added 4 commits November 10, 2026 10:05
Solo workspaces can now be reordered by dragging their heading, or with
Move up and Move down in the workspace actions menu. The order saves to
the existing Solo groups record, so it syncs across devices. Chats stays
last.

The Team sidebar's section drag moves into a shared useSidebarGroup hook
so both sidebars use the same drop line, drag preview and click guard.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude <c131993609cf92f6f206ebddbd7bda1771bf78a493c47642a315439626ffd2af@buzz>
A real pointer drag shows the drop line, saves the new Solo groups order,
leaves the dragged workspace expanded, and survives a reload.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude <c131993609cf92f6f206ebddbd7bda1771bf78a493c47642a315439626ffd2af@buzz>
A failed workspace move now shows a notice with Retry and Dismiss, and
focus stays on the workspace. Back-to-back moves wait for the next second
instead of failing, since a replaceable record refuses a second save in
the same second. Move up and Move down hide when order cannot be saved,
matching Team sections.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude <c131993609cf92f6f206ebddbd7bda1771bf78a493c47642a315439626ffd2af@buzz>
A chat move or workspace delete right after a reorder hit the same
same-second save refusal, so the wait now runs before every fresh write
read instead of only before reorders. A disabled Retry move says why.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Claude <c131993609cf92f6f206ebddbd7bda1771bf78a493c47642a315439626ffd2af@buzz>

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.

1 participant