Commit 1479aead authored by Kirill Unitsaev's avatar Kirill Unitsaev

hyprland/waybar: improve the style

parent e690af64
{ {
"layer": "top", "layer": "top",
"position": "top", "position": "top",
"margin-left": 35, "margin-left": 35,
"margin-top": 5, "margin-top": 5,
...@@ -10,15 +10,14 @@ ...@@ -10,15 +10,14 @@
"gtk-layer-shell": true, "gtk-layer-shell": true,
"passthrough": false, "passthrough": false,
"fixed-center": true, "fixed-center": true,
"reload_style_on_change": true, // Релоад при изменении css "reload_style_on_change": true, // Релоад при изменении css
"include": [ "include": [
"/etc/ximperdistro/hyprland/waybar/modules.json" "/etc/ximperdistro/hyprland/waybar/modules.json"
], ],
"modules-left": [ "modules-left": [
"image#menu", "image#menu",
"hyprland/workspaces#icons", "group/hypr-windowcount-workspaces",
"tray", "tray"
"hyprland/submap"
], ],
"modules-center": [ "modules-center": [
"clock" "clock"
...@@ -27,6 +26,7 @@ ...@@ -27,6 +26,7 @@
"custom/media#mini", "custom/media#mini",
"idle_inhibitor", "idle_inhibitor",
"hyprland/language", "hyprland/language",
"hyprland/submap",
"group/volume", "group/volume",
"network", "network",
"bluetooth", "bluetooth",
...@@ -34,4 +34,4 @@ ...@@ -34,4 +34,4 @@
"backlight", "backlight",
"custom/notification" "custom/notification"
] ]
} }
\ No newline at end of file
{ {
"image#menu": { "image#menu": {
"path": "/usr/share/pixmaps/ximperlinux.svg", "path": "/usr/share/pixmaps/ximperlinux.svg",
"size": 18, "size": 18,
"on-click": "pkill wofi || wofi --show drun -x 8 -y 10 --height 35% --width 25%" "on-click": "pkill wofi || wofi --show drun -x 8 -y 10 --height 35% --width 25%"
}, },
"hyprland/workspaces#icons": {
"hyprland/workspaces#icons": { "active-only": false,
"active-only": false, "all-outputs": false,
"all-outputs": false, "format": "{icon}",
"format": "{icon}", "show-special": true,
"show-special": true, "on-click": "activate",
"on-click": "activate", "on-scroll-up": "hyprctl dispatch workspace e+1",
"on-scroll-up": "hyprctl dispatch workspace e+1", "on-scroll-down": "hyprctl dispatch workspace e-1",
"on-scroll-down": "hyprctl dispatch workspace e-1", "format-icons": {
"format-icons": { "default": "",
"default": "", "special": "󰓏"
"special": "󰓏" }
} },
}, "hyprland/workspaces#numbers": {
"active-only": false,
"hyprland/workspaces#numbers": { "all-outputs": false,
"active-only": false, "format": "{name}",
"all-outputs": false, "show-special": true,
"format": "{name}", "on-click": "activate",
"show-special": true, "on-scroll-up": "hyprctl dispatch workspace e+1",
"on-click": "activate", "on-scroll-down": "hyprctl dispatch workspace e-1",
"on-scroll-up": "hyprctl dispatch workspace e+1", },
"on-scroll-down": "hyprctl dispatch workspace e-1",
},
"hyprland/window": { "hyprland/window": {
"format": "{title}", "format": "{title}",
"icon": "true", "icon": "true",
"icon-size": 16, "icon-size": 16,
"max-length": 30, "max-length": 30,
}, },
"hyprland/windowcount": {
"tray": { "format": "{}",
"icon-size": 15, "separate-outputs": true
"show-passive-items": true, },
"spacing": 8 "hyprland/language": {
}, "format": "{}",
"format-en": "EN",
"hyprland/submap": { "format-ru": "RU",
"format": "{}", "on-scroll-up": "hyprctl switchxkblayout all next",
"on-click": "hyprctl dispatch submap reset", "on-scroll-down": "hyprctl switchxkblayout all prev",
"always-on": "true", },
"default-submap": "reset", "hyprland/submap": {
}, "format": "{}",
"on-click": "hyprctl dispatch submap reset",
"custom/media": { "always-on": "true",
"format": "{icon} {0}", "default-submap": "reset",
"return-type": "json", },
"format-icons": { "tray": {
"Playing": "", "icon-size": 15,
"Paused": "" "show-passive-items": true,
}, "spacing": 8
"max-length": 50, },
"exec": "playerctl -a metadata --format '{\"text\": \"{{artist}} - {{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F", "custom/media": {
"on-click": "playerctl play-pause", "format": "{icon} {0}",
"on-scroll-up": "playerctl next", "return-type": "json",
"on-scroll-down": "playerctl previous" "format-icons": {
}, "Playing": "",
"Paused": ""
},
"max-length": 50,
"exec": "playerctl -a metadata --format '{\"text\": \"{{artist}} - {{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F",
"on-click": "playerctl play-pause",
"on-scroll-up": "playerctl next",
"on-scroll-down": "playerctl previous"
},
"custom/media#mini": { "custom/media#mini": {
"format": "{icon} {0}", "format": "{icon} {0}",
"return-type": "json", "return-type": "json",
...@@ -71,187 +75,161 @@ ...@@ -71,187 +75,161 @@
"Paused": "" "Paused": ""
}, },
"max-length": 30, "max-length": 30,
"exec": "playerctl -a metadata --format '{\"text\": \"{{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(artist)}} - {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F", "exec": "playerctl -a metadata --format '{\"text\": \"{{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(artist)}} - {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F",
"on-click": "playerctl play-pause", "on-click": "playerctl play-pause",
"on-scroll-up": "playerctl next", "on-scroll-up": "playerctl next",
"on-scroll-down": "playerctl previous" "on-scroll-down": "playerctl previous"
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "󰅶",
"deactivated": "󰾫"
},
"tooltip-format-activated": "Кофеин: активен\nРежим ожидания: отключен",
"tooltip-format-deactivated": "Кофеин: отключен\nРежим ожидания: активен"
}, },
"pulseaudio#volume": {
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "󰅶",
"deactivated": "󰾫"
},
"tooltip-format-activated": "Кофеин: активен\nРежим ожидания: отключен",
"tooltip-format-deactivated": "Кофеин: отключен\nРежим ожидания: активен"
},
"hyprland/language": {
"format": "{}",
"format-en": "EN",
"format-ru": "RU",
"on-scroll-up": "hyprctl switchxkblayout all next",
"on-scroll-down": "hyprctl switchxkblayout all prev",
},
"pulseaudio#volume": {
"scroll-step": 5, "scroll-step": 5,
"format": "{icon} {volume}%", "format": "{icon} {volume}%",
"format-bluetooth": " {icon} {volume}%", "format-bluetooth": " {icon} {volume}%",
"format-muted": " ", "format-muted": " ",
"tooltip-format": "{desc}", "tooltip-format": "{desc}",
"format-icons": { "format-icons": {
"headphone": "", "headphone": "",
"default": [ "default": [
"", "",
"", "",
"" ""
] ]
}, },
"on-click": "hyprctl dispatch exec '[size 820 400; move 100%-840 4%]' pwvucontrol", "on-click": "hyprctl dispatch exec '[size 820 400; move 100%-840 4%]' pwvucontrol",
"on-click-right": "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle" "on-click-right": "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
}, },
"pulseaudio#microphone": { "pulseaudio#microphone": {
"format": "{format_source}", "format": "{format_source}",
"format-source": " {volume}%", "format-source": " {volume}%",
"format-source-muted": " ", "format-source-muted": " ",
"on-click": "hyprctl dispatch exec '[size 820 400; move 100%-840 4%]' pwvucontrol", "on-click": "hyprctl dispatch exec '[size 820 400; move 100%-840 4%]' pwvucontrol",
"on-click-right": "wpctl set-mute @DEFAULT_SOURCE@ toggle", "on-click-right": "wpctl set-mute @DEFAULT_SOURCE@ toggle",
"on-scroll-up": "wpctl set-volume @DEFAULT_SOURCE@ 10%+ -l 1.0", "on-scroll-up": "wpctl set-volume @DEFAULT_SOURCE@ 10%+ -l 1.0",
"on-scroll-down": "wpctl set-volume @DEFAULT_SOURCE@ 10%- -l 1.0", "on-scroll-down": "wpctl set-volume @DEFAULT_SOURCE@ 10%- -l 1.0",
"tooltip-format": "{source_desc}" "tooltip-format": "{source_desc}"
}, },
"group/volume": {
"orientation": "horizontal",
"modules": [
"pulseaudio#volume",
"pulseaudio#microphone",
]
},
"network": { "network": {
"tooltip": true, "tooltip": true,
"format-wifi": " ", "format-wifi": " ",
"rotate": 0, "rotate": 0,
"format-ethernet": "󰈀", "format-ethernet": "󰈀",
"format-linked": "󰈀 (No IP)", "format-linked": "󰈀 (No IP)",
"format-disconnected": "󰖪 ", "format-disconnected": "󰖪 ",
"tooltip-format-disconnected": "Нет соединения", "tooltip-format-disconnected": "Нет соединения",
"format-alt": "<span foreground='#90ceaa'> {bandwidthDownBytes}</span> <span foreground='#dd6777'>  {bandwidthUpBytes}</span>", "format-alt": "<span foreground='#90ceaa'> {bandwidthDownBytes}</span> <span foreground='#dd6777'>  {bandwidthUpBytes}</span>",
"interval": 2, "interval": 2,
"on-click-right": "hyprctl dispatch exec '[size 910 460; move 100%-930 4%]' kitty nmtui" "on-click-right": "hyprctl dispatch exec '[size 910 460; move 100%-930 4%]' kitty nmtui"
}, },
"bluetooth": { "bluetooth": {
"format": "", "format": "",
"format-disabled": "󰂳", "format-disabled": "󰂳",
"format-on": "󰂱", "format-on": "󰂱",
"format-off": "󰂲", "format-off": "󰂲",
"format-disconnected": "󰂲", "format-disconnected": "󰂲",
"format-connected": "󰂱 {num_connections}", "format-connected": "󰂱 {num_connections}",
"tooltip": true, "tooltip": true,
"tooltip-format": "", "tooltip-format": "",
"tooltip-format-disabled": "󰂳 Отключено", "tooltip-format-disabled": "󰂳 Отключено",
"tooltip-format-off": "󰂳 Выключено", "tooltip-format-on": "󰂱 Включено",
"tooltip-format-connected": "{device_enumerate}", "tooltip-format-off": "󰂳 Выключено",
"tooltip-format-enumerate-connected": " {device_alias} 󰂄{device_battery_percentage}%", "tooltip-format-connected": "{device_enumerate}",
"on-click-right": "hyprctl dispatch exec '[size 530 350; move 100%-550 4%]' blueman-manager" "tooltip-format-enumerate-connected": " {device_alias} 󰂄{device_battery_percentage}%",
}, "on-click-right": "hyprctl dispatch exec '[size 530 350; move 100%-550 4%]' blueman-manager"
},
"battery": { "battery": {
"states": { "states": {
"good": 95, "good": 95,
"warning": 30, "warning": 30,
"critical": 15 "critical": 15
}, },
"format": "{icon} {capacity}%", "format": "{icon} {capacity}%",
"rotate": 0, "rotate": 0,
"format-charging": " {capacity}%", "format-charging": " {capacity}%",
"format-plugged": " {capacity}%", "format-plugged": " {capacity}%",
"format-alt": "{time} {icon}", "format-alt": "{time} {icon}",
"format-icons": [ "format-icons": [
"󰂎", "󰂎",
"󰁺", "󰁺",
"󰁻", "󰁻",
"󰁼", "󰁼",
"󰁽", "󰁽",
"󰁾", "󰁾",
"󰁿", "󰁿",
"󰂀", "󰂀",
"󰂁", "󰂁",
"󰂂", "󰂂",
"󰁹" "󰁹"
] ]
}, },
"backlight": {
"backlight": { "format": "{icon} {percent}%",
"format": "{icon} {percent}%", "format-icons": [
"format-icons": [ "",
"", "",
"", "",
"", "",
"", "",
"", "",
"", "",
"", "",
"", ""
"" ],
], "on-scroll-up": "brightnessctl s +5%",
"on-scroll-up": "brightnessctl s +5%", "on-scroll-down": "brightnessctl s 5%-"
"on-scroll-down": "brightnessctl s 5%-" },
}, "clock": {
"format": "{:%H:%M}",
"clock": { "tooltip-format": "<tt><big>{calendar}</big></tt>",
"format": "{:%H:%M}", "format-alt": "{:%Y-%m-%d}",
"tooltip-format": "<tt><big>{calendar}</big></tt>", "calendar": {
"format-alt": "{:%Y-%m-%d}", "mode": "month",
"calendar": { "weeks-pos": "left",
"mode": "month", "format": {
"weeks-pos": "left", "months": "<span color='#d0d3d8'><b>{}</b></span>",
"format": { "days": "<span color='#cbced3'><b>{}</b></span>",
"months": "<span color='#d0d3d8'><b>{}</b></span>", "weeks": "<span color='#95d3af'><b>W{}</b></span>",
"days": "<span color='#cbced3'><b>{}</b></span>", "weekdays": "<span color='#98d3ee'><b>{}</b></span>",
"weeks": "<span color='#95d3af'><b>W{}</b></span>", "today": "<span color='#e26c7c'><b><u>{}</u></b></span>"
"weekdays": "<span color='#98d3ee'><b>{}</b></span>", }
"today": "<span color='#e26c7c'><b><u>{}</u></b></span>" }
} },
} "custom/notification": {
}, "format": "{icon} {0}",
"format-icons": {
"custom/notification": { "notification": " <span foreground='red'><sup></sup></span>",
"format": "{icon} {0}", "none": " ",
"format-icons": { "dnd-notification": " <span foreground='red'><sup></sup></span>",
"notification": " <span foreground='red'><sup></sup></span>", "dnd-none": " ",
"none": " ", "inhibited-notification": " <span foreground='red'><sup></sup></span>",
"dnd-notification": " <span foreground='red'><sup></sup></span>", "inhibited-none": " ",
"dnd-none": " ", "dnd-inhibited-notification": " <span foreground='red'><sup></sup></span>",
"inhibited-notification": " <span foreground='red'><sup></sup></span>", "dnd-inhibited-none": " "
"inhibited-none": " ", },
"dnd-inhibited-notification": " <span foreground='red'><sup></sup></span>", "return-type": "json",
"dnd-inhibited-none": " " "exec-if": "which swaync-client",
}, "exec": "swaync-client -swb",
"return-type": "json", "on-click": "swaync-client -t -sw",
"exec-if": "which swaync-client", "on-click-right": "swaync-client -d -sw",
"exec": "swaync-client -swb", "escape": true
"on-click": "swaync-client -t -sw", },
"on-click-right": "swaync-client -d -sw",
"escape": true
},
"cpu": { "cpu": {
"interval": 1, "interval": 1,
"format": " {usage}%", "format": " {usage}%",
"tooltip-format": "{usage}" "tooltip-format": "{usage}"
}, },
"memory": { "memory": {
"interval": 1, "interval": 1,
"format": " {}%", "format": " {}%",
"tooltip-format": "memory: {used:0.1f}/{total:0.1f} GiB \nSWAP: {swapUsed:0.1f}/{swapTotal:0.1f} GiB" "tooltip-format": "memory: {used:0.1f}/{total:0.1f} GiB \nSWAP: {swapUsed:0.1f}/{swapTotal:0.1f} GiB"
}, },
"custom/ddclight": { "custom/ddclight": {
"tooltip": false, "tooltip": false,
"format": "{icon}", "format": "{icon}",
...@@ -272,4 +250,19 @@ ...@@ -272,4 +250,19 @@
"on-scroll-up": "ddclight set +5", "on-scroll-up": "ddclight set +5",
"on-scroll-down": "ddclight set 5-" "on-scroll-down": "ddclight set 5-"
}, },
// ---------- ГРУППЫ ---- GROUPS
"group/hypr-windowcount-workspaces": {
"orientation": "horizontal",
"modules": [
"hyprland/windowcount",
"hyprland/workspaces#icons"
]
},
"group/volume": {
"orientation": "horizontal",
"modules": [
"pulseaudio#volume",
"pulseaudio#microphone",
]
}
} }
...@@ -19,6 +19,7 @@ window#waybar { ...@@ -19,6 +19,7 @@ window#waybar {
} }
.module { .module {
background-color: @bg;
min-height: 0; min-height: 0;
border-radius: 20px; border-radius: 20px;
margin: 5px; margin: 5px;
...@@ -50,10 +51,6 @@ window#waybar { ...@@ -50,10 +51,6 @@ window#waybar {
padding: 0 10px 0 5px; padding: 0 10px 0 5px;
} }
#image:not(:hover) {
background: transparent
}
#workspaces.icons button { #workspaces.icons button {
padding: 0px; padding: 0px;
margin: 0px; margin: 0px;
......
...@@ -19,6 +19,7 @@ window#waybar { ...@@ -19,6 +19,7 @@ window#waybar {
} }
.module { .module {
background-color: @bg;
min-height: 0; min-height: 0;
border-radius: 20px; border-radius: 20px;
margin: 5px; margin: 5px;
...@@ -50,10 +51,6 @@ window#waybar { ...@@ -50,10 +51,6 @@ window#waybar {
padding: 0 10px 0 5px; padding: 0 10px 0 5px;
} }
#image:not(:hover) {
background: transparent
}
#workspaces.icons button { #workspaces.icons button {
padding: 0px; padding: 0px;
margin: 0px; margin: 0px;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment