forked from lingonsaft/hacktoberfest
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpixel_spinner.html
67 lines (65 loc) · 1.7 KB
/
pixel_spinner.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
62
63
64
65
66
67
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Pixel Spinner</title>
<style>
.pixel-spinner, .pixel-spinner * {
box-sizing: border-box;
}
.pixel-spinner {
height: 70px;
width: 70px;
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
}
.pixel-spinner .pixel-spinner-inner {
width: calc(70px / 7);
height: calc(70px / 7);
background-color: #ff1d5e;
color: #ff1d5e;
box-shadow: 15px 15px 0 0,
-15px -15px 0 0,
15px -15px 0 0,
-15px 15px 0 0,
0 15px 0 0,
15px 0 0 0,
-15px 0 0 0,
0 -15px 0 0;
animation: pixel-spinner-animation 2000ms linear infinite;
}
@keyframes pixel-spinner-animation {
50% {
box-shadow: 20px 20px 0px 0px,
-20px -20px 0px 0px,
20px -20px 0px 0px,
-20px 20px 0px 0px,
0px 10px 0px 0px,
10px 0px 0px 0px,
-10px 0px 0px 0px,
0px -10px 0px 0px;
}
75% {
box-shadow: 20px 20px 0px 0px,
-20px -20px 0px 0px,
20px -20px 0px 0px,
-20px 20px 0px 0px,
0px 10px 0px 0px,
10px 0px 0px 0px,
-10px 0px 0px 0px,
0px -10px 0px 0px;
}
100% {
transform: rotate(360deg);
}
}
</style>
</head>
<body>
<div class="pixel-spinner">
<div class="pixel-spinner-inner"></div>
</div>
</body>
</html>