Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

101
Visualizações
Display an div element when another div has reached the middle of the viewport

I'm creating a reading app and I have a page navigation div with previous and next arrows that will take the user to the previous or next chapter. However, I would like the stores to only display when the chapter text is on the screen but be hidden when showing the header or footer. I'm using JQuery and have found some scripts that show/hide elements based on the scroll position on the page. The issue with these are that the length of the header/footer can differ depending on the viewport. So I would like to only trigger (show) the navigation div when the '.maintext' div has reached the center of the viewport, and hide again when it exits. Any help is much appreciated..

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda