Set correct Gnome settings for dark mode (#16)

This commit is contained in:
Aidan Pinard 2022-11-04 15:25:50 -04:00 committed by GitHub
parent 5b9c63851a
commit 081ce971ed
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -5,11 +5,24 @@
config.lib.stylix.mkEnableTarget "GNOME" true;
config.home-manager.sharedModules =
lib.mkIf config.stylix.targets.gnome.enable [{
dconf.settings."org/gnome/desktop/background" = {
color-shading-type = "solid";
picture-options = "zoom";
picture-uri = "file://${config.stylix.image}";
};
}];
if config.stylix.polarity == "dark"
then
lib.mkIf config.stylix.targets.gnome.enable [{
dconf.settings."org/gnome/desktop/background" = {
color-shading-type = "solid";
picture-options = "zoom";
picture-uri-dark = "file://${config.stylix.image}";
};
dconf.settings."org/gnome/desktop/interface" = {
color-scheme = "prefer-dark";
};
}]
else
lib.mkIf config.stylix.targets.gnome.enable [{
dconf.settings."org/gnome/desktop/background" = {
color-shading-type = "solid";
picture-options = "zoom";
picture-uri = "file://${config.stylix.image}";
};
}];
}