-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
255 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import React from "react"; | ||
import Nav from "../Nav"; | ||
import { Link } from "react-router-dom"; | ||
|
||
export const PageNotFound = () => { | ||
console.log("404"); | ||
|
||
return ( | ||
<> | ||
<Nav dark={true} bgColor={"#f8f8f8"} /> | ||
|
||
<div className="flex h-[70vh] w-full flex-col items-center justify-center gap-2 text-black"> | ||
<div className="w-[220px] md:w-[350px]"> | ||
<img | ||
src="https://res.cloudinary.com/dd39ktpmz/image/upload/v1691859844/ck/client_static/clds5fclmmr04posyf4h.webp" | ||
alt="Restaurant nor found image" | ||
width={"100%"} | ||
height={"100%"} | ||
loading={"lazy"} | ||
/> | ||
</div> | ||
<h1 className="text-3xl font-bold capitalize text-primary"> | ||
404 Page not found | ||
</h1> | ||
<Link | ||
to={"/"} | ||
className="w-full text-center text-lg font-bold text-blue-400 underline" | ||
> | ||
Go To Home | ||
</Link> | ||
</div> | ||
</> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
import React, { useEffect, useState } from "react"; | ||
import Nav from "../Nav"; | ||
import Container from "../Container"; | ||
import { useNavigate, useParams } from "react-router-dom"; | ||
import { useAppDispatch } from "../../hooks"; | ||
import { verifiyUser } from "../../state/slices/user.slice"; | ||
import toast from "react-hot-toast"; | ||
|
||
export const Verified = () => { | ||
const { email } = useParams(); | ||
const dispatch = useAppDispatch(); | ||
const navigate = useNavigate(); | ||
|
||
const [message, setMessage] = useState("Verification in progress"); | ||
|
||
useEffect(() => { | ||
if (email) { | ||
const promiseData = dispatch(verifiyUser(email)); | ||
toast.promise( | ||
promiseData, | ||
{ | ||
loading: "Verification in progress", | ||
success: (data: any) => { | ||
if (data.payload?.email) { | ||
navigate("/"); | ||
setMessage("successfully verified"); | ||
return `Successfully Verified`; | ||
} | ||
|
||
throw data.payload?.message || "Something went wrong"; | ||
}, | ||
error: (err) => { | ||
setMessage(err); | ||
return `${err}`; | ||
}, | ||
}, | ||
{ | ||
success: { | ||
duration: 2000, | ||
}, | ||
error: { | ||
duration: 1500, | ||
}, | ||
}, | ||
); | ||
} | ||
}, []); | ||
|
||
return ( | ||
<> | ||
<Nav dark={true} bgColor={"#f8f8f8"} /> | ||
<Container> | ||
<div className="flex min-h-[70vh] items-center justify-center"> | ||
<h3 className="font-head text-xl font-bold capitalize">{message}</h3> | ||
</div> | ||
</Container> | ||
</> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
9355fda
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
ck-cloud-kitchen – ./client
ck-cloud-kitchen.vercel.app
ck-cloud-kitchen-vimal-oneway.vercel.app
ck.vimaldev.in
ck-cloud-kitchen-git-main-vimal-oneway.vercel.app