pre-loader added · reboot100/30DaysOfJavaScript@55b45b6 · GitHub
Skip to content

Commit 55b45b6

Browse files
committed
pre-loader added
1 parent d27ac0f commit 55b45b6

4 files changed

Lines changed: 26 additions & 67 deletions

File tree

84.7 KB
Loading

‎30DaysOfJavaScript/script.js‎

Lines changed: 11 additions & 8 deletions

‎30DaysOfJavaScript/style.css‎

Lines changed: 8 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -15,63 +15,17 @@ body {
1515
}
1616

1717
/* Preloader */
18-
.preloader {
19-
background: #111;;
20-
width: 100%;
21-
height: 100%;
22-
line-height: 50px;
23-
text-align: center;
18+
#loading{
2419
position: fixed;
25-
top: 50%;
26-
left: 50%;
27-
transform: translate(-50%, -50%);
28-
font-family: helvetica, arial, sans-serif;
29-
font-weight: 900;
30-
letter-spacing: 0.2em;
31-
z-index: 9999999;
32-
}
33-
.preloader span {
34-
position: absolute;
35-
width: 250px;
36-
top: 50%;
37-
left: 50%;
38-
transform: translate(-50%, -50%);
39-
color: #fff;
40-
text-transform: uppercase;
41-
}
42-
.preloader span::before,
43-
.preloader span::after {
44-
content: "";
45-
display: block;
46-
width: 15px;
47-
height: 15px;
48-
background: #e47a17;
49-
position: absolute;
50-
animation: load 1s infinite alternate ease-in-out;
51-
}
52-
.preloader span::before {
53-
top: 0;
54-
}
55-
.preloader span::after {
56-
bottom: 0;
57-
}
58-
@keyframes load {
59-
0% {
60-
left: 0;
61-
height: 30px;
62-
width: 15px;
63-
}
64-
50% {
65-
height: 8px;
66-
width: 40px;
67-
}
68-
100% {
69-
left: 235px;
70-
height: 30px;
71-
width: 15px;
72-
}
20+
width: 100%;
21+
height: 100vh;
22+
background: #1f1e1e url('./assets/js-preloader.gif');
23+
background-repeat: no-repeat;
24+
background-position: center;
25+
z-index: 99999;
7326
}
7427

28+
7529
/* Dark Mode */
7630
body.dark-mode {
7731
background-color: #111;

‎index.html‎

Lines changed: 7 additions & 5 deletions

0 commit comments

Comments
 (0)