Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Less-than-carets are removed when event is triggered #47

Open
oyvinev opened this issue Dec 16, 2016 · 1 comment
Open

Less-than-carets are removed when event is triggered #47

oyvinev opened this issue Dec 16, 2016 · 1 comment

Comments

@oyvinev
Copy link

oyvinev commented Dec 16, 2016

The less-than caret followed by text is removed when you e.g. set some text to bold in wysiwyg mode.

E.g: in the demo, write "<e", and change some other text to bold.

Is there any possibility to preserve these when typed in?

LoveAndCoding added a commit to BlinkUX/barkmark that referenced this issue Jun 29, 2017
…ue with chunking selection that doesn't quite split things correctly because `window.getSelection()` is returning the range values from the unescaped text. Need to manage the difference somewhere.
LoveAndCoding added a commit to BlinkUX/barkmark that referenced this issue Jun 29, 2017
Converting back and forth to a native `Selection` object required accommodating the HTML special characters in the offsets. The string the browser returns from `textContent` is not escaped which is a problem when trying to work with a selection in a block with a special character around.

This should finish out the fix for bevacqua#47
@LoveAndCoding
Copy link
Contributor

This issue comes from HTML special characters not being escaped properly in the WYSIWYG editor. Getting the textContent or innerText from the browser will give the unescaped version of the text. I've fixed the issue over at BlinkUX/woofmark and I'll try and see if I can't clean up a PR to merge upstream.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants