Repository navigation
Description
Related: #6 (Menu is one of the five verbs: "the same menu the tray opens"), #17 (chat needs a front door), #18 (tray, settings — the menu's sibling surface), #84 (Do Not Disturb needs a manual switch), #148 (the consent surface needs a home), #154 (asking for computer use starts from chat).
Why
Right-click is already a Verb: the Engine emits and accepts Menu, and nothing answers — the README says so outright. Meanwhile every recent spec needs an entry point: chat (#17) is reachable only by knowing the double-click, Do Not Disturb (#84) has an engine switch nothing calls, character switching (#18) has no UI, and the consent surface (#148) has no home. A UI-less app's one discoverable gesture is right-click on the thing itself. This issue is the front door.
Scope
Right-click on the sprite opens the menu at the cursor — the only entry point this issue ships, and today the app's only possible one: there is no tray icon yet and no OS bundle, only cargo run. Build the menu as its own component anyway, because #6's wording ("the same menu the tray opens") makes it the tray's menu too the day #18 adds one — that day adds an entry point, not a second menu.
v1 items, each an existing or specced mechanism, no new capability:
- Chat… — Summon (Chat surface #17). Until the chat surface exists, the item performs today's Summon (accepted, visibly nothing) — the menu ships before its richest item.
- Character ▸ — the installed packages by name (the loader's search already enumerates them), check-marked current, switch on select. This is the "menu to change Character" Tray and settings #18 promised; restart-free switching is its own acceptance line.
- Do Not Disturb — checkbox calling
Engine::set_do_not_disturb, the switch that exists and is never called. Manual toggle here; macOS Focus auto-detection stays Do Not Disturb: the buddy stays, and stops starting things #84's. - Hide — parity with the hotkey (same instant hide path).
- What the buddy can see… — entry point reserved for Consent-gated capabilities are unreachable: nothing ever tells the user a grant exists #148's consent surface; until it exists, the item is absent (not disabled — nothing pretends).
- Quit.
Mechanics: the shell already decides click-through per tick and the Menu verb already arrives from the right-button press over drawn pixels; on Menu, pop a native context menu at the cursor (Tauri/muda menu — machinery that works in the unbundled cargo run dev build, which is the only way the app runs today; verify that early, it is the issue's one platform risk). While the menu is open, the sprite pauses politely (no chase, no wander — the Engine already has the not-now gates; verify Menu holds them). Menu actions arrive as shell commands; none of them enter the frame loop.
Out of scope: the settings window, autostart, updater (all #18); any menu item that would need an Executor (ADR-0003); per-Instance menus (single Engine today).
Acceptance
- Right-click on the sprite opens the menu at the cursor; right-click anywhere else passes through to the desktop as today.
- Character ▸ lists what
installed()finds, switches without restart, and the switch survives the next launch (or explicitly documents that persistence is Tray and settings #18's settings). - The DND checkbox flips
set_do_not_disturband the buddy audibly quiets: no self-started Behaviors, no dialogue, Poke still works (Do Not Disturb: the buddy stays, and stops starting things #84's semantics, already engine-tested). - Hide from the menu behaves exactly like the hotkey.
- Engine: the Menu verb during walk/chase/drag interrupts like a Poke does (or holds — decide and pin it).
Tests
Engine-side: Menu verb interplay pinned in engine tests. Shell-side: menu construction from a fake installed-characters list (items, checkmarks) as a pure function; the popping itself is manual verification, like the overlay.
Activity
feat(menu): implement context menu on right-click (#155)
fix(linux): leave context menu unimplemented on Linux for now
fix(linux): leave context menu unimplemented on Linux for now
fix(linux): cfg-gate muda to macOS only in Cargo.toml
fix(linux): cfg-gate muda to macOS only in Cargo.toml
feat(menu): implement context menu on right-click (#155) (#170)
omesser commentedon Sep 1, 2026
Implemented and merged in #170 (
d1125dbf7). Recording what landed, what is deferred, and the one check that is still outstanding — this issue did not auto-close, and it should not until that check is done.Landed
Right-click over drawn pixels opens a native context menu at the cursor. Rows: Chat…, Character ▸, Do Not Disturb, Hide, Quit.
The shape is worth knowing, because it is what makes the menu portable and what #18's tray will reuse:
menu::describe()returns aMenuDescriptionof plain rows — owned strings and bools, so it crosses a thread — with no#[cfg]anywhere inmenu.rsand nine tests that run on every platform.menu::show()builds the native menu from that description on the main thread and pops it withpopup_menu_at, throughtauri::menurather than a directmudadependency. One copy of muda in the binary, and no raw view handle.Verb::Menu, with a timeout and a close signal so a menu dismissed with Escape cannot hold a buddy forever.Verb::Menuis the press edge of the right button, so holding it does not restack menus, and a right-click during a drag emits both Menu and Grab — the drag survives.Still to check by hand
Right-click the sprite and choose Do Not Disturb. The buddy should go quiet.
This decides whether
popup_menu_atis modal on macOS, which decides whether a selection can be lost:If the toggle does nothing, the fix is to send the close signal after the selection rather than after
show()returns.Deliberately deferred, so it is not lost
Closeable once the Do Not Disturb click is confirmed.
omesser commentedon Sep 2, 2026
Do Not Disturb manually confirmed on macos to work
omesser commentedon Sep 2, 2026
The Do Not Disturb checkbox now also sits a Character that was walking, via #204. Quiet is sit, not just silence.