feat: make the Activity tab navigable and easier to read

Activity rows are now a cursor list: ↑↓ (and the scroll wheel) move the
highlight, Enter jumps to that repo and opens its detail. Each row shows
a precise local timestamp (MM-DD HH:MM) instead of only a relative age,
colour-codes the kind, colours the repo by its project and widens that
column so long workspace paths are readable, and keeps the relative age
as a dim suffix on the detail. A › marks rows whose repo is still in the
workspace (Enter-able).
This commit is contained in:
dualfroz committed 2026-07-11 22:25:55 +02:00
1 parent abb1e92064
commit 4723d18c59
5 files changed
+107 -39

No files matched your search

+8
View File
@@ -187,7 +187,15 @@ pub fn tui_phase(state: &mut HubState, existing_term: Option<crate::tui::Tty>) -
}
if let Some(Event::Mouse(m)) = &event {
let on_activity = state.tab == Tab::Activity;
match m.kind {
MouseEventKind::ScrollDown if on_activity => {
let n = state.activity_filtered().len();
if n > 0 && state.activity_cursor + 1 < n { state.activity_cursor += 1; }
}
MouseEventKind::ScrollUp if on_activity => {
state.activity_cursor = state.activity_cursor.saturating_sub(1);
}
MouseEventKind::ScrollDown => { state.scroll_down(); }
MouseEventKind::ScrollUp => { state.scroll_up(); }
_ => {}