missive / emoji-mart

🏪 One component to pick them all
https://missiveapp.com/open/emoji-mart
MIT License
8.59k stars 826 forks source link

Can we export an object such that it gives me emoji unicode to all the emojis map? #275

Closed daiict218 closed 5 years ago

daiict218 commented 5 years ago

Hi, I'm using this module in my project. I have a text area and whenever I'm adding an emoji from Emoji Picker, I'm putting the emoji unicode so that browser can determine and show that appropriately so rendering the emoji, I need to send an emoji object to the EmojiIcon component which is been exported from this repo. So, if I'll have a map of emoji utf-8 codes to it's object, that'd be really great. Now, I'm having issues with converting emojis to unicode and some emojis can be of multiple code points

nolanlawson commented 5 years ago

Does importing the JSON file directly from https://github.com/missive/emoji-mart/tree/master/data solve this issue for you?

daiict218 commented 5 years ago

Actually I wanted a behaviour something like emoji-dictionary but instead name, I wanted the unified value from the data but I guess this is not possible because few emojis are made up of multiple code points (hence multiple unified values). Should we implement some function like emoji-dictionary in emoji-mart as well where I can get the name of the emoji from the utf-8 values?

nolanlawson commented 5 years ago

What do you mean by "unified value from the data"? Does this data not exist in the JSON files?

daiict218 commented 5 years ago

This is resolved after the function getEmojiDataFromNative is added to the library

daiict218 commented 5 years ago

We can close this issue