Closed Ameeko closed 2 years ago
This is not directly related to GrapesJS, this all depends on how the pasted content is stored from the external application and which tags are used for the new lines.
The text was a plain text, it had no tags. I tested with \n and \r\n line breaks, it doesn't work well. Unnecessary tags appear in GrapesJS when inserting plain text with line breaks.
Can anyone help me with this?
@Ameeko & @artf I'm also having this issue. Has anyone found a fix for this?
GrapesJS version
What browser are you using?
Chrome v98
Reproducible demo link
https://grapesjs.com/demo.html
Describe the bug
I opened a notepad (Win11) I wrote this in the notepad: test [enter] test [enter] test [enter] I selected the entire text and copied it to the clipboard I created a "Text" element in the GrapesJS editor I copied the text from the clipboard into the "Text" element I clicked outside This will be the result
If I enter this text into a "Text" element manually test [enter] test [enter] test [enter] and click outside, the text will be placed in 1 "Text" element. This is good. Unfortunately, people usually paste the text.
Code of Conduct