fix(StatusListItem): ensure icon background in secondary type works correctly

This commit is contained in:
Pascal Precht 2021-06-22 10:59:54 +02:00 committed by Pascal Precht
parent de2c36d0e9
commit 34b35318bc
2 changed files with 9 additions and 3 deletions

View File

@ -224,6 +224,12 @@ GridLayout {
] ]
} }
StatusListItem {
title: "Title"
icon.name: "info"
type: StatusListItem.Type.Secondary
}
StatusDescriptionListItem { StatusDescriptionListItem {
title: "Title" title: "Title"
subTitle: "Subtitle" subTitle: "Subtitle"

View File

@ -37,9 +37,9 @@ Rectangle {
background: StatusIconBackgroundSettings { background: StatusIconBackgroundSettings {
width: 40 width: 40
height: 40 height: 40
color: type === StatusListItem.Type.Primary ? color: sensor.containsMouse && type === StatusListItem.Type.Secondary ?
Theme.palette.primaryColor3 : "transparent" :
"transparent" Theme.palette.primaryColor3
} }
} }
property StatusImageSettings image: StatusImageSettings { property StatusImageSettings image: StatusImageSettings {