codex-team/editor.js

An empty block is added in readOnly mode on top

Open

#2.613 geöffnet am 12. Feb. 2024

Auf GitHub ansehen
 (3 Kommentare) (6 Reaktionen) (0 zugewiesene Personen)TypeScript (26.602 Stars) (1.985 Forks)batch import
almost donebuggood first issue

Beschreibung

After the update to 2.29.0 in readonly mode there is a empty block added with an invisible (opacity: 0) placeholder text. The empty line is breaking the layout.

I temporarily fixed it with CSS:

.ce-paragraph[data-placeholder][contenteditable="false"]:empty {
  display: none;
}

Expected behavior: No additional line on top should be rendered, like in v2.28.0 in readOnly mode.

Screenshots: image

Device, Browser, OS: Macbook, Chrome, MacOS

Editor.js version: 2.29.0

Contributor Guide