-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(IT Wallet): [SIW-699] Credential image disappearing from wallet (#…
…5250) ## Short description This PR resolves a bug which causes the disappearance of the credential image between usage sessions. The issue is caused by the persistence of mock display data, in particular by the `require` result for the asset which is not constant between usage session. This inconsistency leads to the disappearance of the credential image when restarting the app. ## List of changes proposed in this pull request - Instead of including the required assets in the display data which is then persisted, use the credential type to get the assets at runtime with the `getImageFromCredentialType` helper function. Note that the `CredentialType` enum serves the purpose of avoiding the use of arbitrary strings to represent the credential type. Despite this, the credential type is still represented as a string to align with the library's typing requirements and due to the fact that it remains mocked and subject to potential changes. Therefore, although it is not strictly type checked at the moment, it is used in place of string constants in the mock declaration but not in the underlying Redux state. ## How to test Obtain a PID and a credential. Check if the background image is properly shown in the preview, home and details screen. Then restart the app (kill it from the background apps list) and test it again. --------- Co-authored-by: Mario Perrotta <[email protected]>
- Loading branch information
1 parent
0fe3716
commit 0488086
Showing
8 changed files
with
63 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters