`white-space` CSS-Eigenschaft von Clipboard-Daten wird beim Einfügen in Rich-Text-Editor nicht beachtet

This should be fixed by FIX: [rich editor] convert newlines to hard breaks when parsed from HTML by renato · Pull Request #35518 · discourse/discourse · GitHub (not merged yet, it’s waiting a code review).

My first take was to convert it to a code block, but I think that would be too eager and cause some false positives. Instead, we just respect line breaks converting them to hard breaks within the context the HTML was pasted. (Thanks to Marijn’s improvement to prosemirror-model: When preserving whitespace, replace newlines with line break replacem… · ProseMirror/prosemirror-model@79e9f2b · GitHub)

With the recent improvements to the code toolbar button, users should be able to select this pasted section with the hard breaks and convert it to a code block, and the newlines should be carried over.

2 „Gefällt mir“