From dc75f746375b67cfc9941a0954c52d81e51f30c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:54:40 -0300 Subject: [PATCH 01/23] feat: adding ayncStorage and types of axios MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- package.json | 6 ++- yarn.lock | 103 ++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 107 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index f39288c..65f55d4 100644 --- a/package.json +++ b/package.json @@ -10,10 +10,14 @@ "test": "jest" }, "dependencies": { + "@react-native-async-storage/async-storage": "^1.18.1", "@types/node": "^18.16.0", + "@types/yup": "^0.32.0", + "axios": "^1.4.0", "formik": "^2.2.9", "react": "18.2.0", - "react-native": "0.71.7" + "react-native": "0.71.7", + "yup": "^1.1.1" }, "devDependencies": { "@appbalance/ui": "^1.0.8", diff --git a/yarn.lock b/yarn.lock index ede9f1a..b75ddc1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1470,6 +1470,13 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" +"@react-native-async-storage/async-storage@^1.18.1": + version "1.18.1" + resolved "https://registry.yarnpkg.com/@react-native-async-storage/async-storage/-/async-storage-1.18.1.tgz#b1aea4f07fb1dba3325b857b770671517ddab221" + integrity sha512-70aFW8fVCKl+oA1AKPFDpE6s4t9pulj2QeLX+MabEmzfT3urd/3cckv45WJvtocdoIH/oXA3Y+YcCRJCcNa8mA== + dependencies: + merge-options "^3.0.4" + "@react-native-community/cli-clean@^10.1.1": version "10.1.1" resolved "https://registry.yarnpkg.com/@react-native-community/cli-clean/-/cli-clean-10.1.1.tgz#4c73ce93a63a24d70c0089d4025daac8184ff504" @@ -2038,6 +2045,13 @@ dependencies: "@types/yargs-parser" "*" +"@types/yup@^0.32.0": + version "0.32.0" + resolved "https://registry.yarnpkg.com/@types/yup/-/yup-0.32.0.tgz#2a19c3bbbb3aed1bd755204f83e800f9c95f249a" + integrity sha512-Gr2lllWTDxGVYHgWfL8szjdedERpNgm44L9BDL2cmcHG7Bfd6taEpiW3ayMFLaYvlJr/6bFXDJdh6L406AGlFg== + dependencies: + yup "*" + "@typescript-eslint/eslint-plugin@^5.30.5": version "5.59.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.59.0.tgz#c0e10eeb936debe5d1c3433cf36206a95befefd0" @@ -2334,6 +2348,11 @@ async@^3.2.2: resolved "https://registry.yarnpkg.com/async/-/async-3.2.4.tgz#2d22e00f8cddeb5fde5dd33522b56d1cf569a81c" integrity sha512-iAB+JbDEGXhyIUavoDl9WP/Jj106Kz9DEn1DPgYw5ruDn0e3Wgi3sKFm55sASdGBNOQB8F59d9qQ7deqrHA8wQ== +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" + integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== + atob@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" @@ -2344,6 +2363,15 @@ available-typed-arrays@^1.0.5: resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== +axios@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.4.0.tgz#38a7bf1224cd308de271146038b551d725f0be1f" + integrity sha512-S4XCWMEmzvo64T9GfvQDOXgYRDJ/wsSZc7Jvdgx5u1sd0JwsuPLqb3SYmusag+edF6ziyMensPVqLTSc1PiSEA== + dependencies: + follow-redirects "^1.15.0" + form-data "^4.0.0" + proxy-from-env "^1.1.0" + babel-core@^7.0.0-bridge.0: version "7.0.0-bridge.0" resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-7.0.0-bridge.0.tgz#95a492ddd90f9b4e9a4a1da14eb335b87b634ece" @@ -2795,6 +2823,13 @@ colorette@^1.0.7: resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.4.0.tgz#5190fbb87276259a86ad700bff2c6d6faa3fca40" integrity sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g== +combined-stream@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== + dependencies: + delayed-stream "~1.0.0" + command-exists@^1.2.8: version "1.2.9" resolved "https://registry.yarnpkg.com/command-exists/-/command-exists-1.2.9.tgz#c50725af3808c8ab0260fd60b01fbfa25b954f69" @@ -3085,6 +3120,11 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" + integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== + denodeify@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/denodeify/-/denodeify-1.2.1.tgz#3a36287f5034e699e7577901052c2e6c94251631" @@ -3788,6 +3828,11 @@ flow-parser@^0.185.0: resolved "https://registry.yarnpkg.com/flow-parser/-/flow-parser-0.185.2.tgz#cb7ee57f77377d6c5d69a469e980f6332a15e492" integrity sha512-2hJ5ACYeJCzNtiVULov6pljKOLygy0zddoqSI1fFetM+XRPpRshFdGEijtqlamA1XwyZ+7rhryI6FQFzvtLWUQ== +follow-redirects@^1.15.0: + version "1.15.2" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.2.tgz#b460864144ba63f2681096f274c4e57026da2c13" + integrity sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA== + for-each@^0.3.3: version "0.3.3" resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" @@ -3800,6 +3845,15 @@ for-in@^1.0.2: resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" integrity sha512-7EwmXrOjyL+ChxMhmG5lnW9MPt1aIeZEwKhQzoBUdTV0N3zuwWDZYVJatDvZ2OyzPUvdIAZDsCetk3coyMfcnQ== +form-data@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.0.tgz#93919daeaf361ee529584b9b31664dc12c9fa452" + integrity sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + formik@^2.2.9: version "2.2.9" resolved "https://registry.yarnpkg.com/formik/-/formik-2.2.9.tgz#8594ba9c5e2e5cf1f42c5704128e119fc46232d0" @@ -4366,6 +4420,11 @@ is-path-inside@^3.0.3: resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== +is-plain-obj@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-2.1.0.tgz#45e42e37fccf1f40da8e5f76ee21515840c09287" + integrity sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA== + is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" @@ -5213,6 +5272,13 @@ memoize-one@^5.0.0: resolved "https://registry.yarnpkg.com/memoize-one/-/memoize-one-5.2.1.tgz#8337aa3c4335581839ec01c3d594090cebe8f00e" integrity sha512-zYiwtZUcYyXKo/np96AGZAckk+FWWsUdJ3cHGGmld7+AhvcWmQyGCYUh1hc4Q/pkOhb65dQR/pqCyK0cOaHz4Q== +merge-options@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/merge-options/-/merge-options-3.0.4.tgz#84709c2aa2a4b24c1981f66c179fe5565cc6dbb7" + integrity sha512-2Sug1+knBjkaMsMgf1ctR1Ujx+Ayku4EdJN4Z+C2+JzoeF7A3OZ9KM2GY0CpQS51NR61LTurMJrRKPhSs3ZRTQ== + dependencies: + is-plain-obj "^2.1.0" + merge-stream@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" @@ -5532,7 +5598,7 @@ mime-db@1.52.0, "mime-db@>= 1.43.0 < 2": resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== -mime-types@^2.1.27, mime-types@~2.1.34: +mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.34: version "2.1.35" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== @@ -6097,6 +6163,16 @@ prop-types@*, prop-types@^15.8.1: object-assign "^4.1.1" react-is "^16.13.1" +property-expr@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/property-expr/-/property-expr-2.0.5.tgz#278bdb15308ae16af3e3b9640024524f4dc02cb4" + integrity sha512-IJUkICM5dP5znhCckHSv30Q4b5/JA5enCtkRHYaOVOAocnH/1BQEYTC5NMfT3AVl/iXKdr3aqQbQn9DxyWknwA== + +proxy-from-env@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" + integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== + pump@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" @@ -7050,6 +7126,11 @@ through2@^2.0.1: readable-stream "~2.3.6" xtend "~4.0.1" +tiny-case@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/tiny-case/-/tiny-case-1.0.3.tgz#d980d66bc72b5d5a9ca86fb7c9ffdb9c898ddd03" + integrity sha512-Eet/eeMhkO6TX8mnUteS9zgPbUMQa4I6Kkp5ORiBD5476/m+PIRiumP5tmh5ioJpH7k51Kehawy2UDfsnxxY8Q== + tiny-warning@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754" @@ -7102,6 +7183,11 @@ toidentifier@1.0.1: resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== +toposort@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/toposort/-/toposort-2.0.2.tgz#ae21768175d1559d48bef35420b2f4962f09c330" + integrity sha512-0a5EOkAUp8D4moMi2W8ZF8jcga7BgZd91O/yabJCFY8az+XSzeGyTKs0Aoo897iV1Nj6guFq8orWDS96z91oGg== + tr46@~0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" @@ -7151,6 +7237,11 @@ type-fest@^0.7.1: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.7.1.tgz#8dda65feaf03ed78f0a3f9678f1869147f7c5c48" integrity sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg== +type-fest@^2.19.0: + version "2.19.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-2.19.0.tgz#88068015bb33036a598b952e55e9311a60fd3a9b" + integrity sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA== + typed-array-length@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/typed-array-length/-/typed-array-length-1.0.4.tgz#89d83785e5c4098bec72e08b319651f0eac9c1bb" @@ -7511,3 +7602,13 @@ yocto-queue@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== + +yup@*, yup@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/yup/-/yup-1.1.1.tgz#49dbcf5ae7693ed0a36ed08a9e9de0a09ac18e6b" + integrity sha512-KfCGHdAErqFZWA5tZf7upSUnGKuTOnsI3hUsLr7fgVtx+DK04NPV01A68/FslI4t3s/ZWpvXJmgXhd7q6ICnag== + dependencies: + property-expr "^2.0.5" + tiny-case "^1.0.3" + toposort "^2.0.2" + type-fest "^2.19.0" From 7cdaabeba5a613de7951a5d595bd837191bd3fd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:55:07 -0300 Subject: [PATCH 02/23] refactor: removing propiets to resize elements in view MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- android/app/src/main/AndroidManifest.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index 4122f36..05e5cb5 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -14,7 +14,6 @@ android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize|uiMode" android:launchMode="singleTask" - android:windowSoftInputMode="adjustResize" android:exported="true"> From 8a44093e16b23b324d6861ced25dcb5ceed2d3ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:55:49 -0300 Subject: [PATCH 03/23] feat: Building env MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/commons/constants/env.ts | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 src/commons/constants/env.ts diff --git a/src/commons/constants/env.ts b/src/commons/constants/env.ts new file mode 100644 index 0000000..86ac027 --- /dev/null +++ b/src/commons/constants/env.ts @@ -0,0 +1,7 @@ +const { + // API + + REACT_NATIVE_BASE_API: BASE_API, +} = process.env; + +export { BASE_API }; From b5884c1d948bb9c16e64891a0eab63a82a5dd010 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:56:21 -0300 Subject: [PATCH 04/23] feta: Building api of services MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/services/api/index.ts | 40 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 src/services/api/index.ts diff --git a/src/services/api/index.ts b/src/services/api/index.ts new file mode 100644 index 0000000..6a67373 --- /dev/null +++ b/src/services/api/index.ts @@ -0,0 +1,40 @@ +import axios from 'axios'; +import AsyncStorage from '@react-native-async-storage/async-storage'; + +import { BASE_API } from '../../commons/constants/env'; +// import { IServicePost } from '../@types'; + +export const ServiceGet = async (path: string) => { + const token = AsyncStorage.getItem('token'); + + const config = { + headers: { + Authorization: `Bearer ${token}`, + }, + }; + + const url = `${BASE_API}/${path}`; + const response = await axios.get(url, config); + return response.data; +}; + +export const ServicePost = async (path: string, body: any, isAuth = false) => { + const url = `${BASE_API}/${path}`; + console.log('LOG URL::', url); + const token = AsyncStorage.getItem('token'); + + const config = isAuth + ? {} + : { + headers: { + Authorization: `Bearer ${token}`, + }, + }; + + try { + const response = await axios.post(url, body, config); + return response?.data; + } catch (error) { + return error; + } +}; From 63d65f2dc791e386d5c5e899f8963e1ef15e697c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:56:36 -0300 Subject: [PATCH 05/23] feat: Building types of api MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/services/@types/index.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 src/services/@types/index.ts diff --git a/src/services/@types/index.ts b/src/services/@types/index.ts new file mode 100644 index 0000000..3fc108e --- /dev/null +++ b/src/services/@types/index.ts @@ -0,0 +1,10 @@ +export interface IServicePost { + token: string; + body: {}; + isAuth: Boolean; +} + +export interface IAuthenticateUser { + email: string; + password: string; +} From 73fb7d3e2a85c1ca5a2ac645656278e23461a6cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:56:57 -0300 Subject: [PATCH 06/23] feat: Building services of auth MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/services/auth.ts | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 src/services/auth.ts diff --git a/src/services/auth.ts b/src/services/auth.ts new file mode 100644 index 0000000..1d6521d --- /dev/null +++ b/src/services/auth.ts @@ -0,0 +1,30 @@ +import { IAuthenticateUser, IServicePost } from './@types'; +import { ServiceGet, ServicePost } from './api'; +import AsyncStorage from '@react-native-async-storage/async-storage'; + +export const authenticateUser = async ({ + email, + password, +}: IAuthenticateUser) => { + const isAuth = false; + const response: IServicePost = await ServicePost( + 'auth', + { + email, + password, + }, + isAuth, + ); + + if (!response?.token) { + return response; + } + + AsyncStorage.setItem('token', response.token); + return response; +}; + +export const isAuthenticated = async () => { + const response = await ServiceGet('user'); + return response?.detail ? false : true; +}; From 99d2111415b86f71342e8fc0aa7605e69eadd608 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Tue, 23 May 2023 20:58:15 -0300 Subject: [PATCH 07/23] feat: Building routes and adding Button of left inn header MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/routes/Routes.tsx | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/src/routes/Routes.tsx b/src/routes/Routes.tsx index 56fbcc7..7ea5447 100644 --- a/src/routes/Routes.tsx +++ b/src/routes/Routes.tsx @@ -1,21 +1,30 @@ import React from 'react'; import Register from '../pages/Register'; import Login from '../pages/Login'; +import { theme } from '../commons/styles/theme'; +import Arrow from '../assets/icons/arrowLeft.svg'; +import Button from '../components/elements/Button'; +import { Stack } from '.'; -type Route = { - name: string; - component: React.ComponentType; - options?: {}; -}; - -const routes: Route[] = [ +const routes: Array> = [ { name: 'Register', component: Register, options: { - headerTransparent: true, - headerTitle: 'voltar', - // headerLeft: ({ }) => , + headerShadowVisible: false, + headerStyle: { + backgroundColor: theme.palette.colors.white.main, + }, + headerTitle: 'Voltar', + headerTitleStyle: { + fontSize: 15, + fontFamily: theme.typography.regular, + }, + headerLeft: ({ }) => ( + + ), }, }, { From 886eb3bc59fb05a407a4d3ec96533aefb060b0f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:21:06 -0300 Subject: [PATCH 08/23] feat: Changing variables enviroment MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/services/api/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/services/api/index.ts b/src/services/api/index.ts index 6a67373..2dccab8 100644 --- a/src/services/api/index.ts +++ b/src/services/api/index.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import AsyncStorage from '@react-native-async-storage/async-storage'; -import { BASE_API } from '../../commons/constants/env'; +import { STAGE } from '../../commons/constants/env'; // import { IServicePost } from '../@types'; export const ServiceGet = async (path: string) => { @@ -13,13 +13,13 @@ export const ServiceGet = async (path: string) => { }, }; - const url = `${BASE_API}/${path}`; + const url = `${STAGE.__DEV__.BASE_API}/${path}`; const response = await axios.get(url, config); return response.data; }; export const ServicePost = async (path: string, body: any, isAuth = false) => { - const url = `${BASE_API}/${path}`; + const url = `${STAGE.__DEV__.BASE_API}/${path}`; console.log('LOG URL::', url); const token = AsyncStorage.getItem('token'); From b5d455b055dbaa196cefd79e29856d8d02e18671 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:21:27 -0300 Subject: [PATCH 09/23] feat: adding base url MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/commons/constants/env.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/commons/constants/env.ts b/src/commons/constants/env.ts index 86ac027..6981b58 100644 --- a/src/commons/constants/env.ts +++ b/src/commons/constants/env.ts @@ -1,7 +1,10 @@ -const { +const STAGE = { // API - REACT_NATIVE_BASE_API: BASE_API, -} = process.env; + __DEV__: { + BASE_API: + 'https://xfdewphuedg6qmsoha4ngq3kha0gkxdq.lambda-url.sa-east-1.on.aws', + }, +}; -export { BASE_API }; +export { STAGE }; From 74c7f9b5bfcbab5e12a5da7356437129190d15e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:22:18 -0300 Subject: [PATCH 10/23] feat: adding right icon in form password MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/components/Input/index.tsx | 35 +++++++++++++++++++++++++--------- 1 file changed, 26 insertions(+), 9 deletions(-) diff --git a/src/components/Input/index.tsx b/src/components/Input/index.tsx index a6fe67e..efd8523 100644 --- a/src/components/Input/index.tsx +++ b/src/components/Input/index.tsx @@ -3,26 +3,43 @@ import React from 'react'; import * as S from './styles'; import { InputProps } from './@types'; +import { Text, View } from 'react-native'; + +import Button from '../elements/Button'; const Input = ({ value, + height, placeholder, onChangeText, marginBottom, labelColor, + IconRight, ...props }: InputProps) => { return ( - - {!!value?.length && ( - {placeholder} + + + {!!value?.length && ( + {placeholder} + )} + + + {IconRight && ( + + + )} - ); }; From 1537052e3f3c388dd391779ac7ed8e6c0aab18d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:22:52 -0300 Subject: [PATCH 11/23] feat: adding react native toast and icons MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- package.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package.json b/package.json index 65f55d4..d636c94 100644 --- a/package.json +++ b/package.json @@ -17,6 +17,7 @@ "formik": "^2.2.9", "react": "18.2.0", "react-native": "0.71.7", + "react-native-toast-message": "^2.1.6", "yup": "^1.1.1" }, "devDependencies": { @@ -42,6 +43,7 @@ "react-native-screens": "^3.20.0", "react-native-svg": "^13.9.0", "react-native-svg-transformer": "^1.0.0", + "react-native-vector-icons": "^9.2.0", "react-test-renderer": "18.2.0", "styled-components": "^5.3.10", "typescript": "4.8.4" From ad139001ca999d5392e7a4209bd1013ac1b08b19 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:23:20 -0300 Subject: [PATCH 12/23] feat: typing Input props MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/components/Input/@types/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/components/Input/@types/index.ts b/src/components/Input/@types/index.ts index c2c62e2..a82cb80 100644 --- a/src/components/Input/@types/index.ts +++ b/src/components/Input/@types/index.ts @@ -1,9 +1,12 @@ +import React from 'react'; import { TextInputProps } from 'react-native'; export interface InputProps extends TextInputProps { placeholder: string | undefined; onChangeText: (text: string) => void; value: string | undefined; + height?: string; marginBottom?: string; labelColor?: string; + IconRight?: any; } From 6aa442d452d96dbb770449290215b5c697d7229a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:24:00 -0300 Subject: [PATCH 13/23] feat: Changing styles of input MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/components/Input/styles.ts | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/components/Input/styles.ts b/src/components/Input/styles.ts index 9a982ab..a7209e8 100644 --- a/src/components/Input/styles.ts +++ b/src/components/Input/styles.ts @@ -1,8 +1,12 @@ import styled from 'styled-components/native'; -export const InputContainer = styled.View<{ marginBottom?: string }>` - display: flex; - flex-direction: column; +export const InputContainer = styled.View<{ + marginBottom?: string; + height?: string; +}>` + height: ${({ height }) => (height ? height : 'auto')}; + min-height: 50px; + flex-direction: row; border-bottom-width: 1px; border-bottom-color: #141b41; @@ -14,8 +18,7 @@ export const Label = styled.Text<{ labelColor?: string }>` `; export const Input = styled.TextInput` - width: 100%; - height: 50px; + width: 80%; padding-left: 10px; color: black; `; From a5ea548ee15e3a9127d8679b52b7a07aff3f7d87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:25:26 -0300 Subject: [PATCH 14/23] feat: adding forms and eye to password MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Login/index.tsx | 130 +++++++++++++++++++++++++------------- 1 file changed, 87 insertions(+), 43 deletions(-) diff --git a/src/pages/Login/index.tsx b/src/pages/Login/index.tsx index a59633a..f3ef3eb 100644 --- a/src/pages/Login/index.tsx +++ b/src/pages/Login/index.tsx @@ -1,12 +1,10 @@ import React from 'react'; import { - Image, KeyboardAvoidingView, Platform, SafeAreaView, ScrollView, - // View, } from 'react-native'; import { Formik } from 'formik'; @@ -14,55 +12,101 @@ import * as S from './styles'; import Input from '../../components/Input'; import Typography from '../../components/elements/Typography'; import LogoPurple from '../../assets/icons/logoPurple.svg'; +import { useNavigation } from '@react-navigation/native'; +import { NativeStackScreenProps } from '@react-navigation/native-stack'; +import Button from '../../components/elements/Button'; +import { theme } from '../../commons/styles/theme'; +import { useLogin } from './useLogin'; +import Toast from 'react-native-toast-message'; + +type RootStackParamList = { + Home: undefined; + Profile: { userId: string }; + Feed: { sort: 'latest' | 'top' } | undefined; +}; + +type Props = NativeStackScreenProps; + +type ProfileScrrenProps = Props['navigation']; function Login() { + const navigation = useNavigation(); + const { onSubmit } = useLogin(); + const initialValues = { email: '', password: '', }; return ( - { }}> - {({ handleChange, values }) => ( - - - - - - - - - - - Esqueceu sua senha? - Redefinir - - - - Ainda não tem cadastro? - Cadastre-se. - - - - - )} - + <> + + {({ isSubmitting, handleChange, values, isValid, handleSubmit }) => ( + + + + + + + + + + + {/* */} + + Esqueceu sua senha? + Redefinir + + + + + + + Ainda não tem cadastro? + navigation.navigate('Register')}> + Cadastre-se. + + + + + + )} + + + ); } From 71ee03ff7ecf470e6c2f71011c205bbbb35d7068 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:26:08 -0300 Subject: [PATCH 15/23] feat: adding color placeholderColor and labelColor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Register/Forms/index.tsx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/pages/Register/Forms/index.tsx b/src/pages/Register/Forms/index.tsx index 789e3ea..bb8a1b1 100644 --- a/src/pages/Register/Forms/index.tsx +++ b/src/pages/Register/Forms/index.tsx @@ -14,26 +14,36 @@ const FormRegister = () => { placeholder="Apelido" value={values.surname} onChangeText={handleChange('surname')} + placeholderTextColor="#141b4153" + labelColor="#141b4153" /> ); From 119cfeb86ab52ab3075067610f3c5d0340360433 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:27:08 -0300 Subject: [PATCH 16/23] feat: adding validation schema MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Register/index.tsx | 49 +++++++++++++++++++++++------------- 1 file changed, 32 insertions(+), 17 deletions(-) diff --git a/src/pages/Register/index.tsx b/src/pages/Register/index.tsx index 471d961..b93062f 100644 --- a/src/pages/Register/index.tsx +++ b/src/pages/Register/index.tsx @@ -1,4 +1,9 @@ -import { KeyboardAvoidingView, Platform, ScrollView } from 'react-native'; +import { + KeyboardAvoidingView, + Platform, + SafeAreaView, + ScrollView, +} from 'react-native'; import React from 'react'; import Typography from '../../components/elements/Typography'; @@ -7,6 +12,8 @@ import { Formik } from 'formik'; import { IRegisterForm } from './@types/formikTypes'; import FormRegister from './Forms'; import { theme } from '../../commons/styles/theme'; +import { schemaValidationRegister } from './validationSchema'; +import { useHeaderHeight } from '@react-navigation/elements'; const Register = () => { const initialValues = { @@ -19,16 +26,28 @@ const Register = () => { const handleSubmit = async (values: IRegisterForm) => { }; + const height = useHeaderHeight(); + + console.log(height); + return ( - - + + {({ handleSubmit }) => ( - + behavior={Platform.OS === 'ios' ? 'padding' : 'height'} + style={{ flex: 1 }} + keyboardVerticalOffset={height + 20}> + + {/* */} + - + Cadastro @@ -36,17 +55,13 @@ const Register = () => { - - cadastrar - + cadastrar - + {/* */} + - - + )} + ); }; From 82fb9b54226fa2395d676f4c65e73854005a1fbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:27:37 -0300 Subject: [PATCH 17/23] feat: Changing style of register MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Register/styles.ts | 38 +++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/src/pages/Register/styles.ts b/src/pages/Register/styles.ts index ab949f8..4ba26ff 100644 --- a/src/pages/Register/styles.ts +++ b/src/pages/Register/styles.ts @@ -1,43 +1,49 @@ import styled from 'styled-components/native'; import Button from '../../components/elements/Button'; +import { theme } from '../../commons/styles/theme'; export const Container = styled.View` flex: 1; - - justify-content: center; - margin: 0; - padding: 0; + background-color: #ffff; width: 100%; - height: 100%; + justify-content: center; +`; + +export const StScrollView = styled.ScrollView` + height: 500px; + background-color: #ffff; `; export const ContainerHeader = styled.View` width: 100%; - height: 80px; - justify-content: center; - background-color: aqua; + height: 50px; + flex: 1; + justify-content: flex-end; + /* background-color: aqua; */ align-items: center; `; export const ContainerForms = styled.View` - margin: 0px 45px; - height: 55%; + margin: 0px 25px; + height: 400px; justify-content: center; - margin-bottom: 5%; + /* margin-bottom: 5%; */ + /* background-color: red; */ `; export const ContainerButton = styled.View` width: 100%; - height: 40px; + height: 100px; + flex: 1; align-items: center; - background-color: aqua; justify-content: center; `; -export const StyledButtonLoading = styled(Button)` +export const StyledButtonLoading = styled(Button).attrs({ + color: theme.palette.colors.white.main, +})` width: 200px; height: 40px; - - color: ${({ theme }) => theme.palette.colors.white.main}; font-size: 18px; + font-family: ${({ theme }) => theme.typography.regular}; `; From 4e73466c8bfb515713044a5ac783b9f05fc93527 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:30:11 -0300 Subject: [PATCH 18/23] feat: removing service of auth of user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/services/auth.ts | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/services/auth.ts b/src/services/auth.ts index 1d6521d..371a0ff 100644 --- a/src/services/auth.ts +++ b/src/services/auth.ts @@ -7,18 +7,18 @@ export const authenticateUser = async ({ password, }: IAuthenticateUser) => { const isAuth = false; - const response: IServicePost = await ServicePost( - 'auth', - { - email, - password, - }, - isAuth, - ); + // const response: IServicePost = await ServicePost( + // 'auth', + // { + // email, + // password, + // }, + // isAuth, + // ); - if (!response?.token) { - return response; - } + // if (!response?.token) { + // return response; + // } AsyncStorage.setItem('token', response.token); return response; From 0fd009fe86a7654caa69a2537a5a6f51c97bad87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:30:24 -0300 Subject: [PATCH 19/23] feat: adding style of login MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Login/styles.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/pages/Login/styles.ts b/src/pages/Login/styles.ts index 1b0390e..13bb3e6 100644 --- a/src/pages/Login/styles.ts +++ b/src/pages/Login/styles.ts @@ -4,13 +4,14 @@ import { theme } from '../../commons/styles/theme'; export const Container = styled.View` flex: 1; + background-color: aqua; `; export const ContainerForms = styled.View` justify-content: center; margin: 20px; flex: 1; - height: 200px; + height: 280px; `; export const ContainerLogo = styled.View` @@ -22,13 +23,19 @@ export const ContainerLogo = styled.View` margin-top: 10%; `; -export const ContainerResetPassoword = styled.View` +export const ContainerResetPassword = styled.View` flex-direction: row; height: 50px; align-items: center; `; +export const ContainerButton = styled.View` + height: 80px; + align-items: center; + justify-content: flex-end; +`; + export const ButtonResetPassword = styled(Button).attrs({ variant: 'text', color: theme.palette.colors.primary.main, @@ -49,6 +56,6 @@ export const ContainerRegister = styled.View` flex-direction: row; justify-content: center; flex: 1; - height: 200px; + height: 150px; align-items: flex-end; `; From 29439284c9f1723e824ce6693336cbd172ec1224 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:30:48 -0300 Subject: [PATCH 20/23] feat: Building hook of login MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Login/useLogin/index.ts | 36 +++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/pages/Login/useLogin/index.ts diff --git a/src/pages/Login/useLogin/index.ts b/src/pages/Login/useLogin/index.ts new file mode 100644 index 0000000..b0777e2 --- /dev/null +++ b/src/pages/Login/useLogin/index.ts @@ -0,0 +1,36 @@ +import { ToastAndroid } from 'react-native'; +import Toast from 'react-native-toast-message'; +import { authenticateUser } from '../../../services/auth'; + +interface IValues { + email: string; + password: string; +} + +export const useLogin = () => { + const showToast = () => { + Toast.show({ + type: 'success', + text1: ' 👋 Bem vindo ao balance', + }); + }; + + // const showToastAndroid = () => { + // ToastAndroid.show('Bem vindo ao balance', ToastAndroid.SHORT); + // }; + + const onSubmit = async ({ email, password }: IValues, { setSubmitting }) => { + showToast(); + // showToastAndroid(); + const response = await authenticateUser({ email, password }); + console.log('Executei', response); + if (!response.token) { + setSubmitting(true); + return; + } + }; + + return { + onSubmit, + }; +}; From d0524e4703b0189ac05fa25273924142646aa835 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:31:10 -0300 Subject: [PATCH 21/23] feat: Building schema validation of register MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/pages/Register/validationSchema.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 src/pages/Register/validationSchema.ts diff --git a/src/pages/Register/validationSchema.ts b/src/pages/Register/validationSchema.ts new file mode 100644 index 0000000..db7275b --- /dev/null +++ b/src/pages/Register/validationSchema.ts @@ -0,0 +1,11 @@ +import * as Yup from 'yup'; + +export const schemaValidationRegister = Yup.object().shape({ + surname: Yup.string().required('Este campo é obrigatório'), + fullName: Yup.string().required('Este campo é obrigatório'), + email: Yup.string().email().required('Email é obrigatório'), + password: Yup.string().required('Digite sua senha'), + confirmPassword: Yup.string() + .required('confirmação de senha é obrigatória') + .oneOf([Yup.ref('password')], 'As senhas devem conresponder'), +}); From 9873d645774323f863d8a3913c818fa5f0c7a19b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:31:47 -0300 Subject: [PATCH 22/23] feat: exporting Stack navigation ta typing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- src/routes/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/index.tsx b/src/routes/index.tsx index c2bb889..08b149f 100644 --- a/src/routes/index.tsx +++ b/src/routes/index.tsx @@ -3,7 +3,7 @@ import { NavigationContainer } from '@react-navigation/native'; import { createNativeStackNavigator } from '@react-navigation/native-stack'; import { routes } from './Routes'; -const Stack = createNativeStackNavigator(); +export const Stack = createNativeStackNavigator(); const Routes = () => { return ( From de460b7b20aca28e6da89436ba47f97495f8a54d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Pedro?= Date: Thu, 25 May 2023 20:32:23 -0300 Subject: [PATCH 23/23] yarn lock MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: João Pedro --- yarn.lock | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) diff --git a/yarn.lock b/yarn.lock index b75ddc1..91e50b3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2753,6 +2753,15 @@ cliui@^6.0.0: strip-ansi "^6.0.0" wrap-ansi "^6.2.0" +cliui@^7.0.2: + version "7.0.4" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-7.0.4.tgz#a0265ee655476fc807aea9df3df8df7783808b4f" + integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^7.0.0" + cliui@^8.0.1: version "8.0.1" resolved "https://registry.yarnpkg.com/cliui/-/cliui-8.0.1.tgz#0c04b075db02cbfe60dc8e6cf2f5486b1a3608aa" @@ -6154,7 +6163,7 @@ prompts@^2.0.1, prompts@^2.4.0: kleur "^3.0.3" sisteransi "^1.0.5" -prop-types@*, prop-types@^15.8.1: +prop-types@*, prop-types@^15.7.2, prop-types@^15.8.1: version "15.8.1" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5" integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg== @@ -6294,6 +6303,19 @@ react-native-svg@^13.9.0: css-select "^5.1.0" css-tree "^1.1.3" +react-native-toast-message@^2.1.6: + version "2.1.6" + resolved "https://registry.yarnpkg.com/react-native-toast-message/-/react-native-toast-message-2.1.6.tgz#322827c66901fa22cb3db614c7383cc717f5bbe2" + integrity sha512-VctXuq20vmRa9AE13acaNZhrLcS3FaBS2zEevS3+vhBsnVZYG0FIlWIis9tVnpnNxUb3ART+BWtwQjzSttXTng== + +react-native-vector-icons@^9.2.0: + version "9.2.0" + resolved "https://registry.yarnpkg.com/react-native-vector-icons/-/react-native-vector-icons-9.2.0.tgz#3c0c82e95defd274d56363cbe8fead8d53167ebd" + integrity sha512-wKYLaFuQST/chH3AJRjmOLoLy3JEs1JR6zMNgTaemFpNoXs0ztRnTxcxFD9xhX7cJe1/zoN5BpQYe7kL0m5yyA== + dependencies: + prop-types "^15.7.2" + yargs "^16.1.1" + react-native@0.71.7: version "0.71.7" resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.71.7.tgz#d0ae409f6ee4fc7e7a876b4ca9d8d28934133228" @@ -7563,6 +7585,11 @@ yargs-parser@^18.1.2: camelcase "^5.0.0" decamelize "^1.2.0" +yargs-parser@^20.2.2: + version "20.2.9" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" + integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== + yargs-parser@^21.1.1: version "21.1.1" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" @@ -7585,6 +7612,19 @@ yargs@^15.1.0: y18n "^4.0.0" yargs-parser "^18.1.2" +yargs@^16.1.1: + version "16.2.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66" + integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== + dependencies: + cliui "^7.0.2" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.0" + y18n "^5.0.5" + yargs-parser "^20.2.2" + yargs@^17.3.1, yargs@^17.5.1: version "17.7.1" resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.1.tgz#34a77645201d1a8fc5213ace787c220eabbd0967"