From 56926769d075ce70dc59696a54b4f9ed308ae88c Mon Sep 17 00:00:00 2001 From: Alka Prasad Date: Mon, 4 Mar 2024 17:35:49 +0530 Subject: [PATCH] Reverse Sync Release 0.11.0 into develop (#1326) * fix cancel download popup not shown Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * fix: show tuvali version Co-authored-by: vijay151096 <94220135+vijay151096@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * downgrade tuvali version to 0.4.6 for qa testing (#1149) Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "downgrade tuvali version to 0.4.6 for qa testing (#1149)" This reverts commit 633f42f65f07612f4ed628c650841a12c034e235. Signed-off-by: Swati Goel * Resetting the Data_Backup Toggle (#1202) * [INJI-766] set backupAndRestore env variable to true and remove full stop in the kan langugage in one of the help page question Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJI-766] remove backupAndRestore variable from env file Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "Merge pull request #1227 from tw-mosip/internal-release-01-02-2024" (#1242) This reverts commit 6de62fccb67f7b1da4219ea79edeba6dc56aeb10, reversing changes made to f63445fc0821311bb005880ab4c5ed8d1179a630. Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [Internal-Release-20+] : Sunbird Changes (#1243) * [INJIMOB-683]: add testid for missed vc field (#1226) * [INJIMOB-683]: add testid for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's (#1225) * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * downgrade cocoapods version (#1231) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * Use latest cocoapods version (#1236) * downgrade cocoapods version Signed-off-by: adityankannan-tw * use latest cocoapods version Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw * [INJIMOB-760]: update mosip Logo Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add backup & restore in iOS (iCloud) (#119) * [INJIMOB-752] - Added basic backup and restore flow for iCloud Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] show proceed screen based on stored value Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] fetch last backup details of iCloud Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] show permision required screen when not signed in on iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] retry to sync unsynced file if exists while fetching last backup details Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added sync and open settings Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - Add missing translations and refactor Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - refactoring Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup (#1253) * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove backup and restore toggle Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] sync style of newLabel in purple and default theme Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove debug logs Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] rename file googleCloudUtils to CloudBackupAndRestoreUtils Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] return no backup faile error when backupfiles list from cloud is empty Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add initail state in downloadingCredential to fix warning Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added delayed visibility for backup screen Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> --------- Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-787] Conditional restore of VCs (#120) * [INJI-787] add bootstrap state for restarting restore ops Notes: - all operations depend on the state of the $DOCUMENT_DIR/inji/backup/ directory contents and not on the state of the MMKV DB Signed-off-by: Harsh Vardhan * [INJI-787] conditional restore on restart of restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] fix recent file finder code Signed-off-by: Harsh Vardhan * [INJIMOB-787] add vc remove logic for partial restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] refactor, ACK reviews, rm dead condition Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove console.logs Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove irrelevant TODOs Signed-off-by: Harsh Vardhan --------- Signed-off-by: Harsh Vardhan * Revert "Inji mob 737 rtl issue (#1238)" This reverts commit 2665cdeee193d7fb428fc10354f30cc25084b83d. * [INJIMOB-760]: adjust the mosip logo in the issuer section Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * Inji 787 Xstate refactor (#1262) * [INJIMOB-837] update bundle id and team id for ios (#1273) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * [Injimob-685] fix download error issue which we are getting when the received vc is tampered or when the vc is not stored properly (#1271) * [INJIMOB-834] ignore corrupted VC while performing backup (#1253) * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-837] update ios version and bundle id (#1256) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * INJIMOB - 837 - Update developer team id to match profiles (#1258) * [INJIMOB-837] update ios version and bundle id Signed-off-by: adityankannan-tw * [INJIMOB-837] update the developer team to match profiles Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * Inji 752 backup to iCloud (#1251) * [INJIMOB-760]: update mosip Logo Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added basic backup and restore flow for iCloud Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] show proceed screen based on stored value Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] fetch last backup details of iCloud Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] show permision required screen when not signed in on iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] retry to sync unsynced file if exists while fetching last backup details Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added sync and open settings Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - Add missing translations and refactor Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - refactoring Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove backup and restore toggle Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] sync style of newLabel in purple and default theme Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove debug logs Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] rename file googleCloudUtils to CloudBackupAndRestoreUtils Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] return no backup faile error when backupfiles list from cloud is empty Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add initail state in downloadingCredential to fix warning Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added delayed visibility for backup screen Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] fix delay in databackup and restore screen Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: Vijay <94220135+vijay151096@users.noreply.github.com> Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Swati Goel * [Reverse-Sync-14-02-2024] : Sunbird Integration & Data Backup and Restore Implementation (#1261) * fix cancel download popup not shown Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * fix: show tuvali version Co-authored-by: vijay151096 <94220135+vijay151096@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * downgrade tuvali version to 0.4.6 for qa testing (#1149) Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "downgrade tuvali version to 0.4.6 for qa testing (#1149)" This reverts commit 633f42f65f07612f4ed628c650841a12c034e235. Signed-off-by: Swati Goel * Resetting the Data_Backup Toggle (#1202) * [INJI-766] set backupAndRestore env variable to true and remove full stop in the kan langugage in one of the help page question Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJI-766] remove backupAndRestore variable from env file Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "Merge pull request #1227 from tw-mosip/internal-release-01-02-2024" (#1242) This reverts commit 6de62fccb67f7b1da4219ea79edeba6dc56aeb10, reversing changes made to f63445fc0821311bb005880ab4c5ed8d1179a630. Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [Internal-Release-20+] : Sunbird Changes (#1243) * [INJIMOB-683]: add testid for missed vc field (#1226) * [INJIMOB-683]: add testid for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's (#1225) * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * downgrade cocoapods version (#1231) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * Use latest cocoapods version (#1236) * downgrade cocoapods version Signed-off-by: adityankannan-tw * use latest cocoapods version Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw * [INJIMOB-760]: update mosip Logo Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add backup & restore in iOS (iCloud) (#119) * [INJIMOB-752] - Added basic backup and restore flow for iCloud Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] show proceed screen based on stored value Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] fetch last backup details of iCloud Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] show permision required screen when not signed in on iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] retry to sync unsynced file if exists while fetching last backup details Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added sync and open settings Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - Add missing translations and refactor Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - refactoring Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup (#1253) * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove backup and restore toggle Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] sync style of newLabel in purple and default theme Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove debug logs Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] rename file googleCloudUtils to CloudBackupAndRestoreUtils Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] return no backup faile error when backupfiles list from cloud is empty Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add initail state in downloadingCredential to fix warning Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added delayed visibility for backup screen Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> --------- Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-787] Conditional restore of VCs (#120) * [INJI-787] add bootstrap state for restarting restore ops Notes: - all operations depend on the state of the $DOCUMENT_DIR/inji/backup/ directory contents and not on the state of the MMKV DB Signed-off-by: Harsh Vardhan * [INJI-787] conditional restore on restart of restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] fix recent file finder code Signed-off-by: Harsh Vardhan * [INJIMOB-787] add vc remove logic for partial restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] refactor, ACK reviews, rm dead condition Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove console.logs Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove irrelevant TODOs Signed-off-by: Harsh Vardhan --------- Signed-off-by: Harsh Vardhan * Revert "Inji mob 737 rtl issue (#1238)" This reverts commit 2665cdeee193d7fb428fc10354f30cc25084b83d. * [INJIMOB-760]: adjust the mosip logo in the issuer section Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: Swati Goel Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: Harsh Vardhan Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Swati Goel Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Co-authored-by: Pooja Babusingh <68894211+PoojaBabusingh@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: Harsh Vardhan * [INJIMOB-685] remove received vc metadata from storage when it is tampered or failed to store vc into storage Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Injimob 837 - Update the bundle id for new app (#1263) * [INJIMOB-837] update ios version and bundle id Signed-off-by: adityankannan-tw * [INJIMOB-837] update the developer team to match profiles Signed-off-by: adityankannan-tw * [INJIMOB-837] update the flavor with correct id Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * [INJIMOB-685] remove redundant store error in request machine Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-837] update the flavor with correct id (#1265) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * [INJIMOB-685] remove redundant logic to remove the tampered vc metadata Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-685] fix the logic of checking if tampered vc is myvc or received vc Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-685] fix tampering of received vcs If the received vc is tampered, we should be deleting the vc file & metadata of it. Since the metadata removal was not performed, we were getting download error. This is resolved here. Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-787] refactor backup & restore state machine (#1266) * fix cancel download popup not shown Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * fix: show tuvali version Co-authored-by: vijay151096 <94220135+vijay151096@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * downgrade tuvali version to 0.4.6 for qa testing (#1149) Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "downgrade tuvali version to 0.4.6 for qa testing (#1149)" This reverts commit 633f42f65f07612f4ed628c650841a12c034e235. Signed-off-by: Swati Goel * Resetting the Data_Backup Toggle (#1202) * [INJI-766] set backupAndRestore env variable to true and remove full stop in the kan langugage in one of the help page question Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJI-766] remove backupAndRestore variable from env file Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * Revert "Merge pull request #1227 from tw-mosip/internal-release-01-02-2024" (#1242) This reverts commit 6de62fccb67f7b1da4219ea79edeba6dc56aeb10, reversing changes made to f63445fc0821311bb005880ab4c5ed8d1179a630. Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [Internal-Release-20+] : Sunbird Changes (#1243) * [INJIMOB-683]: add testid for missed vc field (#1226) * [INJIMOB-683]: add testid for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-683]: add testidprops for missed vc field Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's (#1225) * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-770]: parse date received in the vc's Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * downgrade cocoapods version (#1231) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * Use latest cocoapods version (#1236) * downgrade cocoapods version Signed-off-by: adityankannan-tw * use latest cocoapods version Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw * [INJIMOB-760]: update mosip Logo Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add backup & restore in iOS (iCloud) (#119) * [INJIMOB-752] - Added basic backup and restore flow for iCloud Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] show proceed screen based on stored value Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] fetch last backup details of iCloud Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] show permision required screen when not signed in on iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] retry to sync unsynced file if exists while fetching last backup details Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added sync and open settings Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - Add missing translations and refactor Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-752] - refactoring Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-834] ignore corrupted VC while performing backup (#1253) * [INJIMOB-834] ignore corrupted VC while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-834] remove corrupted VC metaData while performing backup Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] download any unsynced files during lang setup in iOS Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove backup and restore toggle Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] sync style of newLabel in purple and default theme Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] remove debug logs Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] rename file googleCloudUtils to CloudBackupAndRestoreUtils Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] return no backup faile error when backupfiles list from cloud is empty Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] add initail state in downloadingCredential to fix warning Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] - Added delayed visibility for backup screen Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> --------- Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-787] Conditional restore of VCs (#120) * [INJI-787] add bootstrap state for restarting restore ops Notes: - all operations depend on the state of the $DOCUMENT_DIR/inji/backup/ directory contents and not on the state of the MMKV DB Signed-off-by: Harsh Vardhan * [INJI-787] conditional restore on restart of restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] fix recent file finder code Signed-off-by: Harsh Vardhan * [INJIMOB-787] add vc remove logic for partial restore Signed-off-by: Harsh Vardhan * [INJIMOB-787] refactor, ACK reviews, rm dead condition Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove console.logs Signed-off-by: Harsh Vardhan * [INJIMOB-787] remove irrelevant TODOs Signed-off-by: Harsh Vardhan --------- Signed-off-by: Harsh Vardhan * Revert "Inji mob 737 rtl issue (#1238)" This reverts commit 2665cdeee193d7fb428fc10354f30cc25084b83d. * [INJIMOB-760]: adjust the mosip logo in the issuer section Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-787] refactor backup & restore states machines Signed-off-by: Harsh Vardhan * [INJIMOB-752] fix label for drive name on backup Signed-off-by: Harsh Vardhan * [INJIMOB-799] fix show restored vcs as shareable Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-752] fix warnings Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: Swati Goel Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: Harsh Vardhan Co-authored-by: vijay151096 <94220135+vijay151096@users.noreply.github.com> Co-authored-by: Swati Goel Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Co-authored-by: Pooja Babusingh <68894211+PoojaBabusingh@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: Harsh Vardhan * [INJIMOB-685] remove unused state and actions in requestMachine After adding timestamp to the incoming received vc, every vc shared from wallet is condered as separate vc. Due to this reason, the check if the incoming vc is already available in our received vcs will always be returning false. Thus removing the mergingIncomingVcrelated states in requestMachine to avoid unnecessary checks. Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-685] remove sharing reason related code Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB_685] remove unused event in vc machine Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-685] revert ios fastfile and project.pbxproj files changes Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: Swati Goel Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: Harsh Vardhan Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: Vijay <94220135+vijay151096@users.noreply.github.com> Co-authored-by: Swati Goel Co-authored-by: Pooja Babusingh <68894211+PoojaBabusingh@users.noreply.github.com> Co-authored-by: Harsh Vardhan * [INJIMOB-856] add testIds (#1274) testIDs added for - Inji tour guide slides, banner notification, issuer component Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-852] - Grace fully handling scrollToIndex error of flatlist (#1276) Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB-864] disable backup button when restoring and vice versa (#1280) Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-867] - remove all files including unsynced files and get latest file based on date (#1282) Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [INJIMOB - 865,868] - Fix duplicate VC key for restored VC's and remove metadata if vc file not found (#1284) * [INJIMOB-something] use incremental timestamp for restore and make unload take a flag start time Signed-off-by: Harsh Vardhan * [INJIMOB-865,868] fix duplicate vckey value for restored vcs and remove vc metadata if file not found Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-869] remove unused method in store.ts machine Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-869] revert removing vc metadata if file not found Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-865] fix tamper vc removal When a VC is tampered, we get the tampered vc popup. Once we press okay button in the popup, we will be refreshing the vc machine's myVcs & recievedVcs context. Due to calling of parallel states, we were having issue with refreshing of myVcs. It is fixed by targeting to init state to refresh Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-865] remove vc metadata when file is not found Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-869] add code comments & fix minor code issues Signed-off-by: Harsh Vardhan --------- Signed-off-by: Harsh Vardhan Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Harsh Vardhan Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * Inji 604 Verify VC error changes to be merged into release branch (#1277) * [INJI-604]: Handle Verification VC Error Scenarios Signed-off-by: BalachandarG * [INJIMOB-604] remove the card from UI when verify credential is failed and show error overlay Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-604] remove unused actions in existingMosipVcItem and issuers machine Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * INJIMOB-604 Replace Error message overlay with new error screen. Signed-off-by: BalachandarG * [INJI-604]: Transation added for Verification error messages. Signed-off-by: BalachandarG * [INJI-604] remove unnecessary log in error screen Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * [INJIMOB-604] remove removeVcFromMyVcs action from verify vc failed event and fix typegen warnings Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * INJIMOB-604 : Removing logs and renaming functions Signed-off-by: BalachandarG * [INJIMOB-604]: Removing unused method. Signed-off-by: BalachandarG * [Inji-604]: Fixing the issue of recursive VC deletion during Go Back event in Verification Error screen. Signed-off-by: BalachandarG * [Inji-604]: Fixing bugs post conflict resolve. Signed-off-by: BalachandarG * [Inji-604]: Removing unused events and adding translations for Go Back button * [Inji-604]: Removed angle brackets for Technical Error * [Inji-604]: Added ToDo to handle backup * [Inji-604]: Removing isVerified flag from the Existing VC Item Machine. * [Inji-604] iOS crash fixed for Verification error Go Back Button Signed-off-by: BalachandarG --------- Signed-off-by: BalachandarG Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: Swati Goel Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Co-authored-by: Swati Goel * [INJIMOB-881] add entitlements file changes for icloud (#1287) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * Injimob 881 - Update code signing identity (#1288) * [INJIMOB-881] add entitlements file changes for icloud Signed-off-by: adityankannan-tw * [INJIMOB-881] update code signing identity to iphone distribution Signed-off-by: adityankannan-tw --------- Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * mocked the verification and updated the app name for app releated popups (#1290) Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Co-authored-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-763] increase threshold of face match config (#1298) Signed-off-by: adityankannan-tw Co-authored-by: adityankannan-tw * [INJIMOB-531] send base64 encode data to encrypt to avoid data loss (#1305) * [INJIMOB-531] send base64 encode data to encrypt to avoid data truncation When we pass data from a react native app with \x00 value, any data post the \x00 gets truncated (i.e., part2 is trimmed off). This happens most likely with the react native bridge. To avoid this issue of truncation, we are required to pass the data as base64 encoded string and secure-keystore module will perform decoding before processing for encryption. Co-authored-by: Harsh Vardhan Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-531] upgrade secure-keystore package version Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Harsh Vardhan * replace storeVerifiableCredential context variable with verifiable credential and remove unused actions in vc item machine (#1306) Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> * OpenG2P Beneficiary Card Rendering Changes. (#1308) * OpenG2P Beneficiary Card Rendering Changes. Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * OpenG2P Beneficiary Card Rendering Changes. Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * OpenG2P Beneficiary Card Rendering fix. (#1313) * OpenG2P Beneficiary Card Rendering fix. Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * OpenG2P Beneficiary Card Rendering fix. Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-903] fix iOS backup & restore issues (#1316) * [INJIMOB-903] add logic to use cloud file as a single source of truth for backup and restore Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-903] - reset loader while fetching last backup details Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-903] fix android issue with fetching last backup details Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> * [INJIMOB-903] move google profile info api call to API Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> --------- Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> * [Inji-604]: Addressing the issue of activity log and data back up being called again during app launch and sharing. (#1317) * [Inji-604]: Removing verification calls from app refresh and adding it only on download VC. Signed-off-by: BalachandarG * [Inji-604]: Removing unused VERIFY event from Esignet machine. Signed-off-by: BalachandarG --------- Signed-off-by: BalachandarG * vc schema change compatibility changes for rendering (#1318) * vc schema change compatibility changes for rendering Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * vc schema change compatibility changes for rendering Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> --------- Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> * [INJIMOB-903] fix data backup screen stuck in loading (#1319) Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> --------- Signed-off-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Signed-off-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Signed-off-by: Swati Goel Signed-off-by: Vijay <94220135+vijay151096@users.noreply.github.com> Signed-off-by: adityankannan-tw Signed-off-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Signed-off-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Signed-off-by: Harsh Vardhan Signed-off-by: BalachandarG Signed-off-by: Alka Prasad Co-authored-by: KiruthikaJeyashankar <81218987+KiruthikaJeyashankar@users.noreply.github.com> Co-authored-by: vijay151096 <94220135+vijay151096@users.noreply.github.com> Co-authored-by: Swati Goel Co-authored-by: PuBHARGAVI <46226958+PuBHARGAVI@users.noreply.github.com> Co-authored-by: Pooja Babusingh <68894211+PoojaBabusingh@users.noreply.github.com> Co-authored-by: adityankannan-tw <109274996+adityankannan-tw@users.noreply.github.com> Co-authored-by: adityankannan-tw Co-authored-by: Sreenadh S <32409698+sree96@users.noreply.github.com> Co-authored-by: Harsh Vardhan Co-authored-by: balachandarg-tw <115633327+balachandarg-tw@users.noreply.github.com> --- .talismanrc | 48 +- components/VC/VcDetailsContainer.tsx | 9 +- components/VC/VcItemContainer.tsx | 9 +- components/VC/common/VCUtils.tsx | 2 +- i18n.ts | 14 +- ios/Inji.xcodeproj/project.pbxproj | 2 +- ios/Inji/Inji.entitlements | 20 +- ios/fastlane/Fastfile | 14 +- locales/ara.json | 2 + locales/en.json | 2 + locales/fil.json | 2 + locales/hin.json | 2 + locales/kan.json | 2 + locales/tam.json | 2 + .../EsignetMosipVCItemMachine.ts | 1 - .../ExistingMosipVCItemMachine.ts | 26 +- .../ExistingMosipVCItemMachine.typegen.ts | 499 +++++------------- machines/backupAndRestore/backup.typegen.ts | 2 + .../backupAndRestore/backupAndRestoreSetup.ts | 5 + machines/backupAndRestore/backupRestore.ts | 2 +- .../backupAndRestore/backupRestore.typegen.ts | 46 +- .../request/requestMachine.typegen.ts | 2 +- machines/bleShare/scan/scanMachine.typegen.ts | 2 +- machines/issuersMachine.typegen.ts | 2 +- screens/History/HistoryScreen.tsx | 3 +- screens/MainLayout.tsx | 7 +- screens/QrLogin/QrConsent.tsx | 4 +- screens/QrLogin/QrLoginSuccessMessage.tsx | 4 +- screens/Request/RequestLayout.tsx | 30 +- screens/Scan/ScanLayout.tsx | 41 +- screens/Scan/ScanScreen.tsx | 14 +- screens/Scan/ScanScreenController.ts | 8 +- screens/Scan/SendVcScreen.tsx | 6 +- shared/openId4VCI/Utils.ts | 7 +- shared/vcjs/verifyCredential.ts | 4 +- 35 files changed, 294 insertions(+), 551 deletions(-) diff --git a/.talismanrc b/.talismanrc index 5e27165dfb..638ed3f33a 100644 --- a/.talismanrc +++ b/.talismanrc @@ -39,8 +39,6 @@ fileignoreconfig: checksum: 2ba2721d9722cd9420ae26762316230f7dab1a0be45820cbda4d0ecae0edf957 - filename: screens/Issuers/IssuersScreen.tsx checksum: 9c53e3770dbefe26e0de67ee4b7d5cc9c52d9823cbb136a1a5104dcb0a101071 - - filename: ios/Podfile.lock - checksum: 3d5c2bd7979bbe75af3b321967257ccc8310027391fd815daa3beae4e122face - filename: shared/commonUtil.ts checksum: 4a53bb615f2ea0fbf687bd7027c4c246e819dd88bc273941ed611e763d9d2356 - filename: screens/Home/MyVcs/GetIdInputModal.tsx @@ -121,6 +119,8 @@ fileignoreconfig: checksum: 02655ff3d7f8a8ea4f3664485f98c961802c598242ec44408594a2ddb721fa5e - filename: screens/Settings/BackupController.tsx checksum: 4a031b46646aa982c8f40e4c7fe0bd3e05a76a6af1ff1c2de7350ba6ebf9a839 + - filename: machines/backupRestore.typegen.ts + checksum: ac9c154060c7c1adb3392ac8c78a42cae5ca3faea3b4b0166dd00d4ca38b290d - filename: machines/settings.typegen.ts checksum: e4ae05822f1b1c23f3f70d03dd46fd8f29ba6b52d40f2f24c121f536fbb5f2c4 - filename: .env @@ -143,10 +143,6 @@ fileignoreconfig: checksum: b0808e0c511412cde21fd169a9bbeaf3b77cb48f25418e12d341cc3ce1df5898 - filename: machines/backupAndRestore/backupAndRestore.typegen.ts checksum: 509b9660553990841883c54f8986971f21c7315e7450c455bba2766738c58bee - - filename: machines/backupAndRestore/backup.ts - checksum: d3453abfc10400e094b841e84283efc194a4fe0443c63ec880c5ddd6741f5293 - - filename: machines/backupAndRestore/backup.typegen.ts - checksum: 4a477f92aabf0a974382df45ef12ff5207dc73c270595cd810406983a65d9ce6 - filename: components/BackupAndRestoreAllScreenBanner.tsx checksum: 2c98e7e83959c9dac4dd12da32f81483c3d334bd05e279637cf465475fbf54b8 checksum: f26489ce4ac607884437ad06c3117cc34d6cbcbcd3dd5719790fbe01a0853ee5 @@ -175,42 +171,30 @@ fileignoreconfig: - filename: components/BannerNotificationContainer.tsx checksum: a98ff1a0dd96d3ead4b8191320be8b0c7a558cda6b0de39f1c62aaa8efef9fb8 - filename: components/HelpScreen.tsx + checksum: bbc69143bd37d065bba3800396301db5a0318e8b7ba51ecd49142dda68783a01 + - filename: machines/backupRestore.ts checksum: bbc69143bd37d065bba3800396301db5a0318e8b7ba51ecd49142dda68783a01 - - filename: machines/backupAndRestore/backupAndRestoreSetup.typegen.ts - checksum: 8203331f1628e01faa5e553e749372be278b477ca2d34a0cdafee1438248fb3c - filename: injitest/README.md checksum: 82974a6b9363512472272245e9b433f92e63377e58ba306980876b745181a09c - - filename: machines/backupAndRestore/backup.ts - checksum: 71cba6237f203a4a8df931a1b02669351466657f64fb6690545248fbad62f8b8 - - filename: machines/backupAndRestore/backupAndRestoreSetup.ts - checksum: 5eca5414d28f523bb920cffa1f51b484ec549a240667d37723773c224fc51792 - filename: shared/VCMetadata.ts checksum: e93f988415bf91064e2cf5fbc09ff6c7226798baa5da721fa0715d5d0d6afddf - - filename: machines/backupAndRestore/backup.ts - checksum: 0127424d704e7dbefcb13e2d66d687e8fa94812728b4eb6bfa7768028425e9b3 - filename: machines/backupRestore.ts - checksum: 71415a5e8de490af506070f8add50f864d559a8077542fc0b3d8ed18f0b33063 + checksum: 8f8725bb55dbc98083f819c74754a8eac258d15038e391a16ca1ab55a53d61f3 - filename: machines/backupRestore.typegen.ts checksum: 85e92ddec56da8dcdd28b5a29dfabd88dd0435e619f822488bc4e19b83872289 - - filename: machines/backupAndRestore/backupAndRestoreSetup.typegen.ts - checksum: dd5dc9c42800328c268f3e6d6c96a16e9686dbfa59735e721250dae3ce37e009 - - filename: machines/backupAndRestore/backupAndRestoreSetup.typegen.ts - checksum: dd5dc9c42800328c268f3e6d6c96a16e9686dbfa59735e721250dae3ce37e009 - - filename: injitest/src/main/java/inji/pages/BackupAndRestorePage.java - checksum: 750d001f5fedb393901004933917c4a0ca73af19a2a84cf4863512c664ae0ccd - - filename: injitest/src/test/java/androidTestCases/VcDownloadAndVerifyUsingSunbirdTest.java - checksum: 39d270982ada73f036ab4c61811f31cf7fa9a92cccc4ef03b7862765ff9b11cd - - filename: injitest/src/test/java/iosTestCases/VcDownloadAndVerifyUsingEsignetTest.java - checksum: d7ef3eda605d4785716b8babde586d9fe3ecd43e090336783e64c1923b68e18e - - filename: injitest/src/test/java/iosTestCases/ChangeLanguageTest.java - checksum: 0ac8c4f3b00138c52d83d719fd8f16c5521290417561c7cf604ade88fa092bc8 - - filename: injitest/src/test/java/androidTestCases/VcBackupAndRestoreTest.java - checksum: cbcbd4c4a185b5af1f23a93467e60cb2128faed718ce2499980e9658e43f19a6 + - filename: ios/Podfile.lock + checksum: 369fecac06b3c087b272e7920aa5ffe6734f261ae0af0c376a92ebf5c11415d4 - filename: screens/Home/MyVcsTab.tsx checksum: 8133e2fefddfd0207eb7207b660d317f9a6acafbab6a65762d29ea86e33787cb - filename: components/BackupAndRestoreBannerNotification.tsx - checksum: e465a9947727687d784d0cb9d8db1e28f765b0659bf4a3aa6d75643aa7b14102 - - filename: components/ActivityLogEvent.ts - checksum: e7c8617cd9c510d5b6a053bc5c6164f02c48e85125aa925e0c4cf55cd1f29d22 + checksum: 7bb544ecd2f691f8cef916d0463106ec67645253107dd407236ce3a81f4e9ba7 + - filename: machines/backupAndRestore/backup.ts + checksum: a0c667ee882689056a8867f7a6d2d510546c4dcb792024112b28db24e21cc884 + - filename: machines/backupAndRestore/backup.typegen.ts + checksum: acf45ed52679db29a23fa7d9e8307df5f4caa404eee49b742b6a5136ff647ffa + - filename: machines/backupAndRestore/backupAndRestoreSetup.ts + checksum: c21559a531b6c62013dc0d932e0e2666cf9bd1ea62e7681240e4983406c96732 + - filename: machines/backupAndRestore/backupAndRestoreSetup.typegen.ts + checksum: 3d8b4183f386c73092a271db77434370260dbe1c91fc4193cb21a81f3b548cda version: "" diff --git a/components/VC/VcDetailsContainer.tsx b/components/VC/VcDetailsContainer.tsx index b9d56ec59b..d45c67a46e 100644 --- a/components/VC/VcDetailsContainer.tsx +++ b/components/VC/VcDetailsContainer.tsx @@ -10,7 +10,10 @@ import {Issuers} from '../../shared/openId4VCI/Utils'; export const VcDetailsContainer: React.FC< ExistingMosipVCItemDetailsProps | EsignetMosipVCItemDetailsProps > = props => { - if (props.vc.vcMetadata.issuer === Issuers.Sunbird) - return ; - return ; + if ( + props.vc.vcMetadata.issuer === Issuers.Mosip || + props.vc.vcMetadata.issuer === Issuers.ESignet + ) + return ; + return ; }; diff --git a/components/VC/VcItemContainer.tsx b/components/VC/VcItemContainer.tsx index 6e14e2c53f..b81a5f6a1c 100644 --- a/components/VC/VcItemContainer.tsx +++ b/components/VC/VcItemContainer.tsx @@ -10,7 +10,10 @@ import {Issuers} from '../../shared/openId4VCI/Utils'; export const VcItemContainer: React.FC< ExistingMosipVCItemProps | EsignetMosipVCItemProps > = props => { - if (props.vcMetadata.issuer === Issuers.Sunbird) - return ; - return ; + if ( + props.vcMetadata.issuer === Issuers.Mosip || + props.vcMetadata.issuer === Issuers.ESignet + ) + return ; + return ; }; diff --git a/components/VC/common/VCUtils.tsx b/components/VC/common/VCUtils.tsx index c894ae7d90..9fad5e4963 100644 --- a/components/VC/common/VCUtils.tsx +++ b/components/VC/common/VCUtils.tsx @@ -59,7 +59,7 @@ export const getFieldValue = ( ); default: { const fieldValue = verifiableCredential?.credentialSubject[field]; - if (Array.isArray(fieldValue) && typeof fieldValue[0] != Object) { + if (Array.isArray(fieldValue) && typeof fieldValue[0] != 'object') { return fieldValue; } return getLocalizedField(fieldValue); diff --git a/i18n.ts b/i18n.ts index 5758b50f3b..9345687fda 100644 --- a/i18n.ts +++ b/i18n.ts @@ -75,12 +75,20 @@ export function getValueForCurrentLanguage( ? valueForCurrentLanguage[0].value : localizedData[0]?.value; } else { - const localizedDataObject = localizedData as {[key: string]: string}; + return localizedData?.value; + } +} - return localizedDataObject.hasOwnProperty(currentLanguageCode) +export function getClientNameForCurrentLanguage( + localizedData: Object, + defaultLanguage = '@none', +) { + const currentLanguage = i18next.language; + const currentLanguageCode = languageCodeMap[currentLanguage]; + const localizedDataObject = localizedData as {[key: string]: string}; + return localizedDataObject.hasOwnProperty(currentLanguageCode) ? localizedDataObject[currentLanguageCode] : localizedDataObject[defaultLanguage]; - } } // This method gets the value from iso-639-3 package, which contains key value pairs of three letter language codes[key] and two letter langugae code[value]. These values are according to iso standards. diff --git a/ios/Inji.xcodeproj/project.pbxproj b/ios/Inji.xcodeproj/project.pbxproj index ed097482a6..a7676ba24e 100644 --- a/ios/Inji.xcodeproj/project.pbxproj +++ b/ios/Inji.xcodeproj/project.pbxproj @@ -508,7 +508,7 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGN_IDENTITY = "Apple Distribution"; - "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Automatic; COPY_PHASE_STRIP = YES; ENABLE_NS_ASSERTIONS = NO; diff --git a/ios/Inji/Inji.entitlements b/ios/Inji/Inji.entitlements index 018a6e20cc..ffe610be5c 100644 --- a/ios/Inji/Inji.entitlements +++ b/ios/Inji/Inji.entitlements @@ -1,8 +1,20 @@ - - aps-environment - development - + + aps-environment + development + com.apple.developer.icloud-container-identifiers + + iCloud.io.mosip.inji.wallet.mobileid + + com.apple.developer.icloud-services + + CloudDocuments + + com.apple.developer.ubiquity-container-identifiers + + iCloud.io.mosip.inji.wallet.mobileid + + \ No newline at end of file diff --git a/ios/fastlane/Fastfile b/ios/fastlane/Fastfile index 40acacec24..e0bcf1b04e 100644 --- a/ios/fastlane/Fastfile +++ b/ios/fastlane/Fastfile @@ -123,7 +123,7 @@ platform :ios do workspace: "Inji.xcworkspace", scheme: "Inji", export_method: "app-store", - + export_options: { provisioningProfiles: { "#{generate_app_bundle_id}" => "match AppStore #{generate_app_bundle_id}" @@ -132,9 +132,9 @@ platform :ios do ) delete_temp_keychain(keychain_name) - + end - + lane :beta do keychain_name = TEMP_KEYCHAIN_USER keychain_password = TEMP_KEYCHAIN_PASSWORD @@ -203,7 +203,7 @@ platform :ios do workspace: "Inji.xcworkspace", scheme: "Inji", export_method: "app-store", - + export_options: { provisioningProfiles: { "#{generate_app_bundle_id}" => "match AppStore #{generate_app_bundle_id}" @@ -226,7 +226,7 @@ platform :ios do }, skip_waiting_for_build_processing: false, distribute_external: true, - submit_beta_review: false, + submit_beta_review: false, groups: ["#{TESTFLIGHT_INTERNAL_TESTERS_GROUP}"], ) @@ -245,14 +245,14 @@ platform :ios do sh("cp -R '#{app_path}' '#{output_directory}'") slack( - message: "#{generate_app_name} #{version} (#{current_build_number}) is uploaded to testflight.", + message: "#{generate_app_name} #{version} (#{current_build_number}) is uploaded to testflight.", success: true, slack_url: "#{SLACK_URL}", default_payloads: [:git_branch, :last_git_commit] ) end - + lane :ios_app_build do archive_path = gym( diff --git a/locales/ara.json b/locales/ara.json index f6f6a4ceab..0c82ebad13 100644 --- a/locales/ara.json +++ b/locales/ara.json @@ -60,6 +60,8 @@ "qrCodeHeader": "رمز الاستجابة السريعة", "nationalCard": "البطاقة الوطنية", "insuranceCard": "بطاقة التأمين", + "beneficiaryCard": "بطاقة المستفيد", + "socialRegistryCard": "بطاقة السجل الاجتماعي", "uin": "UIN", "vid": "VID", "enableVerification": "تفعيل", diff --git a/locales/en.json b/locales/en.json index 5dfbf03850..95dcb1e2a7 100644 --- a/locales/en.json +++ b/locales/en.json @@ -61,6 +61,8 @@ "qrCodeHeader": "QR Code", "nationalCard": "National Card", "insuranceCard": "Insurance Card", + "beneficiaryCard": "Beneficiary Card", + "socialRegistryCard": "Social Registry Card", "uin": "UIN", "vid": "VID", "enableVerification": "Activate", diff --git a/locales/fil.json b/locales/fil.json index 21ddd4369f..6b02a65ce6 100644 --- a/locales/fil.json +++ b/locales/fil.json @@ -60,6 +60,8 @@ "qrCodeHeader": "QR Code", "nationalCard": "Pambansang Kard", "insuranceCard": "Insurance Card", + "beneficiaryCard": "Benepisyaryo Card", + "socialRegistryCard": "Social Registry Card", "uin": "UIN", "vid": "VID", "enableVerification": "I-activate", diff --git a/locales/hin.json b/locales/hin.json index 92d8f71eb3..b5e5e5fce2 100644 --- a/locales/hin.json +++ b/locales/hin.json @@ -60,6 +60,8 @@ "qrCodeHeader": "क्यू आर संहिता", "nationalCard": "राष्ट्रीय कार्ड", "insuranceCard": "बीमा कार्ड", + "beneficiaryCard": "लाभार्थी कार्ड", + "socialRegistryCard": "सामाजिक रजिस्ट्री कार्ड", "uin": "UIN", "vid": "VID", "enableVerification": "सक्रिय", diff --git a/locales/kan.json b/locales/kan.json index b318580a4b..5410778f5f 100644 --- a/locales/kan.json +++ b/locales/kan.json @@ -60,6 +60,8 @@ "qrCodeHeader": "QR ಕೋಡ್", "nationalCard": "ರಾಷ್ಟ್ರೀಯ ಕಾರ್ಡ್", "insuranceCard": "ವಿಮಾ ಕಾರ್ಡ್", + "beneficiaryCard": "ಫಲಾನುಭವಿ ಕಾರ್ಡ್", + "socialRegistryCard": "ಸಾಮಾಜಿಕ ನೋಂದಣಿ ಕಾರ್ಡ್", "uin": "UIN", "vid": "VID", "enableVerification": "ಸಕ್ರಿಯಗೊಳಿಸಿ", diff --git a/locales/tam.json b/locales/tam.json index 29d14d7252..e53fa74e8b 100644 --- a/locales/tam.json +++ b/locales/tam.json @@ -60,6 +60,8 @@ "qrCodeHeader": "க்யு ஆர் குறியீடு", "nationalCard": "தேசிய அட்டை", "insuranceCard": "காப்பீட்டு அட்டை", + "beneficiaryCard": "பயனாளி அட்டை", + "socialRegistryCard": "சமூக பதிவு அட்டை", "uin": "UIN", "vid": "VID", "enableVerification": "செயல்படுத்த", diff --git a/machines/VCItemMachine/EsignetMosipVCItem/EsignetMosipVCItemMachine.ts b/machines/VCItemMachine/EsignetMosipVCItem/EsignetMosipVCItemMachine.ts index 84c4d45b0b..1bb1a99735 100644 --- a/machines/VCItemMachine/EsignetMosipVCItem/EsignetMosipVCItemMachine.ts +++ b/machines/VCItemMachine/EsignetMosipVCItem/EsignetMosipVCItemMachine.ts @@ -69,7 +69,6 @@ const model = createModel( POLL: () => ({}), DOWNLOAD_READY: () => ({}), GET_VC_RESPONSE: (vc: VC) => ({vc}), - VERIFY: () => ({}), LOCK_VC: () => ({}), RESEND_OTP: () => ({}), INPUT_OTP: (otp: string) => ({otp}), diff --git a/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.ts b/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.ts index 7b09ad3ead..cfff78825f 100644 --- a/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.ts +++ b/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.ts @@ -90,7 +90,6 @@ const model = createModel( DOWNLOAD_READY: () => ({}), FAILED: () => ({}), GET_VC_RESPONSE: (vc: VC) => ({vc}), - VERIFY: () => ({}), LOCK_VC: () => ({}), INPUT_OTP: (otp: string) => ({otp}), RESEND_OTP: () => ({}), @@ -145,7 +144,7 @@ export const ExistingMosipVCItemMachine = { actions: 'setCredential', cond: 'hasCredential', - target: 'checkingVerificationStatus', + target: '#vc-item.idle', }, { target: 'checkingStore', @@ -161,7 +160,7 @@ export const ExistingMosipVCItemMachine = { actions: ['setCredential', 'updateVc'], cond: 'hasCredential', - target: 'checkingVerificationStatus', + target: '#vc-item.idle', }, { actions: 'addVcToInProgressDownloads', @@ -240,7 +239,7 @@ export const ExistingMosipVCItemMachine = ], CREDENTIAL_DOWNLOADED: { actions: 'setCredential', - target: '#vc-item.checkingVerificationStatus', + target: '#vc-item.verifyingCredential', }, }, }, @@ -263,9 +262,6 @@ export const ExistingMosipVCItemMachine = idle: { entry: ['clearTransactionId', 'clearOtp'], on: { - VERIFY: { - target: 'verifyingCredential', - }, LOCK_VC: { target: 'requestingOtp', }, @@ -436,16 +432,6 @@ export const ExistingMosipVCItemMachine = }, }, }, - - checkingVerificationStatus: { - description: - 'Check if VC verification is still valid. VCs stored on the device must be re-checked once every [N] time has passed.', - always: [ - { - target: 'verifyingCredential', - }, - ], - }, invalid: { states: { otp: {}, @@ -721,9 +707,9 @@ export const ExistingMosipVCItemMachine = }, { target: 'updatingPrivateKey', - /*The walletBindingResponse is used for conditional rendering in wallet binding. - However, it wrongly considers activation as successful even when there's an error - in updatingPrivateKey state. So created a temporary context variable to store the binding + /*The walletBindingResponse is used for conditional rendering in wallet binding. + However, it wrongly considers activation as successful even when there's an error + in updatingPrivateKey state. So created a temporary context variable to store the binding response and use it in updatingPrivateKey state*/ actions: 'setTempWalletBindingResponse', }, diff --git a/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.typegen.ts b/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.typegen.ts index 01269e9d88..e9bd5ec394 100644 --- a/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.typegen.ts +++ b/machines/VCItemMachine/ExistingMosipVCItem/ExistingMosipVCItemMachine.typegen.ts @@ -1,361 +1,140 @@ -export interface Typegen0 { - '@@xstate/typegen': true; - internalEvents: { - '': {type: ''}; - 'done.invoke.checkStatus': { - type: 'done.invoke.checkStatus'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.downloadCredential': { - type: 'done.invoke.downloadCredential'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.addKeyPair:invocation[0]': { - type: 'done.invoke.vc-item.addKeyPair:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.addingWalletBindingId:invocation[0]': { - type: 'done.invoke.vc-item.addingWalletBindingId:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]': { - type: 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]': { - type: 'done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]': { - type: 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.requestingBindingOtp:invocation[0]': { - type: 'done.invoke.vc-item.requestingBindingOtp:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.requestingLock:invocation[0]': { - type: 'done.invoke.vc-item.requestingLock:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.requestingOtp:invocation[0]': { - type: 'done.invoke.vc-item.requestingOtp:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.requestingRevoke:invocation[0]': { - type: 'done.invoke.vc-item.requestingRevoke:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.updatingPrivateKey:invocation[0]': { - type: 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]': { - type: 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'done.invoke.vc-item.verifyingCredential:invocation[0]': { - type: 'done.invoke.vc-item.verifyingCredential:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; - 'error.platform.checkStatus': { - type: 'error.platform.checkStatus'; - data: unknown; - }; - 'error.platform.downloadCredential': { - type: 'error.platform.downloadCredential'; - data: unknown; - }; - 'error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]': { - type: 'error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.addKeyPair:invocation[0]': { - type: 'error.platform.vc-item.addKeyPair:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.addingWalletBindingId:invocation[0]': { - type: 'error.platform.vc-item.addingWalletBindingId:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]': { - type: 'error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.requestingBindingOtp:invocation[0]': { - type: 'error.platform.vc-item.requestingBindingOtp:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.requestingLock:invocation[0]': { - type: 'error.platform.vc-item.requestingLock:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.requestingRevoke:invocation[0]': { - type: 'error.platform.vc-item.requestingRevoke:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.updatingPrivateKey:invocation[0]': { - type: 'error.platform.vc-item.updatingPrivateKey:invocation[0]'; - data: unknown; - }; - 'error.platform.vc-item.verifyingCredential:invocation[0]': { - type: 'error.platform.vc-item.verifyingCredential:invocation[0]'; - data: unknown; - }; - 'xstate.init': {type: 'xstate.init'}; - }; - invokeSrcNameMap: { - addWalletBindnigId: 'done.invoke.vc-item.addingWalletBindingId:invocation[0]'; - checkDownloadExpiryLimit: 'done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]'; - checkStatus: 'done.invoke.checkStatus'; - downloadCredential: 'done.invoke.downloadCredential'; - generateKeyPair: 'done.invoke.vc-item.addKeyPair:invocation[0]'; - isUserSignedAlready: - | 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]' - | 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]'; - loadDownloadLimitConfig: 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - requestBindingOtp: - | 'done.invoke.vc-item.acceptingBindingOtp.resendOTP:invocation[0]' - | 'done.invoke.vc-item.requestingBindingOtp:invocation[0]'; - requestLock: 'done.invoke.vc-item.requestingLock:invocation[0]'; - requestOtp: - | 'done.invoke.vc-item.acceptingOtpInput.resendOTP:invocation[0]' - | 'done.invoke.vc-item.requestingOtp:invocation[0]'; - requestRevoke: 'done.invoke.vc-item.requestingRevoke:invocation[0]'; - updatePrivateKey: 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - verifyCredential: 'done.invoke.vc-item.verifyingCredential:invocation[0]'; - }; - missingImplementations: { - actions: never; - delays: never; - guards: never; - services: never; - }; - eventsCausingActions: { - addVcToInProgressDownloads: 'STORE_RESPONSE'; - clearOtp: - | '' - | 'CANCEL' - | 'DISMISS' - | 'REVOKE_VC' - | 'SHOW_BINDING_STATUS' - | 'STORE_RESPONSE' - | 'done.invoke.vc-item.requestingBindingOtp:invocation[0]' - | 'done.invoke.vc-item.requestingOtp:invocation[0]' - | 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]' - | 'error.platform.vc-item.requestingLock:invocation[0]' - | 'error.platform.vc-item.requestingRevoke:invocation[0]'; - clearTransactionId: - | '' - | 'CANCEL' - | 'DISMISS' - | 'SHOW_BINDING_STATUS' - | 'STORE_RESPONSE' - | 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]'; - incrementDownloadCounter: - | 'POLL' - | 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - logDownloaded: 'STORE_RESPONSE'; - logRevoked: 'STORE_RESPONSE'; - logVCremoved: 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]'; - logWalletBindingFailure: - | 'error.platform.vc-item.addKeyPair:invocation[0]' - | 'error.platform.vc-item.addingWalletBindingId:invocation[0]' - | 'error.platform.vc-item.requestingBindingOtp:invocation[0]' - | 'error.platform.vc-item.updatingPrivateKey:invocation[0]'; - logWalletBindingSuccess: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - refreshMyVcs: 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]'; - removeVcFromInProgressDownloads: 'STORE_RESPONSE'; - removeVcItem: 'CONFIRM'; - removeVcMetaDataFromStorage: - | 'STORE_ERROR' - | 'error.platform.vc-item.verifyingCredential:invocation[0]'; - removeVcMetaDataFromVcMachine: 'DISMISS'; - requestStoredContext: 'GET_VC_RESPONSE' | 'REFRESH'; - requestVcContext: 'DISMISS' | 'xstate.init'; - revokeVID: 'done.invoke.vc-item.requestingRevoke:invocation[0]'; - sendActivationFailedEndEvent: - | 'DISMISS' - | 'error.platform.vc-item.updatingPrivateKey:invocation[0]'; - sendActivationStartEvent: 'CONFIRM'; - sendActivationSuccessEvent: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - sendBackupEvent: - | 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]' - | 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]'; - sendDownloadLimitExpire: - | 'FAILED' - | 'error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]'; - sendTamperedVc: 'TAMPERED_VC'; - sendTelemetryEvents: 'STORE_RESPONSE'; - sendVcUpdated: 'PIN_CARD'; - sendVerificationError: 'STORE_RESPONSE'; - sendWalletBindingSuccess: 'SHOW_BINDING_STATUS'; - setCredential: - | 'CREDENTIAL_DOWNLOADED' - | 'GET_VC_RESPONSE' - | 'STORE_RESPONSE'; - setDownloadInterval: 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - setLock: 'done.invoke.vc-item.requestingLock:invocation[0]'; - setMaxDownloadCount: 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - setOtp: 'INPUT_OTP'; - setOtpError: - | 'error.platform.vc-item.requestingLock:invocation[0]' - | 'error.platform.vc-item.requestingRevoke:invocation[0]'; - setPinCard: 'PIN_CARD'; - setPrivateKey: 'done.invoke.vc-item.addKeyPair:invocation[0]'; - setPublicKey: 'done.invoke.vc-item.addKeyPair:invocation[0]'; - setRevoke: 'done.invoke.vc-item.requestingRevoke:invocation[0]'; - setTempWalletBindingResponse: 'done.invoke.vc-item.addingWalletBindingId:invocation[0]'; - setThumbprintForWalletBindingId: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - setTransactionId: - | 'INPUT_OTP' - | 'REVOKE_VC' - | 'done.invoke.vc-item.requestingOtp:invocation[0]' - | 'error.platform.vc-item.requestingLock:invocation[0]' - | 'error.platform.vc-item.requestingRevoke:invocation[0]'; - setVcKey: 'REMOVE'; - setVcMetadata: 'UPDATE_VC_METADATA'; - setWalletBindingError: - | 'error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]' - | 'error.platform.vc-item.addKeyPair:invocation[0]' - | 'error.platform.vc-item.addingWalletBindingId:invocation[0]' - | 'error.platform.vc-item.requestingBindingOtp:invocation[0]' - | 'error.platform.vc-item.updatingPrivateKey:invocation[0]'; - setWalletBindingErrorEmpty: - | 'CANCEL' - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - setWalletBindingId: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - storeContext: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]' - | 'done.invoke.vc-item.verifyingCredential:invocation[0]'; - storeLock: 'done.invoke.vc-item.requestingLock:invocation[0]'; - updatePrivateKey: - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - updateVc: - | 'STORE_RESPONSE' - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]' - | 'done.invoke.vc-item.updatingPrivateKey:invocation[0]'; - updateVerificationErrorMessage: 'error.platform.vc-item.verifyingCredential:invocation[0]'; - }; - eventsCausingDelays: {}; - eventsCausingGuards: { - hasCredential: 'GET_VC_RESPONSE' | 'STORE_RESPONSE'; - isCustomSecureKeystore: - | 'done.invoke.vc-item.addKeyPair:invocation[0]' - | 'done.invoke.vc-item.addingWalletBindingId:invocation[0]'; - isDownloadAllowed: 'POLL'; - isSignedIn: - | 'done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]' - | 'done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]'; - }; - eventsCausingServices: { - addWalletBindnigId: 'done.invoke.vc-item.addKeyPair:invocation[0]'; - checkDownloadExpiryLimit: - | 'POLL' - | 'done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]'; - checkStatus: 'done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]'; - downloadCredential: 'DOWNLOAD_READY'; - generateKeyPair: 'INPUT_OTP'; - isUserSignedAlready: 'STORE_RESPONSE'; - loadDownloadLimitConfig: 'STORE_ERROR' | 'STORE_RESPONSE'; - requestBindingOtp: 'CONFIRM' | 'RESEND_OTP'; - requestLock: 'INPUT_OTP'; - requestOtp: 'LOCK_VC' | 'RESEND_OTP'; - requestRevoke: 'INPUT_OTP'; - updatePrivateKey: 'done.invoke.vc-item.addingWalletBindingId:invocation[0]'; - verifyCredential: '' | 'VERIFY'; - }; - matchesStates: - | 'acceptingBindingOtp' - | 'acceptingBindingOtp.idle' - | 'acceptingBindingOtp.resendOTP' - | 'acceptingOtpInput' - | 'acceptingOtpInput.idle' - | 'acceptingOtpInput.resendOTP' - | 'acceptingRevokeInput' - | 'addKeyPair' - | 'addingWalletBindingId' - | 'checkingServerData' - | 'checkingServerData.checkingStatus' - | 'checkingServerData.downloadingCredential' - | 'checkingServerData.loadDownloadLimitConfig' - | 'checkingServerData.savingFailed' - | 'checkingServerData.savingFailed.idle' - | 'checkingServerData.savingFailed.viewingVc' - | 'checkingServerData.verifyingDownloadLimitExpiry' - | 'checkingStore' - | 'checkingVc' - | 'checkingVerificationStatus' - | 'handleVCVerificationFailure' - | 'idle' - | 'invalid' - | 'invalid.backend' - | 'invalid.otp' - | 'kebabPopUp' - | 'kebabPopUp.idle' - | 'kebabPopUp.removeWallet' - | 'kebabPopUp.removingVc' - | 'kebabPopUp.removingVc.triggerAutoBackup' - | 'kebabPopUp.showActivities' - | 'lockingVc' - | 'loggingRevoke' - | 'pinCard' - | 'requestingBindingOtp' - | 'requestingLock' - | 'requestingOtp' - | 'requestingRevoke' - | 'revokingVc' - | 'showBindingWarning' - | 'showingWalletBindingError' - | 'updatingContextVariables' - | 'updatingPrivateKey' - | 'verifyingCredential' - | 'verifyingCredential.idle' - | 'verifyingCredential.triggerAutoBackupForVcDownload' - | { - acceptingBindingOtp?: 'idle' | 'resendOTP'; - acceptingOtpInput?: 'idle' | 'resendOTP'; - checkingServerData?: - | 'checkingStatus' - | 'downloadingCredential' - | 'loadDownloadLimitConfig' - | 'savingFailed' - | 'verifyingDownloadLimitExpiry' - | {savingFailed?: 'idle' | 'viewingVc'}; - invalid?: 'backend' | 'otp'; - kebabPopUp?: - | 'idle' - | 'removeWallet' - | 'removingVc' - | 'showActivities' - | {removingVc?: 'triggerAutoBackup'}; - verifyingCredential?: 'idle' | 'triggerAutoBackupForVcDownload'; - }; - tags: never; -} + // This file was automatically generated. Edits will be overwritten + + export interface Typegen0 { + '@@xstate/typegen': true; + internalEvents: { + "": { type: "" }; +"done.invoke.checkStatus": { type: "done.invoke.checkStatus"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.downloadCredential": { type: "done.invoke.downloadCredential"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.addKeyPair:invocation[0]": { type: "done.invoke.vc-item.addKeyPair:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.addingWalletBindingId:invocation[0]": { type: "done.invoke.vc-item.addingWalletBindingId:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]": { type: "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]": { type: "done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]": { type: "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.requestingBindingOtp:invocation[0]": { type: "done.invoke.vc-item.requestingBindingOtp:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.requestingLock:invocation[0]": { type: "done.invoke.vc-item.requestingLock:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.requestingOtp:invocation[0]": { type: "done.invoke.vc-item.requestingOtp:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.requestingRevoke:invocation[0]": { type: "done.invoke.vc-item.requestingRevoke:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.updatingPrivateKey:invocation[0]": { type: "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]": { type: "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"done.invoke.vc-item.verifyingCredential:invocation[0]": { type: "done.invoke.vc-item.verifyingCredential:invocation[0]"; data: unknown; __tip: "See the XState TS docs to learn how to strongly type this." }; +"error.platform.checkStatus": { type: "error.platform.checkStatus"; data: unknown }; +"error.platform.downloadCredential": { type: "error.platform.downloadCredential"; data: unknown }; +"error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]": { type: "error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]"; data: unknown }; +"error.platform.vc-item.addKeyPair:invocation[0]": { type: "error.platform.vc-item.addKeyPair:invocation[0]"; data: unknown }; +"error.platform.vc-item.addingWalletBindingId:invocation[0]": { type: "error.platform.vc-item.addingWalletBindingId:invocation[0]"; data: unknown }; +"error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]": { type: "error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]"; data: unknown }; +"error.platform.vc-item.requestingBindingOtp:invocation[0]": { type: "error.platform.vc-item.requestingBindingOtp:invocation[0]"; data: unknown }; +"error.platform.vc-item.requestingLock:invocation[0]": { type: "error.platform.vc-item.requestingLock:invocation[0]"; data: unknown }; +"error.platform.vc-item.requestingRevoke:invocation[0]": { type: "error.platform.vc-item.requestingRevoke:invocation[0]"; data: unknown }; +"error.platform.vc-item.updatingPrivateKey:invocation[0]": { type: "error.platform.vc-item.updatingPrivateKey:invocation[0]"; data: unknown }; +"error.platform.vc-item.verifyingCredential:invocation[0]": { type: "error.platform.vc-item.verifyingCredential:invocation[0]"; data: unknown }; +"xstate.init": { type: "xstate.init" }; + }; + invokeSrcNameMap: { + "addWalletBindnigId": "done.invoke.vc-item.addingWalletBindingId:invocation[0]"; +"checkDownloadExpiryLimit": "done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]"; +"checkStatus": "done.invoke.checkStatus"; +"downloadCredential": "done.invoke.downloadCredential"; +"generateKeyPair": "done.invoke.vc-item.addKeyPair:invocation[0]"; +"isUserSignedAlready": "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]" | "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]"; +"loadDownloadLimitConfig": "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; +"requestBindingOtp": "done.invoke.vc-item.acceptingBindingOtp.resendOTP:invocation[0]" | "done.invoke.vc-item.requestingBindingOtp:invocation[0]"; +"requestLock": "done.invoke.vc-item.requestingLock:invocation[0]"; +"requestOtp": "done.invoke.vc-item.acceptingOtpInput.resendOTP:invocation[0]" | "done.invoke.vc-item.requestingOtp:invocation[0]"; +"requestRevoke": "done.invoke.vc-item.requestingRevoke:invocation[0]"; +"updatePrivateKey": "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"verifyCredential": "done.invoke.vc-item.verifyingCredential:invocation[0]"; + }; + missingImplementations: { + actions: never; + delays: never; + guards: never; + services: never; + }; + eventsCausingActions: { + "addVcToInProgressDownloads": "STORE_RESPONSE"; +"clearOtp": "" | "CANCEL" | "DISMISS" | "GET_VC_RESPONSE" | "REVOKE_VC" | "SHOW_BINDING_STATUS" | "STORE_RESPONSE" | "done.invoke.vc-item.requestingBindingOtp:invocation[0]" | "done.invoke.vc-item.requestingOtp:invocation[0]" | "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]" | "error.platform.vc-item.requestingLock:invocation[0]" | "error.platform.vc-item.requestingRevoke:invocation[0]"; +"clearTransactionId": "" | "CANCEL" | "DISMISS" | "GET_VC_RESPONSE" | "SHOW_BINDING_STATUS" | "STORE_RESPONSE" | "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]"; +"incrementDownloadCounter": "POLL" | "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; +"logDownloaded": "STORE_RESPONSE"; +"logRevoked": "STORE_RESPONSE"; +"logVCremoved": "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]"; +"logWalletBindingFailure": "error.platform.vc-item.addKeyPair:invocation[0]" | "error.platform.vc-item.addingWalletBindingId:invocation[0]" | "error.platform.vc-item.requestingBindingOtp:invocation[0]" | "error.platform.vc-item.updatingPrivateKey:invocation[0]"; +"logWalletBindingSuccess": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"refreshMyVcs": "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]"; +"removeVcFromInProgressDownloads": "STORE_RESPONSE"; +"removeVcItem": "CONFIRM"; +"removeVcMetaDataFromStorage": "STORE_ERROR" | "error.platform.vc-item.verifyingCredential:invocation[0]"; +"removeVcMetaDataFromVcMachine": "DISMISS"; +"requestStoredContext": "GET_VC_RESPONSE" | "REFRESH"; +"requestVcContext": "DISMISS" | "xstate.init"; +"revokeVID": "done.invoke.vc-item.requestingRevoke:invocation[0]"; +"sendActivationFailedEndEvent": "DISMISS" | "error.platform.vc-item.updatingPrivateKey:invocation[0]"; +"sendActivationStartEvent": "CONFIRM"; +"sendActivationSuccessEvent": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"sendBackupEvent": "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]" | "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]"; +"sendDownloadLimitExpire": "FAILED" | "error.platform.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]"; +"sendTamperedVc": "TAMPERED_VC"; +"sendTelemetryEvents": "STORE_RESPONSE"; +"sendVcUpdated": "PIN_CARD"; +"sendVerificationError": "STORE_RESPONSE"; +"sendWalletBindingSuccess": "SHOW_BINDING_STATUS"; +"setCredential": "CREDENTIAL_DOWNLOADED" | "GET_VC_RESPONSE" | "STORE_RESPONSE"; +"setDownloadInterval": "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; +"setLock": "done.invoke.vc-item.requestingLock:invocation[0]"; +"setMaxDownloadCount": "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; +"setOtp": "INPUT_OTP"; +"setOtpError": "error.platform.vc-item.requestingLock:invocation[0]" | "error.platform.vc-item.requestingRevoke:invocation[0]"; +"setPinCard": "PIN_CARD"; +"setPrivateKey": "done.invoke.vc-item.addKeyPair:invocation[0]"; +"setPublicKey": "done.invoke.vc-item.addKeyPair:invocation[0]"; +"setRevoke": "done.invoke.vc-item.requestingRevoke:invocation[0]"; +"setTempWalletBindingResponse": "done.invoke.vc-item.addingWalletBindingId:invocation[0]"; +"setThumbprintForWalletBindingId": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"setTransactionId": "INPUT_OTP" | "REVOKE_VC" | "done.invoke.vc-item.requestingOtp:invocation[0]" | "error.platform.vc-item.requestingLock:invocation[0]" | "error.platform.vc-item.requestingRevoke:invocation[0]"; +"setVcKey": "REMOVE"; +"setVcMetadata": "UPDATE_VC_METADATA"; +"setWalletBindingError": "error.platform.vc-item.acceptingBindingOtp.resendOTP:invocation[0]" | "error.platform.vc-item.addKeyPair:invocation[0]" | "error.platform.vc-item.addingWalletBindingId:invocation[0]" | "error.platform.vc-item.requestingBindingOtp:invocation[0]" | "error.platform.vc-item.updatingPrivateKey:invocation[0]"; +"setWalletBindingErrorEmpty": "CANCEL" | "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"setWalletBindingId": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"storeContext": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]" | "done.invoke.vc-item.verifyingCredential:invocation[0]"; +"storeLock": "done.invoke.vc-item.requestingLock:invocation[0]"; +"updatePrivateKey": "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"updateVc": "STORE_RESPONSE" | "done.invoke.vc-item.addingWalletBindingId:invocation[0]" | "done.invoke.vc-item.updatingPrivateKey:invocation[0]"; +"updateVerificationErrorMessage": "error.platform.vc-item.verifyingCredential:invocation[0]"; + }; + eventsCausingDelays: { + + }; + eventsCausingGuards: { + "hasCredential": "GET_VC_RESPONSE" | "STORE_RESPONSE"; +"isCustomSecureKeystore": "done.invoke.vc-item.addKeyPair:invocation[0]" | "done.invoke.vc-item.addingWalletBindingId:invocation[0]"; +"isDownloadAllowed": "POLL"; +"isSignedIn": "done.invoke.vc-item.kebabPopUp.removingVc.triggerAutoBackup:invocation[0]" | "done.invoke.vc-item.verifyingCredential.triggerAutoBackupForVcDownload:invocation[0]"; + }; + eventsCausingServices: { + "addWalletBindnigId": "done.invoke.vc-item.addKeyPair:invocation[0]"; +"checkDownloadExpiryLimit": "POLL" | "done.invoke.vc-item.checkingServerData.loadDownloadLimitConfig:invocation[0]"; +"checkStatus": "done.invoke.vc-item.checkingServerData.verifyingDownloadLimitExpiry:invocation[0]"; +"downloadCredential": "DOWNLOAD_READY"; +"generateKeyPair": "INPUT_OTP"; +"isUserSignedAlready": "STORE_RESPONSE"; +"loadDownloadLimitConfig": "STORE_ERROR" | "STORE_RESPONSE"; +"requestBindingOtp": "CONFIRM" | "RESEND_OTP"; +"requestLock": "INPUT_OTP"; +"requestOtp": "LOCK_VC" | "RESEND_OTP"; +"requestRevoke": "INPUT_OTP"; +"updatePrivateKey": "done.invoke.vc-item.addingWalletBindingId:invocation[0]"; +"verifyCredential": "CREDENTIAL_DOWNLOADED"; + }; + matchesStates: "acceptingBindingOtp" | "acceptingBindingOtp.idle" | "acceptingBindingOtp.resendOTP" | "acceptingOtpInput" | "acceptingOtpInput.idle" | "acceptingOtpInput.resendOTP" | "acceptingRevokeInput" | "addKeyPair" | "addingWalletBindingId" | "checkingServerData" | "checkingServerData.checkingStatus" | "checkingServerData.downloadingCredential" | "checkingServerData.loadDownloadLimitConfig" | "checkingServerData.savingFailed" | "checkingServerData.savingFailed.idle" | "checkingServerData.savingFailed.viewingVc" | "checkingServerData.verifyingDownloadLimitExpiry" | "checkingStore" | "checkingVc" | "handleVCVerificationFailure" | "idle" | "invalid" | "invalid.backend" | "invalid.otp" | "kebabPopUp" | "kebabPopUp.idle" | "kebabPopUp.removeWallet" | "kebabPopUp.removingVc" | "kebabPopUp.removingVc.triggerAutoBackup" | "kebabPopUp.showActivities" | "lockingVc" | "loggingRevoke" | "pinCard" | "requestingBindingOtp" | "requestingLock" | "requestingOtp" | "requestingRevoke" | "revokingVc" | "showBindingWarning" | "showingWalletBindingError" | "updatingContextVariables" | "updatingPrivateKey" | "verifyingCredential" | "verifyingCredential.idle" | "verifyingCredential.triggerAutoBackupForVcDownload" | { "acceptingBindingOtp"?: "idle" | "resendOTP"; +"acceptingOtpInput"?: "idle" | "resendOTP"; +"checkingServerData"?: "checkingStatus" | "downloadingCredential" | "loadDownloadLimitConfig" | "savingFailed" | "verifyingDownloadLimitExpiry" | { "savingFailed"?: "idle" | "viewingVc"; }; +"invalid"?: "backend" | "otp"; +"kebabPopUp"?: "idle" | "removeWallet" | "removingVc" | "showActivities" | { "removingVc"?: "triggerAutoBackup"; }; +"verifyingCredential"?: "idle" | "triggerAutoBackupForVcDownload"; }; + tags: never; + } + \ No newline at end of file diff --git a/machines/backupAndRestore/backup.typegen.ts b/machines/backupAndRestore/backup.typegen.ts index 4d8a24ada9..c0014e82f7 100644 --- a/machines/backupAndRestore/backup.typegen.ts +++ b/machines/backupAndRestore/backup.typegen.ts @@ -1,5 +1,7 @@ // This file was automatically generated. Edits will be overwritten +// This file was automatically generated. Edits will be overwritten + export interface Typegen0 { '@@xstate/typegen': true; internalEvents: { diff --git a/machines/backupAndRestore/backupAndRestoreSetup.ts b/machines/backupAndRestore/backupAndRestoreSetup.ts index b9ea4d94e7..a296b64fc9 100644 --- a/machines/backupAndRestore/backupAndRestoreSetup.ts +++ b/machines/backupAndRestore/backupAndRestoreSetup.ts @@ -206,6 +206,11 @@ export const backupAndRestoreSetupMachine = model.createMachine( target: 'backupAndRestore', }, // What if sign in fails due to n/w error? + { + cond: 'isIOS', + target: 'backupAndRestore', + }, + // What if sign in fails due to n/w error? { actions: 'sendBackupAndRestoreSetupErrorEvent', target: '.error', diff --git a/machines/backupAndRestore/backupRestore.ts b/machines/backupAndRestore/backupRestore.ts index 147e3a1c7f..017056979b 100644 --- a/machines/backupAndRestore/backupRestore.ts +++ b/machines/backupAndRestore/backupRestore.ts @@ -242,7 +242,7 @@ export const backupRestoreMachine = model.createMachine( }, }, - services: { + services: { checkStorageAvailability: () => async () => { return await Storage.isMinimumLimitReached('minStorageRequired'); }, diff --git a/machines/backupAndRestore/backupRestore.typegen.ts b/machines/backupAndRestore/backupRestore.typegen.ts index 49b9989c6f..0605c37600 100644 --- a/machines/backupAndRestore/backupRestore.typegen.ts +++ b/machines/backupAndRestore/backupRestore.typegen.ts @@ -3,21 +3,11 @@ export interface Typegen0 { '@@xstate/typegen': true; internalEvents: { - 'done.invoke.backupRestore.preload:invocation[0]': { - type: 'done.invoke.backupRestore.preload:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]': { type: 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]'; data: unknown; __tip: 'See the XState TS docs to learn how to strongly type this.'; }; - 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]': { - type: 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]'; - data: unknown; - __tip: 'See the XState TS docs to learn how to strongly type this.'; - }; 'done.invoke.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]': { type: 'done.invoke.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]'; data: unknown; @@ -39,9 +29,7 @@ export interface Typegen0 { 'xstate.init': {type: 'xstate.init'}; }; invokeSrcNameMap: { - bootstrap: 'done.invoke.backupRestore.preload:invocation[0]'; checkStorageAvailability: 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]'; - deleteBkpDir: 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]'; downloadLatestBackup: 'done.invoke.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]'; readBackupFile: 'done.invoke.backupRestore.restoreBackup.readBackupFile:invocation[0]'; unzipBackupFile: 'done.invoke.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; @@ -53,18 +41,22 @@ export interface Typegen0 { services: never; }; eventsCausingActions: { + cleanupFiles: + | 'STORE_ERROR' + | 'STORE_RESPONSE' + | 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]' + | 'error.platform.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]' + | 'error.platform.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; downloadUnsyncedBackupFiles: 'DOWNLOAD_UNSYNCED_BACKUP_FILES'; loadDataToMemory: 'DATA_FROM_FILE'; - refreshVCs: 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]'; + refreshVCs: 'STORE_RESPONSE'; sendDataRestoreFailureEvent: | 'STORE_ERROR' | 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]' | 'error.platform.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]' | 'error.platform.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; - sendDataRestoreStartEvent: - | 'BACKUP_RESTORE' - | 'done.invoke.backupRestore.preload:invocation[0]'; - sendDataRestoreSuccessEvent: 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]'; + sendDataRestoreStartEvent: 'BACKUP_RESTORE'; + sendDataRestoreSuccessEvent: 'STORE_RESPONSE'; setBackupFileName: 'done.invoke.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]'; setDataFromBackupFile: 'DATA_FROM_FILE'; setRestoreErrorReason: @@ -73,40 +65,29 @@ export interface Typegen0 { setRestoreTechnicalError: | 'STORE_ERROR' | 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]'; - setShowRestoreInProgress: - | 'BACKUP_RESTORE' - | 'done.invoke.backupRestore.preload:invocation[0]'; + setShowRestoreInProgress: 'BACKUP_RESTORE'; unsetShowRestoreInProgress: | 'DISMISS_SHOW_RESTORE_IN_PROGRESS' | 'STORE_ERROR' + | 'STORE_RESPONSE' | 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]' - | 'done.invoke.backupRestore.restoreBackup.deleteBackupDir:invocation[0]' | 'error.platform.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]' | 'error.platform.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; }; eventsCausingDelays: {}; eventsCausingGuards: { - isBackupFile: 'done.invoke.backupRestore.preload:invocation[0]'; isMinimumStorageRequiredForBackupRestorationReached: 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]'; }; eventsCausingServices: { - bootstrap: 'BACKUP_RESTORE' | 'xstate.init'; - checkStorageAvailability: - | 'BACKUP_RESTORE' - | 'done.invoke.backupRestore.preload:invocation[0]'; - deleteBkpDir: 'STORE_RESPONSE'; + checkStorageAvailability: 'BACKUP_RESTORE'; downloadLatestBackup: 'done.invoke.backupRestore.restoreBackup.checkStorageAvailability:invocation[0]'; - readBackupFile: - | 'done.invoke.backupRestore.preload:invocation[0]' - | 'done.invoke.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; + readBackupFile: 'done.invoke.backupRestore.restoreBackup.unzipBackupFile:invocation[0]'; unzipBackupFile: 'done.invoke.backupRestore.restoreBackup.downloadBackupFileFromCloud:invocation[0]'; }; matchesStates: | 'init' - | 'preload' | 'restoreBackup' | 'restoreBackup.checkStorageAvailability' - | 'restoreBackup.deleteBackupDir' | 'restoreBackup.downloadBackupFileFromCloud' | 'restoreBackup.failure' | 'restoreBackup.idle' @@ -117,7 +98,6 @@ export interface Typegen0 { | { restoreBackup?: | 'checkStorageAvailability' - | 'deleteBackupDir' | 'downloadBackupFileFromCloud' | 'failure' | 'idle' diff --git a/machines/bleShare/request/requestMachine.typegen.ts b/machines/bleShare/request/requestMachine.typegen.ts index fa38c78127..15c96aba12 100644 --- a/machines/bleShare/request/requestMachine.typegen.ts +++ b/machines/bleShare/request/requestMachine.typegen.ts @@ -87,4 +87,4 @@ "waitingForVc"?: "inProgress" | "timeout"; }; tags: never; } - \ No newline at end of file + diff --git a/machines/bleShare/scan/scanMachine.typegen.ts b/machines/bleShare/scan/scanMachine.typegen.ts index aaa7acd599..d1b071070a 100644 --- a/machines/bleShare/scan/scanMachine.typegen.ts +++ b/machines/bleShare/scan/scanMachine.typegen.ts @@ -104,4 +104,4 @@ "showQrLogin"?: "idle" | "navigatingToHistory" | "storing"; }; tags: never; } - \ No newline at end of file + diff --git a/machines/issuersMachine.typegen.ts b/machines/issuersMachine.typegen.ts index 20a57fb6cd..93a4efa5f0 100644 --- a/machines/issuersMachine.typegen.ts +++ b/machines/issuersMachine.typegen.ts @@ -96,4 +96,4 @@ "performAuthorization"?: "idle" | "userCancelledBiometric"; }; tags: never; } - \ No newline at end of file + diff --git a/screens/History/HistoryScreen.tsx b/screens/History/HistoryScreen.tsx index ed6596e284..11e53943a5 100644 --- a/screens/History/HistoryScreen.tsx +++ b/screens/History/HistoryScreen.tsx @@ -5,10 +5,11 @@ import {useTranslation} from 'react-i18next'; import {Centered, Column, Text} from '../../components/ui'; import {useHistoryTab} from './HistoryScreenController'; import {ActivityLogText} from '../../components/ActivityLogText'; +import {MainRouteProps} from '../../routes/main'; import {Theme} from '../../components/ui/styleUtils'; import {BannerNotificationContainer} from '../../components/BannerNotificationContainer'; -export const HistoryScreen: React.FC = () => { +export const HistoryScreen: React.FC = () => { const {t} = useTranslation('HistoryScreen'); const controller = useHistoryTab(); diff --git a/screens/MainLayout.tsx b/screens/MainLayout.tsx index 81069fe7f2..b61ed1cffb 100644 --- a/screens/MainLayout.tsx +++ b/screens/MainLayout.tsx @@ -3,11 +3,16 @@ import { BottomTabNavigationOptions, createBottomTabNavigator, } from '@react-navigation/bottom-tabs'; +import {Icon} from 'react-native-elements'; import {RequestRouteProps, RootRouteProps} from '../routes'; import {mainRoutes, share} from '../routes/main'; import {Theme} from '../components/ui/styleUtils'; import {useTranslation} from 'react-i18next'; -import {Column} from '../components/ui'; +import {Column, Row} from '../components/ui'; +import {Image} from 'react-native'; +import {SettingScreen} from './Settings/SettingScreen'; +import {HelpScreen} from '../components/HelpScreen'; + import {GlobalContext} from '../shared/GlobalContext'; import {ScanEvents} from '../machines/bleShare/scan/scanMachine'; import testIDProps from '../shared/commonUtil'; diff --git a/screens/QrLogin/QrConsent.tsx b/screens/QrLogin/QrConsent.tsx index 60ca766d1b..66563a0125 100644 --- a/screens/QrLogin/QrConsent.tsx +++ b/screens/QrLogin/QrConsent.tsx @@ -8,7 +8,7 @@ import {Icon, ListItem, Switch} from 'react-native-elements'; import {Modal} from '../../components/ui/Modal'; import {QrLoginRef} from '../../machines/QrLoginMachine'; import {ScrollView} from 'react-native'; -import {getLocalizedField} from '../../i18n'; +import {getClientNameForCurrentLanguage} from '../../i18n'; export const QrConsent: React.FC = props => { const {t} = useTranslation('QrLogin'); @@ -40,7 +40,7 @@ export const QrConsent: React.FC = props => { style={Theme.TextStyles.small} weight="bold" margin={'10 0 0 0'}> - {getLocalizedField(controller.clientName)} {t('access')} + {getClientNameForCurrentLanguage(controller.clientName)} {t('access')} diff --git a/screens/QrLogin/QrLoginSuccessMessage.tsx b/screens/QrLogin/QrLoginSuccessMessage.tsx index d238c576f8..43c6c360b5 100644 --- a/screens/QrLogin/QrLoginSuccessMessage.tsx +++ b/screens/QrLogin/QrLoginSuccessMessage.tsx @@ -7,7 +7,7 @@ import {Centered, Button, Text, Column} from '../../components/ui'; import {Theme} from '../../components/ui/styleUtils'; import {useQrLogin} from './QrLoginController'; import {QrLoginRef} from '../../machines/QrLoginMachine'; -import {getLocalizedField} from '../../i18n'; +import {getClientNameForCurrentLanguage} from '../../i18n'; export const QrLoginSuccess: React.FC = props => { const {t} = useTranslation('QrLogin'); @@ -35,7 +35,7 @@ export const QrLoginSuccess: React.FC = props => { margin="20 0 0 0" align="center"> {t('successMessage')} - {getLocalizedField(controller.clientName)} + {getClientNameForCurrentLanguage(controller.clientName)} { component={ReceiveVcScreen} options={{ title: t('incomingVc'), - headerLeft: () => - !I18nManager.isRTL && ( - { - controller.RESET(); - }} - style={Theme.Styles.IconContainer} - tintColor={Theme.Colors.Icon} - /> - ), - headerRight: () => - I18nManager.isRTL && ( - { - controller.RESET(); - }} - style={Theme.Styles.IconContainer} - tintColor={Theme.Colors.Icon} - /> - ), + headerLeft: () => ( + { + controller.RESET(); + }} + /> + ), }} /> )} diff --git a/screens/Scan/ScanLayout.tsx b/screens/Scan/ScanLayout.tsx index 156e88748b..438653cf96 100644 --- a/screens/Scan/ScanLayout.tsx +++ b/screens/Scan/ScanLayout.tsx @@ -9,8 +9,6 @@ import {SharingStatusModal} from './SharingStatusModal'; import {Theme} from '../../components/ui/styleUtils'; import {Icon} from 'react-native-elements'; import {Loader} from '../../components/ui/Loader'; -import {Text} from '../../components/ui'; -import {I18nManager, View} from 'react-native'; import {SvgImage} from '../../components/ui/svg'; import {BANNER_TYPE_SUCCESS} from '../../shared/constants'; @@ -56,31 +54,14 @@ export const ScanLayout: React.FC = () => { component={SendVcScreen} options={{ title: t('sharingVc'), - headerTitleAlign: 'center', - headerTitle: props => ( - - - {props.children} - - - ), headerBackVisible: false, - headerRight: () => - !I18nManager.isRTL && ( - - ), - headerLeft: () => - I18nManager.isRTL && ( - - ), + headerRight: () => ( + + ), }} /> )} @@ -88,14 +69,8 @@ export const ScanLayout: React.FC = () => { name={SCAN_ROUTES.ScanScreen} component={ScanScreen} options={{ + headerTitleStyle: {fontSize: 30, fontFamily: 'Inter_600SemiBold'}, title: t('MainLayout:share'), - headerTitle: props => ( - - - {props.children} - - - ), }} /> diff --git a/screens/Scan/ScanScreen.tsx b/screens/Scan/ScanScreen.tsx index 49c13a61fc..620e090c9d 100644 --- a/screens/Scan/ScanScreen.tsx +++ b/screens/Scan/ScanScreen.tsx @@ -8,14 +8,20 @@ import {QrLogin} from '../QrLogin/QrLogin'; import {useScanScreen} from './ScanScreenController'; import BluetoothStateManager from 'react-native-bluetooth-state-manager'; import {Linking} from 'react-native'; +import {useNavigation, NavigationProp} from '@react-navigation/native'; +import {MainBottomTabParamList} from '../../routes/main'; +import {BOTTOM_TAB_ROUTES} from '../../routes/routesConstants'; import {isIOS} from '../../shared/constants'; import {BannerNotificationContainer} from '../../components/BannerNotificationContainer'; import {SharingStatusModal} from './SharingStatusModal'; import {SvgImage} from '../../components/ui/svg'; export const ScanScreen: React.FC = () => { + type ScanScreenNavigation = NavigationProp; + const {t} = useTranslation('ScanScreen'); const controller = useScanScreen(); + const navigation = useNavigation(); const [isBluetoothOn, setIsBluetoothOn] = useState(false); useEffect(() => { @@ -80,8 +86,7 @@ export const ScanScreen: React.FC = () => { ); } @@ -101,8 +106,7 @@ export const ScanScreen: React.FC = () => { ); } @@ -174,7 +178,7 @@ export const ScanScreen: React.FC = () => { } translationPath={'ScanScreen'} error="errors.storageLimitReached" - onBackdropPress={controller.GOTO_HOME} + onBackdropPress={() => navigation.navigate(BOTTOM_TAB_ROUTES.home)} /> ) ); diff --git a/screens/Scan/ScanScreenController.ts b/screens/Scan/ScanScreenController.ts index 595c5f0226..7a9a9c5c93 100644 --- a/screens/Scan/ScanScreenController.ts +++ b/screens/Scan/ScanScreenController.ts @@ -23,9 +23,6 @@ import { ScanEvents, selectIsMinimumStorageRequiredForAuditEntryLimitReached, } from '../../machines/bleShare/scan/scanMachine'; -import {BOTTOM_TAB_ROUTES} from '../../routes/routesConstants'; -import {MainBottomTabParamList} from '../../routes/main'; -import {useNavigation, NavigationProp} from '@react-navigation/native'; export function useScanScreen() { const {t} = useTranslation('ScanScreen'); @@ -70,9 +67,7 @@ export function useScanScreen() { locationError.message = t('errors.locationDenied.message'); locationError.button = t('errors.locationDenied.button'); } - type ScanScreenNavigation = NavigationProp; - const navigation = useNavigation(); - const GOTO_HOME = () => navigation.navigate(BOTTOM_TAB_ROUTES.home); + return { locationError, isEmpty: !shareableVcsMetadata.length, @@ -95,6 +90,5 @@ export function useScanScreen() { START_PERMISSION_CHECK: () => scanService.send(ScanEvents.START_PERMISSION_CHECK()), SCAN: (qrCode: string) => scanService.send(ScanEvents.SCAN(qrCode)), - GOTO_HOME, }; } diff --git a/screens/Scan/SendVcScreen.tsx b/screens/Scan/SendVcScreen.tsx index 38ea0a8297..b053827d60 100644 --- a/screens/Scan/SendVcScreen.tsx +++ b/screens/Scan/SendVcScreen.tsx @@ -107,8 +107,10 @@ export const SendVcScreen: React.FC = () => { backgroundColor={Theme.Colors.whiteBackgroundColor}> {!controller.selectedVc.shouldVerifyPresence && controller.selectedVc?.vcMetadata && - VCMetadata.fromVcMetadataString(controller.selectedVc.vcMetadata) - .issuer != Issuers.Sunbird && ( + [Issuers.Mosip, Issuers.ESignet].indexOf( + VCMetadata.fromVcMetadataString(controller.selectedVc.vcMetadata) + .issuer, + ) !== -1 && (