-
-
Notifications
You must be signed in to change notification settings - Fork 2
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
emoji handling #2
Comments
node-emoji can convert between actual emojis and emoijlib has Male Singer but no functions for autoconverting :codes:. twemoji looked promising but converts emoji characters to Anyway, if we find a good library this might be a useful thing to put into cabal-client |
@cinnamon-bun does node-emoji work with EDIT: yes it does |
I had some more thoughts to add here. I worked on (but abandoned and deleted) a branch on cabal-clone that would take unicode or I couldn't find a library that satisfied me so I wrote my own parsing function. Largely because none of them let me provide my own map of characters for codes or vice-versa. One thing I stuggled with was finding emoji characters. A big "Eureka" was when I realized I threw together a jsperf notebook here: https://jsperf.com/emoji-parsing/1 . Looks like converting is comparable performance-wise in either direction. I did (just now) find https://github.com/joypixels/emoji-toolkit , which has a nice shortNameToUnicode and ToShort method. Does not appear to support custom emoji. |
I put neato-emoji-converter together yesterday/today to cover most emoji conversion use-cases, while being faster than most. It can borrow The emoji set and replacer functions are totally configurable, so it can be used for basically any emoji strategy I can think of. It doesn't have any sort of picker integration. |
@fenwick67 ohhhhhh wha this looks really cool, it could help make cabal-cli handle emoji way better than the hack i implemented! would you mind adding a license to https://github.com/fenwick67/neato-emoji-converter? |
LICENSE added 👍 |
Hey y'all, I made a PR into cabal-cli to replace unicode with shortcodes cabal-club/cabal-cli#132 . (And it was merged) |
@fenwick67 solved this super nicely! |
Would we like clients to handle emojis as actual emoji characters or as :emoji_codes:?
Clients can convert to emoji characters, convert to :emoji_codes:, or leave it alone.
This could happen when posting a message and/or when displaying a message.
Complexities:
Composite emojis are only supported in some places. Android supports them but not always MacOS Desktop.
The text was updated successfully, but these errors were encountered: