diff --git a/app/(auth)/sign-up.tsx b/app/(auth)/sign-up.tsx index be38c49..96aef16 100644 --- a/app/(auth)/sign-up.tsx +++ b/app/(auth)/sign-up.tsx @@ -1,11 +1,97 @@ -import { Text } from "react-native"; -import { SafeAreaView } from "react-native-safe-area-context"; +import { useState } from "react"; +import { Image, ScrollView, Text, View } from "react-native"; + +import { InputField } from "@/components/input-field"; +import { icons, images } from "@/constants"; +import { CustomButton } from "@/components/custom-button"; +import { Link } from "expo-router"; const SignUp = () => { + const [form, setForm] = useState({ + name: "", + email: "", + password: "", + }); + + const onSignUpPress = async () => {}; + return ( - - SignUp - + + + + Car + + + Create Your Account + + + + + + setForm((prevForm) => ({ + ...prevForm, + name: value, + })) + } + /> + + + setForm((prevForm) => ({ + ...prevForm, + email: value, + })) + } + /> + + + setForm((prevForm) => ({ + ...prevForm, + password: value, + })) + } + /> + + + + {/* OAuth */} + + + Already have an account? + Login + + + + {/* Verification Modal */} + + ); }; diff --git a/app/(auth)/welcome.tsx b/app/(auth)/welcome.tsx index 72d5f1e..3c8cf2e 100644 --- a/app/(auth)/welcome.tsx +++ b/app/(auth)/welcome.tsx @@ -1,11 +1,12 @@ -import { CustomButton } from "@/components/custom-button"; -import { onboarding } from "@/constants"; import { router } from "expo-router"; import { useRef, useState } from "react"; import { Image, Text, TouchableOpacity, View } from "react-native"; import { SafeAreaView } from "react-native-safe-area-context"; import Swiper from "react-native-swiper"; +import { CustomButton } from "@/components/custom-button"; +import { onboarding } from "@/constants"; + const Welcome = () => { const swiperRef = useRef(null); const [activeIndex, setActiveIndex] = useState(0); @@ -32,6 +33,7 @@ const Welcome = () => { {`Onboarding diff --git a/components/custom-button.tsx b/components/custom-button.tsx index 698bc0d..f11d0cb 100644 --- a/components/custom-button.tsx +++ b/components/custom-button.tsx @@ -1,4 +1,4 @@ -import { ButtonProps } from "@/types/type"; +import type { ButtonProps } from "@/types/type"; import React from "react"; import { Text, TouchableOpacity } from "react-native"; diff --git a/components/input-field.tsx b/components/input-field.tsx new file mode 100644 index 0000000..4a8ce07 --- /dev/null +++ b/components/input-field.tsx @@ -0,0 +1,53 @@ +import { + Image, + Keyboard, + KeyboardAvoidingView, + Platform, + Text, + TextInput, + TouchableWithoutFeedback, + View, +} from "react-native"; + +import type { InputFieldProps } from "@/types/type"; + +export const InputField = ({ + label, + labelStyles, + icon, + secureTextEntry = false, + containerStyles, + inputStyles, + iconStyles, + className, + ...props +}: InputFieldProps) => ( + + + + + {label} + + + + {icon && ( + {`${label} + )} + + + + + + +); diff --git a/types/type.d.ts b/types/type.d.ts index 79b07fd..a57b80f 100644 --- a/types/type.d.ts +++ b/types/type.d.ts @@ -82,10 +82,10 @@ declare interface InputFieldProps extends TextInputProps { label: string; icon?: any; secureTextEntry?: boolean; - labelStyle?: string; - containerStyle?: string; - inputStyle?: string; - iconStyle?: string; + labelStyles?: string; + containerStyles?: string; + inputStyles?: string; + iconStyles?: string; className?: string; }