diff --git a/components/StyledIconButton.qml b/components/StyledIconButton.qml index 780113d..98a9662 100644 --- a/components/StyledIconButton.qml +++ b/components/StyledIconButton.qml @@ -11,35 +11,25 @@ RoundButton { } property alias border: rect.border - property color color: hovered ? Theme.palette.primarycontent : Theme.palette.basecontent - property int rotation: 0 font.family: loader.font.family - font.pixelSize: 18 + font.pixelSize: 16 radius: 8 - padding: 6 + padding: 8 HoverHandler { cursorShape: Qt.PointingHandCursor } contentItem: Text { - id: icon font: control.font text: control.text - color: control.color + color: control.hovered ? Theme.palette.primarycontent : Theme.palette.basecontent Behavior on color { ColorAnimation { duration: 100 } } - rotation: control.rotation - Behavior on rotation { - RotationAnimation { - duration: 200 - easing.type: Easing.InOutCubic - } - } } background: Rectangle { diff --git a/modules/bar/components/Pywal.qml b/modules/bar/components/Pywal.qml index d83c508..b21078b 100644 --- a/modules/bar/components/Pywal.qml +++ b/modules/bar/components/Pywal.qml @@ -1,17 +1,27 @@ -import qs.components +import qs.config import qs.constants +import qs.widgets import QtQuick import Quickshell.Io -StyledIconButton { +StyledButton { id: clickable - text: Icons.brickWall - onClicked: { process.running = true; } + content: StyledText { + id: text + + font.family: Theme.lucide.font.family + font.pixelSize: Dimensions.caffeine.fontSize + font.bold: true + text: Icons.brickWall + + color: clickable.containsMouse ? Theme.palette.base300 : Theme.palette.basecontent + } + Process { id: process command: ["sh", "-c", "~/dotfiles/.scripts/pywal-swww.sh"] diff --git a/modules/bar/components/bluetooth/Bluetooth.qml b/modules/bar/components/bluetooth/Bluetooth.qml index c12c93b..80097e0 100644 --- a/modules/bar/components/bluetooth/Bluetooth.qml +++ b/modules/bar/components/bluetooth/Bluetooth.qml @@ -1,13 +1,23 @@ -import qs.components +import qs.config import qs.constants +import qs.widgets -StyledIconButton { +StyledButton { id: root - text: Icons.bluetooth - onClicked: popup.toggle() + content: StyledText { + id: text + + font.family: Theme.lucide.font.family + font.pixelSize: Dimensions.bluetooth.fontSize + font.bold: true + text: Icons.bluetooth + + color: root.containsMouse ? Theme.palette.base300 : Theme.palette.basecontent + } + BluetoothMenu { id: popup diff --git a/modules/bar/components/hyprland/Workspace.qml b/modules/bar/components/hyprland/Workspace.qml index 47270ce..d03298e 100644 --- a/modules/bar/components/hyprland/Workspace.qml +++ b/modules/bar/components/hyprland/Workspace.qml @@ -1,5 +1,3 @@ -pragma ComponentBehavior: Bound - import qs.config import qs.constants import qs.widgets @@ -7,7 +5,6 @@ import QtQuick import Quickshell.Hyprland Loader { - id: root required property HyprlandWorkspace modelData active: modelData.id > 0 @@ -16,7 +13,7 @@ Loader { property Component workspace: StyledButton { id: clickable - onClicked: root.modelData.activate() + onClicked: modelData.activate() content: Text { id: icon @@ -31,7 +28,7 @@ Loader { states: [ State { name: "focused" - when: root.modelData.focused + when: modelData.focused PropertyChanges { icon { rotation: 180 @@ -41,7 +38,7 @@ Loader { }, State { name: "active" - when: root.modelData.active + when: modelData.active PropertyChanges { icon { text: Icons.triangleDashed