#2151
feat: pin Spaces to the rail
Pull Request
Related Issue
N/A. This is maintainer-directed work, part of the plan in #2113.
Description
Draft. Part 2 of 3. It's based on #2150 (the rail with Home and Settings), so this diff shows only what this part adds. Review and merge #2150 first.
Problem
The rail shows only the active Space. Moving between Spaces still means opening the Space switcher. Nothing shows whether another Space has a running Task or is waiting for a reply.
Fix
- Pins:
- People can pin up to five Spaces to the rail. Pins are saved per account on this device.
- The active Space keeps a dashed tile until it's pinned, so the rail always shows where the Space view is.
- Right-clicking a tile, or pressing Shift+F10 or the Menu key, opens Open, Pin / Unpin Space, Rename, Space settings, and Move up / Move down.
- Choose pinned Spaces: when all five pins are taken, pinning another Space opens a popover. It lists every Space. People can pin and unpin there, and reorder by dragging or with the arrow keys. A screen reader announces each move.
- Shortcuts:
- ⌥⌘1–5 on macOS (⇧⌘3–5 take screenshots there) and Ctrl+Shift+1–5 on Windows and Linux open the pinned Spaces in order.
- They're listed in the View menu and the shortcuts dialog. The existing ⌘1–⌘5, ⇧⌘H, ⌘, and ⌘N are unchanged.
- Status dots:
- A new read-only backend endpoint,
GET /runs/attention, reports every Session that has a running Run or one waiting for the user: a question, an Approval orwaiting_for_user. Waiting outranks running. - The rail reads it every 5 seconds while the window is focused, and right away when a Run's status changes or the backend restarts. It stops while the window is hidden or in the background.
- Each tile's accessible name includes the counts, for example "Research, 1 waiting for your reply".
- A new read-only backend endpoint,
- Space menu: the Space switcher in the top bar becomes a menu for the current Space. It has Rename, Space settings, Memory settings, the working folder's pending changes and version history, and Pin / Unpin Space. Moving to other Spaces is done from the rail.
- Space sidebar:
- The Space itself is the first row and opens its Workspace page (⌘1).
- New session (⌘N) takes the Workspace tab's place.
Testing
npm run type-checkandnpm run check:i18npass on this branch.- Full
vitestrun: no new failures. The tests that fail here fail onmaintoo, apart from two that depend on the local setup: the Electron build-config test, and the session-execution integration test, which needs a running backend. - New unit tests:
- the pins store: pin, unpin, reorder, the five-pin limit, archived and deleted Spaces, account switch, and the persist round trip;
- the chooser and the tile menu;
useSpaceAttention: merging, the poll pausing while hidden, and stale Session ids;- the shortcuts in the native menu, plus the shortcut catalog parity test;
- the Space menu.
- New backend contract test,
backend/tests/app/controller/test_run_attention.py: a running Run, an open Approval, an open question and a finished Run (4 passed). - Not yet tested by hand. Screenshots will follow before this leaves Draft.
Testing Evidence (REQUIRED)
- I have included human-verified testing evidence in this PR.
- This PR includes frontend/UI changes, and I attached screenshot(s) or screen recording(s).
- No frontend/UI changes in this PR.
Manual testing and screenshots are still to do.
What is the purpose of this pull request?
- Bug fix
- New Feature
- Documentation update
- Other
Contribution Guidelines Acknowledgement
- I have read and agree to the Eigent Contribution Guideline
Activity
3This pull request is a draft
Merging is unavailable until it is marked ready for review.