• I’ve enabled sticky header and now the call to action button links to same page anchor links pushes the page up too much so that the anchor point is behind the sticky header. I use Gutenberg and Astra. I have tried something like this with no success:

    */ offset header on anchors* /
    .stickytopoffset {
    position: relative;
    top: -150px;
    visibility: visible;
    }

    Any other suggestions? Must be a standard issue.

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Hello @daspi

    Yes, for now, the custom CSS is the correct way to go.

    As the page scroll is handled by default. So while the Sticky Header is used, managing the scroll is a bit tricky.

    Currently, we do not have any option to manage the scenario, if feasible we shall provide such an option or manage it dynamically in future updates.

    I hope that clarifies and answers your query. Do let us know if you have any further queries.

    Regards,
    Suman

    Thread Starter daspi

    (@daspi)

    Well, my current problem is the CSS does not work. Found this somewhere posted, but has no effect. Any suggestions for working CSS on latest Astra?

    Hello @daspi

    Can you provide me with the site URL so that we can take a look at the Sticky Header on your end and provide the relevant CSS?

    Looking forward to hearing from you!

    Regards,
    Suman

    Thread Starter daspi

    (@daspi)

    Sure

    • This reply was modified 4 years, 7 months ago by Jan Dembowski.

    Hello @daspi

    I took some inspiration from where you found the initial custom CSS.

    So to achieve this requirement, either you will need an empty Custom HTML Gutenberg block with div having an ID or else a Heading block with anchor tag.

    Now, the anchor tag will be the ID used in the below custom CSS.

    #world:before {
        content: '';
        display: block; 
        position: relative; 
        width: 0; 
        height: 2em; 
        margin-top: -2em;
    }

    You can adjust or manage the height and margin-top values equally based on the height of Sticky Header.

    If you are facing issues, do reach out to us through our Support Portal so that we can help you out accordingly. Do share this ticket ID for quicker help.

    I hope that helps.

    Regards,
    Suman

    Thread Starter daspi

    (@daspi)

    Thank you! Nice workaround. But hope it will be fixed with an update soon.

    Perfect, @daspi!

    Glad to help achieve this requirement. ??

    Currently, we do not have any plans for introducing this feature in upcoming updates. If feasible, we shall consider the same in our future updates.

    Do let us know if there’s anything else we can help you with. And do mark the topic as resolved.

    This fix sort of works but also stops the nice smooth scroll to anchors from working.

    Would love to see this added as a feature – it essentially limits use of anchors when using a sticky header, and I’ve used lots of other themes that know when the sticky header is enabled and then account for this in anchor links.

    Hoping this might be something the Brainstorm Force team can look at in a future update.

    FYI incase this helps anyone else…

    This can be achieved using this plugin:
    https://www.ads-software.com/plugins/hash-link-scroll-offset/

    But you have to still add in a HTML block with a blank div for it to work nicely.

    
    <div id="AnchorName'></div>
    

    Hello @tidalfan

    Yes, definitely. We have already discussed the same in one of our meetings and it has been added to our to-do list.

    So you can surely expect the same in our future updates.

    I hope that helps. Feel free to reach out to us through our Support Portal for any queries or concerns.

    Regards,
    Suman ??

    Hi same here, waiting for this ??
    I’m using https://www.ads-software.com/plugins/hash-link-scroll-offset/ instead…
    Thanks

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Anchor links pushes up behind sticky header’ is closed to new replies.