From e74be0934e1f3a01ebd42a627f0e2514a731c1d2 Mon Sep 17 00:00:00 2001 From: cberthet <capucine.berthet@savoirfairelinux.com> Date: Thu, 14 Dec 2023 17:03:05 -0500 Subject: [PATCH] linkMessage: new design GitLab: #1325 Change-Id: Id9b4e1430575fbf53f0657e94c9a27c5b35e4a93 --- src/app/commoncomponents/TextMessageDelegate.qml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/app/commoncomponents/TextMessageDelegate.qml b/src/app/commoncomponents/TextMessageDelegate.qml index ce5fe1bcc..2584a31b2 100644 --- a/src/app/commoncomponents/TextMessageDelegate.qml +++ b/src/app/commoncomponents/TextMessageDelegate.qml @@ -33,7 +33,7 @@ SBSMessageBase { property string colorUrl: UtilsAdapter.luma(bubble.color) ? JamiTheme.chatviewLinkColorLight : JamiTheme.chatviewLinkColorDark property string colorText: UtilsAdapter.luma(bubble.color) ? JamiTheme.chatviewTextColorLight : JamiTheme.chatviewTextColorDark - bigMsg: textEditId.lineCount > 1 + bigMsg: (textEditId.lineCount > 1) || extraContent.active Connections { target: bubble @@ -142,7 +142,7 @@ SBSMessageBase { anchors.right: isOutgoing ? parent.right : undefined property real minSize: 192 - property real maxSize: 320 + property real maxSize: 400 active: LinkPreviewInfo.url !== undefined sourceComponent: ColumnLayout { id: previewContent @@ -200,7 +200,7 @@ SBSMessageBase { Layout.preferredWidth: img.width - 2 * hPadding Layout.leftMargin: hPadding Layout.rightMargin: hPadding - spacing: 6 + spacing: 4 Label { width: parent.width font.pointSize: 10 @@ -211,10 +211,11 @@ SBSMessageBase { color: root.colorText visible: LinkPreviewInfo.title.length > 0 text: LinkPreviewInfo.title + lineHeight: 1.3 } Label { width: parent.width - font.pointSize: 11 + font.pointSize: 10 font.hintingPreference: Font.PreferNoHinting wrapMode: Label.WrapAtWordBoundaryOrAnywhere renderType: Text.NativeRendering @@ -223,6 +224,7 @@ SBSMessageBase { font.underline: root.hoveredLink text: LinkPreviewInfo.description color: root.colorUrl + lineHeight: 1.3 } Label { width: parent.width @@ -233,6 +235,7 @@ SBSMessageBase { textFormat: TextEdit.RichText color: root.colorText text: LinkPreviewInfo.domain + lineHeight: 1.3 } } } -- GitLab