completed final todo
This commit is contained in:
committed by
GitHub
parent
96d14cecad
commit
2a0e9a79dc
@@ -24,7 +24,9 @@ const Home = () => {
|
||||
const { setUserLocation, setDestinationLocation } = useLocationStore();
|
||||
const { signOut } = useAuth();
|
||||
const { user } = useUser();
|
||||
const { data: recentRides, loading } = useFetch(`/(api)/ride/${user?.id}`);
|
||||
const { data: recentRides, loading } = useFetch<Ride[]>(
|
||||
`/(api)/ride/${user?.id}`,
|
||||
);
|
||||
|
||||
const [hasPermissions, setHasPermissions] = useState(false);
|
||||
|
||||
@@ -71,7 +73,7 @@ const Home = () => {
|
||||
return (
|
||||
<SafeAreaView className="bg-general-500">
|
||||
<FlatList
|
||||
data={(recentRides as Ride[])?.slice(0, 5)}
|
||||
data={recentRides?.slice(0, 5)}
|
||||
renderItem={({ item }) => <RideCard ride={item} />}
|
||||
className="px-5"
|
||||
keyboardShouldPersistTaps="handled"
|
||||
|
||||
@@ -30,7 +30,7 @@ const Profile = () => {
|
||||
<View className="flex flex-col items-start justify-start w-full">
|
||||
<InputField
|
||||
label="First name"
|
||||
placeholder={user?.firstName || "Not Found"}
|
||||
placeholder={user?.firstName ?? "Your First name"}
|
||||
containerStyles="w-full mb-4"
|
||||
inputStyles="p-3.5"
|
||||
editable={false}
|
||||
@@ -38,7 +38,7 @@ const Profile = () => {
|
||||
|
||||
<InputField
|
||||
label="Last name"
|
||||
placeholder={user?.lastName || "Not Found"}
|
||||
placeholder={user?.lastName ?? "Your Last name"}
|
||||
containerStyles="w-full mb-4"
|
||||
inputStyles="p-3.5"
|
||||
editable={false}
|
||||
@@ -47,7 +47,7 @@ const Profile = () => {
|
||||
<InputField
|
||||
label="Email"
|
||||
placeholder={
|
||||
user?.primaryEmailAddress?.emailAddress || "Not Found"
|
||||
user?.primaryEmailAddress?.emailAddress ?? "Your Email address"
|
||||
}
|
||||
containerStyles="w-full mb-4"
|
||||
inputStyles="p-3.5"
|
||||
|
||||
Reference in New Issue
Block a user