Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

95
Vistas
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 la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda