{config, lib, pkgs, inputs, os, ...} : lib.mkMerge [ (lib.mkIf (os == "linux") { home.file.".mozilla/firefox/default/chrome/theme".source = inputs.firefox-gnome-theme; }) (lib.mkIf (os == "darwin") { home.file."/Users/stephans/Library/Application Support/Firefox/Profiles/default/chrome/theme".source = inputs.firefox-macos-theme; }) { programs.firefox = lib.mkMerge [ (lib.mkIf (os == "darwin") { package = null; }) { enable = true; profiles.default = { isDefault = true; userChrome = if (os == "linux") then '' @import "theme/userChrome.css"; '' else '' @import "theme/chrome/userChrome.css"; @import "theme/custom/singletabhidden.css"; ''; userContent = if (os == "linux") then '' @import "theme/userContent.css"; '' else '' @import "theme/chrome/userContent.css"; ''; settings = { "toolkit.legacyUserProfileCustomizations.stylesheets" = true; # Enable customChrome.cs "browser.uidensity" = 0; # Set UI density to normal "svg.context-properties.content.enabled" = true; # Enable SVG context-propertes "browser.theme.dark-private-windows" = false; # Disable private window dark theme "extensions.autoDisableScopes" = 0; # Auto enable new extentions "browser.toolbars.bookmarks.visibility" = "never"; "gnomeTheme.hideSingleTab" = true; "signon.rememberSignons" = false; "dom.private-attribution.submission.enabled" = false; "app.update.auto" = false; }; extensions = with pkgs.nur.repos.rycee.firefox-addons; [ ublock-origin bitwarden consent-o-matic sponsorblock multi-account-containers ] ++ (if (os == "darwin") then [ onepassword-password-manager ] else [ wayback-machine h264ify fediact tampermonkey ]); search = { default = "DuckDuckGo"; force = true; }; containers = { "Personal" = { color = "green"; icon = "circle"; id = 3; }; "ON2IT" = { color = "orange"; icon = "circle"; id = 1; }; "Lekker van Peet" = { color = "blue"; icon = "circle"; id = 2; }; "Radboud Universiteit" = { color = "red"; icon = "circle"; id = 4; }; "Utrecht University" = { color = "yellow"; icon = "circle"; id = 5; }; }; containersForce = true; }; } ]; } ]