Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. Need Custom Coding for Lay Theme? Find 3rd Party Developers here.
  3. Anchor scroll position, relative to filterbutton div height

Anchor scroll position, relative to filterbutton div height

Scheduled Pinned Locked Moved Need Custom Coding for Lay Theme? Find 3rd Party Developers here.
3 Posts 2 Posters 65 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    Nzagamba
    wrote last edited by
    #1

    Situation (here is my website draft):

    • I have 12+ filter buttons, position fixed on top of the website.
    • the buttons have anchor links that scroll to a certain area.

    Problem:

    • Depending on the screen width, the div, holding the buttons has a different height, breaking into 2, 3, or 4 lines, which makes the div height increase, on smaller screens. This is a problem, because the anchor scroll position should be relative to the div height holding the buttons, it should always scroll to the bottom edge of the div holding the buttons. Now the anchor links scrolls underneath the buttons on small screens. I put a padding-top 200px on the content div, but this only works for wide screens, not when the buttons break in to 3 or 4 lines, on smaller screens.

    Any suggestions or tipps on how I can solve this? I'm happy to get some help on this. Many thanks in advance!

    1 Reply Last reply
    0
    • N Offline
      N Offline
      Nzagamba
      wrote last edited by
      #2

      I also have a second issue, with the same filterbutton-menu from above. In mobile I used css and js to collapse the menu. For some reason, on iphone safari, once I click on one of the filter buttons, the bottom area suddenly covers in white. I spent hours with ChatGPT, trying to find the bug, but couldn't find a solution. So, here I am, I need some human help with this? :-) Could anyone look into it? Bellow images showing the correct screenshot on the left and the bug version on the right (once clicked on a filter button.

      IMG_6358.jpg IMG_6359.jpg

      1 Reply Last reply
      0
      • arminunruhA Offline
        arminunruhA Offline
        arminunruh
        Global Moderator
        wrote last edited by
        #3

        1.:

        you could use a textformat for the buttons that uses a % based font size, namely vw:

        image.png

        in textformats, click this and vw will appear. this will make the font size scale with the browser width

        2.:

        second issue is some new thing with the ios safari, nothing that can be done here as far as i know! found nothing online

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        I also code custom websites or custom Lay features.
        šŸ’æ Email me here: šŸ’æ
        info@laytheme.com

        Our Web Development company: 100k.studio

        Want to tip me? https://www.paypal.com/paypalme/arminunruh

        Before you post:
        1. When using a WordPress Cache plugin, disable it or clear your cache.
        2. Update Lay Theme and all Lay Theme Addons
        3. Disable all Plugins
        4. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"

        This often solves issues you might run into

        When you post:
        1. Post a link to where the problem is
        2. Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
        3. If the problem is difficult to explain, post screenshots / link to a video to explain it
        Online Users
        L
        Liefko
        Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
        laytheme.com
        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Recent
        • Tags
        • Popular
        • Users
        • Search