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. General Discussion
  3. logo Scroll animation

logo Scroll animation

Scheduled Pinned Locked Moved General Discussion
8 Posts 3 Posters 1.3k Views 2 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.
  • W
    W
    Warul Kawa
    wrote on last edited by
    #1

    Hi!
    I'm looking for a way replicate this simple scroll animation, where the first row is fixed, but scrolls away as the second row scrolls in:
    https://spaces.is/loversmagazine/interviews/marc-edwards

    Appreciate any help you can throw my way!

    1 Reply Last reply
    0
    • F
      F
      felix_rabe
      wrote on last edited by felix_rabe
      #2

      imagine a container that contains the headline and below the image. now you give the headline a "position: sticky; top: 0;" as a custom css. Maybe you can work with that?

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

        yea!

        try creating a row,
        right click the row, choose set custom row height

        enter 200vh as row height

        now put a text and image into that row.
        right click both and for both click "make sticky"

        then play around with the positioning of both elements and - right click on element → space top

        1 Reply Last reply
        0
        • F felix_rabe

          imagine a container that contains the headline and below the image. now you give the headline a "position: sticky; top: 0;" as a custom css. Maybe you can work with that?

          W
          W
          Warul Kawa
          wrote on last edited by
          #4

          @felix_rabe
          @arminunruh

          Thanks a lot!

          1 Reply Last reply
          0
          • W
            W
            Warul Kawa
            wrote on last edited by
            #5

            @arminunruh would it also be possible to hide the menu while on that row, like on the example website?

            1 Reply Last reply
            0
            • W
              W
              Warul Kawa
              wrote on last edited by Warul Kawa
              #6

              i tried this but it's not doing the trick (introhead is the class I gave to the row)

              body[data-type="page"][data-id="19"].introhead nav {
              	display: none !important;
              }
              

              here's the website: http://beabeazleyarchitects.com

              1 Reply Last reply
              0
              • arminunruhA
                arminunruhA
                arminunruh
                Global Moderator
                wrote on last edited by
                #7

                this wont work. the nav element would need to be a child element of the row with the class. but its not, also the .introhead needs a space before .

                i think one way to do this would be to just hide the nav for this page:

                body[data-type="page"][data-id="19"] nav {
                	display: none !important;
                }
                

                and then using javascript, show the nav again on scroll:

                <script>
                jQuery(document).on('scroll', function(){
                if(window.scrollY > window.innerHeight) {
                jQuery('nav').css('display', 'inline-block');
                } else {
                jQuery('nav').css('display', '');
                }
                })
                </script>
                

                add this to lay options → custom css & html → custom head content

                you may also need to check if you're on that specific page with javascript,
                you may also need to use the newpageshown event:
                https://laytheme.com/documentation/custom-javascript.html#newpage-events

                to check if you just arrived on this page from another page to then hide the navigation in case your scroll position is < window.scrollY

                1 Reply Last reply
                0
                • W
                  W
                  Warul Kawa
                  wrote on last edited by
                  #8

                  Thank you Armin! I'll try that.

                  1 Reply Last reply
                  0

                  Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                  Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                  With your input, this post could be even better 💗

                  Register Login
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  Online Users
                  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