不明なリアクションのフォールバックに star を使うようにするオプション

This commit is contained in:
syuilo
2019-03-18 01:03:35 +09:00
parent 810ed50976
commit 08c176e549
10 changed files with 26 additions and 16 deletions

View File

@ -48,6 +48,13 @@ export const meta = {
}
},
useStarForReactionFallback: {
validator: $.optional.nullable.bool,
desc: {
'ja-JP': '不明なリアクションのフォールバックに star リアクションを使うか'
}
},
hidedTags: {
validator: $.optional.nullable.arr($.str),
desc: {
@ -362,6 +369,10 @@ export default define(meta, async (ps) => {
set.enableEmojiReaction = ps.enableEmojiReaction;
}
if (typeof ps.useStarForReactionFallback === 'boolean') {
set.useStarForReactionFallback = ps.useStarForReactionFallback;
}
if (Array.isArray(ps.hidedTags)) {
set.hidedTags = ps.hidedTags;
}

View File

@ -152,6 +152,7 @@ export default define(meta, async (ps, me) => {
}
if (me && (me.isAdmin || me.isModerator)) {
response.useStarForReactionFallback = instance.useStarForReactionFallback;
response.hidedTags = instance.hidedTags;
response.recaptchaSecretKey = instance.recaptchaSecretKey;
response.proxyAccount = instance.proxyAccount;

View File

@ -392,7 +392,8 @@ export const schemas = {
'angry',
'confused',
'rip',
'pudding'
'pudding',
'star'
],
description: 'The reaction type.'
},