econia-labs / emojicoin-dot-fun

https://emojicoin-dot-fun.vercel.app
Other
6 stars 14 forks source link

[ECO-2309] Add chat emoji data to the SDK, ensure frontend can only input valid chat message emojis #303

Closed xbtmatt closed 1 month ago

xbtmatt commented 1 month ago

Description

The frontend right now uses the emoji regex/emoji picker library data for chat emojis. This isn't totally accurate, because the chat emojis for the emojicoin_dot_fun.move contract is actually a subset of all chat emojis.

This means currently, there's a few emojis that would cause the frontend to throw an error when a user tries to submit a chat message with them.

In order to more accurately match the data on-chain, I've added the chat emoji data to the typescript data, akin to the symbol-emojis.json data.

This also adds custom types like ChatEmoji that gives us IDE suggestions, as well as SymbolEmojiName and ChatEmojiName types.

Testing

Checklist

vercel[bot] commented 1 month ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
emojicoin-dot-fun ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 16, 2024 8:53pm
emojicoin-dot-fun-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 16, 2024 8:53pm