From c928cd3ca4f1a3f950dd0915160a87ae89bfb636 Mon Sep 17 00:00:00 2001 From: rope Date: Wed, 27 May 2026 12:23:52 +0100 Subject: [PATCH] quickshell: remove inner dropdown wrappers Co-Authored-By: Claude Opus 4.6 --- settings/hyprland.nix | 125 ++++++++++-------------------------------- 1 file changed, 30 insertions(+), 95 deletions(-) diff --git a/settings/hyprland.nix b/settings/hyprland.nix index c09007d..1794d2a 100644 --- a/settings/hyprland.nix +++ b/settings/hyprland.nix @@ -1273,7 +1273,7 @@ in width: dropdown.fullWidth height: dropdown.open ? dropdown.fullHeight : 0 color: Theme.barBg - radius: 10 + radius: 8 topLeftRadius: 0 topRightRadius: 0 bottomRightRadius: dropdown.alignRight ? 0 : 8 @@ -1319,8 +1319,8 @@ in id: contextMenu alignRight: true property var trayItem: null - fullWidth: ctxWrap.width + 8 - fullHeight: ctxWrap.height + 4 + fullWidth: menuItems.width + 24 + fullHeight: menuItems.height + 16 onVisibleChanged: { if (!visible) menuOpener.menu = null; @@ -1330,21 +1330,10 @@ in id: menuOpener } - Rectangle { - id: ctxWrap - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.top - - - width: menuItems.width + 16 - height: menuItems.height + 12 - radius: 10 - color: Theme.base01 - - Column { - id: menuItems - anchors.centerIn: parent - width: 200 + Column { + id: menuItems + anchors.centerIn: parent + width: 200 Repeater { model: menuOpener.children @@ -1402,7 +1391,6 @@ in } } } - } } } @@ -1410,25 +1398,14 @@ in BarDropdown { id: volDropdown alignRight: true - fullWidth: volWrap.width + 8 - fullHeight: volWrap.height + 4 + fullWidth: volDropdownCol.width + 28 + fullHeight: volDropdownCol.height + 20 autoCloseMs: 3000 - Rectangle { - id: volWrap - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.top - - - width: volDropdownCol.width + 20 - height: volDropdownCol.height + 16 - radius: 10 - color: Theme.base01 - - Column { - id: volDropdownCol - anchors.centerIn: parent - width: 260 + Column { + id: volDropdownCol + anchors.centerIn: parent + width: 260 spacing: 8 // Master volume @@ -1449,7 +1426,7 @@ in width: parent.width - masterVolLabel.width - 8 height: 20 radius: 4 - color: Theme.base02 + color: Theme.base01 anchors.verticalCenter: parent.verticalCenter Rectangle { @@ -1567,7 +1544,7 @@ in width: parent.width - appVolLabel.width - 8 height: 16 radius: 3 - color: Theme.base02 + color: Theme.base01 anchors.verticalCenter: parent.verticalCenter Rectangle { @@ -1606,7 +1583,6 @@ in } } } - } } } @@ -1614,24 +1590,13 @@ in BarDropdown { id: netDropdown alignRight: true - fullWidth: netWrap.width + 8 - fullHeight: netWrap.height + 4 + fullWidth: netDropdownCol.width + 28 + fullHeight: netDropdownCol.height + 20 - Rectangle { - id: netWrap - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.top - - - width: netDropdownCol.width + 20 - height: netDropdownCol.height + 16 - radius: 10 - color: Theme.base01 - - Column { - id: netDropdownCol - anchors.centerIn: parent - width: 220 + Column { + id: netDropdownCol + anchors.centerIn: parent + width: 220 spacing: 4 Text { @@ -1759,7 +1724,6 @@ in } } } - } } } @@ -1768,24 +1732,13 @@ in BarDropdown { id: batteryDropdown alignRight: true - fullWidth: batWrap.width + 8 - fullHeight: batWrap.height + 4 + fullWidth: batteryDropdownCol.width + 28 + fullHeight: batteryDropdownCol.height + 20 - Rectangle { - id: batWrap - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.top - - - width: batteryDropdownCol.width + 20 - height: batteryDropdownCol.height + 16 - radius: 10 - color: Theme.base01 - - Column { - id: batteryDropdownCol - anchors.centerIn: parent - width: 200 + Column { + id: batteryDropdownCol + anchors.centerIn: parent + width: 200 spacing: 8 Row { @@ -1888,7 +1841,6 @@ in } } } - } } } ''} @@ -1912,21 +1864,6 @@ in NumberAnimation { duration: 150; easing.type: Easing.OutCubic } } - Rectangle { - width: 7 * 32 + 24 - height: calWrapCol.height + 16 - radius: 10 - - color: Theme.base01 - anchors.horizontalCenter: parent.horizontalCenter - - Column { - id: calWrapCol - anchors.horizontalCenter: parent.horizontalCenter - anchors.top: parent.top - anchors.topMargin: 8 - spacing: 8 - Rectangle { width: 7 * 32 + 8 height: calTitle.height + 12 @@ -2091,7 +2028,7 @@ in width: 7 * 32 + 8 height: notifCol.height + 12 radius: 6 - color: Theme.base02 + color: Theme.base01 Column { id: notifCol @@ -2133,9 +2070,9 @@ in width: actionText.width + 12 height: actionText.height + 4 radius: 4 - color: actionMa.containsMouse ? Theme.base03 : Theme.base02 + color: actionMa.containsMouse ? Theme.base02 : Theme.base01 border.width: 1 - border.color: Theme.base03 + border.color: Theme.base02 Text { id: actionText anchors.centerIn: parent @@ -2176,8 +2113,6 @@ in } } } - } - } } } }