payment-modals v1.0.37
Payment Modals
Initial setup
- Install the package
$ npm i payment-modalsCreate an element in your DOM with id="payment-modal"
Import default
handlePaymentModalvalue from this library in your project and feel free to use it!
It has several properties, that create modals:
window.handlePaymentModal.chooseModal(payNow, submitWithoutPaying, backToForm)All it's arguments are callbacks that invoke if appropriate button is pressed
window.handlePaymentModal.paymentModal(modalKey, uiData, innerData)Each argument is data, needed to configure the init method of SpreedlyExpress
window.handlePaymentModal.processingModal()window.handlePaymentModal.errorModal(isOptional, errorRetry, backToForm, errorSkip)First argument is a
booleanvalue that represents if the payment is optional Other arguments are callbacks that invoke if appropriate button is pressedhandlePaymentModal.successModal(successModalContinue)Single callback argument
handlePaymentModal.none()
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago