diff options
| author | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-03-13 14:04:15 +0000 |
|---|---|---|
| committer | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-03-13 14:04:15 +0000 |
| commit | 51b14cc61578c6aee80fbf63dce2dbb7503914bb (patch) | |
| tree | 5c24fe9969c8a871870a325d3f97c3ed99f6ac80 /src/components/status | |
| parent | 80bd6433aa26d1b8404b0ca7105d9999aa22495b (diff) | |
| parent | 450145dd6b0c91e80b957d7c39dbf6b809b056be (diff) | |
Merge branch 'eientei' into 'develop'
Mute bot posts filtering option
See merge request pleroma/pleroma-fe!1440
Diffstat (limited to 'src/components/status')
| -rw-r--r-- | src/components/status/status.js | 16 | ||||
| -rw-r--r-- | src/components/status/status.vue | 7 |
2 files changed, 21 insertions, 2 deletions
diff --git a/src/components/status/status.js b/src/components/status/status.js index d8f94926..2c3e079f 100644 --- a/src/components/status/status.js +++ b/src/components/status/status.js @@ -166,6 +166,12 @@ const Status = { muteWordHits () { return muteWordHits(this.status, this.muteWords) }, + botStatus () { + return this.status.user.bot + }, + botIndicator () { + return this.botStatus && !this.hideBotIndication + }, mentionsLine () { if (!this.headTailLinks) return [] const writtenSet = new Set(this.headTailLinks.writtenMentions.map(_ => _.url)) @@ -191,7 +197,9 @@ const Status = { // Thread is muted status.thread_muted || // Wordfiltered - this.muteWordHits.length > 0 + this.muteWordHits.length > 0 || + // bot status + (this.muteBotStatuses && this.botStatus && !this.compact) return !this.unmuted && !this.shouldNotMute && reasonsToMute }, userIsMuted () { @@ -293,6 +301,12 @@ const Status = { hidePostStats () { return this.mergedConfig.hidePostStats }, + muteBotStatuses () { + return this.mergedConfig.muteBotStatuses + }, + hideBotIndication () { + return this.mergedConfig.hideBotIndication + }, currentUser () { return this.$store.state.users.currentUser }, diff --git a/src/components/status/status.vue b/src/components/status/status.vue index 3bb29db6..8f51a778 100644 --- a/src/components/status/status.vue +++ b/src/components/status/status.vue @@ -77,6 +77,7 @@ <UserAvatar v-if="retweet" class="left-side repeater-avatar" + :bot="botIndicator" :better-shadow="betterShadow" :user="statusoid.user" /> @@ -124,6 +125,7 @@ @click.stop.prevent.capture.native="toggleUserExpanded" > <UserAvatar + :bot="botIndicator" :compact="compact" :better-shadow="betterShadow" :user="status.user" @@ -407,7 +409,10 @@ class="gravestone" > <div class="left-side"> - <UserAvatar :compact="compact" /> + <UserAvatar + :compact="compact" + :bot="botIndicator" + /> </div> <div class="right-side"> <div class="deleted-text"> |
