mirror of
https://github.com/hansjone/dsh-im-ops.git
synced 2026-10-20 19:33:28 +08:00
feat(feishu): add configurable group response mode
This commit is contained in:
parent
1a86fa5013
commit
9950261a49
19 changed files with 615 additions and 150 deletions
15
src/channels/feishu/group-response-mode.mjs
Normal file
15
src/channels/feishu/group-response-mode.mjs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
export const FEISHU_GROUP_RESPONSE_MODES = Object.freeze({
|
||||
MENTION: 'mention',
|
||||
ALL: 'all',
|
||||
});
|
||||
|
||||
export function normalizeFeishuGroupResponseMode(value) {
|
||||
return value === FEISHU_GROUP_RESPONSE_MODES.ALL
|
||||
? FEISHU_GROUP_RESPONSE_MODES.ALL
|
||||
: FEISHU_GROUP_RESPONSE_MODES.MENTION;
|
||||
}
|
||||
|
||||
export function isFeishuGroupResponseMode(value) {
|
||||
return value === FEISHU_GROUP_RESPONSE_MODES.MENTION
|
||||
|| value === FEISHU_GROUP_RESPONSE_MODES.ALL;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue