@paydock/client-sdk 1.106.1 → 1.107.0-beta
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/README.md +194 -162
- package/bundles/index.cjs +10483 -0
- package/bundles/index.cjs.d.ts +3206 -0
- package/bundles/index.cjs.map +1 -0
- package/bundles/index.mjs +10451 -0
- package/bundles/index.mjs.d.ts +3206 -0
- package/bundles/index.mjs.map +1 -0
- package/{lib → bundles/types}/api/api-base.d.ts +2 -1
- package/bundles/types/api/api-base.d.ts.map +1 -0
- package/{lib → bundles/types}/api/api-charge-internal.d.ts +1 -0
- package/bundles/types/api/api-charge-internal.d.ts.map +1 -0
- package/{lib → bundles/types}/api/api-charge.d.ts +1 -0
- package/bundles/types/api/api-charge.d.ts.map +1 -0
- package/{lib → bundles/types}/api/api-internal.d.ts +1 -0
- package/bundles/types/api/api-internal.d.ts.map +1 -0
- package/{lib → bundles/types}/api/api-service-internal.d.ts +2 -1
- package/bundles/types/api/api-service-internal.d.ts.map +1 -0
- package/{lib → bundles/types}/api/api.d.ts +1 -0
- package/bundles/types/api/api.d.ts.map +1 -0
- package/bundles/types/api/index.d.ts +2 -0
- package/bundles/types/api/index.d.ts.map +1 -0
- package/{lib → bundles/types}/canvas-3ds/canvas-3ds.d.ts +1 -0
- package/bundles/types/canvas-3ds/canvas-3ds.d.ts.map +1 -0
- package/{lib → bundles/types}/canvas-3ds/index.d.ts +1 -0
- package/bundles/types/canvas-3ds/index.d.ts.map +1 -0
- package/{lib → bundles/types}/canvas-3ds/services/gpayments-service.d.ts +1 -0
- package/bundles/types/canvas-3ds/services/gpayments-service.d.ts.map +1 -0
- package/{lib → bundles/types}/canvas-3ds/services/index.d.ts +1 -0
- package/bundles/types/canvas-3ds/services/index.d.ts.map +1 -0
- package/{lib → bundles/types}/canvas-3ds/services/standalone3ds-service.d.ts +1 -0
- package/bundles/types/canvas-3ds/services/standalone3ds-service.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/afterpay/afterpay-checkout-button.d.ts +1 -0
- package/bundles/types/checkout-button/afterpay/afterpay-checkout-button.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/afterpay/afterpay.runner.d.ts +1 -0
- package/bundles/types/checkout-button/afterpay/afterpay.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/checkout-button.d.ts +1 -0
- package/bundles/types/checkout-button/checkout-button.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/checkout-button.interface.d.ts +1 -0
- package/bundles/types/checkout-button/checkout-button.interface.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/checkout-contextual-handler.d.ts +1 -0
- package/bundles/types/checkout-button/checkout-contextual-handler.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/index.d.ts +2 -1
- package/bundles/types/checkout-button/index.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/paypal/paypal-checkout-button.d.ts +1 -0
- package/bundles/types/checkout-button/paypal/paypal-checkout-button.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/paypal/paypal.runner.d.ts +1 -0
- package/bundles/types/checkout-button/paypal/paypal.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/runner/base.runner.d.ts +4 -3
- package/bundles/types/checkout-button/runner/base.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/runner/contextual.runner.d.ts +2 -1
- package/bundles/types/checkout-button/runner/contextual.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/runner/index.d.ts +1 -0
- package/bundles/types/checkout-button/runner/index.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/runner/popup.runner.d.ts +2 -1
- package/bundles/types/checkout-button/runner/popup.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/runner/redirect.runner.d.ts +2 -1
- package/bundles/types/checkout-button/runner/redirect.runner.d.ts.map +1 -0
- package/bundles/types/checkout-button/zipmoney/index.d.ts +4 -0
- package/bundles/types/checkout-button/zipmoney/index.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney-checkout-button.d.ts +1 -0
- package/bundles/types/checkout-button/zipmoney/zipmoney-checkout-button.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney-contextual.runner.d.ts +2 -1
- package/bundles/types/checkout-button/zipmoney/zipmoney-contextual.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney-redirect.runner.d.ts +2 -1
- package/bundles/types/checkout-button/zipmoney/zipmoney-redirect.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney.config.d.ts +1 -0
- package/bundles/types/checkout-button/zipmoney/zipmoney.config.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney.runner.d.ts +2 -1
- package/bundles/types/checkout-button/zipmoney/zipmoney.runner.d.ts.map +1 -0
- package/{lib → bundles/types}/checkout-button/zipmoney/zipmoney.types.d.ts +1 -0
- package/bundles/types/checkout-button/zipmoney/zipmoney.types.d.ts.map +1 -0
- package/{lib → bundles/types}/components/ability-guard.d.ts +1 -0
- package/bundles/types/components/ability-guard.d.ts.map +1 -0
- package/{lib → bundles/types}/components/background.d.ts +1 -0
- package/bundles/types/components/background.d.ts.map +1 -0
- package/{lib → bundles/types}/components/container.d.ts +1 -0
- package/bundles/types/components/container.d.ts.map +1 -0
- package/{lib → bundles/types}/components/dispatcher.d.ts +2 -1
- package/bundles/types/components/dispatcher.d.ts.map +1 -0
- package/{lib → bundles/types}/components/element-style.d.ts +2 -1
- package/bundles/types/components/element-style.d.ts.map +1 -0
- package/{lib → bundles/types}/components/flypay-iframe-event.d.ts +1 -0
- package/bundles/types/components/flypay-iframe-event.d.ts.map +1 -0
- package/{lib/components/form-Interceptor.d.ts → bundles/types/components/form-interceptor.d.ts} +1 -0
- package/bundles/types/components/form-interceptor.d.ts.map +1 -0
- package/{lib → bundles/types}/components/http-core.d.ts +1 -0
- package/bundles/types/components/http-core.d.ts.map +1 -0
- package/{lib → bundles/types}/components/iframe-event.d.ts +2 -0
- package/bundles/types/components/iframe-event.d.ts.map +1 -0
- package/{lib → bundles/types}/components/iframe.d.ts +1 -0
- package/bundles/types/components/iframe.d.ts.map +1 -0
- package/{lib → bundles/types}/components/link.d.ts +2 -1
- package/bundles/types/components/link.d.ts.map +1 -0
- package/{lib → bundles/types}/components/loader.d.ts +1 -0
- package/bundles/types/components/loader.d.ts.map +1 -0
- package/{lib → bundles/types}/components/param.d.ts +8 -7
- package/bundles/types/components/param.d.ts.map +1 -0
- package/{lib → bundles/types}/components/popup.d.ts +1 -0
- package/bundles/types/components/popup.d.ts.map +1 -0
- package/{lib → bundles/types}/components/storage-dispatcher.d.ts +1 -0
- package/bundles/types/components/storage-dispatcher.d.ts.map +1 -0
- package/{lib → bundles/types}/components/trigger.d.ts +1 -0
- package/bundles/types/components/trigger.d.ts.map +1 -0
- package/{lib → bundles/types}/components/vault-display-iframe-event.d.ts +1 -0
- package/bundles/types/components/vault-display-iframe-event.d.ts.map +1 -0
- package/{lib → bundles/types}/components/wallet-background.d.ts +3 -1
- package/bundles/types/components/wallet-background.d.ts.map +1 -0
- package/{lib → bundles/types}/components/wallet-trigger.d.ts +1 -0
- package/bundles/types/components/wallet-trigger.d.ts.map +1 -0
- package/bundles/types/configs/env/environment.cba.d.ts +29 -0
- package/bundles/types/configs/env/environment.cba.d.ts.map +1 -0
- package/bundles/types/configs/env/environment.interface.d.ts +12 -0
- package/bundles/types/configs/env/environment.interface.d.ts.map +1 -0
- package/{lib/configs/env/env.d.ts → bundles/types/configs/env/environment.paydock.d.ts} +5 -8
- package/bundles/types/configs/env/environment.paydock.d.ts.map +1 -0
- package/bundles/types/configs/env/index.d.ts +3 -0
- package/bundles/types/configs/env/index.d.ts.map +1 -0
- package/{lib → bundles/types}/configs/sdk.d.ts +3 -2
- package/bundles/types/configs/sdk.d.ts.map +1 -0
- package/{lib → bundles/types}/constants/validators.d.ts +3 -2
- package/bundles/types/constants/validators.d.ts.map +1 -0
- package/{lib → bundles/types}/external-checkout/builder.d.ts +1 -0
- package/bundles/types/external-checkout/builder.d.ts.map +1 -0
- package/{lib → bundles/types}/external-checkout/checker.d.ts +1 -0
- package/bundles/types/external-checkout/checker.d.ts.map +1 -0
- package/bundles/types/external-checkout/index.d.ts +3 -0
- package/bundles/types/external-checkout/index.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/access-token.d.ts +1 -0
- package/bundles/types/helper/access-token.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/browser.d.ts +1 -0
- package/bundles/types/helper/browser.d.ts.map +1 -0
- package/bundles/types/helper/element-id.d.ts +5 -0
- package/bundles/types/helper/element-id.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/event-emitter.d.ts +1 -0
- package/bundles/types/helper/event-emitter.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/event.d.ts +1 -0
- package/bundles/types/helper/event.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/ms.d.ts +1 -0
- package/bundles/types/helper/ms.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/object.d.ts +1 -0
- package/bundles/types/helper/object.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/url.d.ts +1 -0
- package/bundles/types/helper/url.d.ts.map +1 -0
- package/{lib → bundles/types}/helper/uuid.d.ts +1 -0
- package/bundles/types/helper/uuid.d.ts.map +1 -0
- package/bundles/types/index-cba.d.ts +13 -0
- package/bundles/types/index-cba.d.ts.map +1 -0
- package/bundles/types/index.d.ts +14 -0
- package/bundles/types/index.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source/builder.d.ts +1 -0
- package/bundles/types/payment-source/builder.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source/index.d.ts +1 -0
- package/bundles/types/payment-source/index.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source-widget/html-payment-source-widget.d.ts +1 -0
- package/bundles/types/payment-source-widget/html-payment-source-widget.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source-widget/index.d.ts +1 -0
- package/bundles/types/payment-source-widget/index.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source-widget/interfaces.d.ts +1 -0
- package/bundles/types/payment-source-widget/interfaces.d.ts.map +1 -0
- package/{lib → bundles/types}/payment-source-widget/payment-source-widget.d.ts +1 -0
- package/bundles/types/payment-source-widget/payment-source-widget.d.ts.map +1 -0
- package/bundles/types/secure-remote-commerce/click-to-pay-secure-remote-commerce.d.ts +31 -0
- package/bundles/types/secure-remote-commerce/click-to-pay-secure-remote-commerce.d.ts.map +1 -0
- package/{lib → bundles/types}/secure-remote-commerce/index.d.ts +5 -4
- package/bundles/types/secure-remote-commerce/index.d.ts.map +1 -0
- package/{lib → bundles/types}/secure-remote-commerce/interfaces.d.ts +10 -9
- package/bundles/types/secure-remote-commerce/interfaces.d.ts.map +1 -0
- package/bundles/types/secure-remote-commerce/providers/mastercard-src/index.d.ts +2 -0
- package/bundles/types/secure-remote-commerce/providers/mastercard-src/index.d.ts.map +1 -0
- package/{lib → bundles/types}/secure-remote-commerce/providers/mastercard-src/mastercard-src.d.ts +5 -4
- package/bundles/types/secure-remote-commerce/providers/mastercard-src/mastercard-src.d.ts.map +1 -0
- package/{lib → bundles/types}/secure-remote-commerce/providers/src-provider.d.ts +1 -0
- package/bundles/types/secure-remote-commerce/providers/src-provider.d.ts.map +1 -0
- package/{lib → bundles/types}/secure-remote-commerce/secure-remote-commerce.d.ts +4 -3
- package/bundles/types/secure-remote-commerce/secure-remote-commerce.d.ts.map +1 -0
- package/{lib → bundles/types}/vault-display-widget/index.d.ts +1 -0
- package/bundles/types/vault-display-widget/index.d.ts.map +1 -0
- package/{lib → bundles/types}/vault-display-widget/vault-display-widget.d.ts +1 -0
- package/bundles/types/vault-display-widget/vault-display-widget.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/afterpay.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/afterpay.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/apple.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/apple.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/flypay-v2.wallet-service.d.ts +2 -1
- package/bundles/types/wallet-buttons/flypay-v2.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/flypay.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/flypay.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/google.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/google.wallet-service.d.ts.map +1 -0
- package/bundles/types/wallet-buttons/helpers/flypay-v2.helper.d.ts +6 -0
- package/bundles/types/wallet-buttons/helpers/flypay-v2.helper.d.ts.map +1 -0
- package/bundles/types/wallet-buttons/index-cba.d.ts +2 -0
- package/bundles/types/wallet-buttons/index-cba.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/index.d.ts +1 -0
- package/bundles/types/wallet-buttons/index.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/interfaces.d.ts +1 -0
- package/bundles/types/wallet-buttons/interfaces.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/mastercard.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/mastercard.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/paypal.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/paypal.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/stripe.wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/stripe.wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/wallet-buttons.d.ts +1 -0
- package/bundles/types/wallet-buttons/wallet-buttons.d.ts.map +1 -0
- package/bundles/types/wallet-buttons/wallet-cba-buttons.d.ts +330 -0
- package/bundles/types/wallet-buttons/wallet-cba-buttons.d.ts.map +1 -0
- package/{lib → bundles/types}/wallet-buttons/wallet-service.d.ts +1 -0
- package/bundles/types/wallet-buttons/wallet-service.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/configuration.d.ts +2 -1
- package/bundles/types/widget/configuration.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/html-multi-widget.d.ts +4 -3
- package/bundles/types/widget/html-multi-widget.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/html-widget.d.ts +1 -0
- package/bundles/types/widget/html-widget.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/index.d.ts +2 -1
- package/bundles/types/widget/index.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/meta.d.ts +1 -0
- package/bundles/types/widget/meta.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/multi-widget.d.ts +2 -1
- package/bundles/types/widget/multi-widget.d.ts.map +1 -0
- package/{lib → bundles/types}/widget/style.d.ts +1 -0
- package/bundles/types/widget/style.d.ts.map +1 -0
- package/bundles/widget.umd.js +6755 -6894
- package/bundles/widget.umd.js.d.ts +3206 -0
- package/bundles/widget.umd.js.map +1 -0
- package/bundles/widget.umd.js.min.d.ts +3206 -0
- package/bundles/widget.umd.min.js +2 -1
- package/bundles/widget.umd.min.js.map +1 -0
- package/docs/api-canvas3ds.md +158 -0
- package/docs/api-checkout-button.md +912 -0
- package/docs/api-examples.md +65 -0
- package/docs/api-ps-widget.md +585 -0
- package/docs/api-vault-display.md +94 -0
- package/docs/api-widget.md +2499 -0
- package/docs/api-wrapper.md +78 -0
- package/docs/canvas3ds-examples.md +242 -0
- package/docs/cba-header.md +13 -0
- package/docs/cba-license.md +2 -0
- package/docs/checkout-examples.md +248 -0
- package/docs/click-to-pay-examples.md +231 -0
- package/docs/click-to-pay.md +336 -0
- package/docs/header.md +15 -0
- package/docs/html/layout.html +78 -0
- package/docs/html/marked.js +23 -0
- package/docs/html/style.css +365 -0
- package/docs/install/npm.content.md +16 -0
- package/docs/install/npm.example.md +24 -0
- package/docs/install/umd.content.md +20 -0
- package/docs/install/umd.example.md +6 -0
- package/docs/install.md +43 -0
- package/docs/install.readme.t.md +17 -0
- package/docs/install.slate.t.md +17 -0
- package/docs/license.md +2 -0
- package/docs/partials/header.hbs +3 -0
- package/docs/ps-examples.md +129 -0
- package/docs/vault-display-example.md +132 -0
- package/docs/wallet-buttons-examples.md +609 -0
- package/docs/wallet-buttons.md +619 -0
- package/docs/wallet-cba-buttons-examples.md +388 -0
- package/docs/widget-examples.md +134 -0
- package/package.json +164 -42
- package/slate.md +141 -106
- package/.nvmrc +0 -1
- package/api.d.ts +0 -1
- package/api.js +0 -1
- package/canvas3ds.d.ts +0 -1
- package/canvas3ds.js +0 -1
- package/checkout-button.d.ts +0 -1
- package/checkout-button.js +0 -1
- package/inicialization-guide.md +0 -7
- package/lib/api/api-base.js +0 -101
- package/lib/api/api-base.js.map +0 -1
- package/lib/api/api-charge-internal.js +0 -30
- package/lib/api/api-charge-internal.js.map +0 -1
- package/lib/api/api-charge.js +0 -49
- package/lib/api/api-charge.js.map +0 -1
- package/lib/api/api-internal.js +0 -13
- package/lib/api/api-internal.js.map +0 -1
- package/lib/api/api-service-internal.js +0 -19
- package/lib/api/api-service-internal.js.map +0 -1
- package/lib/api/api.js +0 -62
- package/lib/api/api.js.map +0 -1
- package/lib/api/index.d.ts +0 -1
- package/lib/api/index.js +0 -2
- package/lib/api/index.js.map +0 -1
- package/lib/canvas-3ds/canvas-3ds.js +0 -157
- package/lib/canvas-3ds/canvas-3ds.js.map +0 -1
- package/lib/canvas-3ds/index.js +0 -2
- package/lib/canvas-3ds/index.js.map +0 -1
- package/lib/canvas-3ds/services/gpayments-service.js +0 -181
- package/lib/canvas-3ds/services/gpayments-service.js.map +0 -1
- package/lib/canvas-3ds/services/index.js +0 -2
- package/lib/canvas-3ds/services/index.js.map +0 -1
- package/lib/canvas-3ds/services/standalone3ds-service.js +0 -32
- package/lib/canvas-3ds/services/standalone3ds-service.js.map +0 -1
- package/lib/checkout-button/afterpay/afterpay-checkout-button.js +0 -50
- package/lib/checkout-button/afterpay/afterpay-checkout-button.js.map +0 -1
- package/lib/checkout-button/afterpay/afterpay.runner.js +0 -41
- package/lib/checkout-button/afterpay/afterpay.runner.js.map +0 -1
- package/lib/checkout-button/checkout-button.interface.js +0 -45
- package/lib/checkout-button/checkout-button.interface.js.map +0 -1
- package/lib/checkout-button/checkout-button.js +0 -266
- package/lib/checkout-button/checkout-button.js.map +0 -1
- package/lib/checkout-button/checkout-contextual-handler.js +0 -75
- package/lib/checkout-button/checkout-contextual-handler.js.map +0 -1
- package/lib/checkout-button/index.js +0 -85
- package/lib/checkout-button/index.js.map +0 -1
- package/lib/checkout-button/paypal/paypal-checkout-button.js +0 -25
- package/lib/checkout-button/paypal/paypal-checkout-button.js.map +0 -1
- package/lib/checkout-button/paypal/paypal.runner.js +0 -14
- package/lib/checkout-button/paypal/paypal.runner.js.map +0 -1
- package/lib/checkout-button/runner/base.runner.js +0 -13
- package/lib/checkout-button/runner/base.runner.js.map +0 -1
- package/lib/checkout-button/runner/contextual.runner.js +0 -40
- package/lib/checkout-button/runner/contextual.runner.js.map +0 -1
- package/lib/checkout-button/runner/index.js +0 -11
- package/lib/checkout-button/runner/index.js.map +0 -1
- package/lib/checkout-button/runner/popup.runner.js +0 -68
- package/lib/checkout-button/runner/popup.runner.js.map +0 -1
- package/lib/checkout-button/runner/redirect.runner.js +0 -15
- package/lib/checkout-button/runner/redirect.runner.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney-checkout-button.js +0 -64
- package/lib/checkout-button/zipmoney/zipmoney-checkout-button.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney-contextual.runner.js +0 -78
- package/lib/checkout-button/zipmoney/zipmoney-contextual.runner.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney-redirect.runner.js +0 -49
- package/lib/checkout-button/zipmoney/zipmoney-redirect.runner.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney.config.js +0 -4
- package/lib/checkout-button/zipmoney/zipmoney.config.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney.runner.js +0 -23
- package/lib/checkout-button/zipmoney/zipmoney.runner.js.map +0 -1
- package/lib/checkout-button/zipmoney/zipmoney.types.js +0 -1
- package/lib/checkout-button/zipmoney/zipmoney.types.js.map +0 -1
- package/lib/components/ability-guard.js +0 -44
- package/lib/components/ability-guard.js.map +0 -1
- package/lib/components/background.js +0 -193
- package/lib/components/background.js.map +0 -1
- package/lib/components/container.js +0 -63
- package/lib/components/container.js.map +0 -1
- package/lib/components/dispatcher.js +0 -39
- package/lib/components/dispatcher.js.map +0 -1
- package/lib/components/element-style.js +0 -52
- package/lib/components/element-style.js.map +0 -1
- package/lib/components/flypay-iframe-event.js +0 -28
- package/lib/components/flypay-iframe-event.js.map +0 -1
- package/lib/components/form-Interceptor.js +0 -38
- package/lib/components/form-Interceptor.js.map +0 -1
- package/lib/components/http-core.js +0 -57
- package/lib/components/http-core.js.map +0 -1
- package/lib/components/iframe-event.js +0 -77
- package/lib/components/iframe-event.js.map +0 -1
- package/lib/components/iframe.js +0 -62
- package/lib/components/iframe.js.map +0 -1
- package/lib/components/link.js +0 -60
- package/lib/components/link.js.map +0 -1
- package/lib/components/loader.js +0 -234
- package/lib/components/loader.js.map +0 -1
- package/lib/components/param.js +0 -147
- package/lib/components/param.js.map +0 -1
- package/lib/components/popup.js +0 -104
- package/lib/components/popup.js.map +0 -1
- package/lib/components/storage-dispatcher.js +0 -75
- package/lib/components/storage-dispatcher.js.map +0 -1
- package/lib/components/trigger.js +0 -49
- package/lib/components/trigger.js.map +0 -1
- package/lib/components/vault-display-iframe-event.js +0 -27
- package/lib/components/vault-display-iframe-event.js.map +0 -1
- package/lib/components/wallet-background.js +0 -75
- package/lib/components/wallet-background.js.map +0 -1
- package/lib/components/wallet-trigger.js +0 -27
- package/lib/components/wallet-trigger.js.map +0 -1
- package/lib/configs/env/env.js +0 -117
- package/lib/configs/env/env.js.map +0 -1
- package/lib/configs/sdk.js +0 -16
- package/lib/configs/sdk.js.map +0 -1
- package/lib/constants/validators.js +0 -42
- package/lib/constants/validators.js.map +0 -1
- package/lib/external-checkout/builder.js +0 -45
- package/lib/external-checkout/builder.js.map +0 -1
- package/lib/external-checkout/checker.js +0 -22
- package/lib/external-checkout/checker.js.map +0 -1
- package/lib/external-checkout/index.d.ts +0 -2
- package/lib/external-checkout/index.js +0 -3
- package/lib/external-checkout/index.js.map +0 -1
- package/lib/helper/access-token.js +0 -44
- package/lib/helper/access-token.js.map +0 -1
- package/lib/helper/browser.js +0 -79
- package/lib/helper/browser.js.map +0 -1
- package/lib/helper/event-emitter.js +0 -23
- package/lib/helper/event-emitter.js.map +0 -1
- package/lib/helper/event.js +0 -23
- package/lib/helper/event.js.map +0 -1
- package/lib/helper/ms.js +0 -32
- package/lib/helper/ms.js.map +0 -1
- package/lib/helper/object.js +0 -6
- package/lib/helper/object.js.map +0 -1
- package/lib/helper/url.js +0 -11
- package/lib/helper/url.js.map +0 -1
- package/lib/helper/uuid.js +0 -26
- package/lib/helper/uuid.js.map +0 -1
- package/lib/index.d.ts +0 -15
- package/lib/index.js +0 -15
- package/lib/index.js.map +0 -1
- package/lib/payment-source/builder.js +0 -49
- package/lib/payment-source/builder.js.map +0 -1
- package/lib/payment-source/index.js +0 -2
- package/lib/payment-source/index.js.map +0 -1
- package/lib/payment-source-widget/html-payment-source-widget.js +0 -172
- package/lib/payment-source-widget/html-payment-source-widget.js.map +0 -1
- package/lib/payment-source-widget/index.js +0 -35
- package/lib/payment-source-widget/index.js.map +0 -1
- package/lib/payment-source-widget/interfaces.js +0 -2
- package/lib/payment-source-widget/interfaces.js.map +0 -1
- package/lib/payment-source-widget/payment-source-widget.js +0 -142
- package/lib/payment-source-widget/payment-source-widget.js.map +0 -1
- package/lib/secure-remote-commerce/index.js +0 -103
- package/lib/secure-remote-commerce/index.js.map +0 -1
- package/lib/secure-remote-commerce/interfaces.js +0 -48
- package/lib/secure-remote-commerce/interfaces.js.map +0 -1
- package/lib/secure-remote-commerce/mastercard-secure-remote-commerce.d.ts +0 -30
- package/lib/secure-remote-commerce/mastercard-secure-remote-commerce.js +0 -40
- package/lib/secure-remote-commerce/mastercard-secure-remote-commerce.js.map +0 -1
- package/lib/secure-remote-commerce/providers/mastercard-src/index.d.ts +0 -1
- package/lib/secure-remote-commerce/providers/mastercard-src/index.js +0 -2
- package/lib/secure-remote-commerce/providers/mastercard-src/index.js.map +0 -1
- package/lib/secure-remote-commerce/providers/mastercard-src/mastercard-src.js +0 -89
- package/lib/secure-remote-commerce/providers/mastercard-src/mastercard-src.js.map +0 -1
- package/lib/secure-remote-commerce/providers/src-provider.js +0 -1
- package/lib/secure-remote-commerce/providers/src-provider.js.map +0 -1
- package/lib/secure-remote-commerce/secure-remote-commerce.js +0 -155
- package/lib/secure-remote-commerce/secure-remote-commerce.js.map +0 -1
- package/lib/vault-display-widget/index.js +0 -14
- package/lib/vault-display-widget/index.js.map +0 -1
- package/lib/vault-display-widget/vault-display-widget.js +0 -99
- package/lib/vault-display-widget/vault-display-widget.js.map +0 -1
- package/lib/wallet-buttons/afterpay.wallet-service.js +0 -152
- package/lib/wallet-buttons/afterpay.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/apple.wallet-service.js +0 -324
- package/lib/wallet-buttons/apple.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/flypay-v2.wallet-service.js +0 -163
- package/lib/wallet-buttons/flypay-v2.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/flypay.wallet-service.js +0 -117
- package/lib/wallet-buttons/flypay.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/google.wallet-service.js +0 -301
- package/lib/wallet-buttons/google.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/helpers/flypay-v2.helper.d.ts +0 -3
- package/lib/wallet-buttons/helpers/flypay-v2.helper.js +0 -151
- package/lib/wallet-buttons/helpers/flypay-v2.helper.js.map +0 -1
- package/lib/wallet-buttons/index.js +0 -128
- package/lib/wallet-buttons/index.js.map +0 -1
- package/lib/wallet-buttons/interfaces.js +0 -1
- package/lib/wallet-buttons/interfaces.js.map +0 -1
- package/lib/wallet-buttons/mastercard.wallet-service.js +0 -27
- package/lib/wallet-buttons/mastercard.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/paypal.wallet-service.js +0 -144
- package/lib/wallet-buttons/paypal.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/stripe.wallet-service.js +0 -100
- package/lib/wallet-buttons/stripe.wallet-service.js.map +0 -1
- package/lib/wallet-buttons/wallet-buttons.js +0 -479
- package/lib/wallet-buttons/wallet-buttons.js.map +0 -1
- package/lib/wallet-buttons/wallet-service.js +0 -60
- package/lib/wallet-buttons/wallet-service.js.map +0 -1
- package/lib/widget/configuration.js +0 -260
- package/lib/widget/configuration.js.map +0 -1
- package/lib/widget/html-multi-widget.js +0 -422
- package/lib/widget/html-multi-widget.js.map +0 -1
- package/lib/widget/html-widget.js +0 -127
- package/lib/widget/html-widget.js.map +0 -1
- package/lib/widget/index.js +0 -132
- package/lib/widget/index.js.map +0 -1
- package/lib/widget/meta.js +0 -8
- package/lib/widget/meta.js.map +0 -1
- package/lib/widget/multi-widget.js +0 -437
- package/lib/widget/multi-widget.js.map +0 -1
- package/lib/widget/style.js +0 -204
- package/lib/widget/style.js.map +0 -1
- package/payment-source-widget.d.ts +0 -1
- package/payment-source-widget.js +0 -1
- package/tslint.json +0 -129
- package/typings/globals/jasmine/index.d.ts +0 -576
- package/typings/globals/jasmine-ajax/index.d.ts +0 -83
- package/typings/globals/jquery/index.d.ts +0 -3759
- package/typings/index.d.ts +0 -3
- package/vault-display-widget.d.ts +0 -1
- package/vault-display-widget.js +0 -1
- package/vendors/zipmoney.d.ts +0 -18
- package/vendors/zipmoney.js +0 -1
- package/widget.d.ts +0 -1
- package/widget.js +0 -1
package/README.md
CHANGED
|
@@ -16,76 +16,78 @@ Also you will need added gateway ([see API Reference by gateway](https://docs.pa
|
|
|
16
16
|
|
|
17
17
|
## Get started
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
`npm install @paydock/client-sdk`
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
You can use ES2015 or TypeScript modules
|
|
27
|
-
|
|
28
|
-
`@paydock/client-sdk/widget`
|
|
29
|
-
|
|
19
|
+
The Client SDK ships in JavaScript ES6 (EcmaScript 2015) in three different
|
|
20
|
+
formats (CJS, ESM and UMD) along with respective TypeScript declarations. Below,
|
|
21
|
+
we exemplify how to import each format.
|
|
30
22
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
`@paydock/client-sdk/bundles/widget.umd.js`
|
|
34
|
-
|
|
35
|
-
`@paydock/client-sdk/bundles/widget.umd.min.js`
|
|
23
|
+
### With package manager
|
|
36
24
|
|
|
25
|
+
Our NPM package is compatible with all package managers (e.g., `npm`, `yarn`,
|
|
26
|
+
`pnpm`, `bun`). Using `npm` the following command would add the Client SDK as a
|
|
27
|
+
production dependency.
|
|
37
28
|
|
|
29
|
+
```bash
|
|
30
|
+
npm install @paydock/client-sdk
|
|
31
|
+
```
|
|
38
32
|
|
|
39
|
-
|
|
40
|
-
|
|
33
|
+
After installation is complete, if you are developing in NodeJS environments or
|
|
34
|
+
using tools that expect your JavaScript code to be in CJS format (e.g., Jest,
|
|
35
|
+
Karma, RequireJS, Webpack), you can import the Client SDK using CommonJS modules.
|
|
36
|
+
For these environments the UMD format (`@paydock/client-sdk/bundles/widget.umd.js`)
|
|
37
|
+
can also be used as a fallback. Alternatively, in case you are developing in
|
|
38
|
+
projects that have access to modern bundlers such as Vite or others (e.g., SPA
|
|
39
|
+
libs or SSR Metaframeworks), you can import the Client SDK features using ESM
|
|
40
|
+
through named imports or namespaced imports.
|
|
41
41
|
|
|
42
|
-
import { HtmlWidget } from '@paydock/client-sdk/widget';
|
|
43
42
|
|
|
44
|
-
|
|
43
|
+
```cjs
|
|
44
|
+
// module import - CommonJS/Node projects ✅
|
|
45
|
+
const paydock = require('@paydock/client-sdk')
|
|
46
|
+
const api = new paydock.Api('publicKey');
|
|
45
47
|
```
|
|
46
48
|
|
|
49
|
+
```mjs
|
|
50
|
+
// named import - ESM projects or TypeScript projects ✅
|
|
51
|
+
import { HtmlWidget } from '@paydock/client-sdk'
|
|
52
|
+
const widget = new HtmlWidget('#selector', 'publicKey', 'gatewayId');
|
|
53
|
+
```
|
|
47
54
|
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
</script>
|
|
55
|
+
```mjs
|
|
56
|
+
// namespaced import - ESM projects or TypeScript projects ✅
|
|
57
|
+
import * as Paydock from '@paydock/client-sdk'
|
|
58
|
+
const widget = new Paydock.HtmlWidget('#selector', 'publicKey', 'gatewayId');
|
|
53
59
|
```
|
|
54
60
|
|
|
61
|
+
```js
|
|
62
|
+
// default import - We do not provide default exports. They are handled differently by different tools!
|
|
63
|
+
❌
|
|
64
|
+
import paydock from '@paydock/client-sdk'
|
|
65
|
+
>>> "Uncaught SyntaxError: The requested module does not provide an export named 'default'"
|
|
66
|
+
```
|
|
55
67
|
|
|
56
68
|
|
|
57
69
|
### Download from CDN
|
|
58
70
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
*Compressed version for production*
|
|
64
|
-
`https://widget.paydock.com/sdk/latest/widget.umd.min.js`
|
|
65
|
-
|
|
66
|
-
*Full version for development and debug*
|
|
67
|
-
`https://widget.paydock.com/sdk/latest/widget.umd.js`
|
|
71
|
+
For browser environments, you can import the Client SDK directly from our CDN to
|
|
72
|
+
your project's HTML. To accomplish this, include the Client SDK in your page
|
|
73
|
+
using one and only of the two script tags below. After this step you will be
|
|
74
|
+
able to access the Client SDK features via the global variable `paydock`.
|
|
68
75
|
|
|
76
|
+
For production we recommend using the compressed version (`.min.js`) since
|
|
77
|
+
it will result in faster loading times for your end users.
|
|
69
78
|
|
|
79
|
+
- *Compressed version for production: `https://widget.paydock.com/sdk/latest/widget.umd.min.js`*
|
|
70
80
|
|
|
81
|
+
- *Full version for development and debug: `https://widget.paydock.com/sdk/latest/widget.umd.js`*
|
|
71
82
|
|
|
72
|
-
|
|
83
|
+
You may download the production version of the Client SDK scripts [here][min],
|
|
84
|
+
and, the development version [here][max].
|
|
73
85
|
|
|
74
86
|
[min]: https://widget.paydock.com/sdk/latest/widget.umd.min.js
|
|
75
87
|
[max]: https://widget.paydock.com/sdk/latest/widget.umd.js
|
|
76
88
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
Also for more advanced use, the library has [UMD](https://github.com/umdjs/umd) format, thus can be used in requireJs, webpack, etc.
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
+
For more advanced use-cases, the library has [UMD](https://github.com/umdjs/umd)
|
|
90
|
+
format that can be used in RequireJS, Webpack, etc.
|
|
89
91
|
|
|
90
92
|
|
|
91
93
|
```html
|
|
@@ -95,6 +97,7 @@ Also for more advanced use, the library has [UMD](https://github.com/umdjs/umd)
|
|
|
95
97
|
</script>
|
|
96
98
|
```
|
|
97
99
|
|
|
100
|
+
|
|
98
101
|
## Widget
|
|
99
102
|
You can find description of all methods and parameters [here](https://www.npmjs.com/package/@paydock/client-sdk#widget-simple-example)
|
|
100
103
|
|
|
@@ -119,11 +122,11 @@ var widget = new paydock.HtmlWidget('#widget', 'publicKey');
|
|
|
119
122
|
widget.load();
|
|
120
123
|
```
|
|
121
124
|
|
|
122
|
-
```javascript
|
|
125
|
+
```javascript
|
|
123
126
|
// ES2015 | TypeScript
|
|
124
127
|
|
|
125
|
-
import { HtmlWidget } from '@paydock/client-sdk
|
|
126
|
-
|
|
128
|
+
import { HtmlWidget } from '@paydock/client-sdk';
|
|
129
|
+
|
|
127
130
|
var widget = new HtmlWidget('#widget', 'publicKey');
|
|
128
131
|
widget.load();
|
|
129
132
|
```
|
|
@@ -131,7 +134,7 @@ widget.load();
|
|
|
131
134
|
Then write only need 2 lines of code in js to initialize widget
|
|
132
135
|
|
|
133
136
|
|
|
134
|
-
### Full example
|
|
137
|
+
### Full example
|
|
135
138
|
|
|
136
139
|
```html
|
|
137
140
|
<!DOCTYPE html>
|
|
@@ -194,9 +197,9 @@ widget.setFormFields(['phone', 'email']); // add additional fields for form of w
|
|
|
194
197
|
widget.setSupportedCardIcons(['mastercard', 'visa']); // add icons of supported card types
|
|
195
198
|
```
|
|
196
199
|
|
|
197
|
-
This example shows how you can use a lot of other methods to settings your form
|
|
200
|
+
This example shows how you can use a lot of other methods to settings your form
|
|
198
201
|
|
|
199
|
-
### Full example
|
|
202
|
+
### Full example
|
|
200
203
|
|
|
201
204
|
```html
|
|
202
205
|
<!DOCTYPE html>
|
|
@@ -217,12 +220,12 @@ This example shows how you can use a lot of other methods to settings your form
|
|
|
217
220
|
<script src="https://widget.paydock.com/sdk/latest/widget.umd.js" ></script>
|
|
218
221
|
<script>
|
|
219
222
|
var widget = new paydock.HtmlWidget('#widget', 'publicKey', 'gatewayId');
|
|
220
|
-
|
|
223
|
+
|
|
221
224
|
widget.setSupportedCardIcons(['mastercard', 'visa']);
|
|
222
225
|
widget.setFormFields(['phone', 'email']);
|
|
223
226
|
widget.setRefId('custom-ref-id');
|
|
224
227
|
widget.onFinishInsert('input[name="payment_source_token"]', 'payment_source');z
|
|
225
|
-
|
|
228
|
+
|
|
226
229
|
widget.load();
|
|
227
230
|
</script>
|
|
228
231
|
</script>
|
|
@@ -648,7 +651,7 @@ Class Widget include method for working on html and include extended by HtmlMult
|
|
|
648
651
|
* [.setFormValues(fieldValues)](#user-content-w_MultiWidget+setFormValues)
|
|
649
652
|
* [.setFormLabels(fieldLabels)](#user-content-w_MultiWidget+setFormLabels)
|
|
650
653
|
* [.setFormPlaceholders(fieldPlaceholders)](#user-content-w_MultiWidget+setFormPlaceholders)
|
|
651
|
-
* [.setIcons()](#user-content-w_MultiWidget+setIcons)
|
|
654
|
+
* ~~[.setIcons()](#user-content-w_MultiWidget+setIcons)~~
|
|
652
655
|
* [.setHiddenElements(elements)](#user-content-w_MultiWidget+setHiddenElements)
|
|
653
656
|
* [.setRefId(refId)](#user-content-w_MultiWidget+setRefId)
|
|
654
657
|
* [.useGatewayFieldValidation()](#user-content-w_MultiWidget+useGatewayFieldValidation)
|
|
@@ -1213,15 +1216,13 @@ widget.setFormPlaceholders({
|
|
|
1213
1216
|
```
|
|
1214
1217
|
<a name="w_MultiWidget+setIcons" id="w_MultiWidget+setIcons" href="#user-content-w_MultiWidget+setIcons"> </a>
|
|
1215
1218
|
|
|
1216
|
-
### htmlWidget.setIcons()
|
|
1219
|
+
### ~~htmlWidget.setIcons()~~
|
|
1220
|
+
***Deprecated***
|
|
1221
|
+
|
|
1217
1222
|
The method to change the widget icons
|
|
1218
1223
|
|
|
1219
1224
|
**Kind**: instance method of [<code>HtmlWidget</code>](#user-content-w_HtmlWidget)
|
|
1220
1225
|
**Overrides**: [<code>setIcons</code>](#user-content-w_MultiWidget+setIcons)
|
|
1221
|
-
**Todo**
|
|
1222
|
-
|
|
1223
|
-
- [ ] DEPRECATED
|
|
1224
|
-
|
|
1225
1226
|
<a name="w_MultiWidget+setHiddenElements" id="w_MultiWidget+setHiddenElements" href="#user-content-w_MultiWidget+setHiddenElements"> </a>
|
|
1226
1227
|
|
|
1227
1228
|
### htmlWidget.setHiddenElements(elements)
|
|
@@ -1375,7 +1376,7 @@ Class HtmlMultiWidget include method for working with html
|
|
|
1375
1376
|
* [.setFormLabels(fieldLabels)](#user-content-w_MultiWidget+setFormLabels)
|
|
1376
1377
|
* [.setFormPlaceholders(fieldPlaceholders)](#user-content-w_MultiWidget+setFormPlaceholders)
|
|
1377
1378
|
* [.setFormElements(elements)](#user-content-w_MultiWidget+setFormElements)
|
|
1378
|
-
* [.setIcons()](#user-content-w_MultiWidget+setIcons)
|
|
1379
|
+
* ~~[.setIcons()](#user-content-w_MultiWidget+setIcons)~~
|
|
1379
1380
|
* [.setHiddenElements(elements)](#user-content-w_MultiWidget+setHiddenElements)
|
|
1380
1381
|
* [.setRefId(refId)](#user-content-w_MultiWidget+setRefId)
|
|
1381
1382
|
* [.useGatewayFieldValidation()](#user-content-w_MultiWidget+useGatewayFieldValidation)
|
|
@@ -1841,15 +1842,13 @@ widget.setFormElements([
|
|
|
1841
1842
|
```
|
|
1842
1843
|
<a name="w_MultiWidget+setIcons" id="w_MultiWidget+setIcons" href="#user-content-w_MultiWidget+setIcons"> </a>
|
|
1843
1844
|
|
|
1844
|
-
### htmlMultiWidget.setIcons()
|
|
1845
|
+
### ~~htmlMultiWidget.setIcons()~~
|
|
1846
|
+
***Deprecated***
|
|
1847
|
+
|
|
1845
1848
|
The method to change the widget icons
|
|
1846
1849
|
|
|
1847
1850
|
**Kind**: instance method of [<code>HtmlMultiWidget</code>](#user-content-w_HtmlMultiWidget)
|
|
1848
1851
|
**Overrides**: [<code>setIcons</code>](#user-content-w_MultiWidget+setIcons)
|
|
1849
|
-
**Todo**
|
|
1850
|
-
|
|
1851
|
-
- [ ] DEPRECATED
|
|
1852
|
-
|
|
1853
1852
|
<a name="w_MultiWidget+setHiddenElements" id="w_MultiWidget+setHiddenElements" href="#user-content-w_MultiWidget+setHiddenElements"> </a>
|
|
1854
1853
|
|
|
1855
1854
|
### htmlMultiWidget.setHiddenElements(elements)
|
|
@@ -2162,7 +2161,7 @@ Class MultiWidget include method for for creating iframe url
|
|
|
2162
2161
|
* [.setFormLabels(fieldLabels)](#user-content-w_MultiWidget+setFormLabels)
|
|
2163
2162
|
* [.setFormPlaceholders(fieldPlaceholders)](#user-content-w_MultiWidget+setFormPlaceholders)
|
|
2164
2163
|
* [.setFormElements(elements)](#user-content-w_MultiWidget+setFormElements)
|
|
2165
|
-
* [.setIcons()](#user-content-w_MultiWidget+setIcons)
|
|
2164
|
+
* ~~[.setIcons()](#user-content-w_MultiWidget+setIcons)~~
|
|
2166
2165
|
* [.setHiddenElements(elements)](#user-content-w_MultiWidget+setHiddenElements)
|
|
2167
2166
|
* [.setRefId(refId)](#user-content-w_MultiWidget+setRefId)
|
|
2168
2167
|
* [.useGatewayFieldValidation()](#user-content-w_MultiWidget+useGatewayFieldValidation)
|
|
@@ -2388,14 +2387,12 @@ widget.setFormElements([
|
|
|
2388
2387
|
```
|
|
2389
2388
|
<a name="w_MultiWidget+setIcons" id="w_MultiWidget+setIcons" href="#user-content-w_MultiWidget+setIcons"> </a>
|
|
2390
2389
|
|
|
2391
|
-
### multiWidget.setIcons()
|
|
2390
|
+
### ~~multiWidget.setIcons()~~
|
|
2391
|
+
***Deprecated***
|
|
2392
|
+
|
|
2392
2393
|
The method to change the widget icons
|
|
2393
2394
|
|
|
2394
2395
|
**Kind**: instance method of [<code>MultiWidget</code>](#user-content-w_MultiWidget)
|
|
2395
|
-
**Todo**
|
|
2396
|
-
|
|
2397
|
-
- [ ] DEPRECATED
|
|
2398
|
-
|
|
2399
2396
|
<a name="w_MultiWidget+setHiddenElements" id="w_MultiWidget+setHiddenElements" href="#user-content-w_MultiWidget+setHiddenElements"> </a>
|
|
2400
2397
|
|
|
2401
2398
|
### multiWidget.setHiddenElements(elements)
|
|
@@ -2765,10 +2762,10 @@ var list = new paydock.HtmlPaymentSourceWidget('#list', 'publicKey', 'queryToken
|
|
|
2765
2762
|
list.load();
|
|
2766
2763
|
```
|
|
2767
2764
|
|
|
2768
|
-
```javascript
|
|
2765
|
+
```javascript
|
|
2769
2766
|
// ES2015 | TypeScript
|
|
2770
2767
|
|
|
2771
|
-
import { HtmlPaymentSourceWidget } from '@paydock/client-sdk
|
|
2768
|
+
import { HtmlPaymentSourceWidget } from '@paydock/client-sdk';
|
|
2772
2769
|
|
|
2773
2770
|
var list = new HtmlPaymentSourceWidget('#list', 'publicKey', 'queryToken');
|
|
2774
2771
|
list.load();
|
|
@@ -3481,7 +3478,7 @@ You must create a button to turn it into checkout-button
|
|
|
3481
3478
|
var button = new paydock.PaypalCheckoutButton('#button', 'publicKey', 'gatewayId');
|
|
3482
3479
|
```
|
|
3483
3480
|
|
|
3484
|
-
```javascript
|
|
3481
|
+
```javascript
|
|
3485
3482
|
// ES2015 | TypeScript
|
|
3486
3483
|
|
|
3487
3484
|
|
|
@@ -4624,11 +4621,11 @@ This wrapper helps you to work with paydock api emdpoints
|
|
|
4624
4621
|
var browserDetails = await new paydock.Api('publicKey').setEnv('env').getBrowserDetails();
|
|
4625
4622
|
```
|
|
4626
4623
|
|
|
4627
|
-
```javascript
|
|
4624
|
+
```javascript
|
|
4628
4625
|
// ES2015 | TypeScript
|
|
4629
4626
|
|
|
4630
|
-
import { Api } from '@paydock/client-sdk
|
|
4631
|
-
|
|
4627
|
+
import { Api } from '@paydock/client-sdk';
|
|
4628
|
+
|
|
4632
4629
|
var browserDetails = await new paydock.Api('publicKey').setEnv('env').getBrowserDetails();
|
|
4633
4630
|
```
|
|
4634
4631
|
|
|
@@ -4641,11 +4638,11 @@ var response = await new paydock.Api('publicKey').setEnv('env').charge().preAuth
|
|
|
4641
4638
|
});
|
|
4642
4639
|
```
|
|
4643
4640
|
|
|
4644
|
-
```javascript
|
|
4641
|
+
```javascript
|
|
4645
4642
|
// ES2015 | TypeScript
|
|
4646
4643
|
|
|
4647
|
-
import { Api } from '@paydock/client-sdk
|
|
4648
|
-
|
|
4644
|
+
import { Api } from '@paydock/client-sdk';
|
|
4645
|
+
|
|
4649
4646
|
var response = await new Api('publicKey').setEnv('env').charge().preAuth({
|
|
4650
4647
|
amount: 100,
|
|
4651
4648
|
currency: 'AUD',
|
|
@@ -4655,7 +4652,7 @@ var response = await new Api('publicKey').setEnv('env').charge().preAuth({
|
|
|
4655
4652
|
|
|
4656
4653
|
Then write only need 2 lines of code in js to make request
|
|
4657
4654
|
|
|
4658
|
-
### Initialization full example
|
|
4655
|
+
### Initialization full example
|
|
4659
4656
|
|
|
4660
4657
|
```html
|
|
4661
4658
|
<!DOCTYPE html>
|
|
@@ -4702,10 +4699,10 @@ var canvas3ds = new paydock.Canvas3ds('#widget', 'token');
|
|
|
4702
4699
|
canvas3ds.load();
|
|
4703
4700
|
```
|
|
4704
4701
|
|
|
4705
|
-
```javascript
|
|
4702
|
+
```javascript
|
|
4706
4703
|
// ES2015 | TypeScript
|
|
4707
4704
|
|
|
4708
|
-
import { Canvas3ds } from '@paydock/client-sdk
|
|
4705
|
+
import { Canvas3ds } from '@paydock/client-sdk';
|
|
4709
4706
|
|
|
4710
4707
|
var list = new Canvas3ds('#widget', 'token');
|
|
4711
4708
|
list.load();
|
|
@@ -4926,7 +4923,7 @@ After you initialized the standalone 3ds charge via `v1/charges/standalone-3ds`
|
|
|
4926
4923
|
## Vault Display Widget
|
|
4927
4924
|
You can find description of all methods and parameters [here](https://www.npmjs.com/package/@paydock/client-sdk#vault-display-widget)
|
|
4928
4925
|
|
|
4929
|
-
The vault display form allows viewing card number and CVV. The form can be customised according to your needs.
|
|
4926
|
+
The vault display form allows viewing card number and CVV. The form can be customised according to your needs.
|
|
4930
4927
|
You can set styles as well as subscribe to widget events that help monitor user’s actions in real time.
|
|
4931
4928
|
|
|
4932
4929
|
## Vault Display Widget simple example
|
|
@@ -4946,18 +4943,18 @@ var widget = new paydock.VaultDisplayWidget('#widget', 'token');
|
|
|
4946
4943
|
widget.load();
|
|
4947
4944
|
```
|
|
4948
4945
|
|
|
4949
|
-
```javascript
|
|
4946
|
+
```javascript
|
|
4950
4947
|
// ES2015 | TypeScript
|
|
4951
4948
|
|
|
4952
|
-
import { VaultDisplayWidget } from '@paydock/client-sdk
|
|
4953
|
-
|
|
4949
|
+
import { VaultDisplayWidget } from '@paydock/client-sdk';
|
|
4950
|
+
|
|
4954
4951
|
var widget = new VaultDisplayWidget('#widget', 'token');
|
|
4955
4952
|
widget.load();
|
|
4956
4953
|
```
|
|
4957
4954
|
|
|
4958
4955
|
Then write only need 2 lines of code in js to initialize widget
|
|
4959
4956
|
|
|
4960
|
-
### Full example
|
|
4957
|
+
### Full example
|
|
4961
4958
|
|
|
4962
4959
|
```html
|
|
4963
4960
|
<!DOCTYPE html>
|
|
@@ -4968,9 +4965,9 @@ Then write only need 2 lines of code in js to initialize widget
|
|
|
4968
4965
|
<style>iframe {border: 0;width: 100%;height: 300px;}</style>
|
|
4969
4966
|
</head>
|
|
4970
4967
|
<body>
|
|
4971
|
-
|
|
4968
|
+
|
|
4972
4969
|
<div id="widget"></div>
|
|
4973
|
-
|
|
4970
|
+
|
|
4974
4971
|
<script src="https://widget.paydock.com/sdk/latest/widget.umd.min.js" ></script>
|
|
4975
4972
|
<script>
|
|
4976
4973
|
var widget = new paydock.VaultDisplayWidget('#widget', 'token');
|
|
@@ -5008,9 +5005,9 @@ widget.setStyles({
|
|
|
5008
5005
|
});
|
|
5009
5006
|
```
|
|
5010
5007
|
|
|
5011
|
-
This example shows how you can use a lot of other methods to settings your form
|
|
5008
|
+
This example shows how you can use a lot of other methods to settings your form
|
|
5012
5009
|
|
|
5013
|
-
### Full example
|
|
5010
|
+
### Full example
|
|
5014
5011
|
|
|
5015
5012
|
```html
|
|
5016
5013
|
<!DOCTYPE html>
|
|
@@ -5021,27 +5018,27 @@ This example shows how you can use a lot of other methods to settings your form
|
|
|
5021
5018
|
<style>iframe {border: 0;width: 40%;height: 450px;}</style>
|
|
5022
5019
|
</head>
|
|
5023
5020
|
<body>
|
|
5024
|
-
|
|
5021
|
+
|
|
5025
5022
|
<div id="widget"></div>
|
|
5026
|
-
|
|
5023
|
+
|
|
5027
5024
|
<script src="https://widget.paydock.com/sdk/latest/widget.umd.min.js" ></script>
|
|
5028
5025
|
<script>
|
|
5029
5026
|
var widget = new paydock.VaultDisplayWidget('#widget', 'token');
|
|
5030
5027
|
|
|
5031
5028
|
widget.setEnv('sandbox');
|
|
5032
|
-
|
|
5029
|
+
|
|
5033
5030
|
widget.on('after_load', function (data) {
|
|
5034
5031
|
console.log(data);
|
|
5035
5032
|
});
|
|
5036
|
-
|
|
5033
|
+
|
|
5037
5034
|
widget.on('cvv_secure_code_requested', function (data) {
|
|
5038
5035
|
console.log(data);
|
|
5039
5036
|
});
|
|
5040
|
-
|
|
5037
|
+
|
|
5041
5038
|
widget.on('card_number_secure_code_requested', function (data) {
|
|
5042
5039
|
console.log(data);
|
|
5043
5040
|
});
|
|
5044
|
-
|
|
5041
|
+
|
|
5045
5042
|
widget.setStyles({
|
|
5046
5043
|
background_color: 'rgb(0, 0, 0)',
|
|
5047
5044
|
border_color: 'yellow',
|
|
@@ -5185,7 +5182,7 @@ let button = new paydock.WalletButtons(
|
|
|
5185
5182
|
button.load();
|
|
5186
5183
|
```
|
|
5187
5184
|
|
|
5188
|
-
```javascript
|
|
5185
|
+
```javascript
|
|
5189
5186
|
// ES2015 | TypeScript
|
|
5190
5187
|
import { WalletButtons } from '@paydock/client-sdk';
|
|
5191
5188
|
|
|
@@ -5210,7 +5207,7 @@ let button = new paydock.WalletButtons(
|
|
|
5210
5207
|
button.load();
|
|
5211
5208
|
```
|
|
5212
5209
|
|
|
5213
|
-
```javascript
|
|
5210
|
+
```javascript
|
|
5214
5211
|
// ES2015 | TypeScript
|
|
5215
5212
|
import { WalletButtons } from '@paydock/client-sdk';
|
|
5216
5213
|
|
|
@@ -5234,7 +5231,7 @@ let button = new paydock.WalletButtons(
|
|
|
5234
5231
|
button.load();
|
|
5235
5232
|
```
|
|
5236
5233
|
|
|
5237
|
-
```javascript
|
|
5234
|
+
```javascript
|
|
5238
5235
|
// ES2015 | TypeScript
|
|
5239
5236
|
import { WalletButtons } from '@paydock/client-sdk';
|
|
5240
5237
|
|
|
@@ -6381,21 +6378,31 @@ List of available event's name in the wallet button lifecycle
|
|
|
6381
6378
|
| ON_CLICK | <code>string</code> | <code>"onClick"</code> |
|
|
6382
6379
|
|
|
6383
6380
|
|
|
6384
|
-
#
|
|
6381
|
+
# Click To Pay
|
|
6382
|
+
|
|
6385
6383
|
## Overview
|
|
6386
|
-
|
|
6387
|
-
|
|
6388
|
-
|
|
6384
|
+
|
|
6385
|
+
Integrate with Click To Pay using Paydock's Click To Pay widget.
|
|
6386
|
+
For a full description of the methods and parameters, reference the [README file](https://www.npmjs.com/package/@paydock/client-sdk#ClickToPay).
|
|
6387
|
+
|
|
6388
|
+
## Click To Pay simple example
|
|
6389
|
+
|
|
6389
6390
|
The following section provides an example use case and integration for the widget.
|
|
6391
|
+
|
|
6390
6392
|
### Create a Container
|
|
6391
|
-
|
|
6393
|
+
|
|
6394
|
+
To integrate the Click To Pay checkout iFrame, create a container in your HTML code. This container serves as the placeholder for the iFrame.
|
|
6395
|
+
|
|
6392
6396
|
```html
|
|
6393
6397
|
<div id="checkoutIframe"></div>
|
|
6394
6398
|
```
|
|
6399
|
+
|
|
6395
6400
|
### Initialize the Widget
|
|
6401
|
+
|
|
6396
6402
|
Use the following code to initialize your widget:
|
|
6403
|
+
|
|
6397
6404
|
```javascript
|
|
6398
|
-
var src = new paydock.
|
|
6405
|
+
var src = new paydock.ClickToPay(
|
|
6399
6406
|
"#checkoutIframe",
|
|
6400
6407
|
"service_id",
|
|
6401
6408
|
"paydock_public_key_or_access_token",
|
|
@@ -6403,10 +6410,11 @@ var src = new paydock.MastercardSRCClickToPay(
|
|
|
6403
6410
|
);
|
|
6404
6411
|
src.load();
|
|
6405
6412
|
```
|
|
6406
|
-
|
|
6413
|
+
|
|
6414
|
+
```javascript
|
|
6407
6415
|
// ES2015 | TypeScript
|
|
6408
|
-
import {
|
|
6409
|
-
var src = new
|
|
6416
|
+
import { ClickToPay } from '@paydock/client-sdk';
|
|
6417
|
+
var src = new ClickToPay(
|
|
6410
6418
|
"#checkoutIframe",
|
|
6411
6419
|
"service_id",
|
|
6412
6420
|
"paydock_public_key_or_access_token",
|
|
@@ -6414,9 +6422,13 @@ var src = new MastercardSRCClickToPay(
|
|
|
6414
6422
|
);
|
|
6415
6423
|
src.load();
|
|
6416
6424
|
```
|
|
6425
|
+
|
|
6417
6426
|
*NOTE:* Paydock recommends that you use a Paydock Access Token instead of a public key for security reasons in production environments. When creating your access token, you must enable the `Secure Remote Commerce` and add a whitelist for the domain of your checkout screen.
|
|
6427
|
+
|
|
6418
6428
|
### Full example
|
|
6429
|
+
|
|
6419
6430
|
A full example of the container and the initialized widget is as follows:
|
|
6431
|
+
|
|
6420
6432
|
```html
|
|
6421
6433
|
<!DOCTYPE html>
|
|
6422
6434
|
<html lang="en">
|
|
@@ -6429,7 +6441,7 @@ A full example of the container and the initialized widget is as follows:
|
|
|
6429
6441
|
<div id="checkoutIframe"></div>
|
|
6430
6442
|
<script src="https://widget.paydock.com/sdk/latest/widget.umd.min.js" ></script>
|
|
6431
6443
|
<script>
|
|
6432
|
-
var src = new paydock.
|
|
6444
|
+
var src = new paydock.ClickToPay(
|
|
6433
6445
|
"#checkoutIframe",
|
|
6434
6446
|
"service_id",
|
|
6435
6447
|
"paydock_public_key_or_access_token",
|
|
@@ -6440,9 +6452,13 @@ A full example of the container and the initialized widget is as follows:
|
|
|
6440
6452
|
</body>
|
|
6441
6453
|
</html>
|
|
6442
6454
|
```
|
|
6443
|
-
|
|
6455
|
+
|
|
6456
|
+
## Customize your Click To Pay Checkout
|
|
6457
|
+
|
|
6444
6458
|
The following is an advanced example that includes customization. You can use these methods to enhance your checkout experience.
|
|
6459
|
+
|
|
6445
6460
|
### Settings
|
|
6461
|
+
|
|
6446
6462
|
```javascript
|
|
6447
6463
|
src.setEnv('sandbox'); // set environment
|
|
6448
6464
|
src.hideCheckout(); // hide checkout iframe
|
|
@@ -6460,7 +6476,9 @@ src.on('checkoutError', (error) => {
|
|
|
6460
6476
|
console.log(error);
|
|
6461
6477
|
});
|
|
6462
6478
|
```
|
|
6479
|
+
|
|
6463
6480
|
### Full example
|
|
6481
|
+
|
|
6464
6482
|
```html
|
|
6465
6483
|
<!DOCTYPE html>
|
|
6466
6484
|
<html lang="en">
|
|
@@ -6473,7 +6491,7 @@ src.on('checkoutError', (error) => {
|
|
|
6473
6491
|
<div id="checkoutIframe"></div>
|
|
6474
6492
|
<script src="https://widget.paydock.com/sdk/latest/widget.umd.min.js" ></script>
|
|
6475
6493
|
<script>
|
|
6476
|
-
var src = new paydock.
|
|
6494
|
+
var src = new paydock.ClickToPay(
|
|
6477
6495
|
"#checkoutIframe",
|
|
6478
6496
|
"service_id",
|
|
6479
6497
|
"paydock_public_key_or_access_token",
|
|
@@ -6496,11 +6514,14 @@ src.on('checkoutError', (error) => {
|
|
|
6496
6514
|
</body>
|
|
6497
6515
|
</html>
|
|
6498
6516
|
```
|
|
6517
|
+
|
|
6499
6518
|
## Customize your billing address fields
|
|
6519
|
+
|
|
6500
6520
|
To customize your billing address experience, Paydock uses a flag that manages whether a customer's billing address is mandatory.
|
|
6501
6521
|
The options for this customization are NONE (default option), and POSTAL_COUNTRY or FULL.
|
|
6522
|
+
|
|
6502
6523
|
```
|
|
6503
|
-
var src = new paydock.
|
|
6524
|
+
var src = new paydock.ClickToPay(
|
|
6504
6525
|
"#checkoutIframe",
|
|
6505
6526
|
"service_id",
|
|
6506
6527
|
"paydock_public_key_or_access_token",
|
|
@@ -6511,11 +6532,13 @@ var src = new paydock.MastercardSRCClickToPay(
|
|
|
6511
6532
|
},
|
|
6512
6533
|
);
|
|
6513
6534
|
```
|
|
6514
|
-
|
|
6515
|
-
|
|
6516
|
-
|
|
6517
|
-
|
|
6535
|
+
|
|
6536
|
+
The Click To Pay checkout in the example requires the billing address from the customer, which is then returned as a part of the checkout data. The data is then stored and leveraged in the Paydock charge.
|
|
6537
|
+
You can also provide the billing address at the time of creating the charge. For example, if you have a different method for collecting the billing address, such as outside of the Click To Pay checkout, you can provide it alongside other information at the charge creation step:
|
|
6538
|
+
1. Disable the billing address in Paydock's Click To Pay widget.
|
|
6539
|
+
2. Get your One Time Token from the Click To Pay widget alongside other details that may have been collected outside the Click To Pay checkout as the shipping address.
|
|
6518
6540
|
3. Send the billing address when creating the charge.
|
|
6541
|
+
|
|
6519
6542
|
```
|
|
6520
6543
|
POST v1/charges
|
|
6521
6544
|
{
|
|
@@ -6544,12 +6567,17 @@ POST v1/charges
|
|
|
6544
6567
|
}
|
|
6545
6568
|
}
|
|
6546
6569
|
```
|
|
6570
|
+
|
|
6547
6571
|
## How to customize accepted cards
|
|
6572
|
+
|
|
6548
6573
|
You can send a flag `unaccepted_card_type` to block the usage of a specific card type. The available options are 'DEBIT' and 'CREDIT'.
|
|
6574
|
+
|
|
6549
6575
|
### Example code
|
|
6576
|
+
|
|
6550
6577
|
The following example demonstrates how to block the card:
|
|
6578
|
+
|
|
6551
6579
|
```
|
|
6552
|
-
var src = new paydock.
|
|
6580
|
+
var src = new paydock.ClickToPay(
|
|
6553
6581
|
"#checkoutIframe",
|
|
6554
6582
|
"service_id",
|
|
6555
6583
|
"paydock_public_key",
|
|
@@ -6558,11 +6586,15 @@ var src = new paydock.MastercardSRCClickToPay(
|
|
|
6558
6586
|
},
|
|
6559
6587
|
);
|
|
6560
6588
|
```
|
|
6589
|
+
|
|
6561
6590
|
## Personalize the Style
|
|
6591
|
+
|
|
6562
6592
|
Customize the look and feel of your UI. The following example demonstrates changes in the styling of the buttons.
|
|
6593
|
+
|
|
6563
6594
|
### Example code
|
|
6595
|
+
|
|
6564
6596
|
```
|
|
6565
|
-
var src = new paydock.
|
|
6597
|
+
var src = new paydock.ClickToPay(
|
|
6566
6598
|
"#checkoutIframe",
|
|
6567
6599
|
"service_id",
|
|
6568
6600
|
"paydock_public_key",
|
|
@@ -6581,8 +6613,8 @@ src.setStyles({
|
|
|
6581
6613
|
## Classes
|
|
6582
6614
|
|
|
6583
6615
|
<dl>
|
|
6584
|
-
<dt><a href="#
|
|
6585
|
-
<dd><p>Class
|
|
6616
|
+
<dt><a href="#ClickToPay">ClickToPay</a> ⇐ <code>SRC</code></dt>
|
|
6617
|
+
<dd><p>Class ClickToPay include methods for interacting with the ClickToPay checkout and Manual Card option</p>
|
|
6586
6618
|
</dd>
|
|
6587
6619
|
</dl>
|
|
6588
6620
|
|
|
@@ -6600,7 +6632,7 @@ src.setStyles({
|
|
|
6600
6632
|
When the flow type is src, masked checkoutData available is also returned</p>
|
|
6601
6633
|
</dd>
|
|
6602
6634
|
<dt><a href="#IStyles">IStyles</a> : <code>object</code></dt>
|
|
6603
|
-
<dd><p>Interface for style configs inyected to the
|
|
6635
|
+
<dd><p>Interface for style configs inyected to the Click to Pay checkout</p>
|
|
6604
6636
|
</dd>
|
|
6605
6637
|
</dl>
|
|
6606
6638
|
|
|
@@ -6629,7 +6661,7 @@ Interface of data used for the Mastercard Checkout. For further information refe
|
|
|
6629
6661
|
| [dpa_data.dpa_supported_phone_number.phone_number] | <code>string</code> | The phone number part of the phone number. |
|
|
6630
6662
|
| [dpa_data.dpa_support_uri] | <code>string</code> | URI for DPA support. |
|
|
6631
6663
|
| [dpa_data.application_type] | <code>string</code> | Application type, either 'WEB_BROWSER' or 'MOBILE_APP'. |
|
|
6632
|
-
| [co_brand_names] | <code>Array.<string></code> | List of co-brand names associated with the
|
|
6664
|
+
| [co_brand_names] | <code>Array.<string></code> | List of co-brand names associated with the Click to Pay experience. |
|
|
6633
6665
|
| [checkout_experience] | <code>string</code> | Checkout experience type, either 'WITHIN_CHECKOUT' or 'PAYMENT_SETTINGS'. |
|
|
6634
6666
|
| [services] | <code>string</code> | Services offered, such as 'INLINE_CHECKOUT' or 'INLINE_INSTALLMENTS'. |
|
|
6635
6667
|
| [dpa_transaction_options] | <code>object</code> | Object that stores options for creating a transaction with DPA. |
|
|
@@ -6707,7 +6739,7 @@ When the flow type is src, masked checkoutData available is also returned
|
|
|
6707
6739
|
<a name="IStyles" id="IStyles" href="#IStyles"> </a>
|
|
6708
6740
|
|
|
6709
6741
|
## IStyles : <code>object</code>
|
|
6710
|
-
Interface for style configs inyected to the
|
|
6742
|
+
Interface for style configs inyected to the Click to Pay checkout
|
|
6711
6743
|
|
|
6712
6744
|
**Kind**: global interface
|
|
6713
6745
|
|
|
@@ -6718,19 +6750,19 @@ Interface for style configs inyected to the SRC checkout
|
|
|
6718
6750
|
| [secondary_button_color] | <code>string</code> | Color Code for secondary button. |
|
|
6719
6751
|
| [secondary_button_text_color] | <code>string</code> | Color Code for secondary button text. |
|
|
6720
6752
|
| [font_family] | <code>string</code> | Font family to be used. |
|
|
6721
|
-
| [enable_src_popup] | <code>boolean</code> | Boolean flag to make the
|
|
6753
|
+
| [enable_src_popup] | <code>boolean</code> | Boolean flag to make the Click to Pay checkout show in a popup window instead of embedded in iframe. |
|
|
6722
6754
|
|
|
6723
|
-
<a name="
|
|
6755
|
+
<a name="ClickToPay" id="ClickToPay" href="#ClickToPay"> </a>
|
|
6724
6756
|
|
|
6725
|
-
##
|
|
6726
|
-
Class
|
|
6757
|
+
## ClickToPay ⇐ <code>SRC</code>
|
|
6758
|
+
Class ClickToPay include methods for interacting with the ClickToPay checkout and Manual Card option
|
|
6727
6759
|
|
|
6728
6760
|
**Kind**: global class
|
|
6729
6761
|
**Extends**: <code>SRC</code>
|
|
6730
6762
|
|
|
6731
|
-
* [
|
|
6732
|
-
* [new
|
|
6733
|
-
* [.load()](#
|
|
6763
|
+
* [ClickToPay](#ClickToPay) ⇐ <code>SRC</code>
|
|
6764
|
+
* [new ClickToPay(iframe_selector, service_id, public_key_or_access_token, meta)](#new_ClickToPay_new)
|
|
6765
|
+
* [.load()](#ClickToPay+load)
|
|
6734
6766
|
* [.setStyles(fields)](#SRC+setStyles)
|
|
6735
6767
|
* [.setEnv(env, [alias])](#SRC+setEnv)
|
|
6736
6768
|
* [.getEnv()](#SRC+getEnv)
|
|
@@ -6740,33 +6772,33 @@ Class MastercardSRCClickToPay include methods for interacting with the Mastercar
|
|
|
6740
6772
|
* [.reload()](#SRC+reload)
|
|
6741
6773
|
* [.useAutoResize()](#SRC+useAutoResize)
|
|
6742
6774
|
|
|
6743
|
-
<a name="
|
|
6775
|
+
<a name="new_ClickToPay_new" id="new_ClickToPay_new" href="#new_ClickToPay_new"> </a>
|
|
6744
6776
|
|
|
6745
|
-
### new
|
|
6777
|
+
### new ClickToPay(iframe_selector, service_id, public_key_or_access_token, meta)
|
|
6746
6778
|
|
|
6747
6779
|
| Param | Type | Description |
|
|
6748
6780
|
| --- | --- | --- |
|
|
6749
|
-
| iframe_selector | <code>string</code> | Selector of html element. Container for
|
|
6781
|
+
| iframe_selector | <code>string</code> | Selector of html element. Container for Click To Pay checkout iFrame. |
|
|
6750
6782
|
| service_id | <code>string</code> | Card Scheme Service ID |
|
|
6751
6783
|
| public_key_or_access_token | <code>string</code> | Paydock public key or Access Token |
|
|
6752
|
-
| meta |
|
|
6784
|
+
| meta | <code>IClickToPayMeta</code> | Data that configures the Click To Pay checkout |
|
|
6753
6785
|
|
|
6754
6786
|
**Example**
|
|
6755
6787
|
```js
|
|
6756
|
-
var mastercardSRC = new
|
|
6788
|
+
var mastercardSRC = new ClickToPay('#checkoutIframe', 'service_id', 'public_key', {});
|
|
6757
6789
|
```
|
|
6758
|
-
<a name="
|
|
6790
|
+
<a name="ClickToPay+load" id="ClickToPay+load" href="#ClickToPay+load"> </a>
|
|
6759
6791
|
|
|
6760
|
-
###
|
|
6761
|
-
The final method after configuring the SRC to start the load process of
|
|
6792
|
+
### clickToPay.load()
|
|
6793
|
+
The final method after configuring the SRC to start the load process of Click To Pay checkout
|
|
6762
6794
|
|
|
6763
|
-
**Kind**: instance method of [<code>
|
|
6795
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6764
6796
|
<a name="SRC+setStyles" id="SRC+setStyles" href="#SRC+setStyles"> </a>
|
|
6765
6797
|
|
|
6766
|
-
###
|
|
6798
|
+
### clickToPay.setStyles(fields)
|
|
6767
6799
|
Object contain styles for widget - call before `.load()`.
|
|
6768
6800
|
|
|
6769
|
-
**Kind**: instance method of [<code>
|
|
6801
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6770
6802
|
**Overrides**: [<code>setStyles</code>](#SRC+setStyles)
|
|
6771
6803
|
|
|
6772
6804
|
| Param | Type | Description |
|
|
@@ -6786,11 +6818,11 @@ widget.setStyles({
|
|
|
6786
6818
|
```
|
|
6787
6819
|
<a name="SRC+setEnv" id="SRC+setEnv" href="#SRC+setEnv"> </a>
|
|
6788
6820
|
|
|
6789
|
-
###
|
|
6821
|
+
### clickToPay.setEnv(env, [alias])
|
|
6790
6822
|
Current method can change environment. By default environment = sandbox.
|
|
6791
6823
|
Also we can change domain alias for this environment. By default domain_alias = paydock.com
|
|
6792
6824
|
|
|
6793
|
-
**Kind**: instance method of [<code>
|
|
6825
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6794
6826
|
**Overrides**: [<code>setEnv</code>](#SRC+setEnv)
|
|
6795
6827
|
|
|
6796
6828
|
| Param | Type | Description |
|
|
@@ -6804,10 +6836,10 @@ SRC.setEnv('production');
|
|
|
6804
6836
|
```
|
|
6805
6837
|
<a name="SRC+getEnv" id="SRC+getEnv" href="#SRC+getEnv"> </a>
|
|
6806
6838
|
|
|
6807
|
-
###
|
|
6839
|
+
### clickToPay.getEnv()
|
|
6808
6840
|
Method to read the current environment
|
|
6809
6841
|
|
|
6810
|
-
**Kind**: instance method of [<code>
|
|
6842
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6811
6843
|
**Overrides**: [<code>getEnv</code>](#SRC+getEnv)
|
|
6812
6844
|
**Example**
|
|
6813
6845
|
```js
|
|
@@ -6815,10 +6847,10 @@ SRC.getEnv();
|
|
|
6815
6847
|
```
|
|
6816
6848
|
<a name="SRC+on" id="SRC+on" href="#SRC+on"> </a>
|
|
6817
6849
|
|
|
6818
|
-
###
|
|
6850
|
+
### clickToPay.on(eventName, [cb]) ⇒ <code>Promise.<any></code> \| <code>void</code>
|
|
6819
6851
|
Listen to events of SRC
|
|
6820
6852
|
|
|
6821
|
-
**Kind**: instance method of [<code>
|
|
6853
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6822
6854
|
**Overrides**: [<code>on</code>](#SRC+on)
|
|
6823
6855
|
|
|
6824
6856
|
| Param | Type | Description |
|
|
@@ -6838,10 +6870,10 @@ SRC.on('checkoutCompleted').then(function (token) {
|
|
|
6838
6870
|
```
|
|
6839
6871
|
<a name="SRC+hideCheckout" id="SRC+hideCheckout" href="#SRC+hideCheckout"> </a>
|
|
6840
6872
|
|
|
6841
|
-
###
|
|
6873
|
+
### clickToPay.hideCheckout([saveSize])
|
|
6842
6874
|
Using this method you can hide checkout after load and button click
|
|
6843
6875
|
|
|
6844
|
-
**Kind**: instance method of [<code>
|
|
6876
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6845
6877
|
**Overrides**: [<code>hideCheckout</code>](#SRC+hideCheckout)
|
|
6846
6878
|
|
|
6847
6879
|
| Param | Type | Default | Description |
|
|
@@ -6854,10 +6886,10 @@ SRC.hideCheckout();
|
|
|
6854
6886
|
```
|
|
6855
6887
|
<a name="SRC+showCheckout" id="SRC+showCheckout" href="#SRC+showCheckout"> </a>
|
|
6856
6888
|
|
|
6857
|
-
###
|
|
6889
|
+
### clickToPay.showCheckout()
|
|
6858
6890
|
Using this method you can show checkout after using hideCheckout method
|
|
6859
6891
|
|
|
6860
|
-
**Kind**: instance method of [<code>
|
|
6892
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6861
6893
|
**Overrides**: [<code>showCheckout</code>](#SRC+showCheckout)
|
|
6862
6894
|
**Example**
|
|
6863
6895
|
```js
|
|
@@ -6865,10 +6897,10 @@ SRC.showCheckout()
|
|
|
6865
6897
|
```
|
|
6866
6898
|
<a name="SRC+reload" id="SRC+reload" href="#SRC+reload"> </a>
|
|
6867
6899
|
|
|
6868
|
-
###
|
|
6900
|
+
### clickToPay.reload()
|
|
6869
6901
|
Using this method you can reload the whole checkout
|
|
6870
6902
|
|
|
6871
|
-
**Kind**: instance method of [<code>
|
|
6903
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6872
6904
|
**Overrides**: [<code>reload</code>](#SRC+reload)
|
|
6873
6905
|
**Example**
|
|
6874
6906
|
```js
|
|
@@ -6876,10 +6908,10 @@ SRC.reload()
|
|
|
6876
6908
|
```
|
|
6877
6909
|
<a name="SRC+useAutoResize" id="SRC+useAutoResize" href="#SRC+useAutoResize"> </a>
|
|
6878
6910
|
|
|
6879
|
-
###
|
|
6911
|
+
### clickToPay.useAutoResize()
|
|
6880
6912
|
Use this method for resize checkout iFrame according to content height, if applicable
|
|
6881
6913
|
|
|
6882
|
-
**Kind**: instance method of [<code>
|
|
6914
|
+
**Kind**: instance method of [<code>ClickToPay</code>](#ClickToPay)
|
|
6883
6915
|
**Overrides**: [<code>useAutoResize</code>](#SRC+useAutoResize)
|
|
6884
6916
|
**Example**
|
|
6885
6917
|
```js
|
|
@@ -6888,7 +6920,7 @@ SRC.useAutoResize();
|
|
|
6888
6920
|
<a name="EVENT" id="EVENT" href="#EVENT"> </a>
|
|
6889
6921
|
|
|
6890
6922
|
## EVENT : <code>enum</code>
|
|
6891
|
-
List of available event's name in the
|
|
6923
|
+
List of available event's name in the Click To Pay checkout lifecycle
|
|
6892
6924
|
|
|
6893
6925
|
**Kind**: global enum
|
|
6894
6926
|
|
|
@@ -6896,8 +6928,8 @@ List of available event's name in the SRC checkout lifecycle
|
|
|
6896
6928
|
| --- | --- | --- | --- |
|
|
6897
6929
|
| IFRAME_LOADED | <code>string</code> | <code>"iframeLoaded"</code> | Initial event sent when IFrame is initially loaded. |
|
|
6898
6930
|
| CHECKOUT_READY | <code>string</code> | <code>"checkoutReady"</code> | Event sent when checkout is loaded and ready to be used by customer. Leverage alongside [showCheckout](#SRC+showCheckout) and [hideCheckout](#SRC+hideCheckout). |
|
|
6899
|
-
| CHECKOUT_POPUP_OPEN | <code>string</code> | <code>"checkoutPopupOpen"</code> | Event sent when
|
|
6900
|
-
| CHECKOUT_POPUP_CLOSE | <code>string</code> | <code>"checkoutPopupClose"</code> | Event sent when
|
|
6931
|
+
| CHECKOUT_POPUP_OPEN | <code>string</code> | <code>"checkoutPopupOpen"</code> | Event sent when Click To Pay checkout flow is started, regardless of embedded or windowed mode. |
|
|
6932
|
+
| CHECKOUT_POPUP_CLOSE | <code>string</code> | <code>"checkoutPopupClose"</code> | Event sent when Click To Pay checkout flow is closed, regardless of embedded or windowed mode. |
|
|
6901
6933
|
| CHECKOUT_COMPLETED | <code>string</code> | <code>"checkoutCompleted"</code> | Event sent on successful checkout by customer. Check [data](#EventDataCheckoutCompletedData) for more information. |
|
|
6902
6934
|
| CHECKOUT_ERROR | <code>string</code> | <code>"checkoutError"</code> | Event sent on error checkout by customer. Check [data](#EventData) for more information. |
|
|
6903
6935
|
|