Closed Bug 1998902 Opened 10 months ago Closed 14 days ago

github.com - Blank space on the right side of the page

Categories

(Web Compatibility :: Site Reports, defect, P2)

ARM
Android

Tracking

(Webcompat Priority:P2, Webcompat Score:6, firefox158 fixed)

RESOLVED FIXED
Webcompat Priority P2
Webcompat Score 6
Tracking Status
firefox158 --- fixed

People

(Reporter: ctanase, Unassigned)

References

()

Details

(Keywords: webcompat:platform-bug, webcompat:site-report, Whiteboard: [webcompat-source:web-bugs][webcompat:sightline][webcompat:japan][webcompat:core])

User Story

user-impact-score:300
platform:android
impact:significant-visual
configuration:general
affects:all
branch:release
diagnosis-team:layout

Attachments

(6 files)

Environment:
Operating system: Android 15
Firefox version: Firefox Mobile 144.0/146

Steps to reproduce:

  1. Go to https://github.com/webcompat/web-bugs/milestone/2
  2. Observe the page.

Expected Behavior:
The page content fits the entire screen.

Actual Behavior:
Blank space on the right side of the page.

Notes:

  • If not reproducible by just accessing the page, try zooming out
  • Reproduces regardless of the status of ETP
  • Reproduces in firefox-nightly, and firefox-release
  • Does not reproduce in chrome

Created from https://github.com/webcompat/web-bugs/issues/186370

Attached image image.png —
Whiteboard: [webcompat-source:web-bugs] → [webcompat-source:web-bugs][webcompat:sightline][webcompat:japan]
User Story: (updated)
Webcompat Score: --- → 1
Severity: -- → S4
User Story: (updated)
Webcompat Priority: --- → P2
Webcompat Score: 1 → 6
Priority: -- → P2

I can reproduce in responsive design mode on desktop. I captured a copy of the page with the Singlefile extension, which also reproduces the bug, and we can create a more reduced testcase from that.

Attachment #9529692 - Attachment description: testcase 1 (created with singlefile) → testcase 1 (created with singlefile; view in RDM to see the bug)
Attached file testcase 3 —

I tried to reduce the case even more. The margin is clearly visible with a red background.

I did some investigation, following those steps:

  • Open Fenix
  • In Settings, enable Remote debugging via USB
  • Load the testcase on Fenix.
  • Plug the device into my computer. Open about:debugging on Firefox Desktop
  • Find my device in the list of available devices and Click connect
  • Select the tab containing the testcase.

This will open the dev tools, that we can further use to investigate.
Disclaimer: I'm not super familiar with webcompat in general, so take those results with a grain of salt.

Results:

  • I've found that removing the chips in each row of the table (browser-firefox, os-linux, and so on) does seem to solve the issue.
  • Executing this in the console happens to resolve the issue too:
document.documentElement.style.overflowX = "hidden";
document.body.style.overflowX = "hidden";

I'm not sure which conclusion we can get from that, is it somehow helpful?

Daniel, what are the best next steps here?

Flags: needinfo?(dholbert)

Needs more testcase-minimizing/diagnosis to understand the problem. I'll aim to do some of that in the next day or two; leaving ni open.

(And thanks to titouan for the testcase-reducing - I'm sure that'll be helpful!)

This is a targeted workaround that "fixes" it:

      .sr-only { display: none !important }

That sr-only element is a 1px-by-1px element that I think is a tooltip for the "chips", and it has some styles to attempt to make it not paint (notably the clip-path):

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: rect(0 0 0 0);
  overflow-wrap: normal;
  border: 0;
}

...but apparently it does still contribute to layout enough to influence scrollport-size calculations (and cause the viewport to shrink).
(EDIT: and we get its position incorrect due to bug 489100; see below)

Flags: needinfo?(dholbert)

I think this is essentially a version of bug 489100; I think part of the issue is that we're positoining that abspos element with respect to a display:inline abspos-containing-block, specifically this in the attached testcase:

<span class="Title-module__trailingBadgesContainer--mijcn">

which has these styles applied in the attached testcase (combined with its default display:inline styling):

.Title-module__trailingBadgesContainer--mijcn {
	overflow: hidden;
	position: relative;
	text-overflow: ellipsis;
	top: 1px;
	vertical-align: top;
}

If I add a style element that gives that class display: inline-block like so....

<style>.Title-module__trailingBadgesContainer--mijcn { display: inline-block }</style>

...then the issue goes away (in the latest testcase as well as the original SingleFile testcase).

That in-and-of-itself isn't really a fix, since it does change the layout (the chips end up linewrapping a bit differently). But it's a nice way to confirm that abspos-in-inline-elements (.sr-only within a span with class Title-module__trailingBadgesContainer--mijcn) is the basic diagnosis here.

Attachment #9534693 - Attachment description: testcase-reduced.html → testcase 3
Attached file testcase 4 —
Duplicate of this bug: 2017128
Whiteboard: [webcompat-source:web-bugs][webcompat:sightline][webcompat:japan] → [webcompat-source:web-bugs][webcompat:sightline][webcompat:japan][webcompat:core]

I see the expected behavior with layout.abspos.fragment-aware-inline-cb.enabled=true (introduced in bug 489100). The page content fits the entire screen in responsive design mode. We'll flip the pref by default in bug 2041551.

Status: NEW → RESOLVED
Closed: 4 months ago
Duplicate of bug: 489100
Resolution: --- → DUPLICATE

Reopening the bug and making it depend on bug 2041551.

Status: RESOLVED → REOPENED
Depends on: 2041551
No longer duplicate of bug: 489100
Resolution: DUPLICATE → ---

Fixed, the issue no longer reproduces.

Tested with:

  • Browser / Version: Firefox Nightly 158
  • Operating System: Google Pixel 5 (Android 14)
Status: REOPENED → RESOLVED
Closed: 4 months ago → 14 days ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: