Skip to content

Commit

Permalink
Replace hard-coded navbar with component
Browse files Browse the repository at this point in the history
  • Loading branch information
justshye committed May 17, 2024
1 parent d3a39d3 commit 3fe8a71
Showing 1 changed file with 2 additions and 42 deletions.
44 changes: 2 additions & 42 deletions src/app/page.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import Link from 'next/link';
import React from 'react';
import { useUser } from '@auth0/nextjs-auth0/client';
import { redirect } from 'next/navigation';
import Navbar from '@/components/ui/navbar';

export default function Component() {
const { user, error } = useUser();
Expand All @@ -29,29 +30,7 @@ export default function Component() {

return (
<div className="flex flex-col min-h-[100dvh]">
<header className="px-4 lg:px-6 h-14 flex items-center">
<Link className="flex items-center justify-center" href="#">
<BriefcaseIcon className="h-6 w-6" />
<span className="sr-only">Job Posting Site</span>
</Link>
<nav className="ml-auto flex gap-4 sm:gap-6">
<Link
className="text-sm font-medium hover:underline underline-offset-4"
href="#">
Pricing
</Link>
<Link
className="text-sm font-medium hover:underline underline-offset-4"
href="#">
About
</Link>
<Link
className="text-sm font-medium hover:underline underline-offset-4"
href="#">
Contact
</Link>
</nav>
</header>
<Navbar />
<main className="flex-1">
<section className="w-full py-12 md:py-24 lg:py-32 border-y">
<div className="container px-4 md:px-6 space-y-10 xl:space-y-16">
Expand Down Expand Up @@ -165,22 +144,3 @@ export default function Component() {
</div>
);
}

function BriefcaseIcon(props) {
return (
<svg
{...props}
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth="2"
strokeLinecap="round"
strokeLinejoin="round">
<path d="M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16" />
<rect width="20" height="14" x="2" y="6" rx="2" />
</svg>
);
}

0 comments on commit 3fe8a71

Please sign in to comment.