-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Add workspace upgrade flow #43822
Merged
youssef-lr
merged 20 commits into
Expensify:main
from
allroundexperts:feat-workspace-upgrade
Jul 5, 2024
Merged
Add workspace upgrade flow #43822
Changes from 18 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
dcebd22
add workspace upgrade flow
allroundexperts 5bc393b
add offline indicator
allroundexperts 63ba1f8
fix lint errors
allroundexperts a9695dc
WIP: 1777d7ec70 Merge pull request #43140 from Expensify/cmartins-fix…
allroundexperts 17e4cab
handle comments
allroundexperts 1e36d4e
prettier fix
allroundexperts ce28f3a
Merge branch 'main' into feat-workspace-upgrade
allroundexperts 0e7c440
fix: broken desktop build
allroundexperts 21bbbc8
merge with main
allroundexperts 7113174
prettier fix
allroundexperts f38856b
handle comments
allroundexperts 9b01337
WIP: 1777d7ec70 Merge pull request #43140 from Expensify/cmartins-fix…
allroundexperts 04ae351
add translations
allroundexperts 1bf218a
add todo
allroundexperts fd7aa2b
handle comments
allroundexperts b23453d
Merge branch 'main' into feat-workspace-upgrade
allroundexperts e95b10b
Merge branch 'main' into feat-workspace-upgrade
allroundexperts df8d035
handle comments
allroundexperts c8bac1f
Merge branch 'main' into feat-workspace-upgrade
allroundexperts d05ccd7
Update CONST.ts
allroundexperts File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
type UpgradeToCorporateParams = { | ||
policyID: string; | ||
featureName: string; | ||
}; | ||
|
||
export default UpgradeToCorporateParams; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import React from 'react'; | ||
import ConfirmationPage from '@components/ConfirmationPage'; | ||
import TextLink from '@components/TextLink'; | ||
import useLocalize from '@hooks/useLocalize'; | ||
import useThemeStyles from '@hooks/useThemeStyles'; | ||
import Navigation from '@libs/Navigation/Navigation'; | ||
import ROUTES from '@src/ROUTES'; | ||
|
||
type Props = { | ||
policyName: string; | ||
policyID: string; | ||
}; | ||
|
||
function UpgradeConfirmation({policyName, policyID}: Props) { | ||
const {translate} = useLocalize(); | ||
const styles = useThemeStyles(); | ||
|
||
return ( | ||
<ConfirmationPage | ||
heading={translate('workspace.upgrade.completed.headline')} | ||
description={ | ||
<> | ||
{translate('workspace.upgrade.completed.successMessage', policyName)}{' '} | ||
<TextLink | ||
style={styles.link} | ||
onPress={() => Navigation.navigate(ROUTES.SETTINGS_SUBSCRIPTION)} | ||
> | ||
{translate('workspace.upgrade.completed.viewSubscription')} | ||
</TextLink>{' '} | ||
{translate('workspace.upgrade.completed.moreDetails')} | ||
</> | ||
} | ||
shouldShowButton | ||
onButtonPress={() => Navigation.goBack(ROUTES.WORKSPACE_PROFILE.getRoute(policyID))} | ||
buttonText={translate('workspace.upgrade.completed.gotIt')} | ||
/> | ||
); | ||
} | ||
|
||
export default UpgradeConfirmation; |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's add these optimistic values and their keys in CONST if they're not there:
And then add these values to the optimistic data if instant submit is enabled:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Handled.