-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.html
50 lines (46 loc) · 1.63 KB
/
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<title>Solar System in Pure Web Animations API (WAAPI)</title>
<script type="module" src="https://unpkg.com/@proyecto26/animatable-component@1.1.7/dist/animatable-component/animatable-component.esm.js"></script>
<script nomodule src="https://unpkg.com/@proyecto26/animatable-component@1.1.7/dist/animatable-component/animatable-component.js"></script>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<!-- STARS -->
<div class="stars"></div>
<!-- SOLAR SYSTEM ANIMATABLE -->
<div class="solar-system"></div>
<!-- SHOOTING STARS -->
<animatable-component
class='shooting-star star1'
autoplay
fill="both"
iterations="1"
easing="linear"
duration="2600"
delay="1000"
>
</animatable-component>
<animatable-component
class='shooting-star star2'
autoplay
fill="both"
iterations="1"
easing="linear"
duration="3000"
delay="2600"
>
</animatable-component>
<script type="text/javascript" src="index.js"></script>
<script type="text/javascript" src="utils.js"></script>
<script type="text/javascript">
const solarSystemContainer = document.querySelector('.solar-system');
solarSystemContainer.addEventListener("dblclick", toggleFullscreen);
createStars();
createSolarSystem();
createShootingStar(document.querySelector('.star1'));
createShootingStar(document.querySelector('.star2'));
</script>
</body>
</html>