feat(nixos:appearance): move appearance options to nixos

This commit is contained in:
ooks-io 2024-08-05 17:29:53 +12:00
parent cedeb52103
commit ceb66c03cf
51 changed files with 393 additions and 377 deletions

View file

@ -0,0 +1,30 @@
{
config,
lib,
...
}: let
inherit (lib) mkOption;
inherit (lib.types) str enum attrsOf;
cfg = config.ooknet.colorscheme;
in {
# simple colorscheme module bases on misterio77/nix-colors
options.ooknet.colorscheme = {
name = mkOption {
type = enum ["hozen"];
default = "hozen";
};
variant = mkOption {
type = enum ["dark" "light"];
default = "dark";
};
slug = mkOption {
type = str;
default = "${toString cfg.name-cfg.variant}";
};
palette = {
type = attrsOf str;
default = (import ./palettes/${cfg.slug}.nix).colorscheme.palette;
};
};
}