feat(ui): add pager sidebar toggle#216
Conversation
Greptile SummaryThis PR extends pager mode with a toggleable sidebar file tree, allowing users to press
Confidence Score: 5/5Safe to merge; the change is well-scoped and both unit and PTY integration tests cover the new toggle behaviour. The refactor is minimal and mechanically correct: moving pagerMode before the state declarations, initialising sidebarVisible with !pagerMode, and wiring up the s handler in handlePagerShortcut all work together cleanly. No existing behaviour is broken for non-pager mode. No files require special attention. Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant useAppKeyboardShortcuts
participant App as App.tsx (state)
participant Renderer
Note over App: pagerMode=true, sidebarVisible=false (initial)
App->>Renderer: "renderSidebar = false"
User->>useAppKeyboardShortcuts: press s
useAppKeyboardShortcuts->>App: toggleSidebar()
App->>App: setSidebarVisible(true)
App->>Renderer: "renderSidebar = true"
User->>useAppKeyboardShortcuts: press s again
useAppKeyboardShortcuts->>App: toggleSidebar()
App->>App: setSidebarVisible(false)
App->>Renderer: "renderSidebar = false"
Reviews (1): Last reviewed commit: "feat(ui): add pager sidebar toggle" | Re-trigger Greptile |
Overview
Adds the ability to toggle the sidebar in pager mode. This makes navigating larger diffs a bit easier when using hunk as the pager for
jjorgit.