globalpayments / globalpayments-3ds-js

Helper library for leveraging 3DSecure 2 for Strong Customer Authentication (SCA)
https://www.npmjs.com/package/globalpayments-3ds
GNU General Public License v2.0
5 stars 10 forks source link

"lightbox" displayMode -- how to get a notification when a user closes the lightbox's iframe via closeButton? #22

Open gribunin opened 3 years ago

gribunin commented 3 years ago

I studied the source code and it seems that when a close button is pressed in the "lightbox" displayMode it just closes the corresponding iFrame and nothing more. How can I get the notification that the challenge iframe was closed via close button and update my payment UI accordingly?

securesubmit-buildmaster commented 3 years ago

We do not currently emit an event for when the iframe is closed, though we can add this to our backlog as a future feature enhancement. While not ideal, you can check for the existence of the close button itself (its id is prefixed with GlobalPayments-frame-close-) manually in the meantime.