mirror of
https://activitypub.software/TransFem-org/Sharkey.git
synced 2025-01-25 08:44:33 +01:00
View MR for information: https://activitypub.software/TransFem-org/Sharkey/-/merge_requests/850 Closes #855 Approved-by: Hazelnoot <acomputerdog@gmail.com> Approved-by: Marie <github@yuugi.dev>
This commit is contained in:
commit
6c8d1462c1
1 changed files with 0 additions and 44 deletions
|
@ -19,28 +19,6 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
{{ i18n.ts.receiveAnnouncementFromInstance }}
|
{{ i18n.ts.receiveAnnouncementFromInstance }}
|
||||||
</MkSwitch>
|
</MkSwitch>
|
||||||
</FormSection>
|
</FormSection>
|
||||||
|
|
||||||
<FormSection>
|
|
||||||
<template #label>{{ i18n.ts.emailNotification }}</template>
|
|
||||||
|
|
||||||
<div class="_gaps_s">
|
|
||||||
<MkSwitch v-model="emailNotification_mention">
|
|
||||||
{{ i18n.ts._notification._types.mention }}
|
|
||||||
</MkSwitch>
|
|
||||||
<MkSwitch v-model="emailNotification_reply">
|
|
||||||
{{ i18n.ts._notification._types.reply }}
|
|
||||||
</MkSwitch>
|
|
||||||
<MkSwitch v-model="emailNotification_quote">
|
|
||||||
{{ i18n.ts._notification._types.quote }}
|
|
||||||
</MkSwitch>
|
|
||||||
<MkSwitch v-model="emailNotification_follow">
|
|
||||||
{{ i18n.ts._notification._types.follow }}
|
|
||||||
</MkSwitch>
|
|
||||||
<MkSwitch v-model="emailNotification_receiveFollowRequest">
|
|
||||||
{{ i18n.ts._notification._types.receiveFollowRequest }}
|
|
||||||
</MkSwitch>
|
|
||||||
</div>
|
|
||||||
</FormSection>
|
|
||||||
</div>
|
</div>
|
||||||
<div v-if="!instance.enableEmail" class="_gaps_m">
|
<div v-if="!instance.enableEmail" class="_gaps_m">
|
||||||
<MkInfo>{{ i18n.ts.emailNotSupported }}</MkInfo>
|
<MkInfo>{{ i18n.ts.emailNotSupported }}</MkInfo>
|
||||||
|
@ -81,28 +59,6 @@ async function saveEmailAddress() {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
const emailNotification_mention = ref($i.emailNotificationTypes.includes('mention'));
|
|
||||||
const emailNotification_reply = ref($i.emailNotificationTypes.includes('reply'));
|
|
||||||
const emailNotification_quote = ref($i.emailNotificationTypes.includes('quote'));
|
|
||||||
const emailNotification_follow = ref($i.emailNotificationTypes.includes('follow'));
|
|
||||||
const emailNotification_receiveFollowRequest = ref($i.emailNotificationTypes.includes('receiveFollowRequest'));
|
|
||||||
|
|
||||||
const saveNotificationSettings = () => {
|
|
||||||
misskeyApi('i/update', {
|
|
||||||
emailNotificationTypes: [
|
|
||||||
...[emailNotification_mention.value ? 'mention' : null],
|
|
||||||
...[emailNotification_reply.value ? 'reply' : null],
|
|
||||||
...[emailNotification_quote.value ? 'quote' : null],
|
|
||||||
...[emailNotification_follow.value ? 'follow' : null],
|
|
||||||
...[emailNotification_receiveFollowRequest.value ? 'receiveFollowRequest' : null],
|
|
||||||
].filter(x => x != null),
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
watch([emailNotification_mention, emailNotification_reply, emailNotification_quote, emailNotification_follow, emailNotification_receiveFollowRequest], () => {
|
|
||||||
saveNotificationSettings();
|
|
||||||
});
|
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
watch(emailAddress, () => {
|
watch(emailAddress, () => {
|
||||||
saveEmailAddress();
|
saveEmailAddress();
|
||||||
|
|
Loading…
Add table
Reference in a new issue