From f90566f2fbd3e28e22cdee67a5a9ad8c6dc00650 Mon Sep 17 00:00:00 2001 From: liyang <1711467488@qq.com> Date: Wed, 22 May 2019 08:53:33 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=9A=E5=9B=BD=E8=AF=AD=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Former-commit-id: eaf2280f24b18f3f68407e2102b1f5e1303a990e [formerly eaf2280f24b18f3f68407e2102b1f5e1303a990e [formerly eaf2280f24b18f3f68407e2102b1f5e1303a990e [formerly eaf2280f24b18f3f68407e2102b1f5e1303a990e [formerly 9dc91cf38de012013013912fcc40b1c5d9cf0871 [formerly 5a523dac50ee3832c2ed3f99683eaf29c7151268]]]]] Former-commit-id: 60a70a22a467a1b6af40a60a8aa537b36ff40266 Former-commit-id: ca85e1476b6e0f3138bbe840fc70ef6d38aa0881 Former-commit-id: 14a1544228265bbe58206188ef182c167c183c15 [formerly 219d178e2271b2a584f949694645683161519373] Former-commit-id: c9719d3a73a148e6958bcca466058b7df8433b1b Former-commit-id: a2896c5587348dca3345c6674602df08578dafec Former-commit-id: 2fdef3c0edd9e86ad00357495ab805fa67e1c987 Former-commit-id: f4e7b80606149e91b9c8e243c0163fb9df3a9201 Former-commit-id: d0f52d1de087791127e7d9cc80ced8fa69dc7925 --- .env | 2 +- locales.babel.REMOVED.git-id | 2 +- src/locales/{zh.json => zh-chs.json} | 0 src/locales/zh-cht.json | 61 ++++++++++++++++++++++++++++ src/locales/zh-cns.json | 61 ++++++++++++++++++++++++++++ vue.config.js | 2 +- 6 files changed, 125 insertions(+), 3 deletions(-) rename src/locales/{zh.json => zh-chs.json} (100%) create mode 100644 src/locales/zh-cht.json create mode 100644 src/locales/zh-cns.json diff --git a/.env b/.env index 3dd46db8..8ad3bfc8 100644 --- a/.env +++ b/.env @@ -1,5 +1,5 @@ VUE_APP_TITLE=D2Admin VUE_APP_API=/api/ VUE_APP_REPO=https://github.com/d2-projects/d2-admin -VUE_APP_I18N_LOCALE=zh +VUE_APP_I18N_LOCALE=zh-chs VUE_APP_I18N_FALLBACK_LOCALE=en diff --git a/locales.babel.REMOVED.git-id b/locales.babel.REMOVED.git-id index aec1c07d..310c0e65 100644 --- a/locales.babel.REMOVED.git-id +++ b/locales.babel.REMOVED.git-id @@ -1 +1 @@ -3ed7a815183f5e10fe6088f907aaec472a1c02c2 \ No newline at end of file +83a2f79af6ca23b301c7f0ce715f285aaea43dea \ No newline at end of file diff --git a/src/locales/zh.json b/src/locales/zh-chs.json similarity index 100% rename from src/locales/zh.json rename to src/locales/zh-chs.json diff --git a/src/locales/zh-cht.json b/src/locales/zh-cht.json new file mode 100644 index 00000000..4951a521 --- /dev/null +++ b/src/locales/zh-cht.json @@ -0,0 +1,61 @@ +{ + "public": { + "error-message": { + "form-not-valid": "表單校驗失敗" + }, + "rules": { + "required": "請輸入{name}" + } + }, + "views": { + "system": { + "login": { + "footer": { + "button": { + "clause": "條款", + "help": "幫助", + "privacy": "隱私" + }, + "copyright": { + "author": "FairyEver", + "content": "2018 D2 Projects 開源組織出品", + "copyright": "Copyright" + } + }, + "form": { + "button": { + "login": "登錄" + }, + "label": { + "code": "驗證碼", + "password": "密碼", + "username": "用戶名" + }, + "placeholder": { + "code": "- - - -", + "password": "密碼", + "username": "用戶名" + }, + "prepend": { + "code": "驗證碼" + } + }, + "motto": { + "text": "時間是一切財富中最寶貴的財富。" + }, + "options": { + "forget-password": "忘記密碼", + "register": "註冊用戶" + }, + "quick-login": { + "dialog": { + "title": "快速選擇用戶" + }, + "toggle-button": { + "text": "快速選擇用戶(測試功能)" + } + } + } + } + } +} diff --git a/src/locales/zh-cns.json b/src/locales/zh-cns.json new file mode 100644 index 00000000..1429fca6 --- /dev/null +++ b/src/locales/zh-cns.json @@ -0,0 +1,61 @@ +{ + "public": { + "error-message": { + "form-not-valid": "表单校验失败" + }, + "rules": { + "required": "请输入{name}" + } + }, + "views": { + "system": { + "login": { + "footer": { + "button": { + "clause": "条款", + "help": "帮助", + "privacy": "隐私" + }, + "copyright": { + "author": "FairyEver", + "content": "2018 D2 Projects 开源组织出品", + "copyright": "Copyright" + } + }, + "form": { + "button": { + "login": "登录" + }, + "label": { + "code": "验证码", + "password": "密码", + "username": "用户名" + }, + "placeholder": { + "code": "- - - -", + "password": "密码", + "username": "用户名" + }, + "prepend": { + "code": "验证码" + } + }, + "motto": { + "text": "时间是一切财富中最宝贵的财富。" + }, + "options": { + "forget-password": "忘记密码", + "register": "注册用户" + }, + "quick-login": { + "dialog": { + "title": "快速选择用户" + }, + "toggle-button": { + "text": "快速选择用户(测试功能)" + } + } + } + } + } +} diff --git a/vue.config.js b/vue.config.js index 10b039bf..cb5c5de8 100644 --- a/vue.config.js +++ b/vue.config.js @@ -110,7 +110,7 @@ module.exports = { // i18n pluginOptions: { i18n: { - locale: 'zh', + locale: 'zh-chs', fallbackLocale: 'en', localeDir: 'locales', enableInSFC: true