Add a 'hide more' button to hide the unhide button
This commit is contained in:
parent
dccdf1fb99
commit
e42ec34ce2
@ -12,6 +12,10 @@ function unhide_page() {
|
|||||||
hidden.style.display = 'none';
|
hidden.style.display = 'none';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function hide_actually_everything() {
|
||||||
|
hidden.style.display = 'none';
|
||||||
|
}
|
||||||
|
|
||||||
var shown = document.getElementById("page-content");
|
var shown = document.getElementById("page-content");
|
||||||
var hidden = document.getElementById("page-content-hidden");
|
var hidden = document.getElementById("page-content-hidden");
|
||||||
|
|
||||||
@ -21,3 +25,6 @@ document
|
|||||||
document
|
document
|
||||||
.getElementById("button-unhide-page")
|
.getElementById("button-unhide-page")
|
||||||
.addEventListener("click", unhide_page);
|
.addEventListener("click", unhide_page);
|
||||||
|
document
|
||||||
|
.getElementById("button-hide-everything")
|
||||||
|
.addEventListener("click", hide_actually_everything);
|
||||||
|
@ -25,6 +25,8 @@
|
|||||||
|
|
||||||
<div id="page-content-hidden">
|
<div id="page-content-hidden">
|
||||||
<button id="button-unhide-page">unhide</button>
|
<button id="button-unhide-page">unhide</button>
|
||||||
|
<button id="button-hide-everything">hide more</button>
|
||||||
|
<p>if you click "hide more" it'll hide all this too, and you'll need to reload to get it back
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- this is the canvas that makes up the page background -->
|
<!-- this is the canvas that makes up the page background -->
|
||||||
|
Loading…
x
Reference in New Issue
Block a user