Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(web): expanding stacked notices no longer scrolls a working thread #20086

Mergedderektrimm(GitHub profile, opens in a new tab)merged 4 commits intomain fromrefs/pull/20086/headmerged by juliusmarminge View on GitHub

Expanding stacked composer notices increased timeline padding without immediately scrolling. The next work-row update then moved the thread by that extra padding, and collapse could move it back.

Measure notice growth above the collapsed peek strip and subtract it from the raw overlay height before rounding the timeline reservation. The existing resting-composer allowance and full-overlay clearance remain intact. Expanded notices intentionally cover the last rows, following the maintainer decision on #19880.

Continues @derektrimm's original #20086, preserving the contributor commits and merging main. Retained the useful measurement marker/minimum-height approach; simplified the rounded-height bridge into one subtract-then-round calculation.

Validation:

  • One regression in the existing footer suite, rewritten to carry the reservation through expansion, rest, and collapse: main 41 pass / 1 fail (532px instead of 172px) → head 42 pass. PR-added tests 1 → 1, no new test files.
  • Web typecheck, targeted lint/format, diff check, and 27 scratch fractional-height comparisons pass.
  • Real Linux Chromium ChatView with isolated read-model fixtures, matching 1280×800 viewport, working thread, unsent draft, and two real stacked notices: main's 31.5px expansion increases the scroll range by 32px; the next work row moves scrollTop 809 → 841. Head stays 809 throughout expansion, row arrival, and collapse, with the 12px collapsed strip preserved. Idle expansion/collapse also stays stable.
  • Fixtures render real components; no provider was started, child question opened, branch restored, or shell command executed.

Before — main, expanded notices after the new work row:

Before: expanded notices cause a delayed 32px upward shift in the working timeline

After — head, same state:

After: expanded notices and the new work row preserve the timeline position

Before — expand, new row, collapse:

Before recording

After — expand, new row, collapse:

After recording

Native macOS/Windows, Electron shell, iOS/Android, physical touch, and remote/relay/tunnel clients were not run. This is shared web/desktop layout code; native mobile has a separate composer. Two independent whole-PR reviews found no blockers. Current-head lint, build/typecheck, server tests and focused footer tests pass. Full Web CI remains blocked after one unchanged-head rerun: 8048/8049 tests pass; the unchanged WorkflowOpeningBlock short-script highlighting test exceeds its one-second wait. Both affected preview suites pass all six focused tests. This PR is not CI-ready; see the maintainer follow-up. Unmerged.

Implementation: Codex gpt-6.1-sol (high), tests: Codex gpt-6-astra (high), adversarial reviews: Claude claude-opus-5-5 and Codex gpt-6-sol, through T3 Code.

    1. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    2. Approvability

      Verdict: Approved at 00fe53e

      Macroscope's review found this PR approvable — This is a localized web bug fix that prevents expanded stacked notices from increasing the timeline reservation and causing a later scroll jump. Existing behavior remains unchanged when the optional adjustment is absent, and the new calculation is covered by focused tests.

      You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    3. coderabbitai[bot](GitHub profile, opens in a new tab)commented
      Review in Change Stack →

      Warning

      Review limit reached

      Only developers with an assigned seat can use this organization's usage-based review budget, and seats here are assigned manually. Ask an admin to assign a seat, or change the review continuation mode in Billing.

      Next included review available in 9 minutes.

      Check out review usage here.

      View limit details

      Limit details: You’ve used all 10 included reviews currently available.

      Learn how review limits work.

      Review configuration:

      ⚙️ Run configuration
      • Configuration used: Path: .coderabbit.config.ts
      • Review profile: CHILL
      • Plan: Advanced
      • Run ID: 87a068b0-859a-40e1-97b6-694c2d9c2dd5
      📥 Commits

      Reviewing files that changed from the base of the PR and between 5004d0205e872767f7c35e70d8bb9f63de5fbe81 and 2adb2fc175ce8039eb2ae17073f3674ee6d98fbf.

      📒 Files selected for processing: 4
      • apps/web/src/components/ChatView.tsx
      • apps/web/src/components/chat/ComposerBannerStack.tsx
      • apps/web/src/components/composerFooterLayout.test.ts
      • apps/web/src/components/composerFooterLayout.ts

      No actionable comments were generated in the recent review. 🎉

      ℹ️ Recent review info
      ⚙️ Run configuration
      • Configuration used: Path: .coderabbit.config.ts
      • Review profile: CHILL
      • Plan: Advanced
      • Run ID: 7f6ebd7e-e730-4ad4-aa8a-27761433efcc
      📥 Commits

      Reviewing files that changed from the base of the PR and between e7ed45a8a260d178ff11a68cbe0ae521989bbac8 and 5004d0205e872767f7c35e70d8bb9f63de5fbe81.

      📒 Files selected for processing: 4
      • apps/web/src/components/ChatView.tsx
      • apps/web/src/components/chat/ComposerBannerStack.tsx
      • apps/web/src/components/composerFooterLayout.test.ts
      • apps/web/src/components/composerFooterLayout.ts

      Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

      📝 Walkthrough

      The composer measures expanded notice height and excludes that height from the timeline inset calculation. Tests cover resting and expanded composer states.

      Changes: Composer notice timeline inset

      Layer / File(s)Summary
      Measure and exclude expanded notice height
      apps/web/src/components/composerFooterLayout.ts, apps/web/src/components/chat/ComposerBannerStack.tsx, apps/web/src/components/ChatView.tsx, apps/web/src/components/composerFooterLayout.test.ts
      The inset resolver accepts expanded notice height and subtracts it from the overlay height. The composer measures the notice stack’s growth above its minimum height and passes that value to the resolver. Tests cover resting and expanded composer states.

      Priority: ⬇️ Low

      Estimated code review effort: 2 (Simple) | ~10 minutes

      Change: Bug fix · Severity of issue fixed: Low

      Suggested reviewers: maria-rcks

      Merge Risk: ⚪ Minimal · up to 5004d

      No concrete merge-blocking issue is established in the supplied review evidence; the reported layout change is suitable to merge subject to normal checks.

      Pre-merge checks: Passed 3 · Failed 1
      Failed Failed checks: 1 warning
      Check nameStatusExplanationResolution
      Linked Issues checkWarningIssue [#19880] requires the end-following timeline to move with notice expansion so the last message is not covered, for idle and working threads. This change subtracts expanded notice height from the…Implement the [#19880] expansion behavior that keeps the last message clear for idle and working threads. Add automated coverage for expansion, the next streamed row, and collapse.
      Passed Passed checks: 3 passed
      Check nameStatusExplanation
      Out of Scope Changes checkPassedThe changes stay within the [#19880] composer notice and timeline layout scope. ComposerBannerStack adds the measurement marker, ChatView excludes expanded notice growth from the reservation, and …
      Title checkPassedThe title clearly and concisely describes the primary fix: preventing stacked composer notices from shifting a working thread.
      Description checkPassedThe description is complete and relevant. It explains the problem, the implementation, maintainer-approved scope, focused verification, screenshots, recordings, limitations, and CI status. The content…
      Full details: Out of Scope Changes check

      Explanation

      The changes stay within the [#19880] composer notice and timeline layout scope. ComposerBannerStack adds the measurement marker, ChatView excludes expanded notice growth from the reservation, and composerFooterLayout.test.ts covers the inset calculation.

      Full details: Description check

      Explanation

      The description is complete and relevant. It explains the problem, the implementation, maintainer-approved scope, focused verification, screenshots, recordings, limitations, and CI status. The content does not use the template's explicit section headings, but it contains the required information.

      Full details: Linked Issues check

      Explanation

      Issue [#19880] requires the end-following timeline to move with notice expansion so the last message is not covered, for idle and working threads. This change subtracts expanded notice height from the reserved inset. The added test confirms that the inset remains stable while notices expand. The implementation therefore removes the late jump after a new row, but it intentionally leaves the last rows covered during expansion. The direct issue requirement remains unmet.

      Resolution

      Implement the [#19880] expansion behavior that keeps the last message clear for idle and working threads. Add automated coverage for expansion, the next streamed row, and collapse.

      ✨ Finishing Touches
      🧪 Generate unit tests (beta)
      • Create a new PR
      • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
      Comment `@coderabbitai help` to get the list of available commands.
    4. juliusmarminge assignedjuliusmarminge

    5. Taking over this one. I’ll preserve the intended overlay behavior, rebuild the scroll reservation fix against current main, minimize the tests, and refresh the app evidence.

    6. Pushed 8379462, preserving the contributor commits. Two independent whole-PR reviews are clean; the real-app proof and focused 42-test suite pass. The body includes matched screenshots and recordings.

      The old linked-issue warning is a false positive: the maintainer decision explicitly accepts temporary coverage by expanded notices. The fix must preserve the collapsed reservation and avoid the later jump, rather than scroll on expansion.

      CI is still blocked by the unchanged WorkflowOpeningBlock browser highlighting test after one rerun (run): 8048/8049 tests pass. The first run also timed out in AttachmentFilePreview; that cleared on rerun. A fresh test agent ran both unchanged files together: 6/6 pass. The affected tests/components, highlighting and lazy preview code, configuration, and lockfile match main, and neither fixture mounts the changed composer. No timeout or unrelated source changes were added here. This remains unmerged and not CI-ready; the remaining human gate is resolving or rerunning that existing full-suite timing failure.

    7. The only red job here is the WorkflowOpeningBlock highlighter flake ("shows a short script as highlighted code", expected null not to be null; 528 of 529 web test files passed). #21560 fixed that test and has merged, and main has been green since. The failed run tested a merge commit from before that fix, so a rerun alone would test the same code again: the branch needs main merged in first, and I have left that to you since you own the head.

    8. juliusmarminge merged this48fcf90

    9. juliusmarminge closed this

Sign in to join this conversation.