doc/development/fe_guide/emojis.md
GitLab supports native Emojis through the tanuki_emoji gem.
Because our emoji support is implemented on both the backend and the frontend, we need to update support over three milestones.
tanuki_emoji gem as needed.Gemfile to use the latest tanuki_emoji gem.Gemfile to use the latest unicode-emoji that supports the version of Unicode you're upgrading to.EMOJI_VERSION in lib/gitlab/emoji.rbbundle exec rake tanuki_emoji:import - imports all fallback images into the versioned public/-/emojis directory.
Ensure you see new individual images copied into there.EMOJI_VERSION in app/assets/javascripts/emoji/index.jstanuki_emoji gem's Rake tasks to update aliases, digests, and sprites. Run in the following order:
bundle exec rake tanuki_emoji:aliases - updates fixtures/emojis/aliases.json
bundle exec rake tanuki_emoji:digests - updates public/-/emojis/VERSION/emojis.json and fixtures/emojis/digests.json
bundle exec rake tanuki_emoji:sprite - creates new sprite sheets
If new emoji are added, the sprite sheet may change size. To compensate for
such changes, first generate the app/assets/images/emoji.png sprite sheet with the above Rake
task, then check the dimensions of the new sprite sheet and update the
SPRITESHEET_WIDTH and SPRITESHEET_HEIGHT constants in lib/tasks/tanuki_emoji.rake accordingly.
Then re-run the task.
app/assets/images/emoji.pngapp/assets/images/[email protected]fixtures/emojis/intents.json with any new emoji that we would like to highlight as having positive or negative intent.
0.5.1. This is applied to all emoji automatically so there is no need to set this explicitly.1.5.app/assets/javascripts/emoji/support/is_emoji_unicode_supported.js
and app/assets/javascripts/emoji/support/unicode_support_map.jspackage.json. Used for
filtering emojis in app/assets/javascripts/emoji/index.js.app/assets/javascripts/emoji/constants.js
will need to be updatedRemove any old emoji versions from the public/-/emojis directory. This is not strictly necessary -
everything continues to work if you don't do this. However it's good to clean it up.