uiux: adjust hover color for menu items in profile and channel list

This commit is contained in:
Pascal Precht 2021-01-22 11:21:24 +01:00 committed by Iuri Matias
parent 062c2e26b2
commit 4fbe1f202f
2 changed files with 13 additions and 2 deletions

View File

@ -35,9 +35,12 @@ Rectangle {
id: wrapper id: wrapper
color: { color: {
if (ListView.isCurrentItem || wrapper.hovered) { if (ListView.isCurrentItem) {
return Style.current.secondaryBackground return Style.current.secondaryBackground
} }
if (wrapper.hovered) {
return Style.current.backgroundHover
}
return Style.current.transparent return Style.current.transparent
} }
anchors.right: parent.right anchors.right: parent.right

View File

@ -14,7 +14,15 @@ Rectangle {
property var onClicked: function () {} property var onClicked: function () {}
id: menuButton id: menuButton
color: hovered || active ? Style.current.secondaryBackground : Style.current.transparent color: {
if (active) {
return Style.current.secondaryBackground
}
if (hovered) {
return Style.current.backgroundHover
}
return Style.current.transparent
}
border.width: 0 border.width: 0
height: 48 height: 48
width: parent.width width: parent.width