Update mobile number validation to 9 digits and adjust placeholder; update Gradle init scripts and add new launcher icon
This commit is contained in:
@@ -52,10 +52,10 @@ export default function LoginScreen() {
|
||||
);
|
||||
|
||||
const handleContinue = async () => {
|
||||
if (!/^\d{10}$/.test(mobile)) {
|
||||
setError('Please enter a 10-digit mobile number');
|
||||
return;
|
||||
}
|
||||
if (!/^\d{9}$/.test(mobile)) {
|
||||
setError('Please enter a 9-digit mobile number');
|
||||
return;
|
||||
}
|
||||
|
||||
setError('');
|
||||
try {
|
||||
@@ -96,7 +96,7 @@ export default function LoginScreen() {
|
||||
<View style={styles.formSection}>
|
||||
<CustomInput
|
||||
label="Mobile Number"
|
||||
placeholder="e.g. 9876543210"
|
||||
placeholder="e.g. 987654321"
|
||||
value={mobile}
|
||||
onChangeText={(text) => {
|
||||
setMobile(text.replace(/\D/g, ''));
|
||||
@@ -104,7 +104,7 @@ export default function LoginScreen() {
|
||||
if (error) setError('');
|
||||
}}
|
||||
keyboardType="phone-pad"
|
||||
maxLength={10}
|
||||
maxLength={9}
|
||||
icon="call-outline"
|
||||
error={error}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user