SwiftUI: reveal message timestamps on swipe - #8620
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
ApprovabilityVerdict: Not approved Macroscope's review found this PR not approvable — This adds a substantial user-facing iOS transcript interaction involving gesture arbitration, row overlays, streaming updates, accessibility, and bottom-anchor scrolling. Its production behavior extends well beyond a small isolated UI tweak, so the interaction and scrolling impact should receive human review. You can add or adjust custom eligibility rules. Learn more. |
…eveal Two review findings on the swipe-to-reveal timestamps feature: Eligibility (streaming -> complete) decided a structural branch around the message view, so completing a stream rebuilt the row and dropped MarkdownMessageView's @State, breaking its streaming -> complete promote path. The message view now sits at one fixed structural position and only the timestamp overlay is conditional; the accessibility modifier branches on role, which never changes, and announces an empty value while a message is still streaming. Dismissing the reveal zeroed the anchors immediately, so timestamps faded out while drifting to their row midpoints and the transcript re-anchored mid-dismissal. beginDismissal() now only zeroes the width; the anchors survive the slide-back and are cleared by the release animation's completion, guarded by a generation counter so a stale completion cannot settle a newer gesture. The collection view mirrors timestampReveal.isActive on every update so resets that bypass the completion cannot leave the bottom-anchor suppression stuck on. Co-Authored-By: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit e87bce8. Configure here.

What Changed
The implementation and focused tests stay in the existing transcript owner:
apps/swift-ios/Features/Chat/ThreadDetailView.swiftapps/swift-ios/Tests/FeatureTests/TranscriptViewportGeometryTests.swiftWhy
The SwiftUI client had no quick way to inspect several message times in context. The reveal belongs at the transcript boundary because the collection view already owns visible-row geometry, scrolling, snapshot completion, and gesture arbitration.
The pan recognizer accepts one finger and requires clear horizontal intent. It yields to vertical scrolling, selectable Markdown, and nested horizontal scrollers such as code blocks. The reveal resets when the gesture ends or when a thread update leaves no eligible messages.
This supersedes #5820. PR 8620 is based on
t3code/rebuild-mobile-app-swiftatb67837984e5650888b1eed0e1cd7fff83625f696; the current head isbfb058405a28d78e87eec3923475720180744507.UI Changes
The previous media links were removed because anonymous GET requests returned HTTP 404 pages. Older issue-112 captures also predate the three follow-up fixes on this PR and are not current-head proof.
The replacement packet is blocked on a SwiftUI proof lease. At the latest atomic allocation attempt, all three contracted simulator slots were active:
pr-7453-proof-refreshnon-git-dot-entry-visibilitypr-7399-proof-refreshNo simulator was taken and no lease was bypassed.
When a slot is free, the replacement packet will be captured from exact base
b67837984and exact headbfb058405using the repository timeline workflow:Review fixes already on this head
6d96bd988keeps message identity and timestamp anchors through streaming completion.e87bce8fcrestores the bottom position during a reveal when the transcript is following the latest message.bfb058405refreshes timestamp anchors after that scroll completes.All four review threads are resolved. Cursor Bugbot's latest review completed successfully. Macroscope's correctness check passed; its approvability check still calls for human review because this is a substantial transcript interaction.
Verification
Check: passed onbfb058405.Test: passed onbfb058405.Contract fixtures and native tests: passed onbfb058405.bfb058405.bfb058405.git diff --check: clean locally.Risks and limitations
size:XLbecause it adds the transcript interaction and focused geometry, gesture, anchoring, streaming, and accessibility coverage. It is one SwiftUI-only outcome, but it is not a small patch.Checklist