Add proper support for custom schemes.
This commit is contained in:
parent
7662b95e0b
commit
9bc47a6b69
|
@ -4,6 +4,20 @@ let
|
||||||
url = "https://i.imgur.com/KkZFMD3.png";
|
url = "https://i.imgur.com/KkZFMD3.png";
|
||||||
sha256 = "sha256-cTNUeamZTjQDx8gGZkU1mj4kKS3FEE0+EDzFb5bsyZE=";
|
sha256 = "sha256-cTNUeamZTjQDx8gGZkU1mj4kKS3FEE0+EDzFb5bsyZE=";
|
||||||
forceContrastText = false;
|
forceContrastText = false;
|
||||||
|
|
||||||
|
# SEE: https://github.com/tinted-theming/schemes
|
||||||
|
# Blue: "${pkgs.base16-schemes}/share/themes/moonlight.yaml"
|
||||||
|
# Brown: "${pkgs.base16-schemes}/share/themes/sandcastle.yaml"
|
||||||
|
# Classy: "${pkgs.base16-schemes}/share/themes/monokai.yaml"
|
||||||
|
# Cold: "${pkgs.base16-schemes}/share/themes/nord.yaml"
|
||||||
|
# Cool: "${pkgs.base16-schemes}/share/themes/tokyo-night-dark.yaml"
|
||||||
|
# Gray: "${pkgs.base16-schemes}/share/themes/nova.yaml"
|
||||||
|
# Material: "${pkgs.base16-schemes}/share/themes/material.yaml"
|
||||||
|
# Purple: "${pkgs.base16-schemes}/share/themes/shades-of-purple.yaml"
|
||||||
|
# Retro: "${pkgs.base16-schemes}/share/themes/mocha.yaml"
|
||||||
|
# Warm: "${pkgs.base16-schemes}/share/themes/gruvbox-dark-hard.yaml"
|
||||||
|
# scheme = "${pkgs.base16-schemes}/share/themes/moonlight.yaml";
|
||||||
|
scheme = null;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.module.wallpaper = {
|
options.module.wallpaper = {
|
||||||
|
@ -15,5 +29,15 @@ in
|
||||||
default = pkgs.fetchurl { inherit url sha256; };
|
default = pkgs.fetchurl { inherit url sha256; };
|
||||||
type = lib.types.path;
|
type = lib.types.path;
|
||||||
};
|
};
|
||||||
|
scheme = lib.mkOption {
|
||||||
|
default = scheme;
|
||||||
|
type =
|
||||||
|
with lib.types;
|
||||||
|
nullOr (oneOf [
|
||||||
|
path
|
||||||
|
lines
|
||||||
|
attrs
|
||||||
|
]);
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@ let
|
||||||
wallpaper = config.module.wallpaper;
|
wallpaper = config.module.wallpaper;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
stylix =
|
stylix = lib.mkMerge [
|
||||||
{
|
{
|
||||||
inherit (config.module.style) cursor;
|
inherit (config.module.style) cursor;
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -30,11 +30,13 @@ in
|
||||||
popups = popup;
|
popups = popup;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
// (lib.optionalAttrs wallpaper.forceContrastText {
|
(lib.mkIf wallpaper.forceContrastText {
|
||||||
override = {
|
override = {
|
||||||
base04 = "000000";
|
base04 = "000000";
|
||||||
base05 = "ffffff";
|
base05 = "ffffff";
|
||||||
base06 = "ffffff";
|
base06 = "ffffff";
|
||||||
};
|
};
|
||||||
});
|
})
|
||||||
|
(lib.mkIf (wallpaper.scheme != null) { base16Scheme = wallpaper.scheme; })
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue