You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
I have read the documentation and cannot find an answer.
Describe the bug
You can't stack block quotes in RichText mode. It is possible for it to present them if you make them in Source mode first however so I am guessing it is the reading and conversion of the input in RichText mode that prevents it. Like If you use MarkdownShortcuts and adds a ">" at the start of a line followed by a space it starts a Block Quote but if you add it anywhere else it gets escaped.
Also, Source mode scrambles the input of ">" if you try to stack quotes. If you add this:
> This is a quote
>> A second quote
and changes to RichText it will show up correctly and if you save content externally with the onChange it will be correct, like this: > This is a quote\n>> A second quote. But if you go back to Source mode it will have converted it to > This is a quote> A second quote which, if applied by editing or saving, etc, will break it in RichText mode since it doesn't seems to know how to handle that.
I have seen other Markdown situations where > This is a quote> A second quote is valid but the RichText does not. Maybe something to do with Lexical, but I don't know.
Describe the bug
You can't stack block quotes in RichText mode. It is possible for it to present them if you make them in Source mode first however so I am guessing it is the reading and conversion of the input in RichText mode that prevents it. Like If you use MarkdownShortcuts and adds a ">" at the start of a line followed by a space it starts a Block Quote but if you add it anywhere else it gets escaped.
Also, Source mode scrambles the input of ">" if you try to stack quotes. If you add this:
and changes to RichText it will show up correctly and if you save content externally with the onChange it will be correct, like this:
> This is a quote\n>> A second quote
. But if you go back to Source mode it will have converted it to> This is a quote> A second quote
which, if applied by editing or saving, etc, will break it in RichText mode since it doesn't seems to know how to handle that.I have seen other Markdown situations where
> This is a quote> A second quote
is valid but the RichText does not. Maybe something to do with Lexical, but I don't know.Reproduction
Start from https://codesandbox.io/p/sandbox/mdx-editor-base-q8s7zr?file=/src/App.tsx to reproduce the problem so that I can observe the issue on my side and make sure that the fix reliably addresses it.
https://codesandbox.io/p/sandbox/mdx-editor-base-forked-cgdwkp
To Reproduce
Steps to reproduce the behavior:
> This is a quote> A second quote
.Expected behavior
That either RichText mode can handle
> This is a quote> A second quote
, or that Source mode does not convertinto
> This is a quote> A second quote
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: