From cd15e11ce3a4dee8d1a9e7414d6b1f25a6fdee25 Mon Sep 17 00:00:00 2001 From: MichaelDvP Date: Mon, 12 Sep 2022 19:22:05 +0200 Subject: [PATCH] prepare for polish translation --- interface/package-lock.json | 186 ++++++------ interface/package.json | 4 +- .../src/components/layout/LayoutAuthMenu.tsx | 5 + interface/src/i18n/PL.svg | 1 + interface/src/i18n/i18n-types.ts | 1 + interface/src/i18n/i18n-util.async.ts | 1 + interface/src/i18n/i18n-util.sync.ts | 2 + interface/src/i18n/i18n-util.ts | 1 + interface/src/i18n/pl/index.ts | 265 ++++++++++++++++++ interface/src/project/SettingsApplication.tsx | 1 + src/locale_translations.h | 1 + src/system.cpp | 2 +- 12 files changed, 379 insertions(+), 91 deletions(-) create mode 100644 interface/src/i18n/PL.svg create mode 100644 interface/src/i18n/pl/index.ts diff --git a/interface/package-lock.json b/interface/package-lock.json index 7d88ed7b0..59d2ccd76 100644 --- a/interface/package-lock.json +++ b/interface/package-lock.json @@ -12,9 +12,9 @@ "@emotion/styled": "^11.10.4", "@msgpack/msgpack": "^2.8.0", "@mui/icons-material": "^5.10.3", - "@mui/material": "^5.10.4", + "@mui/material": "^5.10.5", "@table-library/react-table-library": "4.0.18", - "@types/lodash": "^4.14.184", + "@types/lodash": "^4.14.185", "@types/node": "^18.7.16", "@types/react": "^18.0.19", "@types/react-dom": "^18.0.6", @@ -2273,9 +2273,9 @@ "integrity": "sha512-AHPmaAx+RYfZz0eYu6Gviiagpmiyw98ySSlQvCUhVGDRtDFe4DBS0x1bSjdF3gqUDYOczB+yYvBTtEylYSdRhg==" }, "node_modules/@eslint/eslintrc": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.1.tgz", - "integrity": "sha512-OhSY22oQQdw3zgPOOwdoj01l/Dzl1Z+xyUP33tkSN+aqyEhymJCcPHyXt+ylW8FSe0TfRC2VG+ROQOapD0aZSQ==", + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.2.tgz", + "integrity": "sha512-AXYd23w1S/bv3fTs3Lz0vjiYemS08jWkI3hYyS9I1ry+0f+Yjs1wm+sU0BS8qDOPrBIkp4qHYC16I8uVtpLajQ==", "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", @@ -3123,9 +3123,9 @@ } }, "node_modules/@mui/base": { - "version": "5.0.0-alpha.96", - "resolved": "https://registry.npmjs.org/@mui/base/-/base-5.0.0-alpha.96.tgz", - "integrity": "sha512-GZf2YguepLFMWGG8vQNLRl7FlXPDeyxQBYgrkHxwNJYeRw55rrGrJxHzL1iCbk71VZ2IIAIs5IAxNpyHK9iqPQ==", + "version": "5.0.0-alpha.97", + "resolved": "https://registry.npmjs.org/@mui/base/-/base-5.0.0-alpha.97.tgz", + "integrity": "sha512-gvo0hOg/tBzfJ3eDQOGAPBJJU+qTWd0e5zBEMFIkT1ekJqXx14JtIHvheOFU17y9iDciYE256Q8g+tj6a1dcBA==", "dependencies": { "@babel/runtime": "^7.18.9", "@emotion/is-prop-valid": "^1.2.0", @@ -3155,9 +3155,9 @@ } }, "node_modules/@mui/core-downloads-tracker": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-5.10.4.tgz", - "integrity": "sha512-VGekVa9dleJ+ii47+gXvKUV5a11T0nsjXN8bk5NqiJRQWRCAhbTHgsfZuctNcMeLW9FSf2gu6U0k2U6rhABKcA==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-5.10.5.tgz", + "integrity": "sha512-sZYg85rQdlgDYU3V4WcT2Dl+k+y2wYqN04aUvVkFksRR0j81sj6KmfXx4842HJQcq5rjzcTvh4N+yv66XR/9fA==", "funding": { "type": "opencollective", "url": "https://opencollective.com/mui" @@ -3189,14 +3189,14 @@ } }, "node_modules/@mui/material": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.10.4.tgz", - "integrity": "sha512-uwupjunU3p8XxZU4f2zF1GYlwB9GDxW1H05BMDPSh0u+37yLxuQDMMxwQQPUo9jSA5Y22/eR4Y71ScxKU89QHg==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.10.5.tgz", + "integrity": "sha512-VFMadvfA6jqx5DCk2xoBl4bAGyzgmmubJIuB7fUWUZBwYIYL5Ea9SsoFpt5kawA6O2feuj69alDN2fhxPw1MeQ==", "dependencies": { "@babel/runtime": "^7.18.9", - "@mui/base": "5.0.0-alpha.96", - "@mui/core-downloads-tracker": "^5.10.4", - "@mui/system": "^5.10.4", + "@mui/base": "5.0.0-alpha.97", + "@mui/core-downloads-tracker": "^5.10.5", + "@mui/system": "^5.10.5", "@mui/types": "^7.2.0", "@mui/utils": "^5.10.3", "@types/react-transition-group": "^4.4.5", @@ -3259,9 +3259,9 @@ } }, "node_modules/@mui/styled-engine": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-5.10.4.tgz", - "integrity": "sha512-y29qlonPj4wndTjbePk9O6uWp/FBRNXjiMwI64oiYQ+v3E0EkLnADfDn49GAqOJAfN/r7nHbVZBlvLNIcMbgDg==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-5.10.5.tgz", + "integrity": "sha512-6U6tTdf+H1OsjgcFoY12gYPR+qqZ1WHGGIahK5V7JhMkMUgH7ozyiNi8s1LzmwrUlAz1hAAhuO5nBYXku3wWvw==", "dependencies": { "@babel/runtime": "^7.18.9", "@emotion/cache": "^11.10.3", @@ -3290,13 +3290,13 @@ } }, "node_modules/@mui/system": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/system/-/system-5.10.4.tgz", - "integrity": "sha512-fE7LtYStPHPfq7EJXEVLQGvz23pS5YwSI7A4mWEFyyW21hHUh0c1opZXb7caHJsUTiBoC22W7R8GGfbVdSOnZA==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/system/-/system-5.10.5.tgz", + "integrity": "sha512-GUPiDVZTKp9yH3FVeLSIw3Bqsyl7qLxtAK1ZiZmC8e+zdH7bcnZZXvWK3vPIbx35ZyhQpvAOWQFpiF9TjdA77w==", "dependencies": { "@babel/runtime": "^7.18.9", "@mui/private-theming": "^5.10.3", - "@mui/styled-engine": "^5.10.4", + "@mui/styled-engine": "^5.10.5", "@mui/types": "^7.2.0", "@mui/utils": "^5.10.3", "clsx": "^1.2.1", @@ -4003,9 +4003,9 @@ "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==" }, "node_modules/@types/lodash": { - "version": "4.14.184", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.184.tgz", - "integrity": "sha512-RoZphVtHbxPZizt4IcILciSWiC6dcn+eZ8oX9IWEYfDMcocdd42f7NPI6fQj+6zI8y4E0L7gu2pcZKLGTRaV9Q==" + "version": "4.14.185", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.185.tgz", + "integrity": "sha512-evMDG1bC4rgQg4ku9tKpuMh5iBNEwNa3tf9zRHdP1qlv+1WUg44xat4IxCE14gIpZRGUUWAx2VhItCZc25NfMA==" }, "node_modules/@types/mime": { "version": "3.0.1", @@ -4953,9 +4953,9 @@ } }, "node_modules/autoprefixer": { - "version": "10.4.8", - "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.8.tgz", - "integrity": "sha512-75Jr6Q/XpTqEf6D2ltS5uMewJIx5irCU1oBYJrWjFenq/m12WRRrz6g15L1EIoYvPLXTbEry7rDOwrcYNj77xw==", + "version": "10.4.9", + "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.9.tgz", + "integrity": "sha512-Uu67eduPEmOeA0vyJby5ghu1AAELCCNSsLAjK+lz6kYzNM5sqnBO36MqfsjhPjQF/BaJM5U/UuFYyl7PavY/wQ==", "funding": [ { "type": "opencollective", @@ -4968,7 +4968,7 @@ ], "dependencies": { "browserslist": "^4.21.3", - "caniuse-lite": "^1.0.30001373", + "caniuse-lite": "^1.0.30001394", "fraction.js": "^4.2.0", "normalize-range": "^0.1.2", "picocolors": "^1.0.0", @@ -5546,9 +5546,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001393", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001393.tgz", - "integrity": "sha512-N/od11RX+Gsk+1qY/jbPa0R6zJupEa0lxeBG598EbrtblxVCTJsQwbRBm6+V+rxpc5lHKdsXb9RY83cZIPLseA==", + "version": "1.0.30001397", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001397.tgz", + "integrity": "sha512-SW9N2TbCdLf0eiNDRrrQXx2sOkaakNZbCjgNpPyMJJbiOrU5QzMIrXOVMRM1myBXTD5iTkdrtU/EguCrBocHlA==", "funding": [ { "type": "opencollective", @@ -6984,11 +6984,11 @@ } }, "node_modules/eslint": { - "version": "8.23.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.23.0.tgz", - "integrity": "sha512-pBG/XOn0MsJcKcTRLr27S5HpzQo4kLr+HjLQIyK4EiCsijDl/TB+h5uEuJU6bQ8Edvwz1XWOjpaP2qgnXGpTcA==", + "version": "8.23.1", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.23.1.tgz", + "integrity": "sha512-w7C1IXCc6fNqjpuYd0yPlcTKKmHlHHktRkzmBPZ+7cvNBQuiNjx0xaMTjAJGCafJhQkrFJooREv0CtrVzmHwqg==", "dependencies": { - "@eslint/eslintrc": "^1.3.1", + "@eslint/eslintrc": "^1.3.2", "@humanwhocodes/config-array": "^0.10.4", "@humanwhocodes/gitignore-to-minimatch": "^1.0.2", "@humanwhocodes/module-importer": "^1.0.1", @@ -7007,7 +7007,6 @@ "fast-deep-equal": "^3.1.3", "file-entry-cache": "^6.0.1", "find-up": "^5.0.0", - "functional-red-black-tree": "^1.0.1", "glob-parent": "^6.0.1", "globals": "^13.15.0", "globby": "^11.1.0", @@ -7016,6 +7015,7 @@ "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", + "js-sdsl": "^4.1.4", "js-yaml": "^4.1.0", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.4.1", @@ -9107,9 +9107,9 @@ } }, "node_modules/is-callable": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", - "integrity": "sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w==", + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.5.tgz", + "integrity": "sha512-ZIWRujF6MvYGkEuHMYtFRkL2wAtFw89EHfKlXrkPkjQZZRWeh9L1q3SV13NIfHnqxugjLvAOkEHx9mb1zcMnEw==", "engines": { "node": ">= 0.4" }, @@ -11426,6 +11426,11 @@ "url": "https://github.com/chalk/supports-color?sponsor=1" } }, + "node_modules/js-sdsl": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/js-sdsl/-/js-sdsl-4.1.4.tgz", + "integrity": "sha512-Y2/yD55y5jteOAmY50JbUZYwk3CP3wnLPEZnlR1w9oKhITrBEtAxwuWKebFf8hMrPMgbYwFoWK/lH2sBkErELw==" + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -16518,9 +16523,9 @@ } }, "node_modules/update-browserslist-db": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.7.tgz", - "integrity": "sha512-iN/XYesmZ2RmmWAiI4Z5rq0YqSiv0brj9Ce9CfhNE4xIW2h+MFxcgkxIzZ+ShkFPUkjU3gQ+3oypadD3RAMtrg==", + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.8.tgz", + "integrity": "sha512-GHg7C4M7oJSJYW/ED/5QOJ7nL/E0lwTOBGsOorA7jqHr8ExUhPfwAotIAmdSw/LWv3SMLSNpzTAgeLG9zaZKTA==", "funding": [ { "type": "opencollective", @@ -19006,9 +19011,9 @@ "integrity": "sha512-AHPmaAx+RYfZz0eYu6Gviiagpmiyw98ySSlQvCUhVGDRtDFe4DBS0x1bSjdF3gqUDYOczB+yYvBTtEylYSdRhg==" }, "@eslint/eslintrc": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.1.tgz", - "integrity": "sha512-OhSY22oQQdw3zgPOOwdoj01l/Dzl1Z+xyUP33tkSN+aqyEhymJCcPHyXt+ylW8FSe0TfRC2VG+ROQOapD0aZSQ==", + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.2.tgz", + "integrity": "sha512-AXYd23w1S/bv3fTs3Lz0vjiYemS08jWkI3hYyS9I1ry+0f+Yjs1wm+sU0BS8qDOPrBIkp4qHYC16I8uVtpLajQ==", "requires": { "ajv": "^6.12.4", "debug": "^4.3.2", @@ -19631,9 +19636,9 @@ "integrity": "sha512-h9u4u/jiIRKbq25PM+zymTyW6bhTzELvOoUd+AvYriWOAKpLGnIamaET3pnHYoI5iYphAHBI4ayx0MehR+VVPQ==" }, "@mui/base": { - "version": "5.0.0-alpha.96", - "resolved": "https://registry.npmjs.org/@mui/base/-/base-5.0.0-alpha.96.tgz", - "integrity": "sha512-GZf2YguepLFMWGG8vQNLRl7FlXPDeyxQBYgrkHxwNJYeRw55rrGrJxHzL1iCbk71VZ2IIAIs5IAxNpyHK9iqPQ==", + "version": "5.0.0-alpha.97", + "resolved": "https://registry.npmjs.org/@mui/base/-/base-5.0.0-alpha.97.tgz", + "integrity": "sha512-gvo0hOg/tBzfJ3eDQOGAPBJJU+qTWd0e5zBEMFIkT1ekJqXx14JtIHvheOFU17y9iDciYE256Q8g+tj6a1dcBA==", "requires": { "@babel/runtime": "^7.18.9", "@emotion/is-prop-valid": "^1.2.0", @@ -19646,9 +19651,9 @@ } }, "@mui/core-downloads-tracker": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-5.10.4.tgz", - "integrity": "sha512-VGekVa9dleJ+ii47+gXvKUV5a11T0nsjXN8bk5NqiJRQWRCAhbTHgsfZuctNcMeLW9FSf2gu6U0k2U6rhABKcA==" + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/core-downloads-tracker/-/core-downloads-tracker-5.10.5.tgz", + "integrity": "sha512-sZYg85rQdlgDYU3V4WcT2Dl+k+y2wYqN04aUvVkFksRR0j81sj6KmfXx4842HJQcq5rjzcTvh4N+yv66XR/9fA==" }, "@mui/icons-material": { "version": "5.10.3", @@ -19659,14 +19664,14 @@ } }, "@mui/material": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.10.4.tgz", - "integrity": "sha512-uwupjunU3p8XxZU4f2zF1GYlwB9GDxW1H05BMDPSh0u+37yLxuQDMMxwQQPUo9jSA5Y22/eR4Y71ScxKU89QHg==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.10.5.tgz", + "integrity": "sha512-VFMadvfA6jqx5DCk2xoBl4bAGyzgmmubJIuB7fUWUZBwYIYL5Ea9SsoFpt5kawA6O2feuj69alDN2fhxPw1MeQ==", "requires": { "@babel/runtime": "^7.18.9", - "@mui/base": "5.0.0-alpha.96", - "@mui/core-downloads-tracker": "^5.10.4", - "@mui/system": "^5.10.4", + "@mui/base": "5.0.0-alpha.97", + "@mui/core-downloads-tracker": "^5.10.5", + "@mui/system": "^5.10.5", "@mui/types": "^7.2.0", "@mui/utils": "^5.10.3", "@types/react-transition-group": "^4.4.5", @@ -19688,9 +19693,9 @@ } }, "@mui/styled-engine": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-5.10.4.tgz", - "integrity": "sha512-y29qlonPj4wndTjbePk9O6uWp/FBRNXjiMwI64oiYQ+v3E0EkLnADfDn49GAqOJAfN/r7nHbVZBlvLNIcMbgDg==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/styled-engine/-/styled-engine-5.10.5.tgz", + "integrity": "sha512-6U6tTdf+H1OsjgcFoY12gYPR+qqZ1WHGGIahK5V7JhMkMUgH7ozyiNi8s1LzmwrUlAz1hAAhuO5nBYXku3wWvw==", "requires": { "@babel/runtime": "^7.18.9", "@emotion/cache": "^11.10.3", @@ -19699,13 +19704,13 @@ } }, "@mui/system": { - "version": "5.10.4", - "resolved": "https://registry.npmjs.org/@mui/system/-/system-5.10.4.tgz", - "integrity": "sha512-fE7LtYStPHPfq7EJXEVLQGvz23pS5YwSI7A4mWEFyyW21hHUh0c1opZXb7caHJsUTiBoC22W7R8GGfbVdSOnZA==", + "version": "5.10.5", + "resolved": "https://registry.npmjs.org/@mui/system/-/system-5.10.5.tgz", + "integrity": "sha512-GUPiDVZTKp9yH3FVeLSIw3Bqsyl7qLxtAK1ZiZmC8e+zdH7bcnZZXvWK3vPIbx35ZyhQpvAOWQFpiF9TjdA77w==", "requires": { "@babel/runtime": "^7.18.9", "@mui/private-theming": "^5.10.3", - "@mui/styled-engine": "^5.10.4", + "@mui/styled-engine": "^5.10.5", "@mui/types": "^7.2.0", "@mui/utils": "^5.10.3", "clsx": "^1.2.1", @@ -20182,9 +20187,9 @@ "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==" }, "@types/lodash": { - "version": "4.14.184", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.184.tgz", - "integrity": "sha512-RoZphVtHbxPZizt4IcILciSWiC6dcn+eZ8oX9IWEYfDMcocdd42f7NPI6fQj+6zI8y4E0L7gu2pcZKLGTRaV9Q==" + "version": "4.14.185", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.185.tgz", + "integrity": "sha512-evMDG1bC4rgQg4ku9tKpuMh5iBNEwNa3tf9zRHdP1qlv+1WUg44xat4IxCE14gIpZRGUUWAx2VhItCZc25NfMA==" }, "@types/mime": { "version": "3.0.1", @@ -20915,12 +20920,12 @@ "integrity": "sha512-7prDjvt9HmqiZ0cl5CRjtS84sEyhsHP2coDkaZKRKVfCDo9s7iw7ChVmar78Gu9pC4SoR/28wFu/G5JJhTnqEg==" }, "autoprefixer": { - "version": "10.4.8", - "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.8.tgz", - "integrity": "sha512-75Jr6Q/XpTqEf6D2ltS5uMewJIx5irCU1oBYJrWjFenq/m12WRRrz6g15L1EIoYvPLXTbEry7rDOwrcYNj77xw==", + "version": "10.4.9", + "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.9.tgz", + "integrity": "sha512-Uu67eduPEmOeA0vyJby5ghu1AAELCCNSsLAjK+lz6kYzNM5sqnBO36MqfsjhPjQF/BaJM5U/UuFYyl7PavY/wQ==", "requires": { "browserslist": "^4.21.3", - "caniuse-lite": "^1.0.30001373", + "caniuse-lite": "^1.0.30001394", "fraction.js": "^4.2.0", "normalize-range": "^0.1.2", "picocolors": "^1.0.0", @@ -21359,9 +21364,9 @@ } }, "caniuse-lite": { - "version": "1.0.30001393", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001393.tgz", - "integrity": "sha512-N/od11RX+Gsk+1qY/jbPa0R6zJupEa0lxeBG598EbrtblxVCTJsQwbRBm6+V+rxpc5lHKdsXb9RY83cZIPLseA==" + "version": "1.0.30001397", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001397.tgz", + "integrity": "sha512-SW9N2TbCdLf0eiNDRrrQXx2sOkaakNZbCjgNpPyMJJbiOrU5QzMIrXOVMRM1myBXTD5iTkdrtU/EguCrBocHlA==" }, "case-sensitive-paths-webpack-plugin": { "version": "2.4.0", @@ -22398,11 +22403,11 @@ } }, "eslint": { - "version": "8.23.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.23.0.tgz", - "integrity": "sha512-pBG/XOn0MsJcKcTRLr27S5HpzQo4kLr+HjLQIyK4EiCsijDl/TB+h5uEuJU6bQ8Edvwz1XWOjpaP2qgnXGpTcA==", + "version": "8.23.1", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.23.1.tgz", + "integrity": "sha512-w7C1IXCc6fNqjpuYd0yPlcTKKmHlHHktRkzmBPZ+7cvNBQuiNjx0xaMTjAJGCafJhQkrFJooREv0CtrVzmHwqg==", "requires": { - "@eslint/eslintrc": "^1.3.1", + "@eslint/eslintrc": "^1.3.2", "@humanwhocodes/config-array": "^0.10.4", "@humanwhocodes/gitignore-to-minimatch": "^1.0.2", "@humanwhocodes/module-importer": "^1.0.1", @@ -22421,7 +22426,6 @@ "fast-deep-equal": "^3.1.3", "file-entry-cache": "^6.0.1", "find-up": "^5.0.0", - "functional-red-black-tree": "^1.0.1", "glob-parent": "^6.0.1", "globals": "^13.15.0", "globby": "^11.1.0", @@ -22430,6 +22434,7 @@ "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", + "js-sdsl": "^4.1.4", "js-yaml": "^4.1.0", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.4.1", @@ -23922,9 +23927,9 @@ } }, "is-callable": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", - "integrity": "sha512-nsuwtxZfMX67Oryl9LCQ+upnC0Z0BgpwntpS89m1H/TLF0zNfzfLMV/9Wa/6MZsj0acpEjAO0KF1xT6ZdLl95w==" + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.5.tgz", + "integrity": "sha512-ZIWRujF6MvYGkEuHMYtFRkL2wAtFw89EHfKlXrkPkjQZZRWeh9L1q3SV13NIfHnqxugjLvAOkEHx9mb1zcMnEw==" }, "is-core-module": { "version": "2.10.0", @@ -25585,6 +25590,11 @@ } } }, + "js-sdsl": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/js-sdsl/-/js-sdsl-4.1.4.tgz", + "integrity": "sha512-Y2/yD55y5jteOAmY50JbUZYwk3CP3wnLPEZnlR1w9oKhITrBEtAxwuWKebFf8hMrPMgbYwFoWK/lH2sBkErELw==" + }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -29133,9 +29143,9 @@ "integrity": "sha512-aZwGpamFO61g3OlfT7OQCHqhGnW43ieH9WZeP7QxN/G/jS4jfqUkZxoryvJgVPEcrl5NL/ggHsSmLMHuH64Lhg==" }, "update-browserslist-db": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.7.tgz", - "integrity": "sha512-iN/XYesmZ2RmmWAiI4Z5rq0YqSiv0brj9Ce9CfhNE4xIW2h+MFxcgkxIzZ+ShkFPUkjU3gQ+3oypadD3RAMtrg==", + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.8.tgz", + "integrity": "sha512-GHg7C4M7oJSJYW/ED/5QOJ7nL/E0lwTOBGsOorA7jqHr8ExUhPfwAotIAmdSw/LWv3SMLSNpzTAgeLG9zaZKTA==", "requires": { "escalade": "^3.1.1", "picocolors": "^1.0.0" diff --git a/interface/package.json b/interface/package.json index b77386526..a062f18ae 100644 --- a/interface/package.json +++ b/interface/package.json @@ -8,9 +8,9 @@ "@emotion/styled": "^11.10.4", "@msgpack/msgpack": "^2.8.0", "@mui/icons-material": "^5.10.3", - "@mui/material": "^5.10.4", + "@mui/material": "^5.10.5", "@table-library/react-table-library": "4.0.18", - "@types/lodash": "^4.14.184", + "@types/lodash": "^4.14.185", "@types/node": "^18.7.16", "@types/react": "^18.0.19", "@types/react-dom": "^18.0.6", diff --git a/interface/src/components/layout/LayoutAuthMenu.tsx b/interface/src/components/layout/LayoutAuthMenu.tsx index 5f44a88ec..f32df06c0 100644 --- a/interface/src/components/layout/LayoutAuthMenu.tsx +++ b/interface/src/components/layout/LayoutAuthMenu.tsx @@ -27,6 +27,7 @@ import { ReactComponent as NLflag } from '../../i18n/NL.svg'; import { ReactComponent as DEflag } from '../../i18n/DE.svg'; import { ReactComponent as GBflag } from '../../i18n/GB.svg'; import { ReactComponent as SEflag } from '../../i18n/SE.svg'; +import { ReactComponent as PLflag } from '../../i18n/PL.svg'; const ItemTypography = styled(Typography)({ maxWidth: '250px', @@ -87,6 +88,10 @@ const LayoutAuthMenu: FC = () => {  SE + + +  PL + \ No newline at end of file diff --git a/interface/src/i18n/i18n-types.ts b/interface/src/i18n/i18n-types.ts index 83a8f773f..dfde84ba2 100644 --- a/interface/src/i18n/i18n-types.ts +++ b/interface/src/i18n/i18n-types.ts @@ -9,6 +9,7 @@ export type Locales = | 'de' | 'en' | 'nl' + | 'pl' | 'se' export type Translation = RootTranslation diff --git a/interface/src/i18n/i18n-util.async.ts b/interface/src/i18n/i18n-util.async.ts index 7f8ac7330..9f9da27b6 100644 --- a/interface/src/i18n/i18n-util.async.ts +++ b/interface/src/i18n/i18n-util.async.ts @@ -9,6 +9,7 @@ const localeTranslationLoaders = { de: () => import('./de'), en: () => import('./en'), nl: () => import('./nl'), + pl: () => import('./pl'), se: () => import('./se'), } diff --git a/interface/src/i18n/i18n-util.sync.ts b/interface/src/i18n/i18n-util.sync.ts index 2dd390d3f..a87bed14b 100644 --- a/interface/src/i18n/i18n-util.sync.ts +++ b/interface/src/i18n/i18n-util.sync.ts @@ -8,12 +8,14 @@ import { loadedFormatters, loadedLocales, locales } from './i18n-util' import de from './de' import en from './en' import nl from './nl' +import pl from './pl' import se from './se' const localeTranslations = { de, en, nl, + pl, se, } diff --git a/interface/src/i18n/i18n-util.ts b/interface/src/i18n/i18n-util.ts index 98632d6e6..f893ef2e6 100644 --- a/interface/src/i18n/i18n-util.ts +++ b/interface/src/i18n/i18n-util.ts @@ -12,6 +12,7 @@ export const locales: Locales[] = [ 'de', 'en', 'nl', + 'pl', 'se' ] diff --git a/interface/src/i18n/pl/index.ts b/interface/src/i18n/pl/index.ts new file mode 100644 index 000000000..c70c47e0e --- /dev/null +++ b/interface/src/i18n/pl/index.ts @@ -0,0 +1,265 @@ +import type { BaseTranslation } from '../i18n-types'; + +const en: BaseTranslation = { + LANGUAGE: 'Language', + RETRY: 'Retry', + LOADING: 'Loading', + IS_REQUIRED: 'is required', + SIGN_IN: 'Sign In', + SIGN_OUT: 'Sign Out', + USERNAME: 'Username', + PASSWORD: 'Password', + DASHBOARD: 'Dashboard', + SETTINGS: 'Settings', + SAVED: 'saved', + HELP: 'Help', + LOGGED_IN: 'Logged in as {name}', + PLEASE_SIGNIN: 'Please sign in to continue', + UPLOAD_SUCCESSFUL: 'Upload successful', + DOWNLOAD_SUCCESSFUL: 'Download successful', + INVALID_LOGIN: 'Invalid login details', + NETWORK: 'Network', + SECURITY: 'Security', + ONOFF_CAP: 'ON/OFF', + ONOFF: 'on/off', + TYPE: 'Type', + DESCRIPTION: 'Description', + ENTITIES: 'Entities', + REFRESH: 'Refresh', + EXPORT: 'Export', + DEVICE_DETAILS: 'Device Details', + BRAND: 'Brand', + ENTITY_NAME: 'Entity Name', + VALUE: 'Value', + SHOW_FAV: 'only show favorites', + DEVICE_SENSOR_DATA: 'Device and Sensor Data', + DEVICES_SENSORS: 'Devices & Sensors', + ATTACHED_SENSORS: 'Attached EMS-ESP Sensors', + RUN_COMMAND: 'Call Command', + CHANGE_VALUE: 'Change Value', + CANCEL: 'Cancel', + RESET: 'Reset', + SEND: 'Send', + SAVE: 'Save', + REMOVE: 'Remove', + PROBLEM_UPDATING: 'Problem updating', + PROBLEM_LOADING: 'Problem loading', + ACCESS_DENIED: 'Access Denied', + ANALOG_SENSOR: 'Analog Sensor', + ANALOG_SENSORS: 'Analog Sensors', + UPDATED: 'Updated', + UPDATE: 'Update', + REMOVED: 'Removed', + DELETION: 'Deletion', + OFFSET: 'Offset', + FACTOR: 'Factor', + FREQ: 'Frequency', + STARTVALUE: 'Start value', + WARN_GPIO: 'Warning: be careful when assigning a GPIO!', + EDIT: 'Edit', + TEMP_SENSOR: 'Temperature Sensor', + TEMP_SENSORS: 'Temperature Sensors', + WRITE_COMMAND: 'Write command {cmd}', + EMS_BUS_WARNING: + 'EMS bus disconnected. If this warning still persists after a few seconds please check settings and board profile', + EMS_BUS_SCANNING: 'Scanning for EMS devices...', + CONNECTED: 'Connected', + TX_ISSUES: 'Tx issues - try a different Tx Mode', + DISCONNECTED: 'Disconnected', + EMS_SCAN: 'Are you sure you want to initiate a full device scan of the EMS bus?', + EMS_BUS_STATUS: 'EMS Bus Status', + ACTIVE_DEVICES: 'Active Devices & Sensors', + DEVICE: 'Device', + SUCCESS: 'SUCCESS', + FAIL: 'FAIL', + QUALITY: 'QUALITY', + SCAN_DEVICES: 'Scan for new devices', + EMS_BUS_STATUS_TITLE: 'EMS Bus & Activity Status', + SCAN: 'Scan', + STATUS_NAMES: [ + 'EMS Telegrams Received (Rx)', + 'EMS Reads (Tx)', + 'EMS Writes (Tx)', + 'Temperature Sensor Reads', + 'Analog Sensor Reads', + 'MQTT Publishes', + 'API Calls', + 'Syslog Messages' + ], + NUM_DEVICES: '{num} Device{{s}}', + NUM_TEMP_SENSORS: '{num} Temperature Sensor{{s}}', + NUM_ANALOG_SENSORS: '{num} Analog Sensor{{s}}', + NUM_DAYS: '{num} Day{{s}}', + NUM_SECONDS: '{num} Second{{s}}', + NUM_HOURS: '{num} Hour{{s}}', + NUM_MINUTES: '{num} Minute{{s}}', + APPLICATION_SETTINGS: 'Application Settings', + CUSTOMIZATION: 'Customization', + APPLICATION_RESTARTING: 'EMS-ESP is restarting', + BOARD_PROFILE_TEXT: + 'Select a pre-configured interface board profile from the list below or choose Custom to configure your own hardware settings', + BOARD_PROFILE: 'Board Profile', + BUTTON: 'Button', + TEMPERATURE: 'Temperature', + DISABLED: 'disabled', + GENERAL_OPTIONS: 'General Options', + LANGUAGE_ENTITIES: 'Language (for device entities)', + HIDE_LED: 'Hide LED', + ENABLE_TELNET: 'Enable Telnet Console', + ENABLE_ANALOG: 'Enable Analog Sensors', + CONVERT_FAHRENHEIT: 'Convert temperature values to Fahrenheit', + BYPASS_TOKEN: 'Bypass Access Token authorization on API calls', + READONLY: 'Enable read-only mode (blocks all outgoing EMS Tx Write commands)', + UNDERCLOCK_CPU: 'Underclock CPU speed', + ENABLE_SHOWER_TIMER: 'Enable Shower Timer', + ENABLE_SHOWER_ALERT: 'Enable Shower Alert', + TRIGGER_TIME: 'Trigger Time', + COLD_SHOT_DURATION: 'Cold Shot Duration', + FORMATTING_OPTIONS: 'Formatting Options', + BOOLEAN_FORMAT_DASHBOARD: 'Boolean Format Dashboard', + BOOLEAN_FORMAT_API: 'Boolean Format API/MQTT', + ENUM_FORMAT: 'Enum Format API/MQTT', + INDEX: 'Index', + ENABLE_PARASITE: 'Enable parasite power', + LOGGING: 'Logging', + LOG_HEX: 'Log EMS telegrams in hexadecimal', + ENABLE_SYSLOG: 'Enable Syslog', + MARK_INTERVAL: 'Mark Interval', + SECONDS: 'seconds', + MINUTES: 'minutes', + RESTART: 'Restart', + HOURS: 'hours', + RESTART_TEXT: 'EMS-ESP needs to be restarted to apply changed system settings', + COMMAND: 'Command', + CUSTOMIZATIONS_RESTART: 'All customizations have been removed. Restarting...', + CUSTOMIZATIONS_FULL: 'Selected entities exceeded limit. Please save in batches', + CUSTOMIZATIONS_SAVED: 'Customizations saved', + CUSTOMIZATIONS_HELP_1: 'Select a device and customize the entities options or click to rename', + CUSTOMIZATIONS_HELP_2: 'mark as favorite', + CUSTOMIZATIONS_HELP_3: 'disable write action', + CUSTOMIZATIONS_HELP_4: 'exclude from MQTT and API', + CUSTOMIZATIONS_HELP_5: 'hide from Dashboard', + SELECT_DEVICE: 'Select a device', + SET_ALL: 'set all', + OPTIONS: 'Options', + NAME: 'Name', + CUSTOMIZATIONS_RESET: + 'Are you sure you want remove all customizations including the custom settings of the Temperature and Analog sensors?', + DEVICE_ENTITIES: 'Device Entities', + USER_CUSTOMIZATION: 'User Customization', + SUPPORT_INFORMATION: 'Support Information', + CLICK_HERE: 'Click Here', + HELP_INFORMATION_1: 'Visit the online wiki to get instructions on how to configure EMS-ESP', + HELP_INFORMATION_2: 'For live community chat join our Discord server', + HELP_INFORMATION_3: 'To request a feature or report a bug', + HELP_INFORMATION_4: 'remember to download and attach your system information for a faster response when reporting an issue', + HELP_INFORMATION_5: + "EMS-ESP is a free and open-source project. Please support its future development by giving it a star on Github!", + SUPPORT_INFO: 'Support Info', + UPLOAD: 'Upload', + DOWNLOAD: 'Download', + ABORTED: 'aborted', + FAILED: 'failed', + SUCCESSFUL: 'successful', + SYSTEM: 'System', + LOG: 'Log', + STATUS: 'Status', + UPLOAD_DOWNLOAD: 'Upload/Download', + SYSTEM_VERSION_RUNNING: 'You are currently running version', + SYSTEM_APPLY_FIRMWARE: 'to apply the new firmware', + CLOSE: 'Close', + USE: 'Use', + FACTORY_RESET: 'Factory Reset', + SYSTEM_FACTORY_TEXT: 'Device has been factory reset and will now restart', + SYSTEM_FACTORY_TEXT_DIALOG: 'Are you sure you want to reset the device to its factory defaults?', + VERSION_CHECK: 'Version Check', + THE_LATEST: 'The latest', + PLATFORM: 'Device (Platform / SDK)', + UPTIME: 'System Uptime', + CPU_FREQ: 'CPU Frequency', + HEAP: 'Heap (Free / Max Alloc)', + PSRAM: 'PSRAM (Size / Free)', + FLASH: 'Flash Chip (Size / Speed)', + FILESYSTEM: 'File System (Used / Total)', + BUFFER_SIZE: 'Buffer Size', + COMPACT: 'Compact', + ENABLE_OTA: 'Enable OTA Updates', + DOWNLOAD_CUSTOMIZATION_TEXT: 'Download the entity customizations', + DOWNLOAD_SETTINGS_TEXT: + 'Download the application settings. Be careful when sharing your settings as this file contains passwords and other sensitive system information', + UPLOAD_TEXT: 'Upload a new firmware (.bin) file, settings or customizations (.json) file below', + UPLOADING: 'Uploading', + UPLOAD_DROP_TEXT: 'Drop file or click here', + ERROR: 'Unexpected Error, please try again', + TIME_SET: 'Time set', + MANAGE_USERS: 'Manage Users', + IS_ADMIN: 'is Admin', + USER_WARNING: 'You must have at least one admin user configured', + ADD: 'Add', + ACCESS_TOKEN_FOR: 'Access Token for', + ACCESS_TOKEN_TEXT: + 'The token below is used with REST API calls that require authorization. It can be passed either as a Bearer token in the Authorization header or in the access_token URL query parameter.', + GENERATING_TOKEN: 'Generating token', + USER: 'User', + MODIFY: 'Modify', + SU_TEXT: + 'The su (super user) password is used to sign authentication tokens and also enable admin privileges within the Console.', + NOT_ENABLED: 'Not enabled', + ERRORS: 'Errors', + DISCONNECT_REASON: 'Disconnect Reason', + ENABLE_MQTT: 'Enable MQTT', + OPTIONAL: 'Optional', + FORMATTING: 'Formatting', + FORMAT: 'Format', + MQTT_NEST_1: 'Nested in a single topic', + MQTT_NEST_2: 'As individual topics', + MQTT_RESPONSE: 'Publish command output to a `response` topic', + MQTT_PUBLISH_TEXT_1: 'Publish single value topics on change', + MQTT_PUBLISH_TEXT_2: 'Publish to command topics (ioBroker)', + MQTT_PUBLISH_TEXT_3: 'Enable MQTT Discovery (Home Assistant, Domoticz)', + MQTT_PUBLISH_TEXT_4: 'Prefix for the Discovery topics', + MQTT_PUBLISH_INTERVALS: 'Publish Intervals', + MQTT_INT_BOILER: 'Boilers and Heat Pumps', + MQTT_INT_THERMOSTATS: 'Thermostats', + MQTT_INT_SOLAR: 'Solar Modules', + MQTT_INT_MIXER: 'Mixer Modules', + DEFAULT: 'Default', + MQTT_CLEAN_SESSION: 'Set Clean Session', + MQTT_RETAIN_FLAG: 'Always set Retain flag', + INACTIVE: 'Inactive', + ACTIVE: 'Active', + UNKNOWN: 'Unknown', + SET_TIME: 'Set Time', + SET_TIME_TEXT: 'Enter local date and time below to set the time', + LOCAL_TIME: 'Local Time', + UTC_TIME: 'UTC Time', + ENABLE_NTP: 'Enable NTP', + TIME_ZONE: 'Time Zone', + ACCESS_POINT: 'Access Point', + AP_PROVIDE: 'Enable Access Point', + AP_PROVIDE_TEXT_1: 'always', + AP_PROVIDE_TEXT_2: 'when WiFi is disconnected', + AP_PROVIDE_TEXT_3: 'never', + AP_PREFERRED_CHANNEL: 'Preferred Channel', + AP_HIDE_SSID: 'Hide SSID', + NETWORK_SCAN: 'Scan WiFi Networks', + IDLE: 'Idle', + LOST: 'Lost', + SCANNING: 'Scanning', + SCAN_AGAIN: 'Scan again', + NETWORK_SCANNER: 'Network Scanner', + NETWORK_NO_WIFI: 'No WiFi networks found', + NETWORK_BLANK_SSID: 'leave blank to disable WiFi', + POWER: 'Power', + NETWORK_DISABLE_SLEEP: 'Disable WiFi Sleep Mode', + NETWORK_LOW_BAND: 'Use Lower WiFi Bandwidth', + NETWORK_USE_DNS: 'Enable mDNS Service', + NETWORK_ENABLE_IPV6: 'Enable IPv6 support', + NETWORK_FIXED_IP: 'Use Fixed IP address', + ADMIN: 'Admin', + GUEST: 'Guest', + NEW: 'New', + RENAME: 'Rename' +}; + +export default en; diff --git a/interface/src/project/SettingsApplication.tsx b/interface/src/project/SettingsApplication.tsx index a9ef1bf48..f27fa1b2f 100644 --- a/interface/src/project/SettingsApplication.tsx +++ b/interface/src/project/SettingsApplication.tsx @@ -342,6 +342,7 @@ const SettingsApplication: FC = () => { Deutsch (DE) Nederlands (NL) Svenska (SE) + Polski (PL) {data.led_gpio !== 0 && ( diff --git a/src/locale_translations.h b/src/locale_translations.h index 2407741bd..6252bfb0b 100644 --- a/src/locale_translations.h +++ b/src/locale_translations.h @@ -23,6 +23,7 @@ #define EMSESP_LOCALE_DE "de" #define EMSESP_LOCALE_NL "nl" #define EMSESP_LOCALE_SE "se" +#define EMSESP_LOCALE_PL "pl" // translations are in order en, de,nl, se.... // if there is no translation, it will default to en diff --git a/src/system.cpp b/src/system.cpp index 3db7557aa..7edefddab 100644 --- a/src/system.cpp +++ b/src/system.cpp @@ -42,7 +42,7 @@ namespace emsesp { // Languages supported. Note: the order is important and must match locale_translations.h -const char * const languages[] = {EMSESP_LOCALE_EN, EMSESP_LOCALE_DE, EMSESP_LOCALE_NL, EMSESP_LOCALE_SE}; +const char * const languages[] = {EMSESP_LOCALE_EN, EMSESP_LOCALE_DE, EMSESP_LOCALE_NL, EMSESP_LOCALE_SE, EMSESP_LOCALE_PL}; size_t num_languages = sizeof(languages) / sizeof(const char *);