Closed Bug 2050846 Opened 22 days ago Closed 6 days ago

Double border on keyboard navigation for Search Engine Switcher engines in Alpenglow theme

Categories

(Toolkit :: Themes, defect, P2)

defect

Tracking

()

VERIFIED FIXED
154 Branch
Tracking Status
firefox-esr115 --- unaffected
firefox-esr140 --- unaffected
firefox152 --- wontfix
firefox153 --- verified
firefox154 --- verified

People

(Reporter: phorea, Assigned: daisuke)

References

(Blocks 2 open bugs, Regression)

Details

(Keywords: regression)

Attachments

(3 files)

Attached image double border

Notes
Reproduces also when Nova is enabled.

Found in

  • Firefox 154.0a1

Affected versions

  • Firefox Nightly 154.0a1;
  • Firefox 153 beta 4;
  • Firefox 152.0.3 RC.

Tested platforms

  • Affected platform: Windows 11, Ubuntu 24, macOS 15;
  • Unaffected platforms: N/A;

Steps to reproduce

  1. Go to about:addons > Themes and enable Alpenglow theme
  2. Open Search Engine Switcher from address bar
  3. Use Down arrow to navigate between the listed search engines

Expected result

  • Uncertain what the expected result is: Before bug 1998985, hover and keyboard navigation on search engines from Search Mode Switcher had the same visual effect. Now, the keyboard navigation displays a border. If this is expected, Alpenglow should not have a double border. Otherwise, keyboard selection should have the same effect as hover, with a slightly different color.

Actual result

  • Alpenglow theme for all platforms and System Default theme - Ubuntu display a double border on keyboard selection.

Regression range

:mbeier, since you are the author of the regressor, bug 1998985, could you take a look? Also, could you set the severity field?

For more information, please visit BugBot documentation.

Flags: needinfo?(mbeier)
Blocks: ipc-urlbar
Severity: -- → S4
Priority: -- → P2
Whiteboard: [sng]
Blocks: 2010269
No longer blocks: ipc-urlbar
Whiteboard: [sng] → [sng][mcab-hnt]
Depends on: 1826841
Whiteboard: [sng][mcab-hnt] → [sng]
Component: Address Bar → Themes
Product: Firefox → Toolkit
Whiteboard: [sng]

Hi Dão!

I looked into this one. The focus ring here is shown via :focus-visible. In panel-item.css we only set outline-offset and none of the other outline properties, so outline-style ends up as auto.
https://searchfox.org/firefox-main/rev/a07b2cb8ff33387a81968a7ed9d59ebdc4dad607/toolkit/content/widgets/panel-list/panel-item.css#47-49

For auto, Theme intentionally draws a two-tone double ring (PaintAutoStyleOutline: an inner 2px stroke plus an outer 1px stroke).
https://searchfox.org/firefox-main/rev/a07b2cb8ff33387a81968a7ed9d59ebdc4dad607/widget/Theme.cpp#1323-1332

It uses the accent color, but Alpenglow doesn't specify one, so the default colors are used (primary: blue, secondary: white). That's why it shows up like this here.
So, this might not really be a bug, but rather intentional behavior. How do you think we should handle it?
FWIW, setting outline-style to solid gives single white line border with this theme.

Flags: needinfo?(dao+bmo)

Thanks Daisuke, I also just looked into it but could not figure out why it didn't respect the outline-color property.

Flags: needinfo?(mbeier)

(In reply to Daisuke Akatsuka (:daisuke) from comment #2)

Hi Dão!

I looked into this one. The focus ring here is shown via :focus-visible. In panel-item.css we only set outline-offset and none of the other outline properties, so outline-style ends up as auto.
https://searchfox.org/firefox-main/rev/a07b2cb8ff33387a81968a7ed9d59ebdc4dad607/toolkit/content/widgets/panel-list/panel-item.css#47-49

auto is a safe default for the web, erring on the side of making sure it's visible. We don't need that here. I think outline: var(--focus-outline); outline-offset: var(--focus-outline-inset); should do the trick?

Flags: needinfo?(dao+bmo)

Thank you very much, Moritz and Dão!

(In reply to Dão Gottwald [:dao] from comment #4)

I think outline: var(--focus-outline); outline-offset: var(--focus-outline-inset); should do the trick?

Okay, I will try it.

Assignee: nobody → daisuke
Status: NEW → ASSIGNED
Pushed by dgottwald@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/159f9ad11f36 https://hg.mozilla.org/integration/autoland/rev/93510f4e5ae6 Set outline style explicitly for :focus-visible in panel-item r=desktop-theme-reviewers,dao
Status: ASSIGNED → RESOLVED
Closed: 6 days ago
Resolution: --- → FIXED
Target Milestone: --- → 154 Branch

The patch landed in nightly and beta is affected.
:daisuke, is this bug important enough to require an uplift?

For more information, please visit BugBot documentation.

Flags: needinfo?(daisuke)
No longer depends on: 1826841
See Also: → 1826841
Attachment #9608713 - Flags: approval-mozilla-beta?

firefox-beta Uplift Approval Request

  • User impact if declined/Reason for urgency: Recent cosmetic regression from bug 1998985
  • Code covered by automated testing?: no
  • Fix verified in Nightly?: yes
  • Needs manual QE testing?: yes
  • Steps to reproduce for manual QE testing: see comment 0
  • Risk associated with taking this patch: low
  • Explanation of risk level: Trivial CSS fix
  • String changes made/needed?: none
  • Is Android affected?: no
Flags: qe-verify+
Flags: needinfo?(daisuke)
Attachment #9608713 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Reproducible on a 2026-06-26 Firefox Nightly build on Windows 11.

Verified as fixed on Firefox Nightly 154.0a1 on Windows 11, macOS 13, Ubuntu 24.

Verified as fixed on Firefox 153.0b13 (treeherder build) on Windows 11, macOS 13, Ubuntu 22.

Status: RESOLVED → VERIFIED
QA Whiteboard: [QA-5205][S4][qa-found-in-c154] → [QA-5205][S4][qa-found-in-c154][qa-ver-done-c154/b153]
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: