Stylix : Add forceWhiteText switch.

This commit is contained in:
Dmitry Voronin 2024-05-07 16:12:07 +03:00
parent 57cd17bc7d
commit 2b1ca4f29a
Signed by: voronind
SSH key fingerprint: SHA256:3kBb4iV2ahufEBNq+vFbUe4QYfHt98DHQjN7QaptY9k
2 changed files with 13 additions and 13 deletions

View file

@ -1,10 +1,11 @@
{ pkgs, config, wallpaper, ... }: {
{ pkgs, config, wallpaper, ... }: let
forceWhiteText = false;
in {
environment.etc.wallpaper.source = wallpaper.path;
stylix = {
image = wallpaper.path;
autoEnable = true;
polarity = "dark";
# base16Scheme = "${pkgs.base16-schemes}/share/themes/gruvbox-dark-hard.yaml";
opacity = {
applications = 0.85;
terminal = 0.85;
@ -37,5 +38,10 @@
name = "Noto Color Emoji";
};
};
override = if forceWhiteText then {
base04 = "ffffff";
base05 = "ffffff";
base06 = "ffffff";
} else {};
};
}

View file

@ -1,17 +1,11 @@
{ config, ... }: let
forceWhiteText = false;
in {
{ config, ... }: {
color = {
bg = {
dark = config.lib.stylix.colors.base00;
light = config.lib.stylix.colors.base07;
regular = config.lib.stylix.colors.base01;
};
fg = if forceWhiteText then {
dark = "ffffff";
light = "ffffff";
regular = "ffffff";
} else {
fg = {
dark = config.lib.stylix.colors.base04;
light = config.lib.stylix.colors.base06;
regular = config.lib.stylix.colors.base05;
@ -53,9 +47,9 @@ in {
border-g = config.lib.stylix.colors.base01-rgb-g;
border-r = config.lib.stylix.colors.base01-rgb-r;
fg-b = if forceWhiteText then 255 else config.lib.stylix.colors.base06-rgb-b;
fg-g = if forceWhiteText then 255 else config.lib.stylix.colors.base06-rgb-g;
fg-r = if forceWhiteText then 255 else config.lib.stylix.colors.base06-rgb-r;
fg-b = config.lib.stylix.colors.base06-rgb-b;
fg-g = config.lib.stylix.colors.base06-rgb-g;
fg-r = config.lib.stylix.colors.base06-rgb-r;
};
font = {