From aa652aac8a88f6256834db63435a670a2bca797b Mon Sep 17 00:00:00 2001 From: Xeltica <7106976+Xeltica@users.noreply.github.com> Date: Sun, 21 Jun 2020 22:34:28 +0900 Subject: タップ不可能なリアクションを押してもパーティクルが出るバグを修正 (#6472) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * resolve #6453 * リアクションビューワーのトグル可能判定にログインしているかどうかも反映 --- src/client/components/reactions-viewer.reaction.vue | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/client/components') diff --git a/src/client/components/reactions-viewer.reaction.vue b/src/client/components/reactions-viewer.reaction.vue index 6b72f2e105..639a1603ca 100644 --- a/src/client/components/reactions-viewer.reaction.vue +++ b/src/client/components/reactions-viewer.reaction.vue @@ -9,9 +9,9 @@ @mouseleave="onMouseleave" @touchend="onMouseleave" ref="reaction" - v-particle + v-particle="canToggle" > - + {{ count }} @@ -55,21 +55,20 @@ export default Vue.extend({ return this.$store.getters.isSignedIn && this.$store.state.i.id === this.note.userId; }, canToggle(): boolean { - return !this.reaction.match(/@\w/); + return !this.reaction.match(/@\w/) && !this.isMe && this.$store.getters.isSignedIn; }, }, - mounted() { - if (!this.isInitial) this.anime(); - }, watch: { count(newCount, oldCount) { if (oldCount < newCount) this.anime(); if (this.details != null) this.openDetails(); }, }, + mounted() { + if (!this.isInitial) this.anime(); + }, methods: { toggleReaction() { - if (this.isMe) return; if (!this.canToggle) return; const oldReaction = this.note.myReaction; -- cgit v1.2.3-freya