Add mouse navigation to menus and dashboard controls #12

Closed
opened 2026-11-16 14:39:25 +00:00 by aaron · 1 comment
Owner

Story

As a TrueNAS user, I want to navigate controls and lists with the mouse so that monitoring fits my workflow.

Context

Parent scope: #7.

src/ui.rs ignores non-key events. Mouse and keyboard should invoke the same actions; later controls must add corresponding hit areas.

Upstream: btop 5d03929a.

Acceptance criteria

  • Support clicking menu controls, option categories/rows and server/app entries, plus scrolling the list or help text under the pointer.
  • Make highlighted dashboard controls clickable as they land, including presets and panel toggles.
  • Hit testing respects the active overlay and current layout; covered or stale controls cannot trigger.
  • Expose disable_mouse without limiting keyboard navigation.
  • Enable/restore terminal mouse capture with TUI startup and cleanup, including error paths.
  • Test click/scroll dispatch, overlay isolation, resizing and disabled mouse input.

Validation

Run focused tests through mise run test --filter <name> and relevant existing mise format/lint tasks. Record interactive or platform checks required by this issue; report anything untested.

Dependencies

Blocked by #9, #10.

## Story As a TrueNAS user, I want to navigate controls and lists with the mouse so that monitoring fits my workflow. ## Context Parent scope: #7. src/ui.rs ignores non-key events. Mouse and keyboard should invoke the same actions; later controls must add corresponding hit areas. Upstream: [btop 5d03929a](https://github.com/aristocratos/btop/tree/5d03929a45e0720a4c8e2d189360ff1eb9ce1731). ## Acceptance criteria - [x] Support clicking menu controls, option categories/rows and server/app entries, plus scrolling the list or help text under the pointer. - [x] Make highlighted dashboard controls clickable as they land, including presets and panel toggles. - [x] Hit testing respects the active overlay and current layout; covered or stale controls cannot trigger. - [x] Expose disable_mouse without limiting keyboard navigation. - [x] Enable/restore terminal mouse capture with TUI startup and cleanup, including error paths. - [x] Test click/scroll dispatch, overlay isolation, resizing and disabled mouse input. ## Validation Run focused tests through `mise run test --filter <name>` and relevant existing mise format/lint tasks. Record interactive or platform checks required by this issue; report anything untested. ## Dependencies Blocked by #9, #10.
aaron added this to the v0.2.0 milestone 2026-11-16 14:41:41 +00:00
Author
Owner

Verified against pushed main at 1a17d5f520. Completing commit: 410e64be62.

Checked mouse hit dispatch, menu/category/row targets, list scrolling, overlay isolation, disabled input and terminal capture cleanup in src/ui/mouse.rs and src/ui.rs. The border-control tests pass at 70x24 and 160x60, including highlighted keys, click actions and non-overlapping targets.

Fresh checks: all 103 Rust/CLI tests, all lint tasks, all-target/all-feature compilation, build, and all 3 Unix installer tests passed on macOS. The owner approved the live UI and panel-border controls. Final cross-platform packaged-binary checks remain in #7.

Closing after verification; the push stopped automatic issue processing at the dependency on #10.

Verified against pushed main at 1a17d5f520b4aee3f38250931223df054858f6fb. Completing commit: 410e64be62ab9718e411682f1a74f2c5130c4f99. Checked mouse hit dispatch, menu/category/row targets, list scrolling, overlay isolation, disabled input and terminal capture cleanup in src/ui/mouse.rs and src/ui.rs. The border-control tests pass at 70x24 and 160x60, including highlighted keys, click actions and non-overlapping targets. Fresh checks: all 103 Rust/CLI tests, all lint tasks, all-target/all-feature compilation, build, and all 3 Unix installer tests passed on macOS. The owner approved the live UI and panel-border controls. Final cross-platform packaged-binary checks remain in #7. Closing after verification; the push stopped automatic issue processing at the dependency on #10.
aaron closed this issue 2026-11-16 17:29:25 +00:00
Sign in to join this conversation.
No description provided.