update inputs

This commit is contained in:
Reid 2024-05-22 22:27:59 -07:00
parent af1cb08d23
commit 45741e6110
5 changed files with 95 additions and 83 deletions

View file

@ -20,32 +20,36 @@ in {
enable = true;
package = cfg.package;
lockCmd = "${pkgs.procps}/bin/pidof hyprlock || ${lib.getExe config.modules.desktop.hyprlock.package}";
unlockCmd = "${pkgs.procps}/bin/pkill -USR1 hyprlock";
settings = {
general = {
lock_cmd = "${pkgs.procps}/bin/pidof hyprlock || ${lib.getExe config.modules.desktop.hyprlock.package}";
unlock_cmd = "${pkgs.procps}/bin/pkill -USR1 hyprlock";
beforeSleepCmd = "${pkgs.systemd}/bin/loginctl lock-session"; # lock the screen before sleeping
afterSleepCmd = "${hyprctl} dispatch dpms on"; # turn on the screen to avoid moving mouse/pressing key
before_sleep_cmd = "${pkgs.systemd}/bin/loginctl lock-session"; # lock the screen before sleeping
after_sleep_cmd = "${hyprctl} dispatch dpms on"; # turn on the screen to avoid moving mouse/pressing key
};
listeners = [
listener = [
{
timeout = 60 * 1;
onTimeout = "${lib.getExe pkgs.brightnessctl} -c backlight -s set 20"; # dim screen, save brightness state
onResume = "${lib.getExe pkgs.brightnessctl} -c backlight -r"; # restore previous screen brightness state
on-timeout = "${lib.getExe pkgs.brightnessctl} -c backlight -s set 1%"; # dim screen, save brightness state
on-resume = "${lib.getExe pkgs.brightnessctl} -c backlight -r"; # restore previous screen brightness state
}
{
timeout = 90; # 1.5 min
onTimeout = "${hyprctl} dispatch dpms off"; # turn off screen
onResume = "${hyprctl} dispatch dpms on"; # turn it back on
on-timeout = "${hyprctl} dispatch dpms off"; # turn off screen
on-resume = "${hyprctl} dispatch dpms on"; # turn it back on
}
{
timeout = 60 * 2; # 2 min
onTimeout = "${pkgs.systemd}/bin/loginctl lock-session"; # lock computer
on-timeout = "${pkgs.systemd}/bin/loginctl lock-session"; # lock computer
}
{
timeout = 60 * 15; # 15 min
onTimeout = "${pkgs.systemd}/bin/systemctl suspend"; # sleep/suspend
on-timeout = "${pkgs.systemd}/bin/systemctl suspend"; # sleep/suspend
}
];
};
};
};
}

View file

@ -19,13 +19,14 @@ in {
enable = true;
package = cfg.package;
settings = {
general = {
hide_cursor = false;
no_fade_in = true;
no_fade_out = true;
};
backgrounds = [
background = [
{
path = toString ../../assets/lockscreen.png;
blur_passes = 3;
@ -33,26 +34,30 @@ in {
}
];
labels = [
label = [
{
text = "cmd[update:1000] echo \"$(date +'%H:%M')\"";
font_size = 58;
color = "rgb(${base05})";
font_family = config.modules.desktop.fonts.fonts.sansSerif.family;
position = { x = 0; y = 30; };
position = "0, 30";
halign = "center";
valign = "center";
}
{
text = "cmd[update:1000] echo \"$(date +'%A %B %e')\"";
font_size = 14;
color = "rgb(${base05})";
font_family = config.modules.desktop.fonts.fonts.sansSerif.family;
position = { x = 0; y = 10; };
position = "0, 10";
halign = "center";
valign = "center";
}
];
input-fields = [
input-field = [
{
size = { width = 300; height = 28; };
size = "300, 28";
outline_thickness = 2;
dots_size = 0.2;
fade_on_empty = false;
@ -65,9 +70,12 @@ in {
fail_color = "rgb(${base08})";
capslock_color = "rgb(${base09})";
position = { x = 0; y = -30; };
position = "0, -30";
halign = "center";
valign = "center";
}
];
};
};
};
}

View file

@ -69,7 +69,7 @@ in {
hm.qt = {
enable = true;
platformTheme = "gtk";
platformTheme.name = "gtk";
style.name = "gtk2";
};