format
This commit is contained in:
parent
137cef81b6
commit
ebfd07628e
@ -67,7 +67,7 @@ export async function getWordHardMute(
|
||||
}
|
||||
|
||||
if (mutedWords.length > 0) {
|
||||
return checkWordMute(note) || checkWordMute(reply) || checkWordMute(renote)
|
||||
return checkWordMute(note) || checkWordMute(reply) || checkWordMute(renote);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
@ -262,18 +262,14 @@ const inChannel = inject("inChannel", null);
|
||||
let note = $ref(deepClone(props.note));
|
||||
|
||||
const softMuteReasonI18nSrc = (what?: string) => {
|
||||
if (what === "note")
|
||||
return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply")
|
||||
return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote")
|
||||
return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote")
|
||||
return i18n.ts.userSaysSomethingReasonQuote;
|
||||
if (what === "note") return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply") return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote") return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote") return i18n.ts.userSaysSomethingReasonQuote;
|
||||
|
||||
// I don't think here is reachable, but just in case
|
||||
return i18n.ts.userSaysSomething;
|
||||
}
|
||||
};
|
||||
|
||||
// plugin
|
||||
if (noteViewInterruptors.length > 0) {
|
||||
@ -305,7 +301,9 @@ let appearNote = $computed(() =>
|
||||
const isMyRenote = $i && $i.id === note.userId;
|
||||
const showContent = ref(false);
|
||||
const isDeleted = ref(false);
|
||||
const muted = ref(getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords));
|
||||
const muted = ref(
|
||||
getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords)
|
||||
);
|
||||
const translation = ref(null);
|
||||
const translating = ref(false);
|
||||
const enableEmojiReactions = defaultStore.state.enableEmojiReactions;
|
||||
|
@ -111,18 +111,14 @@ const inChannel = inject("inChannel", null);
|
||||
let note = $ref(deepClone(props.note));
|
||||
|
||||
const softMuteReasonI18nSrc = (what?: string) => {
|
||||
if (what === "note")
|
||||
return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply")
|
||||
return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote")
|
||||
return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote")
|
||||
return i18n.ts.userSaysSomethingReasonQuote;
|
||||
if (what === "note") return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply") return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote") return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote") return i18n.ts.userSaysSomethingReasonQuote;
|
||||
|
||||
// I don't think here is reachable, but just in case
|
||||
return i18n.ts.userSaysSomething;
|
||||
}
|
||||
};
|
||||
|
||||
const enableEmojiReactions = defaultStore.state.enableEmojiReactions;
|
||||
|
||||
@ -156,7 +152,9 @@ let appearNote = $computed(() =>
|
||||
const isMyRenote = $i && $i.id === note.userId;
|
||||
const showContent = ref(false);
|
||||
const isDeleted = ref(false);
|
||||
const muted = ref(getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords));
|
||||
const muted = ref(
|
||||
getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords)
|
||||
);
|
||||
const translation = ref(null);
|
||||
const translating = ref(false);
|
||||
const urls = appearNote.text
|
||||
|
@ -226,18 +226,14 @@ const props = withDefaults(
|
||||
let note = $ref(deepClone(props.note));
|
||||
|
||||
const softMuteReasonI18nSrc = (what?: string) => {
|
||||
if (what === "note")
|
||||
return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply")
|
||||
return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote")
|
||||
return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote")
|
||||
return i18n.ts.userSaysSomethingReasonQuote;
|
||||
if (what === "note") return i18n.ts.userSaysSomethingReason;
|
||||
if (what === "reply") return i18n.ts.userSaysSomethingReasonReply;
|
||||
if (what === "renote") return i18n.ts.userSaysSomethingReasonRenote;
|
||||
if (what === "quote") return i18n.ts.userSaysSomethingReasonQuote;
|
||||
|
||||
// I don't think here is reachable, but just in case
|
||||
return i18n.ts.userSaysSomething;
|
||||
}
|
||||
};
|
||||
|
||||
const isRenote =
|
||||
note.renote != null &&
|
||||
@ -255,7 +251,9 @@ let appearNote = $computed(() =>
|
||||
isRenote ? (note.renote as misskey.entities.Note) : note
|
||||
);
|
||||
const isDeleted = ref(false);
|
||||
const muted = ref(getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords));
|
||||
const muted = ref(
|
||||
getWordSoftMute(appearNote, $i, defaultStore.state.mutedWords)
|
||||
);
|
||||
const translation = ref(null);
|
||||
const translating = ref(false);
|
||||
const replies: misskey.entities.Note[] =
|
||||
|
@ -74,7 +74,7 @@ export function getWordSoftMute(
|
||||
if (note.renote) {
|
||||
let renoteMuted = checkWordMute(note.renote);
|
||||
if (renoteMuted.muted) {
|
||||
renoteMuted.what = (note.text == null ? "renote" : "quote");
|
||||
renoteMuted.what = note.text == null ? "renote" : "quote";
|
||||
return renoteMuted;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user