- Scan ID:
- 8cb39042-5c6b-41ed-bb75-5cd8df51999bFinished
- Submitted URL:
- https://gablaxy.github.io/stellar_system/
- Report Finished:
Links · 0 found
The outgoing links identified from the page
JavaScript Variables · 4 found
Global JavaScript variables loaded on the window object of a page, are variables declared outside of functions and accessible from anywhere in the code within the current scope
Name | Type |
---|---|
onbeforetoggle | object |
documentPictureInPicture | object |
onscrollend | object |
removePA | function |
Console log messages · 2 found
Messages logged to the web console
Type | Category | Log |
---|---|---|
warning | other |
|
error | network |
|
HTML
The raw HTML body of the page
<!DOCTYPE html><html lang="en"><head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Stellar system</title>
<link rel="stylesheet" href="./style/index.css">
<link rel="stylesheet" href="./style/common.css">
</head>
<body>
<div class="stars"></div>
<div class="all">
<div class="Soleil"></div>
<div class="Mercure planete"></div>
<div class="Venus planete"></div>
<div class="Terre planete"></div>
<div class="Mars planete"></div>
<div class="Jupiter planete"></div>
<div class="Saturne planete"></div>
<div class="Uranus planete"></div>
<div class="Neptune planete"></div>
</div>
<div class="menu">
<h1>Menu</h1>
<h3 id="nom_planete"></h3>
<a href="" id="zoom_link"><button class="zoom">Zoom</button></a>
</div>
<script type="text/javascript">
let planetes = document.querySelectorAll(".planete");
let soleil = document.querySelector(".Soleil");
let menu = document.querySelector(".menu");
let zlink = document.getElementById("zoom_link");
function removePA() {
planetes.forEach(element => {
element.classList.remove("planete_active");
});
}
// When the sun is clicked, the planets are no longer highlighted
soleil.addEventListener("click", function(){
removePA();
menu.style.display = "block";
document.getElementById("nom_planete").innerHTML = "Soleil";
});
planetes.forEach(element => {
element.addEventListener("click", function(){
removePA();
menu.style.display = "block";
element.classList.add("planete_active");
document.getElementById("nom_planete").innerHTML = element.classList[0];
zlink.href = "./planetes/" + element.classList[0] + ".html";
});
});
menu.addEventListener("click", function(){
menu.style.display = "none";
removePA();
});
</script>
</body></html>