|
@ -1,13 +1,9 @@ |
|
|
import React, { useState, useEffect } from "react"; |
|
|
|
|
|
|
|
|
import React from "react"; |
|
|
import { useFormikContext } from "formik"; |
|
|
import { useFormikContext } from "formik"; |
|
|
import { unMask, mask } from "react-native-mask-text"; |
|
|
import { unMask, mask } from "react-native-mask-text"; |
|
|
import TextInput from "../TextInput"; |
|
|
import TextInput from "../TextInput"; |
|
|
import ErrorMessage from "./ErrorMessage"; |
|
|
import ErrorMessage from "./ErrorMessage"; |
|
|
import { View, Text, StyleSheet } from "react-native"; |
|
|
|
|
|
import { TouchableOpacity } from "react-native-gesture-handler"; |
|
|
|
|
|
import colors from "../../config/colors"; |
|
|
|
|
|
import defaultStyles from "../../config/styles"; |
|
|
|
|
|
// import { MaskedTextInput } from "react-native-mask-text";
|
|
|
|
|
|
|
|
|
import { View } from "react-native"; |
|
|
|
|
|
|
|
|
function PhoneNumberFormField({ |
|
|
function PhoneNumberFormField({ |
|
|
name, |
|
|
name, |
|
@ -16,6 +12,7 @@ function PhoneNumberFormField({ |
|
|
placeholder = "", |
|
|
placeholder = "", |
|
|
paddingLeft = 16, |
|
|
paddingLeft = 16, |
|
|
paddingRight = 16, |
|
|
paddingRight = 16, |
|
|
|
|
|
editable = true, |
|
|
}) { |
|
|
}) { |
|
|
const { |
|
|
const { |
|
|
values, |
|
|
values, |
|
@ -37,6 +34,7 @@ function PhoneNumberFormField({ |
|
|
}} |
|
|
}} |
|
|
> |
|
|
> |
|
|
<TextInput |
|
|
<TextInput |
|
|
|
|
|
editable={editable} |
|
|
height={48} |
|
|
height={48} |
|
|
onBlur={() => setFieldTouched(name)} |
|
|
onBlur={() => setFieldTouched(name)} |
|
|
onChangeText={(val) => { |
|
|
onChangeText={(val) => { |
|
|