generated from nhcarrigan/template
chore: use our configs, update dependencies (#34)
### Explanation This gets us in line with our other project standards, and allows us to start testing! ### Issue Closes #18 ### Attestations - [x] I have read and agree to the [Code of Conduct](https://docs.nhcarrigan.com/community/coc/) - [x] I have read and agree to the [Community Guidelines](https://docs.nhcarrigan.com/community/guide/). - [x] My contribution complies with the [Contributor Covenant](https://docs.nhcarrigan.com/dev/covenant/). ### Dependencies - [x] I have pinned the dependencies to a specific patch version. ### Style - [x] I have run the linter and resolved any errors. - [x] My pull request uses an appropriate title, matching the conventional commit standards. - [x] My scope of feat/fix/chore/etc. correctly matches the nature of changes in my pull request. ### Tests - [ ] My contribution adds new code, and I have added tests to cover it. - [ ] My contribution modifies existing code, and I have updated the tests to reflect these changes. - [ ] All new and existing tests pass locally with my changes. - [ ] Code coverage remains at or above the configured threshold. ### Documentation _No response_ ### Versioning Major - My pull request introduces a breaking change. Reviewed-on: https://codeberg.org/nhcarrigan/portfolio/pulls/34 Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com> Co-committed-by: Naomi Carrigan <commits@nhcarrigan.com>
This commit is contained in:
+49
-36
@@ -1,55 +1,68 @@
|
||||
"use client";
|
||||
import { NavItems } from "@/config/NavItems";
|
||||
/**
|
||||
* @copyright nhcarrigan
|
||||
* @license Naomi's Public License
|
||||
* @author Naomi Carrigan
|
||||
*/
|
||||
import Image from "next/image";
|
||||
import React, { useEffect, useState } from "react";
|
||||
import React, { type JSX } from "react";
|
||||
import { NavItems } from "../config/NavItems";
|
||||
|
||||
export default function Home() {
|
||||
const [isDarkMode, setIsDarkMode] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
const savedTheme = localStorage.getItem("theme");
|
||||
const prefersDark = window.matchMedia(
|
||||
"(prefers-color-scheme: dark)",
|
||||
).matches;
|
||||
const isDark = savedTheme === "dark" || (!savedTheme && prefersDark);
|
||||
document.documentElement.classList.toggle("dark", isDark);
|
||||
setIsDarkMode(isDark);
|
||||
}, []);
|
||||
/**
|
||||
* Renders the main React component.
|
||||
* @returns A JSX element.
|
||||
*/
|
||||
const Home = (): JSX.Element => {
|
||||
return (
|
||||
<div>
|
||||
<div className="absolute top-0 right-[33vw] z-100 w-[100vh] h-[100vh] rotate-90 hidden lg:block">
|
||||
<svg viewBox="0 0 500 500" className="absolute">
|
||||
<div
|
||||
className="absolute top-0 right-[33vw] z-100
|
||||
w-[100vh] h-[100vh] rotate-90 hidden lg:block"
|
||||
>
|
||||
<svg className="absolute" viewBox="0 0 500 500">
|
||||
<path
|
||||
d="M0,100 C150,200 350,0 500,100 L500,00 L0,0 Z"
|
||||
style={{ stroke: "none", fill: "var(--foreground)" }}
|
||||
style={{ fill: "var(--foreground)", stroke: "none" }}
|
||||
></path>
|
||||
</svg>
|
||||
</div>
|
||||
<main className="grid grid-cols-[2fr,1fr] min-h-screen">
|
||||
<section className="bg-[--background] text-[--foreground] flex flex-col items-left justify-center text-left pl-5">
|
||||
<h1 className="text-4xl mb-2">Naomi Carrigan</h1>
|
||||
<section
|
||||
className="bg-[--background] text-[--foreground]
|
||||
flex flex-col items-left justify-center text-left pl-5"
|
||||
>
|
||||
<h1 className="text-4xl mb-2">{`Naomi Carrigan`}</h1>
|
||||
<Image
|
||||
src="https://cdn.nhcarrigan.com/profile.png"
|
||||
alt="Naomi Carrigan"
|
||||
width={200}
|
||||
height={200}
|
||||
className="rounded-full"
|
||||
height={200}
|
||||
src="https://cdn.nhcarrigan.com/profile.png"
|
||||
width={200}
|
||||
/>
|
||||
<p className="text-3xl">Software Engineer</p>
|
||||
<p className="text-3xl">Community Manager</p>
|
||||
<p className="text-3xl">{`Software Engineer`}</p>
|
||||
<p className="text-3xl">{`Community Manager`}</p>
|
||||
</section>
|
||||
<section className="bg-[--foreground] text-[--background] flex flex-col items-center justify-center">
|
||||
{NavItems.map((item, index) => (
|
||||
<a
|
||||
key={item.href}
|
||||
href={item.href}
|
||||
className="block py-2 px-4 text-2xl hover:bg-[--background] hover:text-[--foreground]"
|
||||
>
|
||||
{index % 2 ? "🩷" : "🩵"} {item.text}
|
||||
</a>
|
||||
))}
|
||||
<section
|
||||
className="bg-[--foreground] text-[--background]
|
||||
flex flex-col items-center justify-center"
|
||||
>
|
||||
{NavItems.map((item, index) => {
|
||||
return (
|
||||
<a
|
||||
className="block py-2 px-4 text-2xl
|
||||
hover:bg-[--background] hover:text-[--foreground]"
|
||||
href={item.href}
|
||||
key={item.href}
|
||||
>
|
||||
{index % 2 === 1
|
||||
? "🩷"
|
||||
: "🩵"} {item.text}
|
||||
</a>
|
||||
);
|
||||
})}
|
||||
</section>
|
||||
</main>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
export default Home;
|
||||
|
||||
Reference in New Issue
Block a user