notifications to icon button
This commit is contained in:
parent
2762c7952a
commit
160cd3c1d5
1 changed files with 7 additions and 19 deletions
|
|
@ -1,34 +1,22 @@
|
|||
import qs.components
|
||||
import qs.config
|
||||
import qs.constants
|
||||
import qs.services
|
||||
import qs.widgets
|
||||
import QtQuick
|
||||
|
||||
StyledButton {
|
||||
StyledIconButton {
|
||||
id: root
|
||||
|
||||
onClicked: {
|
||||
menu.toggle();
|
||||
}
|
||||
|
||||
content: StyledText {
|
||||
id: text
|
||||
text: Notifications.hasNotifications ? Icons.bell : Icons.bellRing
|
||||
|
||||
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
|
||||
}
|
||||
states: State {
|
||||
when: Notifications.hasNotifications
|
||||
PropertyChanges {
|
||||
root {
|
||||
text: Icons.bellRing
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue