feat: add i18n for mask

This commit is contained in:
Yidadaa
2023-04-27 01:16:21 +08:00
parent 3cda44e05b
commit c7c58ef031
22 changed files with 890 additions and 81 deletions

View File

@@ -30,6 +30,10 @@ const cn = {
return inputHints + "/ 触发补全";
},
Send: "发送",
Config: {
Reset: "重置默认",
SaveAs: "另存为面具",
},
},
Export: {
Title: "导出聊天记录为 Markdown",
@@ -68,6 +72,7 @@ const cn = {
},
Lang: {
Name: "Language",
All: "所有语言",
Options: {
cn: "简体中文",
en: "English",
@@ -176,6 +181,39 @@ const cn = {
Edit: "当前对话设置",
Add: "新增预设对话",
},
Mask: {
Page: {
Title: "预设角色面具",
SubTitle: (count: number) => `${count} 个预设角色定义`,
Search: "搜索角色面具",
Create: "新建",
},
Item: {
Info: (count: number) => `包含 ${count} 条预设对话`,
Chat: "对话",
View: "查看",
Edit: "编辑",
Delete: "删除",
DeleteConfirm: "确认删除?",
},
EditModal: {
Title: (readonly: boolean) =>
`编辑预设面具 ${readonly ? "(只读)" : ""}`,
Download: "下载预设",
Clone: "克隆预设",
},
Config: {
Avatar: "角色头像",
Name: "角色名称",
},
},
NewChat: {
Return: "返回",
Skip: "跳过",
Title: "挑选一个面具",
SubTitle: "现在开始,与面具背后的灵魂思维碰撞",
More: "搜索更多",
},
};
export type LocaleType = typeof cn;

View File

@@ -31,6 +31,10 @@ const de: LocaleType = {
return inputHints + ", / zum Durchsuchen von Prompts";
},
Send: "Senden",
Config: {
Reset: "Reset to Default",
SaveAs: "Save as Mask",
},
},
Export: {
Title: "Alle Nachrichten",
@@ -70,6 +74,7 @@ const de: LocaleType = {
},
Lang: {
Name: "Language", // ATTENTION: if you wanna add a new translation, please do not translate this value, leave it as `Language`
All: "All Languages",
Options: {
cn: "简体中文",
en: "English",
@@ -184,6 +189,39 @@ const de: LocaleType = {
Edit: "Kontext- und Gedächtnis-Prompts",
Add: "Hinzufügen",
},
Mask: {
Page: {
Title: "Prompt Template",
SubTitle: (count: number) => `${count} prompt templates`,
Search: "Search Templates",
Create: "Create",
},
Item: {
Info: (count: number) => `${count} prompts`,
Chat: "Chat",
View: "View",
Edit: "Edit",
Delete: "Delete",
DeleteConfirm: "Confirm to delete?",
},
EditModal: {
Title: (readonly: boolean) =>
`Edit Prompt Template ${readonly ? "(readonly)" : ""}`,
Download: "Download",
Clone: "Clone",
},
Config: {
Avatar: "Bot Avatar",
Name: "Bot Name",
},
},
NewChat: {
Return: "Return",
Skip: "Skip",
Title: "Pick a Mask",
SubTitle: "Chat with the Soul behind the Mask",
More: "Find More",
},
};
export default de;

View File

@@ -31,6 +31,10 @@ const en: LocaleType = {
return inputHints + ", / to search prompts";
},
Send: "Send",
Config: {
Reset: "Reset to Default",
SaveAs: "Save as Mask",
},
},
Export: {
Title: "All Messages",
@@ -70,6 +74,7 @@ const en: LocaleType = {
},
Lang: {
Name: "Language", // ATTENTION: if you wanna add a new translation, please do not translate this value, leave it as `Language`
All: "All Languages",
Options: {
cn: "简体中文",
en: "English",
@@ -178,7 +183,40 @@ const en: LocaleType = {
Context: {
Toast: (x: any) => `With ${x} contextual prompts`,
Edit: "Contextual and Memory Prompts",
Add: "Add One",
Add: "Add a Prompt",
},
Mask: {
Page: {
Title: "Prompt Template",
SubTitle: (count: number) => `${count} prompt templates`,
Search: "Search Templates",
Create: "Create",
},
Item: {
Info: (count: number) => `${count} prompts`,
Chat: "Chat",
View: "View",
Edit: "Edit",
Delete: "Delete",
DeleteConfirm: "Confirm to delete?",
},
EditModal: {
Title: (readonly: boolean) =>
`Edit Prompt Template ${readonly ? "(readonly)" : ""}`,
Download: "Download",
Clone: "Clone",
},
Config: {
Avatar: "Bot Avatar",
Name: "Bot Name",
},
},
NewChat: {
Return: "Return",
Skip: "Skip",
Title: "Pick a Mask",
SubTitle: "Chat with the Soul behind the Mask",
More: "Find More",
},
};

View File

@@ -31,6 +31,10 @@ const es: LocaleType = {
return inputHints;
},
Send: "Enviar",
Config: {
Reset: "Reset to Default",
SaveAs: "Save as Mask",
},
},
Export: {
Title: "Todos los mensajes",
@@ -70,6 +74,7 @@ const es: LocaleType = {
},
Lang: {
Name: "Language",
All: "All Languages",
Options: {
cn: "简体中文",
en: "Inglés",
@@ -182,6 +187,39 @@ const es: LocaleType = {
Edit: "Contextual and Memory Prompts",
Add: "Add One",
},
Mask: {
Page: {
Title: "Prompt Template",
SubTitle: (count: number) => `${count} prompt templates`,
Search: "Search Templates",
Create: "Create",
},
Item: {
Info: (count: number) => `${count} prompts`,
Chat: "Chat",
View: "View",
Edit: "Edit",
Delete: "Delete",
DeleteConfirm: "Confirm to delete?",
},
EditModal: {
Title: (readonly: boolean) =>
`Edit Prompt Template ${readonly ? "(readonly)" : ""}`,
Download: "Download",
Clone: "Clone",
},
Config: {
Avatar: "Bot Avatar",
Name: "Bot Name",
},
},
NewChat: {
Return: "Return",
Skip: "Skip",
Title: "Pick a Mask",
SubTitle: "Chat with the Soul behind the Mask",
More: "Find More",
},
};
export default es;

View File

@@ -31,6 +31,10 @@ const it: LocaleType = {
return inputHints;
},
Send: "Invia",
Config: {
Reset: "Reset to Default",
SaveAs: "Save as Mask",
},
},
Export: {
Title: "Tutti i messaggi",
@@ -70,6 +74,7 @@ const it: LocaleType = {
},
Lang: {
Name: "Lingue",
All: "All Languages",
Options: {
cn: "简体中文",
en: "English",
@@ -183,6 +188,39 @@ const it: LocaleType = {
Edit: "Prompt contestuali e di memoria",
Add: "Aggiungi altro",
},
Mask: {
Page: {
Title: "Prompt Template",
SubTitle: (count: number) => `${count} prompt templates`,
Search: "Search Templates",
Create: "Create",
},
Item: {
Info: (count: number) => `${count} prompts`,
Chat: "Chat",
View: "View",
Edit: "Edit",
Delete: "Delete",
DeleteConfirm: "Confirm to delete?",
},
EditModal: {
Title: (readonly: boolean) =>
`Edit Prompt Template ${readonly ? "(readonly)" : ""}`,
Download: "Download",
Clone: "Clone",
},
Config: {
Avatar: "Bot Avatar",
Name: "Bot Name",
},
},
NewChat: {
Return: "Return",
Skip: "Skip",
Title: "Pick a Mask",
SubTitle: "Chat with the Soul behind the Mask",
More: "Find More",
},
};
export default it;

View File

@@ -1,6 +1,7 @@
import { SubmitKey } from "../store/config";
import type { LocaleType } from "./index";
const jp = {
const jp: LocaleType = {
WIP: "この機能は開発中です……",
Error: {
Unauthorized:
@@ -30,6 +31,10 @@ const jp = {
return inputHints + "/ で自動補完をトリガー";
},
Send: "送信",
Config: {
Reset: "重置默认",
SaveAs: "另存为面具",
},
},
Export: {
Title: "チャット履歴をMarkdown形式でエクスポート",
@@ -69,6 +74,7 @@ const jp = {
},
Lang: {
Name: "Language",
All: "所有语言",
Options: {
cn: "简体中文",
en: "English",
@@ -182,6 +188,39 @@ const jp = {
Edit: "前置コンテキストと履歴メモリ",
Add: "新規追加",
},
Mask: {
Page: {
Title: "预设角色面具",
SubTitle: (count: number) => `${count} 个预设角色定义`,
Search: "搜索角色面具",
Create: "新建",
},
Item: {
Info: (count: number) => `包含 ${count} 条预设对话`,
Chat: "对话",
View: "查看",
Edit: "编辑",
Delete: "删除",
DeleteConfirm: "确认删除?",
},
EditModal: {
Title: (readonly: boolean) =>
`编辑预设面具 ${readonly ? "(只读)" : ""}`,
Download: "下载预设",
Clone: "克隆预设",
},
Config: {
Avatar: "角色头像",
Name: "角色名称",
},
},
NewChat: {
Return: "返回",
Skip: "跳过",
Title: "挑选一个面具",
SubTitle: "现在开始,与面具背后的灵魂思维碰撞",
More: "搜索更多",
},
};
export default jp;

View File

@@ -31,6 +31,10 @@ const tr: LocaleType = {
return inputHints + ", komutları aramak için / (eğik çizgi)";
},
Send: "Gönder",
Config: {
Reset: "Reset to Default",
SaveAs: "Save as Mask",
},
},
Export: {
Title: "Tüm Mesajlar",
@@ -70,6 +74,7 @@ const tr: LocaleType = {
},
Lang: {
Name: "Language", // ATTENTION: if you wanna add a new translation, please do not translate this value, leave it as `Language`
All: "All Languages",
Options: {
cn: "简体中文",
en: "English",
@@ -183,6 +188,39 @@ const tr: LocaleType = {
Edit: "Bağlamsal ve Bellek Komutları",
Add: "Yeni Ekle",
},
Mask: {
Page: {
Title: "Prompt Template",
SubTitle: (count: number) => `${count} prompt templates`,
Search: "Search Templates",
Create: "Create",
},
Item: {
Info: (count: number) => `${count} prompts`,
Chat: "Chat",
View: "View",
Edit: "Edit",
Delete: "Delete",
DeleteConfirm: "Confirm to delete?",
},
EditModal: {
Title: (readonly: boolean) =>
`Edit Prompt Template ${readonly ? "(readonly)" : ""}`,
Download: "Download",
Clone: "Clone",
},
Config: {
Avatar: "Bot Avatar",
Name: "Bot Name",
},
},
NewChat: {
Return: "Return",
Skip: "Skip",
Title: "Pick a Mask",
SubTitle: "Chat with the Soul behind the Mask",
More: "Find More",
},
};
export default tr;

View File

@@ -30,6 +30,10 @@ const tw: LocaleType = {
return inputHints;
},
Send: "發送",
Config: {
Reset: "重置默认",
SaveAs: "另存为面具",
},
},
Export: {
Title: "匯出聊天記錄為 Markdown",
@@ -68,6 +72,7 @@ const tw: LocaleType = {
},
Lang: {
Name: "Language",
All: "所有语言",
Options: {
cn: "简体中文",
en: "English",
@@ -175,6 +180,39 @@ const tw: LocaleType = {
Edit: "前置上下文和歷史記憶",
Add: "新增壹條",
},
Mask: {
Page: {
Title: "预设角色面具",
SubTitle: (count: number) => `${count} 个预设角色定义`,
Search: "搜索角色面具",
Create: "新建",
},
Item: {
Info: (count: number) => `包含 ${count} 条预设对话`,
Chat: "对话",
View: "查看",
Edit: "编辑",
Delete: "删除",
DeleteConfirm: "确认删除?",
},
EditModal: {
Title: (readonly: boolean) =>
`编辑预设面具 ${readonly ? "(只读)" : ""}`,
Download: "下载预设",
Clone: "克隆预设",
},
Config: {
Avatar: "角色头像",
Name: "角色名称",
},
},
NewChat: {
Return: "返回",
Skip: "跳过",
Title: "挑选一个面具",
SubTitle: "现在开始,与面具背后的灵魂思维碰撞",
More: "搜索更多",
},
};
export default tw;