49 lines
1.8 KiB
TypeScript
49 lines
1.8 KiB
TypeScript
import React from 'react';
|
|
import { Link, useLocation } from 'react-router-dom';
|
|
|
|
const Navbar: React.FC = () => {
|
|
const location = useLocation();
|
|
const isHome = location.pathname === '/';
|
|
|
|
return (
|
|
<nav
|
|
className="fixed w-full z-40 top-0 left-0 border-b border-gray-200 dark:border-white/10 bg-white/80 dark:bg-background-dark/80 backdrop-blur-md"
|
|
>
|
|
<div className="max-w-7xl mx-auto px-6 h-16 flex items-center justify-between">
|
|
<Link to="/" className="flex items-center gap-2">
|
|
<img
|
|
src="/logo.svg"
|
|
alt="Bay Area IT logo"
|
|
className="h-8 w-8"
|
|
/>
|
|
<span className="font-display font-bold text-lg tracking-tight">Bay Area IT</span>
|
|
</Link>
|
|
|
|
<div className="hidden md:flex items-center gap-8 text-sm font-medium text-gray-600 dark:text-gray-400">
|
|
{['About', 'Services', 'Blog', 'Contact'].map((item) => (
|
|
<Link
|
|
key={item}
|
|
to={`/${item.toLowerCase()}`}
|
|
className="hover:text-black dark:hover:text-white transition-colors relative group px-2 py-1"
|
|
>
|
|
<span className="inline-block">
|
|
{item}
|
|
</span>
|
|
<span className="absolute -bottom-1 left-0 w-0 h-0.5 bg-black dark:bg-white transition-all duration-300 ease-out group-hover:w-full"></span>
|
|
</Link>
|
|
))}
|
|
</div>
|
|
|
|
<Link
|
|
to="/contact"
|
|
className="hidden md:inline-flex items-center px-4 py-1.5 bg-black dark:bg-white text-white dark:text-black rounded-full text-sm font-medium hover:bg-gray-800 dark:hover:bg-gray-100 transition-colors"
|
|
>
|
|
Get IT Support
|
|
</Link>
|
|
</div>
|
|
</nav>
|
|
);
|
|
};
|
|
|
|
export default Navbar;
|