Lines and paragraphs are not same things in typography. Usually, there's a spacing between paragraphs, which less than the height of a full line, unless there are different elements involved like figures, headings,... And, sometimes, there's a need to use multiple simple line-breaks for the same paragraph.
Steps for Reproduction
class="ql-editor" component.Expected behavior:
There can be produced output allowing multiple line-breaks within a single paragraph, like:
<p>Some text paragraph</p>
<p>
Another text paragraph:<br/>
with<br/>
multiple<br/>
lines
<p>
<p>Another paragraph</p>
Actual behavior:
Can't produce output above.
Suggested behaviour
Simply: when an enter is pressed once, then a line-break is produced. When enter is pressed twice, then a new paragraph is produced.
Technically:
Not covered:
Platforms:
$ uname -a
Linux miroslav-laptop 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
$ google-chrome --version
Google Chrome 78.0.3904.108
Version:
The published one, when this issue is written.
To support this issue, here is the HTML spec relating to semantic markup: https://www.w3.org/TR/html52/textlevel-semantics.html#elementdef-br
+1
This is one of the most basic features that every text editor must have. Has no one written a module for that?
+1
This is an essential feature for digital humanities work — both for editing academic writing and for editing transcriptions of primary texts.
(Though whether this should be done automatically — or with a shift enter — is very much open to debate. Following most word processors, it should be the latter.)
I'd really like to see shift+enter being added to Quill. It seems the maintainers don't see this as an issue though, they have locked/closed threads discussing this feature before. There are some experimental implementation made by people, but they don't work as expected. Too bad this is not being taken seriously. I really love this editor and dislike the fact that a common thing such as this is deterring people from using it. Me included.
Most helpful comment
(Though whether this should be done automatically — or with a shift enter — is very much open to debate. Following most word processors, it should be the latter.)