From 7b97cef3473ea0897c9c9027a4e9777843c0e50f Mon Sep 17 00:00:00 2001 From: m0ntagur Date: Mon, 27 Nov 2023 18:43:12 +0100 Subject: --- .config/waybar/config | 17 +++++ .config/waybar/modules | 162 +++++++++++++++++++++++++++++++++++++++++++++++ .config/waybar/style.css | 70 ++++++++++++++++++++ 3 files changed, 249 insertions(+) create mode 100644 .config/waybar/config create mode 100644 .config/waybar/modules create mode 100644 .config/waybar/style.css (limited to '.config/waybar') diff --git a/.config/waybar/config b/.config/waybar/config new file mode 100644 index 0000000..95b021a --- /dev/null +++ b/.config/waybar/config @@ -0,0 +1,17 @@ +{ + "include": ["~/.config/waybar/modules"], + "layer": "top", + "position": "top", + "margin": "5 10 0 10", + "modules-left": [ + "hyprland/workspaces", + "hyprland/window" + ], + "modules-center": [ + "custom/media" + ], + "modules-right": [ + "group/systemtray", + "clock" + ], +} diff --git a/.config/waybar/modules b/.config/waybar/modules new file mode 100644 index 0000000..ff31fbb --- /dev/null +++ b/.config/waybar/modules @@ -0,0 +1,162 @@ +{ + "hyprland/workspaces": { + "all-outputs": true, + "active-only": "false", + "on-click": "activate", + "format": "{icon}", + "on-scroll-up": "hyprctl dispatch workspace e+1", + "on-scroll-down": "hyprctl dispatch workspace e-1", + "format-icons": { + "active": "", + "default": "" + } + }, + "hyprland/window": { + "format": "{}", + "rewrite": { + "(.*) — Mozilla Firefox": "Mozilla Firefox" + }, + "seperate-outputs": true, + "max-length": 25 + }, + "wlr/taskbar": { + "format": "{icon}", + "icon-size": 14, + "tooltip-format": "{title}", + "on-click": "activate", + "on-click-middle": "close", + "ignore-list": [] + }, + "tray": { + "icon-size": 19, + "spacing": 10, + "reverse-direction": true + }, + "bluetooth": { + "format": "", + "format-disabled": "󰂲", + "format-connected": "󰂱" + }, + "wireplumber": { + "format": "{icon}", + "tooltip": true, + "tooltip-format": "{volume}", + "scroll-step": 5, + "format-muted": "󰝟", + "on-click": "pactl set-sink-mute @DEFAULT_SINK@ toggle", + "format-icons": [ + "󰕿", + "󰖀", + "󰕾" + ] + }, + "network": { + "tooltip": true, + "format-wifi": "{icon} {essid}", + "format-ethernet": "󰛳", + "format-disconnected": "", + "format-icons": [ + "󰤟", + "󰤢", + "󰤥", + "󰤨" + ], + "tooltip-format": "{bandwidthDownBytes} {bandwidthUpBytes}", + "interval": 1 + }, + "backlight": { + "tooltip": false, + "format": " {}%", + "interval": 1, + "on-scroll-up": "brightnessctl set 20+", + "on-scroll-down": "brightnessctl set 20-" + }, + "battery": { + "states": { + "good": 95, + "warning": 30, + "critical": 20 + }, + "format": "{icon}", + "format-charging": " {capacity}%", + "format-plugged": " {capacity}%", + "format-alt": "{time} {icon}", + "format-icons": ["", "", "", "", ""], + "tooltip": true, + "tooltip-format": "{capacity}%" + }, + "clock": { + "interval": 60, + "format": "{:%a %d.%b %H:%M}" + }, + "cpu": { + "interval": 15, + "format": " {}%", + "max-length": 10 + }, + "memory": { + "interval": 30, + "format": " {}%", + "max-length": 10 + }, + "disk": { + "format": " {free}" + }, + "custom/separator-right": { + "format": "", + "tooltip": false + }, + "custom/separator-left": { + "format": "", + "tooltip": false + }, + "custom/media": { + "interval": 5, + "format": "{icon} {}", + "return-type": "string", + "max-length": 20, + "format-icons": { + "spotify": "", + "default": "" + }, + "escape": true, + "exec": "playerctl metadata title", + "on-click": "playerctl play-pause" + }, + "custom/notification": { + "format": "{icon}", + "format-icons": { + "notification": "󱅫", + "none": "󰂚", + "dnd-notification": "󱅫", + "dnd-none": "󰂛", + "inhibited-notification": "󰂚", + "inhibited-none": "󰂚", + "dnd-inhibited-notification": "󰂛", + "dnd-inhibited-none": "󰂛" + }, + "return-type": "json", + "exec-if": "which swaync-client", + "exec": "swaync-client -swb", + "on-click": "sleep 0.1; swaync-client -t -sw", + "on-click-right": "swaync-client -d -sw", + }, + "group/systemtray": { + "orientation": "horizontal", + "modules": [ + "tray", + "wireplumber", + "battery", + "backlight", + "custom/notification", + ] + }, + "group/stats": { + "orientation": "horizontal", + "modules": [ + "cpu", + "memory", + "disk" + ] + } +} diff --git a/.config/waybar/style.css b/.config/waybar/style.css new file mode 100644 index 0000000..2587865 --- /dev/null +++ b/.config/waybar/style.css @@ -0,0 +1,70 @@ +@import url("/home/user/.cache/wal/colors-css"); +* { + background: transparent; + color: @foreground; + font-size: 1em; + border: none; + box-shadow: none; + min-height: 0; +} + +window#waybar { + border: 2px solid alpha(@color11, 0.3); + border-radius: 0.75em; + background: alpha(black, 0.5); +} + +tooltip { + background: alpha(@background, 0.9); + border: 2px solid alpha(@color11, 0.3); + border-radius: 0.75em; +} + +#workspaces button { + padding: 0em 0em; + margin: 0em 0em; +} + +#tray menu { + border-radius: 0.5em; + background: alpha(@background, 0.9); +} + +#tray separator { + background: @foreground; +} + +#tray menuitem:hover { + background: alpha(@color11, 0.5); +} + +#systemtray, +#workspaces { + margin: 0.5em 0; + background: alpha(@background, 0.3); + border: 2px solid alpha(@color11, 0.3); + border-radius: 0.75em; +} + +#workspaces { + margin-left: 0.5em; +} + +#clock { + margin-right: 0.5em; +} + +#tray, +#window, +#custom-notification, +#custom-launcher, +#custom-updates, +#custom-notification, +#custom-launcher, +#wireplumber, +#clock, +#backlight, +#network, +#battery { + padding: 0.25em 0.5em; +} -- cgit v1.3.1