Tailwind CSS Classes

Tailwind CSS class .content-start / .content-*

<div class="flex flex-wrap content-start bg-gray-200 h-32 my-2">
  <div class="w-2/5 bg-teal-400 p-1 m-1">1</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">2</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">3</div>
</div>
<div class="flex flex-wrap content-center bg-gray-200 h-32 my-2">
  <div class="w-2/5 bg-teal-400 p-1 m-1">1</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">2</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">3</div>
</div>
<div class="flex flex-wrap content-end bg-gray-200 h-32 my-2">
  <div class="w-2/5 bg-teal-400 p-1 m-1">1</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">2</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">3</div>
</div>
<div class="flex flex-wrap content-between bg-gray-200 h-32 my-2">
  <div class="w-2/5 bg-teal-400 p-1 m-1">1</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">2</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">3</div>
</div>
<div class="flex flex-wrap content-around bg-gray-200 h-32 my-2">
  <div class="w-2/5 bg-teal-400 p-1 m-1">1</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">2</div>
  <div class="w-2/5 bg-teal-400 p-1 m-1">3</div>
</div>

Preview

Are you tired of writing HTML by hand?

CSS source

.content-start { align-content: flex-start; }
.content-center { align-content: center; }
.content-end { align-content: flex-end; }
.content-between { align-content: space-between; }
.content-around { align-content: space-around; }

More Tailwind CSS classes in Flex category

© 2024 Shuffle. All rights reserved.