Edit composer doesn't show the original markdown and can mess up the formatting of lists
See original GitHub issueSorry if this is a duplicate, I couldn’t find any other issue about this.
For example, let’s consider this message:
Here's a list:
1. foo
- bar
- baz
Which renders like this on Riot:
When sent, if I click the edit button, this is what appears in the edit composer:
Here's a list:
1. foo
- bar
- baz
Which doesn’t have the same level of indentation, and also removed the blank line between the paragraph and the line (this latter point doesn’t affect rendering here, but I’ve seen cases where it did).
If I edit this message (e.g. adding an extra r to bar) without fixing the markdown by hand, the message renders like this:
Without having any knowledge of how the composer works under the hood, it seems weird to me that it doesn’t just show what’s in the body
of the original event.
I can’t see any error in the console when showing up the composer.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:9
- Comments:5 (5 by maintainers)
What @t3chguy said, but there are also https://github.com/vector-im/element-web/issues/10725 and https://github.com/vector-im/element-web/issues/20387 to track the more general idea of preserving Markdown verbatim
Oh right so it’s not closed by https://github.com/matrix-org/matrix-react-sdk/pull/7300 but as a duplicate of https://github.com/vector-im/element-web/issues/10725 (now that the list formatting part of the problem is fixed). Gotcha, thanks 😃