Skip to content
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

reverse emoji translation (reaction and/or text) #5

Open
martinetd opened this issue Jul 30, 2023 · 2 comments
Open

reverse emoji translation (reaction and/or text) #5

martinetd opened this issue Jul 30, 2023 · 2 comments

Comments

@martinetd
Copy link
Owner

It's be nice to allow sending some common reactions: suggested syntax /regex/ :emoji:

Sounds OK to me if it only works on LRU of recent messages (e.g. since last restart, we wouldn't serialize all messages to disk)

emojis in reaction (ruma_common::events::reaction::ReactionEventContent) seems to just have the glyph in relates_to.key, but it's not practical to input utf-8 emojis in a terminal so having :emoji: aliases would probably be useful.
If we do that, might as well do the translation in messages too

@snan
Copy link

snan commented Sep 19, 2023

I use unicode emojis as is on irc from time to time, maybe I should stop doing that if it's not widely supported yet. 🤷🏻‍♀️
For example, ConnectBot on Android didn't support them last I used it (which was in 2021).

@martinetd
Copy link
Owner Author

I'm not sure I understand your comment: sending unicode emojis from your IRC client is fine and they'll get sent to matrix as is; as long as folks you talk to have fonts that can display them in their web browser there'll be no problem (and this is usually fine)
This isn't always the case with terminals as you pointed out with connectbot -- that's #4 -- we already do lookup emojis from reactions and display both the emoji and its name (so you'll see something like " 🤣 (rolling on the floor laughing)"), but some emojis are missing so it could be improved, and we might also want to do the same conversions in text itself but I'm a bit reluctant to modify text people wrote arbitrarily so this probably won't be done for a while longer.

This issue is the other way around: sending reactions e.g. give a specific message a thumbs up; reactions are also just utf8 characters so if you can input utf8 emojis directly that'll work just as well, but I can't so I suggested matching :foo:, looking it up in some table (currently using the emoji crate which has a lookup_by_name helper) and using that instead as the matrix protocol doesn't handle :foo: itself, it's the sender's job to make that an utf8 glyph.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants