Styling fixes for waybar

This commit is contained in:
Charlotte Van Petegem 2023-04-12 15:11:39 +02:00
parent 1d596578b0
commit 716d22b3f8
No known key found for this signature in database
GPG key ID: 019E764B7184435A

View file

@ -199,20 +199,24 @@ in
modules-center = [ "river/window" ]; modules-center = [ "river/window" ];
modules-right = [ "idle_inhibitor" "network" "battery" "backlight" "mpris" "pulseaudio" "custom/mail-status" "clock" "tray" ]; modules-right = [ "idle_inhibitor" "network" "battery" "backlight" "mpris" "pulseaudio" "custom/mail-status" "clock" "tray" ];
backlight = { backlight = {
format = "{percent}%"; format = "{percent}% {icon}";
format-icons = [ "🌑" "🌒" "🌓" "🌔" "🌕" ];
on-scroll-up = "${pkgs.brightnessctl}/bin/brightnessctl s -- +5%";
on-scroll-down = "${pkgs.brightnessctl}/bin/brightnessctl s -- -5%";
}; };
battery = { battery = {
states = { states = {
good = 95; good = 90;
warning = 30; warning = 30;
critical = 15; critical = 15;
}; };
format = "{capacity}% {icon}"; format = "{capacity}% {icon}";
format-charging = "{capacity}% "; format-charging = "{capacity}% \uf1e6";
format-plugged = "{capacity}% "; format-plugged = "";
format-alt = "{time} {icon}"; format-alt = "{time} {icon}";
format-icons = [ "" "" "" "" "" ]; format-icons = [ "" "" "" "" "" ];
}; };
clock.format = " {:%a %d/%m %H:%M}";
"custom/mail-status" = { "custom/mail-status" = {
exec = "${mail-status}"; exec = "${mail-status}";
return-type = "json"; return-type = "json";
@ -226,9 +230,17 @@ in
deactivated = ""; deactivated = "";
}; };
}; };
mpris.player = "firefox"; mpris = {
player = "firefox";
format = "{status_icon} {artist} - {title}";
status-icons = {
playing = "";
paused = "";
stopped = "";
};
};
network = { network = {
format-wifi = "{essid} ({signalStrength}%) "; format-wifi = "{essid} ";
format-ethernet = "{ipaddr}/{cidr} "; format-ethernet = "{ipaddr}/{cidr} ";
tooltip-format = "{ifname} via {gwaddr} "; tooltip-format = "{ifname} via {gwaddr} ";
format-linked = "{ifname} (No IP) "; format-linked = "{ifname} (No IP) ";
@ -251,7 +263,9 @@ in
car = ""; car = "";
default = [ "" "" "" ]; default = [ "" "" "" ];
}; };
on-click = "pavucontrol"; on-click = "${pkgs.pamixer}/bin/pamixer -t";
on-click-right = "${pkgs.pamixer}/bin/pamixer --default-source -t";
on-click-middle = "${pkgs.pavucontrol}/bin/pavucontrol";
}; };
tray.spacing = 2; tray.spacing = 2;
}; };
@ -261,13 +275,60 @@ in
font-family: Hack, monospace; font-family: Hack, monospace;
font-size: 11px; font-size: 11px;
} }
#window, #idle_inhibitor, #network, #battery, #backlight, #mpris, #pulseaudio, #custom-mail-status, #clock, #tray {
padding: 0 5px;
}
button {
border: none;
border-radius: 0;
}
button:hover {
border: none;
border-radius: 0;
}
window#waybar { window#waybar {
background-color: #ffffff; background-color: #ffffff;
color: #000000; color: #000000;
} }
#backlight {
background-color: #6aaeff;
}
#battery {
background-color: #5ada88;
}
#battery.good {
background-color: #6aaeff;
}
#battery.warning {
background-color: #f5df23;
}
#battery.critical {
background-color: #ff8892;
}
#clock {
padding-right: 0px;
}
#custom-mail-status.has-mail {
background-color: #6aaeff;
}
#idle_inhibitor.activated {
background-color: #6aaeff;
}
#pulseaudio {
background-color: #f5df23;
}
#tags button { #tags button {
border-radius: 0; box-shadow: inset 0 -3px transparent
background-color: #ffffff; background-color: #ffffff;
color: #000000; color: #000000;
} }
@ -280,6 +341,9 @@ in
#tags button.urgent { #tags button.urgent {
background-color: #ff8892; background-color: #ff8892;
} }
#tags button:hover {
box-shadow: inset 0 -3px #000000;
}
''; '';
systemd.enable = true; systemd.enable = true;
}; };