chore: add setting

This commit is contained in:
river
2024-09-19 12:38:46 +08:00
parent 065f015f7b
commit 775794e0e4
4 changed files with 54 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
import { getClientConfig } from "../config/client";
import { SubmitKey } from "../store/config";
import { LocaleType } from "./index";
import { SAAS_CHAT_URL } from "@/app/constant";
// if you are adding a new translation, please use PartialLocaleType instead of LocaleType
const isApp = !!getClientConfig()?.isApp;
@@ -9,8 +9,14 @@ const en: LocaleType = {
WIP: "Coming Soon...",
Error: {
Unauthorized: isApp
? "Invalid API Key, please check it in [Settings](/#/settings) page."
: "Unauthorized access, please enter access code in [auth](/#/auth) page, or enter your OpenAI API Key.",
? `😆 Oops, there's an issue. No worries:
\\ 1⃣ New here? [Click to start chatting now 🚀](${SAAS_CHAT_URL})
\\ 2⃣ Want to use your own OpenAI resources? [Click here](/#/settings) to change settings ⚙️`
: `😆 Oops, there's an issue. Let's fix it:
\ 1⃣ New here? [Click to start chatting now 🚀](${SAAS_CHAT_URL})
\ 2⃣ Using a private setup? [Click here](/#/auth) to enter your key 🔑
\ 3⃣ Want to use your own OpenAI resources? [Click here](/#/settings) to change settings ⚙️
`,
},
Auth: {
Return: "Return",
@@ -303,6 +309,13 @@ const en: LocaleType = {
NoAccess: "Enter API Key to check balance",
},
Access: {
SaasStart: {
Title: "Use NextChat AI",
Label: " (Most Cost-Effective Option)",
SubTitle:
"Maintained by NextChat, zero setup needed, supports the latest models like GPT-4o, Gemini, Claude3, and more.",
ChatNow: "Start Now",
},
AccessCode: {
Title: "Access Code",
SubTitle: "Access control Enabled",
@@ -463,7 +476,7 @@ const en: LocaleType = {
ApiKey: {
Title: "API Key",
SubTitle: "Obtain your API Key from Google AI",
Placeholder: "Enter your Google AI Studio API Key",
Placeholder: "Google AI API Key",
},
Endpoint: {