about summary refs log tree commit diff
path: root/modules/nixos/firefox/default.nix
diff options
context:
space:
mode:
authorAzat Bahawi <azat@bahawi.net>2024-03-03 14:20:46 +0300
committerAzat Bahawi <azat@bahawi.net>2024-03-03 14:20:46 +0300
commit53376afaf1ee4eb5d8e0ffb1ace1ee8f48c71235 (patch)
tree8661c81d8cf75b19a98d9e5db2f439734eb847dc /modules/nixos/firefox/default.nix
parent2024-03-02 (diff)
2024-03-03
Diffstat (limited to '')
-rw-r--r--modules/nixos/firefox/default.nix31
1 files changed, 20 insertions, 11 deletions
diff --git a/modules/nixos/firefox/default.nix b/modules/nixos/firefox/default.nix
index d192ae1..6d1b31b 100644
--- a/modules/nixos/firefox/default.nix
+++ b/modules/nixos/firefox/default.nix
@@ -37,6 +37,7 @@ in {
         profiles.default = let
           mkCssWithRoot = css:
             mkMerge [
+              # https://github.com/tinted-theming/base24/blob/master/styling.md
               (with config.colors.withHashtag; ''
                 :root {
                   --black: ${base01};
@@ -56,17 +57,23 @@ in {
                   --bright-cyan: ${base15};
                   --bright-white: ${base07};
                   --background: ${base00};
-                  --foreground: ${base02};
-              '')
-              (with config.stylix.fonts; ''
-                  --sans-serif-font-family: "${sansSerif.name}", sans-serif;
-                  --sans-serif-font-size: ${toString sizes.applications};
-                  --serif-font-family: "${serif.name}", serif;
-                  --serif-font-size: ${toString sizes.applications};
-                  --monospace-font-family: "${monospace.name}", monospace;
-                  --monospace-font-size: ${toString sizes.applications};
-                }
+                  --foreground: ${base05};
               '')
+              (
+                let
+                  mapFonts = concatMapStringsSep ", " (font: ''"${font}"'');
+                  size = toString config.stylix.fonts.sizes.applications;
+                in
+                  with config.fonts.fontconfig.defaultFonts; ''
+                      --serif-font-family: ${mapFonts serif}, serif;
+                      --serif-font-size: ${size};
+                      --sans-serif-font-family: ${mapFonts sansSerif}, sans-serif;
+                      --sans-serif-font-size: ${size};
+                      --monospace-font-family: ${mapFonts monospace}, monospace;
+                      --monospace-font-size: ${size};
+                    }
+                  ''
+              )
               (builtins.readFile css)
             ];
         in {
@@ -565,6 +572,7 @@ in {
             "browser.disableResetPrompt" = true;
             "browser.download.autohideButton" = false;
             "browser.newtabpage.introShown" = true;
+            "browser.newtabpage.pinned" = "";
             "browser.onboarding.enabled" = false;
             "browser.open.lastDir" = config.my.home;
             "browser.protections_panel.infoMessage.seen" = true;
@@ -575,7 +583,8 @@ in {
             "browser.tabs.closeWindowWithLastTab" = true;
             "browser.tabs.firefox-view" = false;
             "browser.tabs.firefox-view-next" = false;
-            "browser.tabs.inTitlebar" = 1;
+            "browser.tabs.inTitlebar" = 0;
+            "browser.tabs.tabmanager.enabled" = false;
             "browser.tabs.warnOnClose" = false;
             "browser.tabs.warnOnCloseOtherTabs" = false;
             "browser.tabs.warnOnOpen" = false;

Consider giving Nix/NixOS a try! <3