import { useState, type ReactElement } from "react"; import MdProcessor from "../components/MdProcessor"; import CurrentActivity from "../components/CurrentActivity"; import About from "../components/About"; interface ProjectInfo { id: string; name: string; url: string; } interface Section { id: string; title: string; content: ReactElement; } export default function Home(): ReactElement { const projectList: ProjectInfo[] = [ { id: "site", name: "aramjonghu-site", url: "https://git.aramjonghu.dev/AramJonghu/aramjonghu-site/raw/branch/master/README.md", }, { id: "maran freelance portfolio", name: "maran-site", url: "https://git.aramjonghu.dev/AramJonghu/maran-site/src/branch/main/README.md", }, { id: "file-organizer", name: "file-organizer written in zig", url: "https://git.aramjonghu.dev/AramJonghu/file-organizer/src/branch/main/README.md", }, { id: "nvim", name: "Nvim Config", url: "https://git.aramjonghu.dev/AramJonghu/nvim/src/branch/main/README.md", }, ]; const [projIdx, setProjIdx] = useState(0); const prevProject = () => setProjIdx((i) => (i - 1 + projectList.length) % projectList.length); const nextProject = () => setProjIdx((i) => (i + 1) % projectList.length); const [activeTab, setActiveTab] = useState("projects"); const sections: Section[] = [ { id: "projects", title: "Projects", content: ( <>

Projects

{projectList[projIdx].name} ({projIdx + 1}/ {projectList.length})
), }, { id: "current-activity", title: "Current-activity", content: ( <> ), }, { id: "about", title: "About", content: ( <> ), }, ]; return (

AramJonghu

{sections.map((section) => ( ))}
{sections.map((section) => (
{section.content}
))}
); }