Skip to content

fix(messages): support mouse selection and scrolling - #404

Merged
fcoury merged 4 commits into
mainfrom
fcoury/messages-dialog-mouse
Oct 17, 2026
Merged

fcoury merged 4 commits into
mainfrom
fcoury/messages-dialog-mouse

Conversation

@fcoury-oai

Copy link
Copy Markdown
Collaborator

The Messages dialog ignored mouse input, so selecting a notification or scrolling its details required the keyboard. This adds click selection on both the summary and metadata rows, wheel navigation over the message list, and independent scrolling over the detail pane.

Rendering and hit testing share the same layout, including the narrow stacked view and scrolled lists. Click actions carry the notification ID so a notice moving from active to history does not change which message is selected. Detail scrolling clamps at the visible bottom, allowing the next upward gesture to respond immediately.

How to Test

  1. On macOS/Linux, launch cargo run --bin red -- -c 'disable_ai = true' README.md. Run :!seq 1 60 and :!echo second-message, using Esc to return to editing as needed, then open :messages. Click a summary and then another message's timestamp row; the selection and details should follow each click.
  2. Scroll over the list to browse messages, then select the seq message and scroll over its details to scroll only that pane. Scroll beyond the detail bottom, then upward; the first upward gesture should move the content.
  3. Search for seq with / and click the matching message. Resize the terminal to about 64 columns to use the stacked layout and repeat selection and scrolling. Clicking blank space or a border should leave the selection unchanged.
  4. Press Esc to return to the unchanged buffer. Selecting an active message should not acknowledge it.

Focused automated coverage:

cargo test --locked --lib ui::messages
cargo test --locked --lib notification

These cover responsive hit testing, pane-specific scroll bounds, and editor routing that preserves notification identity without acknowledging messages or editing the buffer.

Validation

  • Native Terminal mouse checks passed in wide and stacked layouts, including search, scrolling past the bottom, and keyboard navigation. The maintainer also completed the manual retest successfully.
  • All 67 focused tests and all-target/all-feature Clippy passed in a separate validation checkout using cached dependency versions. Formatting and diff checks passed.
  • The validation environment could not resolve locked Wasmtime 48.0.6. Its cached validation lock used Wasmtime/Pulley 48.0.5, Cranelift 0.135.5, chacha20 0.10.1, and historical Windows dependency resolution. The committed Cargo.lock is unchanged; these results do not establish validation against that exact lockfile.

fcoury-oai and others added 2 commits October 15, 2026 16:31
A second command sent to an RPC plugin that is still starting was refused
with a default-priority warning, which the foreground "is starting"
notice hid until it expired about 4 seconds later. The refusal answers the
keypress, so it now replaces that notice right away.

The delay also left the lazy-initialization test about 1 second before
the plugin's 5-second initialize timeout, which slower Windows runners
now exceed.
@fcoury-oai

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-17T00:14:16.627126Z 613c689 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 613c68937f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/ui/messages.rs Resolved
@fcoury
fcoury merged commit 7a138ee into main Oct 17, 2026
12 checks passed
@fcoury
fcoury deleted the fcoury/messages-dialog-mouse branch October 17, 2026 01:00
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.

2 participants