dotfiles/de/home/.config/eww/modules/bar/revealer-on-hover.yuck
2026-02-17 20:45:02 -08:00

12 lines
697 B
Text

(defwidget revealer-on-hover [revealvar revealvar-name ?class ?duration ?transition]
(box :class "${class} revealer-on-hover"
:orientation "h"
:space-evenly false
(eventbox :onscroll "if test '{}' = 'down';then ${EWW_CMD} update ${revealvar-name}=true;else ${EWW_CMD} update ${revealvar-name}=false;fi"
:onhoverlost "${EWW_CMD} update ${revealvar-name}=false"
(box :space-evenly false
(children :nth 0)
(revealer :reveal revealvar
:transition {transition ?: "slideright"}
:duration {duration ?: "500ms"}
(children :nth 1))))))