updated icons in waybar
This commit is contained in:
@@ -70,7 +70,7 @@
|
||||
"interval": 30,
|
||||
"format-icons": {
|
||||
// match these to the sink NAMES you see in `pactl list sinks`
|
||||
"alsa_output.usb-SteelSeries_Arctis_7_-00.analog-stereo": "", // SteelSeries headset
|
||||
"alsa_output.usb-SteelSeries_Arctis_7_-00.analog-stereo": "", // SteelSeries headset
|
||||
"alsa_output.pci-0000_0a_00.4.iec958-stereo": "", // speaker icon for your soundbar
|
||||
"bluez_output.50_5E_5C_2D_F3_B2.1": "", // Bluetooth earbud icon
|
||||
"default": [
|
||||
@@ -96,14 +96,14 @@
|
||||
"exec": "$HOME/.config/waybar/scripts/alhp.sh",
|
||||
"return-type": "json",
|
||||
"interval": 60,
|
||||
"format": "<span color=\"#4F84CC\">{text}</span>",
|
||||
"format": "{text}",
|
||||
"tooltip": true,
|
||||
},
|
||||
"custom/razer-mouse-battery": {
|
||||
"exec": "$HOME/.config/waybar/scripts/razer_basilisk_v3_pro_battery_info.sh",
|
||||
"return-type": "json",
|
||||
"interval": 10,
|
||||
"format": "<span color=\"#4F84CC\">{text}</span>",
|
||||
"format": "{text}",
|
||||
"tooltip": true,
|
||||
},
|
||||
"tray": {
|
||||
|
@@ -37,15 +37,15 @@ else
|
||||
fi
|
||||
|
||||
case "$class" in
|
||||
good) icon="";;
|
||||
stale) icon="";;
|
||||
bad) icon="";;
|
||||
down) icon="x";;
|
||||
good) icon=" ";;
|
||||
stale) icon=" ";;
|
||||
bad) icon=" ";;
|
||||
down) icon="x ";;
|
||||
esac
|
||||
|
||||
# Emit compact JSON for Statusbar
|
||||
jq -nc \
|
||||
--arg text "$icon $text" \
|
||||
--arg text "<span color=\"#4F84CC\">$icon</span> <span color=\"#CAD3E8\">$text</span>" \
|
||||
--arg class "$class" \
|
||||
--arg tooltip "$tooltip" \
|
||||
'{text: $text, class: $class, tooltip: $tooltip}'
|
||||
|
@@ -19,17 +19,21 @@ type=$(cat "$BASE_MOUSE/device_type")
|
||||
percent=$(( raw * 100 / 255 ))
|
||||
|
||||
tooltip="$type"
|
||||
icon=""
|
||||
|
||||
# Choose icon + class
|
||||
if [[ $status -eq 1 ]]; then
|
||||
icon="⚡"
|
||||
cls="charging"
|
||||
text=" $icon $percent%"
|
||||
icon="⚡"
|
||||
class="charging"
|
||||
text="$percent%"
|
||||
else
|
||||
cls="not_charging"
|
||||
text=" $percent%"
|
||||
class="not_charging"
|
||||
text="$percent%"
|
||||
fi
|
||||
|
||||
# Output Waybar‐friendly JSON
|
||||
printf '{"text":"%s","class":"%s","tooltip":"%s"}\n' "$text" "$cls" "$tooltip"
|
||||
jq -nc \
|
||||
--arg text "<span color=\"#4F84CC\">$icon</span> <span color=\"#CAD3E8\">$text</span>" \
|
||||
--arg class "$class" \
|
||||
--arg tooltip "$tooltip" \
|
||||
'{text: $text, class: $class, tooltip: $tooltip}'
|
||||
|
||||
|
Reference in New Issue
Block a user