Skip to content

Commit

Permalink
minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
domonik committed Oct 25, 2023
1 parent a8fbdf9 commit d0849ef
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 29 deletions.
38 changes: 12 additions & 26 deletions assets/img/pumpkin.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 11 additions & 3 deletions assets/js/restylePage.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,19 +86,27 @@ function halloweenTheme(){
svgElement.parentNode.removeChild(svgElement);
};

const eye1 = svgElement.getElementById('eye1');
const eye2 = svgElement.getElementById('eye2');
const eye1 = svgElement.getElementById('tofill1');
const eye2 = svgElement.getElementById('tofill2');
const eye3 = svgElement.getElementById('tofill3');
const eye4 = svgElement.getElementById('tofill4');

eye1.style.fill = "black"
eye2.style.fill = "black"
eye3.style.fill = "black"
eye4.style.fill = "black"

document.addEventListener('scroll', function() {
eye1.style.fill = "#ffee0a";
eye2.style.fill = "#ffee0a";

eye3.style.fill = "#ffee0a";
eye4.style.fill = "#ffee0a";
clearTimeout(scrollTimeout);
scrollTimeout = setTimeout(function() {
eye1.style.fill = 'black';
eye2.style.fill = "black";
eye3.style.fill = "black";
eye4.style.fill = "black";
}, 200);
});
// You can now access and manipulate elements in the SV
Expand Down

0 comments on commit d0849ef

Please sign in to comment.