导航栏中元素的间距 - Tailwind CSS

问题描述 投票:0回答:1
html css tailwind-css navbar
1个回答
0
投票

span.flex 元素上的

justify-between
类将均匀地间隔导航栏项目。

<script src="https://cdn.tailwindcss.com"></script>
<div class="flex bg-black h-12 items-center space-x-11">
  <nav class="flex">
    <span class="text-white text-3xl font-bold hover:text-gray-300 hover:underline">
      <a href="#">Corner Hair Salon</a>
    </span>
    <span class="flex justify-between">
      <a href="#">Home</a>
      <a href="#">About</a>
      <a href="#">Appointments</a>
    </span>
    <span class="text-white text-3xl font-bold hover:text-gray-300 hover:underline">
      <a href="#">Sign-In</a>
    </span>
  </nav>
</div>

© www.soinside.com 2019 - 2024. All rights reserved.