Skip to content

DeepSeek Harness Tauri 桌面版 | Only 8mb installer, zero environment setup, preset plugins, Windows / macOS / Linux.

feat(i18n): localize config tabs and dialog confirm/cancel buttons

hairyf14dfba763788
diff --git a/src/components/dialog.tsx b/src/components/dialog.tsx
index 025cef44..5d0e8354 100644
--- a/src/components/dialog.tsx
+++ b/src/components/dialog.tsx
@@ -3,6 +3,7 @@ import type { AlertDialogStatus } from 'node_modules/@heroui/react/dist/componen
import type { ReactNode } from 'react'
import { AlertDialog, Button } from '@heroui/react'
import { useDisclosure } from '@overlastic/react'
+import { useTranslation } from 'react-i18next'
export interface DialogProps extends PropsWithOverlays {
status: AlertDialogStatus
@@ -15,6 +16,7 @@ export interface DialogProps extends PropsWithOverlays {
export function Dialog(props: DialogProps) {
const disclosure = useDisclosure({ props })
+ const { t } = useTranslation()
const buttonVariant = props.status === 'danger' ? 'danger' : 'primary'
@@ -33,10 +35,10 @@ export function Dialog(props: DialogProps) {
</AlertDialog.Body>
<AlertDialog.Footer>
<Button className="rounded-md" variant="tertiary" onPress={disclosure.cancel}>
- {props.cancelText || 'Cancel'}
+ {props.cancelText || t('buttons.cancel')}
</Button>
<Button className="rounded-md" variant={buttonVariant} onPress={disclosure.confirm}>
- {props.confirmText || 'Confirm'}
+ {props.confirmText || t('buttons.confirm')}
</Button>
</AlertDialog.Footer>
</AlertDialog.Dialog>
diff --git a/src/i18n/locales/en-US.json b/src/i18n/locales/en-US.json
index 30c99072..cbc81fe6 100644
--- a/src/i18n/locales/en-US.json
+++ b/src/i18n/locales/en-US.json
@@ -200,5 +200,11 @@
"core.remove_failed": "Failed to uninstall the core version",
"core.local_missing_hint": "No local core detected. Install @deepseek-ai/dsh globally via npm/pnpm and the desktop will prefer it automatically.",
"app.dev_env": "Development",
- "app.config": "Configuration"
+ "app.config": "Configuration",
+ "config.debug": "Debug",
+ "config.profiles": "Profiles",
+ "config.plugins": "Plugins",
+ "config.harness": "Harness",
+ "buttons.cancel": "Cancel",
+ "buttons.confirm": "Confirm"
}
diff --git a/src/i18n/locales/zh-CN.json b/src/i18n/locales/zh-CN.json
index 3c4920c6..53a16e3e 100644
--- a/src/i18n/locales/zh-CN.json
+++ b/src/i18n/locales/zh-CN.json
@@ -200,5 +200,11 @@
"core.remove_failed": "卸载核心版本失败",
"core.local_missing_hint": "未检测到本地核心。通过 npm/pnpm 全局安装 @deepseek-ai/dsh 后,桌面端将自动优先使用它。",
"app.dev_env": "开发环境",
- "app.config": "应用配置"
+ "app.config": "应用配置",
+ "config.debug": "调试",
+ "config.profiles": "档案",
+ "config.plugins": "插件",
+ "config.harness": "核心",
+ "buttons.cancel": "取消",
+ "buttons.confirm": "确定"
}