1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-24 21:42:51 -05:00

displays: add niri-specific layout options to configurator

This commit is contained in:
bbedward
2025-12-16 12:23:34 -05:00
parent f6b09751e9
commit ff506548d3
9 changed files with 1028 additions and 303 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -32,15 +32,17 @@ StyledRect {
readonly property bool collapsed: collapsible && !expanded
readonly property bool hasHeader: root.title !== "" || root.iconName !== ""
property bool animationsEnabled: false
Component.onCompleted: Qt.callLater(() => animationsEnabled = true)
property bool userToggledCollapse: false
Behavior on height {
enabled: root.animationsEnabled
enabled: root.userToggledCollapse
NumberAnimation {
duration: Theme.shortDuration
easing.type: Theme.standardEasing
onRunningChanged: {
if (!running)
root.userToggledCollapse = false;
}
}
}
@@ -98,6 +100,7 @@ StyledRect {
onClicked: {
if (!root.collapsible)
return;
root.userToggledCollapse = true;
root.expanded = !root.expanded;
}
}
@@ -108,14 +111,6 @@ StyledRect {
width: parent.width
spacing: Theme.spacingM
visible: !root.collapsed
opacity: root.collapsed ? 0 : 1
Behavior on opacity {
NumberAnimation {
duration: Theme.shortDuration
easing.type: Theme.standardEasing
}
}
}
}
}