hyprland and waybar

This commit is contained in:
Matthieu Fortin (CPC/CCP) 2024-09-25 15:21:04 -04:00
parent 77c1c64811
commit 5a1cfdd5a5
7 changed files with 1031 additions and 155 deletions

View file

@ -0,0 +1,213 @@
// -*- mode: jsonc -*-
{
// "layer": "top", // Waybar at top layer
// "position": "bottom", // Waybar position (top|bottom|left|right)
"height": 30, // Waybar height (to be removed for auto height)
// "width": 1280, // Waybar width
"spacing": 4, // Gaps between modules (4px)
// Choose the order of the modules
"modules-left": [
"hyprland/workspaces",
"custom/media"
],
"modules-center": [
"hyprland/window"
],
"modules-right": [
"mpd",
"idle_inhibitor",
"pulseaudio",
"network",
"power-profiles-daemon",
"cpu",
"memory",
"temperature",
"backlight",
"keyboard-state",
"hyprland/language",
"battery",
"battery#bat2",
"clock",
"tray",
"custom/power"
],
// Modules configuration
"hyprland/workspaces": {
"disable-scroll": true,
"all-outputs": true,
"warp-on-scroll": false,
"format": "{name}: {icon}",
"format-icons": {
// "1": "",
// "2": "",
// "3": "",
// "4": "",
// "5": "",
"urgent": "",
"focused": "",
"default": ""
}
},
"keyboard-state": {
"numlock": true,
"capslock": true,
"format": "{name} {icon}",
"format-icons": {
"locked": "",
"unlocked": ""
}
},
"sway/mode": {
"format": "<span style=\"italic\">{}</span>"
},
"sway/scratchpad": {
"format": "{icon} {count}",
"show-empty": false,
"format-icons": ["", ""],
"tooltip": true,
"tooltip-format": "{app}: {title}"
},
"mpd": {
"format": "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {album} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S}) ⸨{songPosition}|{queueLength}⸩ {volume}% ",
"format-disconnected": "Disconnected ",
"format-stopped": "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped ",
"unknown-tag": "N/A",
"interval": 5,
"consume-icons": {
"on": " "
},
"random-icons": {
"off": "<span color=\"#f53c3c\"></span> ",
"on": " "
},
"repeat-icons": {
"on": " "
},
"single-icons": {
"on": "1 "
},
"state-icons": {
"paused": "",
"playing": ""
},
"tooltip-format": "MPD (connected)",
"tooltip-format-disconnected": "MPD (disconnected)"
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "",
"deactivated": ""
}
},
"tray": {
// "icon-size": 21,
"spacing": 10
},
"clock": {
// "timezone": "America/New_York",
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>",
"format-alt": "{:%Y-%m-%d}"
},
"cpu": {
"format": "{usage}% ",
"tooltip": false
},
"memory": {
"format": "{}% "
},
"temperature": {
// "thermal-zone": 2,
// "hwmon-path": "/sys/class/hwmon/hwmon2/temp1_input",
"critical-threshold": 80,
// "format-critical": "{temperatureC}°C {icon}",
"format": "{temperatureC}°C {icon}",
"format-icons": ["", "", ""]
},
"backlight": {
// "device": "acpi_video1",
"format": "{percent}% {icon}",
"format-icons": ["", "", "", "", "", "", "", "", ""]
},
"battery": {
"states": {
// "good": 95,
"warning": 30,
"critical": 15
},
"format": "{capacity}% {icon}",
"format-full": "{capacity}% {icon}",
"format-charging": "{capacity}% ",
"format-plugged": "{capacity}% ",
"format-alt": "{time} {icon}",
// "format-good": "", // An empty format will hide the module
// "format-full": "",
"format-icons": ["", "", "", "", ""]
},
"battery#bat2": {
"bat": "BAT2"
},
"power-profiles-daemon": {
"format": "{icon}",
"tooltip-format": "Power profile: {profile}\nDriver: {driver}",
"tooltip": true,
"format-icons": {
"default": "",
"performance": "",
"balanced": "",
"power-saver": ""
}
},
"network": {
// "interface": "wlp2*", // (Optional) To force the use of this interface
"format-wifi": "{essid} ({signalStrength}%) ",
"format-ethernet": "{ipaddr}/{cidr} ",
"tooltip-format": "{ifname} via {gwaddr} ",
"format-linked": "{ifname} (No IP) ",
"format-disconnected": "Disconnected ⚠",
"format-alt": "{ifname}: {ipaddr}/{cidr}"
},
"pulseaudio": {
// "scroll-step": 1, // %, can be a float
"format": "{volume}% {icon} {format_source}",
"format-bluetooth": "{volume}% {icon} {format_source}",
"format-bluetooth-muted": " {icon} {format_source}",
"format-muted": " {format_source}",
"format-source": "{volume}% ",
"format-source-muted": "",
"format-icons": {
"headphone": "",
"hands-free": "",
"headset": "",
"phone": "",
"portable": "",
"car": "",
"default": ["", "", ""]
},
"on-click": "pavucontrol"
},
"custom/media": {
"format": "{icon} {text}",
"return-type": "json",
"max-length": 40,
"format-icons": {
"spotify": "",
"default": "🎜"
},
"escape": true,
"exec": "$HOME/.config/waybar/mediaplayer.py 2> /dev/null" // Script in resources folder
// "exec": "$HOME/.config/waybar/mediaplayer.py --player spotify 2> /dev/null" // Filter player based on name
},
"custom/power": {
"format" : "⏻ ",
"tooltip": false,
"menu": "on-click",
"menu-file": "$HOME/.config/waybar/power_menu.xml", // Menu file in resources folder
"menu-actions": {
"shutdown": "shutdown",
"reboot": "reboot",
"suspend": "systemctl suspend",
"hibernate": "systemctl hibernate"
}
}
}

View file

@ -1,75 +1,206 @@
{ {
"layer":"top", "modules-left": ["hyprland/workspaces"],
"position":"top",
"height": 32,
"modules-left":["hyprland/workspaces"], "hyprland/workspaces": {
"hyprland/workspaces": { "format": "{icon}",
// "persistent-workspaces":{"*":9,}, "format-icons": {
"sort-by":"id", "1": "1",
"format": "{icon} {windows}", "2": "2",
"format-icons":{ "3": "3",
"active":"", "4": "4",
"default":"", "5": "5",
}, "6": "6",
"format-window-separator": " ", "7": "7",
"window-rewrite-default": "", "8": "8",
// "window-rewrite": { "9": "9"
// "title<.*youtube.*>": "", // Windows whose titles contain "youtube" }
// "class<librewolf>": "", // Windows whose classes are "firefox"
// "class<librewolf> title<.*GitHub.*>": "", // Windows whose class is "firefox" and title contains "github". Note that "class" always comes first.
// "kitty": "", // Windows that contain "foot" in either class or title. For optimization reasons, it will only match against a title if at least one other window explicitly matches against a title.
// "code": "󰨞",
// },
}, },
"modules-center":["hyprland/window"], // ------------------------------------------------------------------------ //
"hyprland/window":{
"separate-outputs": true,
},
"modules-right":["keyboard-state#caps","keyboard-state#num","wireplumber","battery","clock"], "modules-center": [ "custom/weather", "clock", ],
"keyboard-state#caps": { "custom/weather": {
"capslock": true, "format": "{icon} {percentage}℃",
"numlock": true, "format-icons": {
"format": "{name} {icon}", "sunny": "󰖙",
"format-icons": { "partlycloudy": "󰖕",
"locked":"", "cloudy": "󰖐",
"unlocked": "" "verycloudy": "󰼯",
} "fog": "󰖑",
}, "lightrain": "󰖗",
// "keyboard-state#num": { "heavyrain": "󰖖",
// "numlock": true, "hail": "󰖒",
// "format": "{icon}", "thunder": "󰖓",
// "format-icons": { "lightsnow": "󰖘",
// "locked":"󰎣", "heavysnow": "󰼶",
// "unlocked": "" "snowrain": "󰙿"
// } },
// }, "exec": "$HOME/.config/waybar/modules/weather.sh",
"battery":{ "interval": 600,
"format":"{capacity}% {icon}", "return-type": "json",
"format-icons": ["", "", "", "", ""], "tooltip": true,
}, "on-click": "swx -t env REPORT=1 $HOME/.config/waybar/modules/weather.sh"
"clock": { },
"format":"{:%H:%M}",
"format-alt": "{:%Y-%m-%d %H:%M}" "custom/hotspots": {
}, "format": "{}",
"idle_inhibitor": { "exec": "$HOME/.config/waybar/modules/hotspots.sh",
"format": "{icon}", "on-click": "$HOME/.config/waybar/modules/hotspots.sh click",
"format-icons": { "escape": true,
"activated": "", "interval": 600,
"deactivated": "" "return-type": "json"
} },
},
"wireplumber": { // ------------------------------------------------------------------------ //
"format":"{volume}% {icon}", "modules-right": ["tray", "cpu", "memory", "disk#root", "disk#home", "temperature", "idle_inhibitor", "backlight", "wireplumber", "custom/vpn", "network#tailscale", "network", "battery", "clock"],
"format-muted": "",
"scroll-step": 1, "tray": {
"on-click":"qpwgraph", "icon-size": 15,
"format-icons": ["", "", ""], "spacing": 5
"tooltip":true, },
"tooltip-format": "{volume}%"
"disk#root": {
"path": "/",
"format": "󰋊 <small>/ </small>{percentage_used}%"
},
"disk#home": {
"path": "/home",
"format": "<small>/home </small>{percentage_used}%"
},
"cpu": {
"format": "{icon} {usage}%",
"format-icons": ["󰊚", "󰀦"],
"on-click": "$HOME/bin/swx -t -- btop"
},
"memory": {
"format": "{icon} {percentage}%",
"format-icons": ["󰘚", "󰀦"], // 󰍛
"on-click": "$HOME/bin/swx -t -- btop"
},
"temperature": {
"critical-threshold": 100,
"format": "{icon} {temperatureC}℃",
"format-icons": ["󱃃", "󰔏", "󰸁", "󱜜"]
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "󰅶",
"deactivated": "󰾪"
}
},
"backlight": {
"device": "auto",
"format": "{icon}",
"format-icons": ["󰹐", "󰌶", "󰛩", "󰖧"],
"on-scroll-down": "light -A 5",
"on-scroll-up": "light -U 5",
// save current level
// then set to minimum brightness
"on-click-right": "light -O; light -S $(light -P)",
// revert to previously saved brightness
"on-click-middle": "light -I"
},
"custom/gamma": {
"format": "{icon}",
"format-icons": {
"dawn": "󰱌",
"day": "󰱌",
"dusk": "󰱊",
"night": "󰱊",
},
"exec": "env GAMMA_COMMAND='wlsunset -l $HOME_LAT -L $HOME_LON -p' YAEGI_SYSCALL=1 YAEGI_UNRESTRICTED=1 ${HOME}/.config/waybar/modules/gamma.go",
"return-type": "json"
},
"wireblumper": {
"format": "{icon} {volume}%",
"format-bluetooth": "{icon}󰂯 {volume}%",
"format-muted": "󰝟 {volume}%",
"format-icons": {
"easyeffects_sink": "󰺢",
"headphones": "󰋋",
"handsfree": "󰜟",
"headset": "󰋎",
"phone": "󰏲",
"portable": "󰛵",
"car": "󰄋",
"default": ["󰕿", "󰖀", "󰕾"]
},
},
"custom/vpn": {
"exec": "${HOME}/.config/waybar/modules/vpn.sh",
"interval": 600,
"return-type": "json",
"on-click": "${HOME}/.config/waybar/modules/vpn.sh toggle",
},
"network#tailscale": {
"interface": "tailscale0",
"format": "󰌆",
"format-disconnected": "󰌊",
"tooltip-format": "{ifname}: {bandwidthUpBits} {bandwidthDownBits}",
"tooltip-format-disconnected": "disconnected",
"on-click": "${HOME}/.config/waybar/modules/tailscale.sh toggle",
},
"network": {
"format-wifi": "{icon} {signalStrength}%",
"format-icons": ["󰤫", "󰤟", "󰤢", "󰤥", "󰤨"],
"format-ethernet": "󰌗",
"format-linked": "󰈀 {ifname}",
"format-disconnected": "󰌙 ",
"tooltip-format": "{ifname}: {ipaddr}/{cidr}\ngateway: {gwaddr}\nssid: {essid}\nsignal: {signaldBm} dbm\ndown: {bandwidthDownBits}\nup: {bandwidthUpBits}",
"tooltip-format-disconnected": "disconnected",
// cycles through wifi/ethernet/off
// "on-click": "${HOME}/.config/waybar/modules/network.sh toggle",
},
"battery": {
"states": {
"good": 90,
"warning": 30,
"critical": 15
},
"format": "{icon} {capacity}%",
"format-charging": "󰗱 {capacity}%",
"format-full-charging": "󱊦",
"format-icons": ["󱃍", "󱊡", "󱊢", "󱊣"]
},
"clock": {
"format": " {:%H:%M}",
"format-alt":" {:%Y-%m-%d  %H:%M (%Z)}",
// "tooltip-format": "{tz_list}\n<tt><small>{calendar}</small></tt>",
"timezones": [ "Canada/Eastern","Etc/UTC"],
"calendar": {
"mode":"year",
"mode-mon-col": 3,
"weeks-pos":"left",
"on-scroll":1,
"format": {
"months": "<span font='JetBrains Mono Nerd Font Mono' color='#ffead3'><b>{}</b></span>",
"days": "<span font='JetBrains Mono Nerd Font Mono' color='#ecc6d9'><b>{}</b></span>",
"weeks": "<span font='JetBrains Mono Nerd Font Mono' color='#99ffdd'><b>W{}</b></span>",
"weekdays": "<span font='JetBrains Mono Nerd Font Mono' color='#ffcc66'><b>{}</b></span>",
"today": "<span font='JetBrains Mono Nerd Font Mono' color='#ff6699'><b><u>{}</u></b></span>"
}
},
"actions": {
"on-click-right": "mode",
"on-click-forward": "tz_up",
"on-click-backward": "tz_down",
"on-scroll-up": "shift_up",
"on-scroll-down": "shift_down"
}
},
} }
}

View file

@ -0,0 +1,23 @@
#!/bin/sh
set -e
[ -n "$DEBUG" ] && set -x
if ! command -v timetrace >/dev/null 2>&1; then
exit 0
fi
case "$1" in
on-click)
timetrace status >/dev/null && timetrace stop
exit 0
;;
*) ;;
esac
while true; do
timetrace status -o json |
jq -c 'if .project == "---" then {} else { text: (["▶", .trackedTimeToday] | join(" ")), class: "timetracked", alt: "timetracked" } end' 2>/dev/null
sleep 30
done

View file

@ -0,0 +1,44 @@
#!/bin/sh
set -e
[ -n "$DEBUG" ] && set -x
# loc=$1
loc="45.4208,-75.6901"
if [ -z "${loc}" ]; then
# use /etc/localtime
# loc=$(basename "$(readlink -f /etc/localtime)")
# loc="${HOME_LAT},${HOME_LON}"
loc="45.4208,-75.6901"
fi
if [ -n "$REPORT" ]; then
curl -s v2.wttr.in/"${loc}"?F | less
exit 0
fi
# data="$(curl -s wttr.in/"${loc}"?format=j1)"
data="$(curl -s wttr.in/"${loc}"?format=j1)"
class=
case "$(echo "${data}" | jq -r '.current_condition[].weatherCode')" in
113) class="sunny" ;;
116) class="partlycloudy" ;;
119) class="cloudy" ;;
122) class="verycloudy" ;;
143|248|260) class="fog" ;;
176|263|266|293|296|353) class="lightrain" ;;
179|182|185|281|284|311|314|317|350|362|365|374|377) class="hail" ;;
200|386|389|392) class="thunder" ;;
227|320) class="lightsnow" ;;
230|329|332|335|338|371|395) class="heavysnow" ;;
299|302|305|308|356|359): class="heavyrain" ;;
323|326|368) class="snowrain" ;;
esac
echo "${data}" | jq \
--raw-output \
--unbuffered \
--compact-output \
--arg class "${class}" \
--arg tooltip "$(curl -s v2.wttr.in/"${loc}"?ATFQ | tail -n5)" \
'.current_condition[] | { text: .weatherDesc[0].value, percentage: (.temp_C | tonumber), class: $class, alt: $class, tooltip: ($tooltip) }'

View file

@ -0,0 +1,75 @@
{
"layer":"top",
"position":"top",
"height": 32,
"modules-left":["hyprland/workspaces"],
"hyprland/workspaces": {
// "persistent-workspaces":{"*":9,},
"sort-by":"id",
"format": "{icon} {windows}",
"format-icons":{
"active":"",
"default":"",
},
"format-window-separator": " ",
"window-rewrite-default": "",
// "window-rewrite": {
// "title<.*youtube.*>": "", // Windows whose titles contain "youtube"
// "class<librewolf>": "", // Windows whose classes are "firefox"
// "class<librewolf> title<.*GitHub.*>": "", // Windows whose class is "firefox" and title contains "github". Note that "class" always comes first.
// "kitty": "", // Windows that contain "foot" in either class or title. For optimization reasons, it will only match against a title if at least one other window explicitly matches against a title.
// "code": "󰨞",
// },
},
"modules-center":["hyprland/window"],
"hyprland/window":{
"separate-outputs": true,
},
"modules-right":["keyboard-state#caps","keyboard-state#num","wireplumber","battery","clock"],
"keyboard-state#caps": {
"capslock": true,
"numlock": true,
"format": "{name} {icon}",
"format-icons": {
"locked":"",
"unlocked": ""
}
},
// "keyboard-state#num": {
// "numlock": true,
// "format": "{icon}",
// "format-icons": {
// "locked":"󰎣",
// "unlocked": ""
// }
// },
"battery":{
"format":"{capacity}% {icon}",
"format-icons": ["", "", "", "", ""],
},
"clock": {
"format":"{:%H:%M}",
"format-alt": "{:%Y-%m-%d %H:%M}"
},
"idle_inhibitor": {
"format": "{icon}",
"format-icons": {
"activated": "",
"deactivated": ""
}
},
"wireplumber": {
"format":"{volume}% {icon}",
"format-muted": "",
"scroll-step": 1,
"on-click":"qpwgraph",
"format-icons": ["", "", ""],
"tooltip":true,
"tooltip-format": "{volume}%"
}
}

View file

@ -0,0 +1,120 @@
* {
font-family: FontAwesome, 'Noto Sans', sans-serif;
font-size: 1rem;
min-height: 0;
border: none;
border-radius: 0;
}
window#waybar {
background-color: rgba(43,48,59,0.5);
color: #ffffff;
}
tooltip {
background: rgba(43,48,59,0.5);
border: 1px solid rgba(100,114,125,0.5)
}
tooltip label {
color: white;
}
#wireplumber,
#clock,
#battery {
padding: 0 0.625rem;
/* color: #ffffff; */
}
#workspace button {
padding: 0 0.5em;
background: transparent;
color: white;
border-bottom: 3px solid transparent;
}
#workspace button.focused {
background: #64727D;
border-bottom: 3px solid white;
}
#window,
#workspaces {
margin: 0 0.25rem;
}
.modules-left > widget:first-child > #workspaces {
margin-left: 0;
}
.modules-right > widget:last-child > #workspaces {
margin-right: 0;
}
#wireplumber,
#battery {
background-color: #ffffff;
color: #000000;
}
#battery.plugged {
color: #ffffff;
background-color: #26A65B;
}
#battery.discharging {
background-color: #ff1111;
}
#battery.charging {
background-color: #00ff00;
}
#battery.charging {
color: white;
background-color: #26A65B;
}
@keyframes blink {
to {
background-color: #ffffff;
color: black;
}
}
#battery.warning:not(.charging) {
background: #f53c3c;
color: white;
animation-name: blink;
animation-duration: 0.5s;
animation-timing-function: steps(12);
animation-iteration-count: infinite;
animation-direction: alternate;
}
#clock {
background-color: #ffffff;
color: #000000;
}
#idle_inhibitor.activated {
font-size: 1.5rem;
}
#idle_inhibitor.deactivated {
font-size: 1.5rem;
}
#keyboard-state {
margin: 0 0.625rem;
min-width: 0.5rem;
/* padding: 0 0.625rem; */
}
#keyboard-state > label {
padding: 0 5px;
}
#keyboard-state > label.locked {
background: rgba(0, 0, 0, 0.2);
}

View file

@ -1,120 +1,390 @@
/*
* vim: fdm=marker fdl=1
* */
/* start flavours */
@define-color base00 #0c0c0c;
@define-color base01 #db4d6d;
@define-color base02 #5dac81;
@define-color base03 #fad689;
@define-color base04 #58b2dc;
@define-color base05 #69b0ac;
@define-color base06 #70649a;
@define-color base07 #bdc0ba;
@define-color base08 #1c1c1c;
@define-color base09 #cb1b45;
@define-color base0A #86c166;
@define-color base0B #f7d94c;
@define-color base0C #2ea9df;
@define-color base0D #81c7d4;
@define-color base0E #8a6bbe;
@define-color base0F #fffffb;
* { * {
font-family: FontAwesome, 'Noto Sans', sans-serif; font-family: 'Noto Sans', FontAwesome, Material Design Icons;
font-size: 1rem; font-size: 12pt;
min-height: 0; }
border: none; /* end flavours */
border-radius: 0;
@define-color accent @base06;
@define-color accentdarker @base0E;
@define-color foreground @base07;
@define-color background @base00;
/* @define-color background rgba(12, 12, 12, 0.96); */
@define-color dimmed #5e5e5e;
@define-color dimmeddarker #434343;
@define-color urgent @base09;
* {
border: none;
border-radius: 0;
} }
window#waybar { window#waybar {
background-color: rgba(43,48,59,0.5); background: @background;
color: #ffffff; color: @foreground;
/* padding: 0 0.3rem; */
} }
tooltip { window#waybar.hidden {
background: rgba(43,48,59,0.5); opacity: 0;
border: 1px solid rgba(100,114,125,0.5)
}
tooltip label {
color: white;
} }
#wireplumber,
#clock,
#battery {
padding: 0 0.625rem;
/* color: #ffffff; */
}
#workspace button {
padding: 0 0.5em;
background: transparent;
color: white;
border-bottom: 3px solid transparent;
}
#workspace button.focused {
background: #64727D;
border-bottom: 3px solid white;
}
#window, #window,
#workspaces { #mode,
margin: 0 0.25rem; #clock,
} #battery,
#cpu,
.modules-left > widget:first-child > #workspaces { #memory,
margin-left: 0; #disk,
} #temperature,
#backlight,
.modules-right > widget:last-child > #workspaces { #idle_inhibitor,
margin-right: 0; #network,
} #pulseaudio,
#wireplumber, #wireplumber,
#battery { #custom-toggl,
background-color: #ffffff; #custom-gammastep,
color: #000000; #custom-weather,
#custom-mpris,
#custom-todo,
#custom-covid,
#custom-timetracked,
#tray {
/* border-top: 1px solid @dimmeddarker; */
padding: 0 0.1rem;
margin: 0 0.2rem;
color: @dimmed;
} }
#battery.plugged { #cpu:hover,
color: #ffffff; #memory:hover,
background-color: #26A65B; #backlight:hover,
#idle_inhibitor:hover,
#network:hover,
#network.tailscale:hover,
#pulseaudio:hover,
#wireplumber:hover,
#custom-mpris:hover,
#custom-gammastep:hover,
#custom-todo:hover {
color: @foreground;
transition-property: background;
transition-duration: 0.1s;
} }
#battery.discharging { #tags button,
background-color: #ff1111; #workspaces button {
padding: 0 5px;
background: transparent;
color: @dimmed;
/* border-bottom: 3px solid transparent; */
} }
#tags button {
color: @dimmeddarker;
}
#tags button.occupied {
color: @dimmed;
}
#workspaces button.visible {
color: @dimmeddarker;
background: @accentdarker;
}
#tags button.focused,
#workspaces button.focused {
font-weight: bold;
color: @foreground;
background: @accent;
transition-property: background;
transition-duration: 0.01s;
}
#tags button.urgent,
#workspaces button.urgent {
color: @background;
background: @urgent;
}
#tags button:hover,
#tags button.focused:hover,
#workspaces button:hover,
#workspaces button.focused:hover {
background: @accent;
color: @foreground;
transition-property: background, color;
transition-duration: 0.01s;
/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */
box-shadow: inherit;
text-shadow: inherit;
}
#tags button.urgent:hover,
#workspaces button.urgent:hover {
background: @foreground;
transition-property: background;
transition-duration: 0.01s;
}
#mode {
/* font-style: italic; */
color: @background;
background: @base03;
margin: 3px 6px;
border-radius: 2px;
}
#clock {}
#clock.local {
color: @foreground;
}
#clock.utc {}
#disk.root {}
#disk.home {
/* margin-left: 0; */
/* padding-left: 0; */
}
#battery {}
#battery.charging { #battery.charging {
background-color: #00ff00; color: @background;
} background: @base0A;
#battery.charging {
color: white;
background-color: #26A65B;
} }
@keyframes blink { @keyframes blink {
to { to {
background-color: #ffffff; background: @foreground;
color: black; color: @background;
} }
} }
#battery.warning:not(.charging) { #battery.critical:not(.charging) {
background: #f53c3c; color: @foreground;
color: white; background: @urgent;
animation-name: blink; animation-name: blink;
animation-duration: 0.5s; animation-duration: 0.5s;
animation-timing-function: steps(12); animation-timing-function: linear;
animation-iteration-count: infinite; animation-iteration-count: infinite;
animation-direction: alternate; animation-direction: alternate;
} }
#clock { label:focus {
background-color: #ffffff; background: @background;
color: #000000;
} }
#cpu {}
#memory {}
#backlight {}
#backlight.off {
color: @dimmed;
}
#network {}
#network.disconnected {
border-top: 1px solid @urgent;
color: @dimmed;
}
#network.tailscale.disabled,
#network.tailscale.disconnected,
#network.mullvad.disabled,
#network.mullvad.disconnected {
border-top: 1px solid @dimmeddarker;
}
#network.tailscale.ethernet,
#network.tailscale.linked,
#network.mullvad.ethernet,
#network.mullvad.linked {
color: @foreground;
border-top: 1px solid @base0E;
}
#pulseaudio {}
#pulseaudio.muted {
border-top: 1px solid @urgent;
color: @dimmed;
}
#pulseaudio.bluetooth {
border-top: 1px solid @base04;
}
#wireplumber {}
#wireplumber.muted {
border-top: 1px solid @urgent;
color: @dimmed;
}
#wireplumber.bluetooth {
border-top: 1px solid @base04;
}
#temperature {}
#temperature.critical {
color: @foreground;
background: @urgent;
border-top: none;
}
#tray {}
#idle_inhibitor {}
#idle_inhibitor.activated { #idle_inhibitor.activated {
font-size: 1.5rem; color: @foreground;
border-top: 1px solid @base02;
} }
#idle_inhibitor.deactivated { #mpris {
font-size: 1.5rem; color: @foreground;
} }
#keyboard-state { #mpris.playing,
margin: 0 0.625rem; #mpris.paused {
min-width: 0.5rem; border-top: 1px solid @base04;
/* padding: 0 0.625rem; */
} }
#keyboard-state > label { #mpris.paused {
padding: 0 5px; font-style: italic;
} }
#keyboard-state > label.locked { #mpris.spotify {
background: rgba(0, 0, 0, 0.2); border-top: 1px solid #1db954;
}
#mpris.mpv {
border-top: 1px solid #8f008f;
}
#custom-toggl {
color: @foreground;
border-top: 1px solid @urgent;
}
#custom-todo.off {
color: @dimmed;
border-top: 1px solid @dimmeddarker;
padding: 0 0 0 0.4rem;
}
#custom-todo.on {
color: @foreground;
border-top: 1px solid @urgent;
font-weight: bold;
padding: 0 0.6rem 0 0.4rem;
}
#custom-todo.work {
background: @urgent;
}
#custom-timetracked {
color: @urgent;
border-top: 1px solid @urgent;
}
@keyframes flash {
50% {
background: rgba(255, 174, 66, 0.7);
color: @background;
}
}
#custom-gamma.night {
border-top: 1px solid @base0C;
color: @foreground;
animation-name: flash;
animation-duration: 0.3s;
animation-timing-function: linear;
animation-iteration-count: 1;
}
#custom-gamma.day {
color: @dimmed;
}
#custom-gamma.off {
border-top: 1px solid @urgent;
color: @dimmed;
}
#custom-weather {
color: @dimmed;
}
#custom-covid.green {
/* border-top: 1px solid #00cc00; */
/* color: #00cc00; */
}
#custom-covid.yellow {
/* border-top: 1px solid #f7dd31; */
/* color: #f7dd31; */
}
#custom-covid.orange {
/* border-top: 1px solid #faa31b; */
/* color: #faa31b; */
}
#custom-covid.red {
/* border-top: 1px solid #f92206; */
/* color: #f92206; */
}
#custom-covid.darkred {
/* border-top: 1px solid #c01a00; */
/* color: #c01a00; */
}
#custom-covid.darkdarkred {
/* border-top: 1px solid #941100; */
/* color: #941100; */
}
#custom-hotspots {
border-top: 1px solid @urgent;
color: @dimmed;
}
#custom-hotspots.soon {
color: @urgent;
} }