Empty paragraphs are dropped on save – edit mode and view mode diverge
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 70/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- javascript, markdown
調査の方向性
The issue is in the markdown serialization/parsing logic of the Text app, likely in the tiptap/prosemirror integration. Look for the code that converts the editor's document model to markdown and back. The solution involves modifying the serializer to represent empty paragraphs with and ensuring the parser correctly interprets them. Check existing tests for markdown handling to understand the current behavior and add a test for empty paragraph preservation.
索引モデルが issue の本文から書いたものです。
説明
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
- #902 (same behaviour, closed as duplicate of #593)
- #593 (closed as not planned, but covers preserving external formatting,
not empty paragraphs created in Text itself)
Server details
- Collectives: 4.6.1
- Text: 8.0.0
- Nextcloud: 34.0.4
- 主要言語
- JavaScript
- スター
- 665
- フォーク
- 133
- 平均マージ
- 1日 17時間
- マージ済み PR(30日)
- 172
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
nextcloud/text のほかの issue
-
0. Needs triage bug
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
nextcloud/text#9482 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
0. Needs triage bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
folder description not shows when using folder tree to navigate再び着手できるかも このイシューのプルリクエストはマージされずにクローズされました。 オープンbug feature: folder description
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
1. to develop design call discuss discussion ux
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
bug
難易度 3/5 1〜2日 初心者へのやさしさ 58/100
nextcloud/text#9334 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
mongoosejs/mquery#142 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 65/100
メンテナーはふだん 1 日以内に返信
-
Add toro4n to the data modeling tools対応中かも @henriklantzhedstrom-prog が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
neo4j/docs-getting-started#546 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
メンテナーはふだん 25 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
libnativeapi/nativeapi#21 ·