generated from skills/introduction-to-github
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbouncing ball.html
61 lines (56 loc) · 1.39 KB
/
bouncing ball.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Bouncing ball</title>
<style>
body{
background-color: rgb(61, 60, 59);
}
.imageone{
height: 50px;
width: 50px;
transition: all ease-in-out 0.1s;
position: relative;
top: 100px;
left: 44.5%;
animation: bounce 1.5s infinite;
}
@keyframes bounce {
0% {
transform: translateY(0);
}
50% {
transform: translateY(-100px);
}
100% {
transform: translateY(0);
}
}
.imagetwo{
height: 50px;
width: 50px;
top: 300px;
left: 300px;
animation-name: slider;
animation-duration: 3s;
}
@keyframes slider {
0%{
transform: rotate(0deg);
}
50%{
transform: rotate(180deg);
}
100%{
transform: rotate(0deg);
}
}
</style>
</head>
<body>
<img class="imageone" src="images/ball.png" alt="">
<img class="imagetwo" src="images/arrow-up.png" alt="">
</body>
</html>