Skip to content

Commit f8c9e3f

Browse files
committed
refactor(ui): simplify mobile header layout and update hero control styles
1 parent c0992b4 commit f8c9e3f

File tree

2 files changed

+17
-26
lines changed

2 files changed

+17
-26
lines changed

src/components/sections/header.tsx

Lines changed: 15 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,7 @@ export function Header() {
102102
>
103103
<div className="sticky top-0 z-[var(--z-header)]">
104104
<header className="border-border/40 bg-background/80 supports-[backdrop-filter]:bg-background/60 w-full border-b backdrop-blur">
105-
<div
106-
className={`container flex h-[var(--header-height)] max-w-full items-center justify-between px-4 lg:px-6`}
107-
>
105+
<div className="container flex h-[var(--header-height)] max-w-full items-center justify-between px-4 lg:px-6">
108106
<div className="flex items-center gap-6">
109107
<SmartLink
110108
href="/"
@@ -178,34 +176,27 @@ export function Header() {
178176
</header>
179177
<AnimatePresence>
180178
{isOpen && (
181-
<CollapsibleContent
182-
asChild
183-
forceMount
184-
>
179+
<CollapsibleContent asChild>
185180
<motion.div
186181
initial={{ opacity: 0, height: 0 }}
187182
animate={{ opacity: 1, height: "auto" }}
188183
exit={{ opacity: 0, height: 0 }}
189184
transition={{ duration: 0.3, ease: "easeInOut" }}
190185
className="absolute right-0 left-0 overflow-hidden"
191186
>
192-
<div className="bg-background/95 supports-[backdrop-filter]:bg-background/80 border-t border-b backdrop-blur">
193-
<div className="container px-4 py-4 lg:px-6">
194-
<nav className="grid gap-4 text-sm">
195-
{siteConfig.mainNav.map((link) => (
196-
<div
197-
key={link.href}
198-
className="grid gap-4"
199-
>
200-
<MobileMenuGroup
201-
link={link}
202-
onLinkClick={handleCloseMenu}
203-
/>
204-
</div>
205-
))}
206-
</nav>
207-
</div>
208-
</div>
187+
<nav className="px-4 py-4 lg:px-6 bg-background/95 supports-[backdrop-filter]:bg-background/80 border-b border-b-border/40 backdrop-blur grid gap-4 text-sm">
188+
{siteConfig.mainNav.map((link) => (
189+
<div
190+
key={link.href}
191+
className="grid gap-4"
192+
>
193+
<MobileMenuGroup
194+
link={link}
195+
onLinkClick={handleCloseMenu}
196+
/>
197+
</div>
198+
))}
199+
</nav>
209200
</motion.div>
210201
</CollapsibleContent>
211202
)}

src/components/sections/hero.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ export function Hero({ slides, heightClassName }: HeroProps) {
6565
</CarouselContent>
6666
{hasMultipleSlides ? (
6767
<>
68-
<CarouselPrevious className="text-white bg-transparent border-input/30" />
69-
<CarouselNext className="text-white bg-transparent border-input/30" />
68+
<CarouselPrevious className="text-white bg-transparent border-primary/35" />
69+
<CarouselNext className="text-white bg-transparent border-primary/35" />
7070
</>
7171
) : null}
7272
</Carousel>

0 commit comments

Comments
 (0)