chore: horia kentzen du esteketatik

This commit is contained in:
txarli committed 2026-11-06 12:47:09 +01:00
1 parent e893756d03
commit 9b0ba10efe
1 file changed
+18 -18
+18 -18
View File
@@ -1,24 +1,24 @@
<script is:inline>
let colors = ["var(--green)", "var(--pink)", "var(--blue)", "var(--yellow)"];
let colors = ["var(--green)", "var(--pink)", "var(--blue)"];
function getRandomColor() {
return colors[Math.floor(Math.random() * colors.length)];
}
function getRandomColor() {
return colors[Math.floor(Math.random() * colors.length)];
}
function setRandomLinkColor() {
Array.from(document.getElementsByTagName("a")).forEach((e) => {
e.style.textDecorationColor = getRandomColor();
});
}
function setRandomLinkColor() {
Array.from(document.getElementsByTagName("a")).forEach((e) => {
e.style.textDecorationColor = getRandomColor();
});
}
function setColorHoverListener() {
Array.from(document.querySelectorAll("a, button")).forEach((e) => {
e.addEventListener("mouseover", setRandomLinkColor);
});
}
function setColorHoverListener() {
Array.from(document.querySelectorAll("a, button")).forEach((e) => {
e.addEventListener("mouseover", setRandomLinkColor);
});
}
(function () {
setRandomLinkColor();
setColorHoverListener();
})();
(function () {
setRandomLinkColor();
setColorHoverListener();
})();
</script>