From b15d882d77962b57d8716352b32e5822d2db555e Mon Sep 17 00:00:00 2001 From: Aleksandras Kostarevas Date: Fri, 15 Mar 2024 10:15:16 -0500 Subject: [PATCH] Improve emoji suggestions --- java/res/raw/gemoji.json | 1 - .../src/org/futo/inputmethod/latin/uix/actions/EmojiAction.kt | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/java/res/raw/gemoji.json b/java/res/raw/gemoji.json index 39f0b6677..76a519dc4 100644 --- a/java/res/raw/gemoji.json +++ b/java/res/raw/gemoji.json @@ -19409,7 +19409,6 @@ , "description": "A button (blood type)" , "category": "Symbols" , "aliases": [ - "a" ] , "tags": [ ] diff --git a/java/src/org/futo/inputmethod/latin/uix/actions/EmojiAction.kt b/java/src/org/futo/inputmethod/latin/uix/actions/EmojiAction.kt index 04d3a2621..94e1b5258 100644 --- a/java/src/org/futo/inputmethod/latin/uix/actions/EmojiAction.kt +++ b/java/src/org/futo/inputmethod/latin/uix/actions/EmojiAction.kt @@ -371,8 +371,8 @@ class PersistentEmojiState : PersistentActionState { emojiAliases = HashMap().apply { emojis.value!!.forEach { emoji -> - emoji.tags.forEach { put(it, emoji) } - emoji.aliases.forEach { put(it, emoji) } + emoji.tags.forEach { put(it.split("_").first(), emoji) } + emoji.aliases.forEach { put(it.split("_").first(), emoji) } } }