prestarocket-agence / classic-rocket

Classic Rocket is a rework of "classic theme". It has been built keeping in mind : performance, accessibility and SEO.
https://demoprestashop.prestarocket.com/
Other
229 stars 127 forks source link

Uncaught TypeError: this.el.hoverIntent is not a function #267

Open ShapesGraphicStudio opened 3 years ago

ShapesGraphicStudio commented 3 years ago

Hi,

Is the demo using latest PrestaShop version? On my install, I get Uncaught TypeError: this.el.hoverIntent is not a function error on the checkout page.

I thought it might be related to the child theme I added, but I'm getting the same error switching to Classic Rocket Version 3.0.4 theme.

Error only goes away when switching to Classic Version 1.0.0 theme.

Any idea on how I could get this fixed please?

ShapesGraphicStudio commented 3 years ago

I don't know if it's the best way to do this but I managed to get rid of this error by overriding theme.js file in my child theme.

I changed:

this.el.hoverIntent({ over: this.toggleClassSubMenu, out: this.toggleClassSubMenu, selector: " > li", timeout: 100 });`

to:

if(prestashop.page.page_name != 'checkout') {
    this.el.hoverIntent({ over: this.toggleClassSubMenu, out: this.toggleClassSubMenu, selector: " > li", timeout: 100 });
}