Skip to content

Only add a newline in Markdown Editor if the current line is not empty

What does this MR do?

Stops inserting a newline(\n) in the Markdown Editor for Task List (* []), Bullet List (* ), Numbered List (1. ) and Quotes (> ) if the current line (in front of the caret) is empty, only whitespace characters are allowed.

Are there points in the code the reviewer needs to double check?

The original issue #27978 (closed) only mentioned the Task list (* []), I added it for all similar types. Hope its fine.

Why was this MR needed?

See #27978 (closed)

Screenshots (if relevant)

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

Closes #27978 (closed)

Merge request reports