Add Notifications to waybar

This commit is contained in:
Nathan McCarty 2023-06-17 00:09:53 -04:00
parent 8d1dc3f551
commit 9b61203506
Signed by: thatonelutenist
SSH Key Fingerprint: SHA256:hwQEcmak9E6sdU9bXc98RHw/Xd1AhpB5HZT7ZSVJkRM
1 changed files with 29 additions and 0 deletions

View File

@ -322,6 +322,7 @@ in with lib; {
"memory"
# "temperature"
"tray"
"custom/notification"
"clock"
# "custom/power"
];
@ -390,6 +391,28 @@ in with lib; {
playing = "";
};
};
"custom/notification" = {
tooltip = false;
format = "{icon}";
format-icons = {
notification = "<span foreground='red'><sup></sup></span>";
none = "";
dnd-notification = "<span foreground='red'><sup></sup></span>";
dnd-none = "";
inhibited-notification =
"<span foreground='red'><sup></sup></span>";
inhibited-none = "";
dnd-inhibited-notification =
"<span foreground='red'><sup></sup></span>";
dnd-inhibited-none = "";
};
return-type = "json";
exec-if = "which swaync-client";
exec = "swaync-client -swb";
on-click = "swaync-client -t -sw";
on-click-right = "swaync-client -d -sw";
escape = true;
};
};
};
style = ''
@ -536,6 +559,12 @@ in with lib; {
color: black;
}
#custom-notification {
background-color: #FA8BFF;
background-image: linear-gradient(45deg, #2BD2FF 0%, #2BD2FF 52%, #2BD2FF 90%);
color: black;
}
#memory {
background-color: #FA8BFF;
background-image: linear-gradient(45deg, #2BD2FF 0%, #2BD2FF 52%, #2BD2FF 90%);