Repository navigation
fix(app): keep long prompts folded during session creation - #64452
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
The fix works. With Fold long messages on, the preparing screen now shows the 8-line preview with Read more, and the message keeps the same height through the handoff to the timeline.
How I checked: I ran the new regression test in a built Chromium app.
- It fails on the base: the prompt shows in full and there's no Read more.
- It passes with this PR.
- With only the
foldprop andmeasure()called directly again, it still fails on the first-painted height (569px vs 238px). So both parts of the change are needed.
The session-ui message unit tests and tsc -b for both changed packages pass.
Public API: unchanged.
No blocking concerns. One small thing: a fold opened with Read more on the preparing screen isn't carried over, so it folds again when the timeline takes over. That's probably fine for a screen that only shows for a short time.
Related: #64276
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.


Issue for this PR
Reported in a screen recording during worktree creation.
Type of change
What does this PR do?
With Fold long messages on, a long prompt now shows its eight-line preview as soon as “Creating worktree” appears. The preparing screen uses the same setting as the timeline, and the shared bubble measures wrapped text once its surrounding view has mounted, before the first paint.
How did you verify your code works?
bun run check, changed-file lint, 122 focused unit tests, and five built Chromium tests passed.Visual
Both screenshots show the same prompt during worktree creation at 1280 × 900 with the light theme and folding enabled.
Before (
34d93d4cd5) — the preparing screen shows all 17 lines.After (
1a272cd29e) — the prompt opens with an eight-line preview and “Read more”.Checklist
Added by the opencode bot (AI-generated).
Related: #64276