From fa6a4e85436a089345cd0a92ae52181a9b54f840 Mon Sep 17 00:00:00 2001 From: Pico Date: Sun, 9 Nov 2025 00:11:12 +0300 Subject: [PATCH] spice it up with smooth animations --- .../modules/common/widgets/StyledComboBox.qml | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/dots/.config/quickshell/ii/modules/common/widgets/StyledComboBox.qml b/dots/.config/quickshell/ii/modules/common/widgets/StyledComboBox.qml index cab4a23a6..6bebd6667 100644 --- a/dots/.config/quickshell/ii/modules/common/widgets/StyledComboBox.qml +++ b/dots/.config/quickshell/ii/modules/common/widgets/StyledComboBox.qml @@ -105,6 +105,40 @@ ComboBox { height: Math.min(listView.contentHeight + topPadding + bottomPadding, 300) padding: 8 + enter: Transition { + NumberAnimation { + property: "opacity" + from: 0 + to: 1 + duration: 200 + easing.type: Easing.OutCubic + } + NumberAnimation { + property: "height" + from: 0 + to: popup.height + duration: 200 + easing.type: Easing.OutCubic + } + } + + exit: Transition { + NumberAnimation { + property: "opacity" + from: 1 + to: 0 + duration: 150 + easing.type: Easing.InCubic + } + NumberAnimation { + property: "height" + from: popup.height + to: 0 + duration: 150 + easing.type: Easing.InCubic + } + } + background: Rectangle { radius: Appearance.rounding.normal color: Appearance.colors.colSurfaceContainerHigh