Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[178] - feat: google drive integration with a sign-in flow and backup upload #202

Merged

Conversation

piyushupadhyay19
Copy link
Contributor

Summary

  • Integration with @react-native-google-signin/google-signin for OAuth authentication.
  • Uploading wallet backups to Google Drive using @robinbobin/react-native-google-drive-api-wrapper.

Issue ticket number and link

Checklist before requesting a review

  • All commits contain a DCO Signed-off-by line (we use the DCO GitHub app to enforce this).
  • Self-review of code & No unnecessary commented-out code.
  • All existing functionality remain intact.
  • Updated the README if necessary..
  • No hard-coded sensitive information.

@sairanjit
Copy link
Collaborator

@piyushupadhyay19 Can you add the video of the feature you have completed ?

@piyushupadhyay19
Copy link
Contributor Author

@piyushupadhyay19 Can you add the video of the feature you have completed ?

Screenrecording_20240627_232035.mp4

…into feature/digilocker-integration

Signed-off-by: Piyush Upadhyay <[email protected]>
Comment on lines 34 to 36
isSignedIn: boolean
signIn: () => Promise<void>
signOut: () => Promise<void>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
isSignedIn: boolean
signIn: () => Promise<void>
signOut: () => Promise<void>
isGoogleAccountSignedIn: boolean
googleSignIn: () => Promise<void>
googleSignOut: () => Promise<void>

Comment on lines 56 to 57
// const userInfo = await GoogleSignin.signIn()
// await AsyncStorage.setItem('userInfo', JSON.stringify(userInfo))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • If we don't need this you can remove this

Comment on lines 232 to 236
Toast.show({
type: ToastType.Success,
text1: t('GoogleDrive.SignOutGoogleSuccess'),
position: 'bottom',
})
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • While signing out we can remove this toast. We can just sign-out the user

const [, dispatch] = useStore()
const { t } = useTranslation()

useEffect(() => {
const checkSignInStatus = async () => {
const userInfo = await AsyncStorage.getItem('userInfo')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const userInfo = await AsyncStorage.getItem('userInfo')
const userInfo = await AsyncStorage.getItem('googleUserInfo')

Copy link
Collaborator

@sairanjit sairanjit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sairanjit sairanjit merged commit 9ff7c88 into credebl:dev Jul 3, 2024
1 check passed
@piyushupadhyay19 piyushupadhyay19 changed the title feat: google drive integration with a sign-in flow and backup upload [178] - feat: google drive integration with a sign-in flow and backup upload Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants