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

247
Vistas
Why is vertical scrolling not working whereas horizontal scrolling is working in a webpage?

I have a webpage where there is a slider like this https://tympanus.net/Tutorials/GooeyImageHoverEffects/. The problem is that vertial scroling is not working when I use the mouse wheel, only horizontal scroll is working when I use the mouse wheel. The webpage has a plugin named HorizontalScrollPlugin.js. Code of HorizontalScrollPlugin.js:

import Scrollbar from 'smooth-scrollbar'

export default class HorizontalScrollPlugin extends Scrollbar.ScrollbarPlugin {

 transformDelta(delta, fromEvent) {
     if (this.shouldInvertDelta(fromEvent)) {
         return {
            x: delta.y,
            y: delta.y,
         }
     }

     return delta
 }

 shouldInvertDelta(fromEvent) {
    return this.options.events.some((rule) => fromEvent.type.match(rule))
 }

}

HorizontalScrollPlugin.pluginName = 'horizontalScroll'
HorizontalScrollPlugin.defaultOptions = { events: [] }

I don't know what to change in this code to allow vertiall scrolling by using the mouse wheel. I tried this x: delta.x but it's not working. The rest of the code is here in github https://github.com/Aqro/gooey-hover-codrops. Can anyone help?

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