fix(mac): chat thread scroll + tool row preview + unified stop/send - #17
Merged
Conversation
First line of the tool detail (e.g. the bash command) renders at half opacity next to the tool name, so runs are glanceable without expanding. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Two scroll bugs compounded: any geometry change could unpin the viewport (content growth silently killed autoscroll), and the follow trigger only watched the last timeline item, so height changes in earlier rows (tool upserts, LazyVStack re-measure) shifted the viewport with no re-anchor. Now pin state only changes during user-driven scroll phases (tracking/interacting/decelerating), and any contentSize growth while pinned instantly re-anchors to the bottom. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
One smart trailing control replaces the header stop button: red stop while the agent runs, morphs to send the moment a draft or attachment exists, grayed-out send when idle with nothing to send. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c067dfdfca
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
- Keep stop reachable while drafting: when a turn is running and the smart button has morphed to send, a compact red stop button (Cmd+.) appears beside it so a runaway turn can be cancelled without discarding the draft. - Re-anchor the timeline on thread switch: a same-sized timeline changes neither items.count nor contentSize, so the reused ScrollView kept the previous thread's offset. Scroll to bottom on selectedThreadID change. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Main's tool-row rework (PR #16) already ships a richer header preview (kind-aware font, parse cache, middle truncation), so its version wins and this branch's simpler detailPreview is dropped. Scroll logic keeps this branch's phase-gated pinning; the changeToken signature it replaced is removed. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Three chat UX fixes for the native Mac app:
Tool row command preview
The first line of a tool invocation's detail (e.g. the bash command) now renders at half opacity next to the tool name, so each run is glanceable without expanding the dropdown. Expandable detail unchanged.
Timeline scroll: viewport no longer drifts up mid-stream
Two compounding bugs in
ChatTimelineScrollView:tracking/interacting/deceleratingviaonScrollPhaseChange); scrolling back near the bottom re-pins.contentSizegrowth while pinned now re-anchors to the bottom instantly.Net behavior: consistent auto-follow while the agent works; scrolling up to read history still backs off autoscroll.
Unified stop/send button
Header stop button removed. The composer's trailing button is now one smart control: red stop while the agent runs, morphs to send (symbol-replace transition) the moment a draft or attachment exists, grayed-out send when idle with nothing to send. Cmd+Return triggers whichever mode is showing.
Testing
swift build --package-path apps/macclean🤖 Generated with Claude Code