Skip to content

feat: add native plan decisions to the TUI - #88

Closed
jefft72 wants to merge 1 commit into
plan/09-tui-ownershipfrom
plan/10-tui-workflow
Closed

jefft72 wants to merge 1 commit into
plan/09-tui-ownershipfrom
plan/10-tui-workflow

Conversation

@jefft72

@jefft72 jefft72 commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Presents submitted plans in the TUI: a rendered plan artifact in the transcript, plan state in the footer and tree selector, and a decision prompt that reopens only at safe lifecycle boundaries.

This is the second half of #72.

Reasoning

A submitted plan previously had no interactive affordance, so a user could not accept or reject one without leaving the session.
The decision prompt is suppressed rather than force-reopened after an explicit dismissal, because repeatedly stealing the editor for a plan the user has already set aside is worse than requiring /plan to reopen it.

Plan state is surfaced in the tree selector so navigating to a point with a waiting continuation is visible rather than silent.

Changes

  • Adds PlanMessageComponent to render plan artifacts in the transcript
  • Surfaces plan state in the footer and the tree selector
  • Opens the plan decision only when idle, not streaming, and not behind another overlay
  • Preserves startup prompts and restored continuations across navigation and rebind
  • Adds plan message, tree selector, footer, and startup input coverage

Testing

  • npx vitest --run test/plan-message.test.ts test/tree-selector.test.ts test/footer-width.test.ts test/interactive-mode-startup-input.test.ts
  • tsgo --noEmit reports zero errors

Render submitted plans as transcript artifacts, expose plan state in footer and tree views, and reopen decisions only at safe interactive lifecycle boundaries. Preserve startup prompts and restored continuations across navigation and session rebinds.
@Pepps233
Pepps233 self-requested a review August 16, 2026 18:50
@Pepps233 Pepps233 added enhancement New feature or request UI coding-agent labels Aug 16, 2026
@Pepps233
Pepps233 requested a review from Issacboy123 August 16, 2026 18:51

@Issacboy123 Issacboy123 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Making plans first-class transcript artifacts with a dedicated decision UI is the right direction. That UI is also the human authorization surface, but it omits some raw Markdown fields, such as link titles, which the implementation prompt still receives. Have the decision component and continuation consume the same canonical representation. Essentially, #79 is where the markdown issue originates from, while #88 exposes the issue to the user.

box.addChild(new Spacer(1));
box.addChild(
new Markdown(
plan.markdown,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Markdown renderer omits source metadata such as link titles, while acceptance later sends the raw plan.markdown to the implementation model. Please render or canonicalize the exact representation that will be sent so the user cannot approve a view that hides instructions.

@Pepps233 Pepps233 closed this Sep 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

coding-agent enhancement New feature or request UI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants