qol(qs): scaling based on exists, focused and not

This commit is contained in:
2026-03-11 11:32:07 +00:00
parent eb593db0c0
commit cbd3c408e1
3 changed files with 19 additions and 7 deletions

View File

@@ -20,13 +20,22 @@ Item {
required property int index
property bool focused: HyprlandHelpers.getHyprlandWorkspaceById(index + 1).focused
property bool exists: HyprlandHelpers.getHyprlandWorkspaceById(index + 1) ? true : false
state: focused && exists ? "FOCUSED" : "NOT"
state: focused ? "FOCUSED" : (exists ? "EXISTS" : "NOT")
states: [
State {
name: "FOCUSED"
PropertyChanges {
target: content
width: 10
scale: 1
}
},
State {
name: "EXISTS"
PropertyChanges {
target: content
width: 10
scale: 0.85
}
},
State {
@@ -34,6 +43,7 @@ Item {
PropertyChanges {
target: content
width: 10
scale: 0.75
}
}
]