|
@@ -585,29 +585,3 @@ $.ajax({
|
|
|
});
|
|
|
});
|
|
|
|
|
|
- /* const sec = document.querySelectorAll('.sec');
|
|
|
- const title = document.querySelectorAll('.title');
|
|
|
- const cover = document.querySelectorAll('.cover');
|
|
|
- const test_content = document.querySelectorAll('.test_content');
|
|
|
-
|
|
|
- function checkSlide() {
|
|
|
- console.log('pass');
|
|
|
- sec.forEach((block, i) => {
|
|
|
- // half way through the image
|
|
|
- //const test = document.querySelector('.test');
|
|
|
- const slideInAt = window.scrollY + window.innerHeight;
|
|
|
- console.log(slideInAt);
|
|
|
- //console.log(test.offsetTop);
|
|
|
- // bottom of the image
|
|
|
- const isHalfShown = slideInAt > block.offsetTop;
|
|
|
- if (isHalfShown) {
|
|
|
- console.log('active');
|
|
|
- title[i].style.bottom = '0em';
|
|
|
- cover[i].classList.add('slidein');
|
|
|
- test_content[i].classList.add('fadein');
|
|
|
- }
|
|
|
- })
|
|
|
- };
|
|
|
-
|
|
|
- window.addEventListener('scroll', checkSlide); */
|
|
|
-
|