Added fading for resume page.

This commit is contained in:
g* 2025-06-15 16:22:31 +02:00
commit 3dad792c5f
4 changed files with 68 additions and 23 deletions

12
docs/src/js/resume.js Normal file
View file

@ -0,0 +1,12 @@
window.addEventListener('scroll', function () {
const contents = document.querySelectorAll('.fade-in-up-section');
contents.forEach(content => {
const contentPosition = content.getBoundingClientRect().top;
const screenPosition = window.innerHeight / 1.2;
if (contentPosition < screenPosition) {
content.classList.add('visible');
}
});
});