eww(mediaplayer): add image path support for album art

This commit is contained in:
retrozinndev
2025-01-09 22:50:24 -03:00
parent 0e7f0cd3fb
commit a14034035e
10 changed files with 32 additions and 102 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
(defwidget clock []
(box :class "clock"
:tooltip { formattime(EWW_TIME, "%A, %B %d") }
:tooltip { day_name + ", " + month_name + formattime(EWW_TIME, " %d") }
(eventbox :onclick "sh scripts/eww-window.sh toggle calendar-window"
:class '${ window_state_calendar-window == "open" ? "cal-open" : "" } button'
@@ -10,7 +10,7 @@
(label :text "󰸗"
:class "icon")
(label :text "${ formattime(EWW_TIME, "%A") }")
(label :text "${day_name}")
(revealer :reveal { window_state_calendar-window == "closed" }
:transition "slideright"
+2
View File
@@ -6,10 +6,12 @@
:space-evenly false
(box :class "cpu"
:visible { cpu == "" || cpu ? true : false }
:tooltip { "CPU: " + arraylength(EWW_CPU?.cores) + " Threads" }
(label :text " ${ round(EWW_CPU?.avg, 0) }%")
)
(box :class "memory"
:visible { memory == "" || memory ? true : false }
:tooltip { "Total Memory: " + round(EWW_RAM?.total_mem / 1000000000, 1) + " GiB(s)" }
(label :text " ${ round(EWW_RAM?.used_mem_perc, 0) }%")
)
)
+1
View File
@@ -45,6 +45,7 @@
(button :class "url"
:onclick "wl-copy '${json_media.url}'"
:tooltip "Copy link to Clipboard"
:visible { json_media != "" && json_media.url != "null" }
"󰌷")
(button :class "previous"
:onclick "playerctl previous --player=${json_media.player}"