update
This commit is contained in:
38
app/components/Contact.tsx
Normal file
38
app/components/Contact.tsx
Normal file
@@ -0,0 +1,38 @@
|
||||
// app/components/Contact.tsx
|
||||
"use client";
|
||||
|
||||
export default function Contact() {
|
||||
return (
|
||||
<section id="contact" className="p-10 bg-gray-100 dark:bg-gray-800">
|
||||
<h2 className="text-3xl font-bold text-center text-gray-800 dark:text-white">
|
||||
Contact Me
|
||||
</h2>
|
||||
<form className="mt-6 max-w-md mx-auto space-y-4">
|
||||
<input
|
||||
type="text"
|
||||
placeholder="Name"
|
||||
className="w-full p-2 border rounded dark:bg-gray-700 dark:border-gray-600 dark:text-white"
|
||||
required
|
||||
/>
|
||||
<input
|
||||
type="email"
|
||||
placeholder="Email"
|
||||
className="w-full p-2 border rounded dark:bg-gray-700 dark:border-gray-600 dark:text-white"
|
||||
required
|
||||
/>
|
||||
<textarea
|
||||
placeholder="Message"
|
||||
className="w-full p-2 border rounded dark:bg-gray-700 dark:border-gray-600 dark:text-white"
|
||||
rows={5}
|
||||
required
|
||||
></textarea>
|
||||
<button
|
||||
type="submit"
|
||||
className="w-full p-2 bg-blue-500 text-white rounded hover:bg-blue-600 dark:bg-blue-700 dark:hover:bg-blue-800"
|
||||
>
|
||||
Send
|
||||
</button>
|
||||
</form>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
18
app/components/Footer.tsx
Normal file
18
app/components/Footer.tsx
Normal file
@@ -0,0 +1,18 @@
|
||||
// app/components/Footer.tsx
|
||||
|
||||
import Link from "next/link";
|
||||
|
||||
export default function Footer() {
|
||||
return (
|
||||
<footer className="text-center p-10 bg-gray-800 text-white">
|
||||
<h1 className="text-5xl font-bold">Hi, this is a Footer</h1>
|
||||
<p className="mt-4 text-xl">Maybe some social links here</p>
|
||||
<p>© Dennis Konkol 2024</p>
|
||||
<Link href="#hero">
|
||||
<button className="mt-6 inline-block px-6 py-2 bg-black text-white rounded hover:bg-gray-800 dark:bg-white dark:text-black dark:hover:bg-gray-300">
|
||||
Back to Top
|
||||
</button>
|
||||
</Link>
|
||||
</footer>
|
||||
);
|
||||
}
|
||||
32
app/components/Header.tsx
Normal file
32
app/components/Header.tsx
Normal file
@@ -0,0 +1,32 @@
|
||||
// app/components/Header.tsx
|
||||
"use client";
|
||||
|
||||
import Link from "next/link";
|
||||
|
||||
export default function Header() {
|
||||
return (
|
||||
<header className="p-5 bg-gray-800 text-white">
|
||||
<nav className="flex justify-between items-center">
|
||||
<h1 className="text-lg font-bold">My Portfolio</h1>
|
||||
<ul className="flex space-x-4 items-center">
|
||||
<li>
|
||||
<Link href="#about" className="hover:underline">
|
||||
About
|
||||
</Link>
|
||||
</li>
|
||||
<li>
|
||||
<Link href="#projects" className="hover:underline">
|
||||
Projects
|
||||
</Link>
|
||||
</li>
|
||||
<li>
|
||||
<Link href="#contact" className="hover:underline">
|
||||
Contact
|
||||
</Link>
|
||||
</li>
|
||||
{/* DarkModeToggle removed */}
|
||||
</ul>
|
||||
</nav>
|
||||
</header>
|
||||
);
|
||||
}
|
||||
20
app/components/Hero.tsx
Normal file
20
app/components/Hero.tsx
Normal file
@@ -0,0 +1,20 @@
|
||||
// app/components/Hero.tsx
|
||||
|
||||
import Link from "next/link";
|
||||
|
||||
export default function Hero() {
|
||||
return (
|
||||
<section
|
||||
id="hero"
|
||||
className="text-center p-20 bg-gradient-to-r from-purple-400 to-blue-500 dark:from-gray-800 dark:to-gray-900 text-white"
|
||||
>
|
||||
<h1 className="text-5xl font-bold">Hi, I am Dennis</h1>
|
||||
<p className="mt-4 text-xl">A student</p>
|
||||
<Link href="#projects">
|
||||
<button className="mt-6 inline-block px-6 py-2 bg-black text-white rounded hover:bg-gray-800 dark:bg-white dark:text-black dark:hover:bg-gray-300">
|
||||
See My Work
|
||||
</button>
|
||||
</Link>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
51
app/components/Projects.tsx
Normal file
51
app/components/Projects.tsx
Normal file
@@ -0,0 +1,51 @@
|
||||
// app/components/Projects.tsx
|
||||
"use client";
|
||||
|
||||
import Link from "next/link";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
interface Project {
|
||||
id: string;
|
||||
title: string;
|
||||
description: string;
|
||||
link: string;
|
||||
}
|
||||
|
||||
export default function Projects() {
|
||||
const [projects, setProjects] = useState<Project[]>([]);
|
||||
|
||||
useEffect(() => {
|
||||
fetch("/data/projects.json")
|
||||
.then((res) => res.json())
|
||||
.then((data) => setProjects(data));
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<section id="projects" className="p-10 bg-gray-100 dark:bg-gray-800">
|
||||
<h2 className="text-3xl font-bold text-center text-gray-800 dark:text-white">
|
||||
Projects
|
||||
</h2>
|
||||
<div className="mt-6 grid grid-cols-1 md:grid-cols-2 gap-6">
|
||||
{projects.map((project) => (
|
||||
<div
|
||||
key={project.id}
|
||||
className="p-4 border rounded shadow-lg bg-white dark:bg-gray-700"
|
||||
>
|
||||
<h3 className="text-2xl font-bold text-gray-800 dark:text-white">
|
||||
{project.title}
|
||||
</h3>
|
||||
<p className="mt-2 text-gray-600 dark:text-gray-300">
|
||||
{project.description}
|
||||
</p>
|
||||
<Link
|
||||
href={`/Projects/${project.id}`}
|
||||
className="mt-4 inline-block text-blue-500 hover:underline"
|
||||
>
|
||||
View Project
|
||||
</Link>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user