This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/plugins/chat/assets/javascripts/discourse/components/chat-message-reaction.hbs
2022-12-28 13:11:12 +00:00

29 lines
668 B
Handlebars

{{#if (and this.reaction this.emojiUrl)}}
<button
id={{this.componentId}}
type="button"
{{on "click" (action "handleClick")}}
tabindex="0"
class={{concat-class
this.class
"chat-message-reaction"
(if this.reaction.reacted "reacted")
(if this.reaction.count "show")
}}
data-emoji-name={{this.reaction.emoji}}
title={{this.emojiString}}
>
<img
loading="lazy"
class="emoji"
width="20"
height="20"
alt={{this.emojiString}}
src={{this.emojiUrl}}
/>
{{#if this.reaction.count}}
<span class="count">{{this.reaction.count}}</span>
{{/if}}
</button>
{{/if}}