From 99131c7c4b9a7a006adad3b34ad2229b303ce4e1 Mon Sep 17 00:00:00 2001 From: sajadevo Date: Tue, 28 Jan 2025 05:25:37 +0500 Subject: [PATCH] update the pages --- app/about/page.tsx | 2 +- app/components/contact.tsx | 170 --------------------------- app/components/experience.tsx | 58 --------- app/components/hero.tsx | 78 ------------ app/components/index.ts | 7 -- app/components/projects-carousel.tsx | 85 -------------- app/components/recommendations.tsx | 35 ------ app/components/services.tsx | 63 ---------- app/components/story.tsx | 26 ---- app/page.tsx | 2 +- app/projects/page.tsx | 2 +- 11 files changed, 3 insertions(+), 525 deletions(-) delete mode 100644 app/components/contact.tsx delete mode 100644 app/components/experience.tsx delete mode 100644 app/components/hero.tsx delete mode 100644 app/components/index.ts delete mode 100644 app/components/projects-carousel.tsx delete mode 100644 app/components/recommendations.tsx delete mode 100644 app/components/services.tsx delete mode 100644 app/components/story.tsx diff --git a/app/about/page.tsx b/app/about/page.tsx index 5f08c64..138fcc0 100644 --- a/app/about/page.tsx +++ b/app/about/page.tsx @@ -36,7 +36,7 @@ export default function About() {

Bio

-

+

Hey I'm Sajad, a self-taught frontend engineer and passionate creator of intuitive web experiences, crafting stunning web experiences and intuitive designs for over seven years, I'm all diff --git a/app/components/contact.tsx b/app/components/contact.tsx deleted file mode 100644 index ff73486..0000000 --- a/app/components/contact.tsx +++ /dev/null @@ -1,170 +0,0 @@ -"use client"; - -import React from "react"; - -// @components -import { Input, Textarea, Button } from "@/components"; - -// @hooks -import { useForm } from "react-hook-form"; - -// @utils -import { z } from "zod"; -import { cn } from "@/lib/utils"; -import { zodResolver } from "@hookform/resolvers/zod"; - -// @actions -import { sendInquiry } from "@/lib/actions"; - -const formSchema = z.object({ - name: z.string().min(3, { - message: "Name must be at least 3 characters long", - }), - email: z.string().email({ - message: "Invalid email address", - }), - message: z.string().min(26, { - message: "Message must be at least 26 characters long", - }), -}); - -export function Contact() { - const [isLoading, setIsLoading] = React.useState(false); - const [isSuccess, setIsSuccess] = React.useState(false); - const [error, setError] = React.useState(null); - - const { - reset, - handleSubmit, - register, - formState: { errors }, - } = useForm>({ - resolver: zodResolver(formSchema), - defaultValues: { - name: "", - email: "", - message: "", - }, - }); - - async function onSubmit(values: z.infer) { - setIsLoading(true); - - const response = await sendInquiry(values); - - if (response.sent) { - reset(); - setError(null); - setIsSuccess(true); - setIsLoading(false); - - setTimeout(() => { - setIsSuccess(false); - }, 3000); - } else { - setIsLoading(false); - setIsSuccess(false); - setError("Could not send message. Please try again later."); - } - } - - return ( -

-
-

- Let's Connect -

-
-
-
- - {errors.name?.message && ( -

- {errors.name?.message} -

- )} -
-
- - {errors.email?.message && ( -

- {errors.email?.message} -

- )} -
-
-
-