summaryrefslogtreecommitdiff
path: root/scripts/scroll.js
diff options
context:
space:
mode:
authoraltaf-creator <athaalaa@gmail.com>2023-12-10 09:14:47 +0700
committeraltaf-creator <athaalaa@gmail.com>2023-12-10 09:14:47 +0700
commitd9ef8a652594c782be0422184a8632588805db06 (patch)
tree6acd6723c432b19f3763848d40f9909838b1046c /scripts/scroll.js
parent186df2c71e361ad84bf66625d87fab41eac827a9 (diff)
Added store page for simpliCity, tank shooter not finished
Diffstat (limited to 'scripts/scroll.js')
-rw-r--r--scripts/scroll.js12
1 files changed, 7 insertions, 5 deletions
diff --git a/scripts/scroll.js b/scripts/scroll.js
index b7a6fa0..6c20890 100644
--- a/scripts/scroll.js
+++ b/scripts/scroll.js
@@ -5,17 +5,19 @@ document.addEventListener('scroll', function () {
function progress() {
const sections = document.getElementsByTagName("section");
- const nodes = document.getElementsByTagName("nodes");
+ const nodes = document.getElementsByClassName("node");
if (nodes[0]) {
for (var i = 0; i < sections.length; i++) {
if (isInViewport(sections[i])) {
- nodes[i].style.width = "20px";
- nodes[i].style.height = "20px";
+ nodes[i].style.width = "22px";
+ nodes[i].style.height = "22px";
+ nodes[i].style.backgroundColor = "black";
}
else {
- nodes[i].style.width = "10px";
- nodes[i].style.height = "10px";
+ nodes[i].style.width = "13px";
+ nodes[i].style.height = "13px";
+ nodes[i].style.backgroundColor = "#555";
}
}
}