Repository navigation
Fixes for feature: Add support for redirecting user to a target URL when they click on the magic link code - #37145
Conversation
| Navigation.waitForProtectedRoutes().then(() => { | ||
| const url = NativeModules.HybridAppModule ? Navigation.parseHybridAppUrl(exitTo) : exitTo; | ||
| Navigation.navigate(url, CONST.NAVIGATION.TYPE.FORCED_UP); | ||
| Navigation.navigate(url); |
…s already signed in
| Session.handleExitToNavigation(exitTo); | ||
| return; | ||
| } | ||
| Navigation.goBack(); |
There was a problem hiding this comment.
when user is already signed in on native app, navigation to exitTo path was not performed.
This change fixes this case.
| {autoAuthState === CONST.AUTO_AUTH_STATE.JUST_SIGNED_IN && isSignedIn && <JustSignedInModal is2FARequired={false} />} | ||
| {autoAuthState === CONST.AUTO_AUTH_STATE.NOT_STARTED && ( | ||
| {autoAuthState === CONST.AUTO_AUTH_STATE.JUST_SIGNED_IN && isSignedIn && !exitTo && <JustSignedInModal is2FARequired={false}/>} | ||
| {autoAuthState === CONST.AUTO_AUTH_STATE.NOT_STARTED && !exitTo && ( |
…rowser, navigation was done after clicking just sign in here link
| Session.initAutoAuthState(autoAuthState); | ||
|
|
||
| if (isSignedIn || !login) { | ||
| if (isSignedIn || (!login && !exitTo)) { |
|
@cubuspl42 Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
…o-a-target-url-when-they-click-on-the-magic-link-code
|
Going to add @allroundexperts as C+ here since he helped review the original PR #36390, thanks for quick work here @rayane-djouah. |
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2024-02-26.at.1.28.47.PM.movAndroid: mWeb ChromeScreen.Recording.2024-02-26.at.1.23.57.PM.moviOS: NativeScreen.Recording.2024-02-26.at.1.21.29.PM.moviOS: mWeb SafariScreen.Recording.2024-02-26.at.1.19.20.PM.movMacOS: Chrome / SafariScreen.Recording.2024-02-26.at.12.59.29.PM.movMacOS: DesktopScreen.Recording.2024-02-26.at.1.06.16.PM.mov |
|
@rayane-djouah Back button doesn't seem to work as indicated in the OP Screen.Recording.2024-02-26.at.1.19.20.PM.mov |
|
@allroundexperts |
techievivek
left a comment
There was a problem hiding this comment.
Thanks for the improvement.
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/techievivek in version: 1.4.44-0 🚀
|
|
🚀 Deployed to production by https://github.com/puneetlath in version: 1.4.44-13 🚀
|

Details
This PR is a follow up to #36390
Fixed Issues
$ #36603
PROPOSAL: N/A
Tests
?exitTo=/settings/preferencesat the end of the link.Offline tests
N/A
QA Steps
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)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel so the design team can review the changes.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
Android: Native
android.Recording.2024-02-25.171843.mp4
Android: mWeb Chrome
mweb.chrome.webm
iOS: Native
ios.Recording.2024-02-25.164329.mp4
iOS: mWeb Safari
mweb.safari.Recording.2024-02-25.162910.mp4
MacOS: Chrome / Safari
web.Recording.2024-02-25.144153.mp4
MacOS: Desktop
desktop.Recording.2024-02-25.165540.mp4