feat(tui): left-align start page, enrich tool result & sub-agent rendering#3
Merged
Merged
Conversation
…ering Start page: the welcome key column is now flush-left (padRight) instead of right-aligned, so commands and their descriptions share a clean left edge. Tool results: tool_result now retains a sanitized, line-capped excerpt (resultPreview) instead of a single collapsed line. renderSteps draws it as a tree (⎿) — multi-line, blank-stripped, capped at 5 lines with a "+N more lines" footer — and tints the status glyph ✗ when the output reads as a failure (looksLikeError). argPreview now also surfaces prompt/task/description fields so delegations show their task. Sub-agents: a delegating tool_call is flagged via isSubagent and labelled "sub-agent"; subsequent subagent_log events nest beneath it as its own branch of the step tree (attachSubLog), falling back to a notice when there is no wrapping step. Tests cover padRight, isSubagent, looksLikeError, resultExcerpt, resultPreview, sub-agent log nesting, and the enriched step rendering; internal/tui statement coverage holds at 96%+. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UHpZVF8Lm1cyZXM6L4a6vn
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.
Start page: the welcome key column is now flush-left (padRight) instead of
right-aligned, so commands and their descriptions share a clean left edge.
Tool results: tool_result now retains a sanitized, line-capped excerpt
(resultPreview) instead of a single collapsed line. renderSteps draws it as a
tree (⎿) — multi-line, blank-stripped, capped at 5 lines with a "+N more
lines" footer — and tints the status glyph ✗ when the output reads as a
failure (looksLikeError). argPreview now also surfaces prompt/task/description
fields so delegations show their task.
Sub-agents: a delegating tool_call is flagged via isSubagent and labelled
"sub-agent"; subsequent subagent_log events nest beneath it as its own branch
of the step tree (attachSubLog), falling back to a notice when there is no
wrapping step.
Tests cover padRight, isSubagent, looksLikeError, resultExcerpt,
resultPreview, sub-agent log nesting, and the enriched step rendering;
internal/tui statement coverage holds at 96%+.
Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01UHpZVF8Lm1cyZXM6L4a6vn