@paykka/card-checkout-ui 0.13.16 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/card-checkout-ui.js +54 -26
- package/dist/card-checkout-ui.umd.cjs +54 -26
- package/dist/es/api/modules/boost/index.js +5 -16
- package/dist/es/api/modules/gcash/index.js +5 -16
- package/dist/es/api/modules/get-browser-params.js +1 -4
- package/dist/es/api/modules/grab-pay/index.js +5 -16
- package/dist/es/api/modules/line-pay/index.js +5 -16
- package/dist/es/api/modules/may-bank-qr-pay/index.js +5 -16
- package/dist/es/api/modules/nine-pay/index.js +5 -16
- package/dist/es/api/modules/opay-wallet/index.js +5 -16
- package/dist/es/api/modules/paga-wallet/index.js +5 -16
- package/dist/es/api/modules/paymaya/index.js +5 -16
- package/dist/es/api/modules/shopee-pay/index.js +5 -16
- package/dist/es/api/modules/threeDS/index.js +16 -2
- package/dist/es/api/modules/tng-wallet/index.js +5 -16
- package/dist/es/api/modules/wallet/index.js +16 -0
- package/dist/es/api/modules/zalopay/index.js +5 -16
- package/dist/es/api/utils/index.js +2 -1
- package/dist/es/components/AccordionItem/AccordionItem.js +0 -2
- package/dist/es/components/AddressField/index.js +95 -85
- package/dist/es/components/AliPay/index.js +88 -76
- package/dist/es/components/ApplePay/index.js +61 -43
- package/dist/es/components/CPFField/index.js +2 -1
- package/dist/es/components/Card/index.js +182 -143
- package/dist/es/components/CardExpireDateField/index.js +2 -1
- package/dist/es/components/CardNo/index.js +2 -2
- package/dist/es/components/CardNumberField/index.js +2 -1
- package/dist/es/components/CardSecurityCodeField/index.js +2 -1
- package/dist/es/components/CardSelector/index.js +3 -2
- package/dist/es/components/DropIn/index.js +98 -31
- package/dist/es/components/GooglePay/index.js +190 -151
- package/dist/es/components/GuideCard/index.js +8 -1
- package/dist/es/components/PaymentButton/index.js +58 -0
- package/dist/es/components/RecurringTip/index.js +3 -3
- package/dist/es/components/SecuredFieldsProvider/index.js +81 -17
- package/dist/es/components/SecuredIframe/index.js +120 -52
- package/dist/es/components/Sepa/index.js +23 -25
- package/dist/es/components/SubmitButton/index.js +1 -1
- package/dist/es/components/ThreeDS/index.js +34 -15
- package/dist/es/components/WechatPay/index.js +94 -83
- package/dist/es/components/business/BlikCodeField/BlikCodeField.js +92 -0
- package/dist/es/components/business/BlikCodeField/blik-code-field.js +1 -0
- package/dist/es/components/business/BlikCodeField/index.js +13 -0
- package/dist/es/components/business/BlikConfirmModal/BlikConfirmModal.js +45 -0
- package/dist/es/components/business/BlikConfirmModal/blik-confirm-modal.js +1 -0
- package/dist/es/components/business/BlikConfirmModal/index.js +9 -0
- package/dist/es/components/business/BlikConfirmModal/type.js +1 -0
- package/dist/es/components/business/NameField/NameField.js +51 -0
- package/dist/es/components/business/NameField/index.js +11 -0
- package/dist/es/components/business/NameField/type.js +1 -0
- package/dist/es/components/business/PhoneField/PhoneField.js +125 -0
- package/dist/es/components/business/PhoneField/config.js +33 -0
- package/dist/es/components/business/PhoneField/index.js +14 -0
- package/dist/es/components/business/PhoneField/phone-field.js +1 -0
- package/dist/es/components/business/PhoneField/type.js +1 -0
- package/dist/es/components/business/SegmentedDigitInput/SegmentedDigitInput.js +80 -0
- package/dist/es/components/business/SegmentedDigitInput/format.js +26 -0
- package/dist/es/components/business/SegmentedDigitInput/index.js +5 -0
- package/dist/es/components/business/Tooltip/Tooltip.js +18 -0
- package/dist/es/components/business/Tooltip/index.js +6 -0
- package/dist/es/components/business/Tooltip/tooltip2.js +1 -0
- package/dist/es/components/business/index.js +14 -0
- package/dist/es/components/index.js +14 -7
- package/dist/es/components/internal/CheckBox/CheckBox.js +2 -2
- package/dist/es/components/internal/Input/Input.js +1 -1
- package/dist/es/components/internal/Select/Select.js +7 -1
- package/dist/es/components/internal/icons/IconArrowDown.js +4 -4
- package/dist/es/components/internal/icons/IconBancontact.js +95 -0
- package/dist/es/components/internal/icons/IconBlik.js +567 -0
- package/dist/es/components/internal/icons/IconIdeal.js +86 -0
- package/dist/es/components/internal/icons/IconOvo.js +47 -0
- package/dist/es/components/internal/icons/IconP24.js +40 -0
- package/dist/es/components/internal/icons/IconPhone.js +56 -0
- package/dist/es/components/internal/icons/IconSkrill.js +38 -0
- package/dist/es/components/internal/icons/IconTrustly.js +37 -0
- package/dist/es/components/wallets/Bancontact/Bancontact.js +201 -0
- package/dist/es/components/wallets/Bancontact/bancontact2.js +1 -0
- package/dist/es/components/wallets/Bancontact/index.js +1 -0
- package/dist/es/components/wallets/Bancontact/type.js +1 -0
- package/dist/es/components/wallets/Blik/Blik.js +232 -0
- package/dist/es/components/wallets/Blik/blik2.js +1 -0
- package/dist/es/components/wallets/Blik/index.js +1 -0
- package/dist/es/components/wallets/Blik/type.js +1 -0
- package/dist/es/components/wallets/Boost/Boost.js +183 -0
- package/dist/es/components/wallets/Boost/boost2.js +1 -0
- package/dist/es/components/wallets/Boost/index.js +1 -0
- package/dist/es/components/wallets/Boost/type.js +1 -0
- package/dist/es/components/wallets/GCash/GCash.js +74 -252
- package/dist/es/components/wallets/GrabPay/GrabPay.js +183 -0
- package/dist/es/components/wallets/GrabPay/grab-pay.js +1 -0
- package/dist/es/components/wallets/GrabPay/index.js +1 -0
- package/dist/es/components/wallets/GrabPay/type.js +1 -0
- package/dist/es/components/wallets/IDeal/IDeal.js +201 -0
- package/dist/es/components/wallets/IDeal/ideal2.js +1 -0
- package/dist/es/components/wallets/IDeal/index.js +1 -0
- package/dist/es/components/wallets/IDeal/type.js +1 -0
- package/dist/es/components/wallets/LinePay/LinePay.js +183 -0
- package/dist/es/components/wallets/LinePay/index.js +1 -0
- package/dist/es/components/wallets/LinePay/line-pay.js +1 -0
- package/dist/es/components/wallets/LinePay/type.js +1 -0
- package/dist/es/components/wallets/MayBankQRPay/MayBankQRPay.js +187 -0
- package/dist/es/components/wallets/MayBankQRPay/index.js +1 -0
- package/dist/es/components/wallets/MayBankQRPay/may-bank-qr-pay.js +1 -0
- package/dist/es/components/wallets/MayBankQRPay/type.js +1 -0
- package/dist/es/components/wallets/NinePay/NinePay.js +185 -0
- package/dist/es/components/wallets/NinePay/index.js +1 -0
- package/dist/es/components/wallets/NinePay/nine-pay.js +1 -0
- package/dist/es/components/wallets/NinePay/type.js +1 -0
- package/dist/es/components/wallets/OVO/OVO.js +200 -0
- package/dist/es/components/wallets/OVO/index.js +1 -0
- package/dist/es/components/wallets/OVO/ovo2.js +1 -0
- package/dist/es/components/wallets/OVO/type.js +1 -0
- package/dist/es/components/wallets/OpayWallet/OpayWallet.js +57 -218
- package/dist/es/components/wallets/P24/P24.js +198 -0
- package/dist/es/components/wallets/P24/index.js +1 -0
- package/dist/es/components/wallets/P24/p242.js +1 -0
- package/dist/es/components/wallets/P24/type.js +1 -0
- package/dist/es/components/wallets/PagaWallet/PagaWallet.js +57 -218
- package/dist/es/components/wallets/Paymaya/Paymaya.js +57 -221
- package/dist/es/components/wallets/PicPay/PicPay.js +64 -55
- package/dist/es/components/wallets/Pix/Pix.js +58 -56
- package/dist/es/components/wallets/ShopeePay/ShopeePay.js +185 -0
- package/dist/es/components/wallets/ShopeePay/index.js +1 -0
- package/dist/es/components/wallets/ShopeePay/shopee-pay.js +1 -0
- package/dist/es/components/wallets/ShopeePay/type.js +1 -0
- package/dist/es/components/wallets/Skrill/Skrill.js +200 -0
- package/dist/es/components/wallets/Skrill/index.js +1 -0
- package/dist/es/components/wallets/Skrill/skrill2.js +1 -0
- package/dist/es/components/wallets/Skrill/type.js +1 -0
- package/dist/es/components/wallets/TNGWallet/TNGWallet.js +185 -0
- package/dist/es/components/wallets/TNGWallet/index.js +1 -0
- package/dist/es/components/wallets/TNGWallet/tng-wallet.js +1 -0
- package/dist/es/components/wallets/TNGWallet/type.js +1 -0
- package/dist/es/components/wallets/Trustly/Trustly.js +226 -0
- package/dist/es/components/wallets/Trustly/index.js +1 -0
- package/dist/es/components/wallets/Trustly/trustly2.js +1 -0
- package/dist/es/components/wallets/Trustly/type.js +1 -0
- package/dist/es/components/wallets/Vietqr/Vietqr.js +73 -242
- package/dist/es/components/wallets/Zalopay/Zalopay.js +73 -242
- package/dist/es/components/wallets/index.js +14 -0
- package/dist/es/constant.js +48 -2
- package/dist/es/core/address.js +7 -6
- package/dist/es/core/checkout.js +93 -41
- package/dist/es/core/create-child.js +68 -0
- package/dist/es/core/environment.js +23 -1
- package/dist/es/core/error.js +15 -2
- package/dist/es/core/logger.js +106 -0
- package/dist/es/core/payment.js +65 -0
- package/dist/es/fe-logger.min.js +1 -0
- package/dist/es/hooks/useBaseWallet.js +280 -0
- package/dist/es/hooks/usePayState.js +37 -25
- package/dist/es/hooks/usePayment.js +1 -14
- package/dist/es/hooks/useRetry.js +50 -26
- package/dist/es/i18n/locales/de-DE.js +24 -0
- package/dist/es/i18n/locales/en-GB.js +24 -0
- package/dist/es/i18n/locales/es-ES.js +24 -0
- package/dist/es/i18n/locales/fr-FR.js +24 -0
- package/dist/es/i18n/locales/ja-JP.js +24 -0
- package/dist/es/i18n/locales/ko-KR.js +24 -0
- package/dist/es/i18n/locales/nl-NL.js +24 -0
- package/dist/es/i18n/locales/pt-PT.js +24 -0
- package/dist/es/i18n/locales/ru-RU.js +24 -0
- package/dist/es/i18n/locales/zh-CN.js +24 -0
- package/dist/es/i18n/locales/zh-HK.js +24 -0
- package/dist/es/i18n/locales/zh-TW.js +24 -0
- package/dist/es/index.js +23 -8
- package/dist/es/out/base-fraud-detection.js +4 -1
- package/dist/es/out/config.js +10 -4
- package/dist/es/out/fraud-detection.js +12 -13
- package/dist/es/out/worldpay-ddc-manager.js +7 -14
- package/dist/es/out/worldpay-ddc.js +7 -5
- package/dist/es/polyfill.js +166 -0
- package/dist/es/style.css +1 -1
- package/dist/es/types/event.js +12 -3
- package/dist/es/types/message.js +3 -0
- package/dist/es/utils/iframe.js +1 -1
- package/dist/es/utils/location.js +0 -8
- package/dist/es/utils/payment.js +12 -12
- package/dist/es/utils/redirect.js +4 -5
- package/dist/es/utils/system-info/is-ua-webview.js +1 -20
- package/dist/fe-logger.min.js +1 -0
- package/dist/polyfill.js +166 -0
- package/dist/style.css +1 -1
- package/dist/types/api/modules/index.d.ts +1 -0
- package/dist/types/api/modules/threeDS/index.d.ts +7 -0
- package/dist/types/api/modules/type.d.ts +2 -0
- package/dist/types/api/modules/wallet/index.d.ts +18 -0
- package/dist/types/api/utils/index.d.ts +1 -0
- package/dist/types/components/AddressField/index.d.ts +1 -0
- package/dist/types/components/AddressField/type.d.ts +17 -2
- package/dist/types/components/AddressField/utils.d.ts +22 -0
- package/dist/types/components/AliPay/type.d.ts +11 -15
- package/dist/types/components/ApplePay/type.d.ts +5 -28
- package/dist/types/components/CPFField/type.d.ts +1 -1
- package/dist/types/components/Card/type.d.ts +22 -23
- package/dist/types/components/CardExpireDateField/type.d.ts +1 -1
- package/dist/types/components/CardNo/type.d.ts +3 -2
- package/dist/types/components/CardNumberField/type.d.ts +1 -1
- package/dist/types/components/CardSecurityCodeField/type.d.ts +1 -1
- package/dist/types/components/CardSelector/type.d.ts +4 -4
- package/dist/types/components/DropIn/type.d.ts +10 -22
- package/dist/types/components/GooglePay/createGooglePay.d.ts +4 -4
- package/dist/types/components/GooglePay/type.d.ts +10 -14
- package/dist/types/components/PaymentButton/PaymentButton.d.ts +3 -0
- package/dist/types/components/PaymentButton/index.d.ts +2 -0
- package/dist/types/components/PaymentButton/type.d.ts +13 -0
- package/dist/types/components/RecurringTip/RecurringTip.d.ts +1 -1
- package/dist/types/components/SecuredFieldsProvider/type.d.ts +7 -1
- package/dist/types/components/SecuredIframe/HiddenIframe.d.ts +5 -0
- package/dist/types/components/ThreeDS/components/ThreeDSIframe/ThreeDSIframe.d.ts +0 -6
- package/dist/types/components/ThreeDS/components/ThreeDSIframe/type.d.ts +2 -0
- package/dist/types/components/WechatPay/type.d.ts +11 -15
- package/dist/types/components/business/BlikCodeField/BlikCodeField.d.ts +6 -0
- package/dist/types/components/business/BlikCodeField/index.d.ts +2 -0
- package/dist/types/components/business/BlikCodeField/type.d.ts +9 -0
- package/dist/types/components/business/BlikConfirmModal/BlikConfirmModal.d.ts +6 -0
- package/dist/types/components/business/BlikConfirmModal/index.d.ts +2 -0
- package/dist/types/components/business/BlikConfirmModal/type.d.ts +8 -0
- package/dist/types/components/business/NameField/NameField.d.ts +5 -0
- package/dist/types/components/business/NameField/index.d.ts +2 -0
- package/dist/types/components/business/NameField/type.d.ts +7 -0
- package/dist/types/components/business/PhoneField/PhoneField.d.ts +6 -0
- package/dist/types/components/business/PhoneField/config.d.ts +22 -0
- package/dist/types/components/business/PhoneField/index.d.ts +2 -0
- package/dist/types/components/business/PhoneField/type.d.ts +9 -0
- package/dist/types/components/business/SegmentedDigitInput/SegmentedDigitInput.d.ts +5 -0
- package/dist/types/components/business/SegmentedDigitInput/format.d.ts +5 -0
- package/dist/types/components/business/SegmentedDigitInput/index.d.ts +3 -0
- package/dist/types/components/business/SegmentedDigitInput/type.d.ts +13 -0
- package/dist/types/components/business/Tooltip/Tooltip.d.ts +11 -0
- package/dist/types/components/business/Tooltip/index.d.ts +1 -0
- package/dist/types/components/business/index.d.ts +6 -0
- package/dist/types/components/index.d.ts +0 -7
- package/dist/types/components/internal/CheckBox/type.d.ts +2 -1
- package/dist/types/components/internal/Form/type.d.ts +2 -1
- package/dist/types/components/internal/Select/type.d.ts +1 -1
- package/dist/types/components/internal/icons/IconArrowDown.d.ts +1 -1
- package/dist/types/components/internal/icons/IconBancontact.d.ts +2 -0
- package/dist/types/components/internal/icons/IconBlik.d.ts +2 -0
- package/dist/types/components/internal/icons/IconIdeal.d.ts +2 -0
- package/dist/types/components/internal/icons/IconOvo.d.ts +2 -0
- package/dist/types/components/internal/icons/IconP24.d.ts +2 -0
- package/dist/types/components/internal/icons/IconPhone.d.ts +2 -0
- package/dist/types/components/internal/icons/IconSkrill.d.ts +2 -0
- package/dist/types/components/internal/icons/IconTrustly.d.ts +2 -0
- package/dist/types/components/internal/icons/index.d.ts +8 -0
- package/dist/types/components/type.d.ts +0 -0
- package/dist/types/components/wallets/Bancontact/Bancontact.d.ts +15 -0
- package/dist/types/components/wallets/Bancontact/index.d.ts +2 -0
- package/dist/types/components/{GrabPay → wallets/Bancontact}/type.d.ts +8 -18
- package/dist/types/components/wallets/Blik/Blik.d.ts +15 -0
- package/dist/types/components/wallets/Blik/index.d.ts +2 -0
- package/dist/types/components/wallets/Blik/type.d.ts +29 -0
- package/dist/types/components/{Boost → wallets/Boost}/Boost.d.ts +9 -4
- package/dist/types/components/{Boost → wallets/Boost}/type.d.ts +3 -14
- package/dist/types/components/wallets/GCash/GCash.d.ts +5 -0
- package/dist/types/components/wallets/GCash/type.d.ts +3 -14
- package/dist/types/components/{GrabPay → wallets/GrabPay}/GrabPay.d.ts +4 -4
- package/dist/types/components/wallets/GrabPay/type.d.ts +17 -0
- package/dist/types/components/wallets/IDeal/IDeal.d.ts +15 -0
- package/dist/types/components/wallets/IDeal/index.d.ts +2 -0
- package/dist/types/components/wallets/IDeal/type.d.ts +29 -0
- package/dist/types/components/{LinePay → wallets/LinePay}/LinePay.d.ts +9 -4
- package/dist/types/components/{LinePay → wallets/LinePay}/type.d.ts +3 -14
- package/dist/types/components/wallets/MayBankQRPay/MayBankQRPay.d.ts +15 -0
- package/dist/types/components/{MayBankQRPay → wallets/MayBankQRPay}/type.d.ts +3 -14
- package/dist/types/components/wallets/NinePay/NinePay.d.ts +15 -0
- package/dist/types/components/{NinePay → wallets/NinePay}/type.d.ts +3 -14
- package/dist/types/components/wallets/OVO/OVO.d.ts +15 -0
- package/dist/types/components/wallets/OVO/index.d.ts +2 -0
- package/dist/types/components/wallets/OVO/type.d.ts +29 -0
- package/dist/types/components/wallets/OpayWallet/OpayWallet.d.ts +5 -0
- package/dist/types/components/wallets/OpayWallet/type.d.ts +4 -15
- package/dist/types/components/wallets/P24/P24.d.ts +15 -0
- package/dist/types/components/wallets/P24/index.d.ts +2 -0
- package/dist/types/components/wallets/P24/type.d.ts +29 -0
- package/dist/types/components/wallets/PagaWallet/PagaWallet.d.ts +5 -0
- package/dist/types/components/wallets/PagaWallet/type.d.ts +5 -16
- package/dist/types/components/wallets/Paymaya/Paymaya.d.ts +5 -0
- package/dist/types/components/wallets/Paymaya/type.d.ts +3 -14
- package/dist/types/components/wallets/PicPay/type.d.ts +5 -16
- package/dist/types/components/wallets/Pix/type.d.ts +5 -16
- package/dist/types/components/{ShopeePay → wallets/ShopeePay}/ShopeePay.d.ts +9 -4
- package/dist/types/components/{ShopeePay → wallets/ShopeePay}/type.d.ts +3 -14
- package/dist/types/components/wallets/Skrill/Skrill.d.ts +15 -0
- package/dist/types/components/wallets/Skrill/index.d.ts +2 -0
- package/dist/types/components/wallets/Skrill/type.d.ts +17 -0
- package/dist/types/components/{TNGWallet → wallets/TNGWallet}/TNGWallet.d.ts +9 -4
- package/dist/types/components/{TNGWallet → wallets/TNGWallet}/type.d.ts +3 -14
- package/dist/types/components/wallets/Trustly/Trustly.d.ts +15 -0
- package/dist/types/components/wallets/Trustly/index.d.ts +2 -0
- package/dist/types/components/wallets/Trustly/type.d.ts +21 -0
- package/dist/types/components/wallets/Vietqr/Vietqr.d.ts +5 -0
- package/dist/types/components/wallets/Vietqr/type.d.ts +3 -14
- package/dist/types/components/wallets/Zalopay/Zalopay.d.ts +5 -0
- package/dist/types/components/wallets/Zalopay/type.d.ts +3 -14
- package/dist/types/components/wallets/index.d.ts +14 -0
- package/dist/types/components/wallets/type.d.ts +18 -4
- package/dist/types/constant.d.ts +15 -1
- package/dist/types/core/address.d.ts +2 -5
- package/dist/types/core/checkout.d.ts +10 -10
- package/dist/types/core/create-child.d.ts +1 -0
- package/dist/types/core/environment.d.ts +5 -0
- package/dist/types/core/error.d.ts +9 -3
- package/dist/types/core/index.d.ts +2 -0
- package/dist/types/core/logger.d.ts +55 -0
- package/dist/types/core/payment.d.ts +21 -0
- package/dist/types/hooks/index.d.ts +1 -0
- package/dist/types/hooks/useBaseWallet.d.ts +54 -0
- package/dist/types/hooks/usePayState.d.ts +3 -1
- package/dist/types/hooks/useRetry.console-tests.d.ts +41 -0
- package/dist/types/hooks/useRetry.d.ts +22 -3
- package/dist/types/i18n/locales/de-DE.d.ts +23 -0
- package/dist/types/i18n/locales/en-GB.d.ts +23 -0
- package/dist/types/i18n/locales/es-ES.d.ts +23 -0
- package/dist/types/i18n/locales/fr-FR.d.ts +23 -0
- package/dist/types/i18n/locales/ja-JP.d.ts +23 -0
- package/dist/types/i18n/locales/ko-KR.d.ts +23 -0
- package/dist/types/i18n/locales/nl-NL.d.ts +23 -0
- package/dist/types/i18n/locales/pt-PT.d.ts +23 -0
- package/dist/types/i18n/locales/ru-RU.d.ts +23 -0
- package/dist/types/i18n/locales/zh-CN.d.ts +23 -0
- package/dist/types/i18n/locales/zh-HK.d.ts +23 -0
- package/dist/types/i18n/locales/zh-TW.d.ts +23 -0
- package/dist/types/out/base-fraud-detection.d.ts +1 -0
- package/dist/types/out/config.d.ts +6 -1
- package/dist/types/out/fraud-detection.d.ts +2 -8
- package/dist/types/out/types.d.ts +3 -1
- package/dist/types/out/worldpay-ddc-manager.d.ts +6 -7
- package/dist/types/types/event.d.ts +46 -13
- package/dist/types/types/index.d.ts +8 -37
- package/dist/types/types/message.d.ts +48 -7
- package/dist/types/types/payment.d.ts +63 -0
- package/dist/types/utils/app-payment.d.ts +7 -3
- package/dist/types/utils/behavior-tracker.d.ts +36 -0
- package/dist/types/utils/env.d.ts +37 -0
- package/dist/types/utils/iframe.d.ts +1 -1
- package/dist/types/utils/payment.d.ts +10 -10
- package/package.json +12 -5
- package/dist/es/components/Boost/index.js +0 -348
- package/dist/es/components/GrabPay/index.js +0 -348
- package/dist/es/components/LinePay/index.js +0 -348
- package/dist/es/components/MayBankQRPay/index.js +0 -354
- package/dist/es/components/NinePay/index.js +0 -348
- package/dist/es/components/ShopeePay/index.js +0 -348
- package/dist/es/components/TNGWallet/index.js +0 -348
- package/dist/types/components/MayBankQRPay/MayBankQRPay.d.ts +0 -10
- package/dist/types/components/NinePay/NinePay.d.ts +0 -10
- package/dist/types/utils/logger.d.ts +0 -14
- /package/dist/types/components/{Boost → wallets/Boost}/index.d.ts +0 -0
- /package/dist/types/components/{GrabPay → wallets/GrabPay}/index.d.ts +0 -0
- /package/dist/types/components/{LinePay → wallets/LinePay}/index.d.ts +0 -0
- /package/dist/types/components/{MayBankQRPay → wallets/MayBankQRPay}/index.d.ts +0 -0
- /package/dist/types/components/{NinePay → wallets/NinePay}/index.d.ts +0 -0
- /package/dist/types/components/{ShopeePay → wallets/ShopeePay}/index.d.ts +0 -0
- /package/dist/types/components/{TNGWallet → wallets/TNGWallet}/index.d.ts +0 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ButtonProps } from '../internal/Button';
|
|
2
|
+
import type { ReactNode } from 'preact/compat';
|
|
3
|
+
export type PaymentButtonStatus = 'unSubmit' | 'loading' | 'success';
|
|
4
|
+
export interface PaymentButtonProps extends Pick<ButtonProps, 'style' | 'className' | 'onClick'> {
|
|
5
|
+
/** 是否验证通过 */
|
|
6
|
+
verified?: boolean;
|
|
7
|
+
/** 按钮状态 */
|
|
8
|
+
status?: PaymentButtonStatus;
|
|
9
|
+
/** 是否禁用 */
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
/** 子组件 */
|
|
12
|
+
children?: ReactNode;
|
|
13
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import './recurring-tip.scss';
|
|
2
|
-
export declare function RecurringTip(): import("preact").JSX.Element;
|
|
2
|
+
export declare function RecurringTip(isCard?: boolean): import("preact").JSX.Element;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import type { ReactNode } from 'preact/compat';
|
|
2
2
|
import type { SessionMode } from '../../constant';
|
|
3
3
|
import type { I18n } from '../../i18n';
|
|
4
|
-
import type { EncryptCardMessage, InputStylesConfig, Message, MessageAction } from '../../types';
|
|
4
|
+
import type { EncryptCardMessage, EventData, InputStylesConfig, Message, MessageAction, SecurityIframeEventType } from '../../types';
|
|
5
5
|
import type { CheckoutPaymentParams } from '../../api';
|
|
6
|
+
import type { PayKKaCheckout } from '../../core';
|
|
6
7
|
export interface SecuredFieldsProviderProps extends SecuredFieldsCallback {
|
|
8
|
+
core?: PayKKaCheckout;
|
|
7
9
|
i18n: I18n;
|
|
8
10
|
supportedCardBrands?: string[];
|
|
9
11
|
sessionMode?: SessionMode;
|
|
@@ -12,6 +14,7 @@ export interface SecuredFieldsProviderProps extends SecuredFieldsCallback {
|
|
|
12
14
|
targetElement?: HTMLElement;
|
|
13
15
|
style?: InputStylesConfig;
|
|
14
16
|
checkoutId: string;
|
|
17
|
+
disabled?: boolean;
|
|
15
18
|
}
|
|
16
19
|
export interface SecuredFieldsProviderRef {
|
|
17
20
|
payment: (formData: CheckoutPaymentParams, extraParams?: Recordable) => void;
|
|
@@ -39,6 +42,8 @@ export interface SecuredFieldsCallback {
|
|
|
39
42
|
onCardEncrypted?: (data: Message<MessageAction.CARD_ENCRYPTED>) => void;
|
|
40
43
|
onCardEncryptionFailed?: (data: Message<MessageAction.CARD_ENCRYPTION_FAILED>) => void;
|
|
41
44
|
onValidated?: (data: Message<MessageAction.VALIDATED>) => void;
|
|
45
|
+
onEvent?: (eventType: SecurityIframeEventType, data: EventData<SecurityIframeEventType>) => void;
|
|
46
|
+
onHiddenIframeReady?: (data: Message<MessageAction.HIDDEN_IFRAME_READY>) => void;
|
|
42
47
|
}
|
|
43
48
|
export declare enum EFieldType {
|
|
44
49
|
CARD_NUMBER = "CARD_NUMBER",
|
|
@@ -53,6 +58,7 @@ export interface SecuredFieldConfig extends FieldIframeConfig, SecuredFieldsCall
|
|
|
53
58
|
iframeName: string;
|
|
54
59
|
iframeClassName: string;
|
|
55
60
|
hiddenIframe: HTMLIFrameElement;
|
|
61
|
+
onEvent?: (eventType: SecurityIframeEventType, data: EventData<SecurityIframeEventType>) => void;
|
|
56
62
|
}
|
|
57
63
|
export interface FieldIframeConfig {
|
|
58
64
|
fieldType: AllFieldType;
|
|
@@ -1,9 +1,3 @@
|
|
|
1
1
|
import type { ThreeDSIframeProps } from './type';
|
|
2
2
|
import './three-ds-iframe.scss';
|
|
3
|
-
/**
|
|
4
|
-
* 解析 checkoutId,为 window.name 的倒数第二个值
|
|
5
|
-
* 这是为了让里面的 iframe 最后跳转到我们的成功页时能拿到 checkoutId,防止页面通信错乱
|
|
6
|
-
* 如果不用 window.name 做间接传递,则需要在 iframe 加载完之后进行 postMessage 通信传递 checkoutId
|
|
7
|
-
* 我们这个 3ds 弹窗是 iframe1 嵌套 iframe2,外层传递 checkoutId 给 iframe1,iframe1 再传递给 iframe2,用 postMessage 需要四次交互,过于复杂
|
|
8
|
-
*/
|
|
9
3
|
export declare const ThreeDSIframe: (props: ThreeDSIframeProps) => import("preact").JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { PayKKaLogger } from '../../../../core';
|
|
1
2
|
export interface ThreeDSFormConfig {
|
|
2
3
|
action: string | null;
|
|
3
4
|
dataList: Array<{
|
|
@@ -8,6 +9,7 @@ export interface ThreeDSFormConfig {
|
|
|
8
9
|
export interface ThreeDSIframeProps {
|
|
9
10
|
config: ThreeDSFormConfig;
|
|
10
11
|
sessionId?: string;
|
|
12
|
+
logger?: PayKKaLogger;
|
|
11
13
|
}
|
|
12
14
|
export declare enum ThreeDSChannel {
|
|
13
15
|
ECP = "ECP",
|
|
@@ -1,26 +1,22 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
import type { FormValidateError } from '../internal/Form';
|
|
5
|
-
export interface WechatPayProps extends PayKKaCommonConfig {
|
|
1
|
+
import type { PayKKaCommonConfig } from '../../types';
|
|
2
|
+
import type { PaymentCommonProps } from '../../types/payment';
|
|
3
|
+
export interface WechatPayProps extends PayKKaCommonConfig, PaymentCommonProps {
|
|
6
4
|
/**
|
|
7
5
|
* 是否展示邮箱
|
|
8
|
-
*
|
|
9
|
-
* 若配置
|
|
6
|
+
* @remarks
|
|
7
|
+
* - 若配置 true 但创建收银台时已经传了,就展示禁用状态。
|
|
8
|
+
* - 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
9
|
+
* @defaultValue false
|
|
10
10
|
*/
|
|
11
11
|
showEmail?: boolean;
|
|
12
12
|
/**
|
|
13
13
|
* 是否展示邮箱
|
|
14
|
-
*
|
|
15
|
-
* 若配置
|
|
14
|
+
* @remarks
|
|
15
|
+
* - 若配置 true 但创建收银台时已经传了,还是展示,先不禁用。
|
|
16
|
+
* - 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
17
|
+
* @defaultValue false
|
|
16
18
|
*/
|
|
17
19
|
showAddress?: boolean;
|
|
18
|
-
onSubmit?: (formValidateError?: Recordable<FormValidateError[]>) => void;
|
|
19
|
-
onSuccess?: (data: PaymentInfo) => void;
|
|
20
|
-
onError?: (error: PayKKaError) => void;
|
|
21
|
-
onTimeout?: (source: 'retry' | 'channel') => void;
|
|
22
|
-
onExpired?: () => void;
|
|
23
|
-
onSubmitResponse?: (payRes: PayRes) => void;
|
|
24
20
|
onGetOpenId?: () => Promise<string>;
|
|
25
21
|
onCallWxPayBox?: (payInfo: any) => Promise<void>;
|
|
26
22
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { FormItemProps } from '../../internal/Form';
|
|
2
|
+
import type { InputProps } from '../../internal/Input';
|
|
3
|
+
export interface BlikCodeFieldProps extends Pick<FormItemProps, 'onValidationStatusChange' | 'className' | 'style' | 'label'>, Pick<InputProps, 'onInput' | 'disabled'> {
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
incompleteText?: string;
|
|
6
|
+
invalidText?: string;
|
|
7
|
+
/** 是否在标签文案右侧展示说明图标与悬停提示,默认 true */
|
|
8
|
+
showInfoTooltip?: boolean;
|
|
9
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { FormItemProps } from '../../internal/Form';
|
|
2
|
+
import type { InputProps } from '../../internal/Input';
|
|
3
|
+
export interface NameFieldProps extends Pick<FormItemProps, 'onValidationStatusChange' | 'className' | 'style'>, Pick<InputProps, 'onInput' | 'disabled' | 'maxLength'> {
|
|
4
|
+
label?: string;
|
|
5
|
+
placeholder?: string;
|
|
6
|
+
incompleteText?: string;
|
|
7
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { SelectOption } from '../../internal/Select';
|
|
2
|
+
export declare enum PHONE_TYPE {
|
|
3
|
+
/** 印尼 */
|
|
4
|
+
IDN = "IDN"
|
|
5
|
+
}
|
|
6
|
+
export interface PhoneConfig {
|
|
7
|
+
/** 区号 */
|
|
8
|
+
areaCode: string;
|
|
9
|
+
/** 占位符 */
|
|
10
|
+
placeholder: string;
|
|
11
|
+
/** 正则表达式 */
|
|
12
|
+
regex: RegExp;
|
|
13
|
+
/** 数字分组(每组数字长度,中间用空格分隔) */
|
|
14
|
+
digitGroups: number[];
|
|
15
|
+
/** 最大长度 */
|
|
16
|
+
maxDigits: number;
|
|
17
|
+
}
|
|
18
|
+
export declare const phoneType2ConfigMap: Record<PHONE_TYPE, PhoneConfig>;
|
|
19
|
+
export declare const phoneList: (SelectOption & PhoneConfig)[];
|
|
20
|
+
/** 手机号展示格式化(空格分隔),内部与 SegmentedDigitInput 共用逻辑 */
|
|
21
|
+
export declare const formatPhoneDigits: (rawDigits: string, groups: number[], maxDigits: number) => string;
|
|
22
|
+
export declare const phoneConfigByAreaCode: (areaCode: string | number) => (SelectOption & PhoneConfig) | undefined;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { FormItemProps } from '../../internal/Form';
|
|
2
|
+
import type { InputProps } from '../../internal/Input';
|
|
3
|
+
export interface PhoneFieldProps extends Pick<FormItemProps, 'onValidationStatusChange' | 'className' | 'style' | 'label'>, Pick<InputProps, 'onInput' | 'disabled'> {
|
|
4
|
+
areaCode?: string;
|
|
5
|
+
areaCodeDisabled?: boolean;
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
incompleteText?: string;
|
|
8
|
+
invalidText?: string;
|
|
9
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 将连续数字按分组插入分隔符(如 [3,4,4] + 空格 => 812 3456 7890)
|
|
3
|
+
*/
|
|
4
|
+
export declare function formatDigitsByGroups(rawDigits: string, groups: number[], maxDigits: number, separator?: string): string;
|
|
5
|
+
export declare function maxFormattedLength(groups: number[], maxDigits: number, separator?: string): number;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { TargetedEvent } from 'preact/compat';
|
|
2
|
+
import type { InputProps } from '../../internal/Input';
|
|
3
|
+
export interface SegmentedDigitInputProps extends Pick<InputProps, 'placeholder' | 'disabled' | 'inputClassName' | 'style' | 'onFocus' | 'onBlur' | 'leftIcon' | 'rightIcon'> {
|
|
4
|
+
/** 展示层受控值(含分隔符) */
|
|
5
|
+
value: string;
|
|
6
|
+
/** 每组连续数字位数,分隔符插在组与组之间,如 [3,4,4] */
|
|
7
|
+
digitGroups: number[];
|
|
8
|
+
/** 最多输入的数字个数(不含分隔符) */
|
|
9
|
+
maxDigits: number;
|
|
10
|
+
/** 组间分隔符,默认空格 */
|
|
11
|
+
separator?: string;
|
|
12
|
+
onInput?: (event: TargetedEvent<HTMLInputElement, InputEvent>) => void;
|
|
13
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ReactNode } from 'preact/compat';
|
|
2
|
+
import './tooltip.scss';
|
|
3
|
+
export interface TooltipProps {
|
|
4
|
+
/** 悬停展示的文案 */
|
|
5
|
+
content: string;
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* 最简单的悬停气泡:纯 CSS :hover,无 Portal
|
|
10
|
+
*/
|
|
11
|
+
export declare const Tooltip: (props: TooltipProps) => import("preact/compat").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Tooltip';
|
|
@@ -18,11 +18,4 @@ export * from './CardIBANField';
|
|
|
18
18
|
export * from './EncryptedCard';
|
|
19
19
|
export * from './CombinedCardInfo';
|
|
20
20
|
export * from './DropIn';
|
|
21
|
-
export * from './Boost';
|
|
22
|
-
export * from './LinePay';
|
|
23
|
-
export * from './MayBankQRPay';
|
|
24
|
-
export * from './NinePay';
|
|
25
|
-
export * from './GrabPay';
|
|
26
|
-
export * from './TNGWallet';
|
|
27
|
-
export * from './ShopeePay';
|
|
28
21
|
export * from './wallets';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import type { CustomAttributes } from
|
|
1
|
+
import type { CustomAttributes } from '../../../types';
|
|
2
2
|
export interface CheckBoxProps extends CustomAttributes<HTMLDivElement> {
|
|
3
3
|
checked?: boolean;
|
|
4
4
|
label?: string;
|
|
5
|
+
disabled?: boolean;
|
|
5
6
|
onChange?: (checked: boolean) => void;
|
|
6
7
|
}
|
|
@@ -31,7 +31,8 @@ export interface FormProps {
|
|
|
31
31
|
form: Recordable;
|
|
32
32
|
}
|
|
33
33
|
export interface FormItemProps extends CustomAttributes<HTMLDivElement> {
|
|
34
|
-
|
|
34
|
+
/** 支持字符串或自定义节点(如图标、插槽) */
|
|
35
|
+
label?: ReactNode;
|
|
35
36
|
path?: string;
|
|
36
37
|
rule?: FormRule;
|
|
37
38
|
children?: ReactNode;
|
|
@@ -9,7 +9,7 @@ export type SelectOption = BaseSelectOption<string | number>;
|
|
|
9
9
|
export interface SelectRef {
|
|
10
10
|
blur: () => void;
|
|
11
11
|
}
|
|
12
|
-
export interface SelectProps extends CustomAttributes<HTMLInputElement, 'onBlur' | 'onFocus' | 'placeholder'> {
|
|
12
|
+
export interface SelectProps extends CustomAttributes<HTMLInputElement, 'onBlur' | 'onFocus' | 'placeholder' | 'disabled'> {
|
|
13
13
|
/** 选中值 */
|
|
14
14
|
value?: string | number;
|
|
15
15
|
/** 校验状态 */
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { IconProps } from './type';
|
|
2
|
-
export declare
|
|
2
|
+
export declare const IconArrowDown: ({ size, style, className }: IconProps) => import("preact").JSX.Element;
|
|
@@ -40,3 +40,11 @@ export * from './IconPix';
|
|
|
40
40
|
export * from './IconPicPay';
|
|
41
41
|
export * from './IconOpayWallet';
|
|
42
42
|
export * from './IconPagaWallet';
|
|
43
|
+
export * from './IconP24';
|
|
44
|
+
export * from './IconTrustly';
|
|
45
|
+
export * from './IconBlik';
|
|
46
|
+
export * from './IconOvo';
|
|
47
|
+
export * from './IconSkrill';
|
|
48
|
+
export * from './IconBancontact';
|
|
49
|
+
export * from './IconIdeal';
|
|
50
|
+
export * from './IconPhone';
|
|
File without changes
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import './bancontact.scss';
|
|
2
|
+
import type { BancontactProps, BancontactRef } from './type';
|
|
3
|
+
/**
|
|
4
|
+
* Bancontact 比利时支付方式
|
|
5
|
+
* - 表单:邮箱,姓名
|
|
6
|
+
* - 支付:跳转至银行页面完成支付
|
|
7
|
+
*/
|
|
8
|
+
export declare const Bancontact: import("preact").FunctionalComponent<import("preact/compat").PropsWithoutRef<BancontactProps & import("../../../types").PayKKaCommonConfig & {
|
|
9
|
+
session: import("../../../core").Session;
|
|
10
|
+
core: import("../../../core").PayKKaCheckout;
|
|
11
|
+
threeDSFrame?: import("../../../types").ThreeDSFrameConfig | undefined;
|
|
12
|
+
isDropIn?: boolean | undefined;
|
|
13
|
+
}> & {
|
|
14
|
+
ref?: import("preact").Ref<BancontactRef> | undefined;
|
|
15
|
+
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type {
|
|
4
|
-
export interface
|
|
1
|
+
import type { PayKKaCommonConfig } from '../../../types';
|
|
2
|
+
import type { PaymentCommonProps } from '../../../types/payment';
|
|
3
|
+
import type { WalletCustomProps, WalletRedirectProps } from '../type';
|
|
4
|
+
export interface BancontactProps extends PayKKaCommonConfig, WalletRedirectProps, WalletCustomProps, PaymentCommonProps {
|
|
5
5
|
/**
|
|
6
6
|
* 是否展示邮箱
|
|
7
7
|
* 若配置 true 但创建收银台时已经传了,就展示禁用状态。
|
|
@@ -9,31 +9,21 @@ export interface GrabPayProps extends PayKKaCommonConfig {
|
|
|
9
9
|
*/
|
|
10
10
|
showEmail?: boolean;
|
|
11
11
|
/**
|
|
12
|
-
*
|
|
12
|
+
* 是否展示地址
|
|
13
13
|
* 若配置 true 但创建收银台时已经传了,还是展示,先不禁用。
|
|
14
14
|
* 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
15
15
|
*/
|
|
16
16
|
showAddress?: boolean;
|
|
17
|
-
/** 提交表单时触发 */
|
|
18
|
-
onSubmit?: (formValidateError?: Recordable<FormValidateError[]>) => void;
|
|
19
|
-
/** 支付成功后触发 */
|
|
20
|
-
onSuccess?: (data: PaymentInfo) => void;
|
|
21
|
-
/** 支付失败时触发 */
|
|
22
|
-
onError?: (error: PayKKaError) => void;
|
|
23
|
-
/** 支付超时时触发 */
|
|
24
|
-
onTimeout?: () => void;
|
|
25
|
-
/** 收银台已过期时触发 */
|
|
26
|
-
onExpired?: () => void;
|
|
27
17
|
}
|
|
28
|
-
export interface
|
|
18
|
+
export interface BancontactRef {
|
|
29
19
|
/** 停止轮询支付结果 */
|
|
30
20
|
stopRetry: () => void;
|
|
31
21
|
/** 开始轮询支付结果 */
|
|
32
22
|
startRetry: (timeout?: number) => void;
|
|
33
|
-
/** 更新表单地址 */
|
|
34
|
-
updateAddress: () => void;
|
|
35
23
|
/** 更新表单邮箱 */
|
|
36
24
|
updateEmail: () => void;
|
|
37
25
|
/** 不展示支付按钮时,可调用该方法进行支付 */
|
|
38
26
|
payment: () => void;
|
|
27
|
+
/** 更新表单地址 */
|
|
28
|
+
updateAddress: () => void;
|
|
39
29
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import './blik.scss';
|
|
2
|
+
import type { BlikProps, BlikRef } from './type';
|
|
3
|
+
/**
|
|
4
|
+
* BLIK 波兰支付方式
|
|
5
|
+
* - 表单:邮箱,姓名,BLIK 验证码
|
|
6
|
+
* - 支付:展示弹窗并轮询,等待用户在银行 app 操作
|
|
7
|
+
*/
|
|
8
|
+
export declare const Blik: import("preact").FunctionalComponent<import("preact/compat").PropsWithoutRef<BlikProps & import("../../../types").PayKKaCommonConfig & {
|
|
9
|
+
session: import("../../../core").Session;
|
|
10
|
+
core: import("../../../core").PayKKaCheckout;
|
|
11
|
+
threeDSFrame?: import("../../../types").ThreeDSFrameConfig | undefined;
|
|
12
|
+
isDropIn?: boolean | undefined;
|
|
13
|
+
}> & {
|
|
14
|
+
ref?: import("preact").Ref<BlikRef> | undefined;
|
|
15
|
+
}>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { PayKKaCommonConfig } from '../../../types';
|
|
2
|
+
import type { PaymentCommonProps } from '../../../types/payment';
|
|
3
|
+
import type { WalletCustomProps } from '../type';
|
|
4
|
+
export interface BlikProps extends PayKKaCommonConfig, WalletCustomProps, PaymentCommonProps {
|
|
5
|
+
/**
|
|
6
|
+
* 是否展示邮箱
|
|
7
|
+
* 若配置 true 但创建收银台时已经传了,就展示禁用状态。
|
|
8
|
+
* 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
9
|
+
*/
|
|
10
|
+
showEmail?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* 是否展示地址
|
|
13
|
+
* 若配置 true 但创建收银台时已经传了,还是展示,先不禁用。
|
|
14
|
+
* 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
15
|
+
*/
|
|
16
|
+
showAddress?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface BlikRef {
|
|
19
|
+
/** 停止轮询支付结果 */
|
|
20
|
+
stopRetry: () => void;
|
|
21
|
+
/** 开始轮询支付结果 */
|
|
22
|
+
startRetry: (timeout?: number) => void;
|
|
23
|
+
/** 更新表单邮箱 */
|
|
24
|
+
updateEmail: () => void;
|
|
25
|
+
/** 更新表单地址 */
|
|
26
|
+
updateAddress: () => void;
|
|
27
|
+
/** 不展示支付按钮时,可调用该方法进行支付 */
|
|
28
|
+
payment: () => void;
|
|
29
|
+
}
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
import type { BoostProps } from './type';
|
|
2
2
|
import type { BoostRef } from './type';
|
|
3
3
|
import './boost.scss';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
/**
|
|
5
|
+
* Boost 支付方式
|
|
6
|
+
* - 表单:邮箱,地址
|
|
7
|
+
* - 支付:跳转至 Boost 页面完成支付
|
|
8
|
+
*/
|
|
9
|
+
export declare const Boost: import("preact").FunctionalComponent<import("preact/compat").PropsWithoutRef<BoostProps & import("../../../types").PayKKaCommonConfig & {
|
|
10
|
+
session: import("../../../core").Session;
|
|
11
|
+
core: import("../../../core").PayKKaCheckout;
|
|
12
|
+
threeDSFrame?: import("../../../types").ThreeDSFrameConfig | undefined;
|
|
8
13
|
isDropIn?: boolean | undefined;
|
|
9
14
|
}> & {
|
|
10
15
|
ref?: import("preact").Ref<BoostRef> | undefined;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
export interface BoostProps {
|
|
1
|
+
import type { PayKKaCommonConfig } from '../../../types';
|
|
2
|
+
import type { PaymentCommonProps } from '../../../types/payment';
|
|
3
|
+
export interface BoostProps extends PayKKaCommonConfig, PaymentCommonProps {
|
|
5
4
|
/**
|
|
6
5
|
* 是否展示邮箱
|
|
7
6
|
* 若配置 true 但创建收银台时已经传了,就展示禁用状态。
|
|
@@ -14,16 +13,6 @@ export interface BoostProps {
|
|
|
14
13
|
* 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
15
14
|
*/
|
|
16
15
|
showAddress?: boolean;
|
|
17
|
-
/** 提交表单时触发 */
|
|
18
|
-
onSubmit?: (formValidateError?: Recordable<FormValidateError[]>) => void;
|
|
19
|
-
/** 支付成功后触发 */
|
|
20
|
-
onSuccess?: (data: PaymentInfo) => void;
|
|
21
|
-
/** 支付失败时触发 */
|
|
22
|
-
onError?: (error: PayKKaError) => void;
|
|
23
|
-
/** 支付超时时触发 */
|
|
24
|
-
onTimeout?: () => void;
|
|
25
|
-
/** 收银台已过期时触发 */
|
|
26
|
-
onExpired?: () => void;
|
|
27
16
|
}
|
|
28
17
|
export interface BoostRef {
|
|
29
18
|
/** 停止轮询支付结果 */
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import type { GCashProps, GCashRef } from './type';
|
|
2
2
|
import './g-cash.scss';
|
|
3
|
+
/**
|
|
4
|
+
* GCash 支付方式
|
|
5
|
+
* - 表单:邮箱,地址
|
|
6
|
+
* - 支付:移动端跳转,PC 端展示二维码弹窗
|
|
7
|
+
*/
|
|
3
8
|
export declare const GCash: import("preact").FunctionalComponent<import("preact/compat").PropsWithoutRef<GCashProps & import("../../../types").PayKKaCommonConfig & {
|
|
4
9
|
session: import("../../../core").Session;
|
|
5
10
|
core: import("../../../core").PayKKaCheckout;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
export interface GCashProps extends PayKKaCommonConfig {
|
|
1
|
+
import type { PayKKaCommonConfig } from '../../../types';
|
|
2
|
+
import type { PaymentCommonProps } from '../../../types/payment';
|
|
3
|
+
export interface GCashProps extends PayKKaCommonConfig, PaymentCommonProps {
|
|
5
4
|
/**
|
|
6
5
|
* 是否展示邮箱
|
|
7
6
|
* 若配置 true 但创建收银台时已经传了,就展示禁用状态。
|
|
@@ -14,16 +13,6 @@ export interface GCashProps extends PayKKaCommonConfig {
|
|
|
14
13
|
* 若配置 false 但创建收银台时未传,依旧会展示该输入框。
|
|
15
14
|
*/
|
|
16
15
|
showAddress?: boolean;
|
|
17
|
-
/** 提交表单时触发 */
|
|
18
|
-
onSubmit?: (formValidateError?: Recordable<FormValidateError[]>) => void;
|
|
19
|
-
/** 支付成功后触发 */
|
|
20
|
-
onSuccess?: (data: PaymentInfo) => void;
|
|
21
|
-
/** 支付失败时触发 */
|
|
22
|
-
onError?: (error: PayKKaError) => void;
|
|
23
|
-
/** 支付超时时触发 */
|
|
24
|
-
onTimeout?: () => void;
|
|
25
|
-
/** 收银台已过期时触发 */
|
|
26
|
-
onExpired?: () => void;
|
|
27
16
|
}
|
|
28
17
|
export interface GCashRef {
|
|
29
18
|
/** 停止轮询支付结果 */
|