HomePhabricator
Diffusion Comm f973d528ffd1

[native] Factor out success behavior in SIWEPanel

Description

[native] Factor out success behavior in SIWEPanel

Summary:
In the old flow, we would call the keyserver immediately after receiving a signed message from a user's wallet.

In the new flow, there are still some steps afterwards before we call the keyserver.

To make SIWEPanel support both cases, this diff:

  1. Factors out the SIWE server call and related logic into a useSIWEServerCall hook
  2. Add a new prop called onSuccessfulWalletSignature to SIWEPanel
  3. "Lift" the SIWE server call logic in SIWEPanel up to FullscreenSIWEPanel, one of its parents
  4. Use useSIWEServerCall in FullscreenSIWEPanel

Test Plan: Make sure the old SIWE flow still works

Reviewers: atul, ginsu

Reviewed By: atul

Subscribers: tomek

Differential Revision: https://phab.comm.dev/D7864

Details

Provenance
ashoatAuthored on May 18 2023, 10:29 AM
Reviewer
atul
Differential Revision
D7864: [native] Factor out success behavior in SIWEPanel
Parents
rCOMMb003298adfc8: [web] Increase `font-size` of `formNotice` in `CommunityCreationModal`
Branches
Unknown
Tags
Unknown