feat: add password confirmation to register + fix i18n hardcoded strings

- Add confirmPassword field to registration form with Zod validation
- Replace ~30 hardcoded French/English strings in admin-settings-form
  with proper t() i18n calls (Ollama models, Custom models, search test)
- Extract SettingsHeader to client component for i18n support
- Add 15 i18n keys to all 15 locale files (auth + admin.ai + admin.tools)
- Remove debug "Config value" line from embeddings section

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-04-26 19:59:38 +02:00
parent bbaae76103
commit e358171c45
20 changed files with 385 additions and 114 deletions

View File

@@ -71,7 +71,17 @@
"providerCustomOption": "🔧 Custom OpenAI-Compatible",
"saved": "(已保存)",
"chatProvider": "聊天提供商",
"chatDescription": "用于聊天助手的 AI 提供商。如果未配置,将回退到标签提供商。"
"chatDescription": "用于聊天助手的 AI 提供商。如果未配置,将回退到标签提供商。",
"fetchModelsFailed": "获取模型失败",
"refreshModels": "刷新模型",
"configured": "已配置",
"fetchingModels": "正在获取模型...",
"clickToLoadModels": "点击 ↺ 加载模型",
"searchModel": "搜索模型...",
"noModels": "无模型。点击 ↺",
"modelsAvailable": "{count} 个模型可用",
"enterUrlToLoad": "输入URL并点击↺加载模型",
"currentProvider": "(当前: {provider})"
},
"aiTest": {
"description": "测试您的 AI 提供商的标签生成和语义搜索嵌入",
@@ -217,8 +227,11 @@
"jinaKeyDescription": "用于网页抓取。无密钥也可使用,但有速率限制。",
"saveSettings": "保存工具设置",
"updateSuccess": "工具设置更新成功",
"updateFailed": "更新工具设置失败"
}
"updateFailed": "更新工具设置失败",
"testing": "测试中...",
"testSearch": "测试网络搜索"
},
"settingsDescription": "配置应用程序设置"
},
"ai": {
"analyzing": "AI 分析中...",
@@ -368,7 +381,9 @@
"signIn": "登录",
"signInToAccount": "登录您的账户",
"signOut": "退出登录",
"signUp": "注册"
"signUp": "注册",
"confirmPassword": "确认密码",
"confirmPasswordPlaceholder": "再次输入密码"
},
"autoLabels": {
"analyzing": "分析您的笔记...",