11.stylix/modules/glance/hm.nix
awwpotato 7ffb31da69
treewide: use mkTarget (batch 2) (#1362)
Link: https://github.com/nix-community/stylix/pull/1362

Reviewed-by: Flameopathic <64027365+Flameopathic@users.noreply.github.com>
Reviewed-by: NAHO <90870942+trueNAHO@users.noreply.github.com>
2025-05-23 19:23:39 +02:00

29 lines
642 B
Nix

{ mkTarget, lib, ... }:
mkTarget {
name = "glance";
humanName = "Glance";
configElements = [
(
{ polarity }:
{
services.glance.settings.theme.light = polarity == "light";
}
)
(
{ colors }:
let
rgb-to-hsl = import ./rgb-to-hsl.nix { inherit lib colors; };
in
{
services.glance.settings.theme = {
contrast-multiplier = 1.0;
background-color = rgb-to-hsl "base00";
primary-color = rgb-to-hsl "base05";
positive-color = rgb-to-hsl "base01";
negative-color = rgb-to-hsl "base04";
};
}
)
];
}