@justifi/webcomponents 5.7.3-rc-01 → 5.7.3-rc-02
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/cjs/{Checkout-BsYZoJ0a.js → Checkout-BTgAlgVL.js} +3 -3
- package/dist/cjs/{Refund-BDFOEJv_.js → Refund-BFE-2OxN.js} +56 -0
- package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +3 -4
- package/dist/cjs/{justifi-bank-account-form.cjs.entry.js → bank-account-form.cjs.entry.js} +8 -30
- package/dist/cjs/{business-additional-questions-schema-CHOaeZot.js → business-additional-questions-schema-e3GCIHk5.js} +6 -6
- package/dist/cjs/{business-identity-schema-DmpEndsx.js → business-identity-schema-Diqj_WVQ.js} +10 -10
- package/dist/cjs/{business.service-ev-3rHag.js → business.service-DNoCHqtI.js} +2 -3
- package/dist/cjs/{justifi-card-form.cjs.entry.js → card-form.cjs.entry.js} +9 -31
- package/dist/cjs/{Analytics-DYN4hp2b.js → check-pkg-version-CgQ8N_ta.js} +22 -23
- package/dist/cjs/{checkout.service-D4hTYr1i.js → checkout.service-C3R0uykH.js} +2 -3
- package/dist/cjs/checkouts-list-core.cjs.entry.js +2 -3
- package/dist/cjs/{custom-popper_4.cjs.entry.js → custom-popper_2.cjs.entry.js} +0 -100
- package/dist/cjs/{dispute.service-Dru9NStj.js → dispute.service-CaA-mq-i.js} +2 -3
- package/dist/cjs/form-control-select_2.cjs.entry.js +105 -0
- package/dist/cjs/{get-payment-details-AOibpML7.js → get-payment-details-CnPsEZA8.js} +2 -3
- package/dist/cjs/{get-subaccounts-Dw7CbPDi.js → get-subaccounts-CgOAdXG4.js} +2 -3
- package/dist/cjs/hidden-input_2.cjs.entry.js +1 -1
- package/dist/cjs/{form-CWW8IM-X.js → index.esm-CVuJLXJZ.js} +10022 -10022
- package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +49 -23
- package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +9 -10
- package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +34 -34
- package/dist/cjs/justifi-bank-account-form_4.cjs.entry.js +234 -0
- package/dist/cjs/{justifi-billing-information-form.cjs.entry.js → justifi-billing-information-form_2.cjs.entry.js} +58 -6
- package/dist/cjs/justifi-business-details.cjs.entry.js +7 -8
- package/dist/cjs/justifi-business-form.cjs.entry.js +13 -14
- package/dist/cjs/justifi-checkout-core.cjs.entry.js +1 -1
- package/dist/cjs/{justifi-modular-checkout.cjs.entry.js → justifi-checkout-summary_2.cjs.entry.js} +23 -11
- package/dist/cjs/justifi-checkout.cjs.entry.js +92 -48
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +2 -3
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +8 -9
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +7 -8
- package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +7 -8
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +6 -7
- package/dist/cjs/justifi-new-payment-method.cjs.entry.js +99 -0
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +8 -9
- package/dist/cjs/justifi-owner-form_3.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payment-details.cjs.entry.js +8 -9
- package/dist/cjs/justifi-payment-method-options_3.cjs.entry.js +166 -0
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payments-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payout-details.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +8 -9
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +15 -16
- package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +32 -0
- package/dist/cjs/justifi-season-interruption-insurance-core.cjs.entry.js +2 -2
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +7 -8
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +2 -3
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +2 -3
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +8 -9
- package/dist/cjs/justifi-tokenize-payment-method.cjs.entry.js +6 -7
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-DF9mLjoQ.js → package-wSbEFwqE.js} +1 -1
- package/dist/cjs/{payment.service-rsnscZu7.js → payment.service-C-HKmIG6.js} +2 -3
- package/dist/cjs/payments-list-core.cjs.entry.js +2 -3
- package/dist/cjs/{payout.service-BnmI3X4n.js → payout.service-BHU3EPR2.js} +2 -3
- package/dist/cjs/payouts-list-core.cjs.entry.js +2 -3
- package/dist/cjs/{schema-validations-C0BNwMBi.js → schema-validations-BSeMee-o.js} +31 -54
- package/dist/cjs/terminal-orders-list-core.cjs.entry.js +3 -4
- package/dist/cjs/{terminal-orders-table-OxMHSAJ1.js → terminal-orders-table-C3KZTeE5.js} +2 -3
- package/dist/cjs/{terminal.service--PPaq5xS.js → terminal.service-Bc1YJWi0.js} +2 -3
- package/dist/cjs/terminals-list-core.cjs.entry.js +2 -3
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step-core.js +1 -1
- package/dist/collection/components/business-forms/schemas/business-bank-account-schema.js +36 -8
- package/dist/collection/components/business-forms/schemas/schema-validations.js +1 -47
- package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +2 -2
- package/dist/collection/components/checkout/billing-form/billing-form.js +2 -5
- package/dist/collection/components/checkout/checkout.js +102 -37
- package/dist/collection/components/checkout/new-payment-method.js +2 -2
- package/dist/collection/components/checkout/payment-method-options.js +37 -26
- package/dist/collection/components/checkout/save-new-payment-method.js +1 -1
- package/dist/collection/components/checkout/saved-payment-method.js +1 -1
- package/dist/collection/components/insurance/season-interruption/season-interruption-insurance-core.js +2 -2
- package/dist/collection/components/insurance/season-interruption/season-interruption-insurance.js +1 -2
- package/dist/collection/components/modular-checkout/modular-checkout.js +2 -2
- package/dist/docs.json +177 -203
- package/dist/esm/{Checkout-CV6qgU0r.js → Checkout-CH19cJxH.js} +3 -3
- package/dist/esm/{Refund-CwUn_GFj.js → Refund-BKe90wSq.js} +55 -1
- package/dist/esm/additional-questions-details_5.entry.js +2 -2
- package/dist/esm/{badge-D_Q0kAPD.js → badge-BoemLewg.js} +1 -1
- package/dist/esm/bank-account-document-form-inputs_4.entry.js +5 -6
- package/dist/{module/bank-account-form2.js → esm/bank-account-form.entry.js} +12 -36
- package/dist/esm/{business-additional-questions-schema-0lssJqN7.js → business-additional-questions-schema-uQlQ8fXQ.js} +2 -2
- package/dist/esm/business-details-core.entry.js +3 -3
- package/dist/esm/{business-identity-schema-Bel1K5mu.js → business-identity-schema-BsrgqgDl.js} +2 -2
- package/dist/esm/{business.service-BM8hLxHS.js → business.service-wY8gOZQr.js} +2 -3
- package/dist/esm/{button-BVAxQPpP.js → button-BcLzheaP.js} +1 -1
- package/dist/esm/{justifi-card-form.entry.js → card-form.entry.js} +12 -34
- package/dist/esm/{Analytics-DR277kvb.js → check-pkg-version-BmebRZ4u.js} +22 -23
- package/dist/esm/{checkout.service-CuCgG9hv.js → checkout.service-Ci9Zkxiz.js} +2 -3
- package/dist/esm/checkouts-list-core.entry.js +7 -8
- package/dist/esm/{checkouts-table-Cc6U-0md.js → checkouts-table-ub2cX2KR.js} +2 -2
- package/dist/esm/{custom-popper_4.entry.js → custom-popper_2.entry.js} +3 -101
- package/dist/esm/{dispute.service-rB4Hq6ot.js → dispute.service-D3IjL7Z8.js} +2 -3
- package/dist/esm/form-alert_5.entry.js +1 -1
- package/dist/esm/form-control-checkbox.entry.js +3 -3
- package/dist/esm/form-control-date.entry.js +2 -2
- package/dist/esm/{form-control-error-text-_SAT-ts2.js → form-control-error-text-C4vfc3el.js} +1 -1
- package/dist/esm/form-control-file-v2_2.entry.js +2 -2
- package/dist/esm/{form-control-help-text-Cjeu_VrV.js → form-control-help-text-Dsr1zpTw.js} +1 -1
- package/dist/esm/form-control-monetary-provisioning.entry.js +3 -3
- package/dist/esm/form-control-monetary.entry.js +3 -3
- package/dist/esm/form-control-number-masked_2.entry.js +2 -2
- package/dist/esm/form-control-number.entry.js +3 -3
- package/dist/esm/form-control-radio.entry.js +1 -1
- package/dist/esm/form-control-select_2.entry.js +102 -0
- package/dist/esm/{get-payment-details-DtkGDTwo.js → get-payment-details-CmVKt1jR.js} +2 -3
- package/dist/esm/{get-subaccounts-C-ENQBmY.js → get-subaccounts-BRX7HFGO.js} +2 -3
- package/dist/esm/gross-payment-chart-core.entry.js +3 -3
- package/dist/esm/{header-1-5FIT-wD7.js → header-1-CmImLcLi.js} +1 -1
- package/dist/esm/{header-3-Ce9WLWBm.js → header-3-BMoxz2Hr.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +3 -3
- package/dist/esm/{form-BjGUIqxU.js → index.esm-BCNUj0Dx.js} +10022 -10022
- package/dist/esm/{insurance-state-BcwZy_5w.js → insurance-state-DMexHdvO.js} +1 -1
- package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +43 -17
- package/dist/esm/justifi-additional-questions-form-step_9.entry.js +6 -7
- package/dist/esm/justifi-additional-statement_8.entry.js +2 -2
- package/dist/esm/justifi-bank-account-form_4.entry.js +229 -0
- package/dist/esm/justifi-billing-information-form_2.entry.js +100 -0
- package/dist/esm/justifi-business-details.entry.js +7 -8
- package/dist/esm/justifi-business-form.entry.js +13 -14
- package/dist/esm/justifi-business-representative-form-inputs.entry.js +1 -1
- package/dist/esm/justifi-checkout-core.entry.js +7 -7
- package/dist/esm/{justifi-modular-checkout.entry.js → justifi-checkout-summary_2.entry.js} +22 -11
- package/dist/esm/justifi-checkout.entry.js +91 -47
- package/dist/esm/justifi-checkouts-list-filters.entry.js +3 -4
- package/dist/esm/justifi-checkouts-list.entry.js +10 -11
- package/dist/esm/justifi-details.entry.js +2 -2
- package/dist/esm/justifi-dispute-management.entry.js +5 -6
- package/dist/esm/justifi-dispute-notification_3.entry.js +8 -9
- package/dist/esm/justifi-gross-payment-chart.entry.js +6 -7
- package/dist/esm/justifi-new-payment-method.entry.js +97 -0
- package/dist/esm/justifi-order-terminals.entry.js +8 -9
- package/dist/esm/justifi-owner-form_3.entry.js +8 -9
- package/dist/esm/justifi-payment-details.entry.js +8 -9
- package/dist/esm/justifi-payment-method-options_3.entry.js +162 -0
- package/dist/esm/justifi-payment-provisioning-core.entry.js +2 -2
- package/dist/esm/justifi-payment-provisioning.entry.js +5 -6
- package/dist/esm/justifi-payment-transactions-list.entry.js +8 -9
- package/dist/esm/justifi-payments-list-filters.entry.js +1 -1
- package/dist/esm/justifi-payments-list.entry.js +9 -10
- package/dist/esm/justifi-payout-details.entry.js +7 -8
- package/dist/esm/justifi-payout-transactions-list.entry.js +8 -9
- package/dist/esm/justifi-payouts-list-filters.entry.js +1 -1
- package/dist/esm/justifi-payouts-list.entry.js +10 -11
- package/dist/esm/justifi-refund-payment.entry.js +10 -11
- package/dist/esm/justifi-saved-payment-method.entry.js +30 -0
- package/dist/esm/justifi-season-interruption-insurance-core.entry.js +5 -5
- package/dist/esm/justifi-season-interruption-insurance.entry.js +5 -6
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +3 -4
- package/dist/esm/justifi-terminal-orders-list.entry.js +7 -8
- package/dist/esm/justifi-terminals-list-filters.entry.js +3 -4
- package/dist/esm/justifi-terminals-list.entry.js +9 -10
- package/dist/esm/justifi-tokenize-payment-method.entry.js +6 -7
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{package-CyXXks-Q.js → package-CJdXAC5R.js} +1 -1
- package/dist/esm/pagination-menu.entry.js +1 -1
- package/dist/esm/{parts-_6eQgwfE.js → parts-C71Mxtso.js} +1 -1
- package/dist/esm/payment-details-core.entry.js +5 -5
- package/dist/esm/{payment.service-DoUv1QsX.js → payment.service-ddFQWXPn.js} +2 -3
- package/dist/esm/payments-list-core.entry.js +8 -9
- package/dist/esm/{payments-status-BeL2gi3P.js → payments-status-DvsFQolO.js} +1 -1
- package/dist/esm/{payments-table-MrDAlH2o.js → payments-table-CCKeaI5x.js} +2 -2
- package/dist/esm/payout-details-core.entry.js +6 -6
- package/dist/esm/{payout.service-B_Fm08zQ.js → payout.service-Ws4Pebcz.js} +2 -3
- package/dist/esm/payouts-list-core.entry.js +8 -9
- package/dist/esm/{payouts-status-BxbhUjA3.js → payouts-status-BkM4Gvme.js} +1 -1
- package/dist/esm/{payouts-table-HoX3UYIj.js → payouts-table-CqBOvPOo.js} +2 -2
- package/dist/esm/{schema-validations-DYV7urvw.js → schema-validations-DLWfpHyI.js} +2 -23
- package/dist/esm/{skeleton-CPNYhX-V.js → skeleton-BVM4XTj9.js} +1 -1
- package/dist/esm/{spinner-Cl-6YJPf.js → spinner-BsxFRVXW.js} +1 -1
- package/dist/esm/{table-RCk8zh4L.js → table-DxdC1lXb.js} +2 -2
- package/dist/esm/table-filters-menu.entry.js +2 -2
- package/dist/esm/terminal-orders-list-core.entry.js +7 -8
- package/dist/esm/{terminal-orders-table-DxHLNkx_.js → terminal-orders-table-DV7nRYuE.js} +4 -5
- package/dist/esm/terminal-quantity-selector.entry.js +1 -1
- package/dist/esm/{terminal.service-2VkdfNas.js → terminal.service-DH8gRG1H.js} +2 -3
- package/dist/esm/terminals-list-core.entry.js +7 -8
- package/dist/esm/{terminals-table-v-LOevYA.js → terminals-table-DUHel128.js} +2 -2
- package/dist/esm/{utils-1WrbuHVR.js → utils-B-aPFy3u.js} +1 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/module/Analytics.js +0 -1
- package/dist/module/Refund.js +55 -1
- package/dist/module/bank-account-document-inputs.js +1 -2
- package/dist/module/bank-account-form.js +83 -1
- package/dist/{esm/justifi-bank-account-form.entry.js → module/bank-account.js} +44 -27
- package/dist/module/billing-form.js +25 -19
- package/dist/{esm/justifi-billing-information-form.entry.js → module/billing-form2.js} +61 -19
- package/dist/module/business-bank-account-form-step-core.js +37 -11
- package/dist/module/business-bank-account-form-step.js +0 -1
- package/dist/module/business-terms-conditions-form-step.js +1 -2
- package/dist/module/business.service.js +0 -1
- package/dist/module/button.js +1 -1
- package/dist/module/card-form.js +91 -1
- package/dist/module/card-form2.js +30 -15
- package/dist/module/checkout.service.js +0 -1
- package/dist/module/checkouts-list-core2.js +0 -1
- package/dist/module/dispute-response-actions.js +0 -1
- package/dist/module/form.js +1 -1
- package/dist/module/get-payment-details.js +0 -1
- package/dist/module/get-subaccounts.js +0 -1
- package/dist/module/header-3.js +8 -0
- package/dist/module/justifi-bank-account-form.js +1 -98
- package/dist/module/justifi-billing-information-form.js +1 -89
- package/dist/module/justifi-business-form.js +0 -1
- package/dist/module/justifi-card-form.js +1 -106
- package/dist/module/justifi-checkout-core.js +201 -1
- package/dist/module/justifi-checkout-summary.js +1 -32
- package/dist/module/justifi-checkout.js +104 -109
- package/dist/module/justifi-checkouts-list-filters.js +0 -1
- package/dist/module/justifi-checkouts-list.js +0 -1
- package/dist/module/justifi-gross-payment-chart.js +0 -1
- package/dist/module/justifi-modular-checkout.js +1 -214
- package/dist/module/justifi-new-payment-method.js +214 -1
- package/dist/module/justifi-order-terminals.js +2 -3
- package/dist/module/justifi-payment-provisioning.js +0 -1
- package/dist/module/justifi-payment-transactions-list.js +1 -2
- package/dist/module/justifi-payments-list.js +0 -1
- package/dist/module/justifi-payout-details.js +0 -1
- package/dist/module/justifi-payout-transactions-list.js +1 -2
- package/dist/module/justifi-payouts-list.js +0 -1
- package/dist/module/justifi-postal-code-form.js +1 -81
- package/dist/module/justifi-refund-payment.js +1 -2
- package/dist/module/justifi-saved-payment-method.js +57 -1
- package/dist/module/justifi-saved-payment-methods.js +1 -53
- package/dist/module/justifi-season-interruption-insurance.js +2 -4
- package/dist/module/justifi-sezzle-payment-method.js +1 -108
- package/dist/module/justifi-terminal-orders-list-filters.js +0 -1
- package/dist/module/justifi-terminal-orders-list.js +1 -2
- package/dist/module/justifi-terminals-list-filters.js +0 -1
- package/dist/module/justifi-terminals-list.js +1 -2
- package/dist/module/justifi-tokenize-payment-method.js +8 -75
- package/dist/module/modular-checkout.js +269 -0
- package/dist/module/package.js +1 -1
- package/dist/module/parts.js +1 -1
- package/dist/module/payment-method-options.js +27 -100
- package/dist/module/payment.service.js +0 -1
- package/dist/module/payments-list-core2.js +0 -1
- package/dist/module/payout.service.js +0 -1
- package/dist/module/payouts-list-core2.js +0 -1
- package/dist/module/postal-code-form.js +83 -0
- package/dist/module/save-new-payment-method.js +1 -1
- package/dist/module/saved-payment-methods.js +55 -0
- package/dist/module/schema-validations.js +2 -23
- package/dist/module/season-interruption-insurance-core.js +2 -2
- package/dist/{esm/justifi-sezzle-payment-method.entry.js → module/sezzle-payment-method.js} +46 -14
- package/dist/module/summary.js +34 -0
- package/dist/module/terminal-orders-list-core2.js +0 -1
- package/dist/module/terminal.service.js +0 -1
- package/dist/module/terminals-list-core2.js +0 -1
- package/dist/types/components/business-forms/schemas/schema-validations.d.ts +0 -7
- package/dist/types/components/checkout/checkout.d.ts +19 -9
- package/dist/types/components/checkout/payment-method-options.d.ts +2 -1
- package/dist/types/components/modular-checkout/modular-checkout.d.ts +1 -1
- package/dist/types/components.d.ts +5 -1
- package/dist/webcomponents/p-07e8c50a.entry.js +1 -0
- package/dist/webcomponents/{p-be51c7c5.entry.js → p-0d038c74.entry.js} +1 -1
- package/dist/webcomponents/p-0d24f707.entry.js +1 -0
- package/dist/webcomponents/p-0f07e5d2.entry.js +1 -0
- package/dist/webcomponents/{p-ff223825.entry.js → p-114d2d7e.entry.js} +1 -1
- package/dist/webcomponents/p-16c567ac.entry.js +1 -0
- package/dist/webcomponents/{p-20d7db42.entry.js → p-1debe4fc.entry.js} +1 -1
- package/dist/webcomponents/p-1tXUo5Ef.js +1 -0
- package/dist/webcomponents/{p-ce291c6a.entry.js → p-20ac139f.entry.js} +1 -1
- package/dist/webcomponents/{p-b3e6d27c.entry.js → p-28190487.entry.js} +1 -1
- package/dist/webcomponents/p-30b1b0d4.entry.js +1 -0
- package/dist/webcomponents/{p-1d64d86b.entry.js → p-31b3575b.entry.js} +1 -1
- package/dist/webcomponents/p-32d41de6.entry.js +1 -0
- package/dist/webcomponents/p-3523e4d2.entry.js +1 -0
- package/dist/webcomponents/p-3c172b0a.entry.js +1 -0
- package/dist/webcomponents/{p-5ea3cfca.entry.js → p-498ef7fe.entry.js} +1 -1
- package/dist/webcomponents/p-4cdc323c.entry.js +1 -0
- package/dist/webcomponents/p-54487455.entry.js +1 -0
- package/dist/webcomponents/p-55b2ccd4.entry.js +1 -0
- package/dist/webcomponents/p-56368e10.entry.js +1 -0
- package/dist/webcomponents/{p-712220f9.entry.js → p-62308de3.entry.js} +1 -1
- package/dist/webcomponents/p-655e9c99.entry.js +1 -0
- package/dist/webcomponents/p-6ae0dad9.entry.js +1 -0
- package/dist/webcomponents/p-6ed72565.entry.js +1 -0
- package/dist/webcomponents/{p-8532c68c.entry.js → p-7982b38b.entry.js} +1 -1
- package/dist/webcomponents/p-7efbe6e6.entry.js +1 -0
- package/dist/webcomponents/p-803b249d.entry.js +1 -0
- package/dist/webcomponents/p-819c5da9.entry.js +1 -0
- package/dist/webcomponents/p-85b73bd5.entry.js +1 -0
- package/dist/webcomponents/p-8a2d963a.entry.js +1 -0
- package/dist/webcomponents/p-90521984.entry.js +1 -0
- package/dist/webcomponents/p-93564eb7.entry.js +1 -0
- package/dist/webcomponents/p-95aada97.entry.js +1 -0
- package/dist/webcomponents/{p-df2ad580.entry.js → p-9a4b9734.entry.js} +1 -1
- package/dist/webcomponents/{p-BSUCBhkJ.js → p-B1jCcGW-.js} +1 -1
- package/dist/webcomponents/{p-CwHYDF33.js → p-BRvTM0jE.js} +1 -1
- package/dist/webcomponents/p-BZAglFez.js +1 -0
- package/dist/webcomponents/p-BdTK0wi9.js +1 -0
- package/dist/webcomponents/p-BeOlrj_S.js +1 -0
- package/dist/webcomponents/p-BjIcn6FF.js +1 -0
- package/dist/webcomponents/{p-B7VsiIW-.js → p-BvkP2v3x.js} +1 -1
- package/dist/webcomponents/{p-_6eQgwfE.js → p-C71Mxtso.js} +1 -1
- package/dist/webcomponents/{p-Ctw40vkk.js → p-C8EG4ZSX.js} +1 -1
- package/dist/webcomponents/p-C8rAwXW9.js +1 -0
- package/dist/webcomponents/p-CA9D3qnA.js +1 -0
- package/dist/webcomponents/p-CFpYbRwn.js +1 -0
- package/dist/webcomponents/p-CGCMYhyV.js +1 -0
- package/dist/webcomponents/p-CJdXAC5R.js +1 -0
- package/dist/webcomponents/p-CO90ONTY.js +1 -0
- package/dist/webcomponents/{p-Dw6NWKHn.js → p-Cl-Q3cHB.js} +1 -1
- package/dist/webcomponents/p-DFPGAF4g.js +1 -0
- package/dist/webcomponents/p-DHP6oxsO.js +1 -0
- package/dist/webcomponents/{p-D3SYNGyb.js → p-DLr6u3Be.js} +1 -1
- package/dist/webcomponents/p-DT6jDcoi.js +1 -0
- package/dist/webcomponents/p-DVnVdicA.js +1 -0
- package/dist/webcomponents/p-DX1Drndq.js +1 -0
- package/dist/webcomponents/p-Db-JSm6-.js +1 -0
- package/dist/webcomponents/p-Dc10zfEZ.js +1 -0
- package/dist/webcomponents/p-Dw516k9e.js +1 -0
- package/dist/webcomponents/p-DwxSNAz7.js +1 -0
- package/dist/webcomponents/{p-CnnRWu7z.js → p-Fa3dQnb9.js} +1 -1
- package/dist/webcomponents/p-IrS5pxMU.js +1 -0
- package/dist/webcomponents/p-JOSiCHl7.js +1 -0
- package/dist/webcomponents/p-RadC5UjV.js +1 -0
- package/dist/webcomponents/p-SuXHDcwL.js +1 -0
- package/dist/webcomponents/p-_P2I6GdZ.js +1 -0
- package/dist/webcomponents/p-a3245777.entry.js +1 -0
- package/dist/webcomponents/{p-f7e24a51.entry.js → p-a8f1165e.entry.js} +1 -1
- package/dist/webcomponents/p-abcde13f.entry.js +1 -0
- package/dist/webcomponents/{p-e563df65.entry.js → p-b0c7f45a.entry.js} +1 -1
- package/dist/webcomponents/p-b122d960.entry.js +1 -0
- package/dist/webcomponents/{p-f71b1ff0.entry.js → p-badf50e2.entry.js} +1 -1
- package/dist/webcomponents/p-be676a47.entry.js +1 -0
- package/dist/webcomponents/p-bf9afbe6.entry.js +1 -0
- package/dist/webcomponents/p-c1dabcc9.entry.js +20 -0
- package/dist/webcomponents/p-c4989fc1.entry.js +1 -0
- package/dist/webcomponents/p-c6f6cca0.entry.js +1 -0
- package/dist/webcomponents/{p-d82b509a.entry.js → p-cbfb26e2.entry.js} +1 -1
- package/dist/webcomponents/p-cc26a8fa.entry.js +1 -0
- package/dist/webcomponents/p-cc5dfa3d.entry.js +1 -0
- package/dist/webcomponents/{p-ef9dcfe1.entry.js → p-cc7d0b8c.entry.js} +1 -1
- package/dist/webcomponents/p-d039c1ea.entry.js +1 -0
- package/dist/webcomponents/p-d5f95784.entry.js +1 -0
- package/dist/webcomponents/p-d6tXI5Iw.js +1 -0
- package/dist/webcomponents/p-dad85acd.entry.js +1 -0
- package/dist/webcomponents/{p-3edd5ebd.entry.js → p-db13afe8.entry.js} +1 -1
- package/dist/webcomponents/{p-9a17fd5a.entry.js → p-dd5c8738.entry.js} +1 -1
- package/dist/webcomponents/{p-6b229318.entry.js → p-e2ac6f48.entry.js} +1 -1
- package/dist/webcomponents/{p-1ac365b4.entry.js → p-e2adbafd.entry.js} +1 -1
- package/dist/webcomponents/p-ea883d7c.entry.js +1 -0
- package/dist/webcomponents/{p-15c63931.entry.js → p-ed8eb110.entry.js} +1 -1
- package/dist/webcomponents/{p-e8294f7e.entry.js → p-f0a849be.entry.js} +1 -1
- package/dist/webcomponents/p-f165c5fc.entry.js +1 -0
- package/dist/webcomponents/p-f1dcc9c2.entry.js +1 -0
- package/dist/webcomponents/p-f21e1351.entry.js +1 -0
- package/dist/webcomponents/p-f2d283e5.entry.js +1 -0
- package/dist/webcomponents/p-f55f054a.entry.js +1 -0
- package/dist/webcomponents/p-f7ae2df8.entry.js +1 -0
- package/dist/webcomponents/p-f7ef66ba.entry.js +1 -0
- package/dist/webcomponents/p-f8750427.entry.js +1 -0
- package/dist/webcomponents/p-fa781ff0.entry.js +1 -0
- package/dist/webcomponents/p-fe5b7b4c.entry.js +1 -0
- package/dist/webcomponents/{p-CqVelcDt.js → p-kfHhaHAJ.js} +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/Document-rXGBUaOh.js +0 -58
- package/dist/cjs/bank-account-form_7.cjs.entry.js +0 -411
- package/dist/cjs/billing-form-schema-oZ4GROWP.js +0 -26
- package/dist/cjs/justifi-checkout-summary.cjs.entry.js +0 -21
- package/dist/cjs/justifi-postal-code-form.cjs.entry.js +0 -50
- package/dist/cjs/justifi-saved-payment-methods.cjs.entry.js +0 -31
- package/dist/cjs/justifi-sezzle-payment-method.cjs.entry.js +0 -80
- package/dist/esm/Document-Ct-uNz2r.js +0 -55
- package/dist/esm/bank-account-form_7.entry.js +0 -403
- package/dist/esm/billing-form-schema-PFvYpvy4.js +0 -24
- package/dist/esm/justifi-checkout-summary.entry.js +0 -19
- package/dist/esm/justifi-postal-code-form.entry.js +0 -48
- package/dist/esm/justifi-saved-payment-methods.entry.js +0 -29
- package/dist/module/Document.js +0 -55
- package/dist/module/checkout-actions.js +0 -58
- package/dist/module/checkout-core.js +0 -268
- package/dist/module/new-payment-method.js +0 -204
- package/dist/module/saved-payment-method.js +0 -59
- package/dist/webcomponents/p-00900e52.entry.js +0 -1
- package/dist/webcomponents/p-025ae692.entry.js +0 -1
- package/dist/webcomponents/p-02e26641.entry.js +0 -1
- package/dist/webcomponents/p-04c91ec1.entry.js +0 -1
- package/dist/webcomponents/p-0d5e93b3.entry.js +0 -1
- package/dist/webcomponents/p-19b5f93a.entry.js +0 -1
- package/dist/webcomponents/p-25b310f0.entry.js +0 -1
- package/dist/webcomponents/p-271b131d.entry.js +0 -1
- package/dist/webcomponents/p-2882b4e9.entry.js +0 -1
- package/dist/webcomponents/p-2a08ba01.entry.js +0 -1
- package/dist/webcomponents/p-2f027626.entry.js +0 -1
- package/dist/webcomponents/p-2fa36c0e.entry.js +0 -1
- package/dist/webcomponents/p-379584fb.entry.js +0 -1
- package/dist/webcomponents/p-39f31e23.entry.js +0 -1
- package/dist/webcomponents/p-3b6888c5.entry.js +0 -1
- package/dist/webcomponents/p-3d62f9a5.entry.js +0 -1
- package/dist/webcomponents/p-4232760b.entry.js +0 -1
- package/dist/webcomponents/p-4be4f7b4.entry.js +0 -1
- package/dist/webcomponents/p-531738ae.entry.js +0 -1
- package/dist/webcomponents/p-54019e68.entry.js +0 -1
- package/dist/webcomponents/p-584ba20d.entry.js +0 -1
- package/dist/webcomponents/p-5bc6f1e6.entry.js +0 -20
- package/dist/webcomponents/p-5bfbb0f8.entry.js +0 -1
- package/dist/webcomponents/p-5da3ba38.entry.js +0 -1
- package/dist/webcomponents/p-5f9dbaff.entry.js +0 -1
- package/dist/webcomponents/p-6fc1ace5.entry.js +0 -1
- package/dist/webcomponents/p-716d41f2.entry.js +0 -1
- package/dist/webcomponents/p-7253f1ea.entry.js +0 -1
- package/dist/webcomponents/p-80b662de.entry.js +0 -1
- package/dist/webcomponents/p-82164a5e.entry.js +0 -1
- package/dist/webcomponents/p-8590c5df.entry.js +0 -1
- package/dist/webcomponents/p-8e555a6e.entry.js +0 -1
- package/dist/webcomponents/p-96f89c69.entry.js +0 -1
- package/dist/webcomponents/p-98a39544.entry.js +0 -1
- package/dist/webcomponents/p-9a9f9c57.entry.js +0 -1
- package/dist/webcomponents/p-B4MIwTdb.js +0 -1
- package/dist/webcomponents/p-B8Ovjy6S.js +0 -1
- package/dist/webcomponents/p-BE5Nvydk.js +0 -1
- package/dist/webcomponents/p-BGHVK-vQ.js +0 -1
- package/dist/webcomponents/p-BPCw4WEY.js +0 -1
- package/dist/webcomponents/p-BhLPwu1L.js +0 -1
- package/dist/webcomponents/p-Bond4qGX.js +0 -1
- package/dist/webcomponents/p-BpEw7AJl.js +0 -1
- package/dist/webcomponents/p-C-WgCIei.js +0 -1
- package/dist/webcomponents/p-CCpqJxzB.js +0 -1
- package/dist/webcomponents/p-CLpgfEbx.js +0 -1
- package/dist/webcomponents/p-CRYPNa2o.js +0 -1
- package/dist/webcomponents/p-CeNlJX4-.js +0 -1
- package/dist/webcomponents/p-Ct-uNz2r.js +0 -1
- package/dist/webcomponents/p-CvChBLtI.js +0 -1
- package/dist/webcomponents/p-CyXXks-Q.js +0 -1
- package/dist/webcomponents/p-Czro_9VO.js +0 -1
- package/dist/webcomponents/p-D7js9xfx.js +0 -1
- package/dist/webcomponents/p-DOB09NZD.js +0 -1
- package/dist/webcomponents/p-DUdzWNqB.js +0 -1
- package/dist/webcomponents/p-DaS3t0DL.js +0 -1
- package/dist/webcomponents/p-Dge4w7_c.js +0 -1
- package/dist/webcomponents/p-DkWBoLsd.js +0 -1
- package/dist/webcomponents/p-DknV-QPT.js +0 -1
- package/dist/webcomponents/p-DuiQuWNq.js +0 -1
- package/dist/webcomponents/p-DzPrenCi.js +0 -1
- package/dist/webcomponents/p-YDuIVoos.js +0 -1
- package/dist/webcomponents/p-a2db11b5.entry.js +0 -1
- package/dist/webcomponents/p-a31913e3.entry.js +0 -1
- package/dist/webcomponents/p-a4d457e9.entry.js +0 -1
- package/dist/webcomponents/p-b8ee41c1.entry.js +0 -1
- package/dist/webcomponents/p-bde749ac.entry.js +0 -1
- package/dist/webcomponents/p-bf16b11c.entry.js +0 -1
- package/dist/webcomponents/p-d9b06582.entry.js +0 -1
- package/dist/webcomponents/p-dbc02ba8.entry.js +0 -1
- package/dist/webcomponents/p-dcad0df5.entry.js +0 -1
- package/dist/webcomponents/p-e03630ec.entry.js +0 -1
- package/dist/webcomponents/p-e07sVz4Z.js +0 -1
- package/dist/webcomponents/p-ec9bb3f6.entry.js +0 -1
- package/dist/webcomponents/p-ecf6a315.entry.js +0 -1
|
@@ -1,4 +1,217 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
+
import { W as radioListItem } from './parts.js';
|
|
3
|
+
import { d as defineCustomElement$g } from './custom-popper2.js';
|
|
4
|
+
import { d as defineCustomElement$f } from './form-control-checkbox2.js';
|
|
5
|
+
import { d as defineCustomElement$e } from './form-control-help-text2.js';
|
|
6
|
+
import { d as defineCustomElement$d } from './form-control-radio2.js';
|
|
7
|
+
import { d as defineCustomElement$c } from './form-control-select2.js';
|
|
8
|
+
import { d as defineCustomElement$b } from './form-control-text2.js';
|
|
9
|
+
import { d as defineCustomElement$a } from './form-control-tooltip2.js';
|
|
10
|
+
import { d as defineCustomElement$9 } from './hidden-input2.js';
|
|
11
|
+
import { d as defineCustomElement$8 } from './iframe-input2.js';
|
|
12
|
+
import { d as defineCustomElement$7 } from './bank-account.js';
|
|
13
|
+
import { d as defineCustomElement$6 } from './billing-form.js';
|
|
14
|
+
import { d as defineCustomElement$5 } from './billing-form2.js';
|
|
15
|
+
import { d as defineCustomElement$4 } from './card-form2.js';
|
|
16
|
+
import { d as defineCustomElement$3 } from './postal-code-form.js';
|
|
17
|
+
import { d as defineCustomElement$2 } from './save-new-payment-method.js';
|
|
18
|
+
|
|
19
|
+
const PaymentMethodTypeLabels = {
|
|
20
|
+
bankAccount: 'New bank account',
|
|
21
|
+
card: 'New credit or debit card',
|
|
22
|
+
};
|
|
23
|
+
const NewPaymentMethod = /*@__PURE__*/ proxyCustomElement(class NewPaymentMethod extends HTMLElement {
|
|
24
|
+
constructor() {
|
|
25
|
+
super();
|
|
26
|
+
this.__registerHost();
|
|
27
|
+
this.paymentMethodOptionSelected = createEvent(this, "paymentMethodOptionSelected", 7);
|
|
28
|
+
this.saveNewPaymentMethodChecked = false;
|
|
29
|
+
this.onPaymentMethodOptionClick = (e) => {
|
|
30
|
+
e.preventDefault();
|
|
31
|
+
this.paymentMethodOptionSelected.emit(this.paymentMethodOption);
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
handleCheckboxChanged(event) {
|
|
35
|
+
this.saveNewPaymentMethodChecked = event.detail;
|
|
36
|
+
}
|
|
37
|
+
async fillBillingForm(fields) {
|
|
38
|
+
this.billingFormRef.fill(fields);
|
|
39
|
+
}
|
|
40
|
+
async resolvePaymentMethod(insuranceValidation) {
|
|
41
|
+
var _a, _b;
|
|
42
|
+
if (!this.paymentMethodFormRef || !this.billingFormRef)
|
|
43
|
+
return;
|
|
44
|
+
try {
|
|
45
|
+
const { isValid, errors } = await this.validate();
|
|
46
|
+
if (!isValid || !insuranceValidation.isValid) {
|
|
47
|
+
// get propety value from first property in errors object
|
|
48
|
+
const message = `${Object.values(errors)[0] || 'Validation error'}`;
|
|
49
|
+
return {
|
|
50
|
+
validationError: true,
|
|
51
|
+
error: {
|
|
52
|
+
code: 'validation_error',
|
|
53
|
+
message,
|
|
54
|
+
decline_code: undefined
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
const tokenizeResponse = await this.tokenize();
|
|
59
|
+
if (tokenizeResponse.error) {
|
|
60
|
+
return { error: tokenizeResponse.error };
|
|
61
|
+
}
|
|
62
|
+
else {
|
|
63
|
+
const tokenizeRessponseData = tokenizeResponse.data;
|
|
64
|
+
return {
|
|
65
|
+
token: ((_a = tokenizeRessponseData.card) === null || _a === void 0 ? void 0 : _a.token) || ((_b = tokenizeRessponseData.bank_account) === null || _b === void 0 ? void 0 : _b.token),
|
|
66
|
+
data: tokenizeRessponseData
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
catch (error) {
|
|
71
|
+
return { error };
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
async validate() {
|
|
75
|
+
const billingFormValidation = await this.billingFormRef.validate();
|
|
76
|
+
const paymentMethodFormValidation = await this.paymentMethodFormRef.validate();
|
|
77
|
+
const isValid = billingFormValidation.isValid && paymentMethodFormValidation.isValid;
|
|
78
|
+
const errors = Object.assign(Object.assign({}, billingFormValidation.errors), paymentMethodFormValidation.errors);
|
|
79
|
+
return { isValid, errors };
|
|
80
|
+
}
|
|
81
|
+
async tokenize() {
|
|
82
|
+
try {
|
|
83
|
+
const billingFormFieldValues = await this.billingFormRef.getValues();
|
|
84
|
+
let paymentMethodData;
|
|
85
|
+
if (this.saveNewPaymentMethodChecked) {
|
|
86
|
+
paymentMethodData = Object.assign(Object.assign({}, billingFormFieldValues), { payment_method_group_id: this.paymentMethodGroupId });
|
|
87
|
+
}
|
|
88
|
+
else {
|
|
89
|
+
paymentMethodData = Object.assign({}, billingFormFieldValues);
|
|
90
|
+
}
|
|
91
|
+
const clientId = this.authToken;
|
|
92
|
+
const tokenizeResponse = await this.paymentMethodFormRef.tokenize(clientId, paymentMethodData, this.accountId);
|
|
93
|
+
return tokenizeResponse;
|
|
94
|
+
}
|
|
95
|
+
catch (error) {
|
|
96
|
+
return error;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
showNewPaymentMethodForm() {
|
|
100
|
+
var _a;
|
|
101
|
+
const paymentMethodType = (_a = this.paymentMethodOption) === null || _a === void 0 ? void 0 : _a.id;
|
|
102
|
+
return (h("div", { class: "mt-4 pb-4" }, h("hidden-input", null), paymentMethodType === 'card' ? (h("justifi-card-form", null)) : (h("justifi-bank-account-form", null)), h("justifi-billing-form", { hideCardBillingForm: this.hideCardBillingForm, hideBankAccountBillingForm: this.hideBankAccountBillingForm, paymentMethodType: paymentMethodType }), h("justifi-save-new-payment-method", { hidden: !this.paymentMethodGroupId })));
|
|
103
|
+
}
|
|
104
|
+
get hiddenRadioInput() {
|
|
105
|
+
return !this.showAch || !this.showCard;
|
|
106
|
+
}
|
|
107
|
+
render() {
|
|
108
|
+
var _a, _b;
|
|
109
|
+
return (h(Host, { key: '86a50eecba10706b674e3517c7b1e5ba6674035a', class: "payment-method" }, h("div", { key: '54ec6ea1d0eb1f1bcbb0b5c145858a270dc7ccf4', class: "radio-list-item p-3", part: radioListItem, onClick: this.onPaymentMethodOptionClick, hidden: this.hiddenRadioInput }, h("form-control-radio", { key: '348ab53888c29f3b942f2698dcb72450d73ed90d', name: "paymentMethodType", value: (_a = this.paymentMethodOption) === null || _a === void 0 ? void 0 : _a.id, checked: this.isSelected, label: PaymentMethodTypeLabels[(_b = this.paymentMethodOption) === null || _b === void 0 ? void 0 : _b.id] })), this.isSelected ? this.showNewPaymentMethodForm() : null));
|
|
110
|
+
}
|
|
111
|
+
}, [0, "justifi-new-payment-method", {
|
|
112
|
+
"authToken": [1, "auth-token"],
|
|
113
|
+
"accountId": [1, "account-id"],
|
|
114
|
+
"paymentMethodOption": [16, "payment-method-option"],
|
|
115
|
+
"paymentMethodGroupId": [1, "payment-method-group-id"],
|
|
116
|
+
"isSelected": [4, "is-selected"],
|
|
117
|
+
"showCard": [4, "show-card"],
|
|
118
|
+
"showAch": [4, "show-ach"],
|
|
119
|
+
"hideCardBillingForm": [4, "hide-card-billing-form"],
|
|
120
|
+
"hideBankAccountBillingForm": [4, "hide-bank-account-billing-form"],
|
|
121
|
+
"saveNewPaymentMethodChecked": [32],
|
|
122
|
+
"fillBillingForm": [64],
|
|
123
|
+
"resolvePaymentMethod": [64],
|
|
124
|
+
"validate": [64]
|
|
125
|
+
}, [[0, "checkboxChanged", "handleCheckboxChanged"]]]);
|
|
126
|
+
function defineCustomElement$1() {
|
|
127
|
+
if (typeof customElements === "undefined") {
|
|
128
|
+
return;
|
|
129
|
+
}
|
|
130
|
+
const components = ["justifi-new-payment-method", "custom-popper", "form-control-checkbox", "form-control-help-text", "form-control-radio", "form-control-select", "form-control-text", "form-control-tooltip", "hidden-input", "iframe-input", "justifi-bank-account-form", "justifi-billing-form", "justifi-billing-information-form", "justifi-card-form", "justifi-postal-code-form", "justifi-save-new-payment-method"];
|
|
131
|
+
components.forEach(tagName => { switch (tagName) {
|
|
132
|
+
case "justifi-new-payment-method":
|
|
133
|
+
if (!customElements.get(tagName)) {
|
|
134
|
+
customElements.define(tagName, NewPaymentMethod);
|
|
135
|
+
}
|
|
136
|
+
break;
|
|
137
|
+
case "custom-popper":
|
|
138
|
+
if (!customElements.get(tagName)) {
|
|
139
|
+
defineCustomElement$g();
|
|
140
|
+
}
|
|
141
|
+
break;
|
|
142
|
+
case "form-control-checkbox":
|
|
143
|
+
if (!customElements.get(tagName)) {
|
|
144
|
+
defineCustomElement$f();
|
|
145
|
+
}
|
|
146
|
+
break;
|
|
147
|
+
case "form-control-help-text":
|
|
148
|
+
if (!customElements.get(tagName)) {
|
|
149
|
+
defineCustomElement$e();
|
|
150
|
+
}
|
|
151
|
+
break;
|
|
152
|
+
case "form-control-radio":
|
|
153
|
+
if (!customElements.get(tagName)) {
|
|
154
|
+
defineCustomElement$d();
|
|
155
|
+
}
|
|
156
|
+
break;
|
|
157
|
+
case "form-control-select":
|
|
158
|
+
if (!customElements.get(tagName)) {
|
|
159
|
+
defineCustomElement$c();
|
|
160
|
+
}
|
|
161
|
+
break;
|
|
162
|
+
case "form-control-text":
|
|
163
|
+
if (!customElements.get(tagName)) {
|
|
164
|
+
defineCustomElement$b();
|
|
165
|
+
}
|
|
166
|
+
break;
|
|
167
|
+
case "form-control-tooltip":
|
|
168
|
+
if (!customElements.get(tagName)) {
|
|
169
|
+
defineCustomElement$a();
|
|
170
|
+
}
|
|
171
|
+
break;
|
|
172
|
+
case "hidden-input":
|
|
173
|
+
if (!customElements.get(tagName)) {
|
|
174
|
+
defineCustomElement$9();
|
|
175
|
+
}
|
|
176
|
+
break;
|
|
177
|
+
case "iframe-input":
|
|
178
|
+
if (!customElements.get(tagName)) {
|
|
179
|
+
defineCustomElement$8();
|
|
180
|
+
}
|
|
181
|
+
break;
|
|
182
|
+
case "justifi-bank-account-form":
|
|
183
|
+
if (!customElements.get(tagName)) {
|
|
184
|
+
defineCustomElement$7();
|
|
185
|
+
}
|
|
186
|
+
break;
|
|
187
|
+
case "justifi-billing-form":
|
|
188
|
+
if (!customElements.get(tagName)) {
|
|
189
|
+
defineCustomElement$6();
|
|
190
|
+
}
|
|
191
|
+
break;
|
|
192
|
+
case "justifi-billing-information-form":
|
|
193
|
+
if (!customElements.get(tagName)) {
|
|
194
|
+
defineCustomElement$5();
|
|
195
|
+
}
|
|
196
|
+
break;
|
|
197
|
+
case "justifi-card-form":
|
|
198
|
+
if (!customElements.get(tagName)) {
|
|
199
|
+
defineCustomElement$4();
|
|
200
|
+
}
|
|
201
|
+
break;
|
|
202
|
+
case "justifi-postal-code-form":
|
|
203
|
+
if (!customElements.get(tagName)) {
|
|
204
|
+
defineCustomElement$3();
|
|
205
|
+
}
|
|
206
|
+
break;
|
|
207
|
+
case "justifi-save-new-payment-method":
|
|
208
|
+
if (!customElements.get(tagName)) {
|
|
209
|
+
defineCustomElement$2();
|
|
210
|
+
}
|
|
211
|
+
break;
|
|
212
|
+
} });
|
|
213
|
+
}
|
|
214
|
+
defineCustomElement$1();
|
|
2
215
|
|
|
3
216
|
const JustifiNewPaymentMethod = NewPaymentMethod;
|
|
4
217
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h, proxyCustomElement, HTMLElement, createEvent } from '@stencil/core/internal/client';
|
|
2
|
-
import { X as heading4, _ as heading5,
|
|
2
|
+
import { X as heading4, _ as heading5, a0 as buttonPrimary, t as text } from './parts.js';
|
|
3
3
|
import { S as StyledHost } from './styled-host.js';
|
|
4
4
|
import './details.js';
|
|
5
5
|
import './event-types.js';
|
|
@@ -13,8 +13,7 @@ import './config-state.js';
|
|
|
13
13
|
import { n as formatPhoneNumber } from './utils2.js';
|
|
14
14
|
import './Pagination.js';
|
|
15
15
|
import './Payment.js';
|
|
16
|
-
import {
|
|
17
|
-
import './Document.js';
|
|
16
|
+
import { h as TerminalModel, g as TerminalOrder, a as TerminalOrderType } from './Refund.js';
|
|
18
17
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
19
18
|
import { T as TerminalService } from './terminal.service.js';
|
|
20
19
|
import { d as defineCustomElement$4 } from './custom-popper2.js';
|
|
@@ -7,7 +7,6 @@ import { A as Api } from './Api.js';
|
|
|
7
7
|
import './Pagination.js';
|
|
8
8
|
import './Payment.js';
|
|
9
9
|
import './Refund.js';
|
|
10
|
-
import './Document.js';
|
|
11
10
|
import './Business.js';
|
|
12
11
|
import { d as defineCustomElement$y } from './bank-account-document-inputs.js';
|
|
13
12
|
import { d as defineCustomElement$x } from './bank-account-form-inputs2.js';
|
|
@@ -4,8 +4,7 @@ import { h as convertToLocal } from './utils2.js';
|
|
|
4
4
|
import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkout.js';
|
|
5
5
|
import { p as pagingDefaults } from './Pagination.js';
|
|
6
6
|
import './Payment.js';
|
|
7
|
-
import {
|
|
8
|
-
import './Document.js';
|
|
7
|
+
import { e as PaymentBalanceTransaction } from './Refund.js';
|
|
9
8
|
import './Business.js';
|
|
10
9
|
import { c as checkPkgVersion, J as JustifiAnalytics } from './Analytics.js';
|
|
11
10
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
@@ -6,7 +6,6 @@ import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkou
|
|
|
6
6
|
import './Pagination.js';
|
|
7
7
|
import { b as Payment } from './Payment.js';
|
|
8
8
|
import './Refund.js';
|
|
9
|
-
import './Document.js';
|
|
10
9
|
import './Business.js';
|
|
11
10
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
12
11
|
import { c as checkPkgVersion, J as JustifiAnalytics } from './Analytics.js';
|
|
@@ -6,7 +6,6 @@ import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkou
|
|
|
6
6
|
import './Pagination.js';
|
|
7
7
|
import './Payment.js';
|
|
8
8
|
import { P as Payout } from './Refund.js';
|
|
9
|
-
import './Document.js';
|
|
10
9
|
import './Business.js';
|
|
11
10
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
12
11
|
import { E as ErrorState } from './utils.js';
|
|
@@ -4,8 +4,7 @@ import { h as convertToLocal } from './utils2.js';
|
|
|
4
4
|
import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkout.js';
|
|
5
5
|
import { p as pagingDefaults } from './Pagination.js';
|
|
6
6
|
import './Payment.js';
|
|
7
|
-
import {
|
|
8
|
-
import './Document.js';
|
|
7
|
+
import { f as PayoutBalanceTransaction } from './Refund.js';
|
|
9
8
|
import './Business.js';
|
|
10
9
|
import { c as checkPkgVersion, J as JustifiAnalytics } from './Analytics.js';
|
|
11
10
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
@@ -7,7 +7,6 @@ import './utils2.js';
|
|
|
7
7
|
import './Pagination.js';
|
|
8
8
|
import './Payment.js';
|
|
9
9
|
import { P as Payout } from './Refund.js';
|
|
10
|
-
import './Document.js';
|
|
11
10
|
import './Business.js';
|
|
12
11
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
13
12
|
import { m as makeGetPayoutCSV } from './get-payout-csv.js';
|
|
@@ -1,84 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { S as StyledHost } from './styled-host.js';
|
|
3
|
-
import './details.js';
|
|
4
|
-
import './event-types.js';
|
|
5
|
-
import { n as numberOnlyHandler } from './utils3.js';
|
|
6
|
-
import { F as FormController } from './form.js';
|
|
7
|
-
import { b as billingFormSchema } from './billing-form-schema.js';
|
|
8
|
-
import { d as defineCustomElement$4 } from './custom-popper2.js';
|
|
9
|
-
import { d as defineCustomElement$3 } from './form-control-text2.js';
|
|
10
|
-
import { d as defineCustomElement$2 } from './form-control-tooltip2.js';
|
|
11
|
-
|
|
12
|
-
const PostalCodeForm = /*@__PURE__*/ proxyCustomElement(class PostalCodeForm extends HTMLElement {
|
|
13
|
-
constructor() {
|
|
14
|
-
super();
|
|
15
|
-
this.__registerHost();
|
|
16
|
-
this.__attachShadow();
|
|
17
|
-
this.errors = {};
|
|
18
|
-
this.inputHandler = (name, value) => {
|
|
19
|
-
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { [name]: value }));
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
componentWillLoad() {
|
|
23
|
-
this.formController = new FormController(billingFormSchema(true));
|
|
24
|
-
}
|
|
25
|
-
componentDidLoad() {
|
|
26
|
-
this.formController.values.subscribe(values => this.billingInfo = Object.assign({}, values));
|
|
27
|
-
this.formController.errors.subscribe(errors => {
|
|
28
|
-
this.errors = Object.assign({}, errors);
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
async getValues() {
|
|
32
|
-
return this.formController.values.getValue();
|
|
33
|
-
}
|
|
34
|
-
async fill(fields) {
|
|
35
|
-
this.formController.setInitialValues(fields);
|
|
36
|
-
}
|
|
37
|
-
async validate() {
|
|
38
|
-
let isValid = await this.formController.validate();
|
|
39
|
-
return { isValid: isValid };
|
|
40
|
-
}
|
|
41
|
-
render() {
|
|
42
|
-
const billingFormDefaultValue = this.formController.getInitialValues();
|
|
43
|
-
return (h(StyledHost, { key: 'e5cdb9b21be1e5f4ee6fd21a2d919b2d9271b163' }, h("form", { key: '29c0a3edaad9877d50ecc9e4424ca2f5e667dc30' }, h("form-control-text", { key: '00e8688c8a8e9b91df5089e2fb97c8b71673a3fd', name: 'address_postal_code', label: "ZIP", defaultValue: billingFormDefaultValue.address_postal_code, errorText: this.errors.address_postal_code, inputHandler: this.inputHandler, maxLength: 5, keyDownHandler: numberOnlyHandler }))));
|
|
44
|
-
}
|
|
45
|
-
}, [1, "justifi-postal-code-form", {
|
|
46
|
-
"formController": [32],
|
|
47
|
-
"billingInfo": [32],
|
|
48
|
-
"errors": [32],
|
|
49
|
-
"getValues": [64],
|
|
50
|
-
"fill": [64],
|
|
51
|
-
"validate": [64]
|
|
52
|
-
}]);
|
|
53
|
-
function defineCustomElement$1() {
|
|
54
|
-
if (typeof customElements === "undefined") {
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
const components = ["justifi-postal-code-form", "custom-popper", "form-control-text", "form-control-tooltip"];
|
|
58
|
-
components.forEach(tagName => { switch (tagName) {
|
|
59
|
-
case "justifi-postal-code-form":
|
|
60
|
-
if (!customElements.get(tagName)) {
|
|
61
|
-
customElements.define(tagName, PostalCodeForm);
|
|
62
|
-
}
|
|
63
|
-
break;
|
|
64
|
-
case "custom-popper":
|
|
65
|
-
if (!customElements.get(tagName)) {
|
|
66
|
-
defineCustomElement$4();
|
|
67
|
-
}
|
|
68
|
-
break;
|
|
69
|
-
case "form-control-text":
|
|
70
|
-
if (!customElements.get(tagName)) {
|
|
71
|
-
defineCustomElement$3();
|
|
72
|
-
}
|
|
73
|
-
break;
|
|
74
|
-
case "form-control-tooltip":
|
|
75
|
-
if (!customElements.get(tagName)) {
|
|
76
|
-
defineCustomElement$2();
|
|
77
|
-
}
|
|
78
|
-
break;
|
|
79
|
-
} });
|
|
80
|
-
}
|
|
81
|
-
defineCustomElement$1();
|
|
1
|
+
import { P as PostalCodeForm, d as defineCustomElement$1 } from './postal-code-form.js';
|
|
82
2
|
|
|
83
3
|
const JustifiPostalCodeForm = PostalCodeForm;
|
|
84
4
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -5,8 +5,7 @@ import './config-state.js';
|
|
|
5
5
|
import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkout.js';
|
|
6
6
|
import './Pagination.js';
|
|
7
7
|
import './Payment.js';
|
|
8
|
-
import { R as RefundReasons,
|
|
9
|
-
import './Document.js';
|
|
8
|
+
import { R as RefundReasons, i as RefundPayload } from './Refund.js';
|
|
10
9
|
import './Business.js';
|
|
11
10
|
import { B as Button } from './button.js';
|
|
12
11
|
import { S as StyledHost } from './styled-host.js';
|
|
@@ -1,4 +1,60 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
+
import { C as CardBrandLabels } from './payment-method-option-utils.js';
|
|
3
|
+
import { W as radioListItem } from './parts.js';
|
|
4
|
+
import { d as defineCustomElement$3 } from './form-control-help-text2.js';
|
|
5
|
+
import { d as defineCustomElement$2 } from './form-control-radio2.js';
|
|
6
|
+
|
|
7
|
+
const SavedPaymentMethod = /*@__PURE__*/ proxyCustomElement(class SavedPaymentMethod extends HTMLElement {
|
|
8
|
+
constructor() {
|
|
9
|
+
super();
|
|
10
|
+
this.__registerHost();
|
|
11
|
+
this.paymentMethodOptionSelected = createEvent(this, "paymentMethodOptionSelected", 7);
|
|
12
|
+
this.onPaymentMethodOptionClick = (e) => {
|
|
13
|
+
e.preventDefault();
|
|
14
|
+
this.paymentMethodOptionSelected.emit(this.paymentMethodOption);
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
async resolvePaymentMethod(insuranceValidation) {
|
|
18
|
+
var _a;
|
|
19
|
+
if (!insuranceValidation.isValid) {
|
|
20
|
+
return { validationError: true };
|
|
21
|
+
}
|
|
22
|
+
return { token: (_a = this.paymentMethodOption) === null || _a === void 0 ? void 0 : _a.id };
|
|
23
|
+
}
|
|
24
|
+
;
|
|
25
|
+
render() {
|
|
26
|
+
var _a, _b, _c;
|
|
27
|
+
return (h(Host, { key: '96a1e315728d17d67ef35f2a269210ec28b7eb24', class: "payment-method" }, h("div", { key: 'fb9edf8f6a5a2f76138a83f36c949ffdee4f0f01', class: "radio-list-item p-3", part: radioListItem, onClick: this.onPaymentMethodOptionClick }, h("form-control-radio", { key: '14388b6e3ba9e631719587b798485e4d30664639', name: "paymentMethodType", value: (_a = this.paymentMethodOption) === null || _a === void 0 ? void 0 : _a.id, checked: this.isSelected, label: `${CardBrandLabels[(_b = this.paymentMethodOption) === null || _b === void 0 ? void 0 : _b.brand] || ''} *${(_c = this.paymentMethodOption) === null || _c === void 0 ? void 0 : _c.acct_last_four}` }))));
|
|
28
|
+
}
|
|
29
|
+
}, [0, "justifi-saved-payment-method", {
|
|
30
|
+
"paymentMethodOption": [16, "payment-method-option"],
|
|
31
|
+
"isSelected": [4, "is-selected"],
|
|
32
|
+
"resolvePaymentMethod": [64]
|
|
33
|
+
}]);
|
|
34
|
+
function defineCustomElement$1() {
|
|
35
|
+
if (typeof customElements === "undefined") {
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
const components = ["justifi-saved-payment-method", "form-control-help-text", "form-control-radio"];
|
|
39
|
+
components.forEach(tagName => { switch (tagName) {
|
|
40
|
+
case "justifi-saved-payment-method":
|
|
41
|
+
if (!customElements.get(tagName)) {
|
|
42
|
+
customElements.define(tagName, SavedPaymentMethod);
|
|
43
|
+
}
|
|
44
|
+
break;
|
|
45
|
+
case "form-control-help-text":
|
|
46
|
+
if (!customElements.get(tagName)) {
|
|
47
|
+
defineCustomElement$3();
|
|
48
|
+
}
|
|
49
|
+
break;
|
|
50
|
+
case "form-control-radio":
|
|
51
|
+
if (!customElements.get(tagName)) {
|
|
52
|
+
defineCustomElement$2();
|
|
53
|
+
}
|
|
54
|
+
break;
|
|
55
|
+
} });
|
|
56
|
+
}
|
|
57
|
+
defineCustomElement$1();
|
|
2
58
|
|
|
3
59
|
const JustifiSavedPaymentMethod = SavedPaymentMethod;
|
|
4
60
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -1,56 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { W as radioListItem } from './parts.js';
|
|
3
|
-
import { S as StyledHost } from './styled-host.js';
|
|
4
|
-
import './details.js';
|
|
5
|
-
import './event-types.js';
|
|
6
|
-
import { s as state } from './checkout.store.js';
|
|
7
|
-
import { C as CardBrandLabels } from './payment-method-option-utils.js';
|
|
8
|
-
import { d as defineCustomElement$3 } from './form-control-help-text2.js';
|
|
9
|
-
import { d as defineCustomElement$2 } from './form-control-radio2.js';
|
|
10
|
-
|
|
11
|
-
const SavedPaymentMethods = /*@__PURE__*/ proxyCustomElement(class SavedPaymentMethods extends HTMLElement {
|
|
12
|
-
constructor() {
|
|
13
|
-
super();
|
|
14
|
-
this.__registerHost();
|
|
15
|
-
this.__attachShadow();
|
|
16
|
-
this.onPaymentMethodOptionClick = (paymentMethodId) => (e) => {
|
|
17
|
-
e.preventDefault();
|
|
18
|
-
state.selectedPaymentMethod = paymentMethodId;
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
componentWillLoad() {
|
|
22
|
-
if (!state.paymentMethods.length) {
|
|
23
|
-
console.warn('No saved payment methods available.');
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
render() {
|
|
27
|
-
return (h(StyledHost, { key: '7bebb3f8ff2a2abe400e1d099154a1729913140c' }, h("div", { key: '3a5798c5ceba63160dceecb0dc65f8a211bb5110', class: "saved-payment-methods" }, state.paymentMethods.length ? state.paymentMethods.map((paymentMethod) => (h("div", { class: "radio-list-item p-3", part: radioListItem, onClick: this.onPaymentMethodOptionClick(paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id) }, h("form-control-radio", { name: "paymentMethodType", value: paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id, checked: state.selectedPaymentMethod === (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id), label: `${CardBrandLabels[paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.brand] || ''} *${paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.acct_last_four}` })))) : null)));
|
|
28
|
-
}
|
|
29
|
-
}, [1, "justifi-saved-payment-methods"]);
|
|
30
|
-
function defineCustomElement$1() {
|
|
31
|
-
if (typeof customElements === "undefined") {
|
|
32
|
-
return;
|
|
33
|
-
}
|
|
34
|
-
const components = ["justifi-saved-payment-methods", "form-control-help-text", "form-control-radio"];
|
|
35
|
-
components.forEach(tagName => { switch (tagName) {
|
|
36
|
-
case "justifi-saved-payment-methods":
|
|
37
|
-
if (!customElements.get(tagName)) {
|
|
38
|
-
customElements.define(tagName, SavedPaymentMethods);
|
|
39
|
-
}
|
|
40
|
-
break;
|
|
41
|
-
case "form-control-help-text":
|
|
42
|
-
if (!customElements.get(tagName)) {
|
|
43
|
-
defineCustomElement$3();
|
|
44
|
-
}
|
|
45
|
-
break;
|
|
46
|
-
case "form-control-radio":
|
|
47
|
-
if (!customElements.get(tagName)) {
|
|
48
|
-
defineCustomElement$2();
|
|
49
|
-
}
|
|
50
|
-
break;
|
|
51
|
-
} });
|
|
52
|
-
}
|
|
53
|
-
defineCustomElement$1();
|
|
1
|
+
import { S as SavedPaymentMethods, d as defineCustomElement$1 } from './saved-payment-methods.js';
|
|
54
2
|
|
|
55
3
|
const JustifiSavedPaymentMethods = SavedPaymentMethods;
|
|
56
4
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -4,7 +4,6 @@ import { C as ComponentErrorSeverity, a as ComponentErrorCodes } from './Checkou
|
|
|
4
4
|
import './Pagination.js';
|
|
5
5
|
import './Payment.js';
|
|
6
6
|
import './Refund.js';
|
|
7
|
-
import './Document.js';
|
|
8
7
|
import './Business.js';
|
|
9
8
|
import { g as getErrorCode, a as getErrorMessage } from './utils4.js';
|
|
10
9
|
import { c as checkPkgVersion, J as JustifiAnalytics } from './Analytics.js';
|
|
@@ -86,7 +85,6 @@ const SeasonInterruptionInsurance = /*@__PURE__*/ proxyCustomElement(class Seaso
|
|
|
86
85
|
constructor() {
|
|
87
86
|
super();
|
|
88
87
|
this.__registerHost();
|
|
89
|
-
this.__attachShadow();
|
|
90
88
|
this.errorEvent = createEvent(this, "error-event", 7);
|
|
91
89
|
}
|
|
92
90
|
async validate() {
|
|
@@ -117,9 +115,9 @@ const SeasonInterruptionInsurance = /*@__PURE__*/ proxyCustomElement(class Seaso
|
|
|
117
115
|
this.toggleCoverage = makeToggleCoverage(config);
|
|
118
116
|
}
|
|
119
117
|
render() {
|
|
120
|
-
return (h("justifi-season-interruption-insurance-core", { key: '
|
|
118
|
+
return (h("justifi-season-interruption-insurance-core", { key: 'a6354b724c14651a84d7ac7226fa12132d152b7d', ref: (el) => (this.seasonInterruptionCoreRef = el), "checkout-id": this.checkoutId || state.checkoutId, getQuote: this.getQuote, toggleCoverage: this.toggleCoverage, "primary-identity-first-name": this.primaryIdentityFirstName, "primary-identity-last-name": this.primaryIdentityLastName, "primary-identity-state": this.primaryIdentityState, "primary-identity-postal-code": this.primaryIdentityPostalCode, "primary-identity-country": this.primaryIdentityCountry, "primary-identity-email-address": this.primaryIdentityEmailAddress, "policy-attributes-insurable-amount": this.policyAttributesInsurableAmount, "policy-attributes-start-date": this.policyAttributesStartDate, "policy-attributes-end-date": this.policyAttributesEndDate, "covered-identity-first-name": this.coveredIdentityFirstName, "covered-identity-last-name": this.coveredIdentityLastName }));
|
|
121
119
|
}
|
|
122
|
-
}, [
|
|
120
|
+
}, [0, "justifi-season-interruption-insurance", {
|
|
123
121
|
"authToken": [1, "auth-token"],
|
|
124
122
|
"checkoutId": [1, "checkout-id"],
|
|
125
123
|
"primaryIdentityFirstName": [1, "primary-identity-first-name"],
|
|
@@ -1,111 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { c as formatCurrency } from './utils2.js';
|
|
3
|
-
import { W as radioListItem } from './parts.js';
|
|
4
|
-
import { s as state } from './checkout.store.js';
|
|
5
|
-
import { S as StyledHost } from './styled-host.js';
|
|
6
|
-
import './details.js';
|
|
7
|
-
import './event-types.js';
|
|
8
|
-
import { d as defineCustomElement$3 } from './form-control-help-text2.js';
|
|
9
|
-
import { d as defineCustomElement$2 } from './form-control-radio2.js';
|
|
10
|
-
|
|
11
|
-
const sezzleLogo = (h("img", { class: "sezzle-smart-button-logo-img", src: "https://media.sezzle.com/branding/2.0/Sezzle_Logo_FullColor.svg", alt: "Sezzle", style: {
|
|
12
|
-
display: 'inline',
|
|
13
|
-
width: '80px',
|
|
14
|
-
marginLeft: '5px',
|
|
15
|
-
marginTop: '-5px',
|
|
16
|
-
} }));
|
|
17
|
-
const SezzlePaymentMethod = /*@__PURE__*/ proxyCustomElement(class SezzlePaymentMethod extends HTMLElement {
|
|
18
|
-
constructor() {
|
|
19
|
-
super();
|
|
20
|
-
this.__registerHost();
|
|
21
|
-
this.__attachShadow();
|
|
22
|
-
this.paymentMethodOptionSelected = createEvent(this, "paymentMethodOptionSelected", 7);
|
|
23
|
-
this.paymentMethodOptionId = 'sezzle';
|
|
24
|
-
this.onPaymentMethodOptionClick = (e) => {
|
|
25
|
-
e.preventDefault();
|
|
26
|
-
state.selectedPaymentMethod = this.paymentMethodOptionId;
|
|
27
|
-
this.paymentMethodOptionSelected.emit(this.paymentMethodOptionId);
|
|
28
|
-
};
|
|
29
|
-
this.initializeSezzleCheckout = () => {
|
|
30
|
-
let resolveSezzlePromise;
|
|
31
|
-
this.sezzlePromise = new Promise((resolve) => { resolveSezzlePromise = resolve; });
|
|
32
|
-
const amount = Number(state.paymentAmount);
|
|
33
|
-
const Checkout = window.Checkout;
|
|
34
|
-
const checkout = new Checkout({
|
|
35
|
-
mode: 'popup',
|
|
36
|
-
publicKey: state.bnplProviderClientId,
|
|
37
|
-
apiMode: state.bnplProviderMode,
|
|
38
|
-
apiVersion: state.bnplProviderApiVersion,
|
|
39
|
-
});
|
|
40
|
-
checkout.sezzleButtonElement = this.sezzleButtonRef;
|
|
41
|
-
checkout.init({
|
|
42
|
-
onClick: function (event) {
|
|
43
|
-
event.preventDefault();
|
|
44
|
-
checkout.startCheckout({
|
|
45
|
-
checkout_url: state.bnplProviderCheckoutUrl,
|
|
46
|
-
});
|
|
47
|
-
},
|
|
48
|
-
onComplete: (event) => resolveSezzlePromise({ bnpl: event.data }),
|
|
49
|
-
onCancel: (event) => resolveSezzlePromise({ bnpl: event.data }),
|
|
50
|
-
onFailure: (event) => resolveSezzlePromise({ bnpl: event.data }),
|
|
51
|
-
});
|
|
52
|
-
this.sezzleCheckout = checkout;
|
|
53
|
-
this.installmentPlan = this.sezzleCheckout.getInstallmentPlan(amount);
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
componentDidRender() {
|
|
57
|
-
if (!this.scriptRef)
|
|
58
|
-
return;
|
|
59
|
-
this.scriptRef.onload = () => {
|
|
60
|
-
this.sezzleButtonRef = document.createElement('button');
|
|
61
|
-
this.initializeSezzleCheckout();
|
|
62
|
-
};
|
|
63
|
-
}
|
|
64
|
-
async resolvePaymentMethod(insuranceValidation) {
|
|
65
|
-
if (!insuranceValidation.isValid) {
|
|
66
|
-
return { validationError: true };
|
|
67
|
-
}
|
|
68
|
-
this.sezzleButtonRef.click();
|
|
69
|
-
return this.sezzlePromise;
|
|
70
|
-
}
|
|
71
|
-
render() {
|
|
72
|
-
var _a, _b;
|
|
73
|
-
if (!state.bnplEnabled) {
|
|
74
|
-
console.warn('justifi-sezzle-payment-method: BNPL is not enabled for this account.');
|
|
75
|
-
return null;
|
|
76
|
-
}
|
|
77
|
-
return (h(StyledHost, { class: "payment-method" }, h("script", { src: "https://checkout-sdk.sezzle.com/checkout.min.js", async: true, ref: (el) => (this.scriptRef = el) }), h("div", { class: "radio-list-item p-3", part: radioListItem, onClick: this.onPaymentMethodOptionClick }, h("form-control-radio", { name: "paymentMethodType", value: this.paymentMethodOptionId, checked: state.selectedPaymentMethod === this.paymentMethodOptionId, label: h("div", null, h("div", null, "Buy now, pay later with ", sezzleLogo), this.installmentPlan && (h("small", null, h("span", null, (_a = this.installmentPlan) === null || _a === void 0 ? void 0 : _a.installments.length), "\u00A0", h("span", null, this.installmentPlan.schedule, " payments of"), "\u00A0", h("span", { class: "fw-bold" }, formatCurrency((_b = this.installmentPlan) === null || _b === void 0 ? void 0 : _b.installments[0].amountInCents))))) }))));
|
|
78
|
-
}
|
|
79
|
-
}, [1, "justifi-sezzle-payment-method", {
|
|
80
|
-
"installmentPlan": [32],
|
|
81
|
-
"sezzleCheckout": [32],
|
|
82
|
-
"sezzlePromise": [32],
|
|
83
|
-
"resolvePaymentMethod": [64]
|
|
84
|
-
}]);
|
|
85
|
-
function defineCustomElement$1() {
|
|
86
|
-
if (typeof customElements === "undefined") {
|
|
87
|
-
return;
|
|
88
|
-
}
|
|
89
|
-
const components = ["justifi-sezzle-payment-method", "form-control-help-text", "form-control-radio"];
|
|
90
|
-
components.forEach(tagName => { switch (tagName) {
|
|
91
|
-
case "justifi-sezzle-payment-method":
|
|
92
|
-
if (!customElements.get(tagName)) {
|
|
93
|
-
customElements.define(tagName, SezzlePaymentMethod);
|
|
94
|
-
}
|
|
95
|
-
break;
|
|
96
|
-
case "form-control-help-text":
|
|
97
|
-
if (!customElements.get(tagName)) {
|
|
98
|
-
defineCustomElement$3();
|
|
99
|
-
}
|
|
100
|
-
break;
|
|
101
|
-
case "form-control-radio":
|
|
102
|
-
if (!customElements.get(tagName)) {
|
|
103
|
-
defineCustomElement$2();
|
|
104
|
-
}
|
|
105
|
-
break;
|
|
106
|
-
} });
|
|
107
|
-
}
|
|
108
|
-
defineCustomElement$1();
|
|
1
|
+
import { S as SezzlePaymentMethod, d as defineCustomElement$1 } from './sezzle-payment-method.js';
|
|
109
2
|
|
|
110
3
|
const JustifiSezzlePaymentMethod = SezzlePaymentMethod;
|
|
111
4
|
const defineCustomElement = defineCustomElement$1;
|