Archived topic
Problem with side jump marker
9 replies · Started by Torsten on August 31, 2021
Hello,
I have taken a theme from your library as a basis for mine.
Everything is as desired except for one point.
Unfortunately, there was a problem with the #contact page jump marker. On the smartphone (e.g. iPhone 8) it does not jump to where it should.
How can this be remedied?
Best regards
Torsten
Hi Torsten,
As it is, I believe what you're seeing is, the jump link goes a bit off of the contact form?
That happens because, on mobile, the anchor element has a lot of padding-top that pushes down the actual form. That padding serves like an offset.
Do you want the jump link to go directly to the "Contact Us" text string?
If yes, you should transfer the anchor to that element.
If this is not the case, can you show a recording of what's occurring? To be sure. Thank you. :D
Hello Elvin,
thank you for the quick answer.
Is the anchor alone also padding?
I would like the jump link to point directly to the "Contact" text line?
How is this to be corrected.
By the way, the cache is deleted.
Best regards
Torsten
This is the effect of the padding - https://share.getcloudapp.com/RBuLLvYv
Jump link brings the top of the anchored element to the top of the viewport.
The anchor element "contact" has a padding-top of 180px which effectively pushes its contents (the form) further away from the top of the anchor element's "top" area.
Here's a few things to consider:
You can either:
Reduce the padding-top of the container on mobile.
Or,
Move the "contact" anchor from the Container Block to the Heading block. :)
I have now changed the anchor to the heading.
Unfortunately mobile without change?
I send a recording of what happened.
I suspect that it was due to WP Fastes Cache.
It was the lazyload function of WPFC that interfered. If you deactivate it, it works.
Ah that could be the case as well.
Lazy loaded objects likely didn't load fast enough when you click the jump link.
Have you fully sorted it out? Let us know.
Now it is solved!
Thank you for your support.
Thanks for letting us know. glad you got it sorted. :D