From 0a268c4c73d8d8999bd044c2046e417484124e49 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Thu, 4 Jan 2024 11:32:10 +0800 Subject: updated style to match other pages (neon/cyber) --- src/js/about.js | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) (limited to 'src/js/about.js') diff --git a/src/js/about.js b/src/js/about.js index e69de29b..1a4813c2 100644 --- a/src/js/about.js +++ b/src/js/about.js @@ -0,0 +1,43 @@ +// Random Background color + +// aboutPage = document.querySelector(".aboutPage") + +// function getRandomColor() { +// const letters = "0123456789ABCDEF"; +// let color = "#"; +// for (let i = 0; i < 6; i++) { +// color += letters[Math.floor(Math.random() * 16)]; +// } +// return color; +// } + +// function setRandomGradient() { +// const rand3 = Math.floor(Math.random() * 3) + 1; +// if (rand3 === 1) { +// aboutPage.style.background = `linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()})`; +// } else if (rand3 === 2) { +// aboutPage.style.background = `linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}), +// linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()})`; +// } else { +// aboutPage.style.background = `linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}), +// linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}), +// linear-gradient(${Math.floor( +// Math.random() * 180 +// )}deg, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()}, ${getRandomColor()})`; +// } +// } + +// setRandomGradient(); + +// Execute setRandomGradient() every 1 minute +// setInterval(setRandomGradient, 60000); -- cgit v1.2.3