解决年度报告导出失败 #252;集成WechatVisualization的功能并支持词云排除 #259

This commit is contained in:
cc
2026-02-16 10:23:33 +08:00
parent 6394384be0
commit 28e38f73f8
15 changed files with 360 additions and 26 deletions

View File

@@ -44,7 +44,10 @@ export const CONFIG_KEYS = {
NOTIFICATION_ENABLED: 'notificationEnabled',
NOTIFICATION_POSITION: 'notificationPosition',
NOTIFICATION_FILTER_MODE: 'notificationFilterMode',
NOTIFICATION_FILTER_LIST: 'notificationFilterList'
NOTIFICATION_FILTER_LIST: 'notificationFilterList',
// 词云
WORD_CLOUD_EXCLUDE_WORDS: 'wordCloudExcludeWords'
} as const
export interface WxidConfig {
@@ -465,3 +468,14 @@ export async function getNotificationFilterList(): Promise<string[]> {
export async function setNotificationFilterList(list: string[]): Promise<void> {
await config.set(CONFIG_KEYS.NOTIFICATION_FILTER_LIST, list)
}
// 获取词云排除词列表
export async function getWordCloudExcludeWords(): Promise<string[]> {
const value = await config.get(CONFIG_KEYS.WORD_CLOUD_EXCLUDE_WORDS)
return Array.isArray(value) ? value : []
}
// 设置词云排除词列表
export async function setWordCloudExcludeWords(words: string[]): Promise<void> {
await config.set(CONFIG_KEYS.WORD_CLOUD_EXCLUDE_WORDS, words)
}