aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorJoshua Fern <JoshuaFern@protonmail.com>2020-03-09 06:39:37 +0000
committerRobert Helgesson <robert@rycee.net>2020-03-15 18:26:37 +0100
commit2681568f2b1278b4265b9c46b87e9583145facaa (patch)
treeb7b8cac362dd647ebb4fade160296e0d33c4a2e0 /modules
parent5c1e7349bbd9b51fe41ea96b67c380feef996b90 (diff)
firefox: support user content CSS
The `userContent.css` file is similar to `userChrome.css`, it's a CSS file that you can use to change the way web sites and e-mails look. See http://kb.mozillazine.org/index.php?title=UserContent.css PR #1079
Diffstat (limited to 'modules')
-rw-r--r--modules/programs/firefox.nix17
1 files changed, 16 insertions, 1 deletions
diff --git a/modules/programs/firefox.nix b/modules/programs/firefox.nix
index 17c64752d66..7f2367eb06d 100644
--- a/modules/programs/firefox.nix
+++ b/modules/programs/firefox.nix
@@ -137,7 +137,7 @@ in
userChrome = mkOption {
type = types.lines;
default = "";
- description = "Custom Firefox CSS.";
+ description = "Custom Firefox user chrome CSS.";
example = ''
/* Hide tab bar in FF Quantum */
@-moz-document url("chrome://browser/content/browser.xul") {
@@ -153,6 +153,16 @@ in
'';
};
+ userContent = mkOption {
+ type = types.lines;
+ default = "";
+ description = "Custom Firefox user content CSS.";
+ example = ''
+ /* Hide scrollbar in FF Quantum */
+ *{scrollbar-width:none !important}
+ '';
+ };
+
path = mkOption {
type = types.str;
default = name;
@@ -295,6 +305,11 @@ in
text = profile.userChrome;
};
+ "${profilesPath}/${profile.path}/chrome/userContent.css" =
+ mkIf (profile.userContent != "") {
+ text = profile.userContent;
+ };
+
"${profilesPath}/${profile.path}/user.js" =
mkIf (profile.settings != {} || profile.extraConfig != "") {
text = mkUserJs profile.settings profile.extraConfig;