patleeman / quill-markdown-shortcuts

Quill.js module that converts markdown to rich text formatting while typing.
https://patleeman.github.io/quill-markdown-shortcuts/
140 stars 49 forks source link

bold and italic on the same line breaks #6

Closed xdamman closed 6 years ago

xdamman commented 6 years ago

This looks like a very cool plugin. Running into a few annoying issues though that prevent me from using this on prod:

On the demo: https://patleeman.github.io/quill-markdown-shortcuts/

If you type

**bold** *italic*

It will turn the entire line into italic. Also, unable to get out of a fenced code block. Even after clicking on remove all styles.

See:

patleeman commented 6 years ago

Thanks for pointing these out, I will take a look at these corner cases

patleeman commented 6 years ago

Oh this is interesting, it doesn't happen if you hit enter but it does if you hit space.

patleeman commented 6 years ago

Looking at these discussions:

https://github.com/quilljs/quill/issues/1228

https://github.com/quilljs/quill/issues/954

It seems like Quill's removeFormat doesn't clear block formats without a selected range.