eww: play-pause button
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
(defpoll position :interval "1s" "~/.local/bin/spotify-lyrics position")
|
||||
(defpoll length :interval "1s" "~/.local/bin/spotify-lyrics length")
|
||||
(defpoll offset :interval "1s" "cat $HOME/.local/state/eww/lyrics/offset")
|
||||
(defvar hover false)
|
||||
(defpoll play-button :interval "1s" "if ~/.local/bin/spotify-lyrics status; then echo \"\"; else echo \"\"; fi")(defvar hover false)
|
||||
|
||||
(defwidget lyrics []
|
||||
(box :class "lyrics-window" :space-evenly "false" :orientation "v"
|
||||
@@ -41,9 +41,9 @@
|
||||
(box :class "player-controls-box"
|
||||
:vexpand "false" :hexpand "false" :valign "center" :space-evenly "false" :orientation "h"
|
||||
(button :class "player-prev" :onclick "playerctl prev --player=spotify" "")
|
||||
(button :class "player-pp" :onclick "playerctl play-pause --player=spotify" "")
|
||||
(button :class "player-pp" :onclick "playerctl play-pause --player=spotify" "${play-button}")
|
||||
(button :class "player-next" :onclick "playerctl next --player=spotify" "")
|
||||
(button :class "lyrics-info" :onclick "ghostty -e '\"$HOME/.local/bin/spotify-lyrics\" fetch | less' &" "")
|
||||
(button :class "lyrics-info" :onclick "ghostty -e '\"$HOME/.local/bin/spotify-lyrics\" fetch -p | less' &" "")
|
||||
)
|
||||
(box :class "offset-box"
|
||||
:vexpand "false" :hexpand "true" :valign "center" :halign "center" :space-evenly "false" :orientation "h"
|
||||
@@ -67,7 +67,7 @@
|
||||
)
|
||||
(box :class "control-box-single" :vexpand "false" :hexpand "false" :space-evenly "true" :orientation "v"
|
||||
(box :class "control-row-1-single" :space-evenly "false" :orientation "h"
|
||||
(button :class "info-single" :onclick "ghostty -e '\"$HOME/.local/bin/spotify-lyrics\" fetch | less' &" "")
|
||||
(button :class "info-single" :onclick "ghostty -e '\"$HOME/.local/bin/spotify-lyrics\" fetch -p | less' &" "")
|
||||
(button :class "offset-plus-single" :onclick "Lyrics/scripts/lyric-offset.py +500" "")
|
||||
(button :class "offset-reset-single" :onclick "Lyrics/scripts/lyric-offset.py" "")
|
||||
(button :class "offset-minus-single" :onclick "Lyrics/scripts/lyric-offset.py -500" "")
|
||||
|
||||
Reference in New Issue
Block a user