tui: mouse support — click, scroll, drag #112
Labels
No labels
area:agents
area:ai
area:config
area:dashboard
area:design
area:design-review
area:devtools
area:entities
area:gallery
area:generate
area:image
area:infra
area:meta
area:model-browser
area:navigation
area:presets
area:security
area:sessions
area:settings
area:sharing
area:test
area:ux
area:webhook
area:workdir
type:bug
type:chore
type:meta
type:user-story
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
charles/loom#112
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
User story
As a user, I want to click on UI elements, scroll lists with the mouse wheel, and drag to pan images, so that the TUI feels natural alongside keyboard navigation.
Problem
crossterm::EnableMouseCaptureis already enabled interminal::init(), but noEvent::Mousehandling exists anywhere in the app. Mouse events are received by the event stream but silently dropped.Acceptance criteria
Click to select
Scroll
Drag
Event plumbing
Event::Mouse(MouseEvent)variant toevent.rsEventStreamforwards crossterm mouse eventsScreen::handle()receives mouse events (screens ignore what they don't handle)Overlay::handle()receives mouse eventsfn hit_test(rect: Rect, mouse: MouseEvent) -> boolConfiguration
tui.tomlsupportsmouse_enabled = true(default) /falseDisableMouseCaptureis used instead and no mouse events are processedOut of scope
References
crates/loom-tui/src/terminal.rs—EnableMouseCapturealready presentcrates/loom-tui/src/event.rs—Eventenum,EventStreamcrates/loom-tui/src/app.rs—process_event()dispatchcrossterm::event::MouseEvent,MouseEventKind