From 7dd785b1005aec643004c06eaa7af690b00cb48f Mon Sep 17 00:00:00 2001 From: seraphim <18ycm9tx@anonaddy.me> Date: Sun, 16 Aug 2026 21:55:33 +0700 Subject: . --- waybar/config.jsonc | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++++ waybar/style.css | 49 +++++++++++++++++++++++++++++++++++ 2 files changed, 122 insertions(+) create mode 100644 waybar/config.jsonc create mode 100644 waybar/style.css (limited to 'waybar') diff --git a/waybar/config.jsonc b/waybar/config.jsonc new file mode 100644 index 0000000..4c55e55 --- /dev/null +++ b/waybar/config.jsonc @@ -0,0 +1,73 @@ +{ + "layer": "top", + "position": "top", + "height": 30, + "spacing": 4, + "modules-left": [ + "niri/workspaces" + ], + "modules-center": [ + "clock", + "custom/media", + "custom/layout" + ], + "modules-right": [ + "pulseaudio", + "memory", + "custom/power", + "tray" + ], + + "niri/workspaces": { + "format": "{idx}/10", + "disable-scroll": true + }, + + "clock": { + "format": "[{:%H:%M}]" + }, + + "custom/media": { + "format": "▶ {}", + "max-length": 40, + "interval": 2, + "exec": "playerctl metadata --format '{{ artist }} - {{ title }}' 2>/dev/null", + "on-click": "playerctl play-pause" + }, + + "custom/layout": { + "format": "[{}]", + "interval": 0, + "exec": "niri msg -j keyboard-layouts | jq -r 'if .current_idx == 0 then \"En\" elif .current_idx == 1 then \"Ru\" else .names[.current_idx] end'; niri msg event-stream | while read -r line; do if echo \"$line\" | grep -q 'Keyboard layouts changed'; then niri msg -j keyboard-layouts | jq -r 'if .current_idx == 0 then \"En\" elif .current_idx == 1 then \"Ru\" else .names[.current_idx] end'; fi; done" + }, + + "tray": { + "spacing": 10 + }, + + "pulseaudio": { + "format": "VOL {icon} {volume}%", + "format-muted": "VOL [x_x ] 00%", + "format-icons": [ + "[> ]", + "[=> ]", + "[==> ]", + "[===> ]", + "[====> ]", + "[=====> ]", + "[======> ]", + "[=======>]" + ], + "on-click": "pavucontrol" + }, + + "memory": { + "interval": 5, + "format": "RAM [{percentage:02}%]" + }, + + "custom/power": { + "format": "[ SYS ]", + "on-click": "wlogout -b 2" + } +} diff --git a/waybar/style.css b/waybar/style.css new file mode 100644 index 0000000..4d7326f --- /dev/null +++ b/waybar/style.css @@ -0,0 +1,49 @@ +/* Импортируем цвета, сгенерированные pywal */ +@import "../../.cache/wal/colors-waybar.css"; + +/* Modern Aesthetic Waybar Theme */ +* { + font-family: "JetBrainsMono Nerd Font", "Fira Code", monospace; + font-size: 14px; + border: none; + border-radius: 0; +} + +window#waybar { + /* @background и @foreground берутся из обоев */ + background-color: @background; + color: @foreground; +} + +#workspaces button { + padding: 0 8px; + background: transparent; + color: @color7; +} + +#workspaces button.active { + color: @color2; /* Цвет активного окна из обоев */ + font-weight: bold; +} + +#custom-media, +#custom-workspace, +#clock, +#custom-layout, +#tray, +#pulseaudio, +#memory, +#custom-power { + padding: 0 12px; + color: @foreground; +} + +/* Акценты для отдельных модулей */ +#custom-layout { + color: @color3; +} + +#custom-power { + color: @color1; /* Обычно это красный или яркий цвет из обоев */ + font-weight: bold; +} -- cgit v1.2.3