Merge pull request #32 from anatawa12/pick-renote-sensitive-home-by-default
Pick renote sensitive home by default
This commit is contained in:
commit
93df9394cf
|
@ -20,6 +20,7 @@
|
||||||
- ハイライトから除外するチャンネルをsensitiveチャンネルのみにしました
|
- ハイライトから除外するチャンネルをsensitiveチャンネルのみにしました
|
||||||
|
|
||||||
### Client
|
### Client
|
||||||
|
- センシティブチャンネルのNoteのReNoteはデフォルトでHome TLに流れるようになりました
|
||||||
- Enhance: Renote自体を通報できるように
|
- Enhance: Renote自体を通報できるように
|
||||||
|
|
||||||
### Server
|
### Server
|
||||||
|
|
|
@ -319,9 +319,15 @@ function renote(viaKeyboard = false) {
|
||||||
const configuredVisibility = defaultStore.state.rememberNoteVisibility ? defaultStore.state.visibility : defaultStore.state.defaultNoteVisibility;
|
const configuredVisibility = defaultStore.state.rememberNoteVisibility ? defaultStore.state.visibility : defaultStore.state.defaultNoteVisibility;
|
||||||
const localOnly = defaultStore.state.rememberNoteVisibility ? defaultStore.state.localOnly : defaultStore.state.defaultNoteLocalOnly;
|
const localOnly = defaultStore.state.rememberNoteVisibility ? defaultStore.state.localOnly : defaultStore.state.defaultNoteLocalOnly;
|
||||||
|
|
||||||
|
let visibility = appearNote.visibility;
|
||||||
|
visibility = smallerVisibility(visibility, configuredVisibility);
|
||||||
|
if (appearNote.channel?.isSensitive) {
|
||||||
|
visibility = smallerVisibility(visibility, 'home');
|
||||||
|
}
|
||||||
|
|
||||||
os.api('notes/create', {
|
os.api('notes/create', {
|
||||||
localOnly,
|
localOnly,
|
||||||
visibility: smallerVisibility(appearNote.visibility, configuredVisibility),
|
visibility,
|
||||||
renoteId: appearNote.id,
|
renoteId: appearNote.id,
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
os.toast(i18n.ts.renoted);
|
os.toast(i18n.ts.renoted);
|
||||||
|
|
Loading…
Reference in New Issue