mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-11-29 06:28:45 +03:00
Fix sending emotes or user pills in replies
Change-Id: Idc47d2fcfb28359bda89308a8d830469991d268c
This commit is contained in:
parent
59db6af93e
commit
45b7d7882c
2 changed files with 5 additions and 3 deletions
|
@ -574,8 +574,10 @@ internal class LocalEchoEventFactory @Inject constructor(
|
|||
|
||||
val body = bodyForReply(eventReplied.getLastMessageContent(), eventReplied.isReply())
|
||||
|
||||
// For inline images and user pills
|
||||
val replyTextProcessed = textPillsUtils.processSpecialSpansToHtml(replyText) ?: replyText
|
||||
// As we always supply formatted body for replies we should force the MarkdownParser to produce html.
|
||||
val replyTextFormatted = markdownParser.parse(replyText, force = true, advanced = autoMarkdown).takeFormatted()
|
||||
val replyTextFormatted = markdownParser.parse(replyTextProcessed, force = true, advanced = autoMarkdown).takeFormatted()
|
||||
// Body of the original message may not have formatted version, so may also have to convert to html.
|
||||
val bodyFormatted = body.formattedText ?: markdownParser.parse(body.text, force = true, advanced = autoMarkdown).takeFormatted()
|
||||
val replyFormatted = buildFormattedReply(
|
||||
|
|
|
@ -542,13 +542,13 @@ class MessageComposerViewModel @AssistedInject constructor(
|
|||
state.rootThreadEventId?.let {
|
||||
room.relationService().replyInThread(
|
||||
rootThreadEventId = it,
|
||||
replyInThreadText = action.text.toString(),
|
||||
replyInThreadText = action.text,
|
||||
autoMarkdown = action.autoMarkdown,
|
||||
eventReplied = timelineEvent
|
||||
)
|
||||
} ?: room.relationService().replyToMessage(
|
||||
eventReplied = timelineEvent,
|
||||
replyText = action.text.toString(),
|
||||
replyText = action.text,
|
||||
autoMarkdown = action.autoMarkdown,
|
||||
showInThread = showInThread,
|
||||
rootThreadEventId = rootThreadEventId
|
||||
|
|
Loading…
Reference in a new issue