This commit is contained in:
Your Name committed 2026-06-10 05:27:39 +07:00
1 parent a5f6e3171b
commit f39a0c83dd
9 files changed
+86 -17

No files matched your search

+3 -2
View File
@@ -10,9 +10,10 @@ import { useTranslation } from 'react-i18next'
interface NavbarProps {
categories?: Category[]
topOffsetClassName?: string
}
export default function Navbar({ categories = [] }: NavbarProps) {
export default function Navbar({ categories = [], topOffsetClassName = 'top-0' }: NavbarProps) {
const [searchOpen, setSearchOpen] = useState(false)
const [mobileOpen, setMobileOpen] = useState(false)
const [searchQuery, setSearchQuery] = useState('')
@@ -71,7 +72,7 @@ export default function Navbar({ categories = [] }: NavbarProps) {
<>
{/* ── NAVBAR BAR ── */}
<nav
className={`fixed top-0 w-full z-50 transition-all duration-300 px-4 md:px-6 py-3.5 md:py-4 flex justify-between items-center bg-white/80 backdrop-blur-xl border-b border-black/5 ${
className={`fixed ${topOffsetClassName} w-full z-50 transition-all duration-300 px-4 md:px-6 py-3.5 md:py-4 flex justify-between items-center bg-white/80 backdrop-blur-xl border-b border-black/5 ${
scrolled ? 'shadow-lg shadow-black/5' : 'shadow-none'
}`}
>