Skip to content

Agent: one menu for every sidebar task action - #1281

Open
doowta wants to merge 3 commits into
masterfrom
ux/actions-release
Open

doowta wants to merge 3 commits into
masterfrom
ux/actions-release

Conversation

@doowta

@doowta doowta commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Why

  • A hovered task row shows three small buttons that cover its title, and right-clicking a row does nothing.
  • Some task actions live in the hover strip, others only in the "…" menu, so there is no one place to look.

What this PR adds

  • One "…" menu per task, on hover and on right-click at the pointer: Rename, Pin / Unpin, Mark as unread / read, Open folder (this computer), then Settle / Archive / Reopen and a red Delete. Each item shows its letter shortcut.
  • Pinned rows keep a one-click Unpin in the hover strip.
  • A scroll that does not move the list no longer closes an open menu.
Hover Menu Right-click Motion
Before Hovered row on master: More, rename and settle buttons over the title, dark Master's "…" menu: Rename, Pin, Settle / Reopen, Archive, Delete; no shortcuts. The More button on master, light Nothing happens. Hovering rows on master, light
After Hovering a task row shows only the "…" button, dark The "…" menu with Rename, Pin, Mark as unread, Open folder, Settle, Archive and a red Delete, each with its letter, dark Right-click opens the same menu at the pointer, dark Hovering a row, opening the "…" menu, then right-clicking another row

Scroll sideways to compare. Click an image for full size.

Related: independent of #1278 (calmer rows) and #1236 (collapsed rail); all touch the sidebar rows, so whichever lands later gets a small rebase.

Remote: when connected to a paired computer the menu leaves out Open folder (this computer's file manager can't show it); other computers' rows stay navigation-only.

Details for reviewers (commits, design, files, checks)

Commits

  1. Agent: one menu for every task row action
  2. Agent: move a pinned row's pin into its hover strip
  3. Agent: keep a menu open through a zero-distance scroll

Design

  • Every menu goes through popup.rs; right-click uses Placement::At with the captured pointer position, and button-anchored menus follow their row if it moves.
  • Action descriptors and separators are cached when sidebar entries change; labels read live pin and unread state. The sidebar talks to the screen through the existing events.
  • While a sidebar menu is open, all rows (including other computers' rows) suppress hover. Other computers' tasks get no action menu.
  • The list's scroll handler closes menus only when the scroll position actually changed. A zero-distance wheel event from the trackpad used to close the menu right after it opened.
  • The Active / Settled / Archived ladder, paging and activity indicators are unchanged.

Files (under apps/maple-agent/app): assets/icons/eye.svg, src/assets.rs, src/ui/chat/mod.rs, src/ui/chat/sidebar.rs, src/ui/chat/sidebar_computers.rs, src/ui/chat/tests.rs, src/ui/popup.rs. 7 files, +682 / −315 (tests +316 / −46, 5 net added tests).

Checks (component Nix shell, Xcode 26.5, on master e5870485)

  • cargo fmt --all -- --check: passed.
  • cargo clippy -p maple-agent-app --all-targets --locked -- -D warnings: passed.
  • cargo test -p maple-agent-app --locked: 949 passed, 2 ignored.
  • Full workspace CI was not run locally; GitHub CI covers it. The local commit hook was skipped (MAPLE_HOOK_SKIP=1) because of the existing updater test installer::tests::reads_native_release_tar_format_and_preserves_bundle_modes, which fails only on this machine.
  • Checked by hand against master (recordings above).
Full-size images Hovered row on master: More, rename and settle buttons over the title, dark The More button on master, light Hovering rows on master, light Hovering a task row shows only the "…" button, dark The "…" menu with Rename, Pin, Mark as unread, Open folder, Settle, Archive and a red Delete, each with its letter, dark Right-click opens the same menu at the pointer, dark Hovering a row, opening the "…" menu, then right-clicking another row

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@doowta doowta changed the title Proposal: one menu for every sidebar task action Agent: one menu for every sidebar task action Oct 25, 2026
@doowta
doowta marked this pull request as ready for review October 25, 2026 18:40
doowta and others added 3 commits October 25, 2026 14:29
Task rows showed three hover buttons: the menu, Rename, and a step
button whose meaning changed by rung (Settle, Archive, Delete), so rows
were crowded and the right-most button did something different in each
section. There was no right-click menu, and with a task menu open the
hover highlight and buttons stayed on another row or followed the
pointer as the list scrolled.

A row now shows only its "…" button on hover; a pinned row keeps its
pin. A right-click opens the same menu at the pointer. The menu groups
Rename, Pin, and Mark as unread; Open folder (this computer's tasks
only); then Settle, Archive, and Delete, with Reopen and Unarchive in
their places on settled and archived tasks. Each item shows a letter
that picks it while the menu is open, and Delete shows in the error
color; popup items gain a shortcut and a destructive style.

Mark as unread sets the completed-unread marker through a sidebar
event, and Mark as read clears it as opening the task does. While any
sidebar menu is open, rows show no hover state, and scrolling the list,
by the wheel or by stepping to another task, closes the menu.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A pinned row's pin vanished under the hover strip, which reached past
it, so hovering showed only the "…" button with an "Unpin" tooltip over
nothing. A press there passed the pin's element id to the pin toggle
instead of the task's id, so it pinned a stray id and the task stayed
pinned.

The Pinned section already names a pinned row, so the row drops its
resting pin. The hover strip is one trailing row of buttons at the
row's end: "…", then on a pinned row a pin that unpins the task by its
id. The strip no longer needs an offset to clear the pin.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A secondary click can arrive with a stationary wheel event. GPUI calls
the list scroll handler even when its position does not change, so the
sidebar immediately dismissed a task menu that had just opened.

Remember the list position when a menu opens and compare both the item
and pixel offset after scrolling. Defer the read until ListState releases
its mutable borrow. Keep reveal_row's explicit dismissal and remove the
temporary popup tracing now that the real-device close path is known.

Cover zero, horizontal, and clamped wheel events, a one-pixel move, and
reopening after a real scroll. Retain the full right-click sequence test.

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.

1 participant