Repository navigation
Conversation
|
This PR doesn't fully meet our contributing guidelines and PR template. What needs to be fixed:
Please edit this PR description to address the above within 72 hours, or it will be automatically closed. If you believe this was flagged incorrectly, please let a maintainer know. |
|
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
There was a problem hiding this comment.
Looks good. I ran the TUI from source with the simulated model applying a patch to a file with long lines, at 180 columns in split view. On the base, the diff runs to the right edge of the tool block; with this change it stops 3 columns short, matching the left inset, and long lines still wrap cleanly (screenshots below). The simulated model couldn't call edit in this setup, so only the patch block was rendered; Edit gets the same one-line change. tsc -b and the session tests in packages/tui pass.
Public API: unchanged.
No concerns.
|
This pull request has been automatically closed because it was not updated to meet our contributing guidelines within the 72-hour window. Feel free to open a new pull request that follows our guidelines. |


Issue for this PR
No issue. Requested directly.
Type of change
What does this PR do?
Edit and patch diffs in the session transcript ran all the way to the right edge of their tool block, with no right padding. This adds
paddingRight={3}to the diff wrappers inEditandApplyPatch, which matches the block's 3 columns of left inset (the block'spaddingLeft={2}plus the wrapper'spaddingLeft={1}). It covers split and unified views. Other tool blocks are unchanged.How did you verify your code works?
opencode driveagainst this branch and againstdev, using a simulated model that runseditandpatchon files with long lines. Captured split view at 171 and 180 columns and unified view at 100 columns.bun run checkpasses.bun testinpackages/tui: the only failures (dialog-shell-output,go-upsell-art) also fail ondev.Screenshots / recordings
Patch, split view, 180 columns
Before:

After:

Edit, split view, 171 columns
Before:

After:

Patch, unified view, 100 columns
Before:

After:

Other tool blocks (not changed in this PR)
Shell, write and question blocks have the same problem: long lines wrap right at the block's right edge, while the left side has 2 columns of padding. They all share
BlockTool, which only pads the left. Shown at 171 columns:Shell:

Write:

Question:

Checklist
Requested by: @Tarquinen (dan via Slack)