summaryrefslogtreecommitdiff
path: root/src/client/app/mobile/views
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2018-11-11 21:17:51 +0900
committersyuilo <syuilotan@yahoo.co.jp>2018-11-11 21:17:51 +0900
commit71d42f64dc840e744e757cb5edae32276d83a7f4 (patch)
tree32ccae355b74a00cf47066a862961d8cb33fd642 /src/client/app/mobile/views
parent[Client] Fix i18n (diff)
downloadmisskey-71d42f64dc840e744e757cb5edae32276d83a7f4.tar.gz
misskey-71d42f64dc840e744e757cb5edae32276d83a7f4.tar.bz2
misskey-71d42f64dc840e744e757cb5edae32276d83a7f4.zip
[Client] Implement word mute
Closes #1739
Diffstat (limited to 'src/client/app/mobile/views')
-rw-r--r--src/client/app/mobile/views/components/note.vue2
-rw-r--r--src/client/app/mobile/views/components/notes.vue25
2 files changed, 4 insertions, 23 deletions
diff --git a/src/client/app/mobile/views/components/note.vue b/src/client/app/mobile/views/components/note.vue
index f6b7d39b83..d42efbf344 100644
--- a/src/client/app/mobile/views/components/note.vue
+++ b/src/client/app/mobile/views/components/note.vue
@@ -1,7 +1,7 @@
<template>
<div
class="note"
- v-show="appearNote.deletedAt == null"
+ v-show="appearNote.deletedAt == null && !hideThisNote"
:tabindex="appearNote.deletedAt == null ? '-1' : null"
:class="{ renote: isRenote, smart: $store.state.device.postStyle == 'smart' }"
v-hotkey="keymap"
diff --git a/src/client/app/mobile/views/components/notes.vue b/src/client/app/mobile/views/components/notes.vue
index e363d219a6..e239f8957d 100644
--- a/src/client/app/mobile/views/components/notes.vue
+++ b/src/client/app/mobile/views/components/notes.vue
@@ -35,6 +35,7 @@
<script lang="ts">
import Vue from 'vue';
import i18n from '../../../i18n';
+import shouldMuteNote from '../../../common/scripts/should-mute-note';
const displayLimit = 30;
@@ -118,28 +119,8 @@ export default Vue.extend({
},
prepend(note, silent = false) {
- //#region 弾く
- const isMyNote = note.userId == this.$store.state.i.id;
- const isPureRenote = note.renoteId != null && note.text == null && note.fileIds.length == 0 && note.poll == null;
-
- if (this.$store.state.settings.showMyRenotes === false) {
- if (isMyNote && isPureRenote) {
- return;
- }
- }
-
- if (this.$store.state.settings.showRenotedMyNotes === false) {
- if (isPureRenote && (note.renote.userId == this.$store.state.i.id)) {
- return;
- }
- }
-
- if (this.$store.state.settings.showLocalRenotes === false) {
- if (isPureRenote && (note.renote.user.host == null)) {
- return;
- }
- }
- //#endregion
+ // 弾く
+ if (shouldMuteNote(this.$store.state.i, this.$store.state.settings, note)) return;
// タブが非表示またはスクロール位置が最上部ではないならタイトルで通知
if (document.hidden || !this.isScrollTop()) {