reza fixed profile inputs maxLength and drawer useNativeDrawer has been added

master
Reza_ashrafi 3 years ago
parent 16eb8dca13
commit 7b1b6b5b4f
  1. 1
      src/components/AlertModal.js
  2. 2
      src/components/Drawer.js
  3. 10
      src/screens/Address/index.js

@ -110,7 +110,6 @@ const AlertModal = props => {
}} }}
confirmButtonStyle={ confirmButtonStyle={
{ {
width: ReactNative.Dimensions.get('window').width / 4,
alignItems: 'center', alignItems: 'center',
justifyContent: 'center', justifyContent: 'center',
fontFamily : 'regular', fontFamily : 'regular',

@ -261,6 +261,7 @@ const Drawer = ({ position, setBoxPosition, user, mobile, theme }) => {
Animated.timing(fadeAnim, { Animated.timing(fadeAnim, {
toValue: 0.5, toValue: 0.5,
duration: 300, duration: 300,
useNativeDriver: true // Add This line
}).start(); }).start();
}, 300); }, 300);
} }
@ -268,6 +269,7 @@ const Drawer = ({ position, setBoxPosition, user, mobile, theme }) => {
Animated.timing(fadeAnim, { Animated.timing(fadeAnim, {
toValue: 0, toValue: 0,
duration: 10, duration: 10,
useNativeDriver: true // Add This line
}).start(); }).start();
} }
}, [position]); }, [position]);

@ -252,7 +252,7 @@ const Address = ({
}} }}
> >
<ScrollView style={tw("flex-1 px-4")}> <ScrollView style={tw("flex-1 px-4")}>
<KeyboardAvoidingView behavior={"padding"} style={[{ height }]}> <KeyboardAvoidingView behavior={"padding"}>
<TouchableWithoutFeedback> <TouchableWithoutFeedback>
<View style={tw("flex-1")}> <View style={tw("flex-1")}>
<Navbar <Navbar
@ -313,7 +313,7 @@ const Address = ({
placeholder="" placeholder=""
textAlign="left" textAlign="left"
name="nationalId" name="nationalId"
maxlength="10" maxLength={10}
value={profileFields.nationalId} value={profileFields.nationalId}
onChange={(name, value) => onChange={(name, value) =>
setProfileFields({ ...profileFields, nationalId: value }) setProfileFields({ ...profileFields, nationalId: value })
@ -334,7 +334,7 @@ const Address = ({
placeholder="" placeholder=""
textAlign="left" textAlign="left"
name="cellphone" name="cellphone"
maxlength="11" maxLength={11}
value={ value={
profilePage profilePage
? profileFields.cellphone ? profileFields.cellphone
@ -354,7 +354,7 @@ const Address = ({
placeholder="" placeholder=""
textAlign="left" textAlign="left"
name="phone" name="phone"
maxlength="11" maxLength={11}
value={profilePage ? profileFields.phone : addressFields?.phone} value={profilePage ? profileFields.phone : addressFields?.phone}
onChange={(name, value) => onChange={(name, value) =>
profilePage profilePage
@ -411,7 +411,7 @@ const Address = ({
placeholder="" placeholder=""
textAlign="left" textAlign="left"
name="postalCode" name="postalCode"
maxlength="10" maxLength={10}
value={ value={
profilePage profilePage
? profileFields.postalCode ? profileFields.postalCode

Loading…
Cancel
Save