We have a feature that users can back up and extract their accounts into a custom file. But currently, they can only remove it, and there is no feature to import that custom file.
AC
Have a flow before login to accept backup files with a password.
The flow should only accept the *.krp files.
Once the file is selected, the app should validate the file with a password.
When the password is okay, then the app should show a simple data preview, and when the user accepts to import the account, it should import, and the app should restart.
If we currently have the same account in the app, we shoxuld ask the user to change the username.
Android 13 has a lot of changes regarding permissions and some other things. This issue was created to be compatible with Krypt and libraries that we use with Android 13.
Dear @mehdiyari during task #86 I found that we have a formatSize method used by SelectMediaItemsin app module and another one in DataViewModel in the backup module
Currently, I moved the one in the app module to the media module but we have to fix it later
I opened this issue here to prevent forgetting this problem
Is your feature request related to a problem? Please describe.
No, This is just a new feature.
Describe the solution you'd like
Currently, the flow is that once the user clicks on the backup we save the backup in Krypt private folders, this causes storage usage if Krypt contains a lot of files. I want to request a feature the user can select the path once click on the backup and we can save the backup file directly to this path.
Whats needs to be done:
Once the user clicks on the backup we request user to select a folder.
Once the user selects the folder we check the permission.
If the user grant the permission then we write the backup to the selected folder.
We show the message to the user that the backup was saved to this folder.
We show the backup in the list.
We should change the save action on the backup items, if the user clicks on them we loop the below items and move the current backup.
Describe alternatives you've considered
No Alternative.
Because this project started under time force in the beginning, we did not write tests, and after some time, only some view models and some repositories have test cases.
AC
ViewModels should have line coverage of more than 85%.
Repositories should have line coverage of more than 85%.
Utility classes like cartography and file utils should have line coverage of more than 85%.
We have a bug on Krypt related to navigations, this happens once the user does not select any media from the media picker, and once clicks on the back, the home does not show on the main screen.
To Reproduce
Steps to reproduce the behavior:
Login
Click on Add media
Select nothing and click on the back button.
Home content does not show properly to the user
Expected behavior
The home should be shown to the user.
Screenshots
Smartphone (please complete the following information):
Device: [Pixel 7 Pro] [All of the devices]
OS: [Android 13] [All of the devices]
Additional context
This bug happened because the onBackPressed callback for the media screen was called more than one time