Skip to content

🤖 fix: prevent transcript loading indicator layout flash - #4163

Merged
ammario merged 2 commits into
mainfrom
fix/transcript-loading-layout-flash
Sep 8, 2026
Merged

🤖 fix: prevent transcript loading indicator layout flash#4163
ammario merged 2 commits into
mainfrom
fix/transcript-loading-layout-flash

Conversation

@ammar-agent

@ammar-agent ammar-agent commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Summary

Fix the transcript layout flash caused by the “Loading messages” indicator during history catch-up. Keep loading feedback out of the composer’s normal layout flow so its appearance/removal cannot resize the dock or move cached messages.

Background

Regression introduced by #4125, “🤖 feat: show chat history loading above the composer” (commit d8d368d4bfd49f7b761e6b19d2923b0865458f07). That change inserted a transient 24px row into the in-flow composer dock, changing transcript geometry on workspace switches and catch-up completion.

Implementation

  • Position the compact, non-interactive loading indicator above the dock without consuming layout space. Keep a permanent transcript gutter so the badge cannot cover compact tail rows; the gutter does not toggle with loading.
  • Preserve editable/read-only replay feedback and existing stream/monitor suppression. Yield to “Jump to bottom” while scrolled up so the controls cannot overlap on phones.
  • Extend existing desktop and pinned-phone stories with long cached history, scroll navigation, non-overlap checks against the transcript content boundary, and assertions that catch-up preserves dock height, message position, and scroll height.

Validation

  • make static-check passed.
  • Hydration/reveal and layout-stack unit tests: 8 passed.
  • Chromium Storybook Replay and Phone plays passed, including editable/read-only geometry and phone navigation.
  • Red/green check: returning the loading indicator to normal flow fails both stories on the 24px dock-height change (176 → 152); restoring the fix passes both.
  • Storybook coverage contract passed (38 tests). The separate snapshot-budget tests fail unchanged on the baseline as well (509 estimated snapshots versus a 305 cap); this change adds no stories or viewport variants.

Risks

The indicator is now a small overlay above the composer rather than an extra row. History/subscription state and composer behavior are unchanged. Desktop-agent visual inspection was unavailable in this SSH environment; responsive checks ran in real Chromium via the pinned-phone story.


Generated with xum • Model: openai:gpt-6-astra • Thinking: medium • Cost: $9.15

Keep transient loading feedback out of the in-flow composer dock; add desktop and phone replay geometry regression coverage.

---

_Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `medium` • Cost: `$9.15`_

<!-- mux-attribution: model=openai:gpt-6-astra thinking=medium costs=9.15 -->
@ammar-agent

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 8, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-08T22:07:24.304945Z 096c620 Manual request
🔒 Security Review Completed 2026-09-08T22:07:22.966314Z 096c620 Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

This comment has been minimized.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a77ee000d1

ℹ️ 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".

Comment thread src/browser/components/ChatPane/ChatPane.tsx
---

_Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `medium` • Cost: `$9.15`_

<!-- mux-attribution: model=openai:gpt-6-astra thinking=medium costs=9.15 -->
@ammar-agent

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

This comment has been minimized.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 096c620fb3

ℹ️ 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".

@ammar-agent

Copy link
Copy Markdown
Collaborator Author

Codex approved commit 096c620 with no major issues, and both security reviews reported no security issues. The legacy Codex Comments gate treats the two clean-security informational comments as unresolved findings; marking those informational comments resolved (collapsed, not deleted) so the gate can reflect the actual review result. The substantive tail-overlap finding was fixed and its thread resolved.

@ammario
ammario merged commit 1d1b7b4 into main Sep 8, 2026
35 of 38 checks passed
@ammario
ammario deleted the fix/transcript-loading-layout-flash branch September 8, 2026 22:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants