Remove JS

This commit is contained in:
Jip Fr 2020-10-07 17:33:30 +02:00
parent f7856be21b
commit 760ca35507
2 changed files with 1 additions and 15 deletions

View File

@ -1,12 +0,0 @@
// I stole this code.
for(let el of document.querySelectorAll("details")) {
el.addEventListener("click", evt => {
// Close detail elements if clicking elsewhere
let path = evt.path || [];
document.querySelectorAll("details[open]").forEach(el => {
if (!path.includes(el)) {
el.removeAttribute("open");
}
});
});
}

View File

@ -152,6 +152,4 @@
<footer>Copyright 2020 - Design by mrjvs, development by Jip Fr</footer>
</div>
<script src="main.js"></script>
</div>