Skip to content

refactor(tui): move rendering into a render module (#526) - #555

Merged
ajianaz merged 1 commit into
developfrom
refactor/tui-render-module
Nov 10, 2026
Merged

ajianaz merged 1 commit into
developfrom
refactor/tui-render-module

Conversation

@ajianaz

@ajianaz ajianaz commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

What

Moves App::draw and the styling helpers (tail, styled, diff_style, inline_spans, wrap) out of crates/tole-tui/src/lib.rs into a new private render module that only reads App.

Why

Part 4 of #526. A second front end should be able to reuse the state machine (and replace or reuse drawing) without the ratatui drawing code living in the same file.

Changes

  • New crates/tole-tui/src/render.rs (moved verbatim, helpers pub(crate)).
  • lib.rs: removed the moved code and the now-unused ratatui imports; tests import what they need.
  • CHANGELOG (Changed), docs/tui.md architecture bullet, docs/epics.md status.

Testing

  • cargo fmt, cargo clippy --workspace --all-targets -- -D warnings clean.
  • 76 tole-tui unit tests and the 5 tui_e2e pty tests pass. Pure move: no new tests, no behavior or public API change.

Closes #526


Generated by Claude Code

@github-actions

Copy link
Copy Markdown

🔍 Cora AI Code Review

✅ No issues found. Code looks good!


Review powered by cora-code · BYOK · MIT

@ajianaz
ajianaz merged commit 5cc95a0 into develop Nov 10, 2026
15 of 16 checks passed
@ajianaz
ajianaz deleted the refactor/tui-render-module branch November 11, 2026 04:10
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.

refactor(tui): separate UI state from terminal input and rendering; slim TuiHost

2 participants