Skip to content
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

Update staging to 1.0.16-0 #2287

Merged
merged 61 commits into from
Apr 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
21a8d88
Add email to the set password link
jasperhuangg Mar 18, 2021
e89635c
fix js style
jasperhuangg Mar 18, 2021
55cc702
fix js style
jasperhuangg Mar 18, 2021
4e4b83e
fix js style
jasperhuangg Mar 18, 2021
f96fd91
fix js style
jasperhuangg Mar 18, 2021
0c0d616
Update Session.js
jasperhuangg Mar 18, 2021
6502af7
Update Session.js
jasperhuangg Mar 18, 2021
b22f510
Add reasonable default
jasperhuangg Mar 18, 2021
c9b4933
Merge branch 'jasper-setPasswordEmailLink' of github.com:Expensify/Ex…
jasperhuangg Mar 18, 2021
e9cec36
fix JSDoc
jasperhuangg Mar 18, 2021
398bbe5
fix JSDoc
jasperhuangg Mar 18, 2021
5430cf0
remove unused defaults
jasperhuangg Mar 22, 2021
bb7be20
reroute resend validate code to SetCashPassword command
jasperhuangg Mar 23, 2021
82b5465
remove incorrect destructuring usage
jasperhuangg Mar 23, 2021
b2b00ab
Merge branch 'master' into jasper-setPasswordEmailLink
jasperhuangg Mar 23, 2021
a6e5721
Change API command back to ResendValidateCode
jasperhuangg Mar 24, 2021
daa2fec
Simplify call to createTemporaryLogin
jasperhuangg Mar 24, 2021
8c343b4
Merge branch 'master' of github.com:Expensify/Expensify.cash into jas…
jasperhuangg Mar 24, 2021
a72a6c5
Change SetPassword to use accountID instead of email (to keep consist…
jasperhuangg Mar 26, 2021
251d7e3
Change SetPassword to also include email if provided.
jasperhuangg Mar 26, 2021
b3c2f5c
Change SetPassword to also include email if provided.
jasperhuangg Mar 26, 2021
1c2977b
Change SetPassword to also include email if provided.
jasperhuangg Mar 26, 2021
25b6b8a
Change SetPassword to also include email if provided.
jasperhuangg Mar 26, 2021
4f97d57
Update JSDoc for SetPassword, make accountID optional
jasperhuangg Mar 29, 2021
2f012b7
Remove email parameter from SetPassword, make accountID a required pa…
jasperhuangg Mar 31, 2021
d56a924
Added Localize HOC
parasharrajat Apr 1, 2021
45cdac0
new: added numberFormat method
parasharrajat Apr 2, 2021
46d4393
props update
parasharrajat Apr 3, 2021
c86b93d
Remove unused routes
jasperhuangg Apr 6, 2021
c761d0b
Add font: fontFamily.GTA to link styles
jasperhuangg Apr 6, 2021
9c508d8
initialize current user personal details to an empty object if they h…
marcaaron Apr 6, 2021
d851570
add comments/docs
Maftalion Apr 7, 2021
775439a
Update src/libs/API.js
jasperhuangg Apr 7, 2021
4ee6e0e
Add inline comments
jasperhuangg Apr 7, 2021
1ba8ca8
Merge remote-tracking branch 'origin/jasper-setPasswordEmailLink' int…
jasperhuangg Apr 7, 2021
fa13248
Fix CSS syntax
jasperhuangg Apr 7, 2021
a1b29fa
Revert changes introduced by PR 2183
marcaaron Apr 7, 2021
5869e17
Merge pull request #1857 from Expensify/jasper-setPasswordEmailLink
marcaaron Apr 7, 2021
be85af6
Update version to 1.0.13-5
Apr 7, 2021
b1b663a
Merge pull request #2267 from Expensify/marcaaron-revert2183
roryabraham Apr 7, 2021
c9f106a
Merge pull request #2268 from Expensify/version-bump-5869e1773fb9668a…
OSBotify Apr 7, 2021
914fd8d
Update version to 1.0.13-6
Apr 7, 2021
3a83195
Merge pull request #2250 from Expensify/marcaaron-fixPersonalDetailsC…
Jag96 Apr 7, 2021
be19338
Merge pull request #2269 from Expensify/version-bump-b1b663acb98c1729…
OSBotify Apr 7, 2021
47ab044
Update version to 1.0.13-7
Apr 7, 2021
59cbd28
Merge pull request #2271 from Expensify/version-bump-3a83195ee7d4a051…
OSBotify Apr 7, 2021
6847bf8
Update version to 1.0.14-0
Apr 7, 2021
0a18f60
Merge pull request #2272 from Expensify/version-patch-59cbd28fc195f0c…
OSBotify Apr 7, 2021
08d34db
Change GSD to focus
roryabraham Apr 7, 2021
11488ec
Merge pull request #2273 from Expensify/Rory-GSDToFocus
roryabraham Apr 7, 2021
d8e21c4
Update version to 1.0.14-1
Apr 7, 2021
475628c
Merge pull request #2274 from Expensify/version-bump-11488ec7d1e2f0ca…
OSBotify Apr 7, 2021
89c9094
Update version to 1.0.15-0
Apr 7, 2021
1ab6b39
Merge pull request #2275 from Expensify/version-patch-11488ec7d1e2f0c…
OSBotify Apr 7, 2021
f0b220a
Merge pull request #2251 from Maftalion/matt-2029-seconday-logins-fol…
deetergp Apr 7, 2021
07fc761
Bump expensify-common hash
Apr 7, 2021
965f92f
remove numbeformat Polyfills from IOS
parasharrajat Apr 7, 2021
28301d4
Merge pull request #2237 from Expensify/jasper-fixLinkFont
tgolen Apr 7, 2021
6d14c36
Merge pull request #2277 from Expensify/amechler-expensify-common-hash
ctkochan22 Apr 7, 2021
fbf0864
Merge pull request #2208 from parasharrajat/parasharrajat/translations
iwiznia Apr 7, 2021
2b3d906
Update version to 1.0.16-0
Apr 7, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
versionCode 1001001304
versionName "1.0.13-4"
versionCode 1001001600
versionName "1.0.16-0"
}
splits {
abi {
Expand Down
4 changes: 2 additions & 2 deletions ios/ExpensifyCash/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0.13</string>
<string>1.0.16</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
Expand All @@ -30,7 +30,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>1.0.13.4</string>
<string>1.0.16.0</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationQueriesSchemes</key>
Expand Down
4 changes: 2 additions & 2 deletions ios/ExpensifyCashTests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>1.0.13</string>
<string>1.0.16</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0.13.4</string>
<string>1.0.16.0</string>
</dict>
</plist>
139 changes: 136 additions & 3 deletions package-lock.json

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

8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "expensify.cash",
"version": "1.0.13-4",
"version": "1.0.16-0",
"author": "Expensify, Inc.",
"homepage": "https://expensify.cash",
"description": "Expensify.cash is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.",
Expand Down Expand Up @@ -31,6 +31,10 @@
"dependencies": {
"@babel/plugin-proposal-class-properties": "^7.12.1",
"@babel/preset-flow": "^7.12.13",
"@formatjs/intl-getcanonicallocales": "^1.5.8",
"@formatjs/intl-locale": "^2.4.21",
"@formatjs/intl-numberformat": "^6.2.5",
"@formatjs/intl-pluralrules": "^4.0.13",
"@react-native-community/async-storage": "^1.11.0",
"@react-native-community/cli": "4.13.1",
"@react-native-community/clipboard": "^1.5.1",
Expand All @@ -51,7 +55,7 @@
"electron-log": "^4.2.4",
"electron-serve": "^1.0.0",
"electron-updater": "^4.3.4",
"expensify-common": "git+https://github.com/Expensify/expensify-common.git#3d8fc7500ddd24cd4a543e6e160d4f1ad97cc145",
"expensify-common": "git+https://github.com/Expensify/expensify-common.git#679fc86cfc4f9bc701e3757d583d74057edbbe28",
"file-loader": "^6.0.0",
"html-entities": "^1.3.1",
"lodash": "4.17.21",
Expand Down
2 changes: 1 addition & 1 deletion src/ROUTES.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export default {
IOU_BILL: 'iou/split',
SEARCH: 'search',
SIGNIN: 'signin',
SET_PASSWORD_WITH_VALIDATE_CODE: 'setpassword/:validateCode',
SET_PASSWORD_WITH_VALIDATE_CODE: 'setpassword/:accountID/:validateCode',
DETAILS: 'details',
DETAILS_WITH_LOGIN: 'details/:login',
getDetailsRoute: login => `details/${login}`,
Expand Down
24 changes: 10 additions & 14 deletions src/components/FAB.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import React, {PureComponent} from 'react';
import {
Pressable, Animated, Easing, KeyboardAvoidingView, Platform,
} from 'react-native';
import {Pressable, Animated, Easing} from 'react-native';
import PropTypes from 'prop-types';
import Icon from './Icon';
import {Plus} from './Icon/Expensicons';
Expand Down Expand Up @@ -66,17 +64,15 @@ class FAB extends PureComponent {
});

return (
<KeyboardAvoidingView behavior={Platform.OS === 'ios' ? 'position' : 'height'}>
<AnimatedPressable
onPress={this.props.onPress}
style={[
styles.floatingActionButton,
getAnimatedFABStyle(rotate, backgroundColor),
]}
>
<AnimatedIcon src={Plus} fill={fill} />
</AnimatedPressable>
</KeyboardAvoidingView>
<AnimatedPressable
onPress={this.props.onPress}
style={[
styles.floatingActionButton,
getAnimatedFABStyle(rotate, backgroundColor),
]}
>
<AnimatedIcon src={Plus} fill={fill} />
</AnimatedPressable>
);
}
}
Expand Down
63 changes: 63 additions & 0 deletions src/components/withLocalize.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
import React from 'react';
import PropTypes from 'prop-types';
import {withOnyx} from 'react-native-onyx';
import getComponentDisplayName from '../libs/getComponentDisplayName';
import compose from '../libs/compose';
import ONYXKEYS from '../ONYXKEYS';
import {translate} from '../libs/translate';
import DateUtils from '../libs/DateUtils';
import {toLocalPhone, fromLocalPhone} from '../libs/LocalePhoneNumber';
import numberFormat from '../libs/numberFormat';

const withLocalizePropTypes = {
// Translations functions using current User's preferred locale
translations: PropTypes.shape({
translate: PropTypes.func.isRequired,
numberFormat: PropTypes.func.isRequired,
timestampToRelative: PropTypes.func.isRequired,
timestampToDateTime: PropTypes.func.isRequired,
toLocalPhone: PropTypes.func.isRequired,
fromLocalPhone: PropTypes.func.isRequired,
}),
};

function withLocalizeHOC(WrappedComponent) {
const withLocalize = (props) => {
const translations = {
translate: (phrase, variables) => translate(props.preferredLocale, phrase, variables),
numberFormat: (number, options) => numberFormat(props.preferredLocale, number, options),
timestampToRelative: timestamp => DateUtils.timestampToRelative(props.preferredLocale, timestamp),
timestampToDateTime: (timestamp, includeTimezone) => DateUtils.timestampToDateTime(
props.preferredLocale,
timestamp,
includeTimezone,
),
toLocalPhone: number => toLocalPhone(props.preferredLocale, number),
fromLocalPhone: number => fromLocalPhone(props.preferredLocale, number),
};
return (
<WrappedComponent
// eslint-disable-next-line react/jsx-props-no-spreading
{...props}
translations={translations}
/>
);
};
withLocalize.displayName = `withLocalize(${getComponentDisplayName(WrappedComponent)})`;
withLocalize.defaultProps = {
preferredLocale: 'en',
};
return withLocalize;
}
export default compose(
withOnyx({
preferredLocale: {
key: ONYXKEYS.PREFERRED_LOCALE,
},
}),
withLocalizeHOC,
);

export {
withLocalizePropTypes,
};
3 changes: 2 additions & 1 deletion src/libs/API.js
Original file line number Diff line number Diff line change
Expand Up @@ -554,11 +554,12 @@ function ResetPassword(parameters) {
* @param {Object} parameters
* @param {String} parameters.password
* @param {String} parameters.validateCode
* @param {String} parameters.accountID
* @returns {Promise}
*/
function SetPassword(parameters) {
const commandName = 'SetPassword';
requireParameters(['email', 'password', 'validateCode'], parameters, commandName);
requireParameters(['accountID', 'password', 'validateCode'], parameters, commandName);
return Network.post(commandName, parameters);
}

Expand Down
11 changes: 7 additions & 4 deletions src/libs/actions/PersonalDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,13 @@ function fetch() {
.then((data) => {
let myPersonalDetails = {};

// If personalDetailsList is empty, ensure we set the personal details for the current user
const personalDetailsList = _.isEmpty(data.personalDetailsList)
? {[currentUserEmail]: myPersonalDetails}
: data.personalDetailsList;
// If personalDetailsList does not have the current user ensure we initialize their details with an empty
// object at least
const personalDetailsList = _.isEmpty(data.personalDetailsList) ? {} : data.personalDetailsList;
if (!personalDetailsList[currentUserEmail]) {
personalDetailsList[currentUserEmail] = {};
}

const allPersonalDetails = formatPersonalDetails(personalDetailsList);
Onyx.merge(ONYXKEYS.PERSONAL_DETAILS, allPersonalDetails);

Expand Down
Loading