notifications to icon button

This commit is contained in:
Benjamin Palko 2025-08-29 16:53:28 -04:00
parent 2762c7952a
commit 160cd3c1d5

View file

@ -1,34 +1,22 @@
import qs.components import qs.components
import qs.config
import qs.constants import qs.constants
import qs.services import qs.services
import qs.widgets
import QtQuick import QtQuick
StyledButton { StyledIconButton {
id: root id: root
onClicked: { onClicked: {
menu.toggle(); menu.toggle();
} }
content: StyledText { text: Notifications.hasNotifications ? Icons.bell : Icons.bellRing
id: text
font.family: Theme.lucide.font.family
font.pixelSize: Dimensions.notifications.fontSize
font.bold: true
text: Icons.bell
color: root.containsMouse ? Theme.palette.base300 : Theme.palette.basecontent
states: State { states: State {
when: Notifications.hasNotifications when: Notifications.hasNotifications
PropertyChanges { PropertyChanges {
text { root {
text: Icons.bellRing text: Icons.bellRing
color: root.containsMouse ? Theme.palette.base300 : Theme.palette.secondary
}
} }
} }
} }