diff --git a/src/components/emoji_reactions/emoji_reactions.js b/src/components/emoji_reactions/emoji_reactions.js
index bb11b840..549b9517 100644
--- a/src/components/emoji_reactions/emoji_reactions.js
+++ b/src/components/emoji_reactions/emoji_reactions.js
@@ -27,7 +27,11 @@ const EmojiReactions = {
},
accountsForEmoji () {
return this.status.emoji_reactions.reduce((acc, reaction) => {
- acc[reaction.name] = reaction.accounts || []
+ if (reaction.url) {
+ acc[reaction.url] = reaction.accounts || []
+ } else {
+ acc[reaction.name] = reaction.accounts || []
+ }
return acc
}, {})
},
@@ -42,6 +46,14 @@ const EmojiReactions = {
reactedWith (emoji) {
return this.status.emoji_reactions.find(r => r.name === emoji).me
},
+ isLocalReaction (emojiUrl) {
+ if (!emojiUrl) return true
+ const reacted = this.accountsForEmoji[emojiUrl]
+ if (reacted.length === 0) {
+ return true
+ }
+ return reacted[0].is_local
+ },
fetchEmojiReactionsByIfMissing () {
const hasNoAccounts = this.status.emoji_reactions.find(r => !r.accounts)
if (hasNoAccounts) {
diff --git a/src/components/emoji_reactions/emoji_reactions.vue b/src/components/emoji_reactions/emoji_reactions.vue
index 57e00817..2d7cfb54 100644
--- a/src/components/emoji_reactions/emoji_reactions.vue
+++ b/src/components/emoji_reactions/emoji_reactions.vue
@@ -2,12 +2,13 @@