Skip to content

Commit

Permalink
Loader Animation (#2310)
Browse files Browse the repository at this point in the history
* added modifications in include.js

* loader animation

* added the deleted entry

* Update include.js

Removed extra line

---------

Co-authored-by: Laureline Paris <32878345+LaurelineP@users.noreply.github.com>
  • Loading branch information
rishika-on-git and LaurelineP authored Oct 29, 2023
1 parent 6f98cc7 commit 40f80ba
Show file tree
Hide file tree
Showing 4 changed files with 130 additions and 0 deletions.
21 changes: 21 additions & 0 deletions Art/rishika-on-git/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>ZTM-Animation</title>
<link rel="stylesheet" href="styles.css" />
</head>
<body>
<div class="container">
<div class="box"></div>
</div>

<div class="loader">
<div class="dot"></div>
<div class="dot"></div>
<div class="dot"></div>
<div class="dot"></div>
</div>
</body>
</html>
Binary file added Art/rishika-on-git/result.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
102 changes: 102 additions & 0 deletions Art/rishika-on-git/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
body {
margin: 0;
background-color: purple;
height: 100vh;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
gap: 200px;
}

.container {
width: 300px;
height: 300px;
border: 2px solid white;
animation: orbit 4s linear infinite;
border-radius: 50%;
}

.box {
width: 100px;
height: 100px;
background-color : yellow;

animation-duration: 1s;

animation-iteration-count: infinite;
animation-direction: normal;
animation-timing-function: linear;

border-radius: 50%;
box-shadow: 2px solid white;
}


.loader {
display: flex;
align-items: center;
justify-content: center;
gap: 10px;
}

.dot {
width: 10px;
height: 10px;
border-radius: 50%;
background-color: white;
animation: up-down 0.8s ease infinite alternate both;
}

.dot:nth-child(2) {
animation-delay: 0.1s;
}
.dot:nth-child(3) {
animation-delay: 0.2s;
}
.dot:nth-child(4) {
animation-delay: 0.3s;
}

@keyframes up-down {
from {
transform: translateY(-20px);
}
to {
transform: translateY(20px);
}
}

@keyframes orbit {
from {
transform: rotate(0);
}
to {
transform: rotate(360deg);
}
}

@keyframes slide-in {
0% {
transform: translate(-400px);
}

100% {
transform: translate(200px);
}
}

@keyframes circles {
0%, 100% {
transform: translate(0, 0);
}
25% {
transform: translate(200px, 0);
}
50% {
transform: translate(200px, 200px);
}
75% {
transform: translate(0, 200px);
}
}
7 changes: 7 additions & 0 deletions include.js
Original file line number Diff line number Diff line change
Expand Up @@ -2335,6 +2335,13 @@ let cards = [
author: 'Shubham Kashyap',
githubLink: 'https://github.com/Shubhamkashyap1601'
},
{
artName: 'Basic loader animation',
pageLink: './Art/rishika-on-git/index.html',
imageLink: './Art/rishika-on-git/result.gif',
author: 'Rishika Aggarwal',
githubLink: 'https://github.com/rishika-on-git'
},
{
artName: 'Compass Loader',
pageLink: './Art/AmanPathan/index.html',
Expand Down

0 comments on commit 40f80ba

Please sign in to comment.