@bifold/core 3.0.1 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/components/animated/LoadingSpinner.js +5 -4
- package/lib/commonjs/components/animated/LoadingSpinner.js.map +1 -1
- package/lib/commonjs/components/record/Record.js +11 -5
- package/lib/commonjs/components/record/Record.js.map +1 -1
- package/lib/commonjs/components/views/HomeFooterView.js +3 -2
- package/lib/commonjs/components/views/HomeFooterView.js.map +1 -1
- package/lib/commonjs/constants.js +2 -0
- package/lib/commonjs/constants.js.map +1 -1
- package/lib/commonjs/container-api.js +8 -2
- package/lib/commonjs/container-api.js.map +1 -1
- package/lib/commonjs/container-impl.js +5 -1
- package/lib/commonjs/container-impl.js.map +1 -1
- package/lib/commonjs/contexts/reducers/store.js +16 -1
- package/lib/commonjs/contexts/reducers/store.js.map +1 -1
- package/lib/commonjs/contexts/store.js +3 -0
- package/lib/commonjs/contexts/store.js.map +1 -1
- package/lib/commonjs/hooks/attestation.js +83 -0
- package/lib/commonjs/hooks/attestation.js.map +1 -0
- package/lib/commonjs/hooks/useBifoldAgentSetup.js +1 -0
- package/lib/commonjs/hooks/useBifoldAgentSetup.js.map +1 -1
- package/lib/commonjs/localization/en/en.json +4 -1
- package/lib/commonjs/localization/fr/fr.json +4 -1
- package/lib/commonjs/localization/pt-br/pt-br.json +4 -1
- package/lib/commonjs/modules/openid/components/OpenIDCredentialCard.js.map +1 -1
- package/lib/commonjs/modules/openid/context/OpenIDCredentialRecordProvider.js +63 -25
- package/lib/commonjs/modules/openid/context/OpenIDCredentialRecordProvider.js.map +1 -1
- package/lib/commonjs/modules/openid/displayProof.js +118 -1
- package/lib/commonjs/modules/openid/displayProof.js.map +1 -1
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.js +56 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.js.map +1 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.js +104 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.js.map +1 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.js +87 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.js.map +1 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.js +50 -0
- package/lib/commonjs/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.js.map +1 -0
- package/lib/commonjs/modules/openid/refresh/refreshOrchestrator.js +14 -1
- package/lib/commonjs/modules/openid/refresh/refreshOrchestrator.js.map +1 -1
- package/lib/commonjs/modules/openid/refresh/types.js.map +1 -1
- package/lib/commonjs/modules/openid/resolverProof.js +114 -27
- package/lib/commonjs/modules/openid/resolverProof.js.map +1 -1
- package/lib/commonjs/modules/openid/screens/OpenIDConnection.js +3 -2
- package/lib/commonjs/modules/openid/screens/OpenIDConnection.js.map +1 -1
- package/lib/commonjs/modules/openid/screens/OpenIDCredentialDetails.js +5 -2
- package/lib/commonjs/modules/openid/screens/OpenIDCredentialDetails.js.map +1 -1
- package/lib/commonjs/modules/openid/screens/OpenIDProofChangeCredential.js +6 -11
- package/lib/commonjs/modules/openid/screens/OpenIDProofChangeCredential.js.map +1 -1
- package/lib/commonjs/modules/openid/screens/OpenIDProofPresentation.js +45 -188
- package/lib/commonjs/modules/openid/screens/OpenIDProofPresentation.js.map +1 -1
- package/lib/commonjs/modules/openid/types.js.map +1 -1
- package/lib/commonjs/navigators/DeliveryStack.js +2 -1
- package/lib/commonjs/navigators/DeliveryStack.js.map +1 -1
- package/lib/commonjs/navigators/defaultLayoutOptions.js +2 -1
- package/lib/commonjs/navigators/defaultLayoutOptions.js.map +1 -1
- package/lib/commonjs/navigators/defaultStackOptions.js +1 -1
- package/lib/commonjs/navigators/defaultStackOptions.js.map +1 -1
- package/lib/commonjs/onboarding.js +6 -3
- package/lib/commonjs/onboarding.js.map +1 -1
- package/lib/commonjs/screens/Connection.js +9 -28
- package/lib/commonjs/screens/Connection.js.map +1 -1
- package/lib/commonjs/screens/ListCredentials.js +8 -2
- package/lib/commonjs/screens/ListCredentials.js.map +1 -1
- package/lib/commonjs/screens/Splash.js +21 -2
- package/lib/commonjs/screens/Splash.js.map +1 -1
- package/lib/commonjs/theme.js +2 -1
- package/lib/commonjs/theme.js.map +1 -1
- package/lib/commonjs/utils/agent.js +10 -0
- package/lib/commonjs/utils/agent.js.map +1 -1
- package/lib/commonjs/utils/network.js +16 -0
- package/lib/commonjs/utils/network.js.map +1 -1
- package/lib/commonjs/wallet/map-to-card.js +2 -2
- package/lib/commonjs/wallet/map-to-card.js.map +1 -1
- package/lib/module/components/animated/LoadingSpinner.js +4 -3
- package/lib/module/components/animated/LoadingSpinner.js.map +1 -1
- package/lib/module/components/record/Record.js +12 -6
- package/lib/module/components/record/Record.js.map +1 -1
- package/lib/module/components/views/HomeFooterView.js +3 -2
- package/lib/module/components/views/HomeFooterView.js.map +1 -1
- package/lib/module/constants.js +2 -0
- package/lib/module/constants.js.map +1 -1
- package/lib/module/container-api.js +7 -1
- package/lib/module/container-api.js.map +1 -1
- package/lib/module/container-impl.js +5 -1
- package/lib/module/container-impl.js.map +1 -1
- package/lib/module/contexts/reducers/store.js +16 -1
- package/lib/module/contexts/reducers/store.js.map +1 -1
- package/lib/module/contexts/store.js +3 -0
- package/lib/module/contexts/store.js.map +1 -1
- package/lib/module/hooks/attestation.js +75 -0
- package/lib/module/hooks/attestation.js.map +1 -0
- package/lib/module/hooks/useBifoldAgentSetup.js +1 -0
- package/lib/module/hooks/useBifoldAgentSetup.js.map +1 -1
- package/lib/module/localization/en/en.json +4 -1
- package/lib/module/localization/fr/fr.json +4 -1
- package/lib/module/localization/pt-br/pt-br.json +4 -1
- package/lib/module/modules/openid/components/OpenIDCredentialCard.js.map +1 -1
- package/lib/module/modules/openid/context/OpenIDCredentialRecordProvider.js +63 -25
- package/lib/module/modules/openid/context/OpenIDCredentialRecordProvider.js.map +1 -1
- package/lib/module/modules/openid/displayProof.js +116 -1
- package/lib/module/modules/openid/displayProof.js.map +1 -1
- package/lib/module/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.js +49 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.js.map +1 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.js +97 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.js.map +1 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.js +80 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.js.map +1 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.js +44 -0
- package/lib/module/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.js.map +1 -0
- package/lib/module/modules/openid/refresh/refreshOrchestrator.js +14 -1
- package/lib/module/modules/openid/refresh/refreshOrchestrator.js.map +1 -1
- package/lib/module/modules/openid/refresh/types.js.map +1 -1
- package/lib/module/modules/openid/resolverProof.js +114 -27
- package/lib/module/modules/openid/resolverProof.js.map +1 -1
- package/lib/module/modules/openid/screens/OpenIDConnection.js +3 -2
- package/lib/module/modules/openid/screens/OpenIDConnection.js.map +1 -1
- package/lib/module/modules/openid/screens/OpenIDCredentialDetails.js +5 -2
- package/lib/module/modules/openid/screens/OpenIDCredentialDetails.js.map +1 -1
- package/lib/module/modules/openid/screens/OpenIDProofChangeCredential.js +6 -11
- package/lib/module/modules/openid/screens/OpenIDProofChangeCredential.js.map +1 -1
- package/lib/module/modules/openid/screens/OpenIDProofPresentation.js +47 -191
- package/lib/module/modules/openid/screens/OpenIDProofPresentation.js.map +1 -1
- package/lib/module/modules/openid/types.js.map +1 -1
- package/lib/module/navigators/DeliveryStack.js +2 -1
- package/lib/module/navigators/DeliveryStack.js.map +1 -1
- package/lib/module/navigators/defaultLayoutOptions.js +2 -1
- package/lib/module/navigators/defaultLayoutOptions.js.map +1 -1
- package/lib/module/navigators/defaultStackOptions.js +1 -1
- package/lib/module/navigators/defaultStackOptions.js.map +1 -1
- package/lib/module/onboarding.js +6 -3
- package/lib/module/onboarding.js.map +1 -1
- package/lib/module/screens/Connection.js +9 -28
- package/lib/module/screens/Connection.js.map +1 -1
- package/lib/module/screens/ListCredentials.js +9 -3
- package/lib/module/screens/ListCredentials.js.map +1 -1
- package/lib/module/screens/Splash.js +21 -2
- package/lib/module/screens/Splash.js.map +1 -1
- package/lib/module/theme.js +2 -1
- package/lib/module/theme.js.map +1 -1
- package/lib/module/utils/agent.js +10 -1
- package/lib/module/utils/agent.js.map +1 -1
- package/lib/module/utils/network.js +15 -0
- package/lib/module/utils/network.js.map +1 -1
- package/lib/module/wallet/map-to-card.js +3 -3
- package/lib/module/wallet/map-to-card.js.map +1 -1
- package/lib/typescript/src/components/animated/LoadingSpinner.d.ts +2 -1
- package/lib/typescript/src/components/animated/LoadingSpinner.d.ts.map +1 -1
- package/lib/typescript/src/components/record/Record.d.ts +1 -0
- package/lib/typescript/src/components/record/Record.d.ts.map +1 -1
- package/lib/typescript/src/components/views/HomeFooterView.d.ts.map +1 -1
- package/lib/typescript/src/constants.d.ts +3 -1
- package/lib/typescript/src/constants.d.ts.map +1 -1
- package/lib/typescript/src/container-api.d.ts +12 -0
- package/lib/typescript/src/container-api.d.ts.map +1 -1
- package/lib/typescript/src/container-impl.d.ts +3 -0
- package/lib/typescript/src/container-impl.d.ts.map +1 -1
- package/lib/typescript/src/contexts/reducers/store.d.ts +5 -1
- package/lib/typescript/src/contexts/reducers/store.d.ts.map +1 -1
- package/lib/typescript/src/contexts/store.d.ts.map +1 -1
- package/lib/typescript/src/hooks/attestation.d.ts +4 -0
- package/lib/typescript/src/hooks/attestation.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useBifoldAgentSetup.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/components/OpenIDCredentialCard.d.ts +2 -2
- package/lib/typescript/src/modules/openid/components/OpenIDCredentialCard.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/context/OpenIDCredentialRecordProvider.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/displayProof.d.ts +4 -29
- package/lib/typescript/src/modules/openid/displayProof.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.d.ts +23 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/OpenIDProofRequestDisplay.d.ts.map +1 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.d.ts +13 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestBody.d.ts.map +1 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.d.ts +14 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestFooter.d.ts.map +1 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.d.ts +9 -0
- package/lib/typescript/src/modules/openid/features/OpenIDProofPresentation/components/OpenIDProofRequestHeader.d.ts.map +1 -0
- package/lib/typescript/src/modules/openid/refresh/refreshOrchestrator.d.ts +1 -0
- package/lib/typescript/src/modules/openid/refresh/refreshOrchestrator.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/refresh/types.d.ts +1 -0
- package/lib/typescript/src/modules/openid/refresh/types.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/resolverProof.d.ts +32 -11
- package/lib/typescript/src/modules/openid/resolverProof.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/screens/OpenIDCredentialDetails.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/screens/OpenIDProofChangeCredential.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/screens/OpenIDProofPresentation.d.ts.map +1 -1
- package/lib/typescript/src/modules/openid/types.d.ts +34 -4
- package/lib/typescript/src/modules/openid/types.d.ts.map +1 -1
- package/lib/typescript/src/navigators/defaultLayoutOptions.d.ts.map +1 -1
- package/lib/typescript/src/onboarding.d.ts +1 -1
- package/lib/typescript/src/onboarding.d.ts.map +1 -1
- package/lib/typescript/src/screens/Connection.d.ts.map +1 -1
- package/lib/typescript/src/screens/ListCredentials.d.ts.map +1 -1
- package/lib/typescript/src/screens/Splash.d.ts.map +1 -1
- package/lib/typescript/src/theme.d.ts +1 -0
- package/lib/typescript/src/theme.d.ts.map +1 -1
- package/lib/typescript/src/types/config.d.ts +1 -0
- package/lib/typescript/src/types/config.d.ts.map +1 -1
- package/lib/typescript/src/types/credentials.d.ts +2 -2
- package/lib/typescript/src/types/credentials.d.ts.map +1 -1
- package/lib/typescript/src/types/state.d.ts +4 -0
- package/lib/typescript/src/types/state.d.ts.map +1 -1
- package/lib/typescript/src/utils/agent.d.ts +4 -2
- package/lib/typescript/src/utils/agent.d.ts.map +1 -1
- package/lib/typescript/src/utils/network.d.ts +1 -0
- package/lib/typescript/src/utils/network.d.ts.map +1 -1
- package/lib/typescript/src/wallet/map-to-card.d.ts.map +1 -1
- package/package.json +6 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["getHostNameFromUrl","Linking","handleTextResponse","text","startsWith","success","result","format","type","data","json","JSON","parse","handleJsonResponse","error","Error","Array","isArray","fetchInvitationDataUrl","dataUrl","abortController","AbortController","timeout","setTimeout","abort","response","fetch","headers","Accept","clearTimeout","ok","contentType","get","includes","getCredentialsForProofRequest","agent","request","config","logger","info","resolved","modules","openid4vc","holder","resolveOpenId4VpAuthorizationRequest","presentationExchange","
|
|
1
|
+
{"version":3,"names":["ClaimFormat","CredentialMultiInstanceUseMode","getHostNameFromUrl","Linking","handleTextResponse","text","startsWith","success","result","format","type","data","json","JSON","parse","handleJsonResponse","error","Error","Array","isArray","fetchInvitationDataUrl","dataUrl","abortController","AbortController","timeout","setTimeout","abort","response","fetch","headers","Accept","clearTimeout","ok","contentType","get","includes","getCredentialsForProofRequest","agent","request","config","logger","info","resolved","modules","openid4vc","holder","resolveOpenId4VpAuthorizationRequest","presentationExchange","dcql","requestRecord","verifierHostName","authorizationRequestPayload","response_uri","String","undefined","createdAt","Date","err","message","getPexCredentialsForRequest","credentialsForRequest","selectedProofCredentials","areRequirementsSatisfied","Object","fromEntries","requirements","flatMap","requirement","submissionEntry","map","entry","credentialId","inputDescriptorId","id","credential","verifiableCredentials","find","vc","credentialRecord","getDcqlCredentialForRequest","validCredential","useMode","NewOrFirst","record","claimFormat","MsoMdoc","disclosedPayload","claims","valid_claim_sets","output","SdJwtDc","firstCredential","jsonCredential","getDcqlCredentialsForRequest","queryResult","can_be_satisfied","keys","length","selectCredentialsForDcqlRequest","entries","credentialQueryId","selectedCredential","match","credential_matches","validCredentials","from","valid_credentials","shareProof","_result$serverRespons","credentials","acceptOpenId4VpAuthorizationRequest","origin","serverResponse","body","redirect_uri","openURL","status"],"sourceRoot":"../../../../src","sources":["modules/openid/resolverProof.tsx"],"mappings":"AAAA,SAEEA,WAAW,EACXC,8BAA8B,QAOzB,gBAAgB;AAGvB,SAASC,kBAAkB,QAAQ,eAAe;AAClD,SAASC,OAAO,QAAQ,cAAc;AAWtC,SAASC,kBAAkBA,CAACC,IAAY,EAAyB;EAC/D;EACA,IAAIA,IAAI,CAACC,UAAU,CAAC,IAAI,CAAC,EAAE;IACzB,OAAO;MACLC,OAAO,EAAE,IAAI;MACbC,MAAM,EAAE;QACNC,MAAM,EAAE,QAAQ;QAChBC,IAAI,EAAE,8BAA8B;QACpCC,IAAI,EAAEN;MACR;IACF,CAAC;EACH;;EAEA;EACA,IAAI;IACF,MAAMO,IAAa,GAAGC,IAAI,CAACC,KAAK,CAACT,IAAI,CAAC;IACtC,OAAOU,kBAAkB,CAACH,IAAI,CAAC;;IA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;IAC3G,CAAC,GACDP,SAAS;IAEf,IAAI,CAACP,oBAAoB,IAAI,CAACC,IAAI,EAAE;MAClC,MAAM,IAAI/B,KAAK,CAAC,sFAAsF,CAAC;IACzG;IAEA,MAAMT,MAAM,GAAG,MAAM6B,KAAK,CAACO,SAAS,CAACC,MAAM,CAACiE,mCAAmC,CAAC;MAC9E3D,2BAA2B,EAAEF,aAAa,CAACE,2BAA2B;MACtEJ,oBAAoB;MACpBC,IAAI;MACJ+D,MAAM,EAAE9D,aAAa,CAAC8D;IACxB,CAAC,CAAC;;IAEF;IACA;IACA,IACEvG,MAAM,CAACwG,cAAc,IACrB,OAAOxG,MAAM,CAACwG,cAAc,CAACC,IAAI,KAAK,QAAQ,IAC9C,SAAAL,qBAAA,GAAOpG,MAAM,CAACwG,cAAc,CAACC,IAAI,cAAAL,qBAAA,uBAA1BA,qBAAA,CAA4BM,YAAY,MAAK,QAAQ,EAC5D;MACA,MAAM/G,OAAO,CAACgH,OAAO,CAAC3G,MAAM,CAACwG,cAAc,CAACC,IAAI,CAACC,YAAY,CAAC;IAChE;IAEA,IAAI1G,MAAM,CAACwG,cAAc,KAAKxG,MAAM,CAACwG,cAAc,CAACI,MAAM,GAAG,GAAG,IAAI5G,MAAM,CAACwG,cAAc,CAACI,MAAM,GAAG,GAAG,CAAC,EAAE;MACvG,MAAM,IAAInG,KAAK,CAAC,gDAAgDT,MAAM,CAACwG,cAAc,CAACC,IAAI,EAAY,CAAC;IACzG;IAEA,OAAOzG,MAAM;EACf,CAAC,CAAC,OAAOQ,KAAK,EAAE;IACd;IACA,MAAM,IAAIC,KAAK,CAAC,kCAAkC,CAACD,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAY0C,OAAO,KAAI1C,KAAK,EAAE,CAAC;EACzF;AACF,CAAC","ignoreList":[]}
|
|
@@ -79,8 +79,9 @@ const OpenIDConnection = ({
|
|
|
79
79
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(View, {
|
|
80
80
|
style: styles.pageContainer
|
|
81
81
|
}, /*#__PURE__*/React.createElement(LoadingSpinner, {
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
color: ColorPalette.brand.loadingIcon,
|
|
83
|
+
name: "loading",
|
|
84
|
+
size: 50
|
|
84
85
|
})), /*#__PURE__*/React.createElement(FullScreenErrorModal, {
|
|
85
86
|
errorTitle: (errorDetails === null || errorDetails === void 0 ? void 0 : errorDetails.title) ?? '',
|
|
86
87
|
errorDescription: (errorDetails === null || errorDetails === void 0 ? void 0 : errorDetails.description) ?? '',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useState","BackHandler","View","StyleSheet","DeviceEventEmitter","Screens","useServices","TOKENS","LoadingSpinner","EventTypes","FullScreenErrorModal","TabStacks","useTheme","useOpenID","isOpenIDCredentialRecord","isOpenIdProofRequestRecord","OpenIDConnection","navigation","route","openIDUri","openIDPresentationUri","params","logger","historyEnabled","UTIL_LOGGER","HISTORY_ENABLED","ColorPalette","notificationRecord","showErrorModal","setShowErrorModal","errorDetails","setErrorDetails","styles","create","pageContainer","flex","justifyContent","alignItems","trace","err","error","backHandler","addEventListener","remove","info","replace","OpenIDCredentialOffer","credential","OpenIDProofPresentation","handler","addListener","OPENID_CONNECTION_ERROR","createElement","Fragment","style","
|
|
1
|
+
{"version":3,"names":["React","useEffect","useState","BackHandler","View","StyleSheet","DeviceEventEmitter","Screens","useServices","TOKENS","LoadingSpinner","EventTypes","FullScreenErrorModal","TabStacks","useTheme","useOpenID","isOpenIDCredentialRecord","isOpenIdProofRequestRecord","OpenIDConnection","navigation","route","openIDUri","openIDPresentationUri","params","logger","historyEnabled","UTIL_LOGGER","HISTORY_ENABLED","ColorPalette","notificationRecord","showErrorModal","setShowErrorModal","errorDetails","setErrorDetails","styles","create","pageContainer","flex","justifyContent","alignItems","trace","err","error","backHandler","addEventListener","remove","info","replace","OpenIDCredentialOffer","credential","OpenIDProofPresentation","handler","addListener","OPENID_CONNECTION_ERROR","createElement","Fragment","style","color","brand","loadingIcon","name","size","errorTitle","title","errorDescription","description","visible","onPressCTA","_navigation$getParent","getParent","navigate","HomeStack","screen","Home"],"sourceRoot":"../../../../../src","sources":["modules/openid/screens/OpenIDConnection.tsx"],"mappings":"AACA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAClD,SAASC,WAAW,EAAEC,IAAI,EAAEC,UAAU,EAAEC,kBAAkB,QAAQ,cAAc;AAEhF,SAA8BC,OAAO,QAAQ,2BAA2B;AACxE,SAASC,WAAW,EAAEC,MAAM,QAAQ,wBAAwB;AAC5D,OAAOC,cAAc,MAAM,6CAA6C;AACxE,SAASC,UAAU,QAAQ,oBAAoB;AAC/C,OAAOC,oBAAoB,MAAM,iDAAiD;AAClF,SAASC,SAAS,QAAQ,2BAA2B;AAErD,SAASC,QAAQ,QAAQ,yBAAyB;AAClD,SAASC,SAAS,QAAQ,iBAAiB;AAC3C,SAASC,wBAAwB,EAAEC,0BAA0B,QAAQ,qBAAqB;AAI1F,MAAMC,gBAA2C,GAAGA,CAAC;EAAEC,UAAU;EAAEC;AAAM,CAAC,KAAK;EAC7E,MAAM;IAAEC,SAAS;IAAEC;EAAsB,CAAC,GAAGF,KAAK,CAACG,MAAM;EACzD,MAAM,CAACC,MAAM,EAAEC,cAAc,CAAC,GAAGjB,WAAW,CAAC,CAACC,MAAM,CAACiB,WAAW,EAAEjB,MAAM,CAACkB,eAAe,CAAC,CAAC;EAC1F,MAAM;IAAEC;EAAa,CAAC,GAAGd,QAAQ,CAAC,CAAC;EACnC,MAAMe,kBAAkB,GAAGd,SAAS,CAAC;IAAEM,SAAS;IAAEC;EAAsB,CAAC,CAAC;EAE1E,MAAM,CAACQ,cAAc,EAAEC,iBAAiB,CAAC,GAAG7B,QAAQ,CAAU,KAAK,CAAC;EACpE,MAAM,CAAC8B,YAAY,EAAEC,eAAe,CAAC,GAAG/B,QAAQ,CAAuB,CAAC,CAAC,CAAC;E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 const OpenIDCredentialDetails = ({
|
|
|
53
53
|
const {
|
|
54
54
|
removeCredential,
|
|
55
55
|
getW3CCredentialById,
|
|
56
|
-
getSdJwtCredentialById
|
|
56
|
+
getSdJwtCredentialById,
|
|
57
|
+
getMdocCredentialById
|
|
57
58
|
} = useOpenIDCredentials();
|
|
58
59
|
const [bundleResolver] = useServices([TOKENS.UTIL_OCA_RESOLVER]);
|
|
59
60
|
const [isRemoveModalDisplayed, setIsRemoveModalDisplayed] = useState(false);
|
|
@@ -82,6 +83,8 @@ const OpenIDCredentialDetails = ({
|
|
|
82
83
|
let record;
|
|
83
84
|
if (type === OpenIDCredentialType.SdJwtVc) {
|
|
84
85
|
record = await getSdJwtCredentialById(credentialId);
|
|
86
|
+
} else if (type === OpenIDCredentialType.Mdoc) {
|
|
87
|
+
record = await getMdocCredentialById(credentialId);
|
|
85
88
|
} else {
|
|
86
89
|
record = await getW3CCredentialById(credentialId);
|
|
87
90
|
}
|
|
@@ -92,7 +95,7 @@ const OpenIDCredentialDetails = ({
|
|
|
92
95
|
}
|
|
93
96
|
};
|
|
94
97
|
fetchCredential();
|
|
95
|
-
}, [credentialId, type, getSdJwtCredentialById, getW3CCredentialById, agent, t, credentialRemoved]);
|
|
98
|
+
}, [credentialId, type, getSdJwtCredentialById, getMdocCredentialById, getW3CCredentialById, agent, t, credentialRemoved]);
|
|
96
99
|
useEffect(() => {
|
|
97
100
|
if (!credential) return;
|
|
98
101
|
try {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useState","Screens","getCredentialForDisplay","CommonRemoveModal","ModalUsage","DeviceEventEmitter","StyleSheet","Text","View","useTranslation","testIdWithKey","useTheme","BifoldError","EventTypes","useAgent","RecordRemove","useOpenIDCredentials","OpenIDCredentialType","TOKENS","useServices","Record","buildOverlayFromW3cCredential","CredentialDetailSecondaryHeader","CredentialCardLogo","CredentialDetailPrimaryHeader","ScreenLayout","OpenIDCredentialCard","OpenIDCredScreenMode","paddingHorizontal","paddingVertical","OpenIDCredentialDetails","navigation","route","_overlay$brandingOver","credentialId","type","params","credential","setCredential","undefined","credentialDisplay","setCredentialDisplay","t","i18n","ColorPalette","TextTheme","agent","removeCredential","getW3CCredentialById","getSdJwtCredentialById","bundleResolver","UTIL_OCA_RESOLVER","isRemoveModalDisplayed","setIsRemoveModalDisplayed","credentialRemoved","setCredentialRemoved","overlay","setOverlay","bundle","presentationFields","metaOverlay","brandingOverlay","styles","create","container","backgroundColor","primaryBackgroundColor","display","cardContainer","fetchCredential","record","SdJwtVc","emit","ERROR_ADDED","credDisplay","resolveOverlay","resolvedOverlay","language","resolver","toggleDeclineModalVisible","handleDeclineTouched","Promise","resolve","setTimeout","handleRemove","pop","err","error","message","legacyHeader","createElement","style","renderOpenIdCard","credentialRecord","header","footer","marginBottom","brand","secondaryBackground","marginTop","testID","title","normal","issuer","name","onRemove","screen","fields","hideFieldValues","usage","CredentialRemove","visible","onSubmit","onCancel"],"sourceRoot":"../../../../../src","sources":["modules/openid/screens/OpenIDCredentialDetails.tsx"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAElD,SAA0BC,OAAO,QAAQ,2BAA2B;AACpE,SAASC,uBAAuB,QAAQ,YAAY;AACpD,OAAOC,iBAAiB,MAAM,8CAA8C;AAC5E,SAASC,UAAU,QAAQ,uBAAuB;AAClD,SAASC,kBAAkB,EAAEC,UAAU,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzE,SAASC,cAAc,QAAQ,eAAe;AAC9C,SAASC,aAAa,QAAQ,yBAAyB;AACvD,SAASC,QAAQ,QAAQ,yBAAyB;AAClD,SAASC,WAAW,QAAQ,sBAAsB;AAClD,SAASC,UAAU,QAAQ,oBAAoB;AAC/C,SAASC,QAAQ,QAAQ,qBAAqB;AAC9C,OAAOC,YAAY,MAAM,yCAAyC;AAClE,SAASC,oBAAoB,QAAQ,2CAA2C;AAEhF,SAASC,oBAAoB,QAA8B,UAAU;AACrE,SAASC,MAAM,EAAEC,WAAW,QAAQ,wBAAwB;AAE5D,OAAOC,MAAM,MAAM,mCAAmC;
|
|
1
|
+
{"version":3,"names":["React","useEffect","useState","Screens","getCredentialForDisplay","CommonRemoveModal","ModalUsage","DeviceEventEmitter","StyleSheet","Text","View","useTranslation","testIdWithKey","useTheme","BifoldError","EventTypes","useAgent","RecordRemove","useOpenIDCredentials","OpenIDCredentialType","TOKENS","useServices","Record","buildOverlayFromW3cCredential","CredentialDetailSecondaryHeader","CredentialCardLogo","CredentialDetailPrimaryHeader","ScreenLayout","OpenIDCredentialCard","OpenIDCredScreenMode","paddingHorizontal","paddingVertical","OpenIDCredentialDetails","navigation","route","_overlay$brandingOver","credentialId","type","params","credential","setCredential","undefined","credentialDisplay","setCredentialDisplay","t","i18n","ColorPalette","TextTheme","agent","removeCredential","getW3CCredentialById","getSdJwtCredentialById","getMdocCredentialById","bundleResolver","UTIL_OCA_RESOLVER","isRemoveModalDisplayed","setIsRemoveModalDisplayed","credentialRemoved","setCredentialRemoved","overlay","setOverlay","bundle","presentationFields","metaOverlay","brandingOverlay","styles","create","container","backgroundColor","primaryBackgroundColor","display","cardContainer","fetchCredential","record","SdJwtVc","Mdoc","emit","ERROR_ADDED","credDisplay","resolveOverlay","resolvedOverlay","language","resolver","toggleDeclineModalVisible","handleDeclineTouched","Promise","resolve","setTimeout","handleRemove","pop","err","error","message","legacyHeader","createElement","style","renderOpenIdCard","credentialRecord","header","footer","marginBottom","brand","secondaryBackground","marginTop","testID","title","normal","issuer","name","onRemove","screen","fields","hideFieldValues","usage","CredentialRemove","visible","onSubmit","onCancel"],"sourceRoot":"../../../../../src","sources":["modules/openid/screens/OpenIDCredentialDetails.tsx"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAElD,SAA0BC,OAAO,QAAQ,2BAA2B;AACpE,SAASC,uBAAuB,QAAQ,YAAY;AACpD,OAAOC,iBAAi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ranslation } from 'react-i18next';
|
|
2
2
|
import { FlatList, StyleSheet, TouchableOpacity, View } from 'react-native';
|
|
3
|
+
import { MdocRecord, SdJwtVcRecord, W3cCredentialRecord, W3cV2CredentialRecord } from '@credo-ts/core';
|
|
3
4
|
import React, { useEffect, useState } from 'react';
|
|
4
5
|
import RecordLoading from '../../../components/animated/RecordLoading';
|
|
5
6
|
import { ThemedText } from '../../../components/texts/ThemedText';
|
|
@@ -8,8 +9,8 @@ import ScreenLayout from '../../../layout/ScreenLayout';
|
|
|
8
9
|
import { Screens } from '../../../types/navigators';
|
|
9
10
|
import { testIdWithKey } from '../../../utils/testable';
|
|
10
11
|
import { useOpenIDCredentials } from '../context/OpenIDCredentialRecordProvider';
|
|
11
|
-
import { isSdJwtProofRequest, isW3CProofRequest } from '../utils/utils';
|
|
12
12
|
import CredentialCardGen from '../../../components/misc/CredentialCardGen';
|
|
13
|
+
const isDisplayableOpenIDProofCredential = credential => credential instanceof W3cCredentialRecord || credential instanceof W3cV2CredentialRecord || credential instanceof SdJwtVcRecord || credential instanceof MdocRecord;
|
|
13
14
|
const OpenIDProofCredentialSelect = ({
|
|
14
15
|
route,
|
|
15
16
|
navigation
|
|
@@ -25,8 +26,7 @@ const OpenIDProofCredentialSelect = ({
|
|
|
25
26
|
SelectedCredTheme
|
|
26
27
|
} = useTheme();
|
|
27
28
|
const {
|
|
28
|
-
|
|
29
|
-
getSdJwtCredentialById
|
|
29
|
+
getCredentialById
|
|
30
30
|
} = useOpenIDCredentials();
|
|
31
31
|
const {
|
|
32
32
|
t
|
|
@@ -42,13 +42,8 @@ const OpenIDProofCredentialSelect = ({
|
|
|
42
42
|
id,
|
|
43
43
|
claimFormat
|
|
44
44
|
} of Object.values(altCredentials)) {
|
|
45
|
-
|
|
46
|
-
if (
|
|
47
|
-
credential = await getW3CCredentialById(id);
|
|
48
|
-
} else if (isSdJwtProofRequest(claimFormat)) {
|
|
49
|
-
credential = await getSdJwtCredentialById(id);
|
|
50
|
-
}
|
|
51
|
-
if (credential) {
|
|
45
|
+
const credential = await getCredentialById(id);
|
|
46
|
+
if (credential && isDisplayableOpenIDProofCredential(credential)) {
|
|
52
47
|
creds.push({
|
|
53
48
|
credential,
|
|
54
49
|
claimFormat
|
|
@@ -59,7 +54,7 @@ const OpenIDProofCredentialSelect = ({
|
|
|
59
54
|
setLoading(false);
|
|
60
55
|
}
|
|
61
56
|
fetchCreds();
|
|
62
|
-
}, [altCredentials,
|
|
57
|
+
}, [altCredentials, getCredentialById]);
|
|
63
58
|
const styles = StyleSheet.create({
|
|
64
59
|
pageContainer: {
|
|
65
60
|
flex: 1
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useTranslation","FlatList","StyleSheet","TouchableOpacity","View","React","useEffect","useState","RecordLoading","ThemedText","useTheme","ScreenLayout","Screens","testIdWithKey","useOpenIDCredentials","
|
|
1
|
+
{"version":3,"names":["useTranslation","FlatList","StyleSheet","TouchableOpacity","View","MdocRecord","SdJwtVcRecord","W3cCredentialRecord","W3cV2CredentialRecord","React","useEffect","useState","RecordLoading","ThemedText","useTheme","ScreenLayout","Screens","testIdWithKey","useOpenIDCredentials","CredentialCardGen","isDisplayableOpenIDProofCredential","credential","OpenIDProofCredentialSelect","route","navigation","params","Error","selectedCredentialID","selectedCredID","altCredentials","altCredIDs","onCredChange","ColorPalette","SelectedCredTheme","getCredentialById","t","loading","setLoading","credentialsRequested","setCredentialsRequested","fetchCreds","creds","id","claimFormat","Object","values","push","styles","create","pageContainer","flex","pageMargin","marginHorizontal","cardLoading","backgroundColor","brand","secondaryBackground","flexGrow","marginVertical","borderRadius","paddingHorizontal","changeCred","selection","inputDescriptorID","goBack","listHeader","createElement","style","marginTop","marginBottom","variant","screen","data","ListHeaderComponent","renderItem","item","accessibilityRole","testID","onPress","undefined"],"sourceRoot":"../../../../../src","sources":["modules/openid/screens/OpenIDProofChangeCredential.tsx"],"mappings":"AACA,SAASA,cAAc,QAAQ,eAAe;AAC9C,SAASC,QAAQ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CAACtD,UAAU,CAACqB,EAAE,KAAKf,oBAAoB,GAAGM,iBAAiB,GAAG8C,SAAS,EAC3E;UAAEV,YAAY,EAAE;QAAG,CAAC;MACpB,gBAEF5D,KAAA,CAAAyD,aAAA,CAAC/C,iBAAiB;QAACE,UAAU,EAAEsD,IAAI,CAACtD;MAAW,CAAoB,CACnD,CACd,CAAC;IAEX;EAAE,CACO,CACC,CAAC;AAEnB,CAAC;AAED,eAAeC,2BAA2B","ignoreList":[]}
|
|
@@ -1,26 +1,19 @@
|
|
|
1
1
|
import { useAgent } from '@bifold/react-hooks';
|
|
2
2
|
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
3
3
|
import { useTranslation } from 'react-i18next';
|
|
4
|
-
import { DeviceEventEmitter } from 'react-native';
|
|
5
|
-
import { ScrollView, StyleSheet, Text, View } from 'react-native';
|
|
6
|
-
import Button, { ButtonType } from '../../../components/buttons/Button';
|
|
7
|
-
import OpenIDUnsatisfiedProofRequest from '../components/OpenIDUnsatisfiedProofRequest';
|
|
4
|
+
import { DeviceEventEmitter, View, StyleSheet, Text } from 'react-native';
|
|
8
5
|
import CommonRemoveModal from '../../../components/modals/CommonRemoveModal';
|
|
9
6
|
import { EventTypes } from '../../../constants';
|
|
10
|
-
import { useTheme } from '../../../contexts/theme';
|
|
11
7
|
import ScreenLayout from '../../../layout/ScreenLayout';
|
|
12
8
|
import ProofRequestAccept from '../../../screens/ProofRequestAccept';
|
|
13
9
|
import { BifoldError } from '../../../types/error';
|
|
14
10
|
import { Screens, TabStacks } from '../../../types/navigators';
|
|
15
11
|
import { ModalUsage } from '../../../types/remove';
|
|
16
|
-
import { buildFieldsFromW3cCredsCredential } from '../../../utils/oca';
|
|
17
|
-
import { testIdWithKey } from '../../../utils/testable';
|
|
18
12
|
import { useOpenIDCredentials } from '../context/OpenIDCredentialRecordProvider';
|
|
19
|
-
import
|
|
20
|
-
import {
|
|
13
|
+
import OpenIdProofRequestDisplay from '../features/OpenIDProofPresentation/OpenIDProofRequestDisplay';
|
|
14
|
+
import { useTheme } from '../../../contexts/theme';
|
|
15
|
+
import { formatOpenIdProofRequest } from '../displayProof';
|
|
21
16
|
import { shareProof } from '../resolverProof';
|
|
22
|
-
import { isSdJwtProofRequest, isW3CProofRequest } from '../utils/utils';
|
|
23
|
-
import CredentialCardGen from '../../../components/misc/CredentialCardGen';
|
|
24
17
|
const OpenIDProofPresentation = ({
|
|
25
18
|
navigation,
|
|
26
19
|
route: {
|
|
@@ -29,6 +22,9 @@ const OpenIDProofPresentation = ({
|
|
|
29
22
|
}
|
|
30
23
|
}
|
|
31
24
|
}) => {
|
|
25
|
+
const {
|
|
26
|
+
TextTheme
|
|
27
|
+
} = useTheme();
|
|
32
28
|
const [declineModalVisible, setDeclineModalVisible] = useState(false);
|
|
33
29
|
const [buttonsVisible, setButtonsVisible] = useState(true);
|
|
34
30
|
const [acceptModalVisible, setAcceptModalVisible] = useState(false);
|
|
@@ -36,14 +32,8 @@ const OpenIDProofPresentation = ({
|
|
|
36
32
|
const [satistfiedCredentialsSubmission, setSatistfiedCredentialsSubmission] = useState();
|
|
37
33
|
const [selectedCredentialsSubmission, setSelectedCredentialsSubmission] = useState();
|
|
38
34
|
const {
|
|
39
|
-
|
|
40
|
-
getSdJwtCredentialById
|
|
35
|
+
getCredentialById
|
|
41
36
|
} = useOpenIDCredentials();
|
|
42
|
-
const {
|
|
43
|
-
ColorPalette,
|
|
44
|
-
ListItems,
|
|
45
|
-
TextTheme
|
|
46
|
-
} = useTheme();
|
|
47
37
|
const {
|
|
48
38
|
t
|
|
49
39
|
} = useTranslation();
|
|
@@ -51,51 +41,7 @@ const OpenIDProofPresentation = ({
|
|
|
51
41
|
agent
|
|
52
42
|
} = useAgent();
|
|
53
43
|
const toggleDeclineModalVisible = () => setDeclineModalVisible(!declineModalVisible);
|
|
54
|
-
const
|
|
55
|
-
pageContent: {
|
|
56
|
-
flexGrow: 1,
|
|
57
|
-
justifyContent: 'space-between',
|
|
58
|
-
padding: 10
|
|
59
|
-
},
|
|
60
|
-
credentialsList: {
|
|
61
|
-
marginTop: 20,
|
|
62
|
-
justifyContent: 'space-between'
|
|
63
|
-
},
|
|
64
|
-
headerTextContainer: {
|
|
65
|
-
paddingVertical: 16
|
|
66
|
-
},
|
|
67
|
-
headerText: {
|
|
68
|
-
...ListItems.recordAttributeText,
|
|
69
|
-
flexShrink: 1
|
|
70
|
-
},
|
|
71
|
-
footerButton: {
|
|
72
|
-
paddingVertical: 10
|
|
73
|
-
},
|
|
74
|
-
cardContainer: {
|
|
75
|
-
paddingHorizontal: 25,
|
|
76
|
-
paddingVertical: 16,
|
|
77
|
-
backgroundColor: ColorPalette.brand.secondaryBackground,
|
|
78
|
-
marginBottom: 20
|
|
79
|
-
},
|
|
80
|
-
cardAttributes: {
|
|
81
|
-
flexDirection: 'row',
|
|
82
|
-
flexWrap: 'wrap',
|
|
83
|
-
borderColor: ColorPalette.grayscale.lightGrey,
|
|
84
|
-
borderWidth: 1,
|
|
85
|
-
borderRadius: 8,
|
|
86
|
-
padding: 8
|
|
87
|
-
},
|
|
88
|
-
cardGroupContainer: {
|
|
89
|
-
borderRadius: 8,
|
|
90
|
-
borderWidth: 2,
|
|
91
|
-
borderColor: 'rgba(255, 255, 255, 0.2)'
|
|
92
|
-
},
|
|
93
|
-
cardGroupHeader: {
|
|
94
|
-
padding: 8,
|
|
95
|
-
marginVertical: 8
|
|
96
|
-
}
|
|
97
|
-
});
|
|
98
|
-
const submission = useMemo(() => credential && credential.credentialsForRequest ? formatDifPexCredentialsForRequest(credential.credentialsForRequest) : undefined, [credential]);
|
|
44
|
+
const submission = useMemo(() => credential ? formatOpenIdProofRequest(credential) : undefined, [credential]);
|
|
99
45
|
|
|
100
46
|
//This should run only once when the screen is mounted
|
|
101
47
|
useEffect(() => {
|
|
@@ -117,15 +63,9 @@ const OpenIDProofPresentation = ({
|
|
|
117
63
|
const creds = [];
|
|
118
64
|
for (const [inputDescriptorID, credIDs] of Object.entries(satistfiedCredentialsSubmission)) {
|
|
119
65
|
for (const {
|
|
120
|
-
id
|
|
121
|
-
claimFormat
|
|
66
|
+
id
|
|
122
67
|
} of credIDs) {
|
|
123
|
-
|
|
124
|
-
if (isW3CProofRequest(claimFormat)) {
|
|
125
|
-
credential = await getW3CCredentialById(id);
|
|
126
|
-
} else if (isSdJwtProofRequest(claimFormat)) {
|
|
127
|
-
credential = await getSdJwtCredentialById(id);
|
|
128
|
-
}
|
|
68
|
+
const credential = await getCredentialById(id);
|
|
129
69
|
if (credential && inputDescriptorID) {
|
|
130
70
|
creds.push(credential);
|
|
131
71
|
}
|
|
@@ -134,7 +74,7 @@ const OpenIDProofPresentation = ({
|
|
|
134
74
|
setCredentialsRequested(creds);
|
|
135
75
|
}
|
|
136
76
|
fetchCreds();
|
|
137
|
-
}, [satistfiedCredentialsSubmission,
|
|
77
|
+
}, [satistfiedCredentialsSubmission, getCredentialById]);
|
|
138
78
|
|
|
139
79
|
//Once satisfied credentials are set and all credentials fetched, we select the first one of each submission to display on screen
|
|
140
80
|
useEffect(() => {
|
|
@@ -158,14 +98,13 @@ const OpenIDProofPresentation = ({
|
|
|
158
98
|
}, [credential]);
|
|
159
99
|
const handleAcceptTouched = async () => {
|
|
160
100
|
try {
|
|
161
|
-
if (!agent || !
|
|
101
|
+
if (!agent || !selectedCredentialsSubmission) {
|
|
162
102
|
return;
|
|
163
103
|
}
|
|
164
104
|
await shareProof({
|
|
165
105
|
agent,
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
selectedCredentials: selectedCredentialsSubmission
|
|
106
|
+
requestRecord: credential,
|
|
107
|
+
selectedProofCredentials: selectedCredentialsSubmission
|
|
169
108
|
});
|
|
170
109
|
setAcceptModalVisible(true);
|
|
171
110
|
} catch (err) {
|
|
@@ -175,15 +114,12 @@ const OpenIDProofPresentation = ({
|
|
|
175
114
|
}
|
|
176
115
|
};
|
|
177
116
|
const handleDeclineTouched = async () => {
|
|
178
|
-
var _navigation$getParent;
|
|
179
117
|
toggleDeclineModalVisible();
|
|
180
|
-
(_navigation$getParent = navigation.getParent()) === null || _navigation$getParent === void 0 || _navigation$getParent.navigate(TabStacks.HomeStack, {
|
|
181
|
-
screen: Screens.Home
|
|
182
|
-
});
|
|
183
118
|
};
|
|
184
119
|
const handleDismiss = async () => {
|
|
185
|
-
var _navigation$
|
|
186
|
-
(
|
|
120
|
+
var _navigation$getParent;
|
|
121
|
+
toggleDeclineModalVisible();
|
|
122
|
+
(_navigation$getParent = navigation.getParent()) === null || _navigation$getParent === void 0 || _navigation$getParent.navigate(TabStacks.HomeStack, {
|
|
187
123
|
screen: Screens.Home
|
|
188
124
|
});
|
|
189
125
|
};
|
|
@@ -202,9 +138,11 @@ const OpenIDProofPresentation = ({
|
|
|
202
138
|
}
|
|
203
139
|
}));
|
|
204
140
|
};
|
|
205
|
-
const handleAltCredChange = useCallback((inputDescriptorID, selectedCredID
|
|
206
|
-
const
|
|
207
|
-
|
|
141
|
+
const handleAltCredChange = useCallback((inputDescriptorID, selectedCredID) => {
|
|
142
|
+
const submissionEntries = submission === null || submission === void 0 ? void 0 : submission.entries.find(entry => {
|
|
143
|
+
return entry.inputDescriptorId === inputDescriptorID;
|
|
144
|
+
});
|
|
145
|
+
const credsForEntry = submissionEntries === null || submissionEntries === void 0 ? void 0 : submissionEntries.credentials;
|
|
208
146
|
if (!credsForEntry) return;
|
|
209
147
|
navigation.navigate(Screens.OpenIDProofCredentialSelect, {
|
|
210
148
|
inputDescriptorID: inputDescriptorID,
|
|
@@ -218,120 +156,38 @@ const OpenIDProofPresentation = ({
|
|
|
218
156
|
onCredChange: onCredChange
|
|
219
157
|
});
|
|
220
158
|
}, [submission, navigation]);
|
|
221
|
-
const
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
style: styles.headerText,
|
|
227
|
-
testID: testIdWithKey('HeaderText')
|
|
228
|
-
}, /*#__PURE__*/React.createElement(Text, {
|
|
229
|
-
style: TextTheme.normal
|
|
230
|
-
}, t('ProofRequest.ReceiveProofTitle')), '\n', /*#__PURE__*/React.createElement(Text, {
|
|
231
|
-
style: TextTheme.title
|
|
232
|
-
}, verifierName ? verifierName : '')));
|
|
233
|
-
};
|
|
234
|
-
const renderCard = (sub, selectedCredential, hasMultipleCreds) => {
|
|
235
|
-
const credential = credentialsRequested.find(c => c.id === selectedCredential.id);
|
|
236
|
-
if (!credential) {
|
|
237
|
-
return null;
|
|
238
|
-
}
|
|
239
|
-
const credentialDisplay = getCredentialForDisplay(credential);
|
|
240
|
-
const requestedAttributes = selectedCredential.requestedAttributes;
|
|
241
|
-
const fields = buildFieldsFromW3cCredsCredential(credentialDisplay, requestedAttributes);
|
|
242
|
-
return /*#__PURE__*/React.createElement(CredentialCardGen, {
|
|
243
|
-
credential: credential,
|
|
244
|
-
displayItems: fields,
|
|
245
|
-
hasAltCredentials: hasMultipleCreds,
|
|
246
|
-
handleAltCredChange: () => {
|
|
247
|
-
handleAltCredChange(sub.inputDescriptorId, selectedCredential.id, sub.inputDescriptorId);
|
|
248
|
-
}
|
|
249
|
-
});
|
|
250
|
-
};
|
|
251
|
-
const renderBody = () => {
|
|
252
|
-
if (submission && !submission.areAllSatisfied) {
|
|
253
|
-
return /*#__PURE__*/React.createElement(OpenIDUnsatisfiedProofRequest, {
|
|
254
|
-
credentialName: submission === null || submission === void 0 ? void 0 : submission.name,
|
|
255
|
-
requestPurpose: submission === null || submission === void 0 ? void 0 : submission.purpose,
|
|
256
|
-
verifierName: verifierName
|
|
257
|
-
});
|
|
258
|
-
}
|
|
259
|
-
if (!selectedCredentialsSubmission || !submission) return;
|
|
260
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
261
|
-
style: styles.credentialsList
|
|
262
|
-
}, Object.entries(selectedCredentialsSubmission).map(([inputDescriptorId, credentialSimplified], i) => {
|
|
263
|
-
var _submission$entries;
|
|
264
|
-
//TODO: Support multiplae credentials
|
|
265
|
-
|
|
266
|
-
const globalSubmissionName = submission.name;
|
|
267
|
-
const globalSubmissionPurpose = submission.purpose;
|
|
268
|
-
const correspondingSubmission = (_submission$entries = submission.entries) === null || _submission$entries === void 0 ? void 0 : _submission$entries.find(s => s.inputDescriptorId === inputDescriptorId);
|
|
269
|
-
const submissionName = correspondingSubmission === null || correspondingSubmission === void 0 ? void 0 : correspondingSubmission.name;
|
|
270
|
-
const submissionPurpose = correspondingSubmission === null || correspondingSubmission === void 0 ? void 0 : correspondingSubmission.purpose;
|
|
271
|
-
const isSatisfied = correspondingSubmission === null || correspondingSubmission === void 0 ? void 0 : correspondingSubmission.isSatisfied;
|
|
272
|
-
const credentialSubmittion = correspondingSubmission === null || correspondingSubmission === void 0 ? void 0 : correspondingSubmission.credentials.find(s => s.id === credentialSimplified.id);
|
|
273
|
-
const requestedAttributes = credentialSubmittion === null || credentialSubmittion === void 0 ? void 0 : credentialSubmittion.requestedAttributes;
|
|
274
|
-
const name = submissionName || globalSubmissionName || undefined;
|
|
275
|
-
const purpose = submissionPurpose || globalSubmissionPurpose || undefined;
|
|
276
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
277
|
-
key: i
|
|
278
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
279
|
-
style: styles.cardContainer
|
|
280
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
281
|
-
style: styles.cardGroupContainer
|
|
282
|
-
}, name && purpose && /*#__PURE__*/React.createElement(View, {
|
|
283
|
-
style: styles.cardGroupHeader
|
|
284
|
-
}, /*#__PURE__*/React.createElement(Text, {
|
|
285
|
-
style: TextTheme.bold
|
|
286
|
-
}, name), /*#__PURE__*/React.createElement(Text, {
|
|
287
|
-
style: TextTheme.labelTitle
|
|
288
|
-
}, purpose)), isSatisfied && requestedAttributes ? renderCard(correspondingSubmission, credentialSubmittion, correspondingSubmission.credentials.length > 1) : null)));
|
|
289
|
-
}));
|
|
290
|
-
};
|
|
291
|
-
const footerButton = (title, buttonPress, buttonType, testID, accessibilityLabel) => {
|
|
292
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
293
|
-
style: styles.footerButton
|
|
294
|
-
}, /*#__PURE__*/React.createElement(Button, {
|
|
295
|
-
title: title,
|
|
296
|
-
accessibilityLabel: accessibilityLabel,
|
|
297
|
-
testID: testID,
|
|
298
|
-
buttonType: buttonType,
|
|
299
|
-
onPress: buttonPress,
|
|
300
|
-
disabled: !buttonsVisible
|
|
301
|
-
}));
|
|
302
|
-
};
|
|
303
|
-
const footer = () => {
|
|
304
|
-
if (submission && !submission.areAllSatisfied) {
|
|
305
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
306
|
-
style: {
|
|
307
|
-
paddingHorizontal: 25,
|
|
308
|
-
paddingVertical: 16,
|
|
309
|
-
paddingBottom: 26,
|
|
310
|
-
backgroundColor: ColorPalette.brand.secondaryBackground
|
|
311
|
-
}
|
|
312
|
-
}, footerButton(t('Global.Dismiss'), handleDismiss, ButtonType.Primary, testIdWithKey('DismissCredentialOffer'), t('Global.Dismiss')));
|
|
159
|
+
const styles = StyleSheet.create({
|
|
160
|
+
headerContainer: {
|
|
161
|
+
paddingVertical: 20,
|
|
162
|
+
justifyContent: 'center',
|
|
163
|
+
alignItems: 'center'
|
|
313
164
|
}
|
|
314
|
-
|
|
315
|
-
style: {
|
|
316
|
-
paddingHorizontal: 25,
|
|
317
|
-
paddingVertical: 16,
|
|
318
|
-
paddingBottom: 26,
|
|
319
|
-
backgroundColor: ColorPalette.brand.secondaryBackground
|
|
320
|
-
}
|
|
321
|
-
}, selectedCredentialsSubmission && Object.keys(selectedCredentialsSubmission).length > 0 ? /*#__PURE__*/React.createElement(React.Fragment, null, footerButton(t('Global.Send'), handleAcceptTouched, ButtonType.Primary, testIdWithKey('AcceptCredentialOffer'), t('Global.Send')), footerButton(t('Global.Decline'), toggleDeclineModalVisible, ButtonType.Secondary, testIdWithKey('DeclineCredentialOffer'), t('Global.Decline'))) : /*#__PURE__*/React.createElement(React.Fragment, null, footerButton(t('Global.Dismiss'), handleDismiss, ButtonType.Primary, testIdWithKey('DismissCredentialOffer'), t('Global.Dismiss'))));
|
|
322
|
-
};
|
|
165
|
+
});
|
|
323
166
|
return /*#__PURE__*/React.createElement(ScreenLayout, {
|
|
324
|
-
screen: Screens.
|
|
325
|
-
}, /*#__PURE__*/React.createElement(
|
|
326
|
-
style: styles.
|
|
327
|
-
},
|
|
167
|
+
screen: Screens.OpenIDProofPresentation
|
|
168
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
169
|
+
style: styles.headerContainer
|
|
170
|
+
}, /*#__PURE__*/React.createElement(Text, {
|
|
171
|
+
style: TextTheme.headerTitle
|
|
172
|
+
}, t('ProofRequest.OID4VCTitle'))), /*#__PURE__*/React.createElement(OpenIdProofRequestDisplay, {
|
|
173
|
+
buttonsVisible: buttonsVisible,
|
|
174
|
+
credential: credential,
|
|
175
|
+
credentialsRequested: credentialsRequested,
|
|
176
|
+
onPressAltCredChange: handleAltCredChange,
|
|
177
|
+
onPressAccept: handleAcceptTouched,
|
|
178
|
+
onPressDecline: handleDeclineTouched,
|
|
179
|
+
onPressDismiss: handleDismiss,
|
|
180
|
+
selectedCredentialsSubmission: selectedCredentialsSubmission,
|
|
181
|
+
submission: submission,
|
|
182
|
+
verifierName: verifierName
|
|
183
|
+
}), /*#__PURE__*/React.createElement(ProofRequestAccept, {
|
|
328
184
|
visible: acceptModalVisible,
|
|
329
185
|
proofId: '',
|
|
330
186
|
confirmationOnly: true
|
|
331
187
|
}), /*#__PURE__*/React.createElement(CommonRemoveModal, {
|
|
332
188
|
usage: ModalUsage.ProofRequestDecline,
|
|
333
189
|
visible: declineModalVisible,
|
|
334
|
-
onSubmit:
|
|
190
|
+
onSubmit: handleDismiss,
|
|
335
191
|
onCancel: toggleDeclineModalVisible
|
|
336
192
|
}));
|
|
337
193
|
};
|