94 lines
2.6 KiB
Nix
Executable File
94 lines
2.6 KiB
Nix
Executable File
{
|
|
config,
|
|
lib,
|
|
namespace,
|
|
...
|
|
}:
|
|
{
|
|
imports = [
|
|
(lib.${namespace}.mkHomeModule {
|
|
inherit config;
|
|
domain = "programs";
|
|
name = "wlogout";
|
|
moduleConfig = {
|
|
programs.wlogout = {
|
|
enable = false;
|
|
layout = {
|
|
lock = {
|
|
label = "lock";
|
|
action = "hyprlock --immediate";
|
|
text = "Lock";
|
|
keybind = "l";
|
|
};
|
|
hibernate = {
|
|
label = "hibernate";
|
|
action = "systemctl hibernate";
|
|
text = "Hibernate";
|
|
keybind = "h";
|
|
};
|
|
logout = {
|
|
label = "logout";
|
|
action = "sleep 1; hyprctl dispatch exit";
|
|
text = "Logout";
|
|
keybind = "e";
|
|
};
|
|
shutdown = {
|
|
label = "shutdown";
|
|
action = "systemctl poweroff";
|
|
text = "Shutdown";
|
|
keybind = "s";
|
|
};
|
|
suspend = {
|
|
label = "suspend";
|
|
action = "systemctl suspend";
|
|
text = "Suspend";
|
|
keybind = "u";
|
|
};
|
|
reboot = {
|
|
label = "reboot";
|
|
action = "reboot";
|
|
text = "Reboot";
|
|
keybind = "r";
|
|
};
|
|
};
|
|
style = ''
|
|
* {
|
|
background-image: none;
|
|
}
|
|
|
|
window {
|
|
background-color: ${config.lib.stylix.colors.base00}f0
|
|
}
|
|
|
|
button {
|
|
margin: 8px;
|
|
color: ${config.lib.stylix.colors.base0C};
|
|
background-color: ${config.lib.stylix.colors.base01};
|
|
border-style: solid;
|
|
border-width: 2px;
|
|
background-repeat: no-repeat;
|
|
background-position: center;
|
|
background-size: 25%;
|
|
}
|
|
|
|
button:active,
|
|
button:focus,
|
|
button:hover {
|
|
color: ${config.lib.stylix.colors.base0C};
|
|
background-color: ${config.lib.stylix.colors.base02Alt};
|
|
outline-style: none;
|
|
}
|
|
|
|
#lock { background-image: image(url("icons/lock.png")); }
|
|
#logout { background-image: image(url("icons/logout.png")); }
|
|
#suspend { background-image: image(url("icons/suspend.png")); }
|
|
#hibernate { background-image: image(url("icons/hibernate.png")); }
|
|
#shutdown { background-image: image(url("icons/shutdown.png")); }
|
|
#reboot { background-image: image(url("icons/reboot.png")); }
|
|
'';
|
|
};
|
|
};
|
|
})
|
|
];
|
|
}
|