Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • 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. Sticky text

Sticky text

Scheduled Pinned Locked Moved General Discussion
9 Posts 5 Posters 210 Views
  • 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.
  • mauraverkleijM Offline
    mauraverkleijM Offline
    mauraverkleij
    wrote on last edited by mauraverkleij
    #1

    Hi, does anyone know if it's possible to make a text box sticky? So that the text in the upper left corner scrolls along with the entire page instead of just the first row? Thanks in advance! https://mauraverkleij.com/

    Scherm­afbeelding 2023-11-03 om 14.45.31.jpg

    1 Reply Last reply
    0
    • A Online
      A Online
      alasdair17
      wrote on last edited by
      #2

      hey, I think if you put everything into a stack in one row then the whole sticky text block should move down with it. Hope that helps.

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

        hey!
        i'll work on making this feature better!

        its just that the whole structure of the html code makes it hard to make sticky work at the moment other than within one row :O

        alasdair17's answer is the way to go,

        and actually its what lay theme recommends, if you read the text in the sticky modal:

        Screenshot 2023-11-05 at 17.30.22.png

        1 Reply Last reply
        0
        • mauraverkleijM Offline
          mauraverkleijM Offline
          mauraverkleij
          wrote on last edited by
          #4

          Thanks for your responses. Unfortunately, this is not an option for us as we expand titles using a row (mauraverkleij.com). Are there any alternatives? Is there no code for this?

          I'd like to hear your thoughts.

          1 Reply Last reply
          0
          • panteleyP Offline
            panteleyP Offline
            panteley
            wrote on last edited by panteley
            #5

            Try this, and see if it works:

            Add a Class to the text box, you want to be sticky. [eg. 'sticky']

            Then on Costumize > CSS > Costum Desktop CSS, add this

            div.sticky {
              position: -webkit-sticky;
              position: sticky;
              top: 1%;
            }
            

            'top: 1%' can be a percentage or px, depending on how you have set the Frame spacing.

            1 Reply Last reply
            0
            • mauraverkleijM Offline
              mauraverkleijM Offline
              mauraverkleij
              wrote on last edited by
              #6

              Hello @panteley,

              Thank you for your response. I have tried this several times already, but it doesn't seem to work.

              Could it be because a new line is starting? Or am I doing something wrong with the settings? When I look at the code via Chrome --> Developer Tools, I also don't see 'Sticky' as an element. Is that normal?

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

                hey you can try 2 things:

                make the row sticky where your text is in.
                just add the class "sticky" to your row in the gridder (right click empty part of a row → set html class and id)

                and use this css in lay options → custom css & html

                .sticky {
                  position: sticky;
                  top: 0;
                }
                

                the other thing you can try is:
                give your text the class "fixed"
                then in your css:

                .fixed{
                    position: fixed;
                    top: 50px;
                    left: 50px;
                    z-index: 20;
                }
                

                this will just fix the text at a certain position for the whole page. its almost the same as sticky

                one day i will try and change the sticky feature so an element can be sticky for a whole page

                you could also

                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  mogios
                  wrote on last edited by
                  #8

                  Hey @arminunruh . Is there any easy way to make something sticky with your fixed class custom css, but in the full-screen slider enabled ?

                  Thx !

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

                    no sorry

                    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

                    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
                    A
                    alasdair17
                    V
                    visch
                    M
                    michael_vvc
                    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