Repository navigation
Conversation
…iew modules main.rs was doing five jobs at once — terminal setup, input, key resolution, rendering and cleanup — which is why the tree could not grow. The previous attempt at a modular TUI collapsed into a 1,660-line app.rs before c1f1d38 removed it. Give each responsibility its own module so adding a screen is additive rather than another round of untangling main. - tui.rs owns the terminal. Raw mode, alternate screen, paste and focus modes and the keyboard protocol are switched on in one place and released by one idempotent restore(), reached from Drop, the panic hook and normal shutdown, so a panic or an early return can no longer strand a shell without echo. - event.rs reads input on a dedicated thread and translates it into app events, dropping key releases so the keyboard protocol cannot fire a key twice. - action.rs resolves key presses to named actions, reusing OpenCode's ctrl+x leader and action names so its bindings carry over. Adds ctrl+d and <leader>q. - app.rs is the only place state changes; update() reports whether a repaint is needed, so an idle TUI does no work and a burst of events costs one frame. - ui.rs stays pure, which is what will make a frame reproducible from TestBackend. Renders now run inside a synchronized update so a slow repaint shows one whole frame. Resize repaints explicitly instead of relying on an incidental redraw.
…carets and text editing shortcuts
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.