From a179835409029fdf815255df92fdc3aaf2be7db4 Mon Sep 17 00:00:00 2001 From: Youwen Wu Date: Mon, 26 Aug 2024 03:40:34 -0700 Subject: [PATCH] feat: add network module to desktop --- users/youwen/linux/waybar/desktop/default.nix | 15 +++++++++++++++ users/youwen/linux/waybar/desktop/style.css | 4 ++++ 2 files changed, 19 insertions(+) diff --git a/users/youwen/linux/waybar/desktop/default.nix b/users/youwen/linux/waybar/desktop/default.nix index 0b4172b..c1d1573 100644 --- a/users/youwen/linux/waybar/desktop/default.nix +++ b/users/youwen/linux/waybar/desktop/default.nix @@ -31,6 +31,7 @@ "idle_inhibitor" "backlight" "wireplumber" + "network" "battery" "disk" "memory" @@ -47,6 +48,20 @@ }; }; + network = { + format = "{ifname}"; + format-wifi = "{icon}{essid}"; + format-ethernet = " {essid}"; + format-disconnected = "󰤯 Disconnected"; + format-icons = [ + "󰤟 " + "󰤢 " + "󰤨 " + ]; + tooltip-format = " {bandwidthUpBits} |  {bandwidthDownBits}"; + tooltip-format-wifi = " {bandwidthUpBits} |  {bandwidthDownBits} | 󱄙 {signalStrength}"; + }; + backlight = { interval = 2; format = "󰖨 {percent}%"; diff --git a/users/youwen/linux/waybar/desktop/style.css b/users/youwen/linux/waybar/desktop/style.css index a1bf311..0307cdf 100644 --- a/users/youwen/linux/waybar/desktop/style.css +++ b/users/youwen/linux/waybar/desktop/style.css @@ -65,3 +65,7 @@ window#waybar { #temperature { color: lightslategray; } + +#network { + color: lightsteelblue; +}