mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
feat(custom): make spotify module generic
Set class via json attribute Choose icon via alt attribute
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
// "height": 30, // Waybar height
|
||||
// "width": 1280, // Waybar width
|
||||
// Choose the order of the modules
|
||||
"modules-left": ["sway/workspaces", "sway/mode", "custom/spotify"],
|
||||
"modules-left": ["sway/workspaces", "sway/mode", "custom/media"],
|
||||
"modules-center": ["sway/window"],
|
||||
"modules-right": ["idle_inhibitor", "pulseaudio", "network", "cpu", "memory", "temperature", "backlight", "battery", "battery#bat2", "clock", "tray"],
|
||||
// Modules configuration
|
||||
@ -95,9 +95,14 @@
|
||||
},
|
||||
"on-click": "pavucontrol"
|
||||
},
|
||||
"custom/spotify": {
|
||||
"format": " {}",
|
||||
"custom/media": {
|
||||
"format": "{icon} {}",
|
||||
"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
|
||||
}
|
||||
|
Reference in New Issue
Block a user