Apple & Google Sign In#23673
Conversation
|
Yeah! @situchan it's pretty easy to get your authToken and agent up and running. Here's the explanation on their site: https://dashboard.ngrok.com/get-started/setup - Once you login they list through the steps of setting it up and running the agent. |
Reviewer Checklist
Screenshots/VideosWebMobile Web - ChromeMobile Web - SafariDesktopiOSAndroid |
|
@marcochavezf are there any other checks we need to do to get this through? Also, just to clarify. I'm going to create an issue preemptively for the Bug4 (COOP error likely from Google's GSI), were there any other errors that should have issues created to track? I know we solved the white background issue on dev by hiding the buttons on dev. |
|
We're just tracking the issue here, we can link the bug4 there |
|
@marcochavezf We should test web based platforms after deploy to staging, right? |
|
Yes, given the limitations to testing localhost in both platforms, I'm going to merge it to include it in today's deployment and test properly the remaining parts on staging |
|
@marcochavezf just to make sure I'm on the same page. Link the conversation about bug4 in the tracking issue, or create a new issue about bug4 and link that in the tracking issue? |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
Ah sorry for the confusion @cdanwards, let's create a new issue for bug4 and link it to the tracking issue please |
|
@marcochavezf no worries! Just wanted to make sure I understood. I'll get that issue created! |
|
🚀 Deployed to staging by https://github.com/marcochavezf in version: 1.3.56-0 🚀
|
|
Hi all! See the above deploy blocker - #25768 - Can we look into why that Google sign in button jumps on desktop Safari? Thanks! |
|
@dangrous Hey! I'm taking a look at this! We mainly tested on Chrome and Brave browsers during development and I haven't been able to reproduce there (We were informed that Firefox wasn't supported). Is Safari one of the supported browsers? It definitely seems like an issue of the iframe rendering and possible re-rendering the button and the styles being updated on a millisecond delay. |
|
Yeah that's what I was thinking too. I wonder if we will need to apply the styles/width/height to an empty element and then replace it with the Google button when it's loaded, or something? As for browsers, I'm confirming in Slack but it looks like Safari was on our QA test list so it seems like yes. EDIT: confirmed, we support Safari |
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.56-24 🚀
|
| setHasShownPrompt(true); | ||
| } else { | ||
| // Navigation state is not set up yet, we're unsure if we should show the deep link prompt or not | ||
| if (currentScreen === undefined || isAuthenticated === false) { |
There was a problem hiding this comment.
In this context, why would we use isAuthenticated === false?
There was a problem hiding this comment.
@napster125 We don't want to show the deeplink prompt to unauthenticated users.
There was a problem hiding this comment.
There's discussion of it within this feature's design document. Trying to find if we included that conversation in the contributing guide.
There was a problem hiding this comment.
Following up, here are the slack threads where this was discussed:
https://expensify.slack.com/archives/C01GTK53T8Q/p1683070404415199
https://expensify.slack.com/archives/C01GTK53T8Q/p1689886614735019
|
Google sign-in uses a system theme and adjusts coloring accordingly. We didn't handle the color scheme for this which caused a white background on the G-sign button. #25638 |
| if (!isMacOSWeb() || isUnsupportedDeeplinkRoute || CONFIG.ENVIRONMENT === CONST.ENVIRONMENT.DEV || hasShownPrompt) { | ||
| return; | ||
| } | ||
| // We want to show the prompt immediately if the user is already authenticated. | ||
| // Otherwise, we want to wait until the navigation state is set up | ||
| // and we know the user is on a screen that supports deeplinks. | ||
| if (isAuthenticated) { | ||
| promptToOpenInDesktopApp(); | ||
| setHasShownPrompt(true); | ||
| } else { | ||
| // Navigation state is not set up yet, we're unsure if we should show the deep link prompt or not | ||
| if (currentScreen === undefined || isAuthenticated === false) { |
There was a problem hiding this comment.
These conditions did not consider opening magic link on logged in user, and caused this issue #32795
Details
Fixed Issues
$ #7079
NOTE: Reading through
contributingGuides/APPLE_GOOGLE_SIGNIN.mdprovides more details about testing in development as well as rationale for design decisions.Tests
Apple Sign In
iOS
Android
Web
Desktop
new.expensify.com/sign-in-with-apple(It will automatically redirect to home login because of redirects)staging.new.expensify.com/sign-in-with-appleContinue with Applebutton.Google Sign In
iOS
Android
Web
Desktop
new.expensify.com/sign-in-with-google(It will automatically redirect to home login because of redirects)staging.new.expensify.com/sign-in-with-googleContinue with Googlebutton.Offline tests
Feature is not available in offline mode
QA Steps
Same as Tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Web
Apple:
Apple.Web.Flow_LowRes.mp4
Google:
Google.Web.Flow_LowRes.mp4
Mobile Web - Chrome
Chrome.Mobile.Web_LowRes.mp4
Mobile Web - Safari
Safari.Mobile.Web_LowRes.mp4
Desktop
Apple:
Apple.Desktop.w.Redirect_LowRes.mp4
Google:
Google.Desktop.w.Redirect_LowRes.mp4
iOS
IOS_LowRes.mp4
Android
Android_LowRes.mp4