fix(web): chat text no longer shows through a 1px gap under composer banners #10635
main fromrefs/pull/10635/head·merged by juliusmarminge View on GitHubReplaces #8551, which GitHub would not reopen after the backlog sweep; that PR's closure reason (my own Aug 31 comment) was superseded by the Sep 3 measurements on main after #8734, repeated below.
Closes #8546.
What Changed#
On 125% and 150% displays, a crisp line of chat text shows through a one-pixel gap between any attached composer banner ("Monitoring", offline, "This thread is snoozed", "Resume with less context") and the composer. It looks like a rendering glitch every time the timeline scrolls under the banner.
One line in apps/web/src/components/chat/ComposerBanner.tsx: the banner's glass mask now ends one pixel below the seam instead of exactly on it, so the banner paints the row the composer never reaches. The composer's own glass sits over that pixel, so the overlap is invisible.
Why#
Chromium drops the last device-pixel row of a backdrop-filter surface when its mask cut-off lands between device pixels, and the composer surface starts exactly at that cut-off, so nothing paints the row. A border or shadow on the composer cannot reach it; only the banner's own mask can. A fixed 1px (not scaled with the 1rem overlap) because this repairs a device-pixel rounding artefact, not a layout distance.
UI Changes#
Dark theme, DPR 1.25, collapsed resting composer with the snoozed notice attached, chat text scrolled under the join. Before, then after:
Seam at 4×, before and after:
No motion, so no video.
Verification#
- Measured in the running app with Playwright, 208 viewport/scroll configurations per DPR on
mainvs this commit: crisp-text leaks at DPR 1.25 / 1.5 / 2 go from 24 / 21 / 0 to 0 / 0 / 0. Rows above the seam are byte-identical before and after. - The production Tailwind build emits the arbitrary value with valid spacing, matching the sibling
+ 10pxvalue on the same element. - At DPR 2 in a 1400-px window the banner bottom lands on a whole device pixel, which is why a Retina window of that size never shows the bug and why it went unreported for a while.
Measurement history and alternatives tried
Per-device-row luminance at the cut-off (Rec. 709), collapsed composer:
| before | after | |
|---|---|---|
| cut-off row peak | 75 | 30 |
| neighbour mean | 18.9 | 18.9 |
| peak / neighbour ratio | 3.97 | 1.59 |
Alternatives, 224 configurations (7 DPRs × 8 sub-pixel phases × ancestor transform × light/dark):
| approach | leaking configs |
|---|---|
main | 48 |
border-top or box-shadow: inset 0 1px 0 on the composer | 48 |
a separate strip with the same tokens + backdrop-filter | 30 |
| mask bleed 1px | 0 |
Original report (macOS desktop app, "Resume with less context" banner):
Expanded composer with the offline banner, before and after:
History: #8733 removed the masked overlap and #8734 restored it into ComposerBanner.tsx, which is where the fix now lives.
Checklist#
- This PR is small and focused
- I explained what changed and why
- I included before/after screenshots for any UI changes
- I included a video for animation/interaction changes (nothing moves)
Built with Claude Fable 5 in Claude Code.
Note
Fix 1px gap showing chat text under composer banner in Chromium#
Adjusts the surface pseudo-element mask gradient in ComposerBanner.tsx so the opaque cutoff sits one pixel before the attachment overlap. This covers a Chromium backdrop-filter seam that let chat text bleed through.
- Risk: changes the rendered boundary of attached and floating glass surfaces by extending the masked region one pixel toward the attachment seam
Summary by CodeRabbit#
- Bug Fixes
- Adjusted the chat composer’s visual mask cutoff to prevent a subtle rendering artifact in Chromium.
- Preserved the existing shadow appearance.
- 1
github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted
github-actions[bot](GitHub profile, opens in a new tab) added labelssize:XS
Approvability#
Verdict: Approved at
4bcb1f0Macroscope's review found this PR approvable — This is a narrowly scoped CSS mask adjustment in the composer banner component that fixes a one-pixel visual seam. Its runtime impact is limited to banner surface rendering, with no API, data, security, or deployment changes.
You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Team
Run ID:
2f4fd9ce-4afc-407e-990f-f404d5620adb📥 Commits
Reviewing files that changed from the base of the PR and between 8588d7f63bf57e6285daafe035708cc22a99619c and 3f83ea3294ec8a81ab7ce0a5b86f2ce15cceba8e.
📒 Files selected for processing (1)
apps/web/src/components/chat/ComposerBanner.tsx
Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review.
📝 Walkthrough
Walkthrough#
The composer banner mask cutoff moves one pixel earlier to prevent a visible seam caused by Chromium filtered-backdrop rendering.
Changes#
Composer surface rendering
Layer / File(s) Summary Adjust banner mask cutoff
apps/web/src/components/chat/ComposerBanner.tsxThe Surfacemask transitions to black at one pixel before the attachment overlap. A comment documents the Chromium device-pixel behavior.Estimated code review effort: 1 (Trivial) | ~3 minutes
Severity of issue fixed: Low
Merge Risk: ⚪ Minimal · up to
3f83eAttached composer banners now cover the fractional-scale Chromium seam without changing surrounding rows. No current merge-blocking risk remains.
Suggested reviewers:
maria-rcks,juliusmarminge,t3dotgg🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation Title check ✅ Passed The title clearly and concisely describes the primary fix: preventing a 1px chat-text gap under composer banners. Description check ✅ Passed The description includes the required What Changed, Why, UI Changes, and Checklist sections. It provides screenshots, explains the Chromium rendering cause, and documents verification results. Linked Issues check ✅ Passed The change directly addresses issue [ #8546] by extending the ComposerBanner glass mask by 1px to prevent the uncovered device-pixel row at the banner-composer seam.Out of Scope Changes check ✅ Passed The pull request contains one small, focused change in ComposerBanner.tsx. No unrelated code or scope expansion is present. Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 1 files. ✨ Finishing Touches
🧪 Generate unit tests (beta)
- Create PR with unit tests
Comment `@coderabbitai help` to get the list of available commands.juliusmarminge merged this11601da
juliusmarminge closed this
Sign in to join this conversation.
macroscopeapp[bot](GitHub profile, opens in a new tab) approved these changes