Describe the bug
When pressing Enter to create empty lines (empty paragraphs) in edit mode, they are shown correctly while editing. After leaving edit mode, all empty paragraphs are gone in the
rendered view. This makes it very hard to structure pages
in Collectives, e.g. meeting notes with visual spacing between dated sections.
To Reproduce
- Open a page in Collectives (or a .md file in Text)
- Write a paragraph, press Enter 2–3 times, write another paragraph
- Leave edit mode / reload the page
- The empty lines are gone
Expected behavior
Empty paragraphs survive the markdown round trip, so edit and view mode look the same.
Cause
An empty paragraph serializes to the same \n\n as a regular paragraph separator,
so it is lost when converting to markdown and parsing it again.
Possible solution
Serialize empty paragraphs as (and parse a paragraph containing only
back into an empty paragraph), similar to what tiptap does in
ueberdosis/tiptap#8356 for empty paragraphs next to lists.
Related
Server details
- Collectives: 4.6.1
- Text: 8.0.0
- Nextcloud: 34.0.4
Describe the bug
When pressing Enter to create empty lines (empty paragraphs) in edit mode, they are shown correctly while editing. After leaving edit mode, all empty paragraphs are gone in the
rendered view. This makes it very hard to structure pages
in Collectives, e.g. meeting notes with visual spacing between dated sections.
To Reproduce
Expected behavior
Empty paragraphs survive the markdown round trip, so edit and view mode look the same.
Cause
An empty paragraph serializes to the same
\n\nas a regular paragraph separator,so it is lost when converting to markdown and parsing it again.
Possible solution
Serialize empty paragraphs as
(and parse a paragraph containing only back into an empty paragraph), similar to what tiptap does inueberdosis/tiptap#8356 for empty paragraphs next to lists.
Related
not empty paragraphs created in Text itself)
Server details