Skip to content

Commit

Permalink
Merge pull request #2874 from vedpawar2254/Addmyartwork
Browse files Browse the repository at this point in the history
BouncingBall
  • Loading branch information
l-white authored Oct 31, 2024
2 parents 9c9905e + a3ed618 commit 7279b26
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 0 deletions.
14 changes: 14 additions & 0 deletions Art/vedpawar2254-bouncingball/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Bouncing Ball Animation</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<div class="container">
<div class="ball"></div>
</div>
</body>
</html>
4 changes: 4 additions & 0 deletions Art/vedpawar2254-bouncingball/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"artName": "bouncingball",
"githubHandlde":"vedpawar2254"
}
44 changes: 44 additions & 0 deletions Art/vedpawar2254-bouncingball/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}

body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background-color: #282c34;
}

.container {
position: relative;
width: 300px;
height: 500px;
overflow: hidden;
border: 2px solid #61dafb;
}

.ball {
position: absolute;
bottom: 0;
left: 50%;
width: 50px;
height: 50px;
background-color: #61dafb;
border-radius: 50%;
animation: bounce 1s infinite ease-in-out;
}

@keyframes bounce {
0%, 100% {
transform: translateY(0);
background-color: #61dafb; /* Initial color */
}

50% {
transform: translateY(-200px);
background-color: #ff6f61; /* Change color at the peak */
}
}

0 comments on commit 7279b26

Please sign in to comment.