Benjamin Völkl 2024-01-10 13:47:17 +01:00
parent dc4251bc0c
commit 50c39dfc60
1 changed files with 24 additions and 0 deletions

View File

@ -207,4 +207,28 @@
}));
});
</script>


<script>
// Get the elements
const targetElement = document.querySelector('#lumino-form-sent');
const elementToRemove = document.querySelector('.fixed-bottom');

// Create an Intersection Observer
const observer = new IntersectionObserver(entries => {
entries.forEach(entry => {
// If target element is visible
if (entry.isIntersecting) {
// Remove the element to remove
elementToRemove.remove();
// Stop observing once it's removed (optional)
observer.unobserve(targetElement);
}
});
});

// Observe the target element
observer.observe(targetElement);

</script>
@stop