diff --git a/app/ios/Podfile.lock b/app/ios/Podfile.lock index 019228fcc..38281e3af 100644 --- a/app/ios/Podfile.lock +++ b/app/ios/Podfile.lock @@ -445,7 +445,7 @@ PODS: - React-jsinspector (0.72.5) - React-logger (0.72.5): - glog - - "react-native-attestation (1.0.0-alpha.295+b95c752a)": + - "react-native-attestation (1.0.0-alpha.297+ea2300f5)": - RCT-Folly (= 2021.07.22.00) - React-Core - react-native-config (1.5.0): @@ -931,7 +931,7 @@ SPEC CHECKSUMS: React-jsiexecutor: ff70a72027dea5cc7d71cfcc6fad7f599f63987a React-jsinspector: aef73cbd43b70675f572214d10fa438c89bf11ba React-logger: 2e4aee3e11b3ec4fa6cfd8004610bbb3b8d6cca4 - react-native-attestation: 190c81fbc066d101a947d6b9a73da6a455618a1c + react-native-attestation: 376c47997ba33b29cf64a9cc8f9f625b62f3447b react-native-config: 5330c8258265c1e5fdb8c009d2cabd6badd96727 react-native-encrypted-storage: db300a3f2f0aba1e818417c1c0a6be549038deb7 react-native-get-random-values: a6ea6a8a65dc93e96e24a11105b1a9c8cfe1d72a diff --git a/app/package.json b/app/package.json index 09e318f50..dc64fad9a 100644 --- a/app/package.json +++ b/app/package.json @@ -61,11 +61,11 @@ "@formatjs/intl-relativetimeformat": "9.3.1", "@hyperledger/anoncreds-react-native": "0.2.2", "@hyperledger/aries-askar-react-native": "0.2.3", - "@hyperledger/aries-bifold-core": "1.0.0-alpha.295", - "@hyperledger/aries-bifold-remote-logs": "1.0.0-alpha.295", - "@hyperledger/aries-bifold-verifier": "1.0.0-alpha.295", - "@hyperledger/aries-oca": "1.0.0-alpha.295", - "@hyperledger/aries-react-native-attestation": "1.0.0-alpha.295", + "@hyperledger/aries-bifold-core": "1.0.0-alpha.297", + "@hyperledger/aries-bifold-remote-logs": "1.0.0-alpha.297", + "@hyperledger/aries-bifold-verifier": "1.0.0-alpha.297", + "@hyperledger/aries-oca": "1.0.0-alpha.297", + "@hyperledger/aries-react-native-attestation": "1.0.0-alpha.297", "@hyperledger/indy-vdr-react-native": "0.2.2", "@hyperledger/indy-vdr-shared": "0.2.2", "@react-native-async-storage/async-storage": "1.15.11", diff --git a/app/src/screens/PersonCredential.tsx b/app/src/screens/PersonCredential.tsx index 5e24576a8..614b3f105 100644 --- a/app/src/screens/PersonCredential.tsx +++ b/app/src/screens/PersonCredential.tsx @@ -1,6 +1,14 @@ import { useAgent } from '@credo-ts/react-hooks' -import { useStore, useTheme, Button, ButtonType, testIdWithKey, Link } from '@hyperledger/aries-bifold-core' -import { NotificationStackParams, Screens } from '@hyperledger/aries-bifold-core/lib/typescript/App/types/navigators' +import { + useStore, + useTheme, + Button, + ButtonType, + testIdWithKey, + Link, + Screens, + NotificationStackParams, +} from '@hyperledger/aries-bifold-core' import { StackScreenProps } from '@react-navigation/stack' import React, { useState, useCallback, useEffect } from 'react' import { useTranslation } from 'react-i18next' diff --git a/app/src/screens/PersonCredentialLoading.tsx b/app/src/screens/PersonCredentialLoading.tsx index 9bd8350a1..0a220983e 100644 --- a/app/src/screens/PersonCredentialLoading.tsx +++ b/app/src/screens/PersonCredentialLoading.tsx @@ -4,7 +4,7 @@ import { Button, ButtonType, Screens, - Stacks, + NotificationStackParams, TOKENS, testIdWithKey, useContainer, @@ -14,7 +14,7 @@ import { BifoldError, AttestationEventTypes, } from '@hyperledger/aries-bifold-core' -import { useNavigation } from '@react-navigation/native' +import { StackScreenProps } from '@react-navigation/stack' import React, { useEffect, useRef, useState } from 'react' import { useTranslation } from 'react-i18next' import { @@ -31,8 +31,9 @@ import { import PersonCredentialSpinner from '../components/PersonCredentialSpinner' import { connectToIASAgent, authenticateWithServiceCard, WellKnownAgentDetails } from '../helpers/BCIDHelper' import { BCState } from '../store' +type PersonProps = StackScreenProps -const PersonCredentialLoading: React.FC = () => { +const PersonCredentialLoading: React.FC = ({ navigation }) => { const { ColorPallet, TextTheme } = useTheme() const [store] = useStore() const [remoteAgentDetails, setRemoteAgentDetails] = useState() @@ -44,7 +45,6 @@ const PersonCredentialLoading: React.FC = () => { if (!agent) { throw new Error('Unable to fetch agent from Credo') } - const navigation = useNavigation() const { t } = useTranslation() const attestationProofRequestWaitTimeout = 10000 const [didCompleteAttestationProofRequest, setDidCompleteAttestationProofRequest] = useState(false) @@ -110,11 +110,8 @@ const PersonCredentialLoading: React.FC = () => { // when a person credential offer is received, show the // offer screen to the user. - const goToCredentialOffer = (credentialId?: string) => { - navigation.getParent()?.navigate(Stacks.NotificationStack, { - screen: Screens.CredentialOffer, - params: { credentialId }, - }) + const goToCredentialOffer = (credentialId: string) => { + navigation.replace(Screens.CredentialOffer, { credentialId }) } useEffect(() => { diff --git a/yarn.lock b/yarn.lock index b603ce587..0691c37da 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3021,9 +3021,9 @@ __metadata: languageName: node linkType: hard -"@hyperledger/aries-bifold-core@npm:1.0.0-alpha.295": - version: 1.0.0-alpha.295 - resolution: "@hyperledger/aries-bifold-core@npm:1.0.0-alpha.295" +"@hyperledger/aries-bifold-core@npm:1.0.0-alpha.297": + version: 1.0.0-alpha.297 + resolution: "@hyperledger/aries-bifold-core@npm:1.0.0-alpha.297" peerDependencies: "@credo-ts/anoncreds": 0.5.9 "@credo-ts/askar": 0.5.9 @@ -3097,13 +3097,13 @@ __metadata: uuid: ^9.0.0 bin: bifold: bin/bifold - checksum: 04733b502e997ad8b1b533c327059d321635070f1085b7047b791840f986f79860ec902d8067482d64d29ac352d2f4c055d354110a231efd01638acf6bb94633 + checksum: ba92f8fe3ee580c38998b91cdb0d6aa7389b2997935245338e4c438634bb6d77953fe2f255085f00930b88ad63a4324621f4230b7c43788c6aaa0357ec6a8c77 languageName: node linkType: hard -"@hyperledger/aries-bifold-remote-logs@npm:1.0.0-alpha.295": - version: 1.0.0-alpha.295 - resolution: "@hyperledger/aries-bifold-remote-logs@npm:1.0.0-alpha.295" +"@hyperledger/aries-bifold-remote-logs@npm:1.0.0-alpha.297": + version: 1.0.0-alpha.297 + resolution: "@hyperledger/aries-bifold-remote-logs@npm:1.0.0-alpha.297" peerDependencies: "@credo-ts/core": 0.5.9 axios: ^1.4.0 @@ -3111,43 +3111,43 @@ __metadata: react: ^18.2.0 react-native: ^0.72.5 react-native-logs: ^5.1.0 - checksum: 28b2c8232e823dd6eedc7dd3a4684da1b67537757191fafe778ca5c679b466e79a48d45d76c451705c614e9428921a02fb92ead6ba5741ea6ed4dfd9d42811ff + checksum: bb060c9d55046518a9006eefa26a1fd33e59b5321eac54ee28e67d2af07c997c11d9b47dc5eccceb5b30cfdd36cb3d8cf1fff7b411fecbd1aad296248415f79f languageName: node linkType: hard -"@hyperledger/aries-bifold-verifier@npm:1.0.0-alpha.295": - version: 1.0.0-alpha.295 - resolution: "@hyperledger/aries-bifold-verifier@npm:1.0.0-alpha.295" +"@hyperledger/aries-bifold-verifier@npm:1.0.0-alpha.297": + version: 1.0.0-alpha.297 + resolution: "@hyperledger/aries-bifold-verifier@npm:1.0.0-alpha.297" peerDependencies: "@credo-ts/anoncreds": 0.5.9 "@credo-ts/core": 0.5.9 "@credo-ts/react-hooks": ^0.6.0 "@hyperledger/anoncreds-shared": 0.2.2 react: ^18.2.0 - checksum: 30d312077446225906e22e3f3952628d279361898c7a6a5da9b627ee1a026af437a6803edcf7bc4017e0f1037f4f69fc72f61ef6bb5648bfb62f42ba0d4a0b40 + checksum: 25bf89ab190aff94c3fc28aa0199fefffdd60e66445c80d572621f1421ced26ccf34409d2d4569f51845f6f70fb6b90e36e56de538cd1e3b52bd6801b570c329 languageName: node linkType: hard -"@hyperledger/aries-oca@npm:1.0.0-alpha.295": - version: 1.0.0-alpha.295 - resolution: "@hyperledger/aries-oca@npm:1.0.0-alpha.295" +"@hyperledger/aries-oca@npm:1.0.0-alpha.297": + version: 1.0.0-alpha.297 + resolution: "@hyperledger/aries-oca@npm:1.0.0-alpha.297" dependencies: "@credo-ts/anoncreds": "npm:0.5.9" "@credo-ts/core": "npm:0.5.9" axios: "npm:^1.4.0" lodash.startcase: "npm:^4.4.0" react-native-fs: "npm:^2.16.6" - checksum: 12007cab1692deb99bede78fe6d52c41c7756af473184960040fc864dcc83f527480f73ffa3faba0891af97b93dd484823530289283f960a0ae3b343bb95fcbb + checksum: 331eb574347d8549f3d85748b9ab5c6f40715201e5c8b53502684d3b1d1d0b14d91cd27eda1b683f7952c039b476c11d74e46b9adfd234ab5935319221086b37 languageName: node linkType: hard -"@hyperledger/aries-react-native-attestation@npm:1.0.0-alpha.295": - version: 1.0.0-alpha.295 - resolution: "@hyperledger/aries-react-native-attestation@npm:1.0.0-alpha.295" +"@hyperledger/aries-react-native-attestation@npm:1.0.0-alpha.297": + version: 1.0.0-alpha.297 + resolution: "@hyperledger/aries-react-native-attestation@npm:1.0.0-alpha.297" peerDependencies: react: "*" react-native: "*" - checksum: abeec4ec0e7631bae395963f581d76a2fc3ae453a260d2b40e1a82249d8953081c537732aee2e4d9c5c2df7c27932fb049d805d0245cf23d877811b5a0988f4e + checksum: b68d81a2569609742150ff081a29d6aa20d6630403a18de850fe6cf23aba39567c5f65ccc84f1949588fdd3672ac1797a46fa8f8e34f398c7708e95b0c00e008 languageName: node linkType: hard @@ -7740,11 +7740,11 @@ __metadata: "@formatjs/intl-relativetimeformat": "npm:9.3.1" "@hyperledger/anoncreds-react-native": "npm:0.2.2" "@hyperledger/aries-askar-react-native": "npm:0.2.3" - "@hyperledger/aries-bifold-core": "npm:1.0.0-alpha.295" - "@hyperledger/aries-bifold-remote-logs": "npm:1.0.0-alpha.295" - "@hyperledger/aries-bifold-verifier": "npm:1.0.0-alpha.295" - "@hyperledger/aries-oca": "npm:1.0.0-alpha.295" - "@hyperledger/aries-react-native-attestation": "npm:1.0.0-alpha.295" + "@hyperledger/aries-bifold-core": "npm:1.0.0-alpha.297" + "@hyperledger/aries-bifold-remote-logs": "npm:1.0.0-alpha.297" + "@hyperledger/aries-bifold-verifier": "npm:1.0.0-alpha.297" + "@hyperledger/aries-oca": "npm:1.0.0-alpha.297" + "@hyperledger/aries-react-native-attestation": "npm:1.0.0-alpha.297" "@hyperledger/indy-vdr-react-native": "npm:0.2.2" "@hyperledger/indy-vdr-shared": "npm:0.2.2" "@react-native-async-storage/async-storage": "npm:1.15.11"