Merge branch 'master' of code.areya.de:Areya/basic-business-template
commit
e2aac4800a
|
@ -5,9 +5,9 @@
|
||||||
<style>
|
<style>
|
||||||
.form-anchor{
|
.form-anchor{
|
||||||
opacity:0;
|
opacity:0;
|
||||||
|
transition: opacity .6s;
|
||||||
}
|
}
|
||||||
.form-anchor.show{
|
.form-anchor.show{
|
||||||
transition: opacity 300ms;
|
|
||||||
opacity:1;
|
opacity:1;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -232,7 +232,7 @@
|
||||||
if (entry.isIntersecting) {
|
if (entry.isIntersecting) {
|
||||||
// Remove the element to remove
|
// Remove the element to remove
|
||||||
elementToRemove.classList.remove('show');
|
elementToRemove.classList.remove('show');
|
||||||
setTimeout(() => elementToRemove.style.display = 'none', 300);
|
setTimeout(() => elementToRemove.style.display = 'none', 1200);
|
||||||
} else {
|
} else {
|
||||||
const fixedElementRect = elementToRemove.getBoundingClientRect();
|
const fixedElementRect = elementToRemove.getBoundingClientRect();
|
||||||
const referenceElementRect = targetElement.getBoundingClientRect();
|
const referenceElementRect = targetElement.getBoundingClientRect();
|
||||||
|
@ -240,12 +240,12 @@
|
||||||
if (fixedElementRect.bottom < referenceElementRect.top) {
|
if (fixedElementRect.bottom < referenceElementRect.top) {
|
||||||
// Show the element to remove
|
// Show the element to remove
|
||||||
elementToRemove.style.display = 'block';
|
elementToRemove.style.display = 'block';
|
||||||
setTimeout(() => elementToRemove.classList.add('show'), 300);
|
setTimeout(() => elementToRemove.classList.add('show'), 1200);
|
||||||
} else {
|
} else {
|
||||||
// Hide the element to remove
|
// Hide the element to remove
|
||||||
//elementToRemove.style.display = 'none';
|
//elementToRemove.style.display = 'none';
|
||||||
elementToRemove.classList.remove('show');
|
elementToRemove.classList.remove('show');
|
||||||
setTimeout(() => elementToRemove.style.display = 'none', 300);
|
setTimeout(() => elementToRemove.style.display = 'none', 1200);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Stop observing once it's removed (optional)
|
// Stop observing once it's removed (optional)
|
||||||
|
|
Loading…
Reference in New Issue