102 lines
2.5 KiB
Text
102 lines
2.5 KiB
Text
(include "modules/bar.yuck")
|
|
|
|
(include "modules/bar/workspaces.yuck")
|
|
|
|
(include "modules/bar/profile.yuck")
|
|
|
|
(include "modules/bar/window_name.yuck")
|
|
|
|
(include "modules/bar/clock.yuck")
|
|
|
|
(include "modules/bar/idle_inhibit.yuck")
|
|
|
|
(defwidget revealer-on-hover [revealvar revealvar-name ?class ?duration ?transition]
|
|
(box
|
|
:class "${class} revealer-on-hover"
|
|
:orientation "h"
|
|
:space-evently false
|
|
(eventbox
|
|
:onhover "${EWW_CMD} update ${revealvar-name}=true"
|
|
: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))))))
|
|
|
|
(include "modules/bar/powermenu.yuck")
|
|
|
|
(include "modules/bar/network.yuck")
|
|
|
|
(include "modules/bar/bluetooth.yuck")
|
|
|
|
(include "modules/bar/volume.yuck")
|
|
|
|
(include "modules/bar/battery.yuck")
|
|
|
|
(include "modules/bar/tray.yuck")
|
|
|
|
(include "modules/bar/vpn.yuck")
|
|
|
|
(include "modules/bar/sysmem.yuck")
|
|
|
|
(include "modules/bar/sysdisk.yuck")
|
|
|
|
(include "modules/bar/music.yuck")
|
|
|
|
(defwidget metric [label value onchange]
|
|
(box :orientation "h"
|
|
:class "metric"
|
|
:space-evenly false
|
|
(box :class "label" label)
|
|
(circular-progress
|
|
:active {onchange != ""}
|
|
:value value
|
|
:start-at 0
|
|
:thickness 10
|
|
:clockwise true
|
|
:onchange onchange)))
|
|
|
|
;(defpoll time :interval "10s"
|
|
; "date '+%H:%M %b %d, %Y'")
|
|
|
|
(include "modules/bar.yuck")
|
|
|
|
(defwidget widgets []
|
|
(box :class "widgets"
|
|
:orientation "v"
|
|
:spacing 10
|
|
:width 300
|
|
:space-evenly false
|
|
(rat)
|
|
(weather :json weather_status)))
|
|
|
|
(defpoll rat_image :interval "60s"
|
|
'scripts/randomrat')
|
|
;(defvar rat_image "/home/penelope/Pictures/Phone/Albums/Rattos/20211109_042550_IMG_9873.JPG")
|
|
(defwidget rat []
|
|
(box
|
|
:class "rat"
|
|
:orientation "h"
|
|
:width 300
|
|
:height 300
|
|
:style "background-image: url('${rat_image}');"))
|
|
|
|
(defpoll weather_status :interval "3600s"
|
|
'curl wttr.in/Eugene?format=j1')
|
|
(defwidget weather [json]
|
|
(box
|
|
:class "weather"
|
|
:orientation "v"
|
|
:width 300
|
|
:height 125
|
|
:space-evenly true
|
|
"Eugene, OR | ${json.current_condition[0].weatherDesc[0].value}"
|
|
"${json.current_condition[0].temp_F}°F (feels like ${json.current_condition[0].FeelsLikeF}°F)"
|
|
"${json.weather[0].mintempF}°F / ${json.weather[0].maxtempF}°F"
|
|
"${json.current_condition[0].humidity}% humidity"))
|
|
|
|
(include "windows.yuck")
|