MioVisman / FluxBB_by_Visman

My modification of FluxBB
GNU General Public License v2.0
78 stars 13 forks source link

Emoji support #18

Closed vprelovac closed 2 years ago

vprelovac commented 3 years ago

It would be great if you could include a way to automatically convert something like :smile: to 😄 or :wave: to 👋

The way github does it (real time) would be ideal but just converting it backend would be great too.

MioVisman commented 3 years ago

You can customize your smilies in the admin panel: smiliesplug

vprelovac commented 3 years ago

These are smilies, requiring a picture each. Emojis are unicode characters already existing and do not require any pictures. But, I understand if you don't have time for it you've done enough already.

MioVisman commented 3 years ago
  1. Where can I see the entire emoji conversion list? There is no such list in unicode, there are just symbols.
  2. What about the coincidence of smile codes (administrators in their forums could make changes to smiles) and substrings for conversion to emojis?
vprelovac commented 3 years ago

I saw this one for PHP https://github.com/aaronpk/emoji-detector-php/blob/main/src/map.json

I think it is best to have an option 'Use emojis instead of smilies' and map the most common smilies to emojis. Emojis will give the users so much more power to express.

MioVisman commented 3 years ago

When I have free time, I'll try it.

P.S. Can browsers or their extensions put emoji characters in user-entered text? I didn't have that need and I don't use smartphones, so I don't know. The forum base is ready to accept the emoji characters themselves, for this changes were made to the engine code: https://github.com/MioVisman/FluxBB_by_Visman/releases/tag/1.5.10.79 (item 3).

vprelovac commented 3 years ago

I am already using emojis in fluxbb (I downloaded your project from github yesterday so whats in there works)

Screen 2021-09-13 at 09 33 37@2x

To do that I was manually going to this site and copying the emoji character https://emojipedia.org/smiling-face-with-smiling-eyes/

Since that is a lot of work the best would be to have autocomplete like github has when you type in : (that is pretty much the standard way of using them nowadays)

Screen 2021-09-13 at 09 37 23@2x

MioVisman commented 2 years ago

How to use skin-tone modifiers? example:

    "1F467": "girl",
    "1F467-1F3FB": "girl",
    "1F467-1F3FC": "girl",
    "1F467-1F3FD": "girl",
    "1F467-1F3FE": "girl",
    "1F467-1F3FF": "girl",

and

    "1F469-200D-2764-FE0F-200D-1F48B-200D-1F468": "woman-kiss-man",
    "1F469-1F3FB-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FB": "woman-kiss-man",
    "1F469-1F3FB-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FC": "woman-kiss-man",
    "1F469-1F3FB-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FD": "woman-kiss-man",
    "1F469-1F3FB-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FE": "woman-kiss-man",
    "1F469-1F3FB-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FF": "woman-kiss-man",
    "1F469-1F3FC-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FB": "woman-kiss-man",
    "1F469-1F3FC-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FC": "woman-kiss-man",
    "1F469-1F3FC-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FD": "woman-kiss-man",
    "1F469-1F3FC-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FE": "woman-kiss-man",
    "1F469-1F3FC-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FF": "woman-kiss-man",
    "1F469-1F3FD-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FB": "woman-kiss-man",
    "1F469-1F3FD-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FC": "woman-kiss-man",
    "1F469-1F3FD-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FD": "woman-kiss-man",
    "1F469-1F3FD-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FE": "woman-kiss-man",
    "1F469-1F3FD-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FF": "woman-kiss-man",
    "1F469-1F3FE-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FB": "woman-kiss-man",
    "1F469-1F3FE-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FC": "woman-kiss-man",
    "1F469-1F3FE-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FD": "woman-kiss-man",
    "1F469-1F3FE-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FE": "woman-kiss-man",
    "1F469-1F3FE-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FF": "woman-kiss-man",
    "1F469-1F3FF-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FB": "woman-kiss-man",
    "1F469-1F3FF-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FC": "woman-kiss-man",
    "1F469-1F3FF-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FD": "woman-kiss-man",
    "1F469-1F3FF-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FE": "woman-kiss-man",
    "1F469-1F3FF-200D-2764-FE0F-200D-1F48B-200D-1F468-1F3FF": "woman-kiss-man",

These emojis look different due to skin-tone, but have the same shortcode. It's some nonsense. I did not find information about changing the shortcode in this case. And if in the first case I can add skin-tone to the end of shortcode, then in the second case it is not quite clear where to insert skin-tone.

vprelovac commented 2 years ago

I do not know, I would assume in v1 you ignore it.

MioVisman commented 2 years ago

for test https://github.com/MioVisman/FluxBB_by_Visman/tree/emoji

Emoji have a text size, are poorly read. On github, emoji are shown in pictures, not text. Now emoji shotcodes are processed anyway and before smilies are processed.

vprelovac commented 2 years ago

Thanks for taking this seriously!

Is there a list of files to copy over my existing installation?

MioVisman commented 2 years ago

https://github.com/MioVisman/FluxBB_by_Visman/releases/tag/emoji_test

You can unpack the archive on top of your installation with file replacement. Contains all changes from the master branch and changes for emoji https://github.com/MioVisman/FluxBB_by_Visman/network

First, remember to make a backup of files and database.

vprelovac commented 2 years ago

I confirm it works 🥳 🎉

Screen 2021-09-20 at 12 10 41@2x

Small ask: make it work in post titles too

Big ask: not sure what are these icons called, but it would be great if we could use an emoji in forum settings to define them

Screen 2021-09-20 at 12 11 09@2x

This should allow for whole another level of forum personalization. Great job!

MioVisman commented 2 years ago

Big ask: not sure what are these icons called, but it would be great if we could use an emoji in forum settings to define them

These icons are configured through a style file. You can put emoji there through style too.

Small ask: make it work in post titles too

I can do this, but it still doesn't reach me why use short codes if you can immediately insert emoji into both the message text and the name of the topic? In this case, there will be no additional load on the server. There are js plugins on github for selecting and inserting emoji, I think.

vprelovac commented 2 years ago

These icons are configured through a style file. You can put emoji there through style too.

Not sure if we are on the same page. I would like every forum to have a different emoji icon.

but it still doesn't reach me why use short codes if you can immediately insert emoji into both the message text and the name of the topic?

I think what you are asking me is - why we need this when you copy emoji from a site like emojipedia? Because that is a long process and I can recall most used emojis shortcodes easily. :wave: is super simple to remember. And you can try random things like :tree: and it usually works.

If you had an interface that popups up when you type: (like github) that would be even better.

MioVisman commented 2 years ago

https://github.com/MioVisman/FluxBB_by_Visman/releases/tag/emoji_test2

The scripts were tested only in Firefox and IE11. Most likely there will be errors with the positioning of the list of hints in other browsers. I haven't tested it on smartphones either.

MioVisman commented 2 years ago

Emoji moved to the master branch of the project.