move and add menu

This commit is contained in:
Benjamin Palko 2025-08-02 21:08:18 -04:00
parent 87e9941e0a
commit 3e3275a84d
4 changed files with 128 additions and 10 deletions

View file

@ -0,0 +1,42 @@
import qs.config
import qs.constants
import qs.services
import qs.widgets
import QtQuick
StyledButton {
id: root
onClicked: {
menu.toggle();
}
content: StyledText {
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 {
when: Notifications.hasNotifications
PropertyChanges {
text {
text: Icons.bellRing
color: root.containsMouse ? Theme.palette.base300 : Theme.palette.secondary
}
}
}
}
NotificationMenu {
id: menu
anchor.item: root
anchor.rect.x: root.width / 2 - width / 2
anchor.rect.y: root.height + 8
}
}