refactor bottomBar smol bit

This commit is contained in:
Schrottkatze 2024-09-10 22:07:27 +02:00
parent bd3674accf
commit 54a1e34fa6
Signed by: schrottkatze
SSH key fingerprint: SHA256:hXb3t1vINBFCiDCmhRABHX5ocdbLiKyCdKI4HK2Rbbc
2 changed files with 19 additions and 18 deletions

View file

@ -1,3 +1,5 @@
(include "bottomBar/workspaces.yuck")
(defwindow bottomBar
:monitor 0
:stacking "fg"
@ -39,21 +41,3 @@
)
)
)
(defwidget workspaceWidget []
(box
:class "workspaces"
(for workspace in workspaces
(button
:class "${workspace.urgent ? "urgent" : ""} ${workspace.focused ? "focused" : 0}"
:onclick "swaymsg workspace ${workspace.name}"
(label :text "${workspace.name}")
)
)
)
)
(deflisten workspaces
:initial "[]"
"bar-ws-monitor"
)

View file

@ -0,0 +1,17 @@
(defwidget workspaceWidget []
(box
:class "workspaces"
(for workspace in workspaces
(button
:class "${workspace.urgent ? "urgent" : ""} ${workspace.focused ? "focused" : 0}"
:onclick "swaymsg workspace ${workspace.name}"
(label :text "${workspace.name}")
)
)
)
)
(deflisten workspaces
:initial "[]"
"bar-ws-monitor"
)