jeffharrell / minicart

The minicart is a great way to improve your PayPal shopping cart integration.
MIT License
501 stars 211 forks source link

Close button on modal popup and per item not working #290

Open spencershaw opened 8 years ago

spencershaw commented 8 years ago

The example at http://minicartjs.com/ is not working fully.

  1. The modal cross (top right hand corner of the popup) does nothing
  2. The line item crosses do not work.

Attached is:

screenshot 2016-07-12 16 11 31

bandicam 2016-07-12 16-09-22-414.zip

spencershaw commented 8 years ago

Is minicart.js still supported? Can't believe no one has replied.

mathmach commented 7 years ago

Sorry for the 1 year, but I found the problem...

You're probably using a touch laptop and Chrome turns on the event "ontouchstart" by default. I found in .js the part that creates the "x" event and if "ontouchstart" is enabled, the code does not create this event.

To fix it you need to delete this part "('ontouchstart' in window)? 'Touchstart' :" on line 2793 of minicart.js instead of "events.add (document, ('ontouchstart' in window)? 'Touchstart' : 'Click', viewevents.click, this);".

It will look like this: "events.add (document, 'click', viewevents.click, this);"