froala / wysiwyg-editor

The next generation Javascript WYSIWYG HTML Editor.
https://www.froala.com/wysiwyg-editor
Other
5.3k stars 674 forks source link

Pasting Content With Unicode Spacing Breaks In Safari U+202F #3988

Closed JohnTendik closed 2 weeks ago

JohnTendik commented 4 years ago

Safari does not support unicode half-space characters U+202F so when pasting content with half space characters, the spacing between words becomes 0 making it hard to read content

Screen Shot 2020-07-20 at 10 32 56 AM
Expected behavior.

The pasting should clean up unicode characters that are not supported in Browsers

Actual behavior.

The content is pasted with hidden unicode characters which looks like there are spaces missing in the content. Setting pastePlain: true does not help unfortunately.

Steps to reproduce the problem.

1) Paste content with U+202F characters (see fiddle for example content) 2) View content in Safari browser

JSFIDDLE: https://jsfiddle.net/Lkty6h8b/ View in Safari

Also here is a nice tool to find out the special characters in the content https://www.soscisurvey.de/tools/view-chars.php

Screen Shot 2020-07-20 at 10 36 42 AM
Editor version.

3.1.0 (latest)

OS.

Mac OS Mojave v10.14.6

Browser.

Safari v13.1.1 (14609.2.9.1.3)

ilyaskarim commented 2 weeks ago

We’re closing this issue due to inactivity. If you’re still experiencing this problem on the latest version of our editor, please feel free to reopen the issue and let us know. You can find details on the latest updates here: Froala Editor Changelog.