code-input
code-input copied to clipboard
With highlight.js, SpecialChars will disappear after creation (perhaps to do with SelectTokenCallbacks)
Using these special characters (all ASCII chars from 0000 to 007F), on Firefox 140:
!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~
Out of the full-plugin demos here, only with highlight.js and not with Prism.js, selecting text in the <textarea> or pressing arrow keys (but not adding/deleting text which changes the value and causes a rehighlight) causes:
- the special characters to disappear and stop taking up space in the highlighted element.
- This is a vague description and the characters disappear at some other times, too, but with little pattern; sometimes some but not all of the characters disappear.
- This may be to do with SelectTokenCallbacks, since inspecting the element shows
code-input_select-token-callbacks_temporary-spanelements in the highlighted element.
I cannot reproduce it on the same browser with only the SpecialChars plugin.
This is part of #106.