// NavigationRailExpandButton.qml from end-4 https://github.com/end-4/dots-hyprland/blob/eac4ab3e3c249008d9596023f79dbc2d31012600/.config/quickshell/ii/modules/common/widgets/NavigationRailExpandButton.qml import QtQuick import QtQuick.Layouts import qs.common import qs.common.widgets RippleButton { id: root Layout.alignment: Qt.AlignLeft implicitWidth: 40 implicitHeight: 40 Layout.leftMargin: 8 onClicked: { parent.expanded = !parent.expanded; } buttonRadius: Appearance.rounding.full rotation: root.parent.expanded ? 0 : -180 Behavior on rotation { animation: Appearance.animation.elementMoveFast.numberAnimation.createObject(this) } contentItem: MaterialSymbol { id: icon anchors.centerIn: parent horizontalAlignment: Text.AlignHCenter iconSize: 24 color: Appearance.colors.colOnLayer1 text: root.parent.expanded ? "menu_open" : "menu" } }