mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-11-26 09:13:33 +03:00
React-intl upgrade
This commit is contained in:
parent
c05123d842
commit
4a1922b1b1
@ -43,7 +43,7 @@
|
||||
"lodash": "^4.17.13",
|
||||
"moment": "^2.22.2",
|
||||
"react": "16.8.3",
|
||||
"react-intl": "^2.7.2",
|
||||
"react-intl": "^3.1.6",
|
||||
"react-native": "0.59.8",
|
||||
"react-native-actionsheet": "^2.4.2",
|
||||
"react-native-autocomplete-input": "^4.1.0",
|
||||
|
16
src/index.js
16
src/index.js
@ -1,19 +1,7 @@
|
||||
import React from 'react';
|
||||
import { Provider, connect } from 'react-redux';
|
||||
import { PersistGate } from 'redux-persist/integration/react';
|
||||
import { IntlProvider, addLocaleData } from 'react-intl';
|
||||
|
||||
import en from 'react-intl/locale-data/en';
|
||||
import id from 'react-intl/locale-data/id';
|
||||
import ru from 'react-intl/locale-data/ru';
|
||||
import de from 'react-intl/locale-data/de';
|
||||
import it from 'react-intl/locale-data/it';
|
||||
import hu from 'react-intl/locale-data/hu';
|
||||
import tr from 'react-intl/locale-data/tr';
|
||||
import ko from 'react-intl/locale-data/ko';
|
||||
import lt from 'react-intl/locale-data/lt';
|
||||
import pt from 'react-intl/locale-data/pt';
|
||||
import fa from 'react-intl/locale-data/fa';
|
||||
import { IntlProvider } from 'react-intl';
|
||||
|
||||
import { flattenMessages } from './utils/flattenMessages';
|
||||
import messages from './config/locales';
|
||||
@ -21,8 +9,6 @@ import messages from './config/locales';
|
||||
import Application from './screens/application';
|
||||
import { store, persistor } from './redux/store/store';
|
||||
|
||||
addLocaleData([...en, ...ru, ...de, ...id, ...it, ...hu, ...tr, ...ko, ...pt, ...lt, ...fa]);
|
||||
|
||||
const _renderApp = ({ locale }) => (
|
||||
<PersistGate loading={null} persistor={persistor}>
|
||||
<IntlProvider locale={locale} messages={flattenMessages(messages[locale])}>
|
||||
|
107
yarn.lock
107
yarn.lock
@ -1110,6 +1110,11 @@
|
||||
url "^0.11.0"
|
||||
xmldom "^0.1.27"
|
||||
|
||||
"@formatjs/intl-relativetimeformat@^2.6.2":
|
||||
version "2.6.2"
|
||||
resolved "https://registry.yarnpkg.com/@formatjs/intl-relativetimeformat/-/intl-relativetimeformat-2.6.2.tgz#0429e9b3bdaef8907223b1f01cee78f07b229ac9"
|
||||
integrity sha512-JD6O2yCF2NuefU3+R7va6WmeetvajWO/ab0s4xjGpxnIMu6p9dtjTQfAhW2+NG+4Dc8MYKYo1wbJ8j02mZ1stw==
|
||||
|
||||
"@jest/console@^24.7.1":
|
||||
version "24.7.1"
|
||||
resolved "https://registry.yarnpkg.com/@jest/console/-/console-24.7.1.tgz#32a9e42535a97aedfe037e725bd67e954b459545"
|
||||
@ -1346,6 +1351,19 @@
|
||||
dependencies:
|
||||
"@babel/types" "^7.3.0"
|
||||
|
||||
"@types/hoist-non-react-statics@^3.3.1":
|
||||
version "3.3.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/hoist-non-react-statics/-/hoist-non-react-statics-3.3.1.tgz#1124aafe5118cb591977aeb1ceaaed1070eb039f"
|
||||
integrity sha512-iMIqiko6ooLrTh1joXodJK5X9xeEALT1kM5G3ZLhD3hszxBdIEd5C75U834D9mLcINgD4OyZf5uQXjkuYydWvA==
|
||||
dependencies:
|
||||
"@types/react" "*"
|
||||
hoist-non-react-statics "^3.3.0"
|
||||
|
||||
"@types/invariant@^2.2.30":
|
||||
version "2.2.30"
|
||||
resolved "https://registry.yarnpkg.com/@types/invariant/-/invariant-2.2.30.tgz#20efa342807606ada5483731a8137cb1561e5fe9"
|
||||
integrity sha512-98fB+yo7imSD2F7PF7GIpELNgtLNgo5wjivu0W5V4jx+KVVJxo6p/qN4zdzSTBWy4/sN3pPyXwnhRSD28QX+ag==
|
||||
|
||||
"@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0":
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#42995b446db9a48a11a07ec083499a860e9138ff"
|
||||
@ -1371,11 +1389,19 @@
|
||||
resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.49.tgz#f331afc5efed0796798e5591d6e0ece636969b7b"
|
||||
integrity sha512-YX30JVx0PvSmJ3Eqr74fYLGeBxD+C7vIL20ek+GGGLJeUbVYRUW3EzyAXpIRA0K8c8o0UWqR/GwEFYiFoz1T8w==
|
||||
|
||||
"@types/prop-types@^15.5.5":
|
||||
"@types/prop-types@*", "@types/prop-types@^15.5.5":
|
||||
version "15.7.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.1.tgz#f1a11e7babb0c3cad68100be381d1e064c68f1f6"
|
||||
integrity sha512-CFzn9idOEpHrgdw8JsoTkaDDyRWk1jrzIV8djzcgpq0y9tG4B4lFT+Nxh52DVpDXV+n4+NPNv7M1Dj5uMp6XFg==
|
||||
|
||||
"@types/react@*", "@types/react@^16.0.0":
|
||||
version "16.9.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.1.tgz#862c83b4c9d5cd116e42fd9a4f3694843cd2c051"
|
||||
integrity sha512-jGM2x8F7m7/r+81N/BOaUKVwbC5Cdw6ExlWEUpr77XPwVeNvAppnPEnMMLMfxRDYL8FPEX8MHjwtD2NQMJ0yyQ==
|
||||
dependencies:
|
||||
"@types/prop-types" "*"
|
||||
csstype "^2.2.0"
|
||||
|
||||
"@types/stack-utils@^1.0.1":
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-1.0.1.tgz#0a851d3bd96498fa25c33ab7278ed3bd65f06c3e"
|
||||
@ -2736,6 +2762,11 @@ cssstyle@^1.0.0:
|
||||
dependencies:
|
||||
cssom "0.3.x"
|
||||
|
||||
csstype@^2.2.0:
|
||||
version "2.6.6"
|
||||
resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.6.tgz#c34f8226a94bbb10c32cc0d714afdf942291fc41"
|
||||
integrity sha512-RpFbQGUE74iyPgvr46U9t1xoQBM8T4BL8SxrN66Le2xYAPSaDJJKeztV3awugusb3g3G9iL8StmkBBXhcbbXhg==
|
||||
|
||||
currency-symbol-map@^4.0.4:
|
||||
version "4.0.4"
|
||||
resolved "https://registry.yarnpkg.com/currency-symbol-map/-/currency-symbol-map-4.0.4.tgz#3cfba625974dd3f86822d327ecbd10248695e95e"
|
||||
@ -4654,29 +4685,28 @@ inquirer@^6.2.2:
|
||||
strip-ansi "^5.1.0"
|
||||
through "^2.3.6"
|
||||
|
||||
intl-format-cache@^2.0.5:
|
||||
version "2.2.9"
|
||||
resolved "https://registry.yarnpkg.com/intl-format-cache/-/intl-format-cache-2.2.9.tgz#fb560de20c549cda20b569cf1ffb6dc62b5b93b4"
|
||||
integrity sha512-Zv/u8wRpekckv0cLkwpVdABYST4hZNTDaX7reFetrYTJwxExR2VyTqQm+l0WmL0Qo8Mjb9Tf33qnfj0T7pjxdQ==
|
||||
intl-format-cache@^4.1.9:
|
||||
version "4.1.9"
|
||||
resolved "https://registry.yarnpkg.com/intl-format-cache/-/intl-format-cache-4.1.9.tgz#16108dbde7c13013f02411bf7bdeb82c3dc17991"
|
||||
integrity sha512-DoXRZJ7JtQsgGQDlaRkqn6KfW8B/ivBsQ17JB1kt78qHfojRIpnpbA66Ahgaj/kS5v/+gl83rLlnwdXrFY2LCw==
|
||||
|
||||
intl-messageformat-parser@1.4.0:
|
||||
version "1.4.0"
|
||||
resolved "https://registry.yarnpkg.com/intl-messageformat-parser/-/intl-messageformat-parser-1.4.0.tgz#b43d45a97468cadbe44331d74bb1e8dea44fc075"
|
||||
integrity sha1-tD1FqXRoytvkQzHXS7Ho3qRPwHU=
|
||||
intl-locales-supported@^1.4.4:
|
||||
version "1.4.4"
|
||||
resolved "https://registry.yarnpkg.com/intl-locales-supported/-/intl-locales-supported-1.4.4.tgz#0f2320f295de1a217de4037ede5a5f3a3ebc2320"
|
||||
integrity sha512-dm8tjMFfy6Y+MStEBqzslnV0LTmoEAOGSnZchlKcuyOd9LlxKT8MKLOhq0KqGSRPvWfDRTs94UYTvESw5d+YYA==
|
||||
|
||||
intl-messageformat@^2.0.0, intl-messageformat@^2.1.0:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/intl-messageformat/-/intl-messageformat-2.2.0.tgz#345bcd46de630b7683330c2e52177ff5eab484fc"
|
||||
integrity sha1-NFvNRt5jC3aDMwwuUhd/9eq0hPw=
|
||||
intl-messageformat-parser@^3.0.6:
|
||||
version "3.0.6"
|
||||
resolved "https://registry.yarnpkg.com/intl-messageformat-parser/-/intl-messageformat-parser-3.0.6.tgz#668ffb4ff19a6bde073244c66c202fe70047aa97"
|
||||
integrity sha512-2giAavgG1JSJooXyB0wTotuKBqk8lVz7y8ZdtR+WPlfVZv88TyIuZ85ES89cuF30H68UFqkSswpDXmwCh8X+ig==
|
||||
|
||||
intl-messageformat@^6.1.3:
|
||||
version "6.1.3"
|
||||
resolved "https://registry.yarnpkg.com/intl-messageformat/-/intl-messageformat-6.1.3.tgz#7ff13cfcf3a7919db6d95f4d58de8f717df0e214"
|
||||
integrity sha512-zz2OqVRVaAjdxm1eB+YPZrlejEFxYkZXU89phvlTijKZzceAF5FtosSXgi1mMUvfFbqe2EsTI3oNW2tnoKVtcQ==
|
||||
dependencies:
|
||||
intl-messageformat-parser "1.4.0"
|
||||
|
||||
intl-relativeformat@^2.1.0:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/intl-relativeformat/-/intl-relativeformat-2.2.0.tgz#6aca95d019ec8d30b6c5653b6629f9983ea5b6c5"
|
||||
integrity sha512-4bV/7kSKaPEmu6ArxXf9xjv1ny74Zkwuey8Pm01NH4zggPP7JHwg2STk8Y3JdspCKRDriwIyLRfEXnj2ZLr4Bw==
|
||||
dependencies:
|
||||
intl-messageformat "^2.0.0"
|
||||
intl-format-cache "^4.1.9"
|
||||
intl-messageformat-parser "^3.0.6"
|
||||
|
||||
intl@^1.2.5:
|
||||
version "1.2.5"
|
||||
@ -7581,16 +7611,23 @@ react-devtools-core@^3.6.0:
|
||||
shell-quote "^1.6.1"
|
||||
ws "^3.3.1"
|
||||
|
||||
react-intl@^2.7.2:
|
||||
version "2.9.0"
|
||||
resolved "https://registry.yarnpkg.com/react-intl/-/react-intl-2.9.0.tgz#c97c5d17d4718f1575fdbd5a769f96018a3b1843"
|
||||
integrity sha512-27jnDlb/d2A7mSJwrbOBnUgD+rPep+abmoJE511Tf8BnoONIAUehy/U1zZCHGO17mnOwMWxqN4qC0nW11cD6rA==
|
||||
react-intl@^3.1.6:
|
||||
version "3.1.6"
|
||||
resolved "https://registry.yarnpkg.com/react-intl/-/react-intl-3.1.6.tgz#e41b9fba7bd26c9c83fdae81fb599ac3fdd1c819"
|
||||
integrity sha512-SAqHT9ZI78kwvCaDT8jyCAaPxqheZhRI0vzisIXVGEzzxDXQbxG+2aWWUZvWEHnkCZNwLDr+uK2vLwgeXzLbbw==
|
||||
dependencies:
|
||||
"@formatjs/intl-relativetimeformat" "^2.6.2"
|
||||
"@types/hoist-non-react-statics" "^3.3.1"
|
||||
"@types/invariant" "^2.2.30"
|
||||
"@types/react" "^16.0.0"
|
||||
hoist-non-react-statics "^3.3.0"
|
||||
intl-format-cache "^2.0.5"
|
||||
intl-messageformat "^2.1.0"
|
||||
intl-relativeformat "^2.1.0"
|
||||
intl-format-cache "^4.1.9"
|
||||
intl-locales-supported "^1.4.4"
|
||||
intl-messageformat "^6.1.3"
|
||||
intl-messageformat-parser "^3.0.6"
|
||||
invariant "^2.1.1"
|
||||
react "^16.3.0"
|
||||
shallow-equal "^1.1.0"
|
||||
|
||||
react-is@^16.5.2, react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.3, react-is@^16.8.4:
|
||||
version "16.8.6"
|
||||
@ -7984,6 +8021,15 @@ react@16.8.3:
|
||||
prop-types "^15.6.2"
|
||||
scheduler "^0.13.3"
|
||||
|
||||
react@^16.3.0:
|
||||
version "16.9.0"
|
||||
resolved "https://registry.yarnpkg.com/react/-/react-16.9.0.tgz#40ba2f9af13bc1a38d75dbf2f4359a5185c4f7aa"
|
||||
integrity sha512-+7LQnFBwkiw+BobzOF6N//BdoNw0ouwmSJTEm9cglOOmsg/TMiFHZLe2sEoN5M7LgJTj9oHH0gxklfnQe66S1w==
|
||||
dependencies:
|
||||
loose-envify "^1.1.0"
|
||||
object-assign "^4.1.1"
|
||||
prop-types "^15.6.2"
|
||||
|
||||
read-pkg-up@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-2.0.0.tgz#6b72a8048984e0c41e79510fd5e9fa99b3b549be"
|
||||
@ -8629,6 +8675,11 @@ sha.js@^2.4.0, sha.js@^2.4.8:
|
||||
inherits "^2.0.1"
|
||||
safe-buffer "^5.0.1"
|
||||
|
||||
shallow-equal@^1.1.0:
|
||||
version "1.2.0"
|
||||
resolved "https://registry.yarnpkg.com/shallow-equal/-/shallow-equal-1.2.0.tgz#fd828d2029ff4e19569db7e19e535e94e2d1f5cc"
|
||||
integrity sha512-Z21pVxR4cXsfwpMKMhCEIO1PCi5sp7KEp+CmOpBQ+E8GpHwKOw2sEzk7sgblM3d/j4z4gakoWEoPcjK0VJQogA==
|
||||
|
||||
shebang-command@^1.2.0:
|
||||
version "1.2.0"
|
||||
resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea"
|
||||
|
Loading…
Reference in New Issue
Block a user