forked from coder2hacker/Explore-open-source
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
29 lines (27 loc) · 798 Bytes
/
index.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="style.css">
<title>Birthday</title>
</head>
<body>
<section>
<h1 class="shadow">Happy birthday</h1>
<div class="banner">
<div class="blocks"></div>
</div>
</section>
<script>
// const banner=document.querySelector('.banner');
// const blocks=document.querySelector('.blocks');
const banner=document.getElementsByClassName('banner')[0];
const blocks=document.getElementsByClassName('blocks');
for(var i=1;i<400;i++){
banner.innerHTML+="<div class='blocks'></div>";
blocks[i].style.animationDelay=`${i*0.05}s`
}
</script>
</body>
</html>