Basically, I have this piece of code:
if (this.variantId || theme.config.mqlSmall) {
this.addEventListener('click', this.onHoverHandler.bind(this));
this.querySelector('a').addEventListener('click', (event) => {
event.preventDefault();
console.log("hello")
});
}
That should triggers when a color selector get's clicked. It is adding the event listener into my color selector, but it's not triggering :S I'm a little confused about this, never happened to me
I want it to trigger the function when I click on it