Fix link preview layout

This commit is contained in:
Ali
2023-07-03 12:35:41 +02:00
parent 4c8f8132c0
commit 4ca0e55d15
2 changed files with 13 additions and 3 deletions

View File

@@ -526,11 +526,18 @@ final class ChatMessageAttachedContentNode: ASDisplayNode {
}
}
if preferMediaBeforeText {
if preferMediaBeforeText, let textString, textString.length != 0 {
isImage = false
}
let statusInText = !isImage
var statusInText = !isImage
if let textString {
if textString.length == 0 {
statusInText = false
}
} else {
statusInText = false
}
switch preparePosition {
case .linear(_, .None), .linear(_, .Neighbour(true, _, _)):