refactor: move hyprlock settings to nix
This commit is contained in:
parent
8772b124fa
commit
d298d751fc
3 changed files with 124 additions and 110 deletions
|
|
@ -1,93 +0,0 @@
|
||||||
$font = CaskaydiaCove Nerd Font
|
|
||||||
$font2 = SF Pro Display Bold
|
|
||||||
|
|
||||||
background {
|
|
||||||
monitor =
|
|
||||||
path = screenshot
|
|
||||||
blur_passes = 3
|
|
||||||
blur_size = 8
|
|
||||||
contrast = 0.8916
|
|
||||||
brightness = 0.8172
|
|
||||||
vibrancy = 0.1696
|
|
||||||
vibrancy_darkness = 0.0
|
|
||||||
}
|
|
||||||
|
|
||||||
# GENERAL
|
|
||||||
general {
|
|
||||||
no_fade_in = false
|
|
||||||
grace = 0
|
|
||||||
disable_loading_bar = false
|
|
||||||
}
|
|
||||||
|
|
||||||
# TIME
|
|
||||||
label {
|
|
||||||
monitor =
|
|
||||||
text = cmd[update:1000] echo "$(date +"%-I:%M%p")"
|
|
||||||
color = rgba(250, 189, 47, .75)
|
|
||||||
font_size = 120
|
|
||||||
font_family = $font2
|
|
||||||
position = 0, -140
|
|
||||||
halign = center
|
|
||||||
valign = top
|
|
||||||
}
|
|
||||||
|
|
||||||
# DAY-DATE-MONTH
|
|
||||||
label {
|
|
||||||
monitor =
|
|
||||||
text = cmd[update:1000] echo "<span>$(date '+%A, %d %B')</span>"
|
|
||||||
color = rgba(225, 225, 225, 0.75)
|
|
||||||
font_size = 30
|
|
||||||
font_family = $font2
|
|
||||||
position = 0, 200
|
|
||||||
halign = center
|
|
||||||
valign = center
|
|
||||||
}
|
|
||||||
|
|
||||||
# LOGO
|
|
||||||
image {
|
|
||||||
monitor =
|
|
||||||
path = $HOME/.face
|
|
||||||
border_size = 2
|
|
||||||
border_color = rgba(255, 255, 255, .75)
|
|
||||||
size = 95
|
|
||||||
rounding = -1
|
|
||||||
rotate = 0
|
|
||||||
reload_time = -1
|
|
||||||
reload_cmd =
|
|
||||||
position = 0, 60
|
|
||||||
halign = center
|
|
||||||
valign = center
|
|
||||||
}
|
|
||||||
|
|
||||||
# USER
|
|
||||||
label {
|
|
||||||
monitor =
|
|
||||||
text = Hello, $USER
|
|
||||||
color = rgba(255, 255, 255, .65)
|
|
||||||
font_size = 25
|
|
||||||
font_family = $font2
|
|
||||||
position = 0, -70
|
|
||||||
halign = center
|
|
||||||
valign = center
|
|
||||||
}
|
|
||||||
|
|
||||||
# INPUT FIELD
|
|
||||||
input-field {
|
|
||||||
monitor =
|
|
||||||
size = 290, 60
|
|
||||||
outline_thickness = 2
|
|
||||||
dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8
|
|
||||||
dots_spacing = 0.2 # Scale of dots' absolute size, 0.0 - 1.0
|
|
||||||
dots_center = true
|
|
||||||
outer_color = rgba(0, 0, 0, 0)
|
|
||||||
inner_color = rgba(60, 56, 54, 0.35)
|
|
||||||
font_color = rgb(200, 200, 200)
|
|
||||||
fade_on_empty = false
|
|
||||||
font_family = $font2
|
|
||||||
placeholder_text = <i><span foreground="##ffffff99">Bruh, come back!</span></i>
|
|
||||||
hide_input = false
|
|
||||||
position = 0, -140
|
|
||||||
halign = center
|
|
||||||
valign = center
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
@ -5,7 +5,7 @@ in
|
||||||
map (dev: dev // modulesConfig) [
|
map (dev: dev // modulesConfig) [
|
||||||
# Monitor 1
|
# Monitor 1
|
||||||
{
|
{
|
||||||
output = "DP-3";
|
output = "DP-2";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
exclusive = true;
|
exclusive = true;
|
||||||
passthrough = false;
|
passthrough = false;
|
||||||
|
|
@ -39,7 +39,7 @@ map (dev: dev // modulesConfig) [
|
||||||
}
|
}
|
||||||
# Monitor 2
|
# Monitor 2
|
||||||
{
|
{
|
||||||
output = "DP-2";
|
output = "DP-3";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
exclusive = true;
|
exclusive = true;
|
||||||
height = 54;
|
height = 54;
|
||||||
|
|
|
||||||
|
|
@ -108,21 +108,128 @@ in
|
||||||
"source"
|
"source"
|
||||||
];
|
];
|
||||||
|
|
||||||
extraConfig =
|
settings =
|
||||||
builtins.readFile ../config/hypr/hyprlock.conf
|
let
|
||||||
+ ''
|
font = "CaskaydiaCove Nerd Font";
|
||||||
# CURRENT SONG
|
font2 = "SF Pro Display Bold";
|
||||||
label {
|
mainMonitor =
|
||||||
monitor =
|
if ((builtins.length settings.hyprland.monitors) > 0) then
|
||||||
text = cmd[update:1000] echo "$(${getCurrentSong}/bin/getSong)"
|
# TODO: Identifying monitor by desc is broken
|
||||||
color = rgba(235, 219, 178, .75)
|
# https://github.com/hyprwm/hyprlock/issues/737
|
||||||
font_size = 16
|
# builtins.elemAt settings.hyprland.monitors 0
|
||||||
font_family = $font, $font2
|
"DP-2"
|
||||||
position = 0, 80
|
else
|
||||||
halign = center
|
"";
|
||||||
valign = bottom
|
in
|
||||||
}
|
{
|
||||||
'';
|
background = {
|
||||||
|
monitor = "";
|
||||||
|
path = "screenshot";
|
||||||
|
blur_passes = 3;
|
||||||
|
blur_size = 8;
|
||||||
|
contrast = 0.8916;
|
||||||
|
brightness = 0.8172;
|
||||||
|
vibrancy = 0.1696;
|
||||||
|
vibrancy_darkness = 0.0;
|
||||||
|
};
|
||||||
|
|
||||||
|
# GENERAL
|
||||||
|
general = {
|
||||||
|
no_fade_in = false;
|
||||||
|
grace = 0;
|
||||||
|
disable_loading_bar = false;
|
||||||
|
ignore_empty_input = true;
|
||||||
|
fail_timeout = 1000;
|
||||||
|
};
|
||||||
|
|
||||||
|
# TIME
|
||||||
|
label = [
|
||||||
|
{
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
text = ''cmd[update:1000] echo "$(date +"%-I:%M%p")"'';
|
||||||
|
color = "rgba(250, 189, 47, .75)";
|
||||||
|
font_size = 120;
|
||||||
|
font_family = "${font2}";
|
||||||
|
position = "0, -140";
|
||||||
|
halign = "center";
|
||||||
|
valign = "top";
|
||||||
|
}
|
||||||
|
|
||||||
|
# DAY-DATE-MONTH
|
||||||
|
{
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
text = ''cmd[update:1000] echo "<span>$(date '+%A, %d %B')</span>"'';
|
||||||
|
color = "rgba(225, 225, 225, 0.75)";
|
||||||
|
font_size = 30;
|
||||||
|
font_family = "${font2}";
|
||||||
|
position = "0, 200";
|
||||||
|
halign = "center";
|
||||||
|
valign = "center";
|
||||||
|
}
|
||||||
|
# USER
|
||||||
|
{
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
text = "Hello, $USER";
|
||||||
|
color = "rgba(255, 255, 255, .65)";
|
||||||
|
font_size = 25;
|
||||||
|
font_family = "${font2}";
|
||||||
|
position = "0, -70";
|
||||||
|
halign = "center";
|
||||||
|
valign = "center";
|
||||||
|
}
|
||||||
|
# Current Song
|
||||||
|
{
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
text = ''cmd[update:1000] echo "$(${getCurrentSong}/bin/getSong)"'';
|
||||||
|
color = "rgba(235, 219, 178, .75)";
|
||||||
|
font_size = 16;
|
||||||
|
font_family = "${font}, ${font2}";
|
||||||
|
position = "0, 80";
|
||||||
|
halign = "center";
|
||||||
|
valign = "bottom";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
# LOGO
|
||||||
|
image = {
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
path = "$HOME/.face";
|
||||||
|
border_size = 2;
|
||||||
|
border_color = "rgba(255, 255, 255, .75)";
|
||||||
|
size = 95;
|
||||||
|
rounding = -1;
|
||||||
|
rotate = 0;
|
||||||
|
reload_time = -1;
|
||||||
|
reload_cmd = "";
|
||||||
|
position = "0, 60";
|
||||||
|
halign = "center";
|
||||||
|
valign = "center";
|
||||||
|
};
|
||||||
|
|
||||||
|
# INPUT FIELD
|
||||||
|
input-field = [
|
||||||
|
{
|
||||||
|
monitor = "${mainMonitor}";
|
||||||
|
size = "290, 60";
|
||||||
|
outline_thickness = 2;
|
||||||
|
dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8
|
||||||
|
dots_spacing = 0.2; # Scale of dots' absolute size, 0.0 - 1.0
|
||||||
|
dots_center = true;
|
||||||
|
outer_color = "rgba(0, 0, 0, 0)";
|
||||||
|
inner_color = "rgba(60, 56, 54, 0.35)";
|
||||||
|
font_color = "rgb(200, 200, 200)";
|
||||||
|
fail_color = "rgba(218, 53, 50, 0.56)";
|
||||||
|
fade_on_empty = false;
|
||||||
|
font_family = "${font2}";
|
||||||
|
placeholder_text = ''<i><span foreground="##ffffff99">Bruh, come back!</span></i>'';
|
||||||
|
hide_input = false;
|
||||||
|
position = "0, -140";
|
||||||
|
halign = "center";
|
||||||
|
valign = "center";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# === hypridle === #
|
# === hypridle === #
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue