fix niri
This commit is contained in:
parent
db11846811
commit
67c2117563
16 changed files with 652 additions and 274 deletions
|
|
@ -23,27 +23,32 @@ in
|
|||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
programs.waybar.enable = true;
|
||||
programs.waybar.package = cfg.package;
|
||||
programs.light.enable = true;
|
||||
|
||||
systemd.user.services.waybar.wantedBy = lib.mkForce [ cfg.wantedBy ];
|
||||
environment.etc."xdg/waybar/config".text = builtins.toJSON {
|
||||
mainBar = {
|
||||
systemd.user.services.waybar.restartTriggers = [ "/etc/xdg/waybar/config" "/etc/xdg/waybar/style.css" ];
|
||||
environment.etc."xdg/waybar/config".source =
|
||||
let
|
||||
json = pkgs.formats.json { };
|
||||
in
|
||||
|
||||
(json.generate "waybar-config.json" {
|
||||
layer = "top";
|
||||
position = "top";
|
||||
height = 15;
|
||||
modules-left =
|
||||
(lib.optional (cfg.mode == "river") [
|
||||
modules-left = (lib.optionals (cfg.mode == "river") [
|
||||
"river/tags"
|
||||
"river/layout"
|
||||
"river/window"
|
||||
])
|
||||
++ (lib.optional (cfg.mode == "niri") [
|
||||
++ (lib.optionals (cfg.mode == "niri") [
|
||||
"niri/workspaces"
|
||||
"niri/window"
|
||||
]);
|
||||
modules-right = [
|
||||
"tray"
|
||||
"power-profiles-daemon"
|
||||
"power_profiles_daemon"
|
||||
"idle_inhibitor"
|
||||
"wireplumber"
|
||||
"battery"
|
||||
|
|
@ -52,13 +57,15 @@ in
|
|||
"temperature"
|
||||
"memory"
|
||||
"disk"
|
||||
"custom/tailscale"
|
||||
"network"
|
||||
"clock"
|
||||
];
|
||||
"river/window" = {
|
||||
max-length = 40;
|
||||
};
|
||||
"niri/window" = {
|
||||
max-length = 40;
|
||||
};
|
||||
wireplumber = {
|
||||
"format" = "{icon} {volume}%";
|
||||
"format-muted" = " MUTE";
|
||||
|
|
@ -162,8 +169,7 @@ in
|
|||
"tooltip-format-disconnected" = "Disconnected";
|
||||
"max-length" = 50;
|
||||
};
|
||||
};
|
||||
};
|
||||
});
|
||||
environment.etc."xdg/waybar/style.css".text = ''
|
||||
* {
|
||||
/* `otf-font-awesome` is required to be installed for icons */
|
||||
|
|
@ -202,7 +208,7 @@ in
|
|||
border: none;
|
||||
}*/
|
||||
|
||||
#tags button {
|
||||
#workspaces button {
|
||||
padding: 0 2px;
|
||||
background-color: #1d2021;
|
||||
color: #ebdbb2;
|
||||
|
|
@ -214,24 +220,24 @@ in
|
|||
}
|
||||
|
||||
/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */
|
||||
#tags button:hover {
|
||||
#workspaces button:hover {
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
/* box-shadow: inset 0 -3px #fbf1c7;
|
||||
*/
|
||||
background-color: #3c3836;
|
||||
}
|
||||
|
||||
#tags button.focused {
|
||||
#workspaces button.focused {
|
||||
/* box-shadow: inset 0 -3px #fbf1c7;
|
||||
*/
|
||||
background-color: #3c3836;
|
||||
color: #ebdbb2;
|
||||
}
|
||||
|
||||
#tags button.occupied {
|
||||
#workspaces button.occupied {
|
||||
color: #d3869b;
|
||||
}
|
||||
#tags button.urgent {
|
||||
#workspaces button.urgent {
|
||||
background-color: #cc241d;
|
||||
color: #ebdbb2;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue