add links page back, update header

This commit is contained in:
2025-02-10 13:58:15 -05:00
parent 7bba0d5ea2
commit 42d85db5e5
7 changed files with 133 additions and 61 deletions
+24
View File
@@ -0,0 +1,24 @@
import React from "react"
import Link from "next/link"
export default function CustomButton({
to,
label
}: {
to: string,
label: string
}) {
return (
<div>
<Link href={to} target="_blank">
<div className={`bg-black text-white text-lg font-semibold text-left p-2 w-52 rounded-lg`}>
<div className="px-1 space-x-2">
<div className="inline">
{label}
</div>
</div>
</div>
</Link>
</div>
)
}
+22 -21
View File
@@ -1,27 +1,28 @@
"use client"
import { useState, useEffect } from 'react';
import Link from "next/link"
const quoteArray = [
"It works on my machine",
"Revert 'Revert 'Revert",
"'fuck the tests'",
"this is so cooked",
"Professional Production Tester",
"I break hearts to save lives.",
"go bills",
"josh allen is my goat",
"lets go buffalo",
"oorah",
"how bout them bills??",
"where else would you rather be..",
"..than right here, right now?!"
]
export default function Header() {
const quoteArray = [
"It works on my machine",
"Revert 'Revert 'Revert",
"'fuck the tests'",
"this is so cooked",
"Professional Production Tester",
"I break hearts to save lives.",
"go bills",
"josh allen is my goat",
"lets go buffalo",
"oorah",
"how bout them bills??",
"where else would you rather be..",
"..than right here, right now?!"
]
const [ quote, setQuote ] = useState<string>(quoteArray[0])
async function getQuote(index: number) {
return quoteArray[index]
}
export default async function Header() {
const quote = await getQuote(Math.floor(Math.random() * quoteArray.length))
useEffect(() => {
setQuote(quoteArray[Math.floor(Math.random() * quoteArray.length)]);
}, [])
return (
<div className="bg-zinc-900 p-4 flex justify-between">