Perplexica/messages/zh-CN.json
wei840222 9a772d6abe feat(i18n): Integrate next-intl, localize core UI, add regional locales and zh-TW Discover sources
**Overview**
- Integrates next-intl (App Router, no i18n routing) with cookie-based locale and Accept-Language fallback.
- Adds message bundles and regional variants; sets en-US as the default.

**Key changes**
- i18n foundation
  - Adds request-scoped config to load messages per locale and injects NextIntlClientProvider in [layout.tsx]
  - Adds/updates messages for: en-US, en-GB, zh-TW, zh-HK, zh-CN, ja, ko, fr-FR, fr-CA, de.
Centralizes LOCALES, LOCALE_LABELS, and DEFAULT_LOCALE in [locales.ts]
  - Adds LocaleSwitcher (cookie-based) and [LocaleBootstrap]

- Pages and components
  - Localizes Sidebar, Home (including metadata/manifest), Settings, Discover, Library.
  - Localizes common components: MessageInput, Attach, Focus, Optimization, MessageBox, MessageSources, SearchImages, SearchVideos, EmptyChat, NewsArticleWidget, WeatherWidget.

- APIs
  - Weather API returns localized condition strings server-side.

- UX and quality
  - Converts all remaining <img> to Next Image.
  - Updates browserslist/caniuse DB to silence warnings.
  - Security: Settings API Key inputs are now password fields and placeholders were removed.
2025-08-16 12:27:18 +08:00

251 lines
7.1 KiB
JSON

{
"metadata": {
"title": "Perplexica - 与网络对话",
"description": "Perplexica 是一个能连接互联网的 AI 聊天机器人。"
},
"manifest": {
"name": "Perplexica - 与网络对话",
"shortName": "Perplexica",
"description": "Perplexica 是一个能连接互联网的 AI 聊天机器人。"
},
"navigation": {
"home": "首页",
"discover": "探索",
"library": "资料库",
"settings": "设置"
},
"common": {
"appName": "Perplexica",
"exportedOn": "导出日期:",
"citations": "参考来源:",
"user": "使用者",
"assistant": "助理",
"errors": {
"noChatModelsAvailable": "没有可用的聊天模型",
"chatProviderNotConfigured": "看起来你还没有配置任何聊天模型供应商,请到设置页或配置文件进行设置。",
"noEmbeddingModelsAvailable": "没有可用的向量嵌入模型",
"cannotSendBeforeConfigReady": "在设置就绪前无法发送消息",
"failedToDeleteChat": "删除聊天失败"
}
},
"navbar": {
"exportAsMarkdown": "导出为 Markdown",
"exportAsPDF": "导出为 PDF"
},
"export": {
"chatExportTitle": "聊天导出:{title}"
},
"weather": {
"conditions": {
"clear": "晴朗",
"mainlyClear": "大致晴朗",
"partlyCloudy": "局部多云",
"cloudy": "多云",
"fog": "雾",
"lightDrizzle": "小毛毛雨",
"moderateDrizzle": "中等毛毛雨",
"denseDrizzle": "大毛毛雨",
"lightFreezingDrizzle": "轻微冰雾雨",
"denseFreezingDrizzle": "强冰雾雨",
"slightRain": "小雨",
"moderateRain": "中雨",
"heavyRain": "大雨",
"lightFreezingRain": "轻微冻雨",
"heavyFreezingRain": "强冻雨",
"slightSnowFall": "小雪",
"moderateSnowFall": "中雪",
"heavySnowFall": "大雪",
"snow": "降雪",
"slightRainShowers": "短暂小雨",
"moderateRainShowers": "短暂中雨",
"heavyRainShowers": "短暂大雨",
"slightSnowShowers": "短暂小雪",
"moderateSnowShowers": "短暂中雪",
"heavySnowShowers": "短暂大雪",
"thunderstorm": "雷雨",
"thunderstormSlightHail": "雷雨伴随小冰雹",
"thunderstormHeavyHail": "雷雨伴随大冰雹"
}
},
"pages": {
"home": {
"title": "聊天 - Perplexica",
"description": "连上互联网聊聊天,与 Perplexica 对话。"
},
"discover": {
"title": "探索",
"topics": {
"tech": "科技与科学",
"finance": "财经",
"art": "艺术与文化",
"sports": "运动",
"entertainment": "娱乐"
},
"errorFetchingData": "获取数据时发生错误"
},
"library": {
"title": "资料库",
"empty": "没有找到任何聊天记录。",
"ago": "{time} 前"
},
"settings": {
"title": "设置",
"sections": {
"preferences": "偏好设置",
"automaticSearch": "自动搜索",
"systemInstructions": "系统指示",
"modelSettings": "模型设置",
"apiKeys": "API 密钥"
},
"preferences": {
"theme": "主题",
"measurementUnits": "计量单位",
"language": "语言",
"metric": "公制",
"imperial": "英制"
},
"automaticSearch": {
"image": {
"title": "自动图片搜索",
"desc": "在聊天回复中自动搜索相关图片"
},
"video": {
"title": "自动视频搜索",
"desc": "在聊天回复中自动搜索相关视频"
}
},
"model": {
"chatProvider": "聊天模型供应商",
"chat": "聊天模型",
"noModels": "没有可用的模型",
"invalidProvider": "供应商无效,请检查后端日志",
"custom": {
"modelName": "模型名称",
"apiKey": "自定义 OpenAI API 密钥",
"baseUrl": "自定义 OpenAI Base URL"
}
},
"embedding": {
"provider": "向量嵌入供应商",
"model": "向量嵌入模型"
},
"api": {
"openaiApiKey": "OpenAI API 密钥",
"ollamaApiUrl": "Ollama API 地址",
"groqApiKey": "GROQ API 密钥",
"anthropicApiKey": "Anthropic API 密钥",
"geminiApiKey": "Gemini API 密钥",
"deepseekApiKey": "Deepseek API 密钥",
"aimlApiKey": "AI/ML 密钥",
"lmStudioApiUrl": "LM Studio API 地址"
},
"systemInstructions": {
"placeholder": "任何要给 LLM 的特别指示"
}
}
},
"components": {
"common": {
"viewMore": "查看另外 {count} 项"
},
"messageInput": {
"placeholder": "提出追问"
},
"messageBox": {
"sources": "参考来源",
"answer": "回答",
"related": "相关内容"
},
"copilot": {
"label": "Copilot"
},
"attach": {
"attachedFiles": "已附加的文件",
"add": "新增",
"clear": "清除",
"attach": "附加",
"uploading": "上传中...",
"files": "{count} 个文件"
},
"focus": {
"button": "焦点",
"modes": {
"webSearch": {
"title": "全部",
"description": "在整个互联网搜索"
},
"academicSearch": {
"title": "学术",
"description": "搜索已发表的学术论文"
},
"writingAssistant": {
"title": "写作",
"description": "不搜索网络,直接聊天"
},
"wolframAlphaSearch": {
"title": "Wolfram Alpha",
"description": "计算型知识引擎"
},
"youtubeSearch": {
"title": "YouTube",
"description": "搜索和观看视频"
},
"redditSearch": {
"title": "Reddit",
"description": "搜索讨论与观点"
}
}
},
"optimization": {
"modes": {
"speed": {
"title": "速度",
"description": "优先速度,以最快的方式得到答案。"
},
"balanced": {
"title": "平衡",
"description": "在速度与准确度之间取得平衡"
},
"quality": {
"title": "品质(即将推出)",
"description": "取得最完整与最精确的回答"
}
}
},
"messageActions": {
"rewrite": "重写"
},
"searchImages": {
"searchButton": "搜索图片"
},
"searchVideos": {
"searchButton": "搜索视频",
"badge": "视频"
},
"weather": {
"humidity": "湿度",
"now": "现在"
},
"newsArticleWidget": {
"error": "无法载入新闻。"
},
"emptyChat": {
"title": "研究从这里开始。"
},
"emptyChatMessageInput": {
"placeholder": "问我任何事..."
},
"deleteChat": {
"title": "删除确认",
"description": "确定要删除此聊天吗?",
"cancel": "取消",
"delete": "删除"
},
"themeSwitcher": {
"options": {
"light": "浅色",
"dark": "深色"
}
}
}
}