summaryrefslogtreecommitdiff
path: root/modules/bar/components/workspaces
diff options
context:
space:
mode:
author2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-04-30 12:50:12 +1000
committer2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-04-30 12:50:12 +1000
commit65c54e12c29502a75dc722d788fba626cc926f65 (patch)
tree9a92c4ee40b45ccc0f7e407107c5837f825c9553 /modules/bar/components/workspaces
parentbar: workspaces some fixes (diff)
downloadcaelestia-shell-65c54e12c29502a75dc722d788fba626cc926f65.tar.gz
caelestia-shell-65c54e12c29502a75dc722d788fba626cc926f65.tar.bz2
caelestia-shell-65c54e12c29502a75dc722d788fba626cc926f65.zip
bar: custom workspace labels
Diffstat (limited to 'modules/bar/components/workspaces')
-rw-r--r--modules/bar/components/workspaces/Workspace.qml7
1 files changed, 5 insertions, 2 deletions
diff --git a/modules/bar/components/workspaces/Workspace.qml b/modules/bar/components/workspaces/Workspace.qml
index 5af0e62..a6e2b43 100644
--- a/modules/bar/components/workspaces/Workspace.qml
+++ b/modules/bar/components/workspaces/Workspace.qml
@@ -11,10 +11,13 @@ StyledText {
readonly property bool isWorkspace: true // Flag for finding workspace children
- property int ws: groupOffset + index + 1
+ readonly property int ws: groupOffset + index + 1
+ readonly property string label: BarConfig.workspaces.label || ws
+ readonly property string activeLabel: BarConfig.workspaces.activeLabel || label
animate: true
- text: ws
+ animateProp: "scale"
+ text: (Hyprland.activeWorkspace?.id ?? 1) === ws ? activeLabel : label
color: BarConfig.workspaces.occupiedBg || occupied[ws] ? Appearance.colours.text : Appearance.colours.subtext0
horizontalAlignment: StyledText.AlignHCenter