feat: support settings

This commit is contained in:
Henry Li
2026-01-20 23:43:21 +08:00
parent 3191a3845f
commit 10d253f461
25 changed files with 1355 additions and 217 deletions

View File

@@ -1,6 +1,11 @@
import type { Translations } from "./types";
export const enUS: Translations = {
// Locale meta
locale: {
localName: "English",
},
// Common
common: {
home: "Home",
@@ -83,4 +88,41 @@ export const enUS: Translations = {
readFile: "Read file",
writeFile: "Write file",
},
// Settings
settings: {
title: "Settings",
description: "Adjust how DeerFlow looks and behaves for you.",
sections: {
appearance: "Appearance",
tools: "Tools",
skills: "Skills",
acknowledge: "Acknowledge",
},
appearance: {
themeTitle: "Theme",
themeDescription:
"Choose how the interface follows your device or stays fixed.",
system: "System",
light: "Light",
dark: "Dark",
systemDescription: "Match the operating system preference automatically.",
lightDescription: "Bright palette with higher contrast for daytime.",
darkDescription: "Dim palette that reduces glare for focus.",
languageTitle: "Language",
languageDescription: "Switch between languages.",
},
tools: {
title: "Tools",
description: "Manage the configuration and enabled status of MCP tools.",
},
skills: {
title: "Skills",
description: "Manage the configuration and enabled status of the skills.",
},
acknowledge: {
emptyTitle: "Acknowledgements",
emptyDescription: "Credits and acknowledgements will show here.",
},
},
};

View File

@@ -1,4 +1,9 @@
export interface Translations {
// Locale meta
locale: {
localName: string;
};
// Common
common: {
home: string;
@@ -80,4 +85,40 @@ export interface Translations {
readFile: string;
writeFile: string;
};
// Settings
settings: {
title: string;
description: string;
sections: {
appearance: string;
tools: string;
skills: string;
acknowledge: string;
};
appearance: {
themeTitle: string;
themeDescription: string;
system: string;
light: string;
dark: string;
systemDescription: string;
lightDescription: string;
darkDescription: string;
languageTitle: string;
languageDescription: string;
};
tools: {
title: string;
description: string;
};
skills: {
title: string;
description: string;
};
acknowledge: {
emptyTitle: string;
emptyDescription: string;
};
};
}

View File

@@ -1,6 +1,11 @@
import type { Translations } from "./types";
export const zhCN: Translations = {
// Locale meta
locale: {
localName: "中文",
},
// Common
common: {
home: "首页",
@@ -83,4 +88,40 @@ export const zhCN: Translations = {
readFile: "读取文件",
writeFile: "写入文件",
},
// Settings
settings: {
title: "设置",
description: "根据你的偏好调整 DeerFlow 的界面和行为。",
sections: {
appearance: "外观",
tools: "工具",
skills: "技能",
acknowledge: "致谢",
},
appearance: {
themeTitle: "主题",
themeDescription: "跟随系统或选择固定的界面模式。",
system: "系统",
light: "浅色",
dark: "深色",
systemDescription: "自动匹配操作系统偏好。",
lightDescription: "更明亮的配色,适合日间使用。",
darkDescription: "更暗的配色,减少眩光方便专注。",
languageTitle: "语言",
languageDescription: "在不同语言之间切换。",
},
tools: {
title: "工具",
description: "管理 MCP 工具的配置和启用状态。",
},
skills: {
title: "技能",
description: "管理智能体的技能配置和启用状态。",
},
acknowledge: {
emptyTitle: "致谢",
emptyDescription: "相关的致谢信息会展示在这里。",
},
},
};