@justifi/webcomponents 6.15.0-rc.2 → 6.16.0-rc.1
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/{Analytics-COhunq0p.js → Analytics-jQsZxClw.js} +4 -4
- package/dist/cjs/{Api-Do6SaltY.js → Api-DqXlEWR1.js} +1 -1
- package/dist/cjs/{Business-oBifyXkW.js → Business-CNaz-VLa.js} +5 -1
- package/dist/cjs/{Plaid-D85oV9FN.js → Plaid-BcOAKDaU.js} +1 -1
- package/dist/cjs/additional-questions-form-step_15.cjs.entry.js +14 -14
- package/dist/cjs/additional-questions_4.cjs.entry.js +3 -3
- package/dist/cjs/additional-statement_8.cjs.entry.js +8 -8
- package/dist/cjs/bank-account-billing-form-simple_4.cjs.entry.js +15 -9
- package/dist/cjs/bank-account-document-form-inputs.cjs.entry.js +2 -2
- package/dist/cjs/bank-account-form.cjs.entry.js +68 -14
- package/dist/cjs/{business-form-options-CnlrfbQ6.js → business-form-options-BHBs_yiK.js} +1 -1
- package/dist/cjs/{business-identity-schema-hpDJFnB4.js → business-identity-schema-DuOIMFjG.js} +3 -3
- package/dist/cjs/{business.service-72YETCdB.js → business.service-Ca-olopC.js} +3 -3
- package/dist/cjs/card-form.cjs.entry.js +16 -12
- package/dist/cjs/{checkout-actions-BRQFQ6n-.js → checkout-actions-CQyGpVPe.js} +2 -2
- package/dist/cjs/{checkout.service-CPsXfx0Z.js → checkout.service-DBHPH2ji.js} +3 -3
- package/dist/cjs/{checkout.store-DaV9lvEQ.js → checkout.store-B5lTwvUV.js} +1 -0
- package/dist/cjs/{country-config-C1bWmF8P.js → country-config-CFC3KuVD.js} +25 -3
- package/dist/cjs/custom-popper_2.cjs.entry.js +2 -2
- package/dist/cjs/detect-duplicate-version-D8ZajVUT.js +29 -0
- package/dist/cjs/dispute-notification_2.cjs.entry.js +12 -12
- package/dist/cjs/{event-types-UHzCC7Ga.js → event-types-luy3xnYR.js} +3 -3
- package/dist/cjs/form-address-fields_3.cjs.entry.js +6 -6
- package/dist/cjs/form-alert_3.cjs.entry.js +116 -15
- package/dist/cjs/form-control-checkbox.cjs.entry.js +2 -2
- package/dist/cjs/form-control-date.cjs.entry.js +2 -2
- package/dist/cjs/form-control-file-v2_2.cjs.entry.js +1 -1
- package/dist/cjs/form-control-file.cjs.entry.js +2 -2
- package/dist/cjs/form-control-monetary.cjs.entry.js +2 -2
- package/dist/cjs/form-control-number_2.cjs.entry.js +6 -6
- package/dist/cjs/form-control-radio.cjs.entry.js +2 -2
- package/dist/cjs/form-control-select_2.cjs.entry.js +22 -6
- package/dist/cjs/{get-business-BpaRbn5S.js → get-business-BVxtiSDs.js} +3 -3
- package/dist/cjs/{get-payment-details-Cmg8gWvo.js → get-payment-details-DR1GgpyX.js} +3 -3
- package/dist/cjs/{get-subaccounts-Bp7DOmM_.js → get-subaccounts-D11aTYj1.js} +4 -4
- package/dist/cjs/{input-handlers-_51J5q7J.js → input-handlers-v9h_2Ysi.js} +1 -1
- package/dist/cjs/internal-button.cjs.entry.js +1 -1
- package/dist/cjs/justifi-apple-pay_12.cjs.entry.js +52 -30
- package/dist/cjs/justifi-bank-account-billing-form-simple.cjs.entry.js +8 -8
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +10 -9
- package/dist/cjs/justifi-billing-form-full.cjs.entry.js +1 -1
- package/dist/cjs/justifi-business-details.cjs.entry.js +11 -11
- package/dist/cjs/justifi-business-form.cjs.entry.js +14 -14
- package/dist/cjs/justifi-card-billing-form-simple.cjs.entry.js +1 -1
- package/dist/cjs/justifi-card-form.cjs.entry.js +11 -8
- package/dist/cjs/justifi-checkout-qr-code.cjs.entry.js +7 -7
- package/dist/cjs/justifi-checkout.cjs.entry.js +12 -10
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +6 -4
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +12 -12
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +10 -10
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +34 -21
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +12 -12
- package/dist/cjs/justifi-payment-details.cjs.entry.js +18 -18
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +2 -2
- package/dist/cjs/justifi-payments-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payout-details.cjs.entry.js +13 -13
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +12 -12
- package/dist/cjs/justifi-qr-terminal.cjs.entry.js +10 -10
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +10 -10
- package/dist/cjs/justifi-save-new-payment-method.cjs.entry.js +1 -1
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +9 -9
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +5 -5
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +3 -3
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +11 -11
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-G3Vs7Jx5.js → package-B414Jbra.js} +1 -3
- package/dist/cjs/payment-method-option.cjs.entry.js +1 -1
- package/dist/cjs/{payment-provisioning-actions-DDooZhhk.js → payment-provisioning-actions-SVp7B8pR.js} +2 -2
- package/dist/cjs/payment-provisioning-form-buttons_2.cjs.entry.js +1 -1
- package/dist/cjs/{payment.service-CVwTrHEL.js → payment.service-CNTe8vrp.js} +3 -3
- package/dist/cjs/{payout.service-CL3VR0hN.js → payout.service-BmU3q9jO.js} +3 -3
- package/dist/cjs/{payouts-status-1IUtW-UQ.js → payouts-status-BvHeuy9v.js} +2 -2
- package/dist/cjs/{plaid.service-Cukg5wuY.js → plaid.service-d9LAwbnX.js} +3 -3
- package/dist/cjs/radio-list-item.cjs.entry.js +1 -1
- package/dist/cjs/save-new-payment-method.cjs.entry.js +2 -2
- package/dist/cjs/{schema-validations-DehT309E.js → schema-validations-BDFa_oIq.js} +12 -5
- package/dist/cjs/table-filters-menu.cjs.entry.js +1 -1
- package/dist/cjs/terminal-quantity-selector.cjs.entry.js +1 -1
- package/dist/cjs/{terminal.service-C0KG7BqL.js → terminal.service-BkQWZv9b.js} +3 -3
- package/dist/cjs/{utils-CBriZzRC.js → utils-BScgWJC5.js} +1 -1
- package/dist/cjs/utils-Ct_X5q0U.js +62 -0
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/api/Business.js +2 -0
- package/dist/collection/api/Checkout.js +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/business-details/justifi-business-details.js +3 -3
- package/dist/collection/components/business-forms/business-form/justifi-business-form.js +2 -2
- package/dist/collection/components/business-forms/payment-provisioning/form-address-fields/form-address-fields.js +3 -2
- package/dist/collection/components/business-forms/payment-provisioning/justifi-payment-provisioning.js +2 -2
- package/dist/collection/components/business-forms/schemas/schema-helpers.js +2 -1
- package/dist/collection/components/business-forms/schemas/schema-validations.js +8 -1
- package/dist/collection/components/business-forms/utils/country-config.js +3 -2
- package/dist/collection/components/business-forms/utils/helpers.js +3 -1
- package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +90 -12
- package/dist/collection/components/checkout/billing-form/billing-form-full.js +6 -2
- package/dist/collection/components/checkout/billing-form/card-billing-form-simple.js +6 -2
- package/dist/collection/components/checkout/card-form/card-form.js +39 -11
- package/dist/collection/components/checkout/justifi-checkout.js +26 -4
- package/dist/collection/components/checkout/message-event-types.js +2 -0
- package/dist/collection/components/checkout/save-new-payment-method/justifi-save-new-payment-method.js +1 -1
- package/dist/collection/components/checkout/save-new-payment-method/save-new-payment-method.js +1 -1
- package/dist/collection/components/checkout-qr-code/justifi-checkout-qr-code.js +2 -2
- package/dist/collection/components/checkouts-list/checkouts-list-filters.js +4 -2
- package/dist/collection/components/checkouts-list/justifi-checkouts-list.js +5 -5
- package/dist/collection/components/dispute-management/dispute-notification.js +2 -2
- 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.js +3 -3
- 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/dispute-management/justifi-dispute-management.js +3 -3
- package/dist/collection/components/filters/table-filters-menu.js +1 -1
- package/dist/collection/components/gross-payment-chart/justifi-gross-payment-chart.js +2 -2
- package/dist/collection/components/insurance/season-interruption/justifi-season-interruption-insurance.js +2 -2
- package/dist/collection/components/modular-checkout/justifi-modular-checkout.js +50 -12
- package/dist/collection/components/modular-checkout/sub-components/justifi-apple-pay.js +7 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-bank-account-billing-form-simple.js +3 -3
- package/dist/collection/components/modular-checkout/sub-components/justifi-bank-account-form.js +33 -6
- package/dist/collection/components/modular-checkout/sub-components/justifi-billing-form-full.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-card-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-card-form.js +28 -3
- package/dist/collection/components/modular-checkout/sub-components/justifi-checkout-summary.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/payment-method-option.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/paypal/justifi-paypal.js +1 -1
- package/dist/collection/components/order-terminals/justifi-order-terminals.js +3 -3
- package/dist/collection/components/order-terminals/terminal-quantity-selector/terminal-quantity-selector.js +1 -1
- package/dist/collection/components/payment-details/justifi-payment-details.js +10 -10
- package/dist/collection/components/payment-transactions-list/justifi-payment-transactions-list.js +3 -3
- package/dist/collection/components/payments-list/justifi-payments-list-filters.js +2 -2
- package/dist/collection/components/payments-list/justifi-payments-list.js +3 -3
- package/dist/collection/components/payout-details/justifi-payout-details.js +5 -5
- package/dist/collection/components/payout-transactions-list/justifi-payout-transactions-list.js +3 -3
- package/dist/collection/components/payouts-list/justifi-payouts-list-filters.js +2 -2
- package/dist/collection/components/payouts-list/justifi-payouts-list.js +3 -3
- package/dist/collection/components/qr-terminal/justifi-qr-terminal.js +2 -2
- package/dist/collection/components/refund-payment/justifi-refund-payment.js +2 -2
- package/dist/collection/components/terminal-orders-list/justifi-terminal-orders-list-filters.js +3 -3
- package/dist/collection/components/terminal-orders-list/justifi-terminal-orders-list.js +4 -4
- package/dist/collection/components/terminals-list/justifi-terminals-list-filters.js +1 -1
- package/dist/collection/components/terminals-list/justifi-terminals-list.js +3 -3
- package/dist/collection/components/tokenize-payment-method/justifi-tokenize-payment-method.js +45 -6
- package/dist/collection/store/checkout.store.js +1 -0
- package/dist/collection/ui-components/custom-popper/custom-popper.js +2 -2
- 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 +2 -2
- package/dist/collection/ui-components/form/form-control-select.js +2 -2
- package/dist/collection/ui-components/form/form-control-text.js +37 -4
- package/dist/collection/ui-components/form/iframe-input.js +136 -14
- package/dist/collection/ui-components/form/utils.js +32 -0
- package/dist/collection/ui-components/internal-button.js +1 -1
- package/dist/collection/ui-components/radio-list-item.js +1 -1
- package/dist/collection/utils/detect-duplicate-version.js +24 -0
- package/dist/collection/utils/postal-code.js +19 -0
- package/dist/docs.json +287 -18
- package/dist/esm/{Analytics-3WmRTICF.js → Analytics-DihSSvAP.js} +4 -4
- package/dist/esm/{Api-83B3f28Q.js → Api-INJHjnya.js} +1 -1
- package/dist/esm/{Business-DaDqgDrb.js → Business-CTtGaVYs.js} +5 -1
- package/dist/esm/{Plaid-BP3xNxQF.js → Plaid-CRcTLeaz.js} +1 -1
- package/dist/esm/additional-questions-form-step_15.entry.js +14 -14
- package/dist/esm/additional-questions_4.entry.js +3 -3
- package/dist/esm/additional-statement_8.entry.js +8 -8
- package/dist/esm/bank-account-billing-form-simple_4.entry.js +15 -9
- package/dist/esm/bank-account-document-form-inputs.entry.js +2 -2
- package/dist/esm/bank-account-form.entry.js +68 -14
- package/dist/esm/{business-form-options-BxVQL9ar.js → business-form-options-DLRkVtee.js} +1 -1
- package/dist/esm/{business-identity-schema-BkmRlnQo.js → business-identity-schema-BLKCH6xV.js} +3 -3
- package/dist/esm/{business.service-CTqiKKy5.js → business.service-C8f7OSEu.js} +3 -3
- package/dist/esm/card-form.entry.js +16 -12
- package/dist/esm/{checkout-actions-0ftD0elo.js → checkout-actions-CWnrb317.js} +2 -2
- package/dist/esm/{checkout.service-wjFjBxIB.js → checkout.service-BYDkC7uy.js} +3 -3
- package/dist/esm/{checkout.store-B2mtQcB5.js → checkout.store-B8CGkx0o.js} +1 -0
- package/dist/esm/{country-config-CJwnhkdq.js → country-config-DJFj1v-Q.js} +24 -4
- package/dist/esm/custom-popper_2.entry.js +2 -2
- package/dist/esm/detect-duplicate-version-C4r1WAzO.js +27 -0
- package/dist/esm/dispute-notification_2.entry.js +12 -12
- package/dist/esm/{event-types-cqQHLwCy.js → event-types-S8CgMbPg.js} +3 -3
- package/dist/esm/form-address-fields_3.entry.js +6 -6
- package/dist/esm/form-alert_3.entry.js +116 -15
- package/dist/esm/form-control-checkbox.entry.js +2 -2
- package/dist/esm/form-control-date.entry.js +2 -2
- package/dist/esm/form-control-file-v2_2.entry.js +1 -1
- package/dist/esm/form-control-file.entry.js +2 -2
- package/dist/esm/form-control-monetary.entry.js +2 -2
- package/dist/esm/form-control-number_2.entry.js +6 -6
- package/dist/esm/form-control-radio.entry.js +2 -2
- package/dist/esm/form-control-select_2.entry.js +22 -6
- package/dist/esm/{get-business-BLCT-zfN.js → get-business-IZpxKRZM.js} +3 -3
- package/dist/esm/{get-payment-details-BokzuPGl.js → get-payment-details-DSI41Pq5.js} +3 -3
- package/dist/esm/{get-subaccounts-ClGG-LRZ.js → get-subaccounts-BHWiH8q9.js} +4 -4
- package/dist/esm/{input-handlers-Dfuc6aDW.js → input-handlers-Dm8jO-BT.js} +1 -1
- package/dist/esm/internal-button.entry.js +1 -1
- package/dist/esm/justifi-apple-pay_12.entry.js +52 -30
- package/dist/esm/justifi-bank-account-billing-form-simple.entry.js +8 -8
- package/dist/esm/justifi-bank-account-form.entry.js +10 -9
- package/dist/esm/justifi-billing-form-full.entry.js +1 -1
- package/dist/esm/justifi-business-details.entry.js +11 -11
- package/dist/esm/justifi-business-form.entry.js +14 -14
- package/dist/esm/justifi-card-billing-form-simple.entry.js +1 -1
- package/dist/esm/justifi-card-form.entry.js +11 -8
- package/dist/esm/justifi-checkout-qr-code.entry.js +7 -7
- package/dist/esm/justifi-checkout.entry.js +12 -10
- package/dist/esm/justifi-checkouts-list-filters.entry.js +6 -4
- package/dist/esm/justifi-checkouts-list.entry.js +12 -12
- package/dist/esm/justifi-dispute-management.entry.js +10 -10
- package/dist/esm/justifi-gross-payment-chart.entry.js +34 -21
- package/dist/esm/justifi-order-terminals.entry.js +12 -12
- package/dist/esm/justifi-payment-details.entry.js +18 -18
- package/dist/esm/justifi-payment-provisioning.entry.js +10 -10
- package/dist/esm/justifi-payment-transactions-list.entry.js +10 -10
- package/dist/esm/justifi-payments-list-filters.entry.js +2 -2
- package/dist/esm/justifi-payments-list.entry.js +10 -10
- package/dist/esm/justifi-payout-details.entry.js +13 -13
- package/dist/esm/justifi-payout-transactions-list.entry.js +10 -10
- package/dist/esm/justifi-payouts-list-filters.entry.js +4 -4
- package/dist/esm/justifi-payouts-list.entry.js +12 -12
- package/dist/esm/justifi-qr-terminal.entry.js +10 -10
- package/dist/esm/justifi-refund-payment.entry.js +10 -10
- package/dist/esm/justifi-save-new-payment-method.entry.js +1 -1
- package/dist/esm/justifi-season-interruption-insurance.entry.js +9 -9
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +5 -5
- package/dist/esm/justifi-terminal-orders-list.entry.js +10 -10
- package/dist/esm/justifi-terminals-list-filters.entry.js +3 -3
- package/dist/esm/justifi-terminals-list.entry.js +11 -11
- package/dist/esm/loader.js +1 -1
- package/dist/esm/package-BQpbTebi.js +5 -0
- package/dist/esm/payment-method-option.entry.js +1 -1
- package/dist/esm/{payment-provisioning-actions-VRIPjnAQ.js → payment-provisioning-actions-VtleD509.js} +2 -2
- package/dist/esm/payment-provisioning-form-buttons_2.entry.js +1 -1
- package/dist/esm/{payment.service-D7uv5vym.js → payment.service-CQXRsu6Y.js} +3 -3
- package/dist/esm/{payout.service-BoSyqft1.js → payout.service-RRyWfpEK.js} +3 -3
- package/dist/esm/{payouts-status-CaiC5qpn.js → payouts-status-CnIf4XDi.js} +2 -2
- package/dist/esm/{plaid.service-DufQkxDk.js → plaid.service-Cg3E3Plo.js} +3 -3
- package/dist/esm/radio-list-item.entry.js +1 -1
- package/dist/esm/save-new-payment-method.entry.js +2 -2
- package/dist/esm/{schema-validations-8dbMCACI.js → schema-validations-8GJ34Do1.js} +12 -5
- package/dist/esm/table-filters-menu.entry.js +1 -1
- package/dist/esm/terminal-quantity-selector.entry.js +1 -1
- package/dist/esm/{terminal.service-BM2aebB6.js → terminal.service-Dy6D8bnl.js} +3 -3
- package/dist/esm/utils-Cpck08K0.js +59 -0
- package/dist/esm/{utils-YUOJKtjO.js → utils-DaPywmTI.js} +1 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/module/Business.js +5 -1
- package/dist/module/Plaid.js +1 -1
- package/dist/module/additional-statement2.js +1 -1
- package/dist/module/bank-account-form2.js +65 -10
- package/dist/module/billing-form-full2.js +6 -2
- package/dist/module/cancellation-policy2.js +1 -1
- package/dist/module/card-billing-form-simple2.js +6 -2
- package/dist/module/card-form2.js +14 -9
- package/dist/module/checkout.store.js +1 -0
- package/dist/module/country-config.js +23 -3
- package/dist/module/custom-popper2.js +2 -2
- package/dist/module/customer-details2.js +1 -1
- package/dist/module/detect-duplicate-version.js +27 -0
- package/dist/module/dispute-notification2.js +2 -2
- package/dist/module/dispute-response2.js +3 -3
- package/dist/module/duplicate-charge2.js +1 -1
- package/dist/module/electronic-evidence2.js +1 -1
- package/dist/module/form-address-fields2.js +3 -3
- package/dist/module/form-control-checkbox2.js +2 -2
- package/dist/module/form-control-date2.js +2 -2
- package/dist/module/form-control-file-v22.js +1 -1
- package/dist/module/form-control-file2.js +2 -2
- package/dist/module/form-control-monetary2.js +2 -2
- package/dist/module/form-control-number-masked2.js +2 -2
- package/dist/module/form-control-number2.js +2 -2
- package/dist/module/form-control-radio2.js +2 -2
- package/dist/module/form-control-select2.js +2 -2
- package/dist/module/form-control-text2.js +21 -4
- package/dist/module/iframe-input2.js +119 -15
- package/dist/module/internal-button2.js +1 -1
- package/dist/module/justifi-apple-pay2.js +7 -1
- package/dist/module/justifi-bank-account-billing-form-simple.js +3 -3
- package/dist/module/justifi-bank-account-form.js +6 -4
- package/dist/module/justifi-billing-form-full.js +1 -1
- package/dist/module/justifi-business-details.js +3 -3
- package/dist/module/justifi-business-form.js +2 -2
- package/dist/module/justifi-card-billing-form-simple.js +1 -1
- package/dist/module/justifi-card-form.js +6 -3
- package/dist/module/justifi-checkout-qr-code2.js +2 -2
- package/dist/module/justifi-checkout-summary2.js +1 -1
- package/dist/module/justifi-checkout.js +7 -4
- package/dist/module/justifi-checkouts-list-filters.js +4 -2
- package/dist/module/justifi-checkouts-list.js +4 -4
- package/dist/module/justifi-dispute-management.js +3 -3
- package/dist/module/justifi-gross-payment-chart.js +28 -15
- package/dist/module/justifi-modular-checkout2.js +30 -12
- package/dist/module/justifi-order-terminals.js +3 -3
- package/dist/module/justifi-payment-details.js +10 -10
- package/dist/module/justifi-payment-provisioning.js +2 -2
- package/dist/module/justifi-payment-transactions-list.js +3 -3
- package/dist/module/justifi-payments-list-filters.js +2 -2
- package/dist/module/justifi-payments-list.js +3 -3
- package/dist/module/justifi-payout-details.js +5 -5
- package/dist/module/justifi-payout-transactions-list.js +3 -3
- package/dist/module/justifi-payouts-list-filters.js +2 -2
- package/dist/module/justifi-payouts-list.js +3 -3
- package/dist/module/justifi-paypal2.js +1 -1
- package/dist/module/justifi-qr-terminal.js +2 -2
- package/dist/module/justifi-refund-payment.js +2 -2
- package/dist/module/justifi-save-new-payment-method.js +1 -1
- package/dist/module/justifi-season-interruption-insurance.js +2 -2
- package/dist/module/justifi-terminal-orders-list-filters.js +3 -3
- package/dist/module/justifi-terminal-orders-list.js +4 -4
- package/dist/module/justifi-terminals-list-filters.js +1 -1
- package/dist/module/justifi-terminals-list.js +3 -3
- package/dist/module/justifi-tokenize-payment-method2.js +9 -6
- package/dist/module/package.js +1 -3
- package/dist/module/payment-method-option.js +1 -1
- package/dist/module/product-or-service2.js +1 -1
- package/dist/module/radio-list-item2.js +1 -1
- package/dist/module/refund-policy2.js +1 -1
- package/dist/module/save-new-payment-method2.js +1 -1
- package/dist/module/schema-validations.js +10 -3
- package/dist/module/shipping-details2.js +1 -1
- package/dist/module/table-filters-menu2.js +1 -1
- package/dist/module/terminal-quantity-selector2.js +1 -1
- package/dist/module/utils4.js +33 -1
- package/dist/types/api/Business.d.ts +2 -0
- package/dist/types/api/Checkout.d.ts +7 -7
- package/dist/types/components/checkout/bank-account-form/bank-account-form.d.ts +8 -1
- package/dist/types/components/checkout/card-form/card-form.d.ts +5 -1
- package/dist/types/components/checkout/justifi-checkout.d.ts +2 -0
- package/dist/types/components/checkout/message-event-types.d.ts +2 -0
- package/dist/types/components/checkouts-list/justifi-checkouts-list.d.ts +1 -1
- package/dist/types/components/modular-checkout/justifi-modular-checkout.d.ts +9 -0
- package/dist/types/components/modular-checkout/sub-components/justifi-apple-pay.d.ts +1 -0
- package/dist/types/components/modular-checkout/sub-components/justifi-bank-account-form.d.ts +4 -1
- package/dist/types/components/modular-checkout/sub-components/justifi-card-form.d.ts +9 -0
- package/dist/types/components/tokenize-payment-method/justifi-tokenize-payment-method.d.ts +9 -0
- package/dist/types/components.d.ts +86 -4
- package/dist/types/store/checkout.store.d.ts +1 -0
- package/dist/types/ui-components/form/form-control-text.d.ts +1 -0
- package/dist/types/ui-components/form/iframe-input.d.ts +24 -0
- package/dist/types/ui-components/form/utils.d.ts +1 -0
- package/dist/types/utils/detect-duplicate-version.d.ts +7 -0
- package/dist/types/utils/postal-code.d.ts +3 -0
- package/dist/webcomponents/p-12daf522.entry.js +1 -0
- package/dist/webcomponents/p-1a1aef42.entry.js +1 -0
- package/dist/webcomponents/p-1ceb65cc.entry.js +1 -0
- package/dist/webcomponents/p-1ff1dcc5.entry.js +20 -0
- package/dist/webcomponents/{p-777470cb.entry.js → p-2272a65b.entry.js} +1 -1
- package/dist/webcomponents/{p-c4889a06.entry.js → p-2d25f1d1.entry.js} +1 -1
- package/dist/webcomponents/{p-c5424fda.entry.js → p-30ec1cd6.entry.js} +1 -1
- package/dist/webcomponents/p-357d14ee.entry.js +1 -0
- package/dist/webcomponents/{p-ead48010.entry.js → p-4450dbe9.entry.js} +1 -1
- package/dist/webcomponents/p-4c7e7880.entry.js +1 -0
- package/dist/webcomponents/p-4d85dd63.entry.js +1 -0
- package/dist/webcomponents/p-521c534c.entry.js +1 -0
- package/dist/webcomponents/p-5babaaa9.entry.js +1 -0
- package/dist/webcomponents/{p-1cdbe8c1.entry.js → p-5c889829.entry.js} +1 -1
- package/dist/webcomponents/{p-f5358a80.entry.js → p-5e8f26ec.entry.js} +1 -1
- package/dist/webcomponents/p-622c2af4.entry.js +1 -0
- package/dist/webcomponents/{p-9e3e2e32.entry.js → p-6aaf2758.entry.js} +1 -1
- package/dist/webcomponents/p-6bfdc443.entry.js +1 -0
- package/dist/webcomponents/{p-42021e67.entry.js → p-6f3b035b.entry.js} +1 -1
- package/dist/webcomponents/p-73af269e.entry.js +1 -0
- package/dist/webcomponents/{p-ced6f6f1.entry.js → p-7ff788f8.entry.js} +1 -1
- package/dist/webcomponents/{p-c3818a5a.entry.js → p-846ae5d5.entry.js} +1 -1
- package/dist/webcomponents/p-8758aec4.entry.js +1 -0
- package/dist/webcomponents/p-87f8d4e7.entry.js +1 -0
- package/dist/webcomponents/p-8c22ff9c.entry.js +1 -0
- package/dist/webcomponents/p-91358854.entry.js +1 -0
- package/dist/webcomponents/{p-f3682c72.entry.js → p-956707a2.entry.js} +1 -1
- package/dist/webcomponents/p-9c1863d5.entry.js +1 -0
- package/dist/webcomponents/p-BDtSw_d-.js +1 -0
- package/dist/webcomponents/{p-CIpBEUtx.js → p-BG8NxEUn.js} +1 -1
- package/dist/webcomponents/p-BKtKrQzN.js +1 -0
- package/dist/webcomponents/p-BQpbTebi.js +1 -0
- package/dist/webcomponents/{p-nbKvRcwU.js → p-Bh5BNj74.js} +1 -1
- package/dist/webcomponents/{p-CLq3Og7o.js → p-BhpaUYtS.js} +1 -1
- package/dist/webcomponents/{p-vIQBTQmc.js → p-BtiJJJwv.js} +1 -1
- package/dist/webcomponents/{p-DZQBPUfH.js → p-Bxc0NRj8.js} +1 -1
- package/dist/webcomponents/p-BzESNgd8.js +1 -0
- package/dist/webcomponents/p-C9p1gWAC.js +1 -0
- package/dist/webcomponents/p-CTtGaVYs.js +1 -0
- package/dist/webcomponents/p-CgOgijHy.js +1 -0
- package/dist/webcomponents/p-CkrzG0pB.js +1 -0
- package/dist/webcomponents/p-Cl6irPVE.js +1 -0
- package/dist/webcomponents/p-Cpck08K0.js +1 -0
- package/dist/webcomponents/{p-OReJ-ZQb.js → p-CtlBL-X6.js} +1 -1
- package/dist/webcomponents/p-Cy_sz0Tx.js +1 -0
- package/dist/webcomponents/p-D42DvqTW.js +1 -0
- package/dist/webcomponents/p-D7nyPi2Q.js +1 -0
- package/dist/webcomponents/p-DBudSN_h.js +1 -0
- package/dist/webcomponents/p-DMzYgqml.js +1 -0
- package/dist/webcomponents/{p-B0DHIvEj.js → p-DQmijfCN.js} +1 -1
- package/dist/webcomponents/p-Dqxyi-uK.js +1 -0
- package/dist/webcomponents/p-FsWkrvEF.js +1 -0
- package/dist/webcomponents/p-MLQyjvrV.js +1 -0
- package/dist/webcomponents/p-a095b86d.entry.js +1 -0
- package/dist/webcomponents/p-a1e1afa4.entry.js +1 -0
- package/dist/webcomponents/p-a2c4e99f.entry.js +1 -0
- package/dist/webcomponents/p-a8f1c9b3.entry.js +1 -0
- package/dist/webcomponents/{p-5d7b3d71.entry.js → p-b665841f.entry.js} +1 -1
- package/dist/webcomponents/p-b925d666.entry.js +1 -0
- package/dist/webcomponents/p-bc3e46af.entry.js +1 -0
- package/dist/webcomponents/p-c172decb.entry.js +1 -0
- package/dist/webcomponents/p-c9871158.entry.js +1 -0
- package/dist/webcomponents/p-d19d7d41.entry.js +1 -0
- package/dist/webcomponents/{p-6c94218c.entry.js → p-d35cde99.entry.js} +1 -1
- package/dist/webcomponents/{p-cb1cc88e.entry.js → p-d48f80d1.entry.js} +1 -1
- package/dist/webcomponents/{p-eb31024f.entry.js → p-dae31a59.entry.js} +1 -1
- package/dist/webcomponents/p-deff4422.entry.js +1 -0
- package/dist/webcomponents/{p-1365a46b.entry.js → p-e3c7b4e5.entry.js} +1 -1
- package/dist/webcomponents/{p-d98bc829.entry.js → p-e6d1e3e2.entry.js} +1 -1
- package/dist/webcomponents/{p-97c6593d.entry.js → p-ebae270b.entry.js} +1 -1
- package/dist/webcomponents/p-ebed68aa.entry.js +1 -0
- package/dist/webcomponents/{p-bf3866b3.entry.js → p-f0084d20.entry.js} +1 -1
- package/dist/webcomponents/p-f0da2ca5.entry.js +1 -0
- package/dist/webcomponents/p-f23d7d13.entry.js +1 -0
- package/dist/webcomponents/p-f2c99647.entry.js +1 -0
- package/dist/webcomponents/{p-e55216fb.entry.js → p-f39889f2.entry.js} +1 -1
- package/dist/webcomponents/p-f458928d.entry.js +1 -0
- package/dist/webcomponents/{p-0aa96018.entry.js → p-f5686720.entry.js} +1 -1
- package/dist/webcomponents/p-f681f747.entry.js +1 -0
- package/dist/webcomponents/{p-6eb65d23.entry.js → p-f6efd9e0.entry.js} +1 -1
- package/dist/webcomponents/{p-7002286e.entry.js → p-fa0427d5.entry.js} +1 -1
- package/dist/webcomponents/p-fb1f2fe8.entry.js +1 -0
- package/dist/webcomponents/p-fcc5af24.entry.js +1 -0
- package/dist/webcomponents/p-hdPjEOdB.js +1 -0
- package/dist/webcomponents/{p-CJEetAx7.js → p-l3JhjHLW.js} +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +2 -4
- package/dist/cjs/check-pkg-version-BxGoSXGD.js +0 -47
- package/dist/cjs/utils-DAyWinG2.js +0 -29
- package/dist/collection/utils/check-pkg-version.js +0 -42
- package/dist/esm/check-pkg-version-CmFl6VLH.js +0 -45
- package/dist/esm/package-CAVi_ne1.js +0 -7
- package/dist/esm/utils-BnjCmwMr.js +0 -27
- package/dist/module/check-pkg-version.js +0 -45
- package/dist/types/utils/check-pkg-version.d.ts +0 -1
- package/dist/webcomponents/p-0fbc806f.entry.js +0 -1
- package/dist/webcomponents/p-10787684.entry.js +0 -1
- package/dist/webcomponents/p-1fa62eba.entry.js +0 -1
- package/dist/webcomponents/p-25f70d5f.entry.js +0 -1
- package/dist/webcomponents/p-27igUlku.js +0 -1
- package/dist/webcomponents/p-36340e63.entry.js +0 -1
- package/dist/webcomponents/p-3642e189.entry.js +0 -1
- package/dist/webcomponents/p-388082cd.entry.js +0 -1
- package/dist/webcomponents/p-3f2fb856.entry.js +0 -1
- package/dist/webcomponents/p-4cad48c1.entry.js +0 -1
- package/dist/webcomponents/p-50c2b8f0.entry.js +0 -1
- package/dist/webcomponents/p-5842d4e8.entry.js +0 -1
- package/dist/webcomponents/p-5c89dcdf.entry.js +0 -1
- package/dist/webcomponents/p-5dcb1713.entry.js +0 -1
- package/dist/webcomponents/p-5f8c30b6.entry.js +0 -1
- package/dist/webcomponents/p-68e88747.entry.js +0 -1
- package/dist/webcomponents/p-6931a1f2.entry.js +0 -1
- package/dist/webcomponents/p-72bb4aff.entry.js +0 -1
- package/dist/webcomponents/p-74575a99.entry.js +0 -1
- package/dist/webcomponents/p-7c405573.entry.js +0 -1
- package/dist/webcomponents/p-825a7ee6.entry.js +0 -1
- package/dist/webcomponents/p-909a9828.entry.js +0 -20
- package/dist/webcomponents/p-955c06d3.entry.js +0 -1
- package/dist/webcomponents/p-9e9a2546.entry.js +0 -1
- package/dist/webcomponents/p-9f0ef3f3.entry.js +0 -1
- package/dist/webcomponents/p-BAKuMxC9.js +0 -1
- package/dist/webcomponents/p-BEL8sLz6.js +0 -1
- package/dist/webcomponents/p-BSxXlu9H.js +0 -1
- package/dist/webcomponents/p-BnjCmwMr.js +0 -1
- package/dist/webcomponents/p-CAVi_ne1.js +0 -1
- package/dist/webcomponents/p-CXsRwohv.js +0 -1
- package/dist/webcomponents/p-CawcnSoV.js +0 -1
- package/dist/webcomponents/p-CbyGKcz_.js +0 -1
- package/dist/webcomponents/p-Cy2N3vAg.js +0 -1
- package/dist/webcomponents/p-CyOXIqHo.js +0 -1
- package/dist/webcomponents/p-D6uhYbLo.js +0 -1
- package/dist/webcomponents/p-DN7VhlTn.js +0 -1
- package/dist/webcomponents/p-DNuxxP2B.js +0 -1
- package/dist/webcomponents/p-D_84NsmN.js +0 -1
- package/dist/webcomponents/p-DaDqgDrb.js +0 -1
- package/dist/webcomponents/p-Do9dxNjh.js +0 -1
- package/dist/webcomponents/p-Fpaf7CLD.js +0 -1
- package/dist/webcomponents/p-PdwJswAy.js +0 -1
- package/dist/webcomponents/p-acb0b66c.entry.js +0 -1
- package/dist/webcomponents/p-b23dfa13.entry.js +0 -1
- package/dist/webcomponents/p-b98ea26a.entry.js +0 -1
- package/dist/webcomponents/p-ca13117d.entry.js +0 -1
- package/dist/webcomponents/p-ca6c5365.entry.js +0 -1
- package/dist/webcomponents/p-d59676ea.entry.js +0 -1
- package/dist/webcomponents/p-ee7fe3a8.entry.js +0 -1
- package/dist/webcomponents/p-f0434a13.entry.js +0 -1
- package/dist/webcomponents/p-f9f0cb1f.entry.js +0 -1
- package/dist/webcomponents/p-fda6f27d.entry.js +0 -1
- package/dist/webcomponents/p-fdd087d4.entry.js +0 -1
|
@@ -4,16 +4,16 @@ var index = require('./index-p7cvUYAE.js');
|
|
|
4
4
|
var skeleton = require('./skeleton-DvRCiQlA.js');
|
|
5
5
|
var configState = require('./config-state-C1YMiFpR.js');
|
|
6
6
|
var utils = require('./utils-DB4XHlAU.js');
|
|
7
|
-
var
|
|
8
|
-
var Plaid = require('./Plaid-
|
|
7
|
+
var detectDuplicateVersion = require('./detect-duplicate-version-D8ZajVUT.js');
|
|
8
|
+
var Plaid = require('./Plaid-BcOAKDaU.js');
|
|
9
9
|
require('./Pagination-Dediz133.js');
|
|
10
|
-
require('./Business-
|
|
10
|
+
require('./Business-CNaz-VLa.js');
|
|
11
11
|
var button = require('./button-CR9Rl1-o.js');
|
|
12
12
|
require('./event-types-YOY5TKUN.js');
|
|
13
13
|
require('./parts-BXshb_S-.js');
|
|
14
14
|
require('./index-DDrfAj-j.js');
|
|
15
15
|
require('./dinero-BwNN_k7x.js');
|
|
16
|
-
require('./package-
|
|
16
|
+
require('./package-B414Jbra.js');
|
|
17
17
|
|
|
18
18
|
const CardFormSkeleton = () => {
|
|
19
19
|
return (index.h("div", { class: "container-fluid p-0" }, index.h("div", { class: "mb-3" }, index.h(skeleton.Skeleton, { height: "18px", width: "100px" }), index.h(skeleton.Skeleton, { height: "36px" })), index.h("div", { class: "row" }, index.h("div", { class: "col-4 align-content-end" }, index.h(skeleton.Skeleton, { height: "18px", width: "80px" }), index.h(skeleton.Skeleton, { height: "36px" })), index.h("div", { class: "col-4 align-content-end" }, index.h(skeleton.Skeleton, { height: "36px" })), index.h("div", { class: "col-4 align-content-end" }, index.h(skeleton.Skeleton, { height: "18px", width: "30px" }), index.h(skeleton.Skeleton, { height: "36px" })))));
|
|
@@ -24,6 +24,8 @@ const CardForm = class {
|
|
|
24
24
|
index.registerInstance(this, hostRef);
|
|
25
25
|
this.errorEvent = index.createEvent(this, "error-event", 7);
|
|
26
26
|
this.iframeState = 'loading';
|
|
27
|
+
/** Mask the card number to its last four digits when the field blurs. */
|
|
28
|
+
this.maskCardNumber = false;
|
|
27
29
|
this.reloadIframes = () => {
|
|
28
30
|
this.iframeState = 'loading';
|
|
29
31
|
this.iframeElements.forEach((element) => element.reload());
|
|
@@ -34,7 +36,7 @@ const CardForm = class {
|
|
|
34
36
|
await configState.waitForConfig();
|
|
35
37
|
this.iframeOrigin = configState.configState.iframeOrigin;
|
|
36
38
|
this.tabId = utils.generateTabId();
|
|
37
|
-
|
|
39
|
+
detectDuplicateVersion.detectDuplicateVersion();
|
|
38
40
|
}
|
|
39
41
|
componentDidLoad() {
|
|
40
42
|
this.watchIframesLoad();
|
|
@@ -44,11 +46,13 @@ const CardForm = class {
|
|
|
44
46
|
(_a = this.loadAbortController) === null || _a === void 0 ? void 0 : _a.abort();
|
|
45
47
|
}
|
|
46
48
|
async validate() {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
const
|
|
50
|
-
const
|
|
51
|
-
|
|
49
|
+
// Sequential on purpose: the parent correlates iframe replies by eventType
|
|
50
|
+
// alone, with no request id, so concurrent validates would cross replies.
|
|
51
|
+
const results = [];
|
|
52
|
+
for (const element of this.iframeElements) {
|
|
53
|
+
results.push(await element.validate());
|
|
54
|
+
}
|
|
55
|
+
return { isValid: results.every((result) => (result === null || result === void 0 ? void 0 : result.isValid) === true) };
|
|
52
56
|
}
|
|
53
57
|
async tokenize({ clientId, paymentMethodMetadata, account, }) {
|
|
54
58
|
const result = await this.cardNumberIframeElement.tokenize(clientId, paymentMethodMetadata, account);
|
|
@@ -109,10 +113,10 @@ const CardForm = class {
|
|
|
109
113
|
return (index.h("div", null, index.h("form-alert", { text: Plaid.ComponentErrorMessages.IFRAME_LOAD_ERROR, hideAlert: false }), index.h(button.Button, { variant: "link", clickHandler: this.reloadIframes, "aria-label": "Reload payment form", type: "button" }, "Try again")));
|
|
110
114
|
}
|
|
111
115
|
render() {
|
|
112
|
-
return (index.h("div", { key: '
|
|
116
|
+
return (index.h("div", { key: '6f1adaa489228ab15ee8803f5e8d94b4f38df172' }, this.iframeState === 'loading' && index.h(CardFormSkeleton, { key: '01f38bf843e382d8fb34e59011a603e3a0955847' }), this.iframeState === 'error' && this.renderIframeError(), index.h("hidden-input", { key: 'd4fe8201e7df2ffd00cf76314da60dfa375d0c92' }), index.h("div", { key: 'be021b08ea0cb9bbd4e4dbb9258fb1e4cf0715b7', class: "container-fluid p-0", style: {
|
|
113
117
|
opacity: this.isReady ? '1' : '0',
|
|
114
118
|
height: this.isReady ? 'auto' : '0',
|
|
115
|
-
} }, index.h("div", { key: '
|
|
119
|
+
} }, index.h("div", { key: '5771c79e70cc49c15d170d0f3f820e4d04ab203a', class: "mb-3" }, index.h("iframe-input", { key: 'f24efbd4677be8bd07c9cf3cd0bf77df7b98993e', inputId: "cardNumber", ref: (el) => (this.cardNumberIframeElement = el), label: "Card Number", maskCardNumber: this.maskCardNumber, iframeOrigin: `${this.iframeOrigin}/v2/cardNumber?tabId=${this.tabId}` })), index.h("div", { key: '1d5923d02dbd23551cab1f8bb5d4ef3b5534f152', class: "row" }, index.h("div", { key: '1db376daa12621f2f17113a96ab693bfaae2fc38', class: "col-4 align-content-end" }, index.h("iframe-input", { key: '5cb8c4796ea7f609fecd0919709f70c52ae9c55c', inputId: "expirationMonth", ref: (el) => (this.expirationMonthIframeElement = el), label: "Expiration", iframeOrigin: `${this.iframeOrigin}/v2/expirationMonth?tabId=${this.tabId}` })), index.h("div", { key: '0cc0c04b35174c56097f687d2f843f874ed7fee0', class: "col-4 align-content-end" }, index.h("iframe-input", { key: '79cb809ad28c53c276903ddc5ece50b07fabfd56', inputId: "expirationYear", ref: (el) => (this.expirationYearIframeElement = el), label: "", iframeOrigin: `${this.iframeOrigin}/v2/expirationYear?tabId=${this.tabId}` })), index.h("div", { key: 'e04d26f47245b1f4977e57e456b12f630b8c63cd', class: "col-4 align-content-end" }, index.h("iframe-input", { key: '6e5e2dabbf28725e7e2499455bff1b34f6aefcf9', inputId: "CVV", ref: (el) => (this.cvvIframeElement = el), label: "CVV", iframeOrigin: `${this.iframeOrigin}/v2/CVV?tabId=${this.tabId}` }))))));
|
|
116
120
|
}
|
|
117
121
|
};
|
|
118
122
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Plaid = require('./Plaid-
|
|
4
|
-
var utils = require('./utils-
|
|
3
|
+
var Plaid = require('./Plaid-BcOAKDaU.js');
|
|
4
|
+
var utils = require('./utils-BScgWJC5.js');
|
|
5
5
|
|
|
6
6
|
const makeGetCheckout = ({ authToken, checkoutId, service }) => async ({ onSuccess, onError }) => {
|
|
7
7
|
var _a;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Api = require('./Api-
|
|
4
|
-
require('./Plaid-
|
|
3
|
+
var Api = require('./Api-DqXlEWR1.js');
|
|
4
|
+
require('./Plaid-BcOAKDaU.js');
|
|
5
5
|
require('./Pagination-Dediz133.js');
|
|
6
|
-
require('./Business-
|
|
6
|
+
require('./Business-CNaz-VLa.js');
|
|
7
7
|
|
|
8
8
|
const api = Api.Api();
|
|
9
9
|
class CheckoutService {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Business = require('./Business-
|
|
3
|
+
var Business = require('./Business-CNaz-VLa.js');
|
|
4
4
|
|
|
5
5
|
const ProvinceOptions = [
|
|
6
6
|
{
|
|
@@ -22,6 +22,26 @@ const ProvinceOptions = [
|
|
|
22
22
|
{ label: 'Yukon', value: 'YT' },
|
|
23
23
|
];
|
|
24
24
|
|
|
25
|
+
// Canada Post addressing guidelines: a postal code is six characters in the form
|
|
26
|
+
// "ANA NAN", with a single space between the Forward Sortation Area and the Local
|
|
27
|
+
// Delivery Unit. The first character of the FSA identifies one of 18 geographic
|
|
28
|
+
// areas, so D, F, I, O, Q, U, W and Z never appear there.
|
|
29
|
+
// https://www.canadapost-postescanada.ca/cpc/en/support/articles/addressing-guidelines/postal-codes.page
|
|
30
|
+
const US_ZIP_REGEX = /^\d{5}(-\d{4})?$/;
|
|
31
|
+
const CA_OR_US_POSTAL_REGEX = /^([ABCEGHJKLMNPRSTVXY]\d[A-Z] \d[A-Z]\d|\d{5}(-\d{4})?)$/i;
|
|
32
|
+
// Opening alpha-numeric-alpha is what distinguishes a Canadian code from a US ZIP.
|
|
33
|
+
const CA_SHAPE = /^[A-Z]\d[A-Z]/;
|
|
34
|
+
const normalizePostalCode = (value) => {
|
|
35
|
+
if (!value)
|
|
36
|
+
return value;
|
|
37
|
+
const upper = value.toUpperCase();
|
|
38
|
+
// A US ZIP (or a typo) keeps its characters — only the case is normalized.
|
|
39
|
+
if (!CA_SHAPE.test(upper))
|
|
40
|
+
return upper;
|
|
41
|
+
const compact = upper.replace(/[\s-]/g, '');
|
|
42
|
+
return compact.length > 3 ? `${compact.slice(0, 3)} ${compact.slice(3)}` : compact;
|
|
43
|
+
};
|
|
44
|
+
|
|
25
45
|
const countryLabels = {
|
|
26
46
|
USA: {
|
|
27
47
|
stateLabel: 'State',
|
|
@@ -59,18 +79,20 @@ const countryOptions = {
|
|
|
59
79
|
};
|
|
60
80
|
const countryValidation = {
|
|
61
81
|
USA: {
|
|
62
|
-
postalRegex:
|
|
82
|
+
postalRegex: US_ZIP_REGEX,
|
|
63
83
|
identityDigits: 9,
|
|
64
84
|
taxIdDigits: 9,
|
|
65
85
|
},
|
|
66
86
|
CAN: {
|
|
67
|
-
postalRegex:
|
|
87
|
+
postalRegex: CA_OR_US_POSTAL_REGEX,
|
|
68
88
|
identityDigits: 9,
|
|
69
89
|
taxIdDigits: 9,
|
|
70
90
|
},
|
|
71
91
|
};
|
|
72
92
|
|
|
93
|
+
exports.CA_OR_US_POSTAL_REGEX = CA_OR_US_POSTAL_REGEX;
|
|
73
94
|
exports.ProvinceOptions = ProvinceOptions;
|
|
74
95
|
exports.countryLabels = countryLabels;
|
|
75
96
|
exports.countryOptions = countryOptions;
|
|
76
97
|
exports.countryValidation = countryValidation;
|
|
98
|
+
exports.normalizePostalCode = normalizePostalCode;
|
|
@@ -1903,7 +1903,7 @@ const CustomPopper = class {
|
|
|
1903
1903
|
this.hideEvent.emit();
|
|
1904
1904
|
}
|
|
1905
1905
|
render() {
|
|
1906
|
-
return (index.h("div", { key: '
|
|
1906
|
+
return (index.h("div", { key: '1af0c9c11ffd5c3d0b7a1505e1730e68a8a52c88' }, index.h("style", { key: '6d16cbe171506d3ed398bbf051da1e1023648f7f' }, `
|
|
1907
1907
|
.popper-content {
|
|
1908
1908
|
display: none;
|
|
1909
1909
|
}
|
|
@@ -1911,7 +1911,7 @@ const CustomPopper = class {
|
|
|
1911
1911
|
display: block;
|
|
1912
1912
|
z-index: 1030;
|
|
1913
1913
|
}
|
|
1914
|
-
`), index.h("div", { key: '
|
|
1914
|
+
`), index.h("div", { key: 'fb4e6914fe3ef58e986baa320887b2b5c77b1e6b', class: "popper-content", ref: (el) => this.popperContentRef = el }, index.h("slot", { key: 'a4e4db117f4cae28e84e7b9cd7f810a8d27e50ad' }))));
|
|
1915
1915
|
}
|
|
1916
1916
|
static get watchers() { return {
|
|
1917
1917
|
"anchorRef": ["onAnchorRefChange"]
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var _package = require('./package-B414Jbra.js');
|
|
4
|
+
|
|
5
|
+
const JUSTIFI_VERSION_KEY = '__JUSTIFI_WC_VERSION__';
|
|
6
|
+
/**
|
|
7
|
+
* Records this bundle's version on globalThis and logs an error when a second,
|
|
8
|
+
* different version of @justifi/webcomponents is already on the page. The first
|
|
9
|
+
* version loaded wins — it has registered the custom elements, so any later
|
|
10
|
+
* bundle is inert.
|
|
11
|
+
*/
|
|
12
|
+
const detectDuplicateVersion = () => {
|
|
13
|
+
if (typeof globalThis === 'undefined')
|
|
14
|
+
return;
|
|
15
|
+
const globalScope = globalThis;
|
|
16
|
+
const currentVersion = _package.packageJson.version;
|
|
17
|
+
const existingVersion = globalScope[JUSTIFI_VERSION_KEY];
|
|
18
|
+
if (existingVersion && existingVersion !== currentVersion) {
|
|
19
|
+
console.error(`@justifi/webcomponents: Multiple versions detected. ` +
|
|
20
|
+
`Version ${existingVersion} was loaded first and registered all components. ` +
|
|
21
|
+
`Version ${currentVersion} is also present but its components will NOT be used. ` +
|
|
22
|
+
`To fix this, add to your package.json:\n` +
|
|
23
|
+
`"pnpm": { "overrides": { "@justifi/webcomponents": "${currentVersion}" } }`);
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
globalScope[JUSTIFI_VERSION_KEY] = currentVersion;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
exports.detectDuplicateVersion = detectDuplicateVersion;
|
|
@@ -6,18 +6,18 @@ var parts = require('./parts-BXshb_S-.js');
|
|
|
6
6
|
var button = require('./button-CR9Rl1-o.js');
|
|
7
7
|
var skeleton = require('./skeleton-DvRCiQlA.js');
|
|
8
8
|
require('./event-types-YOY5TKUN.js');
|
|
9
|
-
var Plaid = require('./Plaid-
|
|
10
|
-
var utils = require('./utils-
|
|
11
|
-
var eventTypes = require('./event-types-
|
|
12
|
-
var
|
|
13
|
-
var Analytics = require('./Analytics-
|
|
9
|
+
var Plaid = require('./Plaid-BcOAKDaU.js');
|
|
10
|
+
var utils = require('./utils-BScgWJC5.js');
|
|
11
|
+
var eventTypes = require('./event-types-luy3xnYR.js');
|
|
12
|
+
var detectDuplicateVersion = require('./detect-duplicate-version-D8ZajVUT.js');
|
|
13
|
+
var Analytics = require('./Analytics-jQsZxClw.js');
|
|
14
14
|
require('./dinero-BwNN_k7x.js');
|
|
15
|
-
require('./Api-
|
|
15
|
+
require('./Api-DqXlEWR1.js');
|
|
16
16
|
require('./config-state-C1YMiFpR.js');
|
|
17
17
|
require('./index-DDrfAj-j.js');
|
|
18
|
-
require('./package-
|
|
18
|
+
require('./package-B414Jbra.js');
|
|
19
19
|
require('./Pagination-Dediz133.js');
|
|
20
|
-
require('./Business-
|
|
20
|
+
require('./Business-CNaz-VLa.js');
|
|
21
21
|
|
|
22
22
|
const makeUpdateDisputeResponse = ({ authToken, disputeId, service }) => async ({ payload, onSuccess, onError, final = () => { } }) => {
|
|
23
23
|
var _a;
|
|
@@ -152,8 +152,8 @@ const DisputeNotification = class {
|
|
|
152
152
|
}
|
|
153
153
|
render() {
|
|
154
154
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
155
|
-
return (index.h("div", { key: '
|
|
156
|
-
_b.due_date, ") for this dispute has passed"), index.h("p", { key: '
|
|
155
|
+
return (index.h("div", { key: '12cd6c17c1f4f70e136fa0e9d6ff74d37af82a1e', class: "dispute-notification-root" }, this.isLoading && (index.h("div", { key: '33b1c6259abe1da5d92ac2aa37cfec9033fbb3d1', style: { marginBottom: '8px' } }, index.h(skeleton.Skeleton, { key: '1f5bc2333a37587d3d11e545b58c9b85a2a145a5', height: '28px', width: '70%', styles: { marginBottom: '16px' } }), index.h(skeleton.Skeleton, { key: '280e35a187319c7698922c3cd3f579457a187e7a', height: '18px', styles: { marginBottom: '8px' } }), index.h(skeleton.Skeleton, { key: '3fd7f151a3d7516dd40835d6c42d2240d7170613', height: '18px', styles: { marginBottom: '8px' } }))), ((_a = this.dispute) === null || _a === void 0 ? void 0 : _a.needsResponse) && this.isDueDatePassed() && (index.h("div", { key: 'e78d3cf205ba862b8df5e5358e15c4961add1003', part: parts.text }, index.h("h1", { key: 'c533f650a18a75ca7c9f1cb15a6d1da517317e54', class: "h4", part: parts.heading4 }, "The due date (", (_b = this.dispute) === null || _b === void 0 ? void 0 :
|
|
156
|
+
_b.due_date, ") for this dispute has passed"), index.h("p", { key: '14f82547639777ab5179010f350d42f7b4082845' }, "You can no longer submit evidence to counter this dispute."))), ((_c = this.dispute) === null || _c === void 0 ? void 0 : _c.needsResponse) && !this.isDueDatePassed() && (index.h("div", { key: 'a2eefdc255af0c3b07091183fff4c5860f66af3a', part: parts.text }, index.h("h1", { key: '043801fa6ac2f90ba10e6048feeecf670cc4e4dd', class: "h4", part: parts.heading4 }, "This payment is disputed"), index.h("p", { key: 'b4b115c46340ae96e43a63a1535b59f071efc7cc' }, "The cardholder is disputing this payment. You may accept this dispute, or proceed to provide evidence in a counter dispute."), index.h("h2", { key: '451b315624efea9b5f1e619ae6b942611ba93135', class: "h5" }, "Dispute details"), index.h("div", { key: 'c7765f5f091a346de0eb7aa81c36d475832925d2', class: "d-table gap-2" }, index.h("div", { key: 'cb3ecb618099b579a488232d5ecafef28c7da235', class: "d-table-row gap-2" }, index.h("span", { key: '86475be18418565529a2d08a544962209f9766ac', part: "detail-section-item-title", class: "fw-bold d-table-cell pe-4" }, "Amount"), index.h("span", { key: '5efe0ffd6f0236b906ab9e52f32bd9a0533240a2', part: "detail-section-item-data", class: "flex-1 d-table-cell text-wrap" }, utils$1.formatCurrency((_d = this.dispute) === null || _d === void 0 ? void 0 : _d.amount))), index.h("div", { key: '286b29d07ddb23ba80d4831aadebb4f550545c39', class: "d-table-row gap-2" }, index.h("span", { key: '2a8582b5e4c6e0b4ad1db9b7222148949accf10d', part: "detail-section-item-title", class: "fw-bold d-table-cell pe-4" }, "Reason"), index.h("span", { key: 'b8e43894965778696e0cb41204b3efe1aac9443e', part: "detail-section-item-data", class: "flex-1 d-table-cell text-wrap" }, (_e = this.dispute) === null || _e === void 0 ? void 0 : _e.reason)), index.h("div", { key: '4864005f755bdbdecb5ed28370452850dfc9f047', class: "d-table-row gap-2" }, index.h("span", { key: '64b10de9b84fe9992b07a88294caa38b2b63fdca', part: "detail-section-item-title", class: "fw-bold d-table-cell pe-4" }, "Due Date"), index.h("span", { key: '5198c3cd3ebf4246c42d8b59603765bd39bae06b', part: "detail-section-item-data", class: "flex-1 d-table-cell text-wrap" }, (_f = this.dispute) === null || _f === void 0 ? void 0 : _f.due_date))), index.h("div", { key: '29c98ba58742d3195eca08571cbf793bc9d5a7c6', class: "d-flex gap-2 mt-4 justify-content-end" }, index.h(button.Button, { key: '9ef19c0152cbb6342214aa5073ffed303fc85624', variant: "secondary", onClick: () => this.acceptDispute() }, "Accept dispute"), index.h(button.Button, { key: '558126e83a05c0729e17a1abf5ce849e02574096', variant: "primary", onClick: () => this.initiateRespondToDispute() }, "Counter dispute")))), ((_g = this.dispute) === null || _g === void 0 ? void 0 : _g.underReview) && (index.h("div", { key: 'f8c6fee1c63eef8cf2d2a00fb10051686c7572ae', part: parts.text }, index.h("h1", { key: '23c4bb1c8ab00f4cf9a1447156c124f8ecd1f4b7', class: "h4", part: parts.heading4 }, "This payment is disputed and under review"), index.h("p", { key: 'b1c469330757f22582e5c341c68adcd1aae3def3' }, "The cardholder is disputing this payment. A counter dispute has been submitted and is under review."))), ((_h = this.dispute) === null || _h === void 0 ? void 0 : _h.won) && (index.h("div", { key: '46c92fe084337c67ce0bfedf11d89aca38bdc5e4', part: parts.text }, index.h("h1", { key: 'ac06dc25f88d88d257ff56aec620d803a45d6344', class: "h4", part: parts.heading4 }, "This payment was disputed"), index.h("p", { key: '30a26bceb37855460b8ae6ef54c20591900b5fcf' }, "The cardholder disputed this payment and the card issuer has settled it in your favor."))), ((_j = this.dispute) === null || _j === void 0 ? void 0 : _j.lost) && (index.h("div", { key: '2320aa515a8112a27bdbd9e3f1b3a8daf2c1b28e', part: parts.text }, index.h("h1", { key: '32e0cfc6e8d27afe01194ab61ad342781ec31bf8', class: "h4", part: parts.heading4 }, "This payment was disputed"), index.h("p", { key: '6a8b333f0be16d81ffc23609bcdcb8f70435d515' }, "The cardholder disputed this payment and the card issuer has settled it in their favor.")))));
|
|
157
157
|
}
|
|
158
158
|
};
|
|
159
159
|
|
|
@@ -306,7 +306,7 @@ const DisputeResponse = class {
|
|
|
306
306
|
};
|
|
307
307
|
}
|
|
308
308
|
componentWillLoad() {
|
|
309
|
-
|
|
309
|
+
detectDuplicateVersion.detectDuplicateVersion();
|
|
310
310
|
this.analytics = new Analytics.JustifiAnalytics(this);
|
|
311
311
|
this.initializeDisputeServiceMethods();
|
|
312
312
|
}
|
|
@@ -354,7 +354,7 @@ const DisputeResponse = class {
|
|
|
354
354
|
return this.currentStep === 0;
|
|
355
355
|
}
|
|
356
356
|
render() {
|
|
357
|
-
return (index.h("div", { key: '
|
|
357
|
+
return (index.h("div", { key: 'a558e22c9d41b40d01fd7317566b8e92b181396a', class: "dispute-response-root" }, index.h("div", { key: 'b5ccda631bb6b8d9587c97c5f72c73563b32a336', class: "row gy-3" }, index.h("div", { key: '680cd57e4c08c919284911e03c31bf88e9ea27bd', class: "col-12" }, index.h("h1", { key: 'aa9cad23ec784d2d037a39f536f25547e52038fd', class: "h4", part: parts.heading4 }, "Counter dispute")), index.h("div", { key: '39e1d9bb2cd0cca28841430139c301fd18863f81', class: "col-12" }, this.currentStepComponent), index.h("div", { key: '3c87124fcab317c738b2ecfdaa454b008bd921fd', class: "col-12" }, index.h("div", { key: '210414d3492ce600c34b8c93824c81cae12bb3b4', class: "d-flex gap-2 mt-4 justify-content-end" }, this.isFirstStep ? (index.h(button.Button, { variant: "secondary", onClick: () => this.onCancel(), disabled: this.isLoading, isLoading: this.isLoading }, "Cancel")) : (index.h(button.Button, { variant: "secondary", onClick: () => this.onBack(), disabled: this.isLoading, isLoading: this.isLoading }, "Back")), this.isLastStep ? (index.h(button.Button, { variant: "primary", onClick: () => this.onSubmit(), disabled: this.isLoading, isLoading: this.isLoading }, "Submit Counter Dispute")) : (index.h(button.Button, { variant: "primary", onClick: () => this.onNext(), disabled: this.isLoading, isLoading: this.isLoading }, "Next")))))));
|
|
358
358
|
}
|
|
359
359
|
static get watchers() { return {
|
|
360
360
|
"disputeId": ["propChanged"],
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var Api = require('./Api-
|
|
4
|
-
require('./Plaid-
|
|
3
|
+
var Api = require('./Api-DqXlEWR1.js');
|
|
4
|
+
require('./Plaid-BcOAKDaU.js');
|
|
5
5
|
require('./Pagination-Dediz133.js');
|
|
6
|
-
require('./Business-
|
|
6
|
+
require('./Business-CNaz-VLa.js');
|
|
7
7
|
|
|
8
8
|
const api = Api.Api();
|
|
9
9
|
class DisputeService {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-p7cvUYAE.js');
|
|
4
|
-
var Business = require('./Business-
|
|
5
|
-
var utils = require('./utils-
|
|
6
|
-
var countryConfig = require('./country-config-
|
|
4
|
+
var Business = require('./Business-CNaz-VLa.js');
|
|
5
|
+
var utils = require('./utils-Ct_X5q0U.js');
|
|
6
|
+
var countryConfig = require('./country-config-CFC3KuVD.js');
|
|
7
7
|
var index$1 = require('./index-1MT3Z4XI.js');
|
|
8
8
|
var parts = require('./parts-BXshb_S-.js');
|
|
9
9
|
var formControlErrorText = require('./form-control-error-text-BO58Y6zF.js');
|
|
@@ -18,7 +18,7 @@ const FormAddressFields = class {
|
|
|
18
18
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
19
19
|
const labels = countryConfig.countryLabels[this.country];
|
|
20
20
|
const options = countryConfig.countryOptions[this.country];
|
|
21
|
-
return (index.h(index.Host, { key: '
|
|
21
|
+
return (index.h(index.Host, { key: 'a1bbc92e63a973d2ad70019597132b599529d3b5' }, index.h("div", { key: 'f52aee4bdb8987e40693e75627bd5f852e20f9c9', class: "row gy-3" }, index.h("div", { key: '3557621ecc4910bba3d41551ffc6fbf88cabb1ef', class: "col-12" }, index.h("form-control-text", { key: '5d0df84b735ff1364bf62185db33afdc4c0782e2', name: "line1", label: "Street Address", inputHandler: this.inputHandler, defaultValue: (_a = this.defaultValues) === null || _a === void 0 ? void 0 : _a.line1, errorText: (_b = this.errors) === null || _b === void 0 ? void 0 : _b.line1, helpText: "No PO Boxes." })), index.h("div", { key: '671665f83b6569830296842ac089fdcfafa19b0d', class: "col-12" }, index.h("form-control-text", { key: '21b3f2e4dfc8b30603d22ffb4d59480be2035aff', name: "line2", label: "Address Line 2 (optional)", inputHandler: this.inputHandler, defaultValue: (_c = this.defaultValues) === null || _c === void 0 ? void 0 : _c.line2, errorText: (_d = this.errors) === null || _d === void 0 ? void 0 : _d.line2 })), index.h("div", { key: '731c4bb3c8fcbf2f68f0a721415210819d3721c6', class: "col-12" }, index.h("form-control-text", { key: 'b0283f71fe2d8efdadc918257d119c0af2b02243', name: "city", label: "City", inputHandler: this.inputHandler, defaultValue: (_e = this.defaultValues) === null || _e === void 0 ? void 0 : _e.city, errorText: (_f = this.errors) === null || _f === void 0 ? void 0 : _f.city })), index.h("div", { key: '42c208d228cf9c1f278c9c666d15f1508d6c8c51', class: "col-12 col-md-6" }, index.h("form-control-select", { key: '9da34256e043df09cf924c110b059304e35a3451', name: "state", label: labels.stateLabel, options: options.stateOptions, inputHandler: this.inputHandler, defaultValue: (_g = this.defaultValues) === null || _g === void 0 ? void 0 : _g.state, errorText: (_h = this.errors) === null || _h === void 0 ? void 0 : _h.state })), index.h("div", { key: '24622af99d38f69c942e3e73d6705a68a2a3dc07', class: "col-12 col-md-6" }, index.h("form-control-text", { key: '24405b8aff1b14bcb00583085efeb8b3f33a6903', name: "postal_code", label: labels.postalLabel, inputHandler: this.inputHandler, defaultValue: (_j = this.defaultValues) === null || _j === void 0 ? void 0 : _j.postal_code, errorText: (_k = this.errors) === null || _k === void 0 ? void 0 : _k.postal_code, transformValue: countryConfig.normalizePostalCode, maxLength: this.country === Business.CountryCode.USA ? 10 : 7, keyDownHandler: this.country === Business.CountryCode.USA ? utils.zipCodeOnlyHandler : undefined })))));
|
|
22
22
|
}
|
|
23
23
|
};
|
|
24
24
|
|
|
@@ -86,10 +86,10 @@ const FormControlNumberMasked = class {
|
|
|
86
86
|
return parts.input;
|
|
87
87
|
}
|
|
88
88
|
render() {
|
|
89
|
-
return (index.h(index.Host, { key: '
|
|
89
|
+
return (index.h(index.Host, { key: '9d164bbf77f8a5227128ab5c606d6f9eb8b5e260' }, index.h("div", { key: '780108deefb44f3bec06093bcbf830ba0f0d32d5', class: "form-group d-flex flex-column" }, index.h("div", { key: '8d1d98b481f68227d0843842fbdb0b768c2325fc', class: "d-flex align-items-start gap-2" }, index.h("label", { key: 'fe3fa6fbc9ddc286ddc60041d90b412b548dcdbc', part: parts.label, class: "form-label", htmlFor: this.name }, this.label), index.h("form-control-tooltip", { key: '3c93c47f498e8f15f7fddd8f284e0b577bf8f35c', helpText: this.helpText })), index.h("input", { key: 'c5c1f8d85996ea3c45d8312fdc27e22e02ab2e8d', ref: el => (this.textInput = el), id: this.name, name: this.name, onFocus: () => (this.isFocused = true), onBlur: () => {
|
|
90
90
|
this.isFocused = false;
|
|
91
91
|
this.formControlBlur.emit();
|
|
92
|
-
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-control is-invalid' : 'form-control', type: "text", disabled: this.disabled }), index.h(formControlErrorText.FormControlErrorText, { key: '
|
|
92
|
+
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-control is-invalid' : 'form-control', type: "text", disabled: this.disabled }), index.h(formControlErrorText.FormControlErrorText, { key: 'dac687b433cdd1f480ae8f67cbdd762eda83492a', errorText: this.errorText, name: this.name }))));
|
|
93
93
|
}
|
|
94
94
|
static get watchers() { return {
|
|
95
95
|
"defaultValue": ["handleDefaultValueChange"]
|
|
@@ -5,7 +5,7 @@ var parts = require('./parts-BXshb_S-.js');
|
|
|
5
5
|
var index$1 = require('./index-DDrfAj-j.js');
|
|
6
6
|
var _commonjsHelpers = require('./_commonjsHelpers-BJu3ubxk.js');
|
|
7
7
|
var formControlErrorText = require('./form-control-error-text-BO58Y6zF.js');
|
|
8
|
-
var _package = require('./package-
|
|
8
|
+
var _package = require('./package-B414Jbra.js');
|
|
9
9
|
|
|
10
10
|
const FormAlert = class {
|
|
11
11
|
constructor(hostRef) {
|
|
@@ -1669,6 +1669,8 @@ class FrameCommunicationService {
|
|
|
1669
1669
|
const MessageEventType = {
|
|
1670
1670
|
tokenize: 'tokenize',
|
|
1671
1671
|
validate: 'validate',
|
|
1672
|
+
/** Opts a hosted field into mask-on-blur. Carries no card data. */
|
|
1673
|
+
setMaskCardNumber: 'setMaskCardNumber',
|
|
1672
1674
|
};
|
|
1673
1675
|
|
|
1674
1676
|
const IframeInput = class {
|
|
@@ -1677,11 +1679,24 @@ const IframeInput = class {
|
|
|
1677
1679
|
this.iframeLoaded = index.createEvent(this, "iframeLoaded", 7);
|
|
1678
1680
|
this.isFocused = false;
|
|
1679
1681
|
this.isValid = true;
|
|
1682
|
+
/**
|
|
1683
|
+
* Opt this field into masking its value to the last four characters when it
|
|
1684
|
+
* loses focus. Forwarded to the hosted field, which owns the behavior.
|
|
1685
|
+
*/
|
|
1686
|
+
this.maskCardNumber = false;
|
|
1687
|
+
this.hasLoaded = false;
|
|
1680
1688
|
this.dispatchMessageEvent = (event) => {
|
|
1681
1689
|
const { eventType, data } = event.data;
|
|
1682
1690
|
if ((data === null || data === void 0 ? void 0 : data.id) !== this.inputId) {
|
|
1683
1691
|
return;
|
|
1684
1692
|
}
|
|
1693
|
+
if (eventType === 'loaded') {
|
|
1694
|
+
this.hasLoaded = true;
|
|
1695
|
+
// Re-sent on every load, not just the first: componentDidRender swaps
|
|
1696
|
+
// the iframe src once the style store fills, so the frame can reload
|
|
1697
|
+
// and would otherwise come back without the flag.
|
|
1698
|
+
this.sendMaskCardNumber();
|
|
1699
|
+
}
|
|
1685
1700
|
if (eventType === 'focused') {
|
|
1686
1701
|
this.isFocused = true;
|
|
1687
1702
|
}
|
|
@@ -1690,8 +1705,91 @@ const IframeInput = class {
|
|
|
1690
1705
|
}
|
|
1691
1706
|
};
|
|
1692
1707
|
}
|
|
1708
|
+
maskCardNumberChanged() {
|
|
1709
|
+
if (this.hasLoaded)
|
|
1710
|
+
this.sendMaskCardNumber();
|
|
1711
|
+
}
|
|
1712
|
+
/**
|
|
1713
|
+
* The <iframe> is created in the LIGHT DOM and slotted in: an iframe inside a
|
|
1714
|
+
* shadow tree is invisible to `window.frames` (spec), so siblings could not
|
|
1715
|
+
* resolve it. The ::part wrappers stay in the shadow tree — theming untouched.
|
|
1716
|
+
*/
|
|
1717
|
+
componentDidLoad() {
|
|
1718
|
+
const iframe = document.createElement('iframe');
|
|
1719
|
+
iframe.setAttribute('name', this.inputId);
|
|
1720
|
+
iframe.setAttribute('width', '100%');
|
|
1721
|
+
// Light-DOM element: merchant CSS reaches it, so pin the box inline.
|
|
1722
|
+
iframe.style.border = '0';
|
|
1723
|
+
iframe.style.display = 'block';
|
|
1724
|
+
iframe.style.width = '100%';
|
|
1725
|
+
iframe.style.boxSizing = 'border-box';
|
|
1726
|
+
iframe.addEventListener('load', () => {
|
|
1727
|
+
iFrameResize({
|
|
1728
|
+
log: false,
|
|
1729
|
+
onResized: () => {
|
|
1730
|
+
this.iframeLoaded.emit();
|
|
1731
|
+
}
|
|
1732
|
+
}, iframe);
|
|
1733
|
+
});
|
|
1734
|
+
this.iframeElement = iframe;
|
|
1735
|
+
this.initializeFrameCommunicationService();
|
|
1736
|
+
iframe.setAttribute('src', this.iframeSrc);
|
|
1737
|
+
this.mountIframe();
|
|
1738
|
+
}
|
|
1739
|
+
/**
|
|
1740
|
+
* Stencil runs componentDidLoad once per instance; a DOM move (framework
|
|
1741
|
+
* reparenting, list reorder) fires disconnected → connected on the same
|
|
1742
|
+
* instance, so the iframe has to be put back by hand.
|
|
1743
|
+
*/
|
|
1744
|
+
connectedCallback() {
|
|
1745
|
+
var _a;
|
|
1746
|
+
if (this.iframeElement && !this.iframeElement.isConnected) {
|
|
1747
|
+
(_a = this.frameService) === null || _a === void 0 ? void 0 : _a.addMessageListener(this.dispatchMessageEvent);
|
|
1748
|
+
this.mountIframe();
|
|
1749
|
+
}
|
|
1750
|
+
}
|
|
1751
|
+
mountIframe() {
|
|
1752
|
+
const root = this.el.getRootNode();
|
|
1753
|
+
// Duck-typed: ShadowRoot is not a global in Stencil's mock-doc.
|
|
1754
|
+
const host = root.nodeType === 11 && root.host ? root.host : null;
|
|
1755
|
+
const iframe = this.iframeElement;
|
|
1756
|
+
if (host) {
|
|
1757
|
+
if (host.getRootNode() !== document) {
|
|
1758
|
+
// A host nested in another shadow tree keeps the iframe out of the
|
|
1759
|
+
// document tree; sibling fields fall back to BroadcastChannel.
|
|
1760
|
+
console.warn(`[justifi] hosted field "${this.inputId}" is inside a nested shadow tree; window.frames cannot reach it`);
|
|
1761
|
+
}
|
|
1762
|
+
// Real <slot> element, not JSX: Stencil's slot polyfill for shadow:false
|
|
1763
|
+
// components would otherwise replace it with a virtual slot.
|
|
1764
|
+
if (!this.wrapperElement.querySelector(`slot[name="${this.inputId}"]`)) {
|
|
1765
|
+
const slot = document.createElement('slot');
|
|
1766
|
+
slot.name = this.inputId;
|
|
1767
|
+
this.wrapperElement.appendChild(slot);
|
|
1768
|
+
}
|
|
1769
|
+
iframe.setAttribute('slot', this.inputId);
|
|
1770
|
+
host.appendChild(iframe);
|
|
1771
|
+
}
|
|
1772
|
+
else {
|
|
1773
|
+
iframe.removeAttribute('slot');
|
|
1774
|
+
this.wrapperElement.appendChild(iframe);
|
|
1775
|
+
}
|
|
1776
|
+
}
|
|
1777
|
+
componentDidRender() {
|
|
1778
|
+
// iframeSrc depends on the iframeInputStyles store, which is filled after
|
|
1779
|
+
// first paint; keep the light-DOM iframe in sync like the old JSX src did.
|
|
1780
|
+
if (this.iframeElement && this.iframeElement.getAttribute('src') !== this.renderedSrc) {
|
|
1781
|
+
this.iframeElement.setAttribute('src', this.renderedSrc);
|
|
1782
|
+
}
|
|
1783
|
+
}
|
|
1693
1784
|
disconnectedCallback() {
|
|
1694
|
-
|
|
1785
|
+
var _a, _b, _c, _d, _e;
|
|
1786
|
+
// Stencil defers this call; on a DOM move the element is already back in
|
|
1787
|
+
// the document (its light-DOM iframe moved with the host), so leave it be.
|
|
1788
|
+
if (this.el.isConnected)
|
|
1789
|
+
return;
|
|
1790
|
+
(_a = this.frameService) === null || _a === void 0 ? void 0 : _a.removeMessageListener(this.dispatchMessageEvent);
|
|
1791
|
+
(_d = (_c = (_b = this.iframeElement) === null || _b === void 0 ? void 0 : _b.iFrameResizer) === null || _c === void 0 ? void 0 : _c.removeListeners) === null || _d === void 0 ? void 0 : _d.call(_c);
|
|
1792
|
+
(_e = this.iframeElement) === null || _e === void 0 ? void 0 : _e.remove();
|
|
1695
1793
|
}
|
|
1696
1794
|
async validate() {
|
|
1697
1795
|
const response = await this.frameService
|
|
@@ -1716,6 +1814,12 @@ const IframeInput = class {
|
|
|
1716
1814
|
this.frameService = new FrameCommunicationService(this.iframeElement, this.iframeOrigin);
|
|
1717
1815
|
(_a = this.frameService) === null || _a === void 0 ? void 0 : _a.addMessageListener(this.dispatchMessageEvent);
|
|
1718
1816
|
}
|
|
1817
|
+
sendMaskCardNumber() {
|
|
1818
|
+
var _a;
|
|
1819
|
+
(_a = this.frameService) === null || _a === void 0 ? void 0 : _a.postMessage(MessageEventType.setMaskCardNumber, {
|
|
1820
|
+
enabled: !!this.maskCardNumber,
|
|
1821
|
+
});
|
|
1822
|
+
}
|
|
1719
1823
|
get part() {
|
|
1720
1824
|
if (this.isFocused && !this.isValid) {
|
|
1721
1825
|
return parts.inputInvalidAndFocused;
|
|
@@ -1747,25 +1851,22 @@ const IframeInput = class {
|
|
|
1747
1851
|
return params;
|
|
1748
1852
|
}
|
|
1749
1853
|
get iframeSrc() {
|
|
1750
|
-
|
|
1854
|
+
// iframeOrigin already carries ?tabId=…; a second '?' would fold the
|
|
1855
|
+
// style params into the tabId value on the iframe side.
|
|
1856
|
+
const separator = this.iframeOrigin.includes('?') ? '&' : '?';
|
|
1857
|
+
return `${this.iframeOrigin}${separator}${this.urlParams}`;
|
|
1751
1858
|
}
|
|
1752
1859
|
render() {
|
|
1753
|
-
|
|
1860
|
+
this.renderedSrc = this.iframeSrc;
|
|
1861
|
+
return (index.h(index.Host, { key: '4e4844f10dec9ddcb6f3f4ccaa5ffe7f254f1a33', class: "form-group d-flex flex-column" }, index.h("div", { key: '65cf8392e8e5925560a2bfa80fb15209ec14e267', style: {
|
|
1754
1862
|
visibility: this.iframeLoaded ? 'visible' : 'hidden',
|
|
1755
1863
|
height: this.iframeLoaded ? 'auto' : '0',
|
|
1756
|
-
} }, index.h("label", { key: '
|
|
1757
|
-
this.iframeElement = el;
|
|
1758
|
-
this.initializeFrameCommunicationService();
|
|
1759
|
-
}, width: "100%", onLoad: () => {
|
|
1760
|
-
iFrameResize({
|
|
1761
|
-
log: false,
|
|
1762
|
-
onResized: () => {
|
|
1763
|
-
this.iframeLoaded.emit();
|
|
1764
|
-
}
|
|
1765
|
-
}, this.iframeElement);
|
|
1766
|
-
} })), index.h(formControlErrorText.FormControlErrorText, { key: 'f5897f95387e6400f35c997b2921a60fb5f4f11b', errorText: this.errorText, name: this.inputId }))));
|
|
1864
|
+
} }, index.h("label", { key: 'c33c671e062b2d91a6c7dcdc938faa973a320ac8', class: "form-label", htmlFor: "", part: parts.label }, this.label || ''), index.h("div", { key: 'dd294ff2efac3747af3ec6baa73fc74aaad8b46b', ref: el => (this.wrapperElement = el), class: `p-0 d-flex form-control ${this.isValid ? '' : 'is-invalid'}`, part: this.part, style: Object.assign(Object.assign({}, this.style), { overflow: 'hidden' }) }), index.h(formControlErrorText.FormControlErrorText, { key: 'a6a65814a1ba0fcb2ec4eff7f6b334a134763a8e', errorText: this.errorText, name: this.inputId }))));
|
|
1767
1865
|
}
|
|
1768
1866
|
get el() { return index.getElement(this); }
|
|
1867
|
+
static get watchers() { return {
|
|
1868
|
+
"maskCardNumber": ["maskCardNumberChanged"]
|
|
1869
|
+
}; }
|
|
1769
1870
|
};
|
|
1770
1871
|
|
|
1771
1872
|
exports.form_alert = FormAlert;
|
|
@@ -42,10 +42,10 @@ const FormControlCheckbox = class {
|
|
|
42
42
|
return parts.inputCheckbox;
|
|
43
43
|
}
|
|
44
44
|
render() {
|
|
45
|
-
return (index.h(index.Host, { key: '
|
|
45
|
+
return (index.h(index.Host, { key: 'b4a318391a00778af627a0385a93d7ef60c4bccf' }, index.h("div", { key: '51cc39ecf64ee93f675debb15f41826cb8313f55', class: 'form-group d-flex flex-column' }, index.h("div", { key: '6f94ae2471682353da92935d54ecfc6586c23043', class: "form-check" }, index.h("input", { key: '0765ddf0ca90961699fb4193bc69f4d993a86605', ref: el => (this.checkboxElement = el), type: "checkbox", id: this.name, name: this.name, onFocus: () => this.isFocused = true, onBlur: () => {
|
|
46
46
|
this.isFocused = false;
|
|
47
47
|
this.formControlBlur.emit();
|
|
48
|
-
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-check-input is-invalid' : 'form-check-input', disabled: this.disabled, checked: this.checked }), index.h("label", { key: '
|
|
48
|
+
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-check-input is-invalid' : 'form-check-input', disabled: this.disabled, checked: this.checked }), index.h("label", { key: '1393b351ea9d57d215f57c6dab211db04456563c', class: "form-check-label", htmlFor: this.name, part: parts.label }, this.label)), index.h(formControlHelpText.FormControlHelpText, { key: 'e6cf1f28d5319dddce29f2e8e16d5124696f7f2d', helpText: this.helpText, name: this.name }), index.h(formControlErrorText.FormControlErrorText, { key: '073b4f85a30dad86a1d71acc4f81f8be83d915d9', errorText: this.errorText, name: this.name }))));
|
|
49
49
|
}
|
|
50
50
|
};
|
|
51
51
|
|
|
@@ -49,10 +49,10 @@ const FormControlDate = class {
|
|
|
49
49
|
return part;
|
|
50
50
|
}
|
|
51
51
|
render() {
|
|
52
|
-
return (index.h(index.Host, { key: '
|
|
52
|
+
return (index.h(index.Host, { key: '94251f3df294348460dafe736036018fda20cfb7' }, index.h("div", { key: '16f9e5a436bd58f5e1baf42cc5b6e5f47082cbef', class: "form-group d-flex flex-column" }, index.h("div", { key: 'f4f00eacfe91e033121f3e4e01b3d664dce14319', class: "d-flex gap-2" }, index.h("label", { key: '085aa90a2eb929073227ed1dd8a12541b3d3ab8d', part: parts.label, class: "form-label", htmlFor: this.name }, this.label), index.h("form-control-tooltip", { key: '87c826650b1e5f82db9110464c7e7f9c16cd6353', helpText: this.helpText })), index.h("input", { key: '824e104137bcb77a87e9691c0ae19b57b2812a85', type: this.showTime ? 'datetime-local' : 'date', ref: el => (this.dateInput = el), id: this.name, name: this.name, onFocus: () => this.isFocused = true, onBlur: () => {
|
|
53
53
|
this.isFocused = false;
|
|
54
54
|
this.formControlBlur.emit();
|
|
55
|
-
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-control is-invalid' : 'form-control', disabled: this.disabled, max: this.maxDate }), index.h(formControlErrorText.FormControlErrorText, { key: '
|
|
55
|
+
}, onInput: this.handleFormControlInput, part: this.part, class: this.errorText ? 'form-control is-invalid' : 'form-control', disabled: this.disabled, max: this.maxDate }), index.h(formControlErrorText.FormControlErrorText, { key: '20566bdcd0149a9e464d547596b617ef9c95df27', errorText: this.errorText, name: this.name }))));
|
|
56
56
|
}
|
|
57
57
|
static get watchers() { return {
|
|
58
58
|
"defaultValue": ["handleDefaultValueChange"]
|
|
@@ -14,7 +14,7 @@ const FormControlFileV2 = class {
|
|
|
14
14
|
this.disabled = false;
|
|
15
15
|
}
|
|
16
16
|
render() {
|
|
17
|
-
return (index.h(index.Host, { key: '
|
|
17
|
+
return (index.h(index.Host, { key: 'da210da60328a5f8ee71a88b5fa8d4d67220239b', exportparts: "label,input,input-invalid" }, index.h("div", { key: 'f77db6dd47f4d9d64beace790a6d4fcd937c381c', class: "form-group d-flex flex-column" }, index.h("div", { key: 'ce25b3f690fed13cefa402d07f0afffc7c168f46', class: "d-flex align-items-start gap-2" }, index.h("label", { key: '82d2d2cebee0b98849c90ab90a67cb56be8c239e', part: "label", class: "form-label", htmlFor: this.name }, this.label), index.h("form-control-tooltip", { key: '2593993d8ed2824c8ceaf0c7c9da194361edac25', helpText: this.helpText })), index.h("input", { key: '04d5a84a8c1a92b20ef26f47463b3a836027c8cb', type: "file", name: this.name, part: `input ${this.errorText ? "input-invalid " : ""}${this.disabled ? "input-disabled" : ""}`, class: this.errorText ? "form-control is-invalid" : "form-control", multiple: this.multiple, disabled: this.disabled, onBlur: () => this.formControlBlur.emit(), onChange: () => this.errorText = "" }), index.h(formControlErrorText.FormControlErrorText, { key: 'ccb9cc9b8e138f3f9e1ed96fe660f3d784de004f', errorText: this.errorText, name: this.name }))));
|
|
18
18
|
}
|
|
19
19
|
get el() { return index.getElement(this); }
|
|
20
20
|
};
|