Merge pull request #21 from 3kho/main
Add Chinese and Russian Translations
This commit is contained in:
commit
954c375a5f
12 changed files with 2518 additions and 1882 deletions
2325
package-lock.json
generated
2325
package-lock.json
generated
File diff suppressed because it is too large
Load diff
22
package.json
22
package.json
|
|
@ -12,16 +12,16 @@
|
|||
"lint:fix": "eslint --fix ."
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/node": "^8.2.5",
|
||||
"@astrojs/sitemap": "^3.1.4",
|
||||
"@astrojs/node": "^8.3.2",
|
||||
"@astrojs/sitemap": "^3.1.6",
|
||||
"@mercuryworkshop/bare-as-module3": "^2.2.2",
|
||||
"@mercuryworkshop/bare-mux": "^2.0.2",
|
||||
"@mercuryworkshop/epoxy-transport": "^2.1.3",
|
||||
"@mercuryworkshop/libcurl-transport": "^1.3.6",
|
||||
"@titaniumnetwork-dev/ultraviolet": "^3.2.5",
|
||||
"@tomphttp/bare-server-node": "^2.0.3",
|
||||
"@types/node": "^20.14.10",
|
||||
"astro": "^4.7.0",
|
||||
"@mercuryworkshop/bare-mux": "^2.0.4",
|
||||
"@mercuryworkshop/epoxy-transport": "^2.1.5",
|
||||
"@mercuryworkshop/libcurl-transport": "^1.3.7",
|
||||
"@titaniumnetwork-dev/ultraviolet": "^3.2.6",
|
||||
"@tomphttp/bare-server-node": "^2.0.4",
|
||||
"@types/node": "^20.14.12",
|
||||
"astro": "^4.12.2",
|
||||
"chalk": "^5.3.0",
|
||||
"compression": "^1.7.4",
|
||||
"cookie-parser": "^1.4.6",
|
||||
|
|
@ -32,8 +32,8 @@
|
|||
"wisp-server-node": "^1.1.3"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@typescript-eslint/eslint-plugin": "^7.8.0",
|
||||
"@typescript-eslint/parser": "^7.8.0",
|
||||
"@typescript-eslint/eslint-plugin": "^7.17.0",
|
||||
"@typescript-eslint/parser": "^7.17.0",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-plugin-astro": "^0.31.4",
|
||||
"prettier": "3.2.5",
|
||||
|
|
|
|||
1876
pnpm-lock.yaml
generated
1876
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load diff
|
|
@ -10,8 +10,18 @@ const t = i18n.inferLangUseTranslations(Astro.url);
|
|||
{t("ultraviolet")} - <Link href="https://titaniumnetwork.org/" newTab>Titanium Network</Link>
|
||||
</p>
|
||||
<p class="credit-item">
|
||||
{t("settings.credits.japaneseTranslations")} - <Link href="https://wearr.dev" newTab>wearr</Link>
|
||||
{t("settings.credits.jpTranslations")} - <Link href="https://wearr.dev" newTab>wearr</Link>
|
||||
</p>
|
||||
<p class="credit-item">
|
||||
{t("settings.credits.ruTranslations")} - <Link href="https://3kh0.net" newTab>Echo</Link>
|
||||
</p>
|
||||
<p class="credit-item">
|
||||
{t("settings.credits.zhTranslations")} - <Link href="https://3kh0.net" newTab>Echo</Link>
|
||||
</p>
|
||||
<p class="credit-item">
|
||||
French Translations - <Link href="https://github.com/notboeing747" newTab>notboeing747</Link>
|
||||
</p>
|
||||
<!-- todo: finish localization for this page -->
|
||||
<p class="credit-item">
|
||||
{t("settings.credits.mochaandmacchiatothemes")} - <Link href="https://github.com/catppuccin/catppuccin" newTab>Catppuccin</Link>
|
||||
</p>
|
||||
|
|
@ -21,9 +31,6 @@ const t = i18n.inferLangUseTranslations(Astro.url);
|
|||
<p class="credit-item">
|
||||
Rosé Pine Theme - <Link href="https://rosepinetheme.com/" newTab>Rosé Pine</Link>
|
||||
</p>
|
||||
<p class="credit-item">
|
||||
French Translations - <Link href="https://github.com/notboeing747" newTab>notboeing747</Link>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -13,8 +13,10 @@ const themeList = [
|
|||
|
||||
const languageList = [
|
||||
{ name: "English", value: "en" },
|
||||
{ name: "日本語", value: "jp" },
|
||||
{ name: "Français", value: "fr" },
|
||||
{ name: "中文", value: "zh" },
|
||||
{ name: "日本語", value: "jp" },
|
||||
{ name: "Русский", value: "ru" },
|
||||
];
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -61,5 +61,7 @@
|
|||
|
||||
"settings.credits": "Credits",
|
||||
"settings.credits.mochaandmacchiatothemes": "Mocha & Macchiato Themes",
|
||||
"settings.credits.japaneseTranslations": "Japanese Translations"
|
||||
"settings.credits.jpTranslations": "Japanese Translations",
|
||||
"settings.credits.ruTranslations": "Russian Translations",
|
||||
"settings.credits.zhTranslations": "Chinese Translations"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,5 +61,7 @@
|
|||
|
||||
"settings.credits": "Crédits",
|
||||
"settings.credits.mochaandmacchiatothemes": "Thème Moka & Macchiato",
|
||||
"settings.credits.japaneseTranslations": "Traduction Japonais"
|
||||
"settings.credits.jpTranslations": "Traductions Japonais",
|
||||
"settings.credits.ruTranslations": "Traductions russes",
|
||||
"settings.credits.zhTranslations": "Traductions chinoises"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,5 +61,7 @@
|
|||
|
||||
"settings.credits": "クレジット",
|
||||
"settings.credits.mochaandmacchiatothemes": "モカとマキアートテーマ",
|
||||
"settings.credits.japaneseTranslations": "日本語翻訳"
|
||||
"settings.credits.jpTranslations": "日本語翻訳",
|
||||
"settings.credits.ruTranslations": "ロシア語翻訳",
|
||||
"settings.credits.zhTranslations": "中国語翻訳"
|
||||
}
|
||||
|
|
|
|||
67
src/i18n/ru.json
Normal file
67
src/i18n/ru.json
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
{
|
||||
"ultraviolet": "Ultraviolet",
|
||||
|
||||
"pages.home": "Дом | Alu",
|
||||
"pages.games": "Игры | Alu",
|
||||
"pages.settings": "Настройки | Alu",
|
||||
|
||||
"nav.brand": "Alu",
|
||||
"nav.games": "Игры",
|
||||
"nav.settings": "Настройки",
|
||||
|
||||
"menu.welcome": "Добро пожаловать в Alu",
|
||||
"menu.search": "Искать в Интернете...",
|
||||
|
||||
"faq.title": "Часто задаваемые вопросы",
|
||||
|
||||
"faq.whatIsAProxy": "Что такое прокси?",
|
||||
"faq.whatIsAProxy.answer": "Прокси-сервер - это способ сделать ваш интернет-трафик анонимным, отправляя запрос на сервер (прокси), который выполняет запрос и затем отправляет его обратно вам! Это позволяет обеспечить гораздо более высокий уровень безопасности, а также обойти ограничения на доступ к веб-сайтам в общественных местах и цензуру.",
|
||||
|
||||
"faq.noBareClients": "Что значит \"нет голых клиентов\"?",
|
||||
"faq.noBareClients.answer": "Есть несколько причин, по которым возникает эта ошибка, но чаще всего она связана с тем, что прокси не загружается. Пожалуйста, перезагрузите страницу, и если проблема не исчезнет, создайте проблему на GitHub!",
|
||||
|
||||
"faq.contributeToAlu": "Как я могу внести свой вклад в развитие Alu?",
|
||||
"faq.contributeToAlu.answer.segment1": "Распространение информации об Alu - отличное начало, но если вам действительно нравится Alu и нужны закрытые ссылки, поддержите меня через Patreon!",
|
||||
"faq.contributeToAlu.answer.patreonLinkText": "Вы можете поддержать меня здесь!",
|
||||
"faq.contributeToAlu.answer.segment2": "Спасибо, что помогаете делать Alu великой!",
|
||||
|
||||
"footer.brand": "Alu",
|
||||
"footer.madeWithLove": "Сделано с ❤️ by wearr",
|
||||
"footer.poweredBy": "Titanium Network",
|
||||
"footer.services": "Услуги",
|
||||
"footer.socials": "Соцсети",
|
||||
"footer.aluProject": "Проект Alu",
|
||||
|
||||
"games.title": "Игры",
|
||||
"games.search": "Поиск...",
|
||||
|
||||
"settings.title": "Настройки",
|
||||
"settings.proxy": "Прокси",
|
||||
"settings.proxy.auto": "Авто",
|
||||
"settings.proxy.selectedProxy": "Выбранный прокси",
|
||||
"settings.proxy.searchEngine": "Поисковая система",
|
||||
"settings.proxy.openPageWith": "Открыть с",
|
||||
"settings.proxy.openPageWith.embed": "Встроить",
|
||||
"settings.proxy.openPageWith.newTab": "Новая вкладка",
|
||||
"settings.proxy.searxngURL": "Searx URL",
|
||||
"settings.proxy.transport": "Транспорт",
|
||||
"settings.proxy.wispURL": "Wisp URL",
|
||||
"settings.proxy.bareURL": "Bare URL",
|
||||
|
||||
"settings.customization": "Настройка",
|
||||
"settings.customization.theme": "Тема",
|
||||
"settings.customization.theme.Alu": "Alu",
|
||||
"settings.customization.theme.Macchiato": "Macchiato",
|
||||
"settings.customization.theme.Mocha": "Mocha",
|
||||
"settings.customization.language": "Язык",
|
||||
|
||||
"settings.cloaking": "Маскировка",
|
||||
"settings.cloaking.subtext": "Измените внешний вид своей вкладки...",
|
||||
"settings.cloaking.updateCloak": "Обновить плащ",
|
||||
|
||||
"settings.credits": "Кредиты",
|
||||
"settings.credits.mochaandmacchiatothemes": "Mocha и Macchiato Темы",
|
||||
"settings.credits.jpTranslations": "Японские переводы",
|
||||
"settings.credits.ruTranslations": "Русские переводы",
|
||||
"settings.credits.zhTranslations": "Китайские переводы"
|
||||
}
|
||||
|
|
@ -1,11 +1,15 @@
|
|||
import en from "./en.json";
|
||||
import jp from "./jp.json";
|
||||
import fr from "./fr.json";
|
||||
import zh from "./zh.json";
|
||||
import jp from "./jp.json";
|
||||
import ru from "./ru.json";
|
||||
|
||||
export const defaultLang = "en";
|
||||
|
||||
export const ui = {
|
||||
en,
|
||||
jp,
|
||||
fr,
|
||||
zh,
|
||||
jp,
|
||||
ru,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ import { ui, defaultLang } from "./ui";
|
|||
type LanguageKeys = keyof typeof ui;
|
||||
type TranslationKeys = keyof (typeof ui)[typeof defaultLang];
|
||||
|
||||
export const STATIC_PATHS = [{ params: { lang: "en" } }, { params: { lang: "jp" } }, { params: { lang: "fr" } }];
|
||||
export const STATIC_PATHS = [{ params: { lang: "en" } }, { params: { lang: "fr" } }, { params: { lang: "zh" } }, { params: { lang: "jp" } }, { params: { lang: "ru" } }];
|
||||
|
||||
function getLangFromUrl(url: URL) {
|
||||
// comma lol
|
||||
|
|
|
|||
67
src/i18n/zh.json
Normal file
67
src/i18n/zh.json
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
{
|
||||
"ultraviolet": "Ultraviolet",
|
||||
|
||||
"pages.home": "家 | Alu",
|
||||
"pages.games": "游戏 | Alu",
|
||||
"pages.settings": "设置 | Alu",
|
||||
|
||||
"nav.brand": "Alu",
|
||||
"nav.games": "游戏",
|
||||
"nav.settings": "设置",
|
||||
|
||||
"menu.welcome": "欢迎来到 Alu",
|
||||
"menu.search": "搜索网络...",
|
||||
|
||||
"faq.title": "常见问题解答",
|
||||
|
||||
"faq.whatIsAProxy": "什么是代理?",
|
||||
"faq.whatIsAProxy.answer": "代理是一种匿名上网的方法,它通过将您的请求发送到服务器(代理),让服务器发出请求,然后将其发送回给您!这可以提供更高级别的安全性,并绕过公共场所的网站限制和审查。",
|
||||
|
||||
"faq.noBareClients": "\"没有裸客户端\"是什么意思?",
|
||||
"faq.noBareClients.answer": "发生此特定错误的原因有多种,但最常见的原因是代理加载失败。请重新加载页面,如果问题仍然存在,请提交 GitHub 问题!",
|
||||
|
||||
"faq.contributeToAlu": "我能为 Alu 做出什么贡献?",
|
||||
"faq.contributeToAlu.answer.segment1": "传播 Alu 的消息是一个很好的开始,但如果您真的喜欢 Alu,并且想要私人链接,请考虑通过 Patreon 支持我!",
|
||||
"faq.contributeToAlu.answer.patreonLinkText": "您可以在这里支持我!",
|
||||
"faq.contributeToAlu.answer.segment2": "感谢您帮助 Alu 变得伟大!",
|
||||
|
||||
"footer.brand": "Alu",
|
||||
"footer.madeWithLove": "由 wearr 用❤️制作",
|
||||
"footer.poweredBy": "Titanium Network",
|
||||
"footer.services": "服务",
|
||||
"footer.socials": "社交",
|
||||
"footer.aluProject": "Alu 项目",
|
||||
|
||||
"games.title": "游戏",
|
||||
"games.search": "搜索...",
|
||||
|
||||
"settings.title": "设置",
|
||||
"settings.proxy": "代理人",
|
||||
"settings.proxy.auto": "汽车",
|
||||
"settings.proxy.selectedProxy": "选定代理",
|
||||
"settings.proxy.searchEngine": "搜索引擎",
|
||||
"settings.proxy.openPageWith": "打开用",
|
||||
"settings.proxy.openPageWith.embed": "嵌入",
|
||||
"settings.proxy.openPageWith.newTab": "新标签",
|
||||
"settings.proxy.searxngURL": "Searx 网址",
|
||||
"settings.proxy.transport": "运输",
|
||||
"settings.proxy.wispURL": "Wisp 网址",
|
||||
"settings.proxy.bareURL": "Bare 网址",
|
||||
|
||||
"settings.customization": "定制",
|
||||
"settings.customization.theme": "主题",
|
||||
"settings.customization.theme.Alu": "Alu",
|
||||
"settings.customization.theme.Macchiato": "Macchiato",
|
||||
"settings.customization.theme.Mocha": "Mocha",
|
||||
"settings.customization.language": "语言",
|
||||
|
||||
"settings.cloaking": "隐形",
|
||||
"settings.cloaking.subtext": "更改标签的外观...",
|
||||
"settings.cloaking.updateCloak": "更新斗篷",
|
||||
|
||||
"settings.credits": "致谢",
|
||||
"settings.credits.mochaandmacchiatothemes": "Mocha 和 Macchiato 主题",
|
||||
"settings.credits.jpTranslations": "日语翻译",
|
||||
"settings.credits.ruTranslations": "俄语翻译",
|
||||
"settings.credits.zhTranslations": "中文翻译"
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue