Published on

6 Ideas To Help You Create A Instagram Login Page With Tailwind CSS Like A Pro

Instagram Login Page

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 Instagram Login Page ui component

Similar instagram login page

Why use Tailwind CSS to make a Instagram Login Page ui component?

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

The preview of Instagram Login Page ui component

Free download of the Instagram Login Page's source code

The source code of Instagram Login Page ui component

<!DOCTYPE html>
<html class="border-l" lang="en">
<head>
    <meta charset="UTF-8">
    <title>Login</title>
    <link href="https://unpkg.com/[email protected]^2/dist/tailwind.min.css" rel="stylesheet">
    <style>
        * {
            margin: 0;
            padding: 0;
        }
        .instagram-logo {
            background-position: 0 -130px;
            height: 51px;
            width: 175px;
            background-image: url(https://bit.ly/3v2LT17);
        }
        .facebook-logo {
            background-position: -414px -259px;
            background-image: url(https://bit.ly/3v2LT17);
            height: 16px;
            width: 16px;
        }
        .apple-store-logo {
            background-position: -132px -182px;
            height: 42px;
            width: 128px;
            background-image: url(https://bit.ly/3v2LT17);
        }
        .google-store-logo {
            background-position: 0 -182px;
            height: 42px;
            width: 130px;
            background-image: url(https://bit.ly/3v2LT17);
        }
    </style>
</head>
<body>
<div class="h-screen bg-gray-50 flex flex-col justify-center items-center">
    <div class="bg-white border border-gray-300 w-80 py-8 flex items-center flex-col mb-3">
        <h1 class="bg-no-repeat instagram-logo"></h1>
        <form class="mt-8 w-64 flex flex-col">
            <input autofocus
                   class="text-xs w-full mb-2 rounded border bg-gray-100 border-gray-300 px-2 py-2 focus:outline-none focus:border-gray-400 active:outline-none"
                   id="email" placeholder="Phone number, username, or email" type="text">
            <input autofocus
                   class="text-xs w-full mb-4 rounded border bg-gray-100 border-gray-300 px-2 py-2 focus:outline-none focus:border-gray-400 active:outline-none"
                   id="password" placeholder="Password" type="password">
            <a class=" text-sm text-center bg-blue-300 text-white py-1 rounded font-medium">
                Log In
            </a>
        </form>
        <div class="flex justify-evenly space-x-2 w-64 mt-4">
            <span class="bg-gray-300 h-px flex-grow t-2 relative top-2"></span>
            <span class="flex-none uppercase text-xs text-gray-400 font-semibold">or</span>
            <span class="bg-gray-300 h-px flex-grow t-2 relative top-2"></span>
        </div>
        <button class="mt-4 flex">
            <div class="bg-no-repeat facebook-logo mr-1"></div>
            <span class="text-xs text-blue-900 font-semibold">Log in with Facebook</span>
        </button>
        <a class="text-xs text-blue-900 mt-4 cursor-pointer -mb-4">Forgot password?</a>
    </div>
    <div class="bg-white border border-gray-300 text-center w-80 py-4">
        <span class="text-sm">Don't have an account?</span>
        <a class="text-blue-500 text-sm font-semibold">Sign up</a>
    </div>
    <div class="mt-3 text-center">
        <span class="text-xs">Get the app</span>
        <div class="flex mt-3 space-x-2">
            <div class="bg-no-repeat apple-store-logo"></div>
            <div class="bg-no-repeat google-store-logo"></div>
        </div>
    </div>
</div>
</body>
</html>

How to make a Instagram Login Page with Tailwind CSS?

Install tailwind css of verion 2.2.4

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

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

All the unility class needed to make a Instagram Login Page component

  • border-l
  • h-screen
  • bg-gray-50
  • flex
  • flex-col
  • bg-white
  • border-gray-300
  • w-80
  • py-8
  • mb-3
  • bg-no-repeat
  • mt-8
  • w-64
  • text-xs
  • w-full
  • mb-2
  • bg-gray-100
  • px-2
  • py-2
  • focus:border-gray-400
  • mb-4
  • text-sm
  • text-center
  • bg-blue-300
  • text-white
  • py-1
  • mt-4
  • bg-gray-300
  • h-px
  • flex-grow
  • relative
  • top-2
  • flex-none
  • text-gray-400
  • mr-1
  • text-blue-900
  • -mb-4
  • py-4
  • text-blue-500
  • mt-3

40 steps to make a Instagram Login Page component with Tailwind CSS

  1. Control the border color of an element to l using the border-l utilities.

  2. Use h-screen to make an element span the entire height of the viewport.

  3. Control the background color of an element to gray-50 using the bg-gray-50 utilities.

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

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

  6. Control the background color of an element to white using the bg-white utilities.

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

  8. Use w-80 to set an element to a fixed width(20rem).

  9. Control the vertical padding of an element to 2rem using the py-8 utilities.

  10. Control the margin on bottom side of an element to 0.75rem using the mb-3 utilities.

  11. Control the background color of an element to no-repeat using the bg-no-repeat utilities.

  12. Control the margin on top side of an element to 2rem using the mt-8 utilities.

  13. Use w-64 to set an element to a fixed width(16rem).

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

  15. Use w-full to set an element to a 100% based width.

  16. Control the margin on bottom side of an element to 0.5rem using the mb-2 utilities.

  17. Control the background color of an element to gray-100 using the bg-gray-100 utilities.

  18. Control the horizontal padding of an element to 0.5rem using the px-2 utilities.

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

  20. Control the border color of an element to gray-400 using the focus:border-gray-400 utilities on focus.

  21. Control the margin on bottom side of an element to 1rem using the mb-4 utilities.

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

  23. Control the text color of an element to center using the text-center utilities.

  24. Control the background color of an element to blue-300 using the bg-blue-300 utilities.

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

  26. Control the vertical padding of an element to 0.25rem using the py-1 utilities.

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

  28. Control the background color of an element to gray-300 using the bg-gray-300 utilities.

  29. Use h-px to set an element to a fixed height(px).

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

  31. Use relative to position an element according to the normal flow of the document.

  32. Use the top-2 utilities to set the top position of a positioned element to 0.5rem.

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

  34. Control the text color of an element to gray-400 using the text-gray-400 utilities.

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

  36. Control the text color of an element to blue-900 using the text-blue-900 utilities.

  37. Control the margin on bottom side of an element to -1rem using the -mb-4 utilities.

  38. Control the vertical padding of an element to 1rem using the py-4 utilities.

  39. Control the text color of an element to blue-500 using the text-blue-500 utilities.

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

Conclusion

The above is a step-by-step tutorial on how to use Tailwind CSS to make a Instagram Login Page components, learn and follow along to implement your own components.