added new widget "alhp"
This commit is contained in:
@@ -69,6 +69,7 @@
|
||||
:space-evenly false
|
||||
:spacing 5
|
||||
:halign 'end'
|
||||
(alhp)
|
||||
(hyprsunset)
|
||||
(volume)
|
||||
(datetime)
|
||||
|
@@ -8,3 +8,4 @@
|
||||
@import 'widgets/sysmon.scss';
|
||||
@import 'widgets/swaync.scss';
|
||||
@import 'widgets/volume.scss';
|
||||
@import 'widgets/alhp.scss';
|
||||
|
@@ -8,3 +8,4 @@
|
||||
(include "widgets/sysmon.yuck")
|
||||
(include "widgets/swaync.yuck")
|
||||
(include "widgets/volume.yuck")
|
||||
(include "widgets/alhp.yuck")
|
||||
|
11
.config/eww/widgets/alhp.scss
Normal file
11
.config/eww/widgets/alhp.scss
Normal file
@@ -0,0 +1,11 @@
|
||||
.alhp{
|
||||
&--good {
|
||||
background: olivedrab;
|
||||
color: white;
|
||||
}
|
||||
|
||||
&--bad {
|
||||
background: maroon;
|
||||
color: white;
|
||||
}
|
||||
}
|
15
.config/eww/widgets/alhp.yuck
Normal file
15
.config/eww/widgets/alhp.yuck
Normal file
@@ -0,0 +1,15 @@
|
||||
(deflisten alhpNogo :initial '{"total": 0, "packages": []}' "alhp.utils -j")
|
||||
|
||||
(defwidget alhp []
|
||||
(box
|
||||
:class '${alhpNogo.total == 0 ? "alhp--good" : "alhp--bad"}'
|
||||
:space-evenly false
|
||||
:spacing 0
|
||||
(tooltip
|
||||
(box :orientation "vertical"
|
||||
(for package in {alhpNogo.packages}
|
||||
(box
|
||||
:orientation "horizontal"
|
||||
:space-evenly false
|
||||
(label :text {package}))))
|
||||
(label :text "${alhpNogo.total} "))))
|
Reference in New Issue
Block a user