Expand description
Modal stack (Goal 146).
A modal is a transient overlay drawn on top of the chat screen.
crate::tui::app::App owns a Vec<Modal>; the topmost element (the
“active” modal) is rendered centred over a half-screen window and
consumes all key events until popped.
Modals never mutate runtime state directly — they are pure
read-only views over App. Side-effects (clear / exit /
compact) are routed through the command system in
[crate::commands] and the input dispatcher in
crate::tui::app::App.
Structs§
- Journal
Entry - A simple read-only journal entry: filename + its first 30 lines.
- McpEntry
- One entry in the
Modal::McpServerslist. - Resume
Entry - One entry in the
Modal::ResumePickerlist.
Enums§
- Confirm
Action - A confirmation request awaiting
y/n. - Modal
- All modal flavours the TUI knows how to render.
Functions§
- load_
journal_ from - Pure helper: read journal entries from
dir. Exposed so tests can point at a tempdir. - load_
recent_ journal_ entries - Read up to
max_entries.mdfiles from.dev/journal/, sorted by modification time descending. Each entry’s preview is the first 30 lines. - load_
recent_ sessions - Load up to
limitrecent sessions fromworkspace, sorted byupdated_atdescending. Silently skips dirs with missing/corrupt metadata. - render
- Render the topmost modal centred on the frame area.
- render_
plan_ review - Goal-147: render the body of a
Modal::PlanReview.