Add threads display and prettier highlight to bubbles style

This commit is contained in:
Nicolas Werner 2023-10-09 22:29:53 +02:00
parent 57a27396ad
commit f47f66f748
No known key found for this signature in database
GPG key ID: C8D75E610773F2D9

View file

@ -82,7 +82,9 @@ TimelineEvent {
}, },
Rectangle { Rectangle {
anchors.fill: gridContainer anchors.fill: gridContainer
color: (Settings.messageHoverHighlight && messageHover.hovered) ? palette.alternateBase : "transparent" property color threadColor: TimelineManager.userColor(wrapper.threadId, palette.base)
property color threadBackgroundColor: wrapper.threadId ? Qt.tint(palette.base, Qt.hsla(threadColor.hslHue, 0.7, threadColor.hslLightness, 0.1)) : "transparent"
color: (Settings.messageHoverHighlight && messageHover.hovered) ? palette.alternateBase : threadBackgroundColor
// this looks better without margins // this looks better without margins
TapHandler { TapHandler {
@ -281,7 +283,7 @@ TimelineEvent {
padding: wrapper.isStateEvent ? 0 : 4 padding: wrapper.isStateEvent ? 0 : 4
background: Rectangle { background: Rectangle {
color: !wrapper.isStateEvent ? Qt.tint(palette.base, Qt.hsla(messageBubble.userColor.hslHue, 0.5, messageBubble.userColor.hslLightness, 0.2)) : "transparent" color: !wrapper.isStateEvent ? Qt.tint(palette.base, Qt.hsla(messageBubble.userColor.hslHue, wrapper.hovered ? 0.8 : 0.5, messageBubble.userColor.hslLightness, 0.2)) : "transparent"
radius: 4 radius: 4
border.color: Nheko.theme.red border.color: Nheko.theme.red
border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0 border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0