fix: fix copy link submenu items being unreadable in dark theme

Fixes #2194
This commit is contained in:
Jonathan Rainville 2021-04-07 13:36:30 -04:00 committed by Iuri Matias
parent b45cbe83b7
commit 8c753d58f0
1 changed files with 15 additions and 0 deletions

View File

@ -150,15 +150,30 @@ PopupMenu {
PopupMenu {
id: copyLinkMenu
title: qsTr("Copy link")
Repeater {
id: linksRepeater
model: messageContextMenu.linkUrls.split(" ")
delegate: MenuItem {
id: popupMenuItem
text: modelData
onTriggered: {
chatsModel.copyToClipboard(modelData)
messageContextMenu.close()
}
contentItem: StyledText {
text: popupMenuItem.text
font: popupMenuItem.font
color: Style.current.textColor
horizontalAlignment: Text.AlignLeft
verticalAlignment: Text.AlignVCenter
elide: Text.ElideRight
}
background: Rectangle {
implicitWidth: 220
implicitHeight: 34
color: popupMenuItem.highlighted ? Style.current.backgroundHover: "transparent"
}
}
}
}