11.stylix/modules/mako/hm.nix
2025-06-06 18:58:35 +00:00

44 lines
1.1 KiB
Nix

{ mkTarget, lib, ... }:
mkTarget {
name = "mako";
humanName = "Mako";
# Referenced https://github.com/stacyharper/base16-mako
configElements = [
(
{ fonts }:
{
services.mako.settings.font = "${fonts.sansSerif.name} ${toString fonts.sizes.popups}";
}
)
(
{ colors, opacity }:
{
services.mako =
let
makoOpacity = lib.toHexString (builtins.ceil (opacity.popups * 255));
in
with colors.withHashtag;
{
settings = {
background-color = base00 + makoOpacity;
border-color = base0D;
text-color = base05;
progress-color = "over ${base02}";
"urgency=low" = {
background-color = "${base00}${makoOpacity}";
border-color = base0D;
text-color = base0A;
};
"urgency=high" = {
background-color = "${base00}${makoOpacity}";
border-color = base0D;
text-color = base08;
};
};
};
}
)
];
}