Header Component
A simple, responsive header component for social media, with dark mode support. It features a logo, a search bar, and user avatar. Uses a grayscale color scheme.
HTML Code
<header class="bg-white dark:bg-gray-900 p-4 shadow-md">
<div class="container mx-auto flex justify-between items-center">
<!-- Logo or Site Title -->
<a href="#" class="text-2xl font-bold text-gray-900 dark:text-white">SocialSite</a>
<!-- Search Bar -->
<div class="flex-grow mx-4 max-w-xl">
<input type="text" placeholder="Search..." class="w-full p-2 rounded-lg bg-gray-200 dark:bg-gray-700 text-gray-900 dark:text-white placeholder-gray-500 dark:placeholder-gray-400 focus:outline-none focus:ring-2 focus:ring-gray-300 dark:focus:ring-gray-600">
</div>
<!-- User Avatar/Menu -->
<div class="flex items-center space-x-4">
<img src="https://randomuser.me/api/portraits/men/32.jpg" alt="User Avatar" class="w-10 h-10 rounded-full border-2 border-gray-300 dark:border-gray-600">
</div>
</div>
</header>
Related Components
Header Component
A simple Header Component designed using Neumorphism style with vibrant colors, perfect for a blog/content webpage. It features dark mode support for responsive design.
Complex Dashboard Header
A complex, responsive header component with 3D design elements, earth tone color scheme, designed for dashboards. Includes dark theme support using Tailwind CSS and uses picsum.photos and randomuser.me for demo images/avatars.
Header Component
A minimalist, flat design header component for a portfolio, featuring a responsive design with dark theme support and multiple interactive elements.