hyprlock: update config to include image
also include default startup option without nividia shenanigas for hyprland
This commit is contained in:
		
							parent
							
								
									9a4b7ae215
								
							
						
					
					
						commit
						57b06c12f2
					
				
					 2 changed files with 34 additions and 36 deletions
				
			
		|  | @ -9,7 +9,6 @@ | ||||||
| }: | }: | ||||||
| let | let | ||||||
|   inherit (lib) mkIf mkEnableOption; |   inherit (lib) mkIf mkEnableOption; | ||||||
|   inherit (lib.${namespace}) enabled; |  | ||||||
| 
 | 
 | ||||||
|   hyprlock-package = inputs.hyprlock.packages.${system}.hyprlock; |   hyprlock-package = inputs.hyprlock.packages.${system}.hyprlock; | ||||||
| 
 | 
 | ||||||
|  | @ -21,6 +20,8 @@ let | ||||||
|   ''; |   ''; | ||||||
| 
 | 
 | ||||||
|   cfg = config.${namespace}.desktop.addons.hyprlock; |   cfg = config.${namespace}.desktop.addons.hyprlock; | ||||||
|  | 
 | ||||||
|  |   username = config.${namespace}.user.name; | ||||||
| in | in | ||||||
| { | { | ||||||
|   options.${namespace}.desktop.addons.hyprlock = { |   options.${namespace}.desktop.addons.hyprlock = { | ||||||
|  | @ -36,18 +37,18 @@ in | ||||||
|       ]; |       ]; | ||||||
|     }; |     }; | ||||||
| 
 | 
 | ||||||
|     snowfallorg.users.${config.${namespace}.user.name}.home.config = { |     snowfallorg.users.${username}.home.config = { | ||||||
| 
 | 
 | ||||||
|       programs.hyprlock = { |       programs.hyprlock = { | ||||||
|         enable = true; |         enable = true; | ||||||
|         package = hyprlock-package; |         package = hyprlock-package; | ||||||
|         settings = { |         settings = { | ||||||
|  |           # inspiration from https://github.com/justinmdickey/publicdots/blob/main/.config/hypr/hyprlock.conf | ||||||
|           background = [ |           background = [ | ||||||
|             { |             { | ||||||
|               monitor = "DP-2"; |               monitor = "DP-2"; | ||||||
|               path = "/tmp/screenshot1.png"; |               path = "/tmp/screenshot1.png"; | ||||||
| 
 | 
 | ||||||
|               # all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations |  | ||||||
|               blur_passes = 1; # 0 disables blurring |               blur_passes = 1; # 0 disables blurring | ||||||
|               blur_size = 7; |               blur_size = 7; | ||||||
|               noise = 1.17e-2; |               noise = 1.17e-2; | ||||||
|  | @ -56,33 +57,12 @@ in | ||||||
|               monitor = "HDMI-A-1"; |               monitor = "HDMI-A-1"; | ||||||
|               path = "/tmp/screenshot2.png"; |               path = "/tmp/screenshot2.png"; | ||||||
| 
 | 
 | ||||||
|               # all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations |  | ||||||
|               blur_passes = 2; # 0 disables blurring |               blur_passes = 2; # 0 disables blurring | ||||||
|               blur_size = 7; |               blur_size = 7; | ||||||
|               noise = 1.17e-2; |               noise = 1.17e-2; | ||||||
|             } |             } | ||||||
|           ]; |           ]; | ||||||
| 
 | 
 | ||||||
|           input-field = { |  | ||||||
|             monitor = "DP-2"; |  | ||||||
|             size = "200,50"; |  | ||||||
|             outline_thickness = 2; |  | ||||||
|             dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8 |  | ||||||
|             dots_spacing = 0.35; # Scale of dots' absolute size, 0.0 - 1.0 |  | ||||||
|             dots_center = true; |  | ||||||
|             outer_color = "rgba(0, 0, 0, 0)"; |  | ||||||
|             inner_color = "rgba(0, 0, 0, 0.2)"; |  | ||||||
|             font_color = "rgb(255,129,0)"; |  | ||||||
|             fade_on_empty = false; |  | ||||||
|             rounding = -1; |  | ||||||
|             check_color = "rgb(204, 136, 34)"; |  | ||||||
|             placeholder_text = ''<i><span foreground="##cdd6f4">Input Password...</span></i>''; |  | ||||||
|             hide_input = false; |  | ||||||
|             position = "0, -100"; |  | ||||||
|             halign = "center"; |  | ||||||
|             valign = "center"; |  | ||||||
|           }; |  | ||||||
| 
 |  | ||||||
|           label = [ |           label = [ | ||||||
|             { |             { | ||||||
|               monitor = "DP-2"; |               monitor = "DP-2"; | ||||||
|  | @ -107,19 +87,37 @@ in | ||||||
| 
 | 
 | ||||||
|             } |             } | ||||||
|           ]; |           ]; | ||||||
|         }; | 
 | ||||||
|       }; |           image = { | ||||||
|  |             monitor = "DP-2"; | ||||||
|  |             path = "/home/${username}/Pictures/profile.png"; | ||||||
|  | 
 | ||||||
|  |             position = "0, 50"; | ||||||
|  |             halign = "center"; | ||||||
|  |             valign = "center"; | ||||||
|           }; |           }; | ||||||
| 
 | 
 | ||||||
|     # ${namespace}.home.extraOptions = { |           input-field = { | ||||||
|     #   programs.hello = enabled; |             monitor = "DP-2"; | ||||||
| 
 |             size = "200,50"; | ||||||
|     #   programs.hyprlock = { |             outline_thickness = 2; | ||||||
|     #     enable = true; |             dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8 | ||||||
|     #     settings = { |             dots_spacing = 0.35; # Scale of dots' absolute size, 0.0 - 1.0 | ||||||
|     #       monitor = "DP-2"; |             dots_center = true; | ||||||
|     #     }; |             outer_color = "rgba(0, 0, 0, 0)"; | ||||||
|     #   }; |             inner_color = "rgba(0, 0, 0, 0.2)"; | ||||||
|     # }; |             font_color = "rgb(111, 45, 104)"; | ||||||
|  |             fade_on_empty = false; | ||||||
|  |             rounding = -1; | ||||||
|  |             check_color = "rgb(30, 107, 204)"; | ||||||
|  |             placeholder_text = ''<i><span foreground="##cdd6f4">Input Password...</span></i>''; | ||||||
|  |             hide_input = false; | ||||||
|  |             position = "0, -100"; | ||||||
|  |             halign = "center"; | ||||||
|  |             valign = "center"; | ||||||
|  |           }; | ||||||
|  |         }; | ||||||
|  |       }; | ||||||
|  |     }; | ||||||
|   }; |   }; | ||||||
| } | } | ||||||
|  |  | ||||||
|  | @ -59,7 +59,7 @@ in | ||||||
|         exec-once = [ |         exec-once = [ | ||||||
|           "hyprctl dispatch moveworkspacetomonitor 4 HDMI-A-1" |           "hyprctl dispatch moveworkspacetomonitor 4 HDMI-A-1" | ||||||
|           "xrandr --output DP-2 --primary" |           "xrandr --output DP-2 --primary" | ||||||
|           "[workspace 1 silent] obsidian" |           "[workspace 1 silent] obsidian --disabled-gpu" | ||||||
|           "[workspace 4 silent] git-butler" |           "[workspace 4 silent] git-butler" | ||||||
|         ]; |         ]; | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue