@justifi/webcomponents 6.0.0-rc.9 → 6.0.1-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Api-y2G49jOh.js → Api-CwTLkFY4.js} +2 -2
- package/dist/cjs/{Refund-BVZHsa6Z.js → Refund-BPSBtjQC.js} +3 -1
- package/dist/cjs/additional-questions-details_5.cjs.entry.js +3 -3
- package/dist/cjs/{badge-CcJ9H85-.js → badge-BmOSt4gS.js} +1 -1
- package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +11 -11
- package/dist/cjs/bank-account-form.cjs.entry.js +10 -15
- package/dist/cjs/business-details-core.cjs.entry.js +6 -21
- package/dist/cjs/{business.service-D5IhSyRJ.js → business.service-Dkhqyggm.js} +2 -2
- package/dist/cjs/{button-DsHDMHaa.js → button-7c2RN2yp.js} +2 -3
- package/dist/cjs/card-form.cjs.entry.js +10 -19
- package/dist/cjs/{check-pkg-version-VnhfIX0p.js → check-pkg-version-B48ZmuJS.js} +3 -3
- package/dist/cjs/{checkout.service-4aS641tN.js → checkout.service-LwZVVgP5.js} +2 -2
- package/dist/cjs/checkout.store-C3f3E24L.js +84 -0
- package/dist/cjs/checkouts-list-core.cjs.entry.js +11 -11
- package/dist/cjs/{checkouts-list-params-state-Cewmin_p.js → checkouts-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{checkouts-table-B_gpjGhs.js → checkouts-table-BQUhZZd_.js} +4 -6
- package/dist/cjs/{config-state-BBOZIS8x.js → config-state-B_gyIchD.js} +1 -1
- package/dist/cjs/custom-popper_2.cjs.entry.js +3 -3
- package/dist/cjs/{dispute.service-64ciJH0r.js → dispute.service-927Gzb0N.js} +2 -2
- package/dist/cjs/form-alert_5.cjs.entry.js +5 -5
- package/dist/cjs/form-control-checkbox.cjs.entry.js +5 -5
- package/dist/cjs/form-control-date.cjs.entry.js +4 -4
- package/dist/cjs/{form-control-error-text-B-P5UDhm.js → form-control-error-text-DD0dHGu8.js} +1 -1
- package/dist/cjs/form-control-file-v2_2.cjs.entry.js +5 -5
- package/dist/cjs/{form-control-help-text-JoZjhb9m.js → form-control-help-text-2QwKi78M.js} +1 -1
- package/dist/cjs/form-control-help-text.cjs.entry.js +1 -1
- package/dist/cjs/form-control-monetary-provisioning.cjs.entry.js +5 -5
- package/dist/cjs/form-control-monetary.cjs.entry.js +6 -6
- package/dist/cjs/form-control-number-masked_2.cjs.entry.js +5 -5
- package/dist/cjs/form-control-number.cjs.entry.js +5 -5
- package/dist/cjs/form-control-radio.cjs.entry.js +3 -3
- package/dist/cjs/form-control-select_2.cjs.entry.js +6 -6
- package/dist/cjs/{get-payment-details-DE5xUUpt.js → get-payment-details-BSxp1HX0.js} +2 -2
- package/dist/cjs/{get-subaccounts-CH477rHs.js → get-subaccounts-B31f95PR.js} +3 -3
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +5 -5
- package/dist/cjs/{header-1-DRA3f4Jh.js → header-1-DMsp0XM7.js} +1 -1
- package/dist/cjs/{header-3-sOdOpfx3.js → header-3-BSvFq_IF.js} +1 -1
- package/dist/cjs/hidden-input_2.cjs.entry.js +8 -8
- package/dist/cjs/{checkout.store-MSwLBCby.js → index-C2ITzalN.js} +29 -41
- package/dist/cjs/{index-B32W0A3m.js → index-D1Ba20gi.js} +1 -1
- package/dist/cjs/{index-C9hBD-32.js → index-Dyzl8Hn6.js} +8 -2
- package/dist/cjs/index.cjs.js +8 -0
- package/dist/cjs/{insurance-state-d2thhXUX.js → insurance-state-uWOl6jJN.js} +2 -2
- package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +9 -24
- package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +17 -17
- package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +9 -9
- package/dist/cjs/justifi-apple-pay.cjs.entry.js +177 -86
- package/dist/cjs/justifi-bank-account-billing-form-simple_9.cjs.entry.js +26 -44
- package/dist/cjs/justifi-business-details.cjs.entry.js +10 -10
- package/dist/cjs/justifi-business-form.cjs.entry.js +15 -30
- package/dist/cjs/justifi-business-representative-form-inputs.cjs.entry.js +2 -2
- package/dist/cjs/justifi-checkout-summary_7.cjs.entry.js +200 -164
- package/dist/cjs/justifi-checkout.cjs.entry.js +19 -11
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +8 -8
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +14 -14
- package/dist/cjs/justifi-config-provider.cjs.entry.js +3 -3
- package/dist/cjs/justifi-details.cjs.entry.js +3 -3
- package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +2 -2
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +10 -10
- package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +15 -15
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +9 -9
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +16 -44
- package/dist/cjs/justifi-owner-form_3.cjs.entry.js +11 -11
- package/dist/cjs/justifi-payment-details.cjs.entry.js +11 -11
- package/dist/cjs/justifi-payment-provisioning-core.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +14 -16
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +7 -7
- package/dist/cjs/justifi-payments-list.cjs.entry.js +14 -14
- package/dist/cjs/justifi-payout-details.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +16 -22
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +7 -7
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +15 -15
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +15 -21
- package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +2 -2
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +14 -25
- package/dist/cjs/justifi-skeleton.cjs.entry.js +4 -4
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +9 -9
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +12 -12
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +8 -8
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +14 -14
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{package-BS0_inF6.js → package-C3FMDKcV.js} +1 -1
- package/dist/cjs/pagination-menu.cjs.entry.js +4 -4
- package/dist/cjs/payment-details-core.cjs.entry.js +16 -28
- package/dist/cjs/payment-method-option.cjs.entry.js +3 -3
- package/dist/cjs/{payment.service--kzMop3L.js → payment.service-DUq-W7tS.js} +2 -2
- package/dist/cjs/payments-list-core.cjs.entry.js +12 -12
- package/dist/cjs/{payments-list-params-state-Cewmin_p.js → payments-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{payments-status-DXRh_ekP.js → payments-status-3iIQkoov.js} +2 -2
- package/dist/cjs/{payments-table-DFRtk-T9.js → payments-table-BSHUQhM-.js} +4 -6
- package/dist/cjs/payout-details-core.cjs.entry.js +12 -24
- package/dist/cjs/{payout.service-D3omzNG_.js → payout.service-DoKMr8Xw.js} +2 -2
- package/dist/cjs/payouts-list-core.cjs.entry.js +12 -12
- package/dist/cjs/{payouts-list-params-state-Cewmin_p.js → payouts-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{payouts-status-DxTQZv3i.js → payouts-status-DoQbxIms.js} +2 -2
- package/dist/cjs/{payouts-table-DE3t0x93.js → payouts-table-BD_Fhz_j.js} +5 -7
- package/dist/cjs/{skeleton-C7DQRD6r.js → skeleton-CuIMC98G.js} +1 -1
- package/dist/cjs/spinner-CMZXdrPe.js +10 -0
- package/dist/cjs/{styled-host-BfVJlAsJ.js → styled-host-2KXbjOFw.js} +2 -4
- package/dist/cjs/{table-Ccdrt0v_.js → table-DlQCUVag.js} +5 -11
- package/dist/cjs/table-filters-menu.cjs.entry.js +3 -3
- package/dist/cjs/terminal-orders-list-core.cjs.entry.js +11 -11
- package/dist/cjs/{terminal-orders-list-params-state-Cewmin_p.js → terminal-orders-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{terminal-orders-table-B1LJitwE.js → terminal-orders-table-t6XxNy_K.js} +7 -11
- package/dist/cjs/terminal-quantity-selector.cjs.entry.js +2 -2
- package/dist/cjs/{terminal.service-BOvYfpQW.js → terminal.service-Iyje71vN.js} +2 -2
- package/dist/cjs/terminals-list-core.cjs.entry.js +11 -11
- package/dist/cjs/terminals-list-params-state-C4c8UZtP.js +22 -0
- package/dist/cjs/{terminals-table-DYt7exFQ.js → terminals-table-BTdKRiBN.js} +3 -3
- package/dist/cjs/{utils-BaGF9XIe.js → utils-ChCUZgUy.js} +6 -0
- package/dist/cjs/utils-FFP5ZHyE.js +18 -0
- package/dist/cjs/webcomponents.cjs.js +3 -3
- package/dist/collection/api/Payment.js +2 -0
- package/dist/collection/api/index.js +1 -2
- package/dist/collection/api/services/apple-pay.service.js +95 -8
- package/dist/collection/collection-manifest.json +3 -3
- package/dist/collection/components/business-forms/business-form/additional-questions/additional-questions.js +6 -6
- package/dist/collection/components/business-forms/business-form/business-core-info/business-core-info.js +1 -1
- package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +6 -6
- package/dist/collection/components/business-forms/business-form/legal-address-form/legal-address-form.js +6 -6
- package/dist/collection/components/business-forms/owner-form/identity-address/identity-address-form.js +1 -1
- package/dist/collection/components/business-forms/owner-form/owner-form-core.js +1 -1
- package/dist/collection/components/business-forms/owner-form/owner-form-inputs.js +6 -6
- package/dist/collection/components/business-forms/owner-form/owner-form.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/additional-questions/business-additional-questions-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-document-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/form-control-monetary-provisioning.js +2 -2
- package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-core.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-buttons.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-steps.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/terms-and-conditions/business-terms-conditions-form-step.js +1 -1
- package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +6 -3
- package/dist/collection/components/checkout/card-form/card-form.js +6 -3
- package/dist/collection/components/checkout/checkout.js +16 -1
- package/dist/collection/components/checkout/save-new-payment-method.js +26 -1
- package/dist/collection/components/checkout/saved-payment-method.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list-core.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list-filters.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list.js +1 -1
- package/dist/collection/components/dispute-management/dispute-management-core.js +1 -1
- package/dist/collection/components/dispute-management/dispute-management.js +1 -1
- package/dist/collection/components/dispute-management/dispute-notification.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/additional-statement.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/cancellation-policy.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/customer-details.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/dispute-response-core.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/dispute-response.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/duplicate-charge.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/electronic-evidence.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/product-or-service.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/refund-policy.js +1 -1
- package/dist/collection/components/dispute-management/dispute-response/shipping-details.js +1 -1
- package/dist/collection/components/filters/table-filters-menu.js +1 -1
- package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +1 -1
- package/dist/collection/components/modular-checkout/ModularCheckout.js +27 -0
- package/dist/collection/components/modular-checkout/modular-checkout.js +113 -72
- package/dist/collection/components/modular-checkout/sub-components/apple-pay-skeleton.js +2 -2
- package/dist/collection/components/modular-checkout/sub-components/apple-pay.js +72 -70
- package/dist/collection/components/modular-checkout/sub-components/bank-account-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/bank-account.js +2 -2
- package/dist/collection/components/modular-checkout/sub-components/card-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/card-form.js +2 -2
- package/dist/collection/components/modular-checkout/sub-components/payment-method-option.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/plaid-payment-method.js +57 -65
- package/dist/collection/components/modular-checkout/sub-components/plaid-payment-method.test.js +8 -6
- package/dist/collection/components/modular-checkout/sub-components/saved-payment-methods.js +8 -10
- package/dist/collection/components/modular-checkout/sub-components/sezzle-payment-method.js +22 -7
- package/dist/collection/components/modular-checkout/sub-components/summary.js +1 -1
- package/dist/collection/components/order-terminals/order-terminals.js +1 -1
- package/dist/collection/components/order-terminals/terminal-quantity-selector/terminal-quantity-selector.js +1 -1
- package/dist/collection/components/payment-details/payment-details-core.js +8 -8
- package/dist/collection/components/payment-transactions-list/payment-transactions-list.js +1 -1
- package/dist/collection/components/payments-list/payments-list-core.js +1 -1
- package/dist/collection/components/payments-list/payments-list-filters.js +2 -2
- package/dist/collection/components/payments-list/payments-list.js +1 -1
- package/dist/collection/components/payout-details/payout-details-core.js +3 -3
- package/dist/collection/components/payout-transactions-list/payout-transactions-list.js +1 -1
- package/dist/collection/components/payouts-list/payouts-list-core.js +1 -1
- package/dist/collection/components/payouts-list/payouts-list-filters.js +2 -2
- package/dist/collection/components/payouts-list/payouts-list.js +1 -1
- package/dist/collection/components/terminal-orders-list/terminal-orders-list-core.js +1 -1
- package/dist/collection/components/terminal-orders-list/terminal-orders-list-filters.js +2 -2
- package/dist/collection/components/terminal-orders-list/terminal-orders-list.js +1 -1
- package/dist/collection/components/terminals-list/terminals-list-core.js +1 -1
- package/dist/collection/components/terminals-list/terminals-list-filters.js +1 -1
- package/dist/collection/components/terminals-list/terminals-list.js +1 -1
- package/dist/collection/components/tokenize-payment-method/tokenize-payment-method.js +31 -13
- package/dist/collection/index.js +1 -0
- package/dist/collection/store/checkout.store.js +46 -3
- package/dist/collection/ui-components/custom-popper/custom-popper.js +2 -2
- package/dist/collection/ui-components/details/details.js +1 -1
- package/dist/collection/ui-components/form/form-control-checkbox.js +2 -2
- package/dist/collection/ui-components/form/form-control-date.js +2 -2
- package/dist/collection/ui-components/form/form-control-file-v2.js +1 -1
- package/dist/collection/ui-components/form/form-control-file.js +2 -2
- package/dist/collection/ui-components/form/form-control-monetary.js +2 -2
- package/dist/collection/ui-components/form/form-control-number-masked.js +2 -2
- package/dist/collection/ui-components/form/form-control-number.js +2 -2
- package/dist/collection/ui-components/form/form-control-radio.js +5 -5
- package/dist/collection/ui-components/form/form-control-select.js +2 -2
- package/dist/collection/ui-components/form/form-control-text.js +2 -2
- package/dist/collection/ui-components/form/form-control-textarea.js +2 -2
- package/dist/collection/ui-components/form/hidden-input.js +1 -1
- package/dist/collection/ui-components/form/iframe-input.js +3 -3
- package/dist/collection/ui-components/pagination-menu/pagination-menu.js +3 -3
- package/dist/collection/ui-components/shadow-dom-components/justifi-button.js +1 -1
- package/dist/collection/ui-components/shadow-dom-components/justifi-header.js +1 -1
- package/dist/collection/ui-components/shadow-dom-components/justifi-radio-list-item.js +4 -4
- package/dist/collection/ui-components/shadow-dom-components/justifi-skeleton.js +1 -1
- package/dist/collection/utils/utils.js +5 -0
- package/dist/docs.json +167 -190
- package/dist/esm/{Api-C1I68Tfr.js → Api-D4tj-h4P.js} +2 -2
- package/dist/esm/{Refund-kKW8S1h6.js → Refund-Bc5By0lb.js} +3 -1
- package/dist/esm/additional-questions-details_5.entry.js +3 -3
- package/dist/esm/{badge-DSYSJcRy.js → badge-ChwzCNAF.js} +1 -1
- package/dist/esm/bank-account-document-form-inputs_4.entry.js +11 -11
- package/dist/esm/bank-account-form.entry.js +10 -15
- package/dist/esm/business-details-core.entry.js +6 -21
- package/dist/esm/{business.service-B3wlBl1x.js → business.service-CsbtEDNi.js} +2 -2
- package/dist/esm/{button-CpllL0At.js → button-SAIS_5os.js} +2 -3
- package/dist/esm/card-form.entry.js +10 -19
- package/dist/esm/{check-pkg-version-CGQdCjwh.js → check-pkg-version-DSO4z-Vx.js} +3 -3
- package/dist/esm/{checkout.service-KDp7tISm.js → checkout.service-BCkQ9pOA.js} +2 -2
- package/dist/esm/checkout.store-DBvS7cVB.js +79 -0
- package/dist/esm/checkouts-list-core.entry.js +11 -11
- package/dist/esm/{checkouts-list-params-state-D8tzsGR_.js → checkouts-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{checkouts-table-QOdiLpak.js → checkouts-table-CItEo0DU.js} +4 -6
- package/dist/esm/{config-state-DZeVYerv.js → config-state-Blo0ywwc.js} +1 -1
- package/dist/esm/custom-popper_2.entry.js +3 -3
- package/dist/esm/{dispute.service-DEZEPwn-.js → dispute.service-CyLtJREK.js} +2 -2
- package/dist/esm/form-alert_5.entry.js +5 -5
- package/dist/esm/form-control-checkbox.entry.js +5 -5
- package/dist/esm/form-control-date.entry.js +4 -4
- package/dist/esm/{form-control-error-text-R7U07nTg.js → form-control-error-text-IXJJ4JpV.js} +1 -1
- package/dist/esm/form-control-file-v2_2.entry.js +5 -5
- package/dist/esm/{form-control-help-text-CRLH-2f7.js → form-control-help-text-CuhIsM3v.js} +1 -1
- package/dist/esm/form-control-help-text.entry.js +1 -1
- package/dist/esm/form-control-monetary-provisioning.entry.js +5 -5
- package/dist/esm/form-control-monetary.entry.js +6 -6
- package/dist/esm/form-control-number-masked_2.entry.js +5 -5
- package/dist/esm/form-control-number.entry.js +5 -5
- package/dist/esm/form-control-radio.entry.js +3 -3
- package/dist/esm/form-control-select_2.entry.js +6 -6
- package/dist/esm/{get-payment-details-CYASKLT7.js → get-payment-details-BuT0QNOo.js} +2 -2
- package/dist/esm/{get-subaccounts-E0PYy_pc.js → get-subaccounts-VjY6-x_9.js} +3 -3
- package/dist/esm/gross-payment-chart-core.entry.js +5 -5
- package/dist/esm/{header-1-3M9If0gM.js → header-1-zXsamUS3.js} +1 -1
- package/dist/esm/{header-3-CWa41YWq.js → header-3-DVtaUAlf.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +8 -8
- package/dist/esm/{checkout.store-UMe84fjY.js → index-DCIW8z1f.js} +27 -38
- package/dist/esm/{index-B_KxSZIF.js → index-ZfXl6Xrm.js} +1 -1
- package/dist/esm/{index-Bn7inNWG.js → index-qipqIMyC.js} +8 -2
- package/dist/esm/index.js +1 -1
- package/dist/esm/{insurance-state-CTalqbNa.js → insurance-state-Dh9f36Qh.js} +2 -2
- package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +9 -24
- package/dist/esm/justifi-additional-questions-form-step_9.entry.js +17 -17
- package/dist/esm/justifi-additional-statement_8.entry.js +9 -9
- package/dist/esm/justifi-apple-pay.entry.js +177 -86
- package/dist/esm/justifi-bank-account-billing-form-simple_9.entry.js +26 -44
- package/dist/esm/justifi-business-details.entry.js +10 -10
- package/dist/esm/justifi-business-form.entry.js +15 -30
- package/dist/esm/justifi-business-representative-form-inputs.entry.js +2 -2
- package/dist/esm/justifi-checkout-summary_7.entry.js +193 -157
- package/dist/esm/justifi-checkout.entry.js +19 -11
- package/dist/esm/justifi-checkouts-list-filters.entry.js +8 -8
- package/dist/esm/justifi-checkouts-list.entry.js +14 -14
- package/dist/esm/justifi-config-provider.entry.js +3 -3
- package/dist/esm/justifi-details.entry.js +3 -3
- package/dist/esm/justifi-dispute-management-core.entry.js +2 -2
- package/dist/esm/justifi-dispute-management.entry.js +10 -10
- package/dist/esm/justifi-dispute-notification_3.entry.js +15 -15
- package/dist/esm/justifi-gross-payment-chart.entry.js +9 -9
- package/dist/esm/justifi-order-terminals.entry.js +16 -44
- package/dist/esm/justifi-owner-form_3.entry.js +11 -11
- package/dist/esm/justifi-payment-details.entry.js +11 -11
- package/dist/esm/justifi-payment-provisioning-core.entry.js +4 -4
- package/dist/esm/justifi-payment-provisioning.entry.js +10 -10
- package/dist/esm/justifi-payment-transactions-list.entry.js +14 -16
- package/dist/esm/justifi-payments-list-filters.entry.js +7 -7
- package/dist/esm/justifi-payments-list.entry.js +14 -14
- package/dist/esm/justifi-payout-details.entry.js +10 -10
- package/dist/esm/justifi-payout-transactions-list.entry.js +16 -22
- package/dist/esm/justifi-payouts-list-filters.entry.js +7 -7
- package/dist/esm/justifi-payouts-list.entry.js +15 -15
- package/dist/esm/justifi-refund-payment.entry.js +15 -21
- package/dist/esm/justifi-saved-payment-method.entry.js +2 -2
- package/dist/esm/justifi-season-interruption-insurance.entry.js +14 -25
- package/dist/esm/justifi-skeleton.entry.js +4 -4
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +9 -9
- package/dist/esm/justifi-terminal-orders-list.entry.js +12 -12
- package/dist/esm/justifi-terminals-list-filters.entry.js +8 -8
- package/dist/esm/justifi-terminals-list.entry.js +14 -14
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{package-BiWRKUx3.js → package-tyhA5jkt.js} +1 -1
- package/dist/esm/pagination-menu.entry.js +4 -4
- package/dist/esm/payment-details-core.entry.js +16 -28
- package/dist/esm/payment-method-option.entry.js +3 -3
- package/dist/esm/{payment.service-uJpJaX2Z.js → payment.service-QJEmd6Nl.js} +2 -2
- package/dist/esm/payments-list-core.entry.js +12 -12
- package/dist/esm/{payments-list-params-state-D8tzsGR_.js → payments-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{payments-status-5orNU2Rd.js → payments-status-DDafc8Yr.js} +2 -2
- package/dist/esm/{payments-table-B0uyodyJ.js → payments-table-De3Jb6rY.js} +4 -6
- package/dist/esm/payout-details-core.entry.js +12 -24
- package/dist/esm/{payout.service-ClUgtbbb.js → payout.service-XxyEr0rj.js} +2 -2
- package/dist/esm/payouts-list-core.entry.js +12 -12
- package/dist/esm/{payouts-list-params-state-D8tzsGR_.js → payouts-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{payouts-status-CZPwa2AE.js → payouts-status-u1eSRz3Q.js} +2 -2
- package/dist/esm/{payouts-table-CaCSX_0q.js → payouts-table-BO-MCzXj.js} +5 -7
- package/dist/esm/{skeleton-qMb0_Cjy.js → skeleton-DtpkgjZ6.js} +1 -1
- package/dist/esm/spinner-CIXUVK4F.js +8 -0
- package/dist/esm/{styled-host-CTAGIN84.js → styled-host-CbizlfAU.js} +2 -4
- package/dist/esm/{table-Br3n9Xu-.js → table-DcRHK_sm.js} +5 -11
- package/dist/esm/table-filters-menu.entry.js +3 -3
- package/dist/esm/terminal-orders-list-core.entry.js +11 -11
- package/dist/esm/{terminal-orders-list-params-state-D8tzsGR_.js → terminal-orders-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{terminal-orders-table-DPtof5Zb.js → terminal-orders-table-9nsnrAq8.js} +7 -11
- package/dist/esm/terminal-quantity-selector.entry.js +2 -2
- package/dist/esm/{terminal.service-ClNtE3e-.js → terminal.service-D2oETGnk.js} +2 -2
- package/dist/esm/terminals-list-core.entry.js +11 -11
- package/dist/esm/terminals-list-params-state-C2_GlMKR.js +16 -0
- package/dist/esm/{terminals-table-ClkR_jrC.js → terminals-table-C6NO2m-t.js} +3 -3
- package/dist/esm/{utils-lb8p1Exq.js → utils-BscIVFn8.js} +6 -1
- package/dist/esm/utils-_ckvHjSW.js +11 -0
- package/dist/esm/webcomponents.js +4 -4
- package/dist/module/ModularCheckout.js +57 -0
- package/dist/module/Refund.js +2 -0
- package/dist/module/additional-questions-details2.js +4 -2
- package/dist/module/additional-questions.js +6 -4
- package/dist/module/additional-statement.js +5 -3
- package/dist/module/bank-account-billing-form-simple.js +5 -3
- package/dist/module/bank-account-document-inputs.js +5 -3
- package/dist/module/bank-account-form-inputs2.js +5 -3
- package/dist/module/bank-account-form.js +10 -13
- package/dist/module/bank-account.js +7 -13
- package/dist/module/billing-form-full.js +4 -2
- package/dist/module/billing-form.js +4 -2
- package/dist/module/business-additional-questions-form-step-core.js +4 -2
- package/dist/module/business-additional-questions-form-step.js +5 -3
- package/dist/module/business-bank-account-form-step-core.js +4 -2
- package/dist/module/business-bank-account-form-step.js +5 -3
- package/dist/module/business-core-info-form-step-core.js +4 -2
- package/dist/module/business-core-info-form-step.js +5 -3
- package/dist/module/business-core-info.js +5 -3
- package/dist/module/business-details-core2.js +6 -19
- package/dist/module/business-documents-on-file2.js +4 -2
- package/dist/module/business-owners-form-step-core.js +4 -2
- package/dist/module/business-owners-form-step.js +5 -3
- package/dist/module/business-representative-form-inputs.js +5 -3
- package/dist/module/business-representative-form-step-core.js +4 -2
- package/dist/module/business-representative-form-step.js +5 -3
- package/dist/module/business-representative.js +6 -4
- package/dist/module/business-terms-conditions-form-step.js +5 -3
- package/dist/module/button.js +1 -2
- package/dist/module/cancellation-policy.js +5 -3
- package/dist/module/card-billing-form-simple.js +5 -3
- package/dist/module/card-form.js +10 -17
- package/dist/module/card-form2.js +7 -17
- package/dist/module/checkout.store.js +42 -31
- package/dist/module/checkouts-list-core2.js +6 -6
- package/dist/module/core-info-details2.js +4 -2
- package/dist/module/custom-popper2.js +6 -4
- package/dist/module/customer-details.js +5 -3
- package/dist/module/details.js +5 -3
- package/dist/module/dispute-management-core.js +5 -3
- package/dist/module/dispute-notification.js +5 -3
- package/dist/module/dispute-response-core.js +5 -3
- package/dist/module/dispute-response.js +5 -3
- package/dist/module/duplicate-charge.js +5 -3
- package/dist/module/electronic-evidence.js +5 -3
- package/dist/module/form-alert2.js +4 -2
- package/dist/module/form-control-checkbox2.js +6 -4
- package/dist/module/form-control-date2.js +6 -4
- package/dist/module/form-control-file-v22.js +5 -3
- package/dist/module/form-control-file2.js +6 -4
- package/dist/module/form-control-help-text2.js +4 -2
- package/dist/module/form-control-monetary-provisioning2.js +6 -4
- package/dist/module/form-control-monetary2.js +6 -4
- package/dist/module/form-control-number-masked2.js +6 -4
- package/dist/module/form-control-number.js +6 -4
- package/dist/module/form-control-radio2.js +7 -5
- package/dist/module/form-control-select2.js +6 -4
- package/dist/module/form-control-text2.js +6 -4
- package/dist/module/form-control-textarea2.js +6 -4
- package/dist/module/form-control-tooltip2.js +4 -2
- package/dist/module/gross-payment-chart-core2.js +6 -4
- package/dist/module/hidden-input2.js +5 -3
- package/dist/module/identity-address-form.js +5 -3
- package/dist/module/iframe-input2.js +7 -5
- package/dist/module/index.js +1 -0
- package/dist/module/justifi-apple-pay.js +174 -86
- package/dist/module/justifi-business-details.js +4 -2
- package/dist/module/justifi-business-form.js +6 -19
- package/dist/module/justifi-button2.js +5 -3
- package/dist/module/justifi-checkout.js +15 -4
- package/dist/module/justifi-checkouts-list-filters.js +5 -3
- package/dist/module/justifi-checkouts-list.js +5 -3
- package/dist/module/justifi-config-provider.js +4 -2
- package/dist/module/justifi-dispute-management.js +5 -3
- package/dist/module/justifi-gross-payment-chart.js +4 -2
- package/dist/module/justifi-header2.js +5 -3
- package/dist/module/justifi-order-terminals.js +9 -35
- package/dist/module/justifi-payment-details.js +4 -2
- package/dist/module/justifi-payment-provisioning.js +5 -3
- package/dist/module/justifi-payment-transactions-list.js +6 -6
- package/dist/module/justifi-payments-list-filters.js +6 -4
- package/dist/module/justifi-payments-list.js +5 -3
- package/dist/module/justifi-payout-details.js +4 -2
- package/dist/module/justifi-payout-transactions-list.js +8 -12
- package/dist/module/justifi-payouts-list-filters.js +6 -4
- package/dist/module/justifi-payouts-list.js +5 -3
- package/dist/module/justifi-radio-list-item2.js +6 -4
- package/dist/module/justifi-refund-payment.js +6 -10
- package/dist/module/justifi-saved-payment-method.js +5 -3
- package/dist/module/justifi-season-interruption-insurance.js +6 -16
- package/dist/module/justifi-skeleton.js +5 -3
- package/dist/module/justifi-terminal-orders-list-filters.js +6 -4
- package/dist/module/justifi-terminal-orders-list.js +5 -3
- package/dist/module/justifi-terminals-list-filters.js +5 -3
- package/dist/module/justifi-terminals-list.js +5 -3
- package/dist/module/legal-address-details2.js +4 -2
- package/dist/module/legal-address-form-step-core.js +4 -2
- package/dist/module/legal-address-form-step.js +5 -3
- package/dist/module/legal-address-form.js +6 -4
- package/dist/module/modular-checkout.js +102 -39
- package/dist/module/owner-details2.js +4 -2
- package/dist/module/owner-form-core2.js +5 -3
- package/dist/module/owner-form-inputs2.js +6 -4
- package/dist/module/owner-form.js +5 -3
- package/dist/module/package.js +1 -1
- package/dist/module/pagination-menu2.js +7 -5
- package/dist/module/payment-details-core2.js +13 -23
- package/dist/module/payment-method-option.js +5 -3
- package/dist/module/payment-provisioning-core.js +5 -3
- package/dist/module/payment-provisioning-form-buttons.js +5 -3
- package/dist/module/payment-provisioning-form-steps.js +5 -3
- package/dist/module/payment-provisioning-loading.js +2 -17
- package/dist/module/payments-list-core2.js +6 -6
- package/dist/module/payout-details-core2.js +8 -18
- package/dist/module/payouts-list-core2.js +7 -7
- package/dist/module/plaid-payment-method.js +49 -104
- package/dist/module/plaid.service.js +26 -0
- package/dist/module/product-or-service.js +5 -3
- package/dist/module/refund-policy.js +5 -3
- package/dist/module/representative-details2.js +4 -2
- package/dist/module/save-new-payment-method.js +7 -3
- package/dist/module/saved-payment-methods.js +13 -12
- package/dist/module/sezzle-payment-method.js +14 -24
- package/dist/module/shipping-details.js +5 -3
- package/dist/module/spinner.js +1 -3
- package/dist/module/styled-host.js +1 -3
- package/dist/module/summary.js +5 -3
- package/dist/module/table-filters-menu2.js +5 -3
- package/dist/module/table.js +3 -9
- package/dist/module/terminal-orders-list-core2.js +7 -9
- package/dist/module/terminal-quantity-selector2.js +5 -3
- package/dist/module/terminals-list-core2.js +6 -4
- package/dist/module/tokenize-payment-method.js +16 -12
- package/dist/module/utils.js +5 -16
- package/dist/module/utils2.js +6 -1
- package/dist/types/api/Checkout.d.ts +7 -15
- package/dist/types/api/Payment.d.ts +3 -1
- package/dist/types/api/index.d.ts +2 -2
- package/dist/types/api/services/apple-pay.service.d.ts +7 -0
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +1 -1
- package/dist/types/components/checkout/bank-account-form/bank-account-form.d.ts +1 -0
- package/dist/types/components/checkout/card-form/card-form.d.ts +1 -0
- package/dist/types/components/checkout/checkout.d.ts +5 -0
- package/dist/types/components/checkout/save-new-payment-method.d.ts +1 -0
- package/dist/types/components/modular-checkout/ModularCheckout.d.ts +41 -0
- package/dist/types/components/modular-checkout/modular-checkout.d.ts +5 -5
- package/dist/types/components/modular-checkout/sub-components/apple-pay-skeleton.d.ts +1 -1
- package/dist/types/components/modular-checkout/sub-components/apple-pay.d.ts +9 -3
- package/dist/types/components/modular-checkout/sub-components/plaid-payment-method.d.ts +1 -2
- package/dist/types/components/modular-checkout/sub-components/saved-payment-methods.d.ts +3 -3
- package/dist/types/components/modular-checkout/sub-components/sezzle-payment-method.d.ts +1 -1
- package/dist/types/components/tokenize-payment-method/tokenize-payment-method.d.ts +2 -1
- package/dist/types/components.d.ts +31 -29
- package/dist/types/index.d.ts +4 -0
- package/dist/types/stencil-public-runtime.d.ts +21 -0
- package/dist/types/store/checkout.store.d.ts +12 -5
- package/dist/types/ui-components/form/form-control-radio.d.ts +1 -1
- package/dist/types/ui-components/shadow-dom-components/justifi-radio-list-item.d.ts +1 -1
- package/dist/types/utils/utils.d.ts +1 -0
- package/dist/webcomponents/index.esm.js +1 -0
- package/dist/webcomponents/{p-497632ad.entry.js → p-037d7061.entry.js} +1 -1
- package/dist/webcomponents/{p-4e3bf98f.entry.js → p-070c29ce.entry.js} +1 -1
- package/dist/webcomponents/{p-54ca3070.entry.js → p-0801324e.entry.js} +1 -1
- package/dist/webcomponents/{p-6255c685.entry.js → p-10278c48.entry.js} +1 -1
- package/dist/webcomponents/p-19ccbeee.entry.js +1 -0
- package/dist/webcomponents/{p-15705e8a.entry.js → p-1b3b6956.entry.js} +1 -1
- package/dist/webcomponents/{p-9846b23d.entry.js → p-1b7926f6.entry.js} +1 -1
- package/dist/webcomponents/p-1c433962.entry.js +1 -0
- package/dist/webcomponents/{p-2f01dfd2.entry.js → p-1d7139d3.entry.js} +1 -1
- package/dist/webcomponents/p-214fa6e0.entry.js +1 -0
- package/dist/webcomponents/{p-f13ae573.entry.js → p-2246aa69.entry.js} +1 -1
- package/dist/webcomponents/p-246ef4ff.entry.js +1 -0
- package/dist/webcomponents/{p-4213d10e.entry.js → p-27fc3ef0.entry.js} +3 -3
- package/dist/webcomponents/p-2d818d44.entry.js +1 -0
- package/dist/webcomponents/p-30147031.entry.js +1 -0
- package/dist/webcomponents/p-3546a5aa.entry.js +1 -0
- package/dist/webcomponents/p-3621a429.entry.js +1 -0
- package/dist/webcomponents/{p-f1cba43c.entry.js → p-3d37045d.entry.js} +1 -1
- package/dist/webcomponents/p-406ba650.entry.js +1 -0
- package/dist/webcomponents/{p-36a71a36.entry.js → p-4215ea76.entry.js} +1 -1
- package/dist/webcomponents/p-44d1341c.entry.js +1 -0
- package/dist/webcomponents/{p-36d9d95a.entry.js → p-4b1abc3b.entry.js} +1 -1
- package/dist/webcomponents/p-4d5c71c4.entry.js +1 -0
- package/dist/webcomponents/p-4ea83bfd.entry.js +1 -0
- package/dist/webcomponents/p-558f7967.entry.js +1 -0
- package/dist/webcomponents/p-5c477f08.entry.js +1 -0
- package/dist/webcomponents/p-62a16ef9.entry.js +1 -0
- package/dist/webcomponents/p-65286b2b.entry.js +1 -0
- package/dist/webcomponents/p-68329f16.entry.js +1 -0
- package/dist/webcomponents/p-6af851c5.entry.js +1 -0
- package/dist/webcomponents/{p-aeeb0f68.entry.js → p-6d4ae6c7.entry.js} +1 -1
- package/dist/webcomponents/p-6fe79f16.entry.js +1 -0
- package/dist/webcomponents/p-7494c1b6.entry.js +1 -0
- package/dist/webcomponents/p-7aeb20d2.entry.js +1 -0
- package/dist/webcomponents/{p-28618e6f.entry.js → p-7c5cd118.entry.js} +1 -1
- package/dist/webcomponents/p-8018523d.entry.js +1 -0
- package/dist/webcomponents/{p-4178bdbe.entry.js → p-83fa6da1.entry.js} +1 -1
- package/dist/webcomponents/p-84043580.entry.js +1 -0
- package/dist/webcomponents/{p-48e87a26.entry.js → p-84ccc7bb.entry.js} +1 -1
- package/dist/webcomponents/p-8975bf93.entry.js +1 -0
- package/dist/webcomponents/{p-bc2da364.entry.js → p-9046afd6.entry.js} +1 -1
- package/dist/webcomponents/p-906fdf0c.entry.js +1 -0
- package/dist/webcomponents/{p-9a2c044f.entry.js → p-90e43440.entry.js} +1 -1
- package/dist/webcomponents/{p-70f51444.entry.js → p-914e168d.entry.js} +1 -1
- package/dist/webcomponents/p-91c1e2ac.entry.js +1 -0
- package/dist/webcomponents/p-95348ff6.entry.js +1 -0
- package/dist/webcomponents/p-9f04cac4.entry.js +1 -0
- package/dist/webcomponents/{p-0mMX1Zv4.js → p-B4idKqyn.js} +1 -1
- package/dist/webcomponents/{p-zdIeCUeh.js → p-BHf9IqGw.js} +1 -1
- package/dist/webcomponents/{p-DNo0OPOP.js → p-BIPdn2VU.js} +1 -1
- package/dist/webcomponents/{p-BPtcGAzB.js → p-BUa0YOaw.js} +1 -1
- package/dist/webcomponents/{p-B8iBcmNu.js → p-BY2p6Sxk.js} +1 -1
- package/dist/webcomponents/{p-CB0mCq1M.js → p-BZ7C9duj.js} +1 -1
- package/dist/webcomponents/{p-DGmp4ErD.js → p-BdLLGV9t.js} +1 -1
- package/dist/webcomponents/p-BguBT6Hn.js +1 -0
- package/dist/webcomponents/{p-DhGNCW2f.js → p-Bp_QFeog.js} +1 -1
- package/dist/webcomponents/{p-B71k50jz.js → p-Bvp7uul3.js} +1 -1
- package/dist/webcomponents/{p-CvG-itHC.js → p-C1xGBPma.js} +1 -1
- package/dist/webcomponents/p-C3n7-tlg.js +1 -0
- package/dist/webcomponents/{p-DxqCFDtF.js → p-CLQx9p9q.js} +1 -1
- package/dist/webcomponents/{p-b21ncS7l.js → p-CPVN4dXS.js} +1 -1
- package/dist/webcomponents/p-CQeex56P.js +1 -0
- package/dist/webcomponents/p-CU4XQ3fO.js +1 -0
- package/dist/webcomponents/{p-Bb-6bNcq.js → p-C_3N7nqh.js} +1 -1
- package/dist/webcomponents/{p-BRLwUSZk.js → p-CaxjN6Uo.js} +1 -1
- package/dist/webcomponents/p-CpKvg1ok.js +1 -0
- package/dist/webcomponents/p-CrQgyTRz.js +1 -0
- package/dist/webcomponents/{p-B_6n1dAh.js → p-CtA2NMVz.js} +1 -1
- package/dist/webcomponents/{p-Bu1jU017.js → p-CxzFvTgf.js} +1 -1
- package/dist/webcomponents/{p-DVBbk00Z.js → p-CzPUMw00.js} +1 -1
- package/dist/webcomponents/{p-DDUmOl3v.js → p-D--yCspA.js} +1 -1
- package/dist/webcomponents/{p-qWQmu-fb.js → p-D-JYHdJ7.js} +1 -1
- package/dist/webcomponents/p-D6XirF21.js +1 -0
- package/dist/webcomponents/p-DCIW8z1f.js +1 -0
- package/dist/webcomponents/{p-BfM6X7lF.js → p-DCMrHeJI.js} +1 -1
- package/dist/webcomponents/p-DbX0g1WF.js +1 -0
- package/dist/webcomponents/p-De8UloOS.js +1 -0
- package/dist/webcomponents/p-DsAwPf2y.js +1 -0
- package/dist/webcomponents/p-DvZcI6pC.js +1 -0
- package/dist/webcomponents/p-DyDHaG6n.js +1 -0
- package/dist/webcomponents/{p-D2_iJUrZ.js → p-DyOgQlh2.js} +1 -1
- package/dist/webcomponents/p-IG_KR8zP.js +1 -0
- package/dist/webcomponents/p-Xv8DuU3Y.js +1 -0
- package/dist/webcomponents/p-a0909318.entry.js +1 -0
- package/dist/webcomponents/p-a57c1400.entry.js +1 -0
- package/dist/webcomponents/{p-d46dbb83.entry.js → p-a71a5e64.entry.js} +1 -1
- package/dist/webcomponents/p-a85cf3e0.entry.js +1 -0
- package/dist/webcomponents/{p-72dda22b.entry.js → p-a90b8b93.entry.js} +1 -1
- package/dist/webcomponents/p-bb03a95a.entry.js +1 -0
- package/dist/webcomponents/p-c16c0cbc.entry.js +1 -0
- package/dist/webcomponents/p-c4Mh3ZZ_.js +1 -0
- package/dist/webcomponents/p-d2259dfd.entry.js +1 -0
- package/dist/webcomponents/p-d8e5d7b7.entry.js +1 -0
- package/dist/webcomponents/p-df385efe.entry.js +1 -0
- package/dist/webcomponents/{p-14ff3155.entry.js → p-df7f36aa.entry.js} +1 -1
- package/dist/webcomponents/p-e035a92e.entry.js +1 -0
- package/dist/webcomponents/{p-3e667b07.entry.js → p-e2a38ad0.entry.js} +1 -1
- package/dist/webcomponents/p-e628a0c8.entry.js +1 -0
- package/dist/webcomponents/p-e6516014.entry.js +1 -0
- package/dist/webcomponents/{p-97c0dde4.entry.js → p-e6e96be2.entry.js} +1 -1
- package/dist/webcomponents/p-e79338f9.entry.js +1 -0
- package/dist/webcomponents/p-e7edf4f4.entry.js +1 -0
- package/dist/webcomponents/p-eafd179b.entry.js +1 -0
- package/dist/webcomponents/p-f5c3f489.entry.js +1 -0
- package/dist/webcomponents/{p-C5id7s_l.js → p-fUtq2xDs.js} +1 -1
- package/dist/webcomponents/{p-7cf87637.entry.js → p-ffe01f1b.entry.js} +1 -1
- package/dist/webcomponents/{p-Dgflaz6J.js → p-oGKW57R8.js} +1 -1
- package/dist/webcomponents/p-qipqIMyC.js +2 -0
- package/dist/webcomponents/p-tyhA5jkt.js +1 -0
- package/dist/webcomponents/p-xY5RkFuA.js +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +14 -14
- package/LICENSE +0 -21
- package/dist/cjs/spinner-jmeA44Ee.js +0 -12
- package/dist/cjs/terminals-list-params-state-Cewmin_p.js +0 -22
- package/dist/cjs/utils-Bzyj4qWe.js +0 -29
- package/dist/esm/spinner-DUzyWLhj.js +0 -10
- package/dist/esm/terminals-list-params-state-D8tzsGR_.js +0 -16
- package/dist/esm/utils-Dg6gMUTv.js +0 -22
- package/dist/webcomponents/p-040e8524.entry.js +0 -1
- package/dist/webcomponents/p-0db9943e.entry.js +0 -1
- package/dist/webcomponents/p-1288fda5.entry.js +0 -1
- package/dist/webcomponents/p-3aecd2cd.entry.js +0 -1
- package/dist/webcomponents/p-3bf63d1e.entry.js +0 -1
- package/dist/webcomponents/p-41e17edd.entry.js +0 -1
- package/dist/webcomponents/p-43c5f490.entry.js +0 -1
- package/dist/webcomponents/p-44450a94.entry.js +0 -1
- package/dist/webcomponents/p-5580e6ca.entry.js +0 -1
- package/dist/webcomponents/p-57dde36e.entry.js +0 -1
- package/dist/webcomponents/p-5bc6f5ca.entry.js +0 -1
- package/dist/webcomponents/p-5f87add5.entry.js +0 -1
- package/dist/webcomponents/p-60206d9c.entry.js +0 -1
- package/dist/webcomponents/p-613421d4.entry.js +0 -1
- package/dist/webcomponents/p-6c9732b6.entry.js +0 -1
- package/dist/webcomponents/p-7089fb85.entry.js +0 -1
- package/dist/webcomponents/p-7500c5b7.entry.js +0 -1
- package/dist/webcomponents/p-79da5350.entry.js +0 -1
- package/dist/webcomponents/p-87884ca5.entry.js +0 -1
- package/dist/webcomponents/p-88905a54.entry.js +0 -1
- package/dist/webcomponents/p-8990707a.entry.js +0 -1
- package/dist/webcomponents/p-8b7cbdbf.entry.js +0 -1
- package/dist/webcomponents/p-8cca8903.entry.js +0 -1
- package/dist/webcomponents/p-8dc4eb6a.entry.js +0 -1
- package/dist/webcomponents/p-8ff839a4.entry.js +0 -1
- package/dist/webcomponents/p-95cbb655.entry.js +0 -1
- package/dist/webcomponents/p-98cffba9.entry.js +0 -1
- package/dist/webcomponents/p-9df86b97.entry.js +0 -1
- package/dist/webcomponents/p-9edfd38c.entry.js +0 -1
- package/dist/webcomponents/p-9f5c9e41.entry.js +0 -1
- package/dist/webcomponents/p-B5Rc83j1.js +0 -1
- package/dist/webcomponents/p-BEPUC3Po.js +0 -1
- package/dist/webcomponents/p-BP7op0vq.js +0 -1
- package/dist/webcomponents/p-BQ2TIFoY.js +0 -1
- package/dist/webcomponents/p-BSt6p1oq.js +0 -1
- package/dist/webcomponents/p-BY1mRAvj.js +0 -1
- package/dist/webcomponents/p-BbZwa5UI.js +0 -1
- package/dist/webcomponents/p-BiWRKUx3.js +0 -1
- package/dist/webcomponents/p-Bn7inNWG.js +0 -2
- package/dist/webcomponents/p-C6c6Q0E7.js +0 -1
- package/dist/webcomponents/p-CaAVuW6B.js +0 -1
- package/dist/webcomponents/p-CpaS1Lex.js +0 -1
- package/dist/webcomponents/p-DD0Mvpeu.js +0 -1
- package/dist/webcomponents/p-DIDloHpm.js +0 -1
- package/dist/webcomponents/p-Dc1CS9Mi.js +0 -1
- package/dist/webcomponents/p-DsZZxRXY.js +0 -1
- package/dist/webcomponents/p-a1d3bb81.entry.js +0 -1
- package/dist/webcomponents/p-a9957ca5.entry.js +0 -1
- package/dist/webcomponents/p-abbf14b5.entry.js +0 -1
- package/dist/webcomponents/p-b2dcef65.entry.js +0 -1
- package/dist/webcomponents/p-c44325f8.entry.js +0 -1
- package/dist/webcomponents/p-c874ca2b.entry.js +0 -1
- package/dist/webcomponents/p-caac63bf.entry.js +0 -1
- package/dist/webcomponents/p-d72e8541.entry.js +0 -1
- package/dist/webcomponents/p-da44dc6e.entry.js +0 -1
- package/dist/webcomponents/p-e0cb5de5.entry.js +0 -1
- package/dist/webcomponents/p-eP3fmhta.js +0 -1
- package/dist/webcomponents/p-ecce97b3.entry.js +0 -1
- package/dist/webcomponents/p-f680e617.entry.js +0 -1
- package/dist/webcomponents/p-fd4ffaa2.entry.js +0 -1
- package/dist/webcomponents/p-sw5RO19U.js +0 -1
|
@@ -1,26 +1,27 @@
|
|
|
1
|
-
import { r as registerInstance, h, c as createEvent, H as Host, g as getElement } from './index-
|
|
1
|
+
import { r as registerInstance, h, c as createEvent, H as Host, g as getElement } from './index-qipqIMyC.js';
|
|
2
2
|
import { z as text, r as radioListItem } from './parts-RvUQ__Pq.js';
|
|
3
|
-
import { f as formatCurrency } from './utils-
|
|
4
|
-
import { c as checkoutStore,
|
|
5
|
-
import { S as StyledHost } from './styled-host-
|
|
3
|
+
import { f as formatCurrency } from './utils-BscIVFn8.js';
|
|
4
|
+
import { c as checkoutStore, o as onAnyChange, g as getAvailablePaymentMethodTypes, a as onChange } from './checkout.store-DBvS7cVB.js';
|
|
5
|
+
import { S as StyledHost } from './styled-host-CbizlfAU.js';
|
|
6
6
|
import './event-types-CZfYo5-1.js';
|
|
7
|
-
import { H as Header1 } from './header-1-
|
|
8
|
-
import { H as Header2, b as insuranceValuesOn, h as hasInsuranceValueChanged, i as insuranceValues } from './insurance-state-
|
|
9
|
-
import { H as Header3 } from './header-3-
|
|
10
|
-
import { J as JustifiAnalytics, c as checkPkgVersion } from './check-pkg-version-
|
|
11
|
-
import './config-state-
|
|
7
|
+
import { H as Header1 } from './header-1-zXsamUS3.js';
|
|
8
|
+
import { H as Header2, b as insuranceValuesOn, h as hasInsuranceValueChanged, i as insuranceValues } from './insurance-state-Dh9f36Qh.js';
|
|
9
|
+
import { H as Header3 } from './header-3-DVtaUAlf.js';
|
|
10
|
+
import { J as JustifiAnalytics, c as checkPkgVersion } from './check-pkg-version-DSO4z-Vx.js';
|
|
11
|
+
import './config-state-Blo0ywwc.js';
|
|
12
12
|
import './dinero-HXpYMWUU.js';
|
|
13
13
|
import { C as ComponentErrorSeverity, a as ComponentErrorCodes, b as ComponentErrorMessages } from './ComponentError-Cjcsf8ku.js';
|
|
14
|
-
import { I as ICheckoutStatus } from './Refund-
|
|
14
|
+
import { I as ICheckoutStatus } from './Refund-Bc5By0lb.js';
|
|
15
15
|
import './Pagination-CLHwhyvu.js';
|
|
16
16
|
import './Business-BCoP0TAV.js';
|
|
17
17
|
import './Dispute-BH0Xfn-F.js';
|
|
18
18
|
import { g as getErrorCode, a as getErrorMessage } from './utils-BeQLScSm.js';
|
|
19
|
-
import { C as CheckoutService } from './checkout.service-
|
|
20
|
-
import { A as Api } from './Api-
|
|
19
|
+
import { C as CheckoutService } from './checkout.service-BCkQ9pOA.js';
|
|
20
|
+
import { A as Api } from './Api-D4tj-h4P.js';
|
|
21
|
+
import { P as PAYMENT_METHODS, a as PaymentMethod, b as PAYMENT_MODE } from './index-DCIW8z1f.js';
|
|
21
22
|
import { C as CardBrandLabels } from './payment-method-option-utils-lUHAQVFl.js';
|
|
22
|
-
import './index-
|
|
23
|
-
import './package-
|
|
23
|
+
import './index-ZfXl6Xrm.js';
|
|
24
|
+
import './package-tyhA5jkt.js';
|
|
24
25
|
import './helpers-Mu7LQT-w.js';
|
|
25
26
|
import './state-options-BX8GieXu.js';
|
|
26
27
|
|
|
@@ -29,7 +30,7 @@ const Summary = class {
|
|
|
29
30
|
registerInstance(this, hostRef);
|
|
30
31
|
}
|
|
31
32
|
render() {
|
|
32
|
-
return (h(StyledHost, { key: '
|
|
33
|
+
return (h(StyledHost, { key: '3161e6f6a196c79d684574cafbc90bcf741b2150' }, h("section", { key: '594b4485ed4fd9d7c1ee7f4556f071139f92ef0c' }, h("div", { key: '5c2d14677dda6fc7ddcb074d4887b839385dca3a' }, h("div", { key: 'fb850cd7e9c11741349710696dd4e6241c98e805', part: text }, checkoutStore === null || checkoutStore === void 0 ? void 0 : checkoutStore.paymentDescription), h("div", { key: '959014d7fa2a9c97bae0c986313a604930c1e0f3' }, h("span", { key: '14ab0932a083568419b1c36c95f9072c73962b11', part: text }, "Total"), "\u00A0", h("span", { key: '08a9e00332253070ae984b77eb2a9bab88eb3472', part: text }, formatCurrency(+(checkoutStore === null || checkoutStore === void 0 ? void 0 : checkoutStore.totalAmount))))))));
|
|
33
34
|
}
|
|
34
35
|
};
|
|
35
36
|
|
|
@@ -45,7 +46,7 @@ const Header = class {
|
|
|
45
46
|
}
|
|
46
47
|
render() {
|
|
47
48
|
const HeaderComponent = this.levels[this.level];
|
|
48
|
-
return (h(StyledHost, { key: '
|
|
49
|
+
return (h(StyledHost, { key: 'eb3651b698897193d34a6c6456cd57dd0bd0bc43' }, h(HeaderComponent, { key: '39caee687f93d3d4d90e62d9fbcae318eaa8022e', text: this.text, class: this.class })));
|
|
49
50
|
}
|
|
50
51
|
};
|
|
51
52
|
|
|
@@ -104,18 +105,38 @@ const makeCheckoutComplete = ({ authToken, checkoutId, service }) => async ({ pa
|
|
|
104
105
|
}
|
|
105
106
|
};
|
|
106
107
|
|
|
108
|
+
const api = Api();
|
|
109
|
+
class PlaidService {
|
|
110
|
+
async getLinkToken(authToken, accountId, checkoutId, signal) {
|
|
111
|
+
const endpoint = `plaid/${accountId}/link`;
|
|
112
|
+
const body = { checkout_id: checkoutId };
|
|
113
|
+
return api.post({ endpoint, body, authToken, signal });
|
|
114
|
+
}
|
|
115
|
+
async tokenizeBankAccount(authToken, accountId, publicToken, linkTokenId, paymentMethodGroupId, signal) {
|
|
116
|
+
const endpoint = `plaid/${accountId}/tokenize`;
|
|
117
|
+
const body = { public_token: publicToken };
|
|
118
|
+
if (linkTokenId) {
|
|
119
|
+
body.link_token_id = linkTokenId;
|
|
120
|
+
}
|
|
121
|
+
if (paymentMethodGroupId) {
|
|
122
|
+
body.payment_method_group_id = paymentMethodGroupId;
|
|
123
|
+
}
|
|
124
|
+
return api.post({ endpoint, body, authToken, signal });
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
107
128
|
const ModularCheckout = class {
|
|
108
129
|
constructor(hostRef) {
|
|
109
130
|
registerInstance(this, hostRef);
|
|
110
131
|
this.errorEvent = createEvent(this, "error-event");
|
|
111
132
|
this.submitEvent = createEvent(this, "submit-event");
|
|
112
|
-
this.
|
|
113
|
-
this.
|
|
133
|
+
this.checkoutChangedEvent = createEvent(this, "checkout-changed");
|
|
134
|
+
this.plaidService = new PlaidService();
|
|
114
135
|
this.handleApplePayCompleted = (event) => {
|
|
115
136
|
const { success, token, paymentMethodId, error } = event.detail;
|
|
116
137
|
if (success && token) {
|
|
117
138
|
checkoutStore.paymentToken = paymentMethodId;
|
|
118
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.APPLE_PAY;
|
|
139
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.APPLE_PAY };
|
|
119
140
|
this.submitCheckout();
|
|
120
141
|
}
|
|
121
142
|
else {
|
|
@@ -128,11 +149,12 @@ const ModularCheckout = class {
|
|
|
128
149
|
}
|
|
129
150
|
};
|
|
130
151
|
this.handleApplePayError = (event) => {
|
|
131
|
-
const { error } = event.detail;
|
|
152
|
+
const { error, code } = event.detail;
|
|
132
153
|
console.error("Apple Pay error:", error);
|
|
133
154
|
this.errorEvent.emit({
|
|
134
155
|
message: error || "Apple Pay error occurred",
|
|
135
|
-
|
|
156
|
+
// prefix with APPLE_PAY_
|
|
157
|
+
errorCode: `APPLE_PAY_${code}`,
|
|
136
158
|
severity: ComponentErrorSeverity.ERROR,
|
|
137
159
|
});
|
|
138
160
|
};
|
|
@@ -141,9 +163,6 @@ const ModularCheckout = class {
|
|
|
141
163
|
checkoutStore.selectedPaymentMethod = undefined;
|
|
142
164
|
};
|
|
143
165
|
}
|
|
144
|
-
savePaymentMethodChanged(newValue) {
|
|
145
|
-
checkoutStore.savePaymentMethod = newValue;
|
|
146
|
-
}
|
|
147
166
|
connectedCallback() {
|
|
148
167
|
this.observer = new MutationObserver(() => {
|
|
149
168
|
this.queryFormRefs();
|
|
@@ -161,15 +180,15 @@ const ModularCheckout = class {
|
|
|
161
180
|
};
|
|
162
181
|
this.getCheckout = makeGetCheckout(config);
|
|
163
182
|
this.completeCheckout = makeCheckoutComplete(config);
|
|
164
|
-
|
|
165
|
-
|
|
183
|
+
// Emit checkout-changed whenever any store key changes
|
|
184
|
+
onAnyChange(() => {
|
|
185
|
+
this.emitCheckoutChanged();
|
|
166
186
|
});
|
|
167
187
|
}
|
|
168
188
|
componentWillLoad() {
|
|
169
189
|
this.analytics = new JustifiAnalytics(this);
|
|
170
190
|
checkPkgVersion();
|
|
171
191
|
checkoutStore.authToken = this.authToken;
|
|
172
|
-
checkoutStore.savePaymentMethod = this.savePaymentMethod;
|
|
173
192
|
this.fetchCheckout();
|
|
174
193
|
// Refresh the checkout data when insurance values actually change (not on initial load)
|
|
175
194
|
insuranceValuesOn("set", (key) => {
|
|
@@ -200,6 +219,7 @@ const ModularCheckout = class {
|
|
|
200
219
|
if (this.getCheckout) {
|
|
201
220
|
this.getCheckout({
|
|
202
221
|
onSuccess: ({ checkout }) => {
|
|
222
|
+
this.updateStore(checkout);
|
|
203
223
|
if (checkout.status === ICheckoutStatus.completed) {
|
|
204
224
|
this.errorEvent.emit({
|
|
205
225
|
message: ComponentErrorMessages.CHECKOUT_ALREADY_COMPLETED,
|
|
@@ -216,13 +236,12 @@ const ModularCheckout = class {
|
|
|
216
236
|
});
|
|
217
237
|
return;
|
|
218
238
|
}
|
|
219
|
-
this.updateStore(checkout);
|
|
220
239
|
},
|
|
221
240
|
onError: (error) => {
|
|
222
241
|
this.errorEvent.emit({
|
|
223
242
|
message: error.message,
|
|
224
|
-
errorCode:
|
|
225
|
-
severity:
|
|
243
|
+
errorCode: error.code,
|
|
244
|
+
severity: error.severity,
|
|
226
245
|
});
|
|
227
246
|
},
|
|
228
247
|
});
|
|
@@ -231,7 +250,8 @@ const ModularCheckout = class {
|
|
|
231
250
|
updateStore(checkout) {
|
|
232
251
|
var _a, _b, _c, _d, _e;
|
|
233
252
|
checkoutStore.accountId = checkout.account_id;
|
|
234
|
-
checkoutStore.
|
|
253
|
+
checkoutStore.checkoutLoaded = true;
|
|
254
|
+
checkoutStore.paymentMethods = checkout.payment_methods.map((paymentMethod) => new PaymentMethod(paymentMethod));
|
|
235
255
|
checkoutStore.paymentMethodGroupId = checkout.payment_method_group_id;
|
|
236
256
|
checkoutStore.paymentDescription = checkout.payment_description;
|
|
237
257
|
checkoutStore.totalAmount = checkout.total_amount;
|
|
@@ -245,6 +265,14 @@ const ModularCheckout = class {
|
|
|
245
265
|
checkoutStore.bnplProviderCheckoutUrl =
|
|
246
266
|
(_e = checkout === null || checkout === void 0 ? void 0 : checkout.bnpl) === null || _e === void 0 ? void 0 : _e.provider_checkout_url;
|
|
247
267
|
}
|
|
268
|
+
emitCheckoutChanged() {
|
|
269
|
+
const detail = {
|
|
270
|
+
availablePaymentMethodTypes: getAvailablePaymentMethodTypes(),
|
|
271
|
+
selectedPaymentMethod: checkoutStore.selectedPaymentMethod,
|
|
272
|
+
savedPaymentMethods: checkoutStore.paymentMethods,
|
|
273
|
+
};
|
|
274
|
+
this.checkoutChangedEvent.emit(detail);
|
|
275
|
+
}
|
|
248
276
|
queryFormRefs() {
|
|
249
277
|
this.billingFormRef = this.hostEl.querySelector("justifi-billing-form, justifi-bank-account-billing-form-simple, justifi-card-billing-form-simple, justifi-billing-form-full");
|
|
250
278
|
this.applePayRef = this.hostEl.querySelector("justifi-apple-pay");
|
|
@@ -289,16 +317,19 @@ const ModularCheckout = class {
|
|
|
289
317
|
// set the selected payment method to the checkout store from outside the component
|
|
290
318
|
async setSelectedPaymentMethod(paymentMethod) {
|
|
291
319
|
checkoutStore.selectedPaymentMethod = paymentMethod;
|
|
320
|
+
checkoutStore.paymentToken = paymentMethod.id || undefined;
|
|
292
321
|
}
|
|
293
322
|
// if validation fails, the error will be emitted by the component
|
|
294
323
|
async validate() {
|
|
324
|
+
var _a, _b;
|
|
295
325
|
const promises = [];
|
|
296
326
|
if (checkoutStore.insuranceEnabled && this.insuranceFormRef) {
|
|
297
327
|
promises.push(this.insuranceFormRef.validate());
|
|
298
328
|
}
|
|
329
|
+
const isNewCard = ((_a = checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === PAYMENT_METHODS.NEW_CARD;
|
|
330
|
+
const isNewBankAccount = ((_b = checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === PAYMENT_METHODS.NEW_BANK_ACCOUNT;
|
|
299
331
|
// For new card/bank account, validate payment method + billing.
|
|
300
|
-
if (
|
|
301
|
-
checkoutStore.selectedPaymentMethod === PAYMENT_METHODS.NEW_BANK_ACCOUNT) {
|
|
332
|
+
if (isNewCard || isNewBankAccount) {
|
|
302
333
|
if (this.paymentMethodFormRef)
|
|
303
334
|
promises.push(this.paymentMethodFormRef.validate());
|
|
304
335
|
if (this.billingFormRef)
|
|
@@ -322,17 +353,29 @@ const ModularCheckout = class {
|
|
|
322
353
|
}
|
|
323
354
|
return true;
|
|
324
355
|
}
|
|
325
|
-
catch (
|
|
356
|
+
catch (_c) {
|
|
326
357
|
// If any validator throws/rejects, consider the whole validation failed.
|
|
327
358
|
return false;
|
|
328
359
|
}
|
|
329
360
|
}
|
|
330
361
|
async submitCheckout(submitCheckoutArgs) {
|
|
362
|
+
var _a, _b, _c, _d, _e;
|
|
331
363
|
const isValid = await this.validate();
|
|
332
|
-
|
|
364
|
+
if (!checkoutStore.selectedPaymentMethod) {
|
|
365
|
+
this.errorEvent.emit({
|
|
366
|
+
message: 'No payment method selected.',
|
|
367
|
+
errorCode: ComponentErrorCodes.VALIDATION_ERROR,
|
|
368
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
369
|
+
});
|
|
370
|
+
return;
|
|
371
|
+
}
|
|
372
|
+
const isNewCard = ((_a = checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === PAYMENT_METHODS.NEW_CARD;
|
|
373
|
+
const isNewBankAccount = ((_b = checkoutStore.selectedPaymentMethod) === null || _b === void 0 ? void 0 : _b.type) === PAYMENT_METHODS.NEW_BANK_ACCOUNT;
|
|
374
|
+
const isPlaid = ((_c = checkoutStore.selectedPaymentMethod) === null || _c === void 0 ? void 0 : _c.type) === PAYMENT_METHODS.PLAID;
|
|
375
|
+
const shouldTokenize = isNewCard || isNewBankAccount;
|
|
333
376
|
if (shouldTokenize) {
|
|
334
377
|
const tokenizeResult = await this.tokenizePaymentMethod(submitCheckoutArgs);
|
|
335
|
-
if (tokenizeResult.error) {
|
|
378
|
+
if (tokenizeResult === null || tokenizeResult === void 0 ? void 0 : tokenizeResult.error) {
|
|
336
379
|
this.errorEvent.emit({
|
|
337
380
|
message: tokenizeResult.error.message,
|
|
338
381
|
errorCode: ComponentErrorCodes.TOKENIZE_ERROR,
|
|
@@ -341,6 +384,41 @@ const ModularCheckout = class {
|
|
|
341
384
|
return;
|
|
342
385
|
}
|
|
343
386
|
}
|
|
387
|
+
// For Plaid, perform exchange at submit time using stored public token and link token id
|
|
388
|
+
if (isPlaid && !checkoutStore.paymentToken) {
|
|
389
|
+
const publicToken = checkoutStore.plaidPublicToken;
|
|
390
|
+
const linkTokenId = checkoutStore.plaidLinkTokenId;
|
|
391
|
+
if (!publicToken) {
|
|
392
|
+
this.errorEvent.emit({
|
|
393
|
+
message: 'Missing Plaid public token. Please connect your bank.',
|
|
394
|
+
errorCode: ComponentErrorCodes.TOKENIZE_ERROR,
|
|
395
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
396
|
+
});
|
|
397
|
+
return;
|
|
398
|
+
}
|
|
399
|
+
try {
|
|
400
|
+
const response = await this.plaidService.tokenizeBankAccount(checkoutStore.authToken, checkoutStore.accountId, publicToken, linkTokenId || undefined, checkoutStore.savePaymentMethod ? checkoutStore.paymentMethodGroupId : undefined);
|
|
401
|
+
if (response === null || response === void 0 ? void 0 : response.error) {
|
|
402
|
+
this.errorEvent.emit({
|
|
403
|
+
message: typeof response.error === 'string' ? response.error : response.error.message || 'Failed to tokenize bank account',
|
|
404
|
+
errorCode: ComponentErrorCodes.TOKENIZE_ERROR,
|
|
405
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
406
|
+
});
|
|
407
|
+
return;
|
|
408
|
+
}
|
|
409
|
+
const paymentMethod = response === null || response === void 0 ? void 0 : response.data;
|
|
410
|
+
const token = ((_d = paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.bank_account) === null || _d === void 0 ? void 0 : _d.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id);
|
|
411
|
+
checkoutStore.paymentToken = token;
|
|
412
|
+
}
|
|
413
|
+
catch (err) {
|
|
414
|
+
this.errorEvent.emit({
|
|
415
|
+
message: (err === null || err === void 0 ? void 0 : err.message) || 'Plaid exchange error',
|
|
416
|
+
errorCode: ComponentErrorCodes.TOKENIZE_ERROR,
|
|
417
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
418
|
+
});
|
|
419
|
+
return;
|
|
420
|
+
}
|
|
421
|
+
}
|
|
344
422
|
if (!isValid) {
|
|
345
423
|
this.errorEvent.emit({
|
|
346
424
|
message: "Please fill in all required fields.",
|
|
@@ -355,19 +433,27 @@ const ModularCheckout = class {
|
|
|
355
433
|
errorCode: ComponentErrorCodes.TOKENIZE_ERROR,
|
|
356
434
|
severity: ComponentErrorSeverity.ERROR,
|
|
357
435
|
});
|
|
436
|
+
return;
|
|
358
437
|
}
|
|
359
438
|
let payment;
|
|
360
|
-
const
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
439
|
+
const mapTypeToPaymentMode = (type) => {
|
|
440
|
+
switch (type) {
|
|
441
|
+
case PAYMENT_METHODS.NEW_CARD:
|
|
442
|
+
case PAYMENT_METHODS.SAVED_CARD:
|
|
443
|
+
case PAYMENT_METHODS.NEW_BANK_ACCOUNT:
|
|
444
|
+
case PAYMENT_METHODS.SAVED_BANK_ACCOUNT:
|
|
445
|
+
case PAYMENT_METHODS.PLAID:
|
|
446
|
+
return PAYMENT_MODE.ECOM;
|
|
447
|
+
case PAYMENT_METHODS.SEZZLE:
|
|
448
|
+
return PAYMENT_MODE.BNPL;
|
|
449
|
+
case PAYMENT_METHODS.APPLE_PAY:
|
|
450
|
+
return PAYMENT_MODE.APPLE_PAY;
|
|
451
|
+
default:
|
|
452
|
+
return undefined;
|
|
453
|
+
}
|
|
368
454
|
};
|
|
369
455
|
payment = {
|
|
370
|
-
payment_mode:
|
|
456
|
+
payment_mode: mapTypeToPaymentMode((_e = checkoutStore.selectedPaymentMethod) === null || _e === void 0 ? void 0 : _e.type),
|
|
371
457
|
payment_token: checkoutStore.paymentToken,
|
|
372
458
|
};
|
|
373
459
|
this.completeCheckout({
|
|
@@ -388,36 +474,13 @@ const ModularCheckout = class {
|
|
|
388
474
|
});
|
|
389
475
|
}
|
|
390
476
|
render() {
|
|
391
|
-
return h(Host, { key: '
|
|
477
|
+
return h(Host, { key: 'dbe1fe78f8206fef2e3f4f51628d716786dea858' });
|
|
392
478
|
}
|
|
393
479
|
get hostEl() { return getElement(this); }
|
|
394
|
-
static get watchers() { return {
|
|
395
|
-
"savePaymentMethod": ["savePaymentMethodChanged"]
|
|
396
|
-
}; }
|
|
397
480
|
};
|
|
398
481
|
|
|
399
482
|
const plaidIconSvg = 'data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjQ4IiB2aWV3Qm94PSIwIDAgMjggMjkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgY2xhc3M9ImNzcy0xcmRhajhtIj48ZyBmaWxsPSIjMTExIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yNS43NjI5IDI2LjI2MjhMMjggMTcuNTMwOUwyNC45NjkxIDE0LjUwMDFMMjcuOTk5OSAxMS40NjkxTDI1Ljc2MjggMi43MzcwNkwxNy4wMzA5IDAuNUwxNC4wMDAxIDMuNTMxTDEwLjk2OSAwLjUwMDE0TDIuMjM3MDYgMi43MzczNEwwIDExLjQ2OTFMMy4wMzEyOCAxNC40OTk5TDAuMDAwMTQgMTcuNTMxTDIuMjM3MiAyNi4yNjI5TDEwLjk2OTEgMjguNUwxNC4wMDAxIDI1LjQ2OUwxNy4wMzEgMjguNDk5OUwyNS43NjI5IDI2LjI2MjhaTTE1LjczMjEgMjMuNzM3MUwxOC42MTg2IDIwLjg1MDVMMjIuMjkxMiAyNC41MjMzTDE3LjY5NTYgMjUuNzAwN0wxNS43MzIxIDIzLjczNzFaTTExLjExMzYgOS44ODE1NEwxNC4wMDAzIDYuOTk1MDJMMTYuODg2OCA5Ljg4MTRMMTQuMDAwMSAxMi43Njc5TDExLjExMzYgOS44ODE1NFpNMTIuMjY4MiAxNC41TDkuMzgxNTQgMTcuMzg2NUw2LjQ5NTAyIDE0LjVMOS4zODE1NCAxMS42MTM1TDEyLjI2ODIgMTQuNVpNMTguNjE4NyAxMS42MTMzTDIxLjUwNTMgMTQuNUwxOC42MTg2IDE3LjM4NjVMMTUuNzMyMSAxNC41TDE4LjYxODcgMTEuNjEzM1pNMTYuODg2NyAxOS4xMTg2TDE0LjAwMDEgMjIuMDA1MUwxMS4xMTM1IDE5LjExODVMMTQuMDAwMSAxNi4yMzE5TDE2Ljg4NjcgMTkuMTE4NlpNMTAuMzA0NCAyNS43MDA3TDUuNzA4NjQgMjQuNTIzM0w5LjM4MTU0IDIwLjg1MDRMMTIuMjY4MiAyMy43MzcxTDEwLjMwNDQgMjUuNzAwN1pNNC43NjMwOCAxNi4yMzE5TDcuNjQ5NiAxOS4xMTg1TDMuOTc2NyAyMi43OTE0TDIuNzk5MyAxOC4xOTU3TDQuNzYzMDggMTYuMjMxOVpNMy45NzY3IDYuMjA4MzZMNy42NDk3NCA5Ljg4MTRMNC43NjMwOCAxMi43NjgxTDIuNzk5MyAxMC44MDQxTDMuOTc2NyA2LjIwODM2Wk0xMi4yNjgzIDUuMjYyOTRMOS4zODE2OCA4LjE0OTZMNS43MDg5MiA0LjQ3NjdMMTAuMzA0NyAzLjI5OTNMMTIuMjY4MyA1LjI2Mjk0Wk0xNy42OTU5IDMuMjk5M0wyMi4yOTE1IDQuNDc2N0wxOC42MTg2IDguMTQ5NDZMMTUuNzMyMSA1LjI2Mjk0TDE3LjY5NTkgMy4yOTkzWk0yMy4yMzcyIDEyLjc2ODFMMjAuMzUwNSA5Ljg4MTRMMjQuMDIzMyA2LjIwODc4TDI1LjIwMDcgMTAuODA0NkwyMy4yMzcyIDEyLjc2ODFaTTI0LjAyMzMgMjIuNzkxNEwyMC4zNTA1IDE5LjExODZMMjMuMjM3MiAxNi4yMzIxTDI1LjIwMDcgMTguMTk1N0wyNC4wMjMzIDIyLjc5MTRaIj48L3BhdGg+PC9nPjwvc3ZnPgo=';
|
|
400
483
|
|
|
401
|
-
const api = Api();
|
|
402
|
-
class PlaidService {
|
|
403
|
-
async getLinkToken(authToken, accountId, checkoutId, signal) {
|
|
404
|
-
const endpoint = `plaid/${accountId}/link`;
|
|
405
|
-
const body = { checkout_id: checkoutId };
|
|
406
|
-
return api.post({ endpoint, body, authToken, signal });
|
|
407
|
-
}
|
|
408
|
-
async tokenizeBankAccount(authToken, accountId, publicToken, linkTokenId, paymentMethodGroupId, signal) {
|
|
409
|
-
const endpoint = `plaid/${accountId}/tokenize`;
|
|
410
|
-
const body = { public_token: publicToken };
|
|
411
|
-
if (linkTokenId) {
|
|
412
|
-
body.link_token_id = linkTokenId;
|
|
413
|
-
}
|
|
414
|
-
if (paymentMethodGroupId) {
|
|
415
|
-
body.payment_method_group_id = paymentMethodGroupId;
|
|
416
|
-
}
|
|
417
|
-
return api.post({ endpoint, body, authToken, signal });
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
|
|
421
484
|
// Plaid-specific error codes
|
|
422
485
|
var PlaidErrorCodes;
|
|
423
486
|
(function (PlaidErrorCodes) {
|
|
@@ -500,25 +563,6 @@ const PlaidPaymentMethod = class {
|
|
|
500
563
|
}, 100);
|
|
501
564
|
}
|
|
502
565
|
};
|
|
503
|
-
this.onPaymentMethodOptionClick = (e) => {
|
|
504
|
-
e.preventDefault();
|
|
505
|
-
// Update local selection state
|
|
506
|
-
this.isSelected = true;
|
|
507
|
-
// Update store selection
|
|
508
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.PLAID;
|
|
509
|
-
// Emit selection event
|
|
510
|
-
this.paymentMethodOptionSelected.emit(PAYMENT_METHODS.PLAID);
|
|
511
|
-
// If there's an error, clear it and try to initialize again
|
|
512
|
-
if (this.error) {
|
|
513
|
-
this.clearError();
|
|
514
|
-
this.waitForStoreAndInitialize();
|
|
515
|
-
return;
|
|
516
|
-
}
|
|
517
|
-
// If Plaid Link is ready and no public token exists, open Plaid Link
|
|
518
|
-
if (this.plaidLink && !this.publicToken && !this.isAuthenticating) {
|
|
519
|
-
this.openPlaidLink();
|
|
520
|
-
}
|
|
521
|
-
};
|
|
522
566
|
this.initializePlaidLink = async () => {
|
|
523
567
|
try {
|
|
524
568
|
// Check if Plaid is available globally
|
|
@@ -601,6 +645,9 @@ const PlaidPaymentMethod = class {
|
|
|
601
645
|
this.linkToken = response.data.link_token;
|
|
602
646
|
// Try to capture link token id if present in envelope
|
|
603
647
|
this.linkTokenId = (response === null || response === void 0 ? void 0 : response.id) || ((_a = response === null || response === void 0 ? void 0 : response.data) === null || _a === void 0 ? void 0 : _a.id) || null;
|
|
648
|
+
if (this.linkTokenId) {
|
|
649
|
+
checkoutStore.plaidLinkTokenId = this.linkTokenId;
|
|
650
|
+
}
|
|
604
651
|
}
|
|
605
652
|
catch (error) {
|
|
606
653
|
// Clear timeout
|
|
@@ -672,7 +719,7 @@ const PlaidPaymentMethod = class {
|
|
|
672
719
|
// Ensure the component remains selected after successful authentication
|
|
673
720
|
if (!this.isSelected) {
|
|
674
721
|
this.isSelected = true;
|
|
675
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.PLAID;
|
|
722
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.PLAID };
|
|
676
723
|
}
|
|
677
724
|
// Emit success event for parent components
|
|
678
725
|
this.plaidErrorRecovered.emit({
|
|
@@ -680,41 +727,10 @@ const PlaidPaymentMethod = class {
|
|
|
680
727
|
message: 'Bank account connected successfully',
|
|
681
728
|
severity: ComponentErrorSeverity.INFO
|
|
682
729
|
});
|
|
683
|
-
//
|
|
684
|
-
|
|
685
|
-
};
|
|
686
|
-
this.exchangePublicTokenForPaymentMethod = async () => {
|
|
687
|
-
var _a;
|
|
688
|
-
if (!this.publicToken) {
|
|
689
|
-
console.error('[PlaidPaymentMethod] exchange: missing publicToken');
|
|
690
|
-
return;
|
|
691
|
-
}
|
|
692
|
-
if (!checkoutStore.authToken || !checkoutStore.accountId) {
|
|
693
|
-
console.error('[PlaidPaymentMethod] exchange: missing auth/account context');
|
|
694
|
-
return;
|
|
695
|
-
}
|
|
696
|
-
try {
|
|
697
|
-
const response = await this.plaidService.tokenizeBankAccount(checkoutStore.authToken, checkoutStore.accountId, this.publicToken, this.linkTokenId || undefined, checkoutStore.savePaymentMethod ? checkoutStore.paymentMethodGroupId : undefined);
|
|
698
|
-
if (response === null || response === void 0 ? void 0 : response.error) {
|
|
699
|
-
console.error('[PlaidPaymentMethod] exchange: backend error', response.error);
|
|
700
|
-
return;
|
|
701
|
-
}
|
|
702
|
-
// Extract token from payment method response
|
|
703
|
-
const paymentMethod = response === null || response === void 0 ? void 0 : response.data;
|
|
704
|
-
const token = ((_a = paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.bank_account) === null || _a === void 0 ? void 0 : _a.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.token) || (paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id);
|
|
705
|
-
if (!token) {
|
|
706
|
-
console.error('[PlaidPaymentMethod] exchange: no token in response');
|
|
707
|
-
return;
|
|
708
|
-
}
|
|
709
|
-
// Save for downstream submit flows
|
|
710
|
-
checkoutStore.paymentToken = token;
|
|
711
|
-
}
|
|
712
|
-
catch (err) {
|
|
713
|
-
console.error('[PlaidPaymentMethod] exchange: exception', {
|
|
714
|
-
message: (err === null || err === void 0 ? void 0 : err.message) || String(err),
|
|
715
|
-
});
|
|
716
|
-
}
|
|
730
|
+
// Store public token in checkout store; exchange will be handled on submit
|
|
731
|
+
checkoutStore.plaidPublicToken = publicToken;
|
|
717
732
|
};
|
|
733
|
+
// Exchange logic moved to Modular Checkout submit flow.
|
|
718
734
|
this.handlePlaidExit = (err, _metadata) => {
|
|
719
735
|
this.isAuthenticating = false;
|
|
720
736
|
if (err) {
|
|
@@ -853,16 +869,26 @@ const PlaidPaymentMethod = class {
|
|
|
853
869
|
};
|
|
854
870
|
// Watch for store changes to sync component state
|
|
855
871
|
this.syncWithStore = () => {
|
|
856
|
-
|
|
872
|
+
var _a;
|
|
873
|
+
const shouldBeSelected = ((_a = checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === PAYMENT_METHODS.PLAID;
|
|
857
874
|
if (this.isSelected !== shouldBeSelected) {
|
|
858
875
|
this.isSelected = shouldBeSelected;
|
|
859
876
|
}
|
|
860
877
|
};
|
|
861
878
|
}
|
|
862
879
|
onSelectionChange(newValue) {
|
|
880
|
+
var _a;
|
|
863
881
|
// Ensure store is updated when component selection changes
|
|
864
|
-
if (newValue && checkoutStore.selectedPaymentMethod !== PAYMENT_METHODS.PLAID) {
|
|
865
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.PLAID;
|
|
882
|
+
if (newValue && ((_a = checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) !== PAYMENT_METHODS.PLAID) {
|
|
883
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.PLAID };
|
|
884
|
+
}
|
|
885
|
+
// Auto-start Plaid flow when selected and ready
|
|
886
|
+
if (newValue &&
|
|
887
|
+
this.plaidLink &&
|
|
888
|
+
!this.publicToken &&
|
|
889
|
+
!this.isAuthenticating &&
|
|
890
|
+
!this.error) {
|
|
891
|
+
this.openPlaidLink();
|
|
866
892
|
}
|
|
867
893
|
}
|
|
868
894
|
componentDidRender() {
|
|
@@ -884,8 +910,9 @@ const PlaidPaymentMethod = class {
|
|
|
884
910
|
};
|
|
885
911
|
}
|
|
886
912
|
componentWillLoad() {
|
|
913
|
+
var _a;
|
|
887
914
|
// Initialize selection state based on store
|
|
888
|
-
this.isSelected = checkoutStore.selectedPaymentMethod === PAYMENT_METHODS.PLAID;
|
|
915
|
+
this.isSelected = ((_a = checkoutStore.selectedPaymentMethod) === null || _a === void 0 ? void 0 : _a.type) === PAYMENT_METHODS.PLAID;
|
|
889
916
|
}
|
|
890
917
|
async resolvePaymentMethod() {
|
|
891
918
|
if (!this.publicToken) {
|
|
@@ -902,17 +929,29 @@ const PlaidPaymentMethod = class {
|
|
|
902
929
|
// Returns a usable payment method token for checkout completion.
|
|
903
930
|
// Will perform the backend exchange if the token is not yet present in the store.
|
|
904
931
|
async getPaymentToken() {
|
|
905
|
-
if (checkoutStore.paymentToken) {
|
|
906
|
-
return checkoutStore.paymentToken;
|
|
907
|
-
}
|
|
908
|
-
await this.exchangePublicTokenForPaymentMethod();
|
|
909
932
|
return checkoutStore.paymentToken;
|
|
910
933
|
}
|
|
934
|
+
async handleSelectionClick() {
|
|
935
|
+
// Update local selection state
|
|
936
|
+
this.isSelected = true;
|
|
937
|
+
// Update store selection
|
|
938
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.PLAID };
|
|
939
|
+
// If there's an error, clear it and try to initialize again
|
|
940
|
+
if (this.error) {
|
|
941
|
+
this.clearError();
|
|
942
|
+
this.waitForStoreAndInitialize();
|
|
943
|
+
return;
|
|
944
|
+
}
|
|
945
|
+
// If Plaid Link is ready and no public token exists, open Plaid Link
|
|
946
|
+
if (this.plaidLink && !this.publicToken && !this.isAuthenticating) {
|
|
947
|
+
this.openPlaidLink();
|
|
948
|
+
}
|
|
949
|
+
}
|
|
911
950
|
// Method to handle external selection changes (e.g., from other payment methods)
|
|
912
951
|
async setSelected(selected) {
|
|
913
952
|
this.isSelected = selected;
|
|
914
953
|
if (selected) {
|
|
915
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.PLAID;
|
|
954
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.PLAID };
|
|
916
955
|
}
|
|
917
956
|
}
|
|
918
957
|
// Method to check if component is currently selected
|
|
@@ -1019,7 +1058,7 @@ const PlaidPaymentMethod = class {
|
|
|
1019
1058
|
}
|
|
1020
1059
|
return null;
|
|
1021
1060
|
};
|
|
1022
|
-
return (h(StyledHost, { class: "payment-method" }, h("script", { src: "https://cdn.plaid.com/link/v2/stable/link-initialize.js", async: true, ref: (el) => (this.scriptRef = el) }), h("div", {
|
|
1061
|
+
return (h(StyledHost, { class: "payment-method" }, h("script", { src: "https://cdn.plaid.com/link/v2/stable/link-initialize.js", async: true, ref: (el) => (this.scriptRef = el) }), h("div", { title: "Pay with Plaid" }, h("div", { onClick: (event) => { event.preventDefault(); this.handleSelectionClick(); } }, "Pay with Bank Account ", plaidLogo, " "), renderErrorState(), renderStatusState())));
|
|
1023
1062
|
}
|
|
1024
1063
|
static get watchers() { return {
|
|
1025
1064
|
"isSelected": ["onSelectionChange"]
|
|
@@ -1031,18 +1070,16 @@ const SavedPaymentMethods = class {
|
|
|
1031
1070
|
registerInstance(this, hostRef);
|
|
1032
1071
|
this.onPaymentMethodOptionClick = (paymentMethod) => (e) => {
|
|
1033
1072
|
e.preventDefault();
|
|
1034
|
-
|
|
1035
|
-
[PAYMENT_METHOD_TYPES.CARD]: PAYMENT_METHODS.SAVED_CARD,
|
|
1036
|
-
[PAYMENT_METHOD_TYPES.BANK_ACCOUNT]: PAYMENT_METHODS.SAVED_BANK_ACCOUNT,
|
|
1037
|
-
};
|
|
1038
|
-
checkoutStore.selectedPaymentMethod = SELECTED_PAYMENT_METHODS[paymentMethod.type];
|
|
1073
|
+
checkoutStore.selectedPaymentMethod = { id: paymentMethod.id, type: paymentMethod.type };
|
|
1039
1074
|
checkoutStore.paymentToken = paymentMethod.id;
|
|
1040
1075
|
};
|
|
1041
|
-
this.isAllowedPaymentMethod = (
|
|
1042
|
-
|
|
1076
|
+
this.isAllowedPaymentMethod = (paymentMethodType) => {
|
|
1077
|
+
const isCard = paymentMethodType === PAYMENT_METHODS.SAVED_CARD;
|
|
1078
|
+
const isBankAccount = paymentMethodType === PAYMENT_METHODS.SAVED_BANK_ACCOUNT;
|
|
1079
|
+
if (isCard && checkoutStore.disableCreditCard) {
|
|
1043
1080
|
return false;
|
|
1044
1081
|
}
|
|
1045
|
-
if (
|
|
1082
|
+
if (isBankAccount && checkoutStore.disableBankAccount) {
|
|
1046
1083
|
return false;
|
|
1047
1084
|
}
|
|
1048
1085
|
return true;
|
|
@@ -1061,7 +1098,7 @@ const SavedPaymentMethods = class {
|
|
|
1061
1098
|
return null;
|
|
1062
1099
|
}
|
|
1063
1100
|
return (h(StyledHost, null, h("div", { class: "saved-payment-methods" }, checkoutStore.paymentMethods.length ? checkoutStore.paymentMethods
|
|
1064
|
-
.filter(this.isAllowedPaymentMethod)
|
|
1101
|
+
.filter((paymentMethod) => this.isAllowedPaymentMethod(paymentMethod.type))
|
|
1065
1102
|
.map((paymentMethod) => (h("div", { class: "radio-list-item p-3", part: radioListItem, onClick: this.onPaymentMethodOptionClick(paymentMethod) }, h("form-control-radio", { name: "paymentMethodType", value: paymentMethod === null || paymentMethod === void 0 ? void 0 : paymentMethod.id, checked: checkoutStore.paymentToken === (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)));
|
|
1066
1103
|
}
|
|
1067
1104
|
};
|
|
@@ -1077,11 +1114,6 @@ const SezzlePaymentMethod = class {
|
|
|
1077
1114
|
registerInstance(this, hostRef);
|
|
1078
1115
|
this.paymentMethodOptionSelected = createEvent(this, "paymentMethodOptionSelected");
|
|
1079
1116
|
this.paymentMethodOptionId = PAYMENT_METHODS.SEZZLE;
|
|
1080
|
-
this.onPaymentMethodOptionClick = (e) => {
|
|
1081
|
-
e.preventDefault();
|
|
1082
|
-
checkoutStore.selectedPaymentMethod = this.paymentMethodOptionId;
|
|
1083
|
-
this.paymentMethodOptionSelected.emit(this.paymentMethodOptionId);
|
|
1084
|
-
};
|
|
1085
1117
|
this.initializeSezzleCheckout = () => {
|
|
1086
1118
|
let resolveSezzlePromise;
|
|
1087
1119
|
this.sezzlePromise = new Promise((resolve) => { resolveSezzlePromise = resolve; });
|
|
@@ -1124,13 +1156,17 @@ const SezzlePaymentMethod = class {
|
|
|
1124
1156
|
this.sezzleButtonRef.click();
|
|
1125
1157
|
return this.sezzlePromise;
|
|
1126
1158
|
}
|
|
1159
|
+
async handleSelectionClick() {
|
|
1160
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.SEZZLE };
|
|
1161
|
+
this.paymentMethodOptionSelected.emit(this.paymentMethodOptionId);
|
|
1162
|
+
}
|
|
1127
1163
|
render() {
|
|
1128
1164
|
var _a, _b;
|
|
1129
1165
|
if (!checkoutStore.bnplEnabled || checkoutStore.disableBnpl) {
|
|
1130
1166
|
console.warn('justifi-sezzle-payment-method: BNPL is not enabled for this account.');
|
|
1131
1167
|
return null;
|
|
1132
1168
|
}
|
|
1133
|
-
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",
|
|
1169
|
+
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", 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)))))));
|
|
1134
1170
|
}
|
|
1135
1171
|
};
|
|
1136
1172
|
|
|
@@ -1174,7 +1210,7 @@ const TokenizePaymentMethod = class {
|
|
|
1174
1210
|
}
|
|
1175
1211
|
handleRadioClick(event) {
|
|
1176
1212
|
this.selectedPaymentMethod = event.detail;
|
|
1177
|
-
checkoutStore.selectedPaymentMethod = event.detail;
|
|
1213
|
+
checkoutStore.selectedPaymentMethod = { type: event.detail };
|
|
1178
1214
|
}
|
|
1179
1215
|
async fillBillingForm(fields) {
|
|
1180
1216
|
var _a;
|
|
@@ -1266,11 +1302,11 @@ const TokenizePaymentMethod = class {
|
|
|
1266
1302
|
}
|
|
1267
1303
|
if (!this.disableCreditCard) {
|
|
1268
1304
|
this.selectedPaymentMethod = PAYMENT_METHODS.NEW_CARD;
|
|
1269
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.NEW_CARD;
|
|
1305
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.NEW_CARD };
|
|
1270
1306
|
}
|
|
1271
1307
|
else if (!this.disableBankAccount) {
|
|
1272
1308
|
this.selectedPaymentMethod = PAYMENT_METHODS.NEW_BANK_ACCOUNT;
|
|
1273
|
-
checkoutStore.selectedPaymentMethod = PAYMENT_METHODS.NEW_BANK_ACCOUNT;
|
|
1309
|
+
checkoutStore.selectedPaymentMethod = { type: PAYMENT_METHODS.NEW_BANK_ACCOUNT };
|
|
1274
1310
|
}
|
|
1275
1311
|
}
|
|
1276
1312
|
setComputedHideSubmitButton() {
|
|
@@ -1369,17 +1405,17 @@ const TokenizePaymentMethod = class {
|
|
|
1369
1405
|
return this.disableCreditCard || this.disableBankAccount;
|
|
1370
1406
|
}
|
|
1371
1407
|
renderPaymentMethodOption(paymentMethodType) {
|
|
1372
|
-
const isSelected = this.selectedPaymentMethod === paymentMethodType;
|
|
1408
|
+
const isSelected = this.selectedPaymentMethod === paymentMethodType && checkoutStore.selectedPaymentMethod.id === undefined;
|
|
1373
1409
|
return (h("div", { class: "payment-method" }, h("justifi-radio-list-item", { name: "paymentMethodType", value: paymentMethodType, checked: isSelected, label: PAYMENT_METHOD_TYPE_LABELS[paymentMethodType], hidden: this.shouldHideRadioInput }), isSelected && this.renderSelectedPaymentMethodForm(paymentMethodType)));
|
|
1374
1410
|
}
|
|
1375
|
-
renderSelectedPaymentMethodForm(
|
|
1376
|
-
return (h("div", { class: "mt-4 pb-4" }, this.renderPaymentMethodForm(
|
|
1411
|
+
renderSelectedPaymentMethodForm(paymentMethodType) {
|
|
1412
|
+
return (h("div", { class: "mt-4 pb-4" }, this.renderPaymentMethodForm(paymentMethodType), h("div", { class: "mt-4" }, h("justifi-billing-form", { ref: (el) => (this.billingFormRef = el), hideCardBillingForm: this.hideCardBillingForm, hideBankAccountBillingForm: this.hideBankAccountBillingForm, paymentMethodType: paymentMethodType })), h("div", { class: "mt-4" }, h("justifi-save-new-payment-method", { hidden: !this.paymentMethodGroupID, label: this.savePaymentMethodLabel }))));
|
|
1377
1413
|
}
|
|
1378
|
-
renderPaymentMethodForm(
|
|
1379
|
-
return
|
|
1414
|
+
renderPaymentMethodForm(paymentMethodType) {
|
|
1415
|
+
return paymentMethodType === PAYMENT_METHODS.NEW_CARD ? (h("justifi-card-form", { ref: (el) => (this.paymentMethodFormRef = el) })) : (h("justifi-bank-account-form", { ref: (el) => (this.paymentMethodFormRef = el) }));
|
|
1380
1416
|
}
|
|
1381
1417
|
render() {
|
|
1382
|
-
return (h(StyledHost, { key: '
|
|
1418
|
+
return (h(StyledHost, { key: '5fc5dad15215fe24b421f4d6c13355fb849b8a76' }, h("form", { key: '0e0330e5b11ee3ae0bef9e092fa2fb2a0a6af3e7' }, h("fieldset", { key: 'ee4c026ccda62a249e019a9e105e40ea465fc400' }, h("div", { key: '15a8a86fa5be8a545745260d76a8c3b2569d6a0e', class: "row gy-3" }, h("div", { key: 'bbbeed6ee96311394a876b4beb206e8e335184c2', class: "col-12" }, this.availablePaymentMethods.map((method) => this.renderPaymentMethodOption(method))), h("div", { key: 'da2a2009abe4348e25a5fc712557e81e9f6c4c1f', class: "col-12" }, h("justifi-button", { key: '050939c757999383226f281ee0eff1ec178be203', text: this.submitButtonText, variant: "primary", type: "submit", clickHandler: (e) => this.tokenizePaymentMethod(e), isLoading: this.isLoading, "data-testid": "submit-button", hidden: this.computedHideSubmitButton })))))));
|
|
1383
1419
|
}
|
|
1384
1420
|
get host() { return getElement(this); }
|
|
1385
1421
|
static get watchers() { return {
|