Navigation 구성 요소
다크 모드 UI용으로 설계된 반응형 탐색 구성 요소로, 링크, 드롭다운 및 로고가 특징이며, 모두 Tailwind CSS로 스타일이 지정되었습니다.
HTML 코드
<nav class="bg-gray-800 p-4 fixed w-full">
<div class="flex justify-between items-center">
<div class="text-white text-lg font-bold">
<a href="#" class="flex items-center">
<img src="https://picsum.photos/40" alt="Logo" class="mr-2 rounded-full">
MyApp
</a>
</div>
<div class="hidden md:flex space-x-4">
<a href="#" class="text-gray-300 hover:bg-gray-700 px-3 py-2 rounded">Home</a>
<a href="#" class="text-gray-300 hover:bg-gray-700 px-3 py-2 rounded">About</a>
<div class="relative">
<button class="text-gray-300 hover:bg-gray-700 px-3 py-2 rounded flex items-center">Services
<svg class="w-4 h-4 ml-1" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 15l7-7 7 7"/>
</svg>
</button>
<div class="absolute left-0 hidden bg-gray-800 text-white mt-1 rounded shadow-md w-40">
<a href="#" class="block px-4 py-2 hover:bg-gray-700">Web Design</a>
<a href="#" class="block px-4 py-2 hover:bg-gray-700">SEO</a>
<a href="#" class="block px-4 py-2 hover:bg-gray-700">Marketing</a>
</div>
</div>
<a href="#" class="text-gray-300 hover:bg-gray-700 px-3 py-2 rounded">Contact</a>
</div>
<div class="md:hidden">
<button class="text-gray-300 hover:bg-gray-700 px-3 py-2 rounded focus:outline-none">
<svg class="w-6 h-6" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 6h16M4 12h16m-7 6h7"/>
</svg>
</button>
</div>
</div>
</nav>
<div class="mt-16 p-4">
<h1 class="text-3xl text-white">Welcome to MyApp</h1>
<p class="text-gray-300">This is an example of a dark mode navigation component using Tailwind CSS.</p>
</div>
<style>
.dropdown:hover .dropdown-content {
display: block;
}
</style>
관련 구성 요소
Neumorphism Navigation 컴포넌트
Neumorphism Navigation Component는 포트폴리오 웹 사이트에 최적화되어 있습니다. 여러 대화형 요소가 있는 복잡한 레이아웃, 반응형 디자인, Tailwind CSS를 사용한 다크 모드 지원이 특징입니다. 색 구성표는 유사합니다.
스큐어모픽 내비게이션 컴포넌트(Skeuomorphic Navigation Component)
스큐어모픽 스타일로 디자인된 탐색 구성 요소로, 생생한 색상과 블로그 콘텐츠에 적합한 반응형 레이아웃을 특징으로 합니다. 여기에는 호버 효과와 같은 대화형 기능이 포함되어 있으며 다크 모드에 최적화되어 있습니다.