feat(i18n): add support for Vietnamese (Vietnam) language (vi_VN) (#51)

Co-authored-by: Sukharev <57486732+di-sukharev@users.noreply.github.com>
This commit is contained in:
Dang Quang Linh
2023-03-28 10:16:17 +07:00
committed by GitHub
parent bdce94f2ac
commit 284604f6a4
2 changed files with 9 additions and 0 deletions

View File

@@ -7,6 +7,7 @@ import zh_CN from '../i18n/zh_CN.json' assert { type: 'json' };
import zh_TW from '../i18n/zh_TW.json' assert { type: 'json' };
import ja from '../i18n/ja.json' assert { type: 'json' };
import pt_br from '../i18n/pt_br.json' assert { type: 'json' };
import vi_VN from '../i18n/vi_VN.json' assert { type: 'json' };
import es_ES from '../i18n/es_ES.json' assert { type: 'json' };
export enum I18nLocals {
@@ -32,6 +33,7 @@ export const i18n = {
it,
ko,
pt_br,
vi_VN,
es_ES
};
@@ -44,6 +46,7 @@ export const I18N_CONFIG_ALIAS: { [key: string]: string[] } = {
fr: ['fr', 'French', 'française'],
it: ['it', 'Italian', 'italiano'],
pt_br: ['pt_br', 'Portuguese', 'português'],
vi_VN: ['vi_VN', 'Vietnamese', 'tiếng Việt'],
en: ['en', 'English', 'english'],
es_ES: ['es_ES', 'Spanish', 'español'],
};

6
src/i18n/vi_VN.json Normal file
View File

@@ -0,0 +1,6 @@
{
"localLanguage": "vietnamese",
"commitFix": "fix(server.ts): thay đổi chữ viết thường của biến port thành chữ viết hoa PORT",
"commitFeat": "feat(server.ts): thêm hỗ trợ cho biến môi trường process.env.PORT",
"commitDescription": "Biến port đã được đổi tên thành PORT, giúp cải thiện tính nhất quán trong việc đặt tên theo quy ước vì PORT là một hằng số. Hỗ trợ cho biến môi trường cho phép ứng dụng linh hoạt hơn khi có thể chạy trên bất kỳ cổng nào được chỉ định thông qua biến môi trường process.env.PORT."
}