Page MenuHomePhabricator

[native] Support rainbow url scheme for Android
ClosedPublic

Authored by michal on Dec 29 2022, 4:09 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 30, 10:05 AM
Unknown Object (File)
Sat, Nov 30, 10:05 AM
Unknown Object (File)
Sat, Nov 30, 6:54 AM
Unknown Object (File)
Thu, Nov 28, 11:14 AM
Unknown Object (File)
Fri, Nov 22, 8:51 PM
Unknown Object (File)
Fri, Nov 22, 4:53 AM
Unknown Object (File)
Fri, Nov 22, 4:53 AM
Unknown Object (File)
Fri, Nov 22, 4:53 AM
Subscribers

Details

Summary

SIWE tries to redirect user to Rainbow which fails with a warning. To handle this we need to specify which apps we will interact with in the Android manifest.
More context:
ENG-2571
StackOverflow Post
Documentation

Test Plan

In the logged-out-modal.react.js I replaced onPressSIWE with:

onPressSIWE = () => {
    const url =
      'rainbow://open?_branch_referrer=H4sIAAAAAAAAA8soKSkottLXL8pLKk8sKNBLzs%2FVL08GAO6SbDcWAAAA&link_click_id=1136675358861894366';
    Linking.canOpenURL(url).then(function (supported) {
      if (supported) {
        return Linking.openURL(url);
      }
      console.warn("Can't open url: ".concat(url));
      return undefined;
    });
  };

and checked if the Rainbow app opens correctly.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage