Open Bug 1941921 Opened 22 days ago Updated 21 days ago

Policies - no option for browser.uiCustomization.state placements (like autoconfig.js)

Categories

(Firefox :: Enterprise Policies, enhancement)

Firefox 134
enhancement

Tracking

()

UNCONFIRMED

People

(Reporter: zilexa, Unassigned)

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:134.0) Gecko/20100101 Firefox/134.0

Steps to reproduce:

I used to configure Firefox installations using autoconfig.js (defaultPrefs). However we moved to Fedora Silverblue based OS and none of the system-wide firefox folders that could contain the autoconfig.js file work.
That is OK, because I thought I could switch to policies instead:
https://mozilla.github.io/policy-templates/

Unfortunately, I cannot configure the browser UI customisation state.
With autoconfig, I could do this:
defaultPref("browser.uiCustomization.state", "{"placements":{"widget-overflow-fixed-list":["screenshot-button","print-button","save-to-pocket-button","bookmarks-menu-button","library-button","preferences-button","panic-button"],"nav-bar":["back-button","forward-button","stop-reload-button","customizableui-special-spring1","downloads-button","ublock0_raymondhill_net-browser-action","urlbar-container","customizableui-special-spring2"],"toolbar-menubar":["menubar-items"],"TabsToolbar":["tabbrowser-tabs","new-tab-button","alltabs-button"],"PersonalToolbar":["fxa-toolbar-menu-button","history-panelmenu","personal-bookmarks"]},"seen":["save-to-pocket-button","d133e097-46d9-4ecc-9903-fa6a722a6e0e-browser-action","_contain-facebook-browser-action","sponsorblocker_ajay_app-browser-action","ublock0_raymondhill_net-browser-action","developer-button"],"dirtyAreaCache":["nav-bar","widget-overflow-fixed-list","PersonalToolbar"],"currentVersion":17,"newElementCount":3}");

The Policy templates do not provide a method to configure the UI:
https://mozilla.github.io/policy-templates/

Actual results:

I want to switch completely to policy-templates. But there is a gap in functionality.

Expected results:

An policy-template that allows to configure all elements of the UI as given in the example above.

The Bugbug bot thinks this bug should belong to the 'Firefox::Enterprise Policies' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Enterprise Policies

I cannot edit my comment but this is the actual policy I am testing. The last policy ( "browser.uiCustomization.state" ) is the only one not having any effect:

{ "policies": { "DisableProfileImport": true, "NoDefaultBookmarks": true, "DisplayBookmarksToolbar": "always", "Extensions": { "Install": ["https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi", "https://github.com/bpc-clone/bpc_updates/releases/download/latest/bypass_paywalls_clean-3.7.1.0.xpi", "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/facebook-container/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/google-container/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/nord-polar-night-theme/latest.xpi"]}, "browser.uiCustomization.state": { "Value": "{\"placements\":{\"widget-overflow-fixed-list\":[\"screenshot-button\",\"save-to-pocket-button\",\"logins-button\",\"panic-button\",\"preferences-button\",\"bookmarks-menu-button\"],\"unified-extensions-area\":[\"sponsorblocker_ajay_app-browser-action\",\"_contain-facebook-browser-action\",\"magnolia_12_34-browser-action\"],\"nav-bar\":[\"back-button\",\"forward-button\",\"stop-reload-button\",\"customizableui-special-spring1\",\"downloads-button\",\"ublock0_raymondhill_net-browser-action\",\"urlbar-container\",\"customizableui-special-spring2\",\"_446900e4-71c2-419f-a6a7-df9c091e268b_-browser-action\",\"unified-extensions-button\"],\"toolbar-menubar\":[\"menubar-items\"],\"TabsToolbar\":[\"firefox-view-button\",\"tabbrowser-tabs\",\"new-tab-button\",\"alltabs-button\",\"fullscreen-button\"],\"vertical-tabs\":[],\"PersonalToolbar\":[\"fxa-toolbar-menu-button\",\"history-panelmenu\",\"personal-bookmarks\"]},\"seen\":[\"save-to-pocket-button\",\"developer-button\",\"sponsorblocker_ajay_app-browser-action\",\"ublock0_raymondhill_net-browser-action\",\"_contain-facebook-browser-action\",\"magnolia_12_34-browser-action\",\"_446900e4-71c2-419f-a6a7-df9c091e268b_-browser-action\"],\"dirtyAreaCache\":[\"nav-bar\",\"unified-extensions-area\",\"toolbar-menubar\",\"TabsToolbar\",\"PersonalToolbar\",\"widget-overflow-fixed-list\",\"vertical-tabs\"],\"currentVersion\":20,\"newElementCount\":8}", "Status": "default" } } }

Proper format:

{
  "policies": {
    "DisableProfileImport": true,
    "NoDefaultBookmarks": true,
    "DisplayBookmarksToolbar": "always",
    "Extensions": { 
      "Install": ["https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi", "https://github.com/bpc-clone/bpc_updates/releases/download/latest/bypass_paywalls_clean-3.7.1.0.xpi", "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/facebook-container/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/google-container/latest.xpi", "https://addons.mozilla.org/firefox/downloads/latest/nord-polar-night-theme/latest.xpi"]},
    "browser.uiCustomization.state": {
      "Value": "{\"placements\":{\"widget-overflow-fixed-list\":[\"screenshot-button\",\"save-to-pocket-button\",\"logins-button\",\"panic-button\",\"preferences-button\",\"bookmarks-menu-button\"],\"unified-extensions-area\":[\"sponsorblocker_ajay_app-browser-action\",\"_contain-facebook-browser-action\",\"magnolia_12_34-browser-action\"],\"nav-bar\":[\"back-button\",\"forward-button\",\"stop-reload-button\",\"customizableui-special-spring1\",\"downloads-button\",\"ublock0_raymondhill_net-browser-action\",\"urlbar-container\",\"customizableui-special-spring2\",\"_446900e4-71c2-419f-a6a7-df9c091e268b_-browser-action\",\"unified-extensions-button\"],\"toolbar-menubar\":[\"menubar-items\"],\"TabsToolbar\":[\"firefox-view-button\",\"tabbrowser-tabs\",\"new-tab-button\",\"alltabs-button\",\"fullscreen-button\"],\"vertical-tabs\":[],\"PersonalToolbar\":[\"fxa-toolbar-menu-button\",\"history-panelmenu\",\"personal-bookmarks\"]},\"seen\":[\"save-to-pocket-button\",\"developer-button\",\"sponsorblocker_ajay_app-browser-action\",\"ublock0_raymondhill_net-browser-action\",\"_contain-facebook-browser-action\",\"magnolia_12_34-browser-action\",\"_446900e4-71c2-419f-a6a7-df9c091e268b_-browser-action\"],\"dirtyAreaCache\":[\"nav-bar\",\"unified-extensions-area\",\"toolbar-menubar\",\"TabsToolbar\",\"PersonalToolbar\",\"widget-overflow-fixed-list\",\"vertical-tabs\"],\"currentVersion\":20,\"newElementCount\":8}",
      "Status": "default"
      }
  }    
}
You need to log in before you can comment on or make changes to this bug.