diff --git a/dots/.config/waybar/config b/dots/.config/waybar/config index 4d96ea5a..43577e1d 100644 --- a/dots/.config/waybar/config +++ b/dots/.config/waybar/config @@ -1,162 +1,169 @@ -{ - "layer": "top", - "position": "top", - "modules-left": [ - "idle_inhibitor", - "cpu", - "temperature", - "memory", - "battery", - "disk", - "pulseaudio", - "custom/media" - ], - "modules-center": [ - "sway/workspaces" - ], - "modules-right": [ - "custom/weather", - "network", - "clock", - "custom/offswitch" - ], - "sway/window": {}, - "custom/weather": { - "tooltip": false, - "min-length": 5, - "exec": "curl 'https://wttr.in/?format='%t''", - "interval": 3600 - }, - "battery": { - "min-length": 5, - "states": { - "full": 90, - "warning": 30, - "critical": 15 +[ + { + "layer": "top", + "position": "top", + "modules-left": [ + "idle_inhibitor", + "cpu", + "temperature", + "memory", + "battery", + "disk", + "pulseaudio" + ], + "modules-center": [ + "custom/media" + ], + "modules-right": [ + "custom/weather", + "network", + "clock", + "custom/offswitch" + ], + "custom/weather": { + "tooltip": false, + "min-length": 5, + "exec": "curl 'https://wttr.in/?format='%t''", + "interval": 3600 }, - "tooltip": false, - "full-at": 95, - "format-plugged": "{icon} {capacity}%", - "format-charging": "{icon} {capacity}%", - "format": "{icon} {capacity}%", - "format-icons": [ - "", - "", - "", - "", - "", - "", - "", - "", - "", - "" - ] - }, - "clock": { - "format": " {:%a %b %d %I:%M %p}", - "tooltip": false, - "min-length": 18 - }, - "custom/offswitch": { - "tooltip": false, - "format": "", - "interval": "once", - "on-click": "systemctl poweroff" - }, - "network": { - "interval": 10, - "format-wifi": " {essid}", - "format-ethernet": " {ipaddr}", - "format-linked": " {ifname}", - "format-disconnected": " Disconnected", - "tooltip": false, - "max-length": 20, - "min-length": 14 - }, - "pulseaudio": { - "tooltip": false, - "min-length": 5, - "format": "{icon} {volume}%", - "format-bluetooth": "{icon} {volume}%", - "format-muted": "MUTE", - "format-icons": { - "headphone": "", - "headset": "", - "default": [ - "", - "", - "" + "battery": { + "min-length": 5, + "states": { + "full": 90, + "warning": 30, + "critical": 15 + }, + "tooltip": false, + "full-at": 95, + "format-plugged": "{icon} {capacity}%", + "format-charging": "{icon} {capacity}%", + "format": "{icon} {capacity}%", + "format-icons": [ + "", + "", + "", + "", + "", + "", + "", + "", + "", + "" ] - } - }, - "idle_inhibitor": { - "tooltip": false, - "format": "{icon}", - "format-icons": { - "activated": "", - "deactivated": "" - } - }, - "cpu": { - "interval": 4, - "min-length": 6, - "format": " {usage}%", - "tooltip": false, - "states": { - "critical": 90 - } - }, - "temperature": { - "tooltip": false, - "min-length": 6, - "thermal-zone": 1, - "critical-threshold": 90, - "format": "{icon} {temperatureF}°F", - "format-critical": "{icon} {temperatureF}°F", - "format-icons": { - "default": [ - "", - "", - "", - "", - "" - ] - } - }, - "memory": { - "tooltip": false, - "format": " {percentage}%", - "states": { - "critical": 90 }, - "min-length": 5 - }, - "disk": { - "tooltip": false, - "path": "/", - "interval": 60, - "min-length": 5, - "format": " {percentage_used}%", - "states": { - "critical": 90 + "clock": { + "format": " {:%a %b %d %I:%M %p}", + "tooltip": false, + "min-length": 18 + }, + "custom/offswitch": { + "tooltip": false, + "format": "", + "interval": "once", + "on-click": "systemctl poweroff" + }, + "network": { + "interval": 10, + "format-wifi": " {essid}", + "format-ethernet": " {ipaddr}", + "format-linked": " {ifname}", + "format-disconnected": " Disconnected", + "tooltip": false, + "max-length": 20, + "min-length": 14 + }, + "pulseaudio": { + "tooltip": false, + "min-length": 5, + "format": "{icon} {volume}%", + "format-bluetooth": "{icon} {volume}%", + "format-muted": "MUTE", + "format-icons": { + "headphone": "", + "headset": "", + "default": [ + "", + "", + "" + ] + } + }, + "idle_inhibitor": { + "tooltip": false, + "format": "{icon}", + "format-icons": { + "activated": "", + "deactivated": "" + } + }, + "cpu": { + "interval": 4, + "min-length": 6, + "format": " {usage}%", + "tooltip": false, + "states": { + "critical": 90 + } + }, + "temperature": { + "tooltip": false, + "min-length": 6, + "thermal-zone": 1, + "critical-threshold": 90, + "format": "{icon} {temperatureF}°F", + "format-critical": "{icon} {temperatureF}°F", + "format-icons": { + "default": [ + "", + "", + "", + "", + "" + ] + } + }, + "memory": { + "tooltip": false, + "format": " {percentage}%", + "states": { + "critical": 90 + }, + "min-length": 5 + }, + "disk": { + "tooltip": false, + "path": "/", + "interval": 60, + "min-length": 5, + "format": " {percentage_used}%", + "states": { + "critical": 90 + } + }, + "custom/media": { + "interval": 1, + "return-type": "json", + "exec": "~/.config/waybar/scripts/get-media.bash", + "escape": true } }, - "sway/workspaces": { - "tooltip": false, - "disable-scroll": true, - "persistent_workspaces": { - "1": [], - "2": [], - "3": [], - "4": [], - "5": [], - "6": [] + { + "layer": "bottom", + "position": "bottom", + "modules-center": [ + "sway/workspaces" + ], + "sway/workspaces": { + "tooltip": false, + "disable-scroll": true, + "persistent_workspaces": { + "1": [], + "2": [], + "3": [], + "4": [], + "5": [], + "6": [] + } } - }, - "custom/media": { - "interval": 1, - "return-type": "json", - "exec": "~/.config/waybar/scripts/get-media.bash", - "escape": true } -} +] diff --git a/dots/.config/waybar/scripts/get-media.bash b/dots/.config/waybar/scripts/get-media.bash index b9b4d8ef..6bfff288 100755 --- a/dots/.config/waybar/scripts/get-media.bash +++ b/dots/.config/waybar/scripts/get-media.bash @@ -8,10 +8,10 @@ main() { local player_ctl_info="$(playerctl metadata --format '{{ artist }} | {{ title }} | {{ album }}')" if [[ "${class}" == "playing" ]]; then - text="▶ ${player_ctl_info}" + text=" ${player_ctl_info}" elif [[ "${class}" == "paused" ]]; then - text="⏸︎ ${player_ctl_info}" + text=" ${player_ctl_info}" fi printf '{"class": "%s", "text": "%s"}\n' "${class}" "${text}" diff --git a/dots/.config/waybar/style.css b/dots/.config/waybar/style.css index 1bc16e93..8ad3d9f0 100644 --- a/dots/.config/waybar/style.css +++ b/dots/.config/waybar/style.css @@ -38,9 +38,10 @@ * { min-height: 0; padding: 3px; - margin: 3px; border-radius: 20px; padding-left: 20px; + margin-left: 5px; + margin-right: 5px; padding-right: 20px; } @@ -55,6 +56,7 @@ background: @sumiInk0; border-top: 2px solid @oniViolet; border-left: 2px solid @oniViolet; + border-right: 2px solid @oniViolet; } #workspaces {