0
Fork 0
mirror of https://codeberg.org/librewolf/source.git synced 2024-12-22 13:43:04 -05:00
LibreWolf/patches/hide-passwordmgr.patch
2024-06-15 17:26:09 +02:00

29 lines
836 B
Diff

--- a/browser/base/content/browser-init.js
+++ b/browser/base/content/browser-init.js
@@ -300,6 +300,13 @@ var gBrowserInit = {
)?.removeAttribute("key");
}
+ if (Services.prefs.getBoolPref("librewolf.hidePasswdmgr", false)) {
+ PanelMultiView.getViewNode(
+ document,
+ "appMenu-passwords-button"
+ )?.remove();
+ }
+
this._loadHandled = true;
},
--- a/browser/components/preferences/privacy.js
+++ b/browser/components/preferences/privacy.js
@@ -1214,6 +1214,10 @@ var gPrivacyPane = {
this.initWebAuthn();
+ if (Services.prefs.getBoolPref("librewolf.hidePasswdmgr", false)) {
+ document.getElementById("passwordsGroup")?.remove();
+ }
+
// Notify observers that the UI is now ready
Services.obs.notifyObservers(window, "privacy-pane-loaded");
},