Add dialog to see who has read this message

You were previously relegated to looking at any avatars or a buggy
tooltip, but suffer no longer! If you tap on a message's read marker, a
dialog will pop up listing the users who have read it.

Uou can also view their profiles from here, etc.
This commit is contained in:
Joshua Goins
2026-01-09 18:25:11 -05:00
parent 71c84be4b4
commit e8da02be7d
6 changed files with 118 additions and 27 deletions

View File

@@ -8,16 +8,24 @@ import QtQuick.Layouts
import org.kde.kirigami as Kirigami
import org.kde.kirigamiaddons.labs.components as KirigamiComponents
import org.kde.neochat
RowLayout {
id: root
property var avatarSize: Kirigami.Units.iconSizes.small
property alias model: avatarFlowRepeater.model
property alias model: root.limiterModel.sourceModel
property string toolTipText
property LimiterModel limiterModel: LimiterModel {
maximumCount: 5
}
spacing: -avatarSize / 2
Repeater {
id: avatarFlowRepeater
model: root.limiterModel
delegate: KirigamiComponents.Avatar {
required property string displayName
required property url avatarUrl
@@ -39,11 +47,11 @@ RowLayout {
Layout.preferredHeight: Kirigami.Units.iconSizes.small + Kirigami.Units.smallSpacing
Layout.fillHeight: true
visible: text !== ""
visible: root.limiterModel.extraCount > 0
color: Kirigami.Theme.textColor
horizontalAlignment: Text.AlignHCenter
text: root.model?.excessReadMarkersString ?? ""
text: "+ " + root.limiterModel.extraCount
background: Kirigami.ShadowedRectangle {
color: Kirigami.Theme.backgroundColor