nixos-laptop/home-manager/firefox/default.nix

38 lines
1 KiB
Nix

{
pkgs,
lib,
config,
...
}: let
firefoxAddons = import ./addons.nix pkgs lib;
firefoxSettings = {
"browser.aboutConfig.showWarning" = false;
"browser.toolbars.bookmarks.visibility" = "always";
"browser.tabs.firefox-view" = false;
"browser.shell.checkDefaultBrowser" = false;
"browser.translations.automaticallyPopup" = false;
"signon.rememberSignons" = false;
"media.webspeech.synth.dont_notify_on_error" = true;
"browser.gesture.swipe.left" = false;
"browser.gesture.swipe.right" = false;
"browser.newtabpage.activity-stream.showSponsored" = false;
"browser.newtabpage.activity-stream.showSponsoredTopSites" = false;
};
cfg = config.pim.firefox;
in {
options.pim.firefox.enable = lib.mkEnableOption "firefox";
config = lib.mkIf cfg.enable {
programs.firefox = {
enable = true;
profiles = {
default = {
id = 0;
isDefault = true;
settings = firefoxSettings;
extensions = firefoxAddons;
};
};
};
};
}