-
Notifications
You must be signed in to change notification settings - Fork 173
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
Avoid matching emoji followed by text variation selector (U+FE0E) #61
Comments
Any update on this? |
Good catch. We could add a negative lookahead for For the emoji variation selector case, I'd expect it to match just the emoji itself in case that's already an
The sequence U+2757 U+FE0F is a valid presentation sequence per TL;DR U+2757 is References to the relevant data files follow. https://unicode.org/Public/13.0.0/ucd/emoji/emoji-data.txt
https://unicode.org/Public/13.0.0/ucd/emoji/emoji-variation-sequences.txt
https://unicode.org/Public/emoji/13.1/emoji-sequences.txt
|
Yes, fix this please! This is appalling, I hate seeing my favourite characters (like U+263A) get Emoji presentation by default suddenly because more than half the software I see doesn’t implement variant selection properly. This is a bug with massive impact, and anything suffixed with U+FE0E must not be rendered as Emoji! |
First of all, thanks for this project! It's very useful.
It appears that the regex even matches codepoints that are followed by a text variant selector (FE0E).
The exclamation mark is an emoji with emoji-default representation. It should be matched both without a variant selector and with an emoji variant selector (FE0F).
However, it should not be matched when followed by a text variant selector (FE0E).
This will match the emoji 3 times, each time with length 1.
My expectation would be that the version without variant selector is matched with length 1, that the version with emoji variant selector is matched with length 2, and that the version with text variant selector is not matched at all.
The text was updated successfully, but these errors were encountered: