Closed Bug 1687828 Opened 3 years ago Closed 3 years ago

A scrollbar is briefly shown when transitioning a panelview between subviews

Categories

(Firefox :: Menus, defect)

defect

Tracking

()

RESOLVED FIXED
86 Branch
Tracking Status
firefox86 --- fixed

People

(Reporter: mconley, Assigned: molly)

References

(Blocks 1 open bug, Regressed 1 open bug)

Details

(Whiteboard: [proton-hamburger-menu])

Attachments

(1 file)

The easiest way to see this right now probably is to:

  1. Enable Proton (browser.proton.enabled set to true)
  2. Open a new window
  3. Open the AppMenu/Hamburger menu, and click on "Library"
  4. Note during the transition a brief appearance of a vertical scrollbar on the panel

This isn't Proton-specific - it looks this can happen when transitioning between a short subview to a tall subview.

Thankfully, PanelMultiView.jsm (the thing that powers <panelmultiview> elements) adds a transitioning="true" attribute on the panelview as it's transitioning, which we can maybe use to add overflow-y: hidden; on the subview when that attribute is present.

Note that PanelMultiView.jsm also has this cleanup function which might be relevant: https://searchfox.org/mozilla-central/rev/2c06b16a0c15ae340a0532e319cbf89ef9d21b68/browser/components/customizableui/PanelMultiView.jsm#1109-1148

It looks like there's effort to disable scrollbars entirely for things with panel-viewcontainer class.

My tentative suggestion is to add something like this:

panelmultiview[transitioning] > .panel-viewcontainer > .panel-viewstack > panelview > .panel-subview-body {
  overflow-y: hidden;
}

somewhere within https://searchfox.org/mozilla-central/rev/2c06b16a0c15ae340a0532e319cbf89ef9d21b68/browser/themes/shared/customizableui/panelUI.inc.css

In... theory that might work? But I haven't tried it.

Do you have a few moments to see if that CSS would work?

Flags: needinfo?(mhowell)

That does appear to work; the scrollbar is gone and I don't see any other artifacts. Patch forthcoming.

Flags: needinfo?(mhowell)
Assignee: nobody → mhowell
Status: NEW → ASSIGNED
Pushed by mhowell@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/01d0075921df
Prevent a temporary scrollbar while transitioning between subviews of a panelmultiview. r=mconley
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 86 Branch
Regressions: 1711864
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: