feat: nav v2

This commit is contained in:
VizoleLabs 2024-04-09 11:48:38 +00:00
parent f7311438a3
commit 35d7129f85
4 changed files with 14 additions and 9 deletions

View file

@ -8,7 +8,7 @@ export default function RootLayout({ children }: { children: React.ReactNode })
return ( return (
<html lang="en"> <html lang="en">
<body className="bg-[#0f172a] "> <body className="bg-[#0f172a] ">
<Navbar logoSrc="/images/image-removebg-preview (1).png" /> <Navbar logoSrc="/images/logo.webp" />
{children} {children}
<Footer /> <Footer />
</body> </body>

View file

@ -1,12 +1,12 @@
"use client" "use client"
interface NavbarProps {
logoSrc: string // Path to your logo image
}
import { useState, useEffect } from "react" import { useState, useEffect } from "react"
import { Button } from "components/Button/Button" import { Button } from "components/Button/Button"
import { FaArrowRight } from "react-icons/fa" import { FaArrowRight } from "react-icons/fa"
interface NavbarProps {
logoSrc: string // Path to your logo image
}
const Navbar: React.FC<NavbarProps> = ({ logoSrc }) => { const Navbar: React.FC<NavbarProps> = ({ logoSrc }) => {
const [showBackground, setShowBackground] = useState(false) const [showBackground, setShowBackground] = useState(false)
const TOP_OFFSET = 50 const TOP_OFFSET = 50
@ -36,13 +36,18 @@ const Navbar: React.FC<NavbarProps> = ({ logoSrc }) => {
return ( return (
<nav <nav
className={`${ className={`${
showBackground ? "backdrop-blur" : "bg-transparent" showBackground ? "backdrop-blur-2xl" : "bg-transparent"
} fixed left-0 top-0 z-50 flex h-20 w-full items-center justify-between px-4 text-white`} } fixed left-0 top-0 z-50 flex h-20 w-full items-center justify-between px-4 px-[8.5rem] py-[1rem] text-white transition-all`}
> >
<a href="/"> <a href="/">
<img src={logoSrc} alt="Your Logo" className="h-20 text-white" /> <img
src={logoSrc}
alt="Vizole Labs"
className="h-8
text-white"
/>
</a> </a>
<ul className="hidden space-x-4 text-lg font-medium md:flex"> <ul className="text-md font-ligth hidden space-x-4 md:flex">
<li> <li>
<a href="/" className="hover:text-vizoleG2"> <a href="/" className="hover:text-vizoleG2">
Home Home

BIN
public/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 129 KiB

BIN
public/images/logo.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB