Skip to content

Comments

feat: Core TUI model + log list with virtual scrolling (closes #12)#14

Merged
clarabennettdev merged 1 commit intomainfrom
feature/tui-core-scrolling
Feb 20, 2026
Merged

feat: Core TUI model + log list with virtual scrolling (closes #12)#14
clarabennettdev merged 1 commit intomainfrom
feature/tui-core-scrolling

Conversation

@clarabennettdev
Copy link
Owner

Changes

  • Expanded TUI model with log line buffer, virtual scrolling (O(1) rendering regardless of buffer size)
  • Keyboard navigation: j/k, arrows, g/G, pgup/pgdown, d/u half-page
  • Auto-scroll to bottom on new entries; disables when user scrolls up
  • LogMsg/LogBatchMsg/ErrMsg message types for source integration
  • Status bar with line count, scroll position, source name
  • Terminal resize handling with viewport recalculation
  • Wired file sources into TUI mode in main.go
  • 22 tests covering scrolling, clamping, resize, auto-scroll, batch messages

Closes #12

- Expand Model with log entry buffer and virtual scrolling
- Only render visible lines (offset:offset+viewHeight) for O(1) View()
- Keyboard navigation: j/k, g/G, pgup/pgdown, half-page d/u
- Auto-scroll to bottom on new entries, disable on manual scroll up
- LogMsg/LogBatchMsg/ErrMsg types for source→TUI communication
- ListenForLines() wires sources to tea.Program via goroutines
- Status bar showing line count, scroll position, source info
- Wire file sources into TUI mode in main.go
- Comprehensive tests for scrolling, resize, auto-scroll behavior

Closes #12
@clarabennettdev clarabennettdev merged commit 35941eb into main Feb 20, 2026
4 checks passed
@clarabennettdev clarabennettdev deleted the feature/tui-core-scrolling branch February 20, 2026 01:03
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.

Core TUI model + log list with virtual scrolling

1 participant