11.stylix/modules/fnott/hm.nix
Karun Sandhu 8775d8322a
fnott: set font size (#1243)
Link: https://github.com/danth/stylix/pull/1243

Reviewed-by: awwpotato <awwpotato@voidq.com>
2025-05-09 08:21:32 -07:00

39 lines
1.1 KiB
Nix

{ lib, config, ... }:
{
options.stylix.targets.fnott.enable =
config.lib.stylix.mkEnableTarget "Fnott" true;
config.services.fnott.settings =
lib.mkIf (config.stylix.enable && config.stylix.targets.fnott.enable)
(
let
font = "${config.stylix.fonts.sansSerif.name}:size=${toString config.stylix.fonts.sizes.popups}";
fg = c: "${c}ff";
bg =
c:
"${c}${
lib.toHexString (
((builtins.floor (config.stylix.opacity.popups * 100 + 0.5)) * 255) / 100
)
}";
in
with config.lib.stylix.colors;
{
main = {
title-font = font;
summary-font = font;
body-font = font;
title-color = fg base05;
summary-color = fg base05;
body-color = fg base05;
progress-bar-color = fg base02;
background = bg base00;
};
low.border-color = fg base0B;
normal.border-color = fg base0E;
critical.border-color = fg base08;
}
);
}