mirror of
https://gitlab.com/bashrc2/epicyon
synced 2026-11-05 04:02:21 +00:00
Show message if no emoji are found
This commit is contained in:
1 parent
7a88dea618
commit
524b7dec4c
1 file changed
+6
@@ -82,6 +82,7 @@ def htmlSearchEmoji(cssCache: {}, translate: {},
|
||||
customEmojiJson = loadJson(customEmojiLookupFilename)
|
||||
if customEmojiJson:
|
||||
emojiJson = dict(emojiJson, **customEmojiJson)
|
||||
|
||||
results = {}
|
||||
for emojiName, filename in emojiJson.items():
|
||||
if searchStr in emojiName:
|
||||
@@ -89,6 +90,11 @@ def htmlSearchEmoji(cssCache: {}, translate: {},
|
||||
for emojiName, filename in emojiJson.items():
|
||||
if emojiName in searchStr:
|
||||
results[emojiName] = filename + '.png'
|
||||
|
||||
if not results:
|
||||
emojiForm += '<center><h5>' + \
|
||||
translate['No results'] + '</h5></center>'
|
||||
|
||||
headingShown = False
|
||||
emojiForm += '<center>'
|
||||
msgStr1 = translate['Copy the text then paste it into your post']
|
||||
|
||||
Reference in new issue
Block a user