feat(emoji-picker): update emoji library and add ru emodji search - #92
Merged
Merged
Conversation
…ges, add RU search Emoji rendered via the OS/browser font look different across platforms. Swaps the picker's data source and rendering to @astronautlabs/emoji's Twemoji SVG set so emoji look identical everywhere, and adds Russian names/keywords (via emojibase-data) so search works in Russian, not just English. - scripts/build-emojis.ts regenerates emojis.json from @astronautlabs/emoji, enforcing that every character already in the committed dataset stays selectable (protects recentEmojis and any emoji already placed elsewhere from a data-source change), and dedupes legacy/library variants of the same glyph (e.g. FE0F-qualified keycaps) by resolved asset id rather than exact string match. - New Emoji component + getEmojiIconId compute the Twemoji asset id from a raw character (not from picker data), so it works for any valid emoji, with a graceful text fallback if an image fails to load. - emojiBaseUrl is threaded through the public API (EmojiPicker -> EmojiPickerPopup -> EmojiView -> EmojiCategory) so consumers can point at their own asset host instead of the default /emoji/svg. - Fixes EmojiPickerPopup width jumping when switching the emoji/sticker tabs, and StickerView layout stretching around non-square stickers. - Removes the unused unicodeToNative helper. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
Author
unknownproperty
approved these changes
Aug 29, 2026
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

fix 178
Было: ручной emojis.json
Стало: автоматическая генерация через scripts/build-emojis.ts (запуск: npm run codegen) из библиотеки @astronautlabs/emoji — на выходе 8 категорий.
Генерация
Сравнивает новый набор с закоммиченной версией (не с файлом на диске) — чтобы баг одного прогона не переходил на следующие
Старые эмодзи не удаляются — если символ пропадает, скрипт падает с ошибкой (защита recentEmojis и уже расставленных на доске)
Если эмодзи отличаются только вариационным селектором (FE0F) — оставляется старый вариант, сопоставление по getEmojiIconId
Русские названия и теги подтягиваются из emojibase-data — если пакет недоступен, скрипт падает (нет тихой подмены на английский)
Рендеринг (раньше текст → теперь картинки)
с SVG из Twemoji через компонент Emoji
Было: текст через CSS font-family — разный вид на разных ОС
Стало:
Если картинка не загружена — плавный откат на текстовый рендер (тот же символ)
Состояние ошибки сбрасывается при смене char (не залипает)
SVG-файлы должен раздавать потребитель (путь: emojiBaseUrl, по умолчанию /emoji/svg)
Поиск
Фильтрация одновременно по трём полям: name, nameRus, keywordsRus — работает и по-английски, и по-русски, и по синонимам.
Эксплуатационные моменты
Обязательно наличие SVG-ассетов по пути emojiBaseUrl — иначе текстовый фолбэк (работает, но без картинок)
Тултип показывает nameRus, остальной текст в пикере — на русском (без i18n)
Ширина попапа и размеры тайлов фиксированы, чтобы интерфейс не дёргался