Outline of address bar focus ring obscured when in search mode with no engines or results
Categories
(Firefox :: Address Bar, defect, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr78 | --- | unaffected |
firefox82 | --- | wontfix |
firefox83 | --- | fixed |
People
(Reporter: heycam, Assigned: bugzilla)
References
(Regression)
Details
(Keywords: regression)
Attachments
(2 files)
See the attached screen shot. When I press Ctrl+K, the orange (here on Linux) focus ring around the address bar is not painted on the bottom edge, which looks a bit weird.
Updated•4 years ago
|
Assignee | ||
Comment 1•4 years ago
|
||
I can't reproduce on macOS. Cameron, it seems like you don't have any one-offs or search history in your screenshot, which is unexpected. Have you unchecked most/all of the engines under about:preferences#search > Search Shortcuts? Also what is the value of the pref browser.urlbar.maxHistoricalSearchSuggestions
?
Assignee | ||
Updated•4 years ago
|
Reporter | ||
Comment 2•4 years ago
|
||
Yes, that is exactly what I've done. I have removed all but DuckDuckGo from the Search Shortcuts list. I also have unchecked "Provide search suggestions". My browser.urlbar.maxHistoricalSearchSuggestions value is 2, which looks like the default.
Assignee | ||
Comment 3•4 years ago
|
||
Ah, now I can reproduce. Thank you.
Assignee | ||
Comment 4•4 years ago
|
||
Hm, I can no longer reproduce this, including with a fresh profile and by rolling back to a Nightly from a few days ago. Cameron, can you still reproduce on the latest Nightly? If so, could you please post the values of browser.urlbar.update2
and all the browser.urlbar.update2.*
prefs?
Reporter | ||
Comment 5•4 years ago
•
|
||
I can still reproduce on current Nightly.
browser.urlbar.update2 true
browser.urlbar.update2.disableOneOffsHorizontalKeyNavigation true
browser.urlbar.update2.emptySearchBehavior 2
browser.urlbar.update2.localOneOffs true
browser.urlbar.update2.oneOffsRefresh true
browser.urlbar.update2.restyleBrowsingHistoryAsSearch true
browser.urlbar.update2.tabToComplete true
Comment 6•4 years ago
|
||
Assignee | ||
Comment 7•4 years ago
|
||
Thanks, Marco.
Assignee | ||
Comment 8•4 years ago
|
||
This was more difficult to solve than I expected. The main issue is that the
[open]
attribute on #urlbar
wasn't accurate when the view was "open" but
there were no results or one-offs, so it was in fact closed. This broke a few
style rules.
This bug can also be reached when the user has no engines and clears the search
string while in search mode. This includes pressing Accel+K when typing a search
string while not in search mode.
The relationship between the UrlbarView and the one-offs is complex and depends
on a lot of listeners and async calls made in synchronous contexts. Furthermore,
most of the UrlbarView open/close code is synchronous, but checking the number
of engines (to determine if the one-offs will open) is an async operation. These
factors make it difficult for the view to discern any state about the one-offs
and plan accordingly.
First I tried adding a [oneoff] attribute to .urlbarView, set asynchronously when
the one-offs are built. Then I changed CSS rules to check
.urlbarView:not([noresults]),
.urlbarView[oneoffs]
instead of just #urlbar[open]
. This approach would've required changing
a bunch of CSS from the simple #urlbar[open]
to the more complicated CSS
above, which was not good for code readability. Also it would keep [open]
in
a weird useless state where it couldn't really be trusted. This would've caused
other styling problems.
I settled on adding a .then
call around the affected UrlbarView opening. The
view opens only if we are sure that we will have either results or one-offs,
so we can once again trust the [open]
parameter. This approach has its
drawbacks. Mainly, it's a more JavaScript-heavy solution so it's possibly
slow. Thankfully, it's something that can be easily cached.
Assignee | ||
Updated•4 years ago
|
Updated•4 years ago
|
Comment 10•4 years ago
|
||
bugherder |
Updated•4 years ago
|
Description
•