Skip to content

Commit

Permalink
Fix element-hq/element-web#6523 Emoji rendering destroys paragraphs
Browse files Browse the repository at this point in the history
This regression was probably introduced in
4f4441f and is caused by the fact that
the variable `isHtml` conflates two different meanings:

- The event contains an HTML message
- The event message is displayed using HTML

This is an important difference. Plain text messages that contain
emojies are rendered with an HTML string and thus have to be sanitized
etc. But they must not use the MarkDown CSS styles for HTML messages.

The MarkDown CSS styles include `whitespace: normal` because HTML events
use `<br/>`-tags for line breaks. Plain text messages with emojies
obviously don't use `<br/>`-tags, so these styles must not be applied.

Signed-off-by: Jonas Schürmann <[email protected]>
  • Loading branch information
Jonas Schürmann authored and Jonas Schürmann committed May 17, 2018
1 parent bf0ec24 commit b55e0f4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6,672 deletions.
Loading

0 comments on commit b55e0f4

Please sign in to comment.