fix of frequently used emojis

This commit is contained in:
Valery Sizov 2015-12-24 15:44:43 +02:00
parent 5ed1256492
commit a55b653d93

View file

@ -137,9 +137,9 @@ class @AwardsHandler
for emoji in frequently_used_emojis
do (emoji) ->
$(".emoji-menu-content [data-emoji='" + emoji + "']").closest("li").clone().appendTo(ul)
$(".emoji-menu-content [data-emoji='#{emoji}']").closest("li").clone().appendTo(ul)
$(".emoji-menu-content").prepend(ul).prepend($("<h4>").text("Frequently used"))
$("input.emoji-search").after(ul).after($("<h5>").text("Frequently used"))
setupSearch: ->
$("input.emoji-search").keyup (ev) =>
@ -149,7 +149,7 @@ class @AwardsHandler
$("ul.emoji-search,h5.emoji-search").remove()
if term
# Generate search result block
# Generate a search result block
h5 = $("<h5>").text("Search results").addClass("emoji-search")
found_emojis = @searchEmojis(term).show()
ul = $("<ul>").addClass("emoji-search").append(found_emojis)