add notification indicator on waybar
This commit is contained in:
parent
4febdaac93
commit
e05531c16c
2 changed files with 27 additions and 3 deletions
|
@ -1,4 +1,5 @@
|
||||||
{ pkgs, ... }: {
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
programs.waybar = {
|
programs.waybar = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.waybar.override {
|
package = pkgs.waybar.override {
|
||||||
|
@ -14,7 +15,10 @@
|
||||||
height = 28;
|
height = 28;
|
||||||
modules-left = [ "hyprland/workspaces" "hyprland/window" "hyprland/submap" ];
|
modules-left = [ "hyprland/workspaces" "hyprland/window" "hyprland/submap" ];
|
||||||
modules-center = [ ];
|
modules-center = [ ];
|
||||||
modules-right = [ "tray" "idle_inhibitor" "network" "bluetooth" "wireplumber" "backlight" "battery" "clock" ];
|
modules-right = [ "tray" "idle_inhibitor" "network" "bluetooth" "wireplumber" "backlight" "battery" "clock" "custom/notification" ];
|
||||||
|
"hyprland/workspaces" = {
|
||||||
|
separate-outputs = true;
|
||||||
|
};
|
||||||
idle_inhibitor = {
|
idle_inhibitor = {
|
||||||
format = "{icon}";
|
format = "{icon}";
|
||||||
format-icons = {
|
format-icons = {
|
||||||
|
@ -73,6 +77,25 @@
|
||||||
tray = {
|
tray = {
|
||||||
spacing = 4;
|
spacing = 4;
|
||||||
};
|
};
|
||||||
|
"custom/notification" = let swaync-client = "${pkgs.swaynotificationcenter}/bin/swaync-client"; in {
|
||||||
|
tooltip = false;
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = {
|
||||||
|
notification = "";
|
||||||
|
none = "";
|
||||||
|
dnd-notification = "";
|
||||||
|
dnd-none = "";
|
||||||
|
inhibited-notification = "";
|
||||||
|
inhibited-none = "";
|
||||||
|
dnd-inhibited-notification = "";
|
||||||
|
dnd-inhibited-none = "";
|
||||||
|
};
|
||||||
|
return-type = "json";
|
||||||
|
exec = "${swaync-client} -swb";
|
||||||
|
on-click = "${swaync-client} -t -sw";
|
||||||
|
on-click-right = "${swaync-client} -d -sw";
|
||||||
|
escape = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -74,7 +74,8 @@ window#waybar.solo {
|
||||||
#mode,
|
#mode,
|
||||||
#submap,
|
#submap,
|
||||||
#idle_inhibitor,
|
#idle_inhibitor,
|
||||||
#bluetooth {
|
#bluetooth,
|
||||||
|
#custom-notification {
|
||||||
padding: 0 10px;
|
padding: 0 10px;
|
||||||
color: @foreground;
|
color: @foreground;
|
||||||
background-color: @background;
|
background-color: @background;
|
||||||
|
|
Loading…
Reference in a new issue