♻️ refactor(waybar): network module

This commit is contained in:
Sergio Laín 2024-09-21 17:45:46 +02:00
parent 701964cf4e
commit 1500b379c9
No known key found for this signature in database
GPG key ID: 8429B2EE312F8150
3 changed files with 9 additions and 8 deletions

View file

@ -9,10 +9,12 @@
"~/.config/waybar/modules/custom-notifications.jsonc",
"~/.config/waybar/modules/hyprland-window.jsonc",
"~/.config/waybar/modules/hyprland-workspaces.jsonc",
"~/.config/waybar/modules/network.jsonc",
],
"modules-left": ["custom/arch", "hyprland/workspaces"],
"modules-center": ["hyprland/window"],
"modules-right": [
"network",
"memory",
"cpu",
"temperature#cpu",

View file

@ -1,12 +1,14 @@
{
"network": {
"format-wifi": " ",
"format-ethernet": "󰈀 ",
"format-wifi": " {ifname}",
"format-ethernet": "󰈀 {ifname}",
"tooltip-format-wifi": "Network: <b>{essid}</b>\nSignal strength: <b>{signaldBm}dBm ({signalStrength}%)</b>\nFrequency: <b>{frequency}MHz</b>\nInterface: <b>{ifname}</b>\nIP: <b>{ipaddr}/{cidr}</b>\nGateway: <b>{gwaddr}</b>\nNetmask: <b>{netmask}</b>\n<span foreground='#eed49f'> {bandwidthDownBytes}</span> <span foreground='#b7bdf8'> {bandwidthUpBytes}</span>",
"tooltip-format-ethernet": "Network: <b>{essid}</b>\nInterface: <b>{ifname}</b>\nIP: <b>{ipaddr}/{cidr}</b>\nGateway: <b>{gwaddr}</b>\nNetmask: <b>{netmask}</b>\n<span foreground='#eed49f'> {bandwidthDownBytes}</span> <span foreground='#b7bdf8'> {bandwidthUpBytes}</span>",
"format-linked": "󰈀 {ifname} (No IP)",
"format-disconnected": "󰖪 ",
"tooltip": true,
"interval": 2,
"on-click": "pypr toggle network",
"on-click-right": "pypr toggle wifi",
},
}

View file

@ -322,11 +322,7 @@ window#waybar.hidden {
}
#network {
color: @mantle;
}
#network {
color: @mantle;
color: @sky;
}
#network.disconnected {
@ -335,7 +331,8 @@ window#waybar.hidden {
}
#network.linked {
color: @yellow;
background-color: @peach;
color: @mantle;
}
#clock.cl2 {