From fdbad76428bf5e8b7accb19fae03df2f9046e5bf Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Mon, 14 Mar 2022 14:37:45 -0300 Subject: [PATCH] Fix location resources. --- packages/editor/package.json | 4 +-- packages/webapp/lang/en.json | 5 +++- packages/webapp/lang/zh.json | 12 ++++----- packages/webapp/package.json | 4 +-- packages/webapp/src/classes/app-i18n/index.ts | 2 +- packages/webapp/src/compiled-lang/en.json | 26 +++++++++++++++++-- packages/webapp/src/compiled-lang/zh.json | 12 ++++----- 7 files changed, 45 insertions(+), 20 deletions(-) diff --git a/packages/editor/package.json b/packages/editor/package.json index b08accde..7d88d4be 100644 --- a/packages/editor/package.json +++ b/packages/editor/package.json @@ -8,8 +8,8 @@ "cy:run": "cypress run", "test:integration": "start-server-and-test 'yarn playground' http-get://localhost:8081 'yarn cy:run'", "test": "yarn test:integration", - "extract": "for lang in {'es','en','fr','de'};do formatjs extract 'src/**/*.ts*' --ignore 'src/@types/**/*' --out-file lang/${lang}.json;done", - "compile": "formatjs compile" + "i18n:extract": "formatjs extract 'src/**/*.ts*' --ignore 'src/@types/**/*' --out-file lang/es.json", + "i18n:compile": "for lang in {'es','en','fr','de','zh','ru'};do formatjs compile lang/${lang}.json --ast --out-file src/compiled-lang/${lang}.json;done" }, "repository": "http://www.wisemapping.com", "author": "Paulo Veiga , Ezequiel Bergamaschi ", diff --git a/packages/webapp/lang/en.json b/packages/webapp/lang/en.json index c744821f..b6dc8426 100644 --- a/packages/webapp/lang/en.json +++ b/packages/webapp/lang/en.json @@ -258,7 +258,7 @@ "defaultMessage": "Add label" }, "label.add-for": { - "defaultMessage": "Editing labels for maps:" + "defaultMessage": "Editing labels for" }, "label.add-placeholder": { "defaultMessage": "Label title" @@ -275,6 +275,9 @@ "label.description": { "defaultMessage": "Use labels to organize your maps." }, + "label.maps-count": { + "defaultMessage": "{count} maps" + }, "label.title": { "defaultMessage": "Add a label" }, diff --git a/packages/webapp/lang/zh.json b/packages/webapp/lang/zh.json index 2629fedd..8fbeab6a 100644 --- a/packages/webapp/lang/zh.json +++ b/packages/webapp/lang/zh.json @@ -1,5 +1,5 @@ { - "account.delete-warning": { + "account.delete-warning警告": { "defaultMessage": "请记住,您将无法访问您添加的任何思维导图。您的所有信息都将被删除,并且无法恢复。" }, "accountinfo.button": { @@ -249,7 +249,7 @@ "defaultMessage": "分享" }, "info.starred": { - "defaultMessage": "星标" + "defaultMessage": "收藏" }, "info.title": { "defaultMessage": "信息" @@ -364,16 +364,16 @@ "defaultMessage": "所有" }, "maps.nav-onwned": { - "defaultMessage": "拥有" + "defaultMessage": "我的" }, "maps.nav-public": { - "defaultMessage": "公共" + "defaultMessage": "公开" }, "maps.nav-shared": { "defaultMessage": "与我分享" }, "maps.nav-starred": { - "defaultMessage": "星标" + "defaultMessage": "收藏" }, "maps.page-title": { "defaultMessage": "我的脑图|WiseMapping" @@ -388,7 +388,7 @@ "defaultMessage": "打开编辑" }, "maps.tooltip-starred": { - "defaultMessage": "星标" + "defaultMessage": "收藏" }, "maps.view": { "defaultMessage": "查看" diff --git a/packages/webapp/package.json b/packages/webapp/package.json index ef72bd5b..050678a5 100644 --- a/packages/webapp/package.json +++ b/packages/webapp/package.json @@ -9,8 +9,8 @@ "lint": "eslint src", "cy:run": "cypress run", "test:integration": "start-server-and-test start http-get://localhost:3000 cy:run", - "extract": "formatjs extract 'src/**/*.ts*' --ignore 'src/@types/**/*' --out-file lang/en.json", - "compile": "formatjs compile", + "i18n:extract": "formatjs extract 'src/**/*.ts*' --ignore 'src/@types/**/*' --out-file lang/en.json", + "i18n:compile": "for lang in {'es','en','fr','de','zh','ru'};do formatjs compile lang/${lang}.json --ast --out-file src/compiled-lang/${lang}.json;done", "test": "yarn test:integration" }, "files": [ diff --git a/packages/webapp/src/classes/app-i18n/index.ts b/packages/webapp/src/classes/app-i18n/index.ts index 48cfa9a2..9dbb79dc 100644 --- a/packages/webapp/src/classes/app-i18n/index.ts +++ b/packages/webapp/src/classes/app-i18n/index.ts @@ -57,7 +57,7 @@ export const Locales = { DE: new Locale('fr', 'Français', require('./../../compiled-lang/fr.json')), // eslint-disable-line FR: new Locale('de', 'Deutsch', require('./../../compiled-lang/de.json')), // eslint-disable-line RU: new Locale('ru', 'Pусский', require('./../../compiled-lang/ru.json')), // eslint-disable-line - ZH: new Locale('zh', '中文', require('./../../compiled-lang/zh.json')), // eslint-disable-line + ZH: new Locale('zh', '中文 (简体)', require('./../../compiled-lang/zh.json')), // eslint-disable-line }; diff --git a/packages/webapp/src/compiled-lang/en.json b/packages/webapp/src/compiled-lang/en.json index b473d642..048200d6 100644 --- a/packages/webapp/src/compiled-lang/en.json +++ b/packages/webapp/src/compiled-lang/en.json @@ -275,6 +275,12 @@ "value": "Image: Get a graphic representation of your map including all colors and shapes." } ], + "export.img-center": [ + { + "type": 0, + "value": "Center and zoom to fit" + } + ], "export.title": [ { "type": 0, @@ -512,7 +518,7 @@ "label.add-for": [ { "type": 0, - "value": "Editing labels for maps:" + "value": "Editing labels for" } ], "label.add-placeholder": [ @@ -545,6 +551,16 @@ "value": "Use labels to organize your maps." } ], + "label.maps-count": [ + { + "type": 1, + "value": "count" + }, + { + "type": 0, + "value": " maps" + } + ], "label.title": [ { "type": 0, @@ -887,6 +903,12 @@ "value": "Last Name" } ], + "registration.page-title": [ + { + "type": 0, + "value": "Registration | WiseMapping" + } + ], "registration.password": [ { "type": 0, @@ -914,7 +936,7 @@ "registration.title": [ { "type": 0, - "value": "Registration | WiseMapping" + "value": "Become a member" } ], "rename.description": [ diff --git a/packages/webapp/src/compiled-lang/zh.json b/packages/webapp/src/compiled-lang/zh.json index b249b5b4..6a386e91 100644 --- a/packages/webapp/src/compiled-lang/zh.json +++ b/packages/webapp/src/compiled-lang/zh.json @@ -1,5 +1,5 @@ { - "account.delete-warning": [ + "account.delete-warning警告": [ { "type": 0, "value": "请记住,您将无法访问您添加的任何思维导图。您的所有信息都将被删除,并且无法恢复。" @@ -500,7 +500,7 @@ "info.starred": [ { "type": 0, - "value": "星标" + "value": "收藏" } ], "info.title": [ @@ -740,13 +740,13 @@ "maps.nav-onwned": [ { "type": 0, - "value": "拥有" + "value": "我的" } ], "maps.nav-public": [ { "type": 0, - "value": "公共" + "value": "公开" } ], "maps.nav-shared": [ @@ -758,7 +758,7 @@ "maps.nav-starred": [ { "type": 0, - "value": "星标" + "value": "收藏" } ], "maps.page-title": [ @@ -788,7 +788,7 @@ "maps.tooltip-starred": [ { "type": 0, - "value": "星标" + "value": "收藏" } ], "maps.view": [