You can listen to the overlay events easily with a few lines of code. You'll need to make sure you've got the Lemon.js library installed on your page first.
Every time an event is fired from the Overlay,
Overlays events conform to a specific format. Any additional data will be included in the
data object section of the event, but it may not always be present.
List of Events
Lemon.js currently supports the following events:
|PaymentMethodUpdate.Mounted||Payment Method Update Overlay has been loaded|
|PaymentMethodUpdate.Closed||Payment Method Update Overlay has been closed|
|PaymentMethodUpdate.Updated||Payment method has been updated successfully|
|Checkout.Success||Checkout was successful|