Published on

6 Tips To Create A Free Tailwind CSS Page Heading Component With Tailwind CSS

Tags
Free Tailwind CSS Page Heading Component

What is Tailwind CSS?

Tailwind CSS is a utility-first CSS framework that focuses on creating personalized user interfaces quickly. It can gives you all the building blocks you are able to create personalized designs without having to fight to override irritating opinionated styles. Also, Tailwind CSS is a highly configurable, low-level CSS framework.

The description of Free Tailwind CSS Page Heading Component ui component

Tailwind heading is used to add headlines to a web page that characterize content areas and give a title to a page. find more free and premium tailwind css components at www.tailwinduikit.com

Why use Tailwind CSS to create a Free Tailwind CSS Page Heading Component ui component?

  • It can make the building process of Free Tailwind CSS Page Heading Component ui component faster and more easily.
  • Enables building complex responsive layouts and components freely.
  • Minimum lines of CSS code in Free Tailwind CSS Page Heading Component component file.

The preview of Free Tailwind CSS Page Heading Component ui component

Free download of the Free Tailwind CSS Page Heading Component's source code

The source code of Free Tailwind CSS Page Heading Component ui component

<!-- Code block starts -->
        <div class="my-6 lg:my-12 container px-6 mx-auto flex flex-col md:flex-row items-start md:items-center justify-between pb-4 border-b border-gray-300">
            <div>
<!--- more free and premium Tailwind CSS components at https://tailwinduikit.com/ --->
                <h4 class="text-2xl font-bold leading-tight text-gray-800 dark:text-gray-100">User Profile</h4>
                <ul aria-label="current Status" class="flex flex-col md:flex-row items-start md:items-center text-gray-600 dark:text-gray-400 text-sm mt-3">
                    <li class="flex items-center mr-4">
                        <div class="mr-1">
                            <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-paperclip" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
                                <path stroke="none" d="M0 0h24v24H0z" />
                                <path d="M15 7l-6.5 6.5a1.5 1.5 0 0 0 3 3l6.5 -6.5a3 3 0 0 0 -6 -6l-6.5 6.5a4.5 4.5 0 0 0 9 9 l6.5 -6.5" />
                            </svg>
                        </div>
                        <span>Active</span>
                    </li>
                    <li class="flex items-center mr-4 mt-4 md:mt-0">
                        <div class="mr-1">
                            <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-trending-up" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
                                <path stroke="none" d="M0 0h24v24H0z" />
                                <polyline points="3 17 9 11 13 15 21 7" />
                                <polyline points="14 7 21 7 21 14" />
                            </svg>
                        </div>
                        <span> Trending</span>
                    </li>
                    <li class="flex items-center mt-4 md:mt-0">
                        <div class="mr-1">
                            <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-plane-departure" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
                                <path stroke="none" d="M0 0h24v24H0z" />
                                <path d="M15 12h5a2 2 0 0 1 0 4h-15l-3 -6h3l2 2h3l-2 -7h3z" transform="rotate(-15 12 12) translate(0 -1)" />
                                <line x1="3" y1="21" x2="21" y2="21" />
                            </svg>
                        </div>
                        <span>Started on 29 Jan 2020</span>
                    </li>
                </ul>
            </div>
            <div class="mt-6 md:mt-0">
                <button class="mr-3 bg-gray-200 dark:bg-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-700 transition duration-150 ease-in-out rounded hover:bg-gray-300 text-indigo-700 dark:hover:bg-gray-600 dark:text-indigo-600 px-5 py-2 text-sm">Back</button>
                <button class="transition focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-700 duration-150 ease-in-out hover:bg-indigo-600 bg-indigo-700 rounded text-white px-8 py-2 text-sm">Edit Profile</button>
            </div>
        </div>
        <!-- Code block ends -->

How to create a Free Tailwind CSS Page Heading Component with Tailwind CSS?

Install tailwind css of verion 2.2.19

Use the script html tag to import the script of Tailwind CSS of the version 2.2.19

<script src="https://cdn.tailwindcss.com"></script>

All the unility class needed to create a Free Tailwind CSS Page Heading Component component

  • my-6
  • lg:my-12
  • px-6
  • mx-auto
  • flex
  • flex-col
  • md:flex-row
  • pb-4
  • border-b
  • border-gray-300
  • text-2xl
  • text-gray-800
  • dark:text-gray-100
  • text-gray-600
  • dark:text-gray-400
  • text-sm
  • mt-3
  • mr-4
  • mr-1
  • mt-4
  • md:mt-0
  • mt-6
  • mr-3
  • bg-gray-200
  • dark:bg-gray-700
  • hover:bg-gray-300
  • text-indigo-700
  • dark:text-indigo-600
  • px-5
  • py-2
  • hover:bg-indigo-600
  • bg-indigo-700
  • text-white
  • px-8

34 steps to create a Free Tailwind CSS Page Heading Component component with Tailwind CSS

  1. Control the vertical margin of an element to 1.5rem using the my-6 utilities.

  2. Control the vertical margin of an element to 3rem at only large screen sizes using the lg:my-12 utilities.

  3. Control the horizontal padding of an element to 1.5rem using the px-6 utilities.

  4. Control the horizontal margin of an element to auto using the mx-auto utilities.

  5. Use flex to create a block-level flex container.

  6. Use flex to create a block-level flex container.

  7. Use flex to create a block-level flex container at only medium screen sizes.

  8. Control the padding on bottom side of an element to 1rem using the pb-4 utilities.

  9. Control the border color of an element to b using the border-b utilities.

  10. Control the border color of an element to gray-300 using the border-gray-300 utilities.

  11. Control the text color of an element to 2xl using the text-2xl utilities.

  12. Control the text color of an element to gray-800 using the text-gray-800 utilities.

  13. Control the text color of an element to gray-100 in dark theme using the dark:text-gray-100 utilities.

  14. Control the text color of an element to gray-600 using the text-gray-600 utilities.

  15. Control the text color of an element to gray-400 in dark theme using the dark:text-gray-400 utilities.

  16. Control the text color of an element to sm using the text-sm utilities.

  17. Control the margin on top side of an element to 0.75rem using the mt-3 utilities.

  18. Control the margin on right side of an element to 1rem using the mr-4 utilities.

  19. Control the margin on right side of an element to 0.25rem using the mr-1 utilities.

  20. Control the margin on top side of an element to 1rem using the mt-4 utilities.

  21. Control the margin on top side of an element to 0rem at only medium screen sizes using the md:mt-0 utilities.

  22. Control the margin on top side of an element to 1.5rem using the mt-6 utilities.

  23. Control the margin on right side of an element to 0.75rem using the mr-3 utilities.

  24. Control the background color of an element to gray-200 using the bg-gray-200 utilities.

  25. Control the background color of an element to gray-700 using the dark:bg-gray-700 utilities in dark theme.

  26. Control the background color of an element to gray-300 using the hover:bg-gray-300 utilities on hover.

  27. Control the text color of an element to indigo-700 using the text-indigo-700 utilities.

  28. Control the text color of an element to indigo-600 in dark theme using the dark:text-indigo-600 utilities.

  29. Control the horizontal padding of an element to 1.25rem using the px-5 utilities.

  30. Control the vertical padding of an element to 0.5rem using the py-2 utilities.

  31. Control the background color of an element to indigo-600 using the hover:bg-indigo-600 utilities on hover.

  32. Control the background color of an element to indigo-700 using the bg-indigo-700 utilities.

  33. Control the text color of an element to white using the text-white utilities.

  34. Control the horizontal padding of an element to 2rem using the px-8 utilities.

Conclusion

The above is a step-by-step tutorial on how to use Tailwind CSS to create a Free Tailwind CSS Page Heading Component components, learn and follow along to implement your own components.