Merge remote-tracking branch 'upstream/development' into nt/pin-encryption

This commit is contained in:
Nouman Tahir 2022-07-28 11:34:37 +05:00
commit 3062e91e02
12 changed files with 63 additions and 32 deletions

View File

@ -144,7 +144,7 @@ android {
minSdkVersion rootProject.ext.minSdkVersion minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion
versionCode versionMajor * 10000 + versionMinor * 100 + versionPatch versionCode versionMajor * 10000 + versionMinor * 100 + versionPatch
versionName "3.0.32" versionName "3.0.33"
resValue "string", "build_config_package", "app.esteem.mobile.android" resValue "string", "build_config_package", "app.esteem.mobile.android"
multiDexEnabled true multiDexEnabled true
// react-native-image-crop-picker // react-native-image-crop-picker

View File

@ -15,11 +15,11 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>3.0.32</string> <string>3.0.33</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2811</string> <string>2812</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true /> <true />
<key>NSAppTransportSecurity</key> <key>NSAppTransportSecurity</key>

View File

@ -15,10 +15,10 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>BNDL</string> <string>BNDL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>3.0.32</string> <string>3.0.33</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2811</string> <string>2812</string>
</dict> </dict>
</plist> </plist>

View File

@ -1132,7 +1132,7 @@
CODE_SIGN_IDENTITY = "iPhone Distribution"; CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Manual; CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = 2811; CURRENT_PROJECT_VERSION = 2812;
DEAD_CODE_STRIPPING = NO; DEAD_CODE_STRIPPING = NO;
DEVELOPMENT_TEAM = 75B6RXTKGT; DEVELOPMENT_TEAM = 75B6RXTKGT;
EXCLUDED_ARCHS = ""; EXCLUDED_ARCHS = "";
@ -1211,7 +1211,7 @@
CODE_SIGN_ENTITLEMENTS = Ecency/Ecency.entitlements; CODE_SIGN_ENTITLEMENTS = Ecency/Ecency.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_IDENTITY = "iPhone Developer";
CODE_SIGN_STYLE = Manual; CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = 2811; CURRENT_PROJECT_VERSION = 2812;
DEAD_CODE_STRIPPING = NO; DEAD_CODE_STRIPPING = NO;
DEVELOPMENT_TEAM = 75B6RXTKGT; DEVELOPMENT_TEAM = 75B6RXTKGT;
EXCLUDED_ARCHS = ""; EXCLUDED_ARCHS = "";

View File

@ -17,7 +17,7 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>3.0.32</string> <string>3.0.33</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleURLTypes</key> <key>CFBundleURLTypes</key>

View File

@ -15,10 +15,10 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>BNDL</string> <string>BNDL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>3.0.32</string> <string>3.0.33</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2811</string> <string>2812</string>
</dict> </dict>
</plist> </plist>

View File

@ -17,9 +17,9 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string> <string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>3.0.32</string> <string>3.0.33</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>2811</string> <string>2812</string>
<key>NSExtension</key> <key>NSExtension</key>
<dict> <dict>
<key>NSExtensionAttributes</key> <key>NSExtensionAttributes</key>

View File

@ -1,6 +1,6 @@
{ {
"name": "ecency", "name": "ecency",
"version": "3.0.32", "version": "3.0.33",
"displayName": "Ecency", "displayName": "Ecency",
"private": true, "private": true,
"rnpm": { "rnpm": {

View File

@ -26,7 +26,6 @@ interface Props extends TextInputProps {
inputStyle:TextStyle; inputStyle:TextStyle;
isValid:boolean; isValid:boolean;
onChange?:(value:string)=>void; onChange?:(value:string)=>void;
handleFocus?:(value:boolean)=>void;
} }
const FormInputView = ({ const FormInputView = ({
@ -45,7 +44,6 @@ const FormInputView = ({
isValid, isValid,
value, value,
onBlur, onBlur,
handleFocus,
...props ...props
}:Props) => { }:Props) => {
const [_value, setValue] = useState(value || ''); const [_value, setValue] = useState(value || '');
@ -64,16 +62,10 @@ const FormInputView = ({
const _handleOnFocus = () => { const _handleOnFocus = () => {
setInputBorderColor('#357ce6'); setInputBorderColor('#357ce6');
if(handleFocus){
handleFocus(true);
}
}; };
const _handleOnBlur = () => { const _handleOnBlur = () => {
setInputBorderColor('#e7e7e7'); setInputBorderColor('#e7e7e7');
if(handleFocus){
handleFocus(false);
}
if (onBlur) { if (onBlur) {
onBlur(); onBlur();
} }

View File

@ -1,5 +1,6 @@
import React, { PureComponent } from 'react'; import React, { PureComponent } from 'react';
import { View, Text, Image, SafeAreaView } from 'react-native'; import { View, Text, Image, SafeAreaView } from 'react-native';
import * as Animatable from 'react-native-animatable';
// Constants // Constants
// Components // Components
@ -7,6 +8,7 @@ import { TextButton } from '../../buttons';
import { LineBreak } from '../../basicUIElements'; import { LineBreak } from '../../basicUIElements';
// Styles // Styles
import styles from './loginHeaderStyles'; import styles from './loginHeaderStyles';
import getWindowDimensions from '../../../utils/getWindowDimensions';
class LoginHeaderView extends PureComponent { class LoginHeaderView extends PureComponent {
/* Props /* Props
@ -43,7 +45,10 @@ class LoginHeaderView extends PureComponent {
/> />
</View> </View>
</View> </View>
{!isKeyboardOpen && ( <Animatable.View
animation={isKeyboardOpen ? hideAnimation : showAnimation}
duration={300}
>
<View style={styles.body}> <View style={styles.body}>
<View style={styles.titleText}> <View style={styles.titleText}>
<Text style={styles.title}>{title}</Text> <Text style={styles.title}>{title}</Text>
@ -51,7 +56,7 @@ class LoginHeaderView extends PureComponent {
</View> </View>
<Image style={styles.mascot} source={require('../../../assets/love_mascot.png')} /> <Image style={styles.mascot} source={require('../../../assets/love_mascot.png')} />
</View> </View>
)} </Animatable.View>
<LineBreak /> <LineBreak />
</View> </View>
</SafeAreaView> </SafeAreaView>
@ -60,3 +65,27 @@ class LoginHeaderView extends PureComponent {
} }
export default LoginHeaderView; export default LoginHeaderView;
const { height } = getWindowDimensions();
const bodyHeight = height / 3.9;
const showAnimation = {
from: {
opacity: 0,
height: 0,
},
to: {
opacity: 1,
height: bodyHeight,
},
};
const hideAnimation = {
from: {
opacity: 1,
height: bodyHeight,
},
to: {
opacity: 0,
height: 0,
},
};

View File

@ -1,5 +1,5 @@
import React, { PureComponent } from 'react'; import React, { PureComponent } from 'react';
import { View, StatusBar, Platform } from 'react-native'; import { View, StatusBar, Platform, Keyboard } from 'react-native';
import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view'; import { KeyboardAwareScrollView } from 'react-native-keyboard-aware-scroll-view';
import ScrollableTabView from 'react-native-scrollable-tab-view'; import ScrollableTabView from 'react-native-scrollable-tab-view';
import { injectIntl } from 'react-intl'; import { injectIntl } from 'react-intl';
@ -41,6 +41,11 @@ class LoginScreen extends PureComponent {
}; };
} }
componentWillUnmount() {
this.keyboardDidShowListener.remove();
this.keyboardDidHideListener.remove();
}
_handleOnPasswordChange = (value) => { _handleOnPasswordChange = (value) => {
this.setState({ password: value }); this.setState({ password: value });
}; };
@ -62,13 +67,20 @@ class LoginScreen extends PureComponent {
this.setState({ isModalOpen: !isModalOpen }); this.setState({ isModalOpen: !isModalOpen });
}; };
_handleFormInputFocus = (isFocused) => { UNSAFE_componentWillMount() {
this.setState({ keyboardIsOpen: isFocused }); this.keyboardDidShowListener = Keyboard.addListener('keyboardDidShow', () =>
}; this.setState({ keyboardIsOpen: true }),
);
this.keyboardDidHideListener = Keyboard.addListener('keyboardDidHide', () =>
this.setState({ keyboardIsOpen: false }),
);
}
render() { render() {
const { navigation, intl, handleOnPressLogin, handleSignUp, isLoading } = this.props; const { navigation, intl, handleOnPressLogin, handleSignUp, isLoading } = this.props;
const { username, isUsernameValid, keyboardIsOpen, password, isModalOpen } = this.state; const { username, isUsernameValid, keyboardIsOpen, password, isModalOpen } = this.state;
console.log('keyboardIsOpen : ', keyboardIsOpen);
return ( return (
<View style={styles.container}> <View style={styles.container}>
<StatusBar hidden translucent /> <StatusBar hidden translucent />
@ -123,7 +135,6 @@ class LoginScreen extends PureComponent {
isFirstImage isFirstImage
value={username} value={username}
inputStyle={styles.input} inputStyle={styles.input}
handleFocus={this._handleFormInputFocus}
/> />
<FormInput <FormInput
rightIconName="lock" rightIconName="lock"
@ -138,7 +149,6 @@ class LoginScreen extends PureComponent {
type="password" type="password"
numberOfLines={1} numberOfLines={1}
inputStyle={styles.input} inputStyle={styles.input}
handleFocus={this._handleFormInputFocus}
/> />
<InformationArea <InformationArea
description={intl.formatMessage({ description={intl.formatMessage({

View File

@ -27,9 +27,9 @@ export default EStyleSheet.create({
justifyContent: 'center', justifyContent: 'center',
alignItems: 'center', alignItems: 'center',
alignSelf: 'flex-end', alignSelf: 'flex-end',
marginRight: 10, paddingRight: 24,
bottom: 24, paddingBottom: 24,
right: 24, backgroundColor: '$primaryBackgroundColor',
}, },
cancelButton: { cancelButton: {
marginRight: 10, marginRight: 10,