More refactoring and added hyprlock

This commit is contained in:
marc
2024-12-03 22:57:56 +01:00
parent a5cd3713e7
commit 2af075c7dd
9 changed files with 170 additions and 75 deletions

View File

@@ -0,0 +1,66 @@
{ config, lib, pkgs, inputs, ... }:
with lib;
let
cfg = config.samfelag.modules.desktop.tools.hyprlock;
hexToRGBString = inputs.nix-colors.lib-core.conversions.hexToRGBString ",";
in
{
options.samfelag.modules.desktop.tools.hyprlock = {
enable = mkEnableOption "Hyprlock screen locker";
};
config = mkIf cfg.enable {
hm.programs.hyprlock = {
enable = true;
settings = {
general = {
# disable_loading_bar = true;
# grace = 5;
};
background = [
{
path = "${config.samfelag.modules.desktop.wallpaper}";
blur_passes = 2;
blur_size = 4;
}
];
input-field = [
{
font_family = "Iosevka";
size = "300, 40";
position = "0, -80";
outline_thickness = 1;
fade_on_empty = "false";
placeholder_text = "";
outer_color = "rgba(${hexToRGBString config.colorScheme.palette.base02},0.9)";
inner_color = "rgba(${hexToRGBString config.colorScheme.palette.base00},0.9)";
font_color = "rgba(${hexToRGBString config.colorScheme.palette.base05},1.0)";
check_color = "rgba(${hexToRGBString config.colorScheme.palette.base07},1.0)";
fail_color = "rgba(${hexToRGBString config.colorScheme.palette.base06},1.0)";
}
];
label = [
{
text = "$TIME";
color = "rgba(${hexToRGBString config.colorScheme.palette.base00},1.0)";
font_size = 25;
font_family = "Iosevka";
position = "0, 80";
halign = "center";
valign = "center";
}
];
};
};
};
}