Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into 54470-no-animation-…
Browse files Browse the repository at this point in the history
…submitting-expenses-new-user
  • Loading branch information
huult committed Jan 6, 2025
2 parents b44240a + b23c478 commit fb46ac3
Show file tree
Hide file tree
Showing 164 changed files with 3,655 additions and 3,298 deletions.
3 changes: 1 addition & 2 deletions .eslintrc.changed.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,14 @@ module.exports = {
overrides: [
{
files: [
'src/libs/ReportUtils.ts',
'src/libs/actions/IOU.ts',
'src/libs/actions/Report.ts',
'src/libs/actions/Task.ts',
'src/libs/OptionsListUtils.ts',
'src/libs/ReportActionsUtils.ts',
'src/libs/TransactionUtils/index.ts',
'src/pages/home/ReportScreen.tsx',
'src/pages/workspace/WorkspaceInitialPage.tsx',
'src/pages/home/report/PureReportActionItem.tsx',
],
rules: {
'rulesdir/no-default-id-values': 'off',
Expand Down
2 changes: 1 addition & 1 deletion Mobile-Expensify
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
versionCode 1009008002
versionName "9.0.80-2"
versionCode 1009008006
versionName "9.0.80-6"
// Supported language variants must be declared here to avoid from being removed during the compilation.
// This also helps us to not include unnecessary language variants in the APK.
resConfigs "en", "es"
Expand Down
2 changes: 1 addition & 1 deletion ios/NewExpensify/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>9.0.80.2</string>
<string>9.0.80.6</string>
<key>FullStory</key>
<dict>
<key>OrgId</key>
Expand Down
2 changes: 1 addition & 1 deletion ios/NewExpensifyTests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>9.0.80.2</string>
<string>9.0.80.6</string>
</dict>
</plist>
2 changes: 1 addition & 1 deletion ios/NotificationServiceExtension/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<key>CFBundleShortVersionString</key>
<string>9.0.80</string>
<key>CFBundleVersion</key>
<string>9.0.80.2</string>
<string>9.0.80.6</string>
<key>NSExtension</key>
<dict>
<key>NSExtensionPointIdentifier</key>
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "new.expensify",
"version": "9.0.80-2",
"version": "9.0.80-6",
"author": "Expensify, Inc.",
"homepage": "https://new.expensify.com",
"description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.",
Expand Down

This file was deleted.

2 changes: 0 additions & 2 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {GestureHandlerRootView} from 'react-native-gesture-handler';
import {PickerStateProvider} from 'react-native-picker-select';
import {SafeAreaProvider} from 'react-native-safe-area-context';
import '../wdyr';
import * as ActionSheetAwareScrollView from './components/ActionSheetAwareScrollView';
import ActiveElementRoleProvider from './components/ActiveElementRoleProvider';
import ActiveWorkspaceContextProvider from './components/ActiveWorkspaceProvider';
import ColorSchemeWrapper from './components/ColorSchemeWrapper';
Expand Down Expand Up @@ -90,7 +89,6 @@ function App({url}: AppProps) {
CustomStatusBarAndBackgroundContextProvider,
ActiveElementRoleProvider,
ActiveWorkspaceContextProvider,
ActionSheetAwareScrollView.ActionSheetAwareScrollViewProvider,
ReportIDsContextProvider,
PlaybackContextProvider,
FullScreenContextProvider,
Expand Down
95 changes: 49 additions & 46 deletions src/CONST.ts
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ const CONST = {
COMBINED_TRACK_SUBMIT: 'combinedTrackSubmit',
CATEGORY_AND_TAG_APPROVERS: 'categoryAndTagApprovers',
PER_DIEM: 'newDotPerDiem',
PRODUCT_TRAINING: 'productTraining',
NEWDOT_MERGE_ACCOUNTS: 'newDotMergeAccounts',
},
BUTTON_STATES: {
DEFAULT: 'default',
Expand Down Expand Up @@ -939,7 +939,6 @@ const CONST = {
CONFIGURE_REIMBURSEMENT_SETTINGS_HELP_URL: 'https://help.expensify.com/articles/expensify-classic/workspaces/Configure-Reimbursement-Settings',
COPILOT_HELP_URL: 'https://help.expensify.com/articles/expensify-classic/copilots-and-delegates/Assign-or-remove-a-Copilot',
DELAYED_SUBMISSION_HELP_URL: 'https://help.expensify.com/articles/expensify-classic/reports/Automatically-submit-employee-reports',
ENCRYPTION_AND_SECURITY_HELP_URL: 'https://help.expensify.com/articles/new-expensify/settings/Encryption-and-Data-Security',
PLAN_TYPES_AND_PRICING_HELP_URL: 'https://help.expensify.com/articles/new-expensify/billing-and-subscriptions/Plan-types-and-pricing',
// Use Environment.getEnvironmentURL to get the complete URL with port number
DEV_NEW_EXPENSIFY_URL: 'https://dev.new.expensify.com:',
Expand Down Expand Up @@ -2360,6 +2359,7 @@ const CONST = {
DISTANCE: 'distance',
MANUAL: 'manual',
SCAN: 'scan',
PER_DIEM: 'per-diem',
},
REPORT_ACTION_TYPE: {
PAY: 'pay',
Expand Down Expand Up @@ -2980,6 +2980,50 @@ const CONST = {
PAYPERUSE: 'monthly2018',
},
},
get SUBSCRIPTION_PRICES() {
return {
[this.PAYMENT_CARD_CURRENCY.USD]: {
[this.POLICY.TYPE.CORPORATE]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 900,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 1800,
},
[this.POLICY.TYPE.TEAM]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 500,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 1000,
},
},
[this.PAYMENT_CARD_CURRENCY.AUD]: {
[this.POLICY.TYPE.CORPORATE]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 1500,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 3000,
},
[this.POLICY.TYPE.TEAM]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 700,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 1400,
},
},
[this.PAYMENT_CARD_CURRENCY.GBP]: {
[this.POLICY.TYPE.CORPORATE]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 700,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 1400,
},
[this.POLICY.TYPE.TEAM]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 400,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 800,
},
},
[this.PAYMENT_CARD_CURRENCY.NZD]: {
[this.POLICY.TYPE.CORPORATE]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 1600,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 3200,
},
[this.POLICY.TYPE.TEAM]: {
[this.SUBSCRIPTION.TYPE.ANNUAL]: 800,
[this.SUBSCRIPTION.TYPE.PAYPERUSE]: 1600,
},
},
};
},
REGEX: {
SPECIAL_CHARS_WITHOUT_NEWLINE: /((?!\n)[()-\s\t])/g,
DIGITS_AND_PLUS: /^\+?[0-9]*$/,
Expand Down Expand Up @@ -3167,6 +3211,7 @@ const CONST = {
REPORT_NAME_LIMIT: 100,
TITLE_CHARACTER_LIMIT: 100,
DESCRIPTION_LIMIT: 1000,
SEARCH_QUERY_LIMIT: 1000,
WORKSPACE_NAME_CHARACTER_LIMIT: 80,
STATE_CHARACTER_LIMIT: 32,

Expand Down Expand Up @@ -3204,6 +3249,7 @@ const CONST = {
CANCEL_PAYMENT: 'cancelPayment',
UNAPPROVE: 'unapprove',
DEBUG: 'debug',
GO_TO_WORKSPACE: 'goToWorkspace',
},
EDIT_REQUEST_FIELD: {
AMOUNT: 'amount',
Expand Down Expand Up @@ -4613,6 +4659,7 @@ const CONST = {
MANUAL: 'manual',
SCAN: 'scan',
DISTANCE: 'distance',
PER_DIEM: 'per-diem',
},

STATUS_TEXT_MAX_LENGTH: 100,
Expand Down Expand Up @@ -6441,50 +6488,6 @@ const CONST = {
},
},

CORPAY_FIELDS: {
BANK_ACCOUNT_DETAILS_FIELDS: ['accountNumber', 'localAccountNumber', 'routingCode', 'localRoutingCode', 'swiftBicCode'] as string[],
ACCOUNT_TYPE_KEY: 'BeneficiaryAccountType',
BANK_INFORMATION_FIELDS: ['bankName', 'bankAddressLine1', 'bankAddressLine2', 'bankCity', 'bankRegion', 'bankPostal', 'BeneficiaryBankBranchName'] as string[],
ACCOUNT_HOLDER_FIELDS: [
'accountHolderName',
'accountHolderAddress1',
'accountHolderAddress2',
'accountHolderCity',
'accountHolderRegion',
'accountHolderCountry',
'accountHolderPostal',
'accountHolderPhoneNumber',
'accountHolderEmail',
'ContactName',
'BeneficiaryCPF',
'BeneficiaryRUT',
'BeneficiaryCedulaID',
'BeneficiaryTaxID',
] as string[],
SPECIAL_LIST_REGION_KEYS: ['bankRegion', 'accountHolderRegion'] as string[],
SPECIAL_LIST_ADDRESS_KEYS: ['bankAddressLine1', 'accountHolderAddress1'] as string[],
STEPS_NAME: {
COUNTRY_SELECTOR: 'CountrySelector',
BANK_ACCOUNT_DETAILS: 'BankAccountDetails',
ACCOUNT_TYPE: 'AccountType',
BANK_INFORMATION: 'BankInformation',
ACCOUNT_HOLDER_INFORMATION: 'AccountHolderInformation',
CONFIRMATION: 'Confirmation',
SUCCESS: 'Success',
},
INDEXES: {
MAPPING: {
COUNTRY_SELECTOR: 0,
BANK_ACCOUNT_DETAILS: 1,
ACCOUNT_TYPE: 2,
BANK_INFORMATION: 3,
ACCOUNT_HOLDER_INFORMATION: 4,
CONFIRMATION: 5,
SUCCESS: 6,
},
},
},

HYBRID_APP: {
REORDERING_REACT_NATIVE_ACTIVITY_TO_FRONT: 'reorderingReactNativeActivityToFront',
},
Expand Down
11 changes: 8 additions & 3 deletions src/ONYXKEYS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,7 @@ const ONYXKEYS = {
POLICY_RECENTLY_USED_CATEGORIES: 'policyRecentlyUsedCategories_',
POLICY_TAGS: 'policyTags_',
POLICY_RECENTLY_USED_TAGS: 'nvp_recentlyUsedTags_',
POLICY_RECENTLY_USED_DESTINATIONS: 'nvp_recentlyUsedDestinations_',
// Whether the policy's connection data was attempted to be fetched in
// the current user session. As this state only exists client-side, it
// should not be included as part of the policy object. The policy
Expand Down Expand Up @@ -600,8 +601,6 @@ const ONYXKEYS = {
HOME_ADDRESS_FORM_DRAFT: 'homeAddressFormDraft',
PERSONAL_DETAILS_FORM: 'personalDetailsForm',
PERSONAL_DETAILS_FORM_DRAFT: 'personalDetailsFormDraft',
INTERNATIONAL_BANK_ACCOUNT_FORM: 'internationalBankAccountForm',
INTERNATIONAL_BANK_ACCOUNT_FORM_DRAFT: 'internationalBankAccountFormDraft',
NEW_ROOM_FORM: 'newRoomForm',
NEW_ROOM_FORM_DRAFT: 'newRoomFormDraft',
ROOM_SETTINGS_FORM: 'roomSettingsForm',
Expand All @@ -622,6 +621,10 @@ const ONYXKEYS = {
MONEY_REQUEST_HOLD_FORM_DRAFT: 'moneyHoldReasonFormDraft',
MONEY_REQUEST_COMPANY_INFO_FORM: 'moneyRequestCompanyInfoForm',
MONEY_REQUEST_COMPANY_INFO_FORM_DRAFT: 'moneyRequestCompanyInfoFormDraft',
MONEY_REQUEST_TIME_FORM: 'moneyRequestTimeForm',
MONEY_REQUEST_TIME_FORM_DRAFT: 'moneyRequestTimeFormDraft',
MONEY_REQUEST_SUBRATE_FORM: 'moneyRequestSubrateForm',
MONEY_REQUEST_SUBRATE_FORM_DRAFT: 'moneyRequestSubrateFormDraft',
NEW_CONTACT_METHOD_FORM: 'newContactMethodForm',
NEW_CONTACT_METHOD_FORM_DRAFT: 'newContactMethodFormDraft',
WAYPOINT_FORM: 'waypointForm',
Expand Down Expand Up @@ -767,6 +770,8 @@ type OnyxFormValuesMapping = {
[ONYXKEYS.FORMS.MONEY_REQUEST_MERCHANT_FORM]: FormTypes.MoneyRequestMerchantForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_AMOUNT_FORM]: FormTypes.MoneyRequestAmountForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_DATE_FORM]: FormTypes.MoneyRequestDateForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_TIME_FORM]: FormTypes.MoneyRequestTimeForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_SUBRATE_FORM]: FormTypes.MoneyRequestSubrateForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_HOLD_FORM]: FormTypes.MoneyRequestHoldReasonForm;
[ONYXKEYS.FORMS.MONEY_REQUEST_COMPANY_INFO_FORM]: FormTypes.MoneyRequestCompanyInfoForm;
[ONYXKEYS.FORMS.NEW_CONTACT_METHOD_FORM]: FormTypes.NewContactMethodForm;
Expand Down Expand Up @@ -821,7 +826,6 @@ type OnyxFormValuesMapping = {
[ONYXKEYS.FORMS.RULES_MAX_EXPENSE_AGE_FORM]: FormTypes.RulesMaxExpenseAgeForm;
[ONYXKEYS.FORMS.SEARCH_SAVED_SEARCH_RENAME_FORM]: FormTypes.SearchSavedSearchRenameForm;
[ONYXKEYS.FORMS.DEBUG_DETAILS_FORM]: FormTypes.DebugReportForm | FormTypes.DebugReportActionForm | FormTypes.DebugTransactionForm | FormTypes.DebugTransactionViolationForm;
[ONYXKEYS.FORMS.INTERNATIONAL_BANK_ACCOUNT_FORM]: FormTypes.InternationalBankAccountForm;
[ONYXKEYS.FORMS.WORKSPACE_PER_DIEM_FORM]: FormTypes.WorkspacePerDiemForm;
};

Expand All @@ -837,6 +841,7 @@ type OnyxCollectionValuesMapping = {
[ONYXKEYS.COLLECTION.POLICY_CATEGORIES_DRAFT]: OnyxTypes.PolicyCategories;
[ONYXKEYS.COLLECTION.POLICY_TAGS]: OnyxTypes.PolicyTagLists;
[ONYXKEYS.COLLECTION.POLICY_RECENTLY_USED_CATEGORIES]: OnyxTypes.RecentlyUsedCategories;
[ONYXKEYS.COLLECTION.POLICY_RECENTLY_USED_DESTINATIONS]: OnyxTypes.RecentlyUsedCategories;
[ONYXKEYS.COLLECTION.POLICY_HAS_CONNECTIONS_DATA_BEEN_FETCHED]: boolean;
[ONYXKEYS.COLLECTION.DEPRECATED_POLICY_MEMBER_LIST]: OnyxTypes.PolicyEmployeeList;
[ONYXKEYS.COLLECTION.WORKSPACE_INVITE_MEMBERS_DRAFT]: OnyxTypes.InvitedEmailsToAccountIDs;
Expand Down
35 changes: 34 additions & 1 deletion src/ROUTES.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,6 @@ const ROUTES = {
},
SETTINGS_ADD_DEBIT_CARD: 'settings/wallet/add-debit-card',
SETTINGS_ADD_BANK_ACCOUNT: 'settings/wallet/add-bank-account',
SETTINGS_ADD_US_BANK_ACCOUNT: 'settings/wallet/add-us-bank-account',
SETTINGS_ENABLE_PAYMENTS: 'settings/wallet/enable-payments',
SETTINGS_WALLET_CARD_DIGITAL_DETAILS_UPDATE_ADDRESS: {
route: 'settings/wallet/card/:domain/digital-details/update-address',
Expand Down Expand Up @@ -486,6 +485,36 @@ const ROUTES = {
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/upgrade/${transactionID}/${reportID}`, backTo),
},
MONEY_REQUEST_STEP_DESTINATION: {
route: ':action/:iouType/destination/:transactionID/:reportID',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/destination/${transactionID}/${reportID}`, backTo),
},
MONEY_REQUEST_STEP_TIME: {
route: ':action/:iouType/time/:transactionID/:reportID',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/time/${transactionID}/${reportID}`, backTo),
},
MONEY_REQUEST_STEP_SUBRATE: {
route: ':action/:iouType/subrate/:transactionID/:reportID/:pageIndex',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/subrate/${transactionID}/${reportID}/0`, backTo),
},
MONEY_REQUEST_STEP_DESTINATION_EDIT: {
route: ':action/:iouType/destination/:transactionID/:reportID/edit',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/destination/${transactionID}/${reportID}/edit`, backTo),
},
MONEY_REQUEST_STEP_TIME_EDIT: {
route: ':action/:iouType/time/:transactionID/:reportID/edit',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/time/${transactionID}/${reportID}/edit`, backTo),
},
MONEY_REQUEST_STEP_SUBRATE_EDIT: {
route: ':action/:iouType/subrate/:transactionID/:reportID/edit/:pageIndex',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string, pageIndex = 0, backTo = '') =>
getUrlWithBackToParam(`${action as string}/${iouType as string}/subrate/${transactionID}/${reportID}/edit/${pageIndex}`, backTo),
},
SETTINGS_TAGS_ROOT: {
route: 'settings/:policyID/tags',
getRoute: (policyID: string, backTo = '') => getUrlWithBackToParam(`settings/${policyID}/tags`, backTo),
Expand Down Expand Up @@ -646,6 +675,10 @@ const ROUTES = {
route: ':action/:iouType/start/:transactionID/:reportID/scan',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string) => `create/${iouType as string}/start/${transactionID}/${reportID}/scan` as const,
},
MONEY_REQUEST_CREATE_TAB_PER_DIEM: {
route: ':action/:iouType/start/:transactionID/:reportID/per-diem',
getRoute: (action: IOUAction, iouType: IOUType, transactionID: string, reportID: string) => `create/${iouType as string}/start/${transactionID}/${reportID}/per-diem` as const,
},

MONEY_REQUEST_STATE_SELECTOR: {
route: 'submit/state',
Expand Down
7 changes: 6 additions & 1 deletion src/SCREENS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ const SCREENS = {
ADD_DEBIT_CARD: 'Settings_Add_Debit_Card',
ADD_PAYMENT_CARD_CHANGE_CURRENCY: 'Settings_Add_Payment_Card_Change_Currency',
ADD_BANK_ACCOUNT: 'Settings_Add_Bank_Account',
ADD_US_BANK_ACCOUNT: 'Settings_Add_US_Bank_Account',
CLOSE: 'Settings_Close',
TWO_FACTOR_AUTH: 'Settings_TwoFactorAuth',
REPORT_CARD_LOST_OR_DAMAGED: 'Settings_ReportCardLostOrDamaged',
Expand Down Expand Up @@ -231,6 +230,12 @@ const SCREENS = {
RECEIPT: 'Money_Request_Receipt',
STATE_SELECTOR: 'Money_Request_State_Selector',
STEP_ATTENDEES: 'Money_Request_Attendee',
STEP_DESTINATION: 'Money_Request_Destination',
STEP_TIME: 'Money_Request_Time',
STEP_SUBRATE: 'Money_Request_SubRate',
STEP_DESTINATION_EDIT: 'Money_Request_Destination_Edit',
STEP_TIME_EDIT: 'Money_Request_Time_Edit',
STEP_SUBRATE_EDIT: 'Money_Request_SubRate_Edit',
},

TRANSACTION_DUPLICATE: {
Expand Down
Loading

0 comments on commit fb46ac3

Please sign in to comment.