desktop: Add options for theme/opacity/fontSize

This commit is contained in:
Donovan Glover 2024-04-07 12:30:50 -04:00
parent 8fb6142ddd
commit 9fa0aa4206
No known key found for this signature in database
GPG Key ID: EA7408A77AE1BE65

View File

@ -1,15 +1,13 @@
{ nix-config, pkgs, config, lib, ... }: { nix-config, pkgs, config, lib, ... }:
let let
inherit (lib) mkEnableOption mkIf mkMerge; inherit (lib) mkEnableOption mkIf mkMerge mkOption;
inherit (lib.types) str float int;
inherit (config.modules.system) username; inherit (config.modules.system) username;
inherit (cfg) bloat gnome plasma container; inherit (cfg) bloat gnome plasma container theme opacity fontSize;
inherit (builtins) attrValues; inherit (builtins) attrValues;
inherit (nix-config.packages.${pkgs.system}) aleo-fonts; inherit (nix-config.packages.${pkgs.system}) aleo-fonts;
inherit (pkgs) phinger-cursors noto-fonts-cjk-sans maple-mono noto-fonts-emoji;
theme = "monokai";
opacity = 0.95;
font-size = 11;
cfg = config.modules.desktop; cfg = config.modules.desktop;
in in
@ -20,6 +18,21 @@ in
}; };
options.modules.desktop = { options.modules.desktop = {
theme = mkOption {
type = str;
default = "monokai";
};
opacity = mkOption {
type = float;
default = 0.95;
};
fontSize = mkOption {
type = int;
default = 11;
};
bloat = mkEnableOption "GUI applications like Logseq"; bloat = mkEnableOption "GUI applications like Logseq";
gnome = mkEnableOption "GNOME specialization"; gnome = mkEnableOption "GNOME specialization";
plasma = mkEnableOption "Plasma specialization"; plasma = mkEnableOption "Plasma specialization";
@ -163,13 +176,13 @@ in
popups = opacity; popups = opacity;
}; };
cursor = with pkgs; { cursor = {
package = phinger-cursors; package = phinger-cursors;
name = "phinger-cursors"; name = "phinger-cursors";
size = 24; size = 24;
}; };
fonts = with pkgs; { fonts = {
serif = { serif = {
package = aleo-fonts; package = aleo-fonts;
name = "Aleo"; name = "Aleo";
@ -191,10 +204,10 @@ in
}; };
sizes = { sizes = {
applications = font-size; applications = fontSize;
desktop = font-size; desktop = fontSize;
popups = font-size; popups = fontSize;
terminal = font-size; terminal = fontSize;
}; };
}; };
}; };