layout fix quick search

This commit is contained in:
Oliver Kieselbach
2026-03-27 22:06:11 +01:00
parent f2acfc06f1
commit f016620a29
4 changed files with 12 additions and 12 deletions
@@ -1 +1 @@
633
635
@@ -212,9 +212,9 @@ export default function GlobalSearch() {
};
return (
<>
{/* Desktop: inline search field (visible md+) */}
<div ref={containerRef} className="hidden md:flex relative flex-1 max-w-md mr-1">
<div className="flex-1 flex items-center">
{/* Desktop: inline search field centered (visible md+) */}
<div ref={containerRef} className="hidden md:flex relative w-full max-w-md mx-auto">
<div className="relative w-full">
<div className="absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none">
<SearchIcon />
@@ -233,10 +233,10 @@ export default function GlobalSearch() {
<ResultsDropdown />
</div>
{/* Mobile: magnifying glass button (visible <md) */}
{/* Mobile: magnifying glass button pushed right (visible <md) */}
<button
onClick={() => setMobileOpen(true)}
className="md:hidden p-2 rounded-lg hover:bg-gray-100 transition-colors"
className="md:hidden ml-auto p-2 rounded-lg hover:bg-gray-100 transition-colors"
title="Search"
>
<svg className="w-5 h-5 text-gray-600" fill="none" viewBox="0 0 24 24" stroke="currentColor" strokeWidth={2}>
@@ -277,6 +277,6 @@ export default function GlobalSearch() {
<ResultsDropdown mobile />
</div>
)}
</>
</div>
);
}
@@ -229,11 +229,11 @@ export default function Navbar() {
</Link>
</div>
{/* Right side — Search + Dark Mode, Notifications, Settings, Overflow, User */}
<div className="flex items-center justify-end flex-1 space-x-1">
{/* Global Search */}
<GlobalSearch />
{/* Global Search — centered on desktop, lupe pushed right on mobile */}
<GlobalSearch />
{/* Right side — Dark Mode, Notifications, Settings, Overflow, User */}
<div className="flex items-center space-x-1">
{/* Dark Mode Toggle — hidden on <sm, moved to overflow */}
<button
onClick={toggleTheme}
File diff suppressed because one or more lines are too long