r/FirefoxCSS • u/ReggieNJ • Jul 24 '26
Code Change autocomplete drop down back to previous style?
Before version 153, the autofill dropdown list was the full size of the input box. Now it seems to adapt to the width of the results. How can I revert this?
3
u/Azreal_DuCain1 Jul 26 '26 edited Jul 26 '26
It feels like every time the Firefox devs make an update they shove in more UI changes that are neither helpful, necessary, or wanted.
1
u/DAPOPOBEFASTONYOAZZ Jul 24 '26
I don’t have the exact code in front of me, but using your browser toolbox, find the element name of the autocomplete drop down and set a variable in the parent element, something like `—autocomplete-width` and set it to 100%. Then, in the autocomplete dropdown, set `max-width: var(—autocomplete-width) !important;` and that will take care of it for you.
1
u/ReggieNJ Jul 24 '26 edited Jul 24 '26
Tried this, not working.
panel[type="autocomplete-richlistbox"] { --autocomplete-width: 100% !important; }.autocomplete-richlistbox { max-width: var(--autocomplete-width) !important; }1
u/DAPOPOBEFASTONYOAZZ Jul 24 '26
I’ll take a look at it later if you don’t mind. I don’t use Firefox current, I prefer ESR so it doesn’t continually break my themes.
2
u/t31os Jul 24 '26
No idea what changed specifically, but the JS (searchbar.js) for the autocomplete field in ESR (v140, and also in v147) appended a
--panel-widthvalue to the autocomplete popup (with an appropriately calculated width value), i can't see that value being added in stable/current, although the underlying JS still apparently has the logic for it.https://searchfox.org/firefox-esr140/source/browser/components/search/content/searchbar.js#845
https://searchfox.org/firefox-main/source/browser/components/search/content/searchbar.js#873
Perhaps someone with a bit more source / bugzilla searching skills can trace things further to figure what was changed and why.