Loader Using HTML & CSS (part-1)

Hello wizards, I hope you are doing great. Today in this blog you’ll learn how to create the Loader using HTML & CSS (part-1).

Preview 

In the above video, you’ve seen the preview of the Loader and I hope you are now able to create this type of project. If not, I have provided all the HTML & CSS code below. 

Loader [Source Code] 

To get the following HTML & CSS code for the Loader. You need to create two files one is an HTML file, and the second one is a CSS file. After completing these two files, you can copy-paste the codes on your document. 

Remember, you’ve to create a file with a .html extension for HTML code and a .css extension for CSS code.

You can also download all source code files from the given download button.

HTML
<html>

<head>
  <meta charset="UTF-8">
  <title>Loader</title>
  <link rel="stylesheet" type="text/css" href="styles.css">

</head>

<body>
  <div class="spinner">
    <div class="circle"></div>
  </div>
</body>
CSS
* {
  margin: 0;
  padding: 0;
}

body {
  background: black;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.spinner {
  width: 10rem;
  height: 10rem;
  border-top: 1rem solid red;
  border-right: 1rem solid transparent;
  border-radius: 50%;
  margin: auto;
  animation: spinner 1s linear infinite;
}

.circle {
  width: 1rem;
  height: 1rem;
  background-color: red;
  border-radius: 50%;
  margin-left: 8.5rem;
  margin-top: 0.5rem;
}

@keyframes spinner {
  100% {
    transform: rotate(360deg);
  }
}
You have to wait 15 seconds.

Generating Download Link...

Post a Comment

Previous Post Next Post