payment-modals v1.0.37
Payment Modals
Initial setup
- Install the package
$ npm i payment-modals
Create an element in your DOM with id="payment-modal"
Import default
handlePaymentModal
value 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
boolean
value 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()
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 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
5 years ago
5 years ago
5 years ago