Closed Bug 1714135 Opened 3 years ago Closed 3 years ago

Toolbar elements get pushed when an extension counter badge reaches 3 digits

Categories

(Firefox :: Toolbars and Customization, defect, P1)

Firefox 90
Desktop
All
defect
Points:
3

Tracking

()

VERIFIED FIXED
92 Branch
Tracking Status
firefox-esr78 --- unaffected
firefox89 --- unaffected
firefox90 --- wontfix
firefox91 --- wontfix
firefox92 --- fixed
firefox95 --- verified

People

(Reporter: Fanolian+BMO, Assigned: bigiri)

References

(Blocks 1 open bug, Regressed 1 open bug, Regression)

Details

(Keywords: nightly-community, regression, reproducible, Whiteboard: [proton-cleanups])

Attachments

(4 files)

Attached video extension badge.mp4

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Firefox/91.0
Build ID: 20210601213358

Steps to reproduce

  1. In a new profile, install an extension that provides a toolbar icon with counter badge, e.g. ublock origin or ClearURLs. (ClearURLs is used below for easier setup.)
  2. Click the ClearURLs toolbar icon, make sure "badges" is enabled.
  3. Visit https://www.mozilla.org/en-US/firefox/nightly/firstrun/ and https://www.youtube.com.
  4. Scroll down in YouTube until the ClearURLs counter reaches >100.
  5. Switch between YouTube and firstrun tab. Observe elements on browser toolbar.

Actual result

(Please refer to the attached video.)
Address bar shrinks for a few pixels. Other toolbar buttons, if any, get pushed for a few pixels as well.

Expected result

All toolbar elements stay at their positions and sizes.

Notes

This can be reproduced in Normal and Touch density, but not Compact.
This can be reproduced when flexible spaces are removed.
I do not have a Linux system for testing.

Regression

Last good Nightly: 2021-05-13
First bad Nightly: 2021-05-14
pushlog: https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=940a3ad12e3dc9b2809b02f6a8ac8e941a50d2a1&tochange=ef13365d8188c453af959b13198818f6dbffc833

Bisecting autoland builds:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=4d49ee8d88d5b7b8d3eee36d0e72538844cd0c83&tochange=27548e3039fc2c4ef7d6a55438cbeb502b379e6e
This is regressed by bug 1711083.

Flags: needinfo?(emalysz)
Has Regression Range: --- → yes
Has STR: --- → yes
Regressed by: 1711083
Attached image badge with 4 digits

The address bar shrinks a few more pixels when the badge reaches 4 digits.
The badge is clipped on the right but this is an old bug that is not regressed by 1711083.

I can also reproduce, with Tab Counter.

Status: UNCONFIRMED → NEW
Ever confirmed: true

Set release status flags based on info from the regressing bug 1711083

Thanks for reporting. This issue is ultimately due to the padding we have on the toolbarbutton badges, and like Itiel mentioned, it is reproducible for various types of .toolbarbutton-badge.

We ultimately have to restrict the size of the badges, so I'm not sure how actionable the 4 digit cutoff is. We'll also want to keep the padding for these badges as is to optimize for the Firefox icon badges. I think the actionable item here could be to make sure the toolbarbutton does not move when a badge reaches a certain size.

I'd suggest a low priority (P5) for this issue, since we display the 3 digit count correctly

Flags: needinfo?(emalysz)
Whiteboard: [proton-cleanups]
Severity: -- → S4
OS: Unspecified → All
Hardware: Unspecified → Desktop
Points: --- → 3
Assignee: nobody → bigiri
Status: NEW → ASSIGNED

Set a limit on the width of toolbar elements so that when they expand they do not shift the position of other elements on the toolbar.

Attachment #9230991 - Attachment description: Bug 1714135 - Limit width of toolbar elements so they don't shift the toolbar r=gijs → Bug 1714135 - Limit width of toolbar badges so they don't shift the toolbar r=gijs
Priority: -- → P1
Pushed by bigiri@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/3db744dae210 Limit width of toolbar badges so they don't shift the toolbar r=desktop-theme-reviewers,dao
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 92 Branch
Regressions: 1733844

I was able to reproduce the issue on 91.0 build on Win10x64 and Ubuntu 20.4 and confirmed that the issue is fixed (does not flick - on 95.0b1) but the badge does not display the 4th digit at all after the fix. So reopen the issue in order to fix the badge display (see attached screenshot).

Status: RESOLVED → REOPENED
Resolution: FIXED → ---

(In reply to Monica Chiorean from comment #8)
but the badge does not display the 4th digit at all after the fix. So reopen the issue in order to fix the badge display (see attached screenshot).

Is it bug 1733844?

Flags: needinfo?(monica.chiorean)

The thing that got fixed is that the other toolbar butons moved when the counter exceeded 3 digits. This is fixed, please do not reopen the bug. I agree with Fanolian that the issue you've observed looks like bug 1733844, which we'll fix separately.

Status: REOPENED → RESOLVED
Closed: 3 years ago3 years ago
Resolution: --- → FIXED

(In reply to :Gijs (he/him) from comment #10)

The thing that got fixed is that the other toolbar butons moved when the counter exceeded 3 digits. This is fixed, please do not reopen the bug. I agree with Fanolian that the issue you've observed looks like bug 1733844, which we'll fix separately.

Yes, you are right. I did not know that the issue was already logged. Sorry about the confusion.
I am closing this as fixed and verified on Release 95.0b1 on Win10x64, Ubuntu 20.4 and Mac 10.13. I will add all details to bug 1733844.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Flags: needinfo?(monica.chiorean)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: