@justifi/webcomponents 6.1.0 → 6.2.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/{Business-DCRzZf0w.js → Business-DWHy_-z9.js} +299 -9
- package/dist/cjs/bank-account-document-form-inputs_6.cjs.entry.js +132 -0
- package/dist/cjs/bank-account-form.cjs.entry.js +2 -2
- package/dist/cjs/{business-additional-questions-schema-b8P-0T0O.js → business-additional-questions-schema-CetDMUp7.js} +26 -4
- package/dist/cjs/{business-form-options-CMII7nIK.js → business-form-options-e9UFw4P-.js} +1 -1
- package/dist/cjs/business-identity-schema-Cd0tvfJr.js +101 -0
- package/dist/cjs/{business.service-Cj_NUZsr.js → business.service-DRZurAMP.js} +1 -1
- package/dist/cjs/card-form.cjs.entry.js +2 -2
- package/dist/cjs/{check-pkg-version-C7b-OLb5.js → check-pkg-version-W_AFeiO6.js} +2 -2
- package/dist/cjs/{checkout.service-Bc8L9ixO.js → checkout.service-vZbSE3A3.js} +1 -1
- package/dist/cjs/checkouts-list-core.cjs.entry.js +2 -4
- package/dist/cjs/country-config-MCOhn8o3.js +68 -0
- package/dist/cjs/{custom-popper_2.cjs.entry.js → custom-popper.cjs.entry.js} +2 -22
- package/dist/cjs/{dispute.service-DhO_tuDc.js → dispute.service-DV9a61Tu.js} +1 -1
- package/dist/cjs/form-alert_5.cjs.entry.js +25 -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 +3 -3
- package/dist/cjs/form-control-monetary-provisioning.cjs.entry.js +3 -3
- package/dist/cjs/form-control-monetary.cjs.entry.js +2 -2
- package/dist/cjs/form-control-number-masked_3.cjs.entry.js +119 -0
- package/dist/cjs/form-control-number.cjs.entry.js +2 -2
- package/dist/cjs/form-control-radio.cjs.entry.js +2 -2
- package/dist/cjs/{form-control-select_2.cjs.entry.js → form-control-select_3.cjs.entry.js} +23 -4
- package/dist/cjs/{form-input-masks-DgXd0f4V.js → form-input-masks-BnNFJ3IJ.js} +9 -4
- package/dist/cjs/{get-business-o5jPq_ME.js → get-business-D9ZHyPem.js} +1 -1
- package/dist/cjs/{get-payment-details-BinT-ZEP.js → get-payment-details-AYzxPu-X.js} +1 -1
- package/dist/cjs/{get-subaccounts-BoTVdl7v.js → get-subaccounts-C_KD197w.js} +1 -1
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +1 -1
- package/dist/cjs/hidden-input_2.cjs.entry.js +5 -5
- package/dist/cjs/{input-handlers-DYl_0IwC.js → input-handlers-D6QMwPTB.js} +2 -2
- package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +121 -64
- package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +17 -18
- package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +8 -8
- package/dist/cjs/justifi-apple-pay_8.cjs.entry.js +8 -10
- package/dist/cjs/justifi-bank-account-billing-form-simple_9.cjs.entry.js +16 -17
- package/dist/cjs/justifi-business-details.cjs.entry.js +5 -7
- package/dist/cjs/justifi-business-form.cjs.entry.js +16 -12
- package/dist/cjs/justifi-business-representative-form-inputs.cjs.entry.js +14 -6
- package/dist/cjs/justifi-checkout.cjs.entry.js +5 -7
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +2 -4
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +6 -8
- package/dist/cjs/justifi-details.cjs.entry.js +1 -1
- package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +1 -1
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +5 -7
- package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +7 -9
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +3 -5
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +7 -9
- package/dist/cjs/justifi-owner-form_3.cjs.entry.js +22 -13
- package/dist/cjs/justifi-payment-details.cjs.entry.js +5 -7
- package/dist/cjs/justifi-payment-provisioning-core.cjs.entry.js +36 -21
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +5 -7
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +5 -7
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +2 -2
- package/dist/cjs/justifi-payments-list.cjs.entry.js +5 -7
- package/dist/cjs/justifi-payout-details.cjs.entry.js +4 -6
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +5 -7
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +2 -2
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +6 -8
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +5 -7
- package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +1 -1
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +3 -5
- package/dist/cjs/justifi-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +3 -5
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +5 -7
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +2 -4
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +6 -8
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-BHmdO9eK.js → package-BADgkv50.js} +1 -1
- package/dist/cjs/pagination-menu.cjs.entry.js +3 -3
- package/dist/cjs/payment-details-core.cjs.entry.js +9 -11
- package/dist/cjs/payment-method-option.cjs.entry.js +1 -1
- package/dist/cjs/{payment.service-C9thkR4g.js → payment.service-1t60I69m.js} +1 -1
- package/dist/cjs/payments-list-core.cjs.entry.js +2 -4
- package/dist/cjs/payout-details-core.cjs.entry.js +3 -3
- package/dist/cjs/{payout.service-CGZxpQMq.js → payout.service-CQEXfufW.js} +1 -1
- package/dist/cjs/payouts-list-core.cjs.entry.js +2 -4
- package/dist/cjs/{schema-validations-Bj7eYNO8.js → schema-validations-0mjPveQ0.js} +45 -6
- package/dist/cjs/table-filters-menu.cjs.entry.js +1 -1
- package/dist/cjs/terminal-orders-list-core.cjs.entry.js +3 -5
- package/dist/cjs/{terminal-orders-table-7ew1vCKk.js → terminal-orders-table-B4ZXHj3w.js} +1 -1
- package/dist/cjs/terminal-quantity-selector.cjs.entry.js +1 -1
- package/dist/cjs/{terminal.service-BkKxH-k4.js → terminal.service-BlW-CJ67.js} +1 -1
- package/dist/cjs/terminals-list-core.cjs.entry.js +2 -4
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/api/BankAccount.js +4 -0
- package/dist/collection/api/Business.js +16 -1
- package/dist/collection/collection-manifest.json +4 -1
- package/dist/collection/components/business-forms/business-form/additional-questions/additional-questions.js +7 -6
- package/dist/collection/components/business-forms/business-form/business-core-info/business-core-info.js +36 -4
- package/dist/collection/components/business-forms/business-form/business-form.js +6 -2
- package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +46 -9
- package/dist/collection/components/business-forms/business-form/legal-address-form/legal-address-form.js +32 -10
- package/dist/collection/components/business-forms/owner-form/identity-address/identity-address-form.js +26 -6
- package/dist/collection/components/business-forms/owner-form/owner-form-core.js +29 -3
- package/dist/collection/components/business-forms/owner-form/owner-form-inputs.js +48 -6
- package/dist/collection/components/business-forms/owner-form/owner-form.js +26 -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-canada.js +88 -0
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs.js +2 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-read-only-value.js +50 -0
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step-core.js +36 -5
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step-core.js +47 -7
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step-core.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.js +43 -4
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step-core.js +33 -4
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/form-address-fields/form-address-fields.js +101 -0
- 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-core.js +35 -10
- package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +26 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-core.js +39 -20
- 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 +34 -6
- 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/business-forms/payment-provisioning/test/mockBusiness.js +52 -0
- package/dist/collection/components/business-forms/schemas/business-address-schema.js +41 -19
- package/dist/collection/components/business-forms/schemas/business-bank-account-schema.js +74 -39
- package/dist/collection/components/business-forms/schemas/business-core-info-schema.js +27 -4
- package/dist/collection/components/business-forms/schemas/business-form-schema.js +7 -4
- package/dist/collection/components/business-forms/schemas/business-identity-schema.js +53 -24
- package/dist/collection/components/business-forms/schemas/schema-validations.js +41 -4
- package/dist/collection/components/business-forms/utils/country-config.js +47 -0
- package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +2 -2
- package/dist/collection/components/checkout/card-form/card-form.js +2 -2
- package/dist/collection/components/checkout/checkout.js +2 -2
- package/dist/collection/components/checkout/save-new-payment-method.js +1 -1
- package/dist/collection/components/checkout/saved-payment-method.js +1 -1
- package/dist/collection/components/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/modular-checkout.js +3 -4
- 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/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 +3 -4
- 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 +2 -2
- 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 +1 -1
- package/dist/collection/ui-components/shadow-dom-components/justifi-skeleton.js +1 -1
- package/dist/collection/utils/country-codes.js +5 -0
- package/dist/collection/utils/form-input-masks.js +8 -0
- package/dist/collection/utils/province-options.js +20 -0
- package/dist/docs.json +1129 -147
- package/dist/esm/{Api-DhiA2e_P.js → Api-K9QH1Aki.js} +1 -1
- package/dist/esm/{Business-BCoP0TAV.js → Business-B5rtFhtR.js} +290 -3
- package/dist/esm/{Refund-B-iOTRxz.js → Refund-L_muwEAh.js} +1 -1
- package/dist/esm/additional-questions-details_5.entry.js +3 -3
- package/dist/esm/{badge-CtdO-tEY.js → badge-B8fF98jp.js} +1 -1
- package/dist/esm/bank-account-document-form-inputs_6.entry.js +125 -0
- package/dist/esm/bank-account-form.entry.js +5 -5
- package/dist/esm/{business-additional-questions-schema-9FAJSx_D.js → business-additional-questions-schema-DSvdNuI1.js} +26 -5
- package/dist/esm/business-details-core.entry.js +3 -3
- package/dist/esm/{business-form-options-CgssATyg.js → business-form-options-D6s5H4RI.js} +2 -2
- package/dist/esm/business-identity-schema-mN4VhA1v.js +94 -0
- package/dist/esm/{business.service-D55OVyco.js → business.service-BJcGEUDH.js} +3 -3
- package/dist/esm/{button-DtTaQHMK.js → button-DZoLTGMB.js} +1 -1
- package/dist/esm/card-form.entry.js +5 -5
- package/dist/esm/{check-pkg-version-xM0uWxbL.js → check-pkg-version-CG8qzhGl.js} +4 -4
- package/dist/esm/{checkout.service-fwbqSq8g.js → checkout.service-aymuZDC9.js} +3 -3
- package/dist/esm/checkouts-list-core.entry.js +9 -11
- package/dist/esm/{checkouts-table-B6gGDtOr.js → checkouts-table-B8k-Aylm.js} +3 -3
- package/dist/esm/country-config-BQ4D46Lb.js +64 -0
- package/dist/esm/{custom-popper_2.entry.js → custom-popper.entry.js} +3 -22
- package/dist/esm/{dispute.service-Cdq3_yRo.js → dispute.service-DiPbsswm.js} +3 -3
- package/dist/esm/form-alert_5.entry.js +25 -15
- 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-bprS-t9d.js → form-control-error-text-BmD6bGbR.js} +1 -1
- package/dist/esm/form-control-file-v2_2.entry.js +5 -5
- package/dist/esm/{form-control-help-text-Bvnp-IAG.js → form-control-help-text-DbIhIcc6.js} +1 -1
- package/dist/esm/form-control-monetary-provisioning.entry.js +6 -6
- package/dist/esm/form-control-monetary.entry.js +6 -6
- package/dist/esm/form-control-number-masked_3.entry.js +115 -0
- 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 → form-control-select_3.entry.js} +25 -7
- package/dist/esm/{form-input-masks-B-iV5cYd.js → form-input-masks-CVaOFfrI.js} +9 -3
- package/dist/esm/{get-business-Crb6P-iI.js → get-business-Xt7B5dSo.js} +1 -1
- package/dist/esm/{get-payment-details-sGoWyAat.js → get-payment-details-DcC5v85s.js} +2 -2
- package/dist/esm/{get-subaccounts-BsJSlShO.js → get-subaccounts-CMJMDwSP.js} +3 -3
- package/dist/esm/gross-payment-chart-core.entry.js +5 -5
- package/dist/esm/{header-1-C1Hnxki8.js → header-1-umkpdspt.js} +1 -1
- package/dist/esm/{header-3-Bq8fpjm-.js → header-3-CD5K5vCa.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +7 -7
- package/dist/esm/{input-handlers-CX6mSvOM.js → input-handlers-D3y0TzH9.js} +1 -1
- package/dist/esm/{insurance-state-CVme82j7.js → insurance-state-sR5DrCdu.js} +1 -1
- package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +127 -70
- package/dist/esm/justifi-additional-questions-form-step_9.entry.js +22 -23
- package/dist/esm/justifi-additional-statement_8.entry.js +9 -9
- package/dist/esm/justifi-apple-pay_8.entry.js +16 -18
- package/dist/esm/justifi-bank-account-billing-form-simple_9.entry.js +22 -23
- package/dist/esm/justifi-business-details.entry.js +10 -12
- package/dist/esm/justifi-business-form.entry.js +23 -19
- package/dist/esm/justifi-business-representative-form-inputs.entry.js +15 -7
- package/dist/esm/justifi-checkout.entry.js +9 -11
- package/dist/esm/justifi-checkouts-list-filters.entry.js +5 -7
- package/dist/esm/justifi-checkouts-list.entry.js +12 -14
- package/dist/esm/justifi-details.entry.js +3 -3
- package/dist/esm/justifi-dispute-management-core.entry.js +1 -1
- package/dist/esm/justifi-dispute-management.entry.js +8 -10
- package/dist/esm/justifi-dispute-notification_3.entry.js +13 -15
- package/dist/esm/justifi-gross-payment-chart.entry.js +8 -10
- package/dist/esm/justifi-order-terminals.entry.js +12 -14
- package/dist/esm/justifi-owner-form_3.entry.js +27 -18
- package/dist/esm/justifi-payment-details.entry.js +10 -12
- package/dist/esm/justifi-payment-provisioning-core.entry.js +38 -23
- package/dist/esm/justifi-payment-provisioning.entry.js +8 -10
- package/dist/esm/justifi-payment-transactions-list.entry.js +11 -13
- package/dist/esm/justifi-payments-list-filters.entry.js +4 -4
- package/dist/esm/justifi-payments-list.entry.js +12 -14
- package/dist/esm/justifi-payout-details.entry.js +9 -11
- package/dist/esm/justifi-payout-transactions-list.entry.js +11 -13
- package/dist/esm/justifi-payouts-list-filters.entry.js +4 -4
- package/dist/esm/justifi-payouts-list.entry.js +13 -15
- package/dist/esm/justifi-refund-payment.entry.js +11 -13
- package/dist/esm/justifi-saved-payment-method.entry.js +2 -2
- package/dist/esm/justifi-season-interruption-insurance.entry.js +9 -11
- package/dist/esm/justifi-skeleton.entry.js +3 -3
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +6 -8
- package/dist/esm/justifi-terminal-orders-list.entry.js +10 -12
- package/dist/esm/justifi-terminals-list-filters.entry.js +5 -7
- package/dist/esm/justifi-terminals-list.entry.js +12 -14
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{package-DL-q4EcN.js → package-yiqa5abX.js} +1 -1
- package/dist/esm/pagination-menu.entry.js +4 -4
- package/dist/esm/{parts-xDbRW9xn.js → parts-Dj_zevuD.js} +1 -1
- package/dist/esm/payment-details-core.entry.js +16 -18
- package/dist/esm/payment-method-option.entry.js +2 -2
- package/dist/esm/{payment.service-BoQ1MW1k.js → payment.service-C0xnydJ8.js} +3 -3
- package/dist/esm/payments-list-core.entry.js +10 -12
- package/dist/esm/{payments-status-cvtVmtY5.js → payments-status-CzazNnFv.js} +1 -1
- package/dist/esm/{payments-table-D_BlyU1F.js → payments-table-BPKxBAJ0.js} +3 -3
- package/dist/esm/payout-details-core.entry.js +10 -10
- package/dist/esm/{payout.service-xcBdom3q.js → payout.service-Cl4yxnrx.js} +3 -3
- package/dist/esm/payouts-list-core.entry.js +10 -12
- package/dist/esm/{payouts-status-D-vjrqBb.js → payouts-status-rKlX41bK.js} +1 -1
- package/dist/esm/{payouts-table-Clj8YGLV.js → payouts-table-C6ZDcd_-.js} +3 -3
- package/dist/esm/{schema-validations-B9dmY7ME.js → schema-validations-BFoU1cR8.js} +41 -6
- package/dist/esm/{skeleton-B8EUwt4b.js → skeleton-BEoPu3My.js} +1 -1
- package/dist/esm/{spinner-CYXkn1fh.js → spinner-Ac-w5zWg.js} +1 -1
- package/dist/esm/{table-Bj20uWfu.js → table-BCwizIf9.js} +2 -2
- package/dist/esm/table-filters-menu.entry.js +3 -3
- package/dist/esm/terminal-orders-list-core.entry.js +9 -11
- package/dist/esm/{terminal-orders-table-DzBpIW8i.js → terminal-orders-table-BBQsoUh8.js} +5 -5
- package/dist/esm/terminal-quantity-selector.entry.js +2 -2
- package/dist/esm/{terminal.service-l6zTIPZ3.js → terminal.service-mwaS-Mbj.js} +3 -3
- package/dist/esm/terminals-list-core.entry.js +9 -11
- package/dist/esm/{terminals-table-BMS5tazC.js → terminals-table-ByiFdTfy.js} +3 -3
- package/dist/esm/{utils-BOijEGPV.js → utils-CIaHqjQt.js} +1 -1
- package/dist/esm/{utils-DRwofES0.js → utils-KBIYAa0D.js} +1 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/module/Business.js +290 -3
- package/dist/module/additional-questions.js +2 -2
- package/dist/module/additional-statement.js +2 -2
- package/dist/module/bank-account-billing-form-simple.js +1 -1
- package/dist/module/bank-account-document-inputs.js +1 -1
- package/dist/module/bank-account-form-inputs-canada.d.ts +11 -0
- package/dist/module/bank-account-form-inputs-canada.js +6 -0
- package/dist/module/bank-account-form-inputs-canada2.js +68 -0
- package/dist/module/bank-account-form-inputs2.js +9 -2
- package/dist/module/bank-account-form.js +2 -2
- package/dist/module/bank-account-read-only-value.d.ts +11 -0
- package/dist/module/bank-account-read-only-value.js +6 -0
- package/dist/module/bank-account-read-only-value2.js +33 -0
- package/dist/module/bank-account.js +2 -2
- package/dist/module/billing-form-full.js +1 -1
- package/dist/module/business-additional-questions-form-step.js +1 -1
- package/dist/module/business-address-schema.js +40 -20
- package/dist/module/business-bank-account-form-step-core.js +101 -48
- package/dist/module/business-bank-account-form-step.js +18 -5
- package/dist/module/business-core-info-form-step-core.js +22 -7
- package/dist/module/business-core-info-form-step.js +2 -1
- package/dist/module/business-core-info-schema.js +26 -5
- package/dist/module/business-core-info.js +12 -4
- package/dist/module/business-identity-schema.js +52 -25
- package/dist/module/business-owners-form-step-core.js +20 -13
- package/dist/module/business-owners-form-step.js +22 -15
- package/dist/module/business-representative-form-inputs.js +34 -17
- package/dist/module/business-representative-form-step-core.js +29 -18
- package/dist/module/business-representative-form-step.js +24 -17
- package/dist/module/business-representative.js +37 -19
- package/dist/module/business-terms-conditions-form-step.js +1 -1
- package/dist/module/button.js +1 -1
- package/dist/module/cancellation-policy.js +2 -2
- package/dist/module/card-billing-form-simple.js +1 -1
- package/dist/module/card-form.js +2 -2
- package/dist/module/card-form2.js +2 -2
- package/dist/module/checkouts-list-core2.js +1 -1
- package/dist/module/country-config.js +64 -0
- package/dist/module/custom-popper2.js +2 -2
- package/dist/module/customer-details.js +2 -2
- package/dist/module/details.js +1 -1
- package/dist/module/dispute-management-core.js +1 -1
- package/dist/module/dispute-notification.js +2 -2
- package/dist/module/dispute-response-core.js +2 -2
- package/dist/module/dispute-response.js +1 -1
- package/dist/module/duplicate-charge.js +2 -2
- package/dist/module/electronic-evidence.js +2 -2
- package/dist/module/form-address-fields.js +65 -0
- 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-monetary-provisioning2.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-number.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 +2 -2
- package/dist/module/form-control-textarea2.js +2 -2
- package/dist/module/form-input-masks.js +9 -3
- package/dist/module/get-business.js +1 -1
- package/dist/module/gross-payment-chart-core2.js +1 -1
- package/dist/module/hidden-input2.js +1 -1
- package/dist/module/identity-address-form.js +16 -14
- package/dist/module/iframe-input2.js +3 -3
- package/dist/module/input-handlers.js +1 -1
- package/dist/module/justifi-business-form.js +41 -29
- package/dist/module/justifi-button2.js +1 -1
- package/dist/module/justifi-checkout.js +2 -2
- package/dist/module/justifi-checkouts-list-filters.js +1 -1
- package/dist/module/justifi-checkouts-list.js +1 -1
- package/dist/module/justifi-dispute-management.js +1 -1
- package/dist/module/justifi-form-address-fields.d.ts +11 -0
- package/dist/module/justifi-form-address-fields.js +6 -0
- package/dist/module/justifi-header2.js +1 -1
- package/dist/module/justifi-order-terminals.js +3 -3
- package/dist/module/justifi-payment-provisioning.js +67 -49
- package/dist/module/justifi-payment-transactions-list.js +1 -1
- package/dist/module/justifi-payments-list-filters.js +2 -2
- package/dist/module/justifi-payments-list.js +1 -1
- package/dist/module/justifi-payout-transactions-list.js +1 -1
- package/dist/module/justifi-payouts-list-filters.js +2 -2
- package/dist/module/justifi-payouts-list.js +1 -1
- package/dist/module/justifi-radio-list-item2.js +1 -1
- package/dist/module/justifi-saved-payment-method.js +1 -1
- package/dist/module/justifi-skeleton.js +1 -1
- package/dist/module/justifi-terminal-orders-list-filters.js +2 -2
- package/dist/module/justifi-terminal-orders-list.js +1 -1
- package/dist/module/justifi-terminals-list-filters.js +1 -1
- package/dist/module/justifi-terminals-list.js +1 -1
- package/dist/module/legal-address-form-step-core.js +26 -19
- package/dist/module/legal-address-form-step.js +16 -9
- package/dist/module/legal-address-form.js +18 -15
- package/dist/module/modular-checkout.js +1 -1
- package/dist/module/owner-form-core2.js +23 -15
- package/dist/module/owner-form-inputs2.js +34 -15
- package/dist/module/owner-form.js +20 -13
- package/dist/module/package.js +1 -1
- package/dist/module/pagination-menu2.js +3 -3
- package/dist/module/parts.js +1 -1
- package/dist/module/payment-details-core2.js +8 -8
- package/dist/module/payment-method-option.js +1 -1
- package/dist/module/payment-provisioning-core.js +104 -69
- package/dist/module/payment-provisioning-form-buttons.js +1 -1
- package/dist/module/payment-provisioning-form-steps.js +75 -54
- package/dist/module/payments-list-core2.js +1 -1
- package/dist/module/payout-details-core2.js +3 -3
- package/dist/module/payouts-list-core2.js +1 -1
- package/dist/module/product-or-service.js +2 -2
- package/dist/module/refund-policy.js +2 -2
- package/dist/module/save-new-payment-method.js +1 -1
- package/dist/module/schema-validations.js +41 -6
- package/dist/module/shipping-details.js +2 -2
- package/dist/module/summary.js +1 -1
- package/dist/module/table-filters-menu2.js +1 -1
- package/dist/module/terminal-orders-list-core2.js +1 -1
- package/dist/module/terminal-quantity-selector2.js +2 -2
- package/dist/module/terminals-list-core2.js +1 -1
- package/dist/module/tokenize-payment-method.js +1 -1
- package/dist/types/api/BankAccount.d.ts +6 -0
- package/dist/types/api/Business.d.ts +9 -0
- package/dist/types/components/business-forms/business-form/business-core-info/business-core-info.d.ts +3 -0
- package/dist/types/components/business-forms/business-form/business-form.d.ts +2 -0
- package/dist/types/components/business-forms/business-form/business-representative/business-representative.d.ts +4 -1
- package/dist/types/components/business-forms/business-form/legal-address-form/legal-address-form.d.ts +2 -0
- package/dist/types/components/business-forms/owner-form/identity-address/identity-address-form.d.ts +2 -0
- package/dist/types/components/business-forms/owner-form/owner-form-core.d.ts +2 -0
- package/dist/types/components/business-forms/owner-form/owner-form-inputs.d.ts +3 -0
- package/dist/types/components/business-forms/owner-form/owner-form.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs-canada.d.ts +7 -0
- package/dist/types/components/business-forms/payment-provisioning/bank-account/bank-account-read-only-value.d.ts +5 -0
- package/dist/types/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step-core.d.ts +5 -0
- package/dist/types/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step-core.d.ts +3 -0
- package/dist/types/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/business-owners/business-owners-form-step-core.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.d.ts +3 -0
- package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step-core.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/form-address-fields/form-address-fields.d.ts +8 -0
- package/dist/types/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step-core.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/payment-provisioning-core.d.ts +4 -2
- package/dist/types/components/business-forms/payment-provisioning/payment-provisioning-form-steps.d.ts +2 -0
- package/dist/types/components/business-forms/payment-provisioning/test/mockBusiness.d.ts +12 -0
- package/dist/types/components/business-forms/schemas/business-address-schema.d.ts +54 -2
- package/dist/types/components/business-forms/schemas/business-bank-account-schema.d.ts +14 -16
- package/dist/types/components/business-forms/schemas/business-core-info-schema.d.ts +67 -3
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +165 -7
- package/dist/types/components/business-forms/schemas/business-identity-schema.d.ts +122 -2
- package/dist/types/components/business-forms/schemas/schema-validations.d.ts +5 -0
- package/dist/types/components.d.ts +119 -10
- package/dist/types/utils/country-codes.d.ts +4 -0
- package/dist/types/utils/form-input-masks.d.ts +1 -0
- package/dist/types/utils/province-options.d.ts +5 -0
- package/dist/webcomponents/p-0926c397.entry.js +1 -0
- package/dist/webcomponents/p-09aaaf03.entry.js +1 -0
- package/dist/webcomponents/p-0b36f1a8.entry.js +1 -0
- package/dist/webcomponents/p-10537b60.entry.js +1 -0
- package/dist/webcomponents/p-164fe6d3.entry.js +1 -0
- package/dist/webcomponents/{p-0eb69f41.entry.js → p-1c362f36.entry.js} +1 -1
- package/dist/webcomponents/{p-0217783c.entry.js → p-221ec54e.entry.js} +4 -4
- package/dist/webcomponents/p-24621c40.entry.js +1 -0
- package/dist/webcomponents/{p-cff5dd60.entry.js → p-2ebc8539.entry.js} +1 -1
- package/dist/webcomponents/p-30848456.entry.js +1 -0
- package/dist/webcomponents/p-3b43f8c0.entry.js +1 -0
- package/dist/webcomponents/p-4a0f34de.entry.js +1 -0
- package/dist/webcomponents/p-4d243123.entry.js +1 -0
- package/dist/webcomponents/p-4d6e0ebe.entry.js +1 -0
- package/dist/webcomponents/p-4e57359c.entry.js +1 -0
- package/dist/webcomponents/p-5277f2a6.entry.js +1 -0
- package/dist/webcomponents/p-54cea29e.entry.js +1 -0
- package/dist/webcomponents/{p-7c8deca8.entry.js → p-580f3bb6.entry.js} +1 -1
- package/dist/webcomponents/p-5de4d9e4.entry.js +1 -0
- package/dist/webcomponents/p-5fcfedb2.entry.js +1 -0
- package/dist/webcomponents/p-6190fbb7.entry.js +1 -0
- package/dist/webcomponents/p-620ec409.entry.js +1 -0
- package/dist/webcomponents/p-65090485.entry.js +1 -0
- package/dist/webcomponents/p-66833631.entry.js +1 -0
- package/dist/webcomponents/p-68aeb5bd.entry.js +1 -0
- package/dist/webcomponents/p-6d61092c.entry.js +1 -0
- package/dist/webcomponents/p-72f5e234.entry.js +1 -0
- package/dist/webcomponents/p-7498759d.entry.js +1 -0
- package/dist/webcomponents/p-760e739c.entry.js +1 -0
- package/dist/webcomponents/p-81099469.entry.js +1 -0
- package/dist/webcomponents/p-82723f07.entry.js +1 -0
- package/dist/webcomponents/p-86372164.entry.js +1 -0
- package/dist/webcomponents/{p-b608add9.entry.js → p-8896ab68.entry.js} +1 -1
- package/dist/webcomponents/p-89052ce0.entry.js +1 -0
- package/dist/webcomponents/{p-ClvhB3WW.js → p-890S0Nwr.js} +1 -1
- package/dist/webcomponents/{p-37a93597.entry.js → p-8a156528.entry.js} +1 -1
- package/dist/webcomponents/p-8a68be8f.entry.js +1 -0
- package/dist/webcomponents/p-91b09245.entry.js +1 -0
- package/dist/webcomponents/p-9ce44689.entry.js +1 -0
- package/dist/webcomponents/p-B5rtFhtR.js +1 -0
- package/dist/webcomponents/{p-CEk3bv0x.js → p-B9MN_vv4.js} +1 -1
- package/dist/webcomponents/p-BIcS6lTe.js +1 -0
- package/dist/webcomponents/{p-BBx_EQqR.js → p-BRbqaU66.js} +1 -1
- package/dist/webcomponents/{p-Bgnhf5c9.js → p-BS7OgSQe.js} +1 -1
- package/dist/webcomponents/p-BT473_5I.js +1 -0
- package/dist/webcomponents/p-BXMAoCNA.js +1 -0
- package/dist/webcomponents/{p-B6IWa9Ph.js → p-BYrSeoci.js} +1 -1
- package/dist/webcomponents/{p-CCmDcLao.js → p-BdmYH_IK.js} +1 -1
- package/dist/webcomponents/p-BkaPXFTl.js +1 -0
- package/dist/webcomponents/{p-hbWSMN3O.js → p-Bm8T-MOQ.js} +1 -1
- package/dist/webcomponents/p-BwBb2Opu.js +1 -0
- package/dist/webcomponents/p-C6g4MbnB.js +1 -0
- package/dist/webcomponents/{p-1ydcg9ti.js → p-C77ElQ41.js} +1 -1
- package/dist/webcomponents/p-CJ9qo7_g.js +1 -0
- package/dist/webcomponents/{p-C98BC5W5.js → p-CPKSE7M4.js} +1 -1
- package/dist/webcomponents/{p-yH3TC3ZQ.js → p-CPpUGsw5.js} +1 -1
- package/dist/webcomponents/p-CQQ0H4Pb.js +1 -0
- package/dist/webcomponents/p-CTAOJGVx.js +1 -0
- package/dist/webcomponents/p-CVaOFfrI.js +1 -0
- package/dist/webcomponents/p-CVtpEQBE.js +1 -0
- package/dist/webcomponents/p-D9Yus-je.js +1 -0
- package/dist/webcomponents/p-DIdnZUSh.js +1 -0
- package/dist/webcomponents/{p-CH8Y3GSr.js → p-DSCBoCn-.js} +1 -1
- package/dist/webcomponents/p-DfKxeSrC.js +1 -0
- package/dist/webcomponents/{p-D5Jb9OcR.js → p-DfsX5bt_.js} +1 -1
- package/dist/webcomponents/{p-xDbRW9xn.js → p-Dj_zevuD.js} +1 -1
- package/dist/webcomponents/p-DqPvh0aN.js +1 -0
- package/dist/webcomponents/p-DxVCqvBt.js +1 -0
- package/dist/webcomponents/p-DxnXyWPn.js +1 -0
- package/dist/webcomponents/p-Dy3-IlQ3.js +1 -0
- package/dist/webcomponents/p-Dyk0thEr.js +1 -0
- package/dist/webcomponents/p-DzWLLt4t.js +1 -0
- package/dist/webcomponents/{p-CmBCj61h.js → p-F6TcNeK4.js} +1 -1
- package/dist/webcomponents/{p-au49QgoI.js → p-IYf7zn5J.js} +1 -1
- package/dist/webcomponents/{p-C0wTyoTh.js → p-UUJudj_5.js} +1 -1
- package/dist/webcomponents/{p-0cac8468.entry.js → p-a2344efb.entry.js} +1 -1
- package/dist/webcomponents/p-a42ec25b.entry.js +1 -0
- package/dist/webcomponents/p-a81f9fc3.entry.js +1 -0
- package/dist/webcomponents/p-aa51c9e6.entry.js +1 -0
- package/dist/webcomponents/p-af31dc6d.entry.js +1 -0
- package/dist/webcomponents/p-b4b5dd24.entry.js +1 -0
- package/dist/webcomponents/p-b4bb6fa6.entry.js +1 -0
- package/dist/webcomponents/p-b72794e3.entry.js +1 -0
- package/dist/webcomponents/p-be0cbdf9.entry.js +1 -0
- package/dist/webcomponents/p-c4d919be.entry.js +1 -0
- package/dist/webcomponents/p-c796f813.entry.js +1 -0
- package/dist/webcomponents/p-c8656d20.entry.js +1 -0
- package/dist/webcomponents/{p-0cf71cbd.entry.js → p-c8e94ab9.entry.js} +1 -1
- package/dist/webcomponents/p-c9bed02a.entry.js +1 -0
- package/dist/webcomponents/p-cca865be.entry.js +1 -0
- package/dist/webcomponents/p-cd108cae.entry.js +1 -0
- package/dist/webcomponents/p-cfd3035e.entry.js +1 -0
- package/dist/webcomponents/p-d7558874.entry.js +1 -0
- package/dist/webcomponents/p-d8c2cea4.entry.js +1 -0
- package/dist/webcomponents/p-e2ab3f61.entry.js +1 -0
- package/dist/webcomponents/p-e4e6f3b8.entry.js +1 -0
- package/dist/webcomponents/p-e60e7f6a.entry.js +1 -0
- package/dist/webcomponents/p-ef8ac9f4.entry.js +1 -0
- package/dist/webcomponents/p-f4a1d3da.entry.js +1 -0
- package/dist/webcomponents/p-f72f67ef.entry.js +1 -0
- package/dist/webcomponents/p-fcb185fd.entry.js +1 -0
- package/dist/webcomponents/p-fdf5a349.entry.js +1 -0
- package/dist/webcomponents/{p-C8k7a6D-.js → p-i--LPP1s.js} +1 -1
- package/dist/webcomponents/p-sCHf--Vc.js +1 -0
- package/dist/webcomponents/{p-DdZLLkQ5.js → p-ty1sI-fI.js} +1 -1
- package/dist/webcomponents/p-yiqa5abX.js +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +13 -13
- package/LICENSE +0 -21
- package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +0 -112
- package/dist/cjs/business-identity-schema-aFUle0C9.js +0 -51
- package/dist/cjs/form-control-number-masked_2.cjs.entry.js +0 -107
- package/dist/cjs/helpers-B5OCqlIM.js +0 -35
- package/dist/cjs/state-options-CIT9xdTz.js +0 -246
- package/dist/esm/bank-account-document-form-inputs_4.entry.js +0 -107
- package/dist/esm/business-identity-schema-CDJzknbg.js +0 -48
- package/dist/esm/form-control-number-masked_2.entry.js +0 -104
- package/dist/esm/helpers-Mu7LQT-w.js +0 -29
- package/dist/esm/state-options-BX8GieXu.js +0 -244
- package/dist/module/helpers.js +0 -29
- package/dist/module/state-options.js +0 -244
- package/dist/webcomponents/p-0256af65.entry.js +0 -1
- package/dist/webcomponents/p-0af5269e.entry.js +0 -1
- package/dist/webcomponents/p-0f47f052.entry.js +0 -1
- package/dist/webcomponents/p-28a3bf32.entry.js +0 -1
- package/dist/webcomponents/p-2b568e8e.entry.js +0 -1
- package/dist/webcomponents/p-2d300faa.entry.js +0 -1
- package/dist/webcomponents/p-30856338.entry.js +0 -1
- package/dist/webcomponents/p-328117e4.entry.js +0 -1
- package/dist/webcomponents/p-32978110.entry.js +0 -1
- package/dist/webcomponents/p-47997bc2.entry.js +0 -1
- package/dist/webcomponents/p-50701f16.entry.js +0 -1
- package/dist/webcomponents/p-5235230f.entry.js +0 -1
- package/dist/webcomponents/p-526b7442.entry.js +0 -1
- package/dist/webcomponents/p-5aae36f3.entry.js +0 -1
- package/dist/webcomponents/p-5b5d7a8f.entry.js +0 -1
- package/dist/webcomponents/p-5bd3d86e.entry.js +0 -1
- package/dist/webcomponents/p-66db858a.entry.js +0 -1
- package/dist/webcomponents/p-720a2324.entry.js +0 -1
- package/dist/webcomponents/p-78cb62a8.entry.js +0 -1
- package/dist/webcomponents/p-7dc9ef8a.entry.js +0 -1
- package/dist/webcomponents/p-84551ee4.entry.js +0 -1
- package/dist/webcomponents/p-854b3db0.entry.js +0 -1
- package/dist/webcomponents/p-85a2eac6.entry.js +0 -1
- package/dist/webcomponents/p-8663e8bd.entry.js +0 -1
- package/dist/webcomponents/p-89f6ad8f.entry.js +0 -1
- package/dist/webcomponents/p-8S_ROmnq.js +0 -1
- package/dist/webcomponents/p-8ca21fab.entry.js +0 -1
- package/dist/webcomponents/p-8cebc84b.entry.js +0 -1
- package/dist/webcomponents/p-8f8dfd4b.entry.js +0 -1
- package/dist/webcomponents/p-94237472.entry.js +0 -1
- package/dist/webcomponents/p-9ad7d724.entry.js +0 -1
- package/dist/webcomponents/p-B-iV5cYd.js +0 -1
- package/dist/webcomponents/p-BX8GieXu.js +0 -1
- package/dist/webcomponents/p-BjNuRWXK.js +0 -1
- package/dist/webcomponents/p-BlJnA265.js +0 -1
- package/dist/webcomponents/p-BoQ6_4Ks.js +0 -1
- package/dist/webcomponents/p-C9EQ459H.js +0 -1
- package/dist/webcomponents/p-C9iide2W.js +0 -1
- package/dist/webcomponents/p-CCLgieAN.js +0 -1
- package/dist/webcomponents/p-D0Peuz-m.js +0 -1
- package/dist/webcomponents/p-D6BImiVi.js +0 -1
- package/dist/webcomponents/p-DH8F0bsw.js +0 -1
- package/dist/webcomponents/p-DL-q4EcN.js +0 -1
- package/dist/webcomponents/p-DQZ5VHTZ.js +0 -1
- package/dist/webcomponents/p-DWn9BiNn.js +0 -1
- package/dist/webcomponents/p-DfV3dFDB.js +0 -1
- package/dist/webcomponents/p-Dt-vy9Le.js +0 -1
- package/dist/webcomponents/p-NAjz1Xfo.js +0 -1
- package/dist/webcomponents/p-PSJOKMWp.js +0 -1
- package/dist/webcomponents/p-RQzxYnz_.js +0 -1
- package/dist/webcomponents/p-T2yENPvU.js +0 -1
- package/dist/webcomponents/p-a5c70eee.entry.js +0 -1
- package/dist/webcomponents/p-aa14cc74.entry.js +0 -1
- package/dist/webcomponents/p-ae7054bf.entry.js +0 -1
- package/dist/webcomponents/p-ae8ae5bb.entry.js +0 -1
- package/dist/webcomponents/p-b095c781.entry.js +0 -1
- package/dist/webcomponents/p-b36adce3.entry.js +0 -1
- package/dist/webcomponents/p-b612d870.entry.js +0 -1
- package/dist/webcomponents/p-baf0d3e7.entry.js +0 -1
- package/dist/webcomponents/p-bb53e2e9.entry.js +0 -1
- package/dist/webcomponents/p-be05d450.entry.js +0 -1
- package/dist/webcomponents/p-c089fb5f.entry.js +0 -1
- package/dist/webcomponents/p-ce652ff9.entry.js +0 -1
- package/dist/webcomponents/p-d0a2035f.entry.js +0 -1
- package/dist/webcomponents/p-d1bceac6.entry.js +0 -1
- package/dist/webcomponents/p-d37d752e.entry.js +0 -1
- package/dist/webcomponents/p-d4476052.entry.js +0 -1
- package/dist/webcomponents/p-d7f91c48.entry.js +0 -1
- package/dist/webcomponents/p-d84f0122.entry.js +0 -1
- package/dist/webcomponents/p-e55a161f.entry.js +0 -1
- package/dist/webcomponents/p-e6be4e19.entry.js +0 -1
- package/dist/webcomponents/p-ec9514f8.entry.js +0 -1
- package/dist/webcomponents/p-f11a74c3.entry.js +0 -1
- package/dist/webcomponents/p-f705fc49.entry.js +0 -1
- package/dist/webcomponents/p-f930acaa.entry.js +0 -1
- package/dist/webcomponents/p-fe8c2243.entry.js +0 -1
- package/dist/webcomponents/p-fedfe376.entry.js +0 -1
- package/dist/webcomponents/p-ffefa09c.entry.js +0 -1
- package/dist/webcomponents/p-h5pyZngT.js +0 -1
- package/dist/webcomponents/p-tYuXMkCd.js +0 -1
- package/dist/webcomponents/p-wQgEEOq_.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as i,r as e,H as t}from"./p-DOjVAAtq.js";import{S as a}from"./p-BIcS6lTe.js";import{w as s,c}from"./p-a6tcNl_T.js";import{b as r}from"./p-BS7OgSQe.js";import"./p-Dj_zevuD.js";import"./p-DdMxswn1.js";import"./p-HXpYMWUU.js";const n=e=>{const{isReady:t}=e;return t?null:i("div",{class:"container-fluid p-0"},i("div",{class:"row mb-3"},i("div",{class:"col-12 align-content-end"},i(a,{height:"18px",width:"120px"}),i(a,{height:"36px"}))),i("div",{class:"row"},i("div",{class:"col-12 align-content-end"},i(a,{height:"18px",width:"110px"}),i(a,{height:"36px"}))))},o=class{constructor(i){e(this,i),this.isReady=!1}async componentWillLoad(){await s(),this.iframeOrigin=c.iframeOrigin,this.tabId=r()}componentDidRender(){Promise.all([this.accountNumberIframeElement,this.routingNumberIframeElement].map((i=>new Promise((e=>{i.addEventListener("iframeLoaded",(()=>{e()}))}))))).then((()=>{this.isReady=!0}))}async validate(){const i=await this.accountNumberIframeElement.validate(),e=await this.routingNumberIframeElement.validate();return i&&e}async tokenize(i,e,t){return this.accountNumberIframeElement.tokenize(i,e,t)}render(){return i(t,{key:"1c142c117694002871cfcb0f9c419febda59ee1b"},i(n,{key:"06ee99086ab92d21f098bc266d9a3860cf0cfee3",isReady:this.isReady}),i("div",{key:"f1ff30c399806c07854701c45698ee3b2a4d1492",class:"container-fluid p-0",style:{opacity:this.isReady?"1":"0",height:this.isReady?"auto":"0"}},i("div",{key:"b9225fef945018fea713a58bf0f2d58b24069826",class:"row mb-3"},i("iframe-input",{key:"116526dcaa3325b9f9de8c70f6a0dafdf9ec7ced",inputId:"accountNumber",ref:i=>this.accountNumberIframeElement=i,label:"Account Number",iframeOrigin:`${this.iframeOrigin}/v2/accountNumber?tabId=${this.tabId}`})),i("div",{key:"ef4856499b18125170f6b1117981cab79aa69914",class:"row"},i("iframe-input",{key:"ed3c4988a2eb856450f36ff225a91104f5c10422",inputId:"routingNumber",ref:i=>this.routingNumberIframeElement=i,label:"Routing Number",iframeOrigin:`${this.iframeOrigin}/v2/routingNumber?tabId=${this.tabId}`}))))}};export{o as bank_account_form}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,h as n,H as t,c as i,g as o}from"./p-DOjVAAtq.js";import{c as r}from"./p-DdMxswn1.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-xDbRW9xn.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-NAjz1Xfo.js";import{p as h}from"./p-DL-q4EcN.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:g}=m,b=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();g("fontStyles",e);const n=await this.getFocusedStyles();g("focused",n);const t=await this.getFocusedAndInvalidStyles();g("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"547220ec7d5fec026ca4a3a0c8698ffc1e87d207"},n("input",{key:"dfc3979a87ec4e993e10c010d55d1bebdc0f003f",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){C(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=P(),window.iFrameResize=window.iFrameResize||P()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function g(e,n,t){e.removeEventListener(n,t,!1)}function b(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,b(e))}function v(e,n){x("info",e,n,b(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function z(e){function n(){t("Height"),t("Width"),N((function(){R(W),j(L),l("onResized",W)}),W,"init")}function t(e){var n=Number(u[L]["max"+e]),t=Number(u[L]["min"+e]),i=e.toLowerCase(),o=Number(W[i]);p(L,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(L,"Set "+i+" to min value")),o>n&&(o=n,p(L,"Set "+i+" to max value")),W[i]=""+o}function i(e){return C.slice(C.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;E("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=W.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return M(L),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(W.iframe):{x:0,y:0},t={x:Number(W.width)+n.x,y:Number(W.height)+n.y};p(L,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(L,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(L,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?T():j(L)}function f(e){var n={};if(0===Number(W.width)&&0===Number(W.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:W.width,y:W.height};l(e,{iframe:W.iframe,screenX:Number(n.x),screenY:Number(n.y),type:W.type})}function l(e,n){return I(L,e,n)}var m,b,y,x,z,F,C=e.data,W={},L=null;"[iFrameResizerChild]Ready"===C?function(){for(var e in u)E("iFrame requested init",A(e),u[e].iframe,e)}():a===(""+C).slice(0,13)&&C.slice(13).split(":")[0]in u?(x=(y=C.slice(13).split(":"))[1]?parseInt(y[1],10):0,z=u[y[0]]&&u[y[0]].iframe,F=getComputedStyle(z),W={iframe:z,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(F)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(F),width:y[2],type:y[3]},u[L=W.id]&&(u[L].loaded=!0),(b=W.type in{true:1,false:1,undefined:1})&&p(L,"Ignoring init message from meta parent page"),!b&&function(e){var n=!0;return u[e]||(n=!1,k(W.type+" No settings for "+e+". Message was: "+C)),n}(L)&&(p(L,"Received: "+C),m=!0,null===W.iframe&&(k(L,"IFrame ("+W.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[L]&&u[L].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(L,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(L,"Checking connection is from: "+(n=u[L]&&u[L].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+W.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[L]&&u[L].firstRun&&u[L]&&(u[L].firstRun=!1),W.type){case"close":S(W.iframe);break;case"message":m=i(6),p(L,"onMessage passed: {iframe: "+W.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:W.iframe,message:JSON.parse(m)}),p(L,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[L].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[L]&&u[L].iframe,L),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",g)}var t=L;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[L]&&u[L].stopPageInfo&&(u[L].stopPageInfo(),delete u[L].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(L,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(L,"--")):window.top===window.self?p(L,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(L,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":O(W);break;case"init":n(),l("onInit",W.iframe);break;default:0===Number(W.width)&&0===Number(W.height)?k("Unsupported message received ("+W.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(L,"Ignored: "+C)}function I(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function F(e){delete u[e.id]}function S(e){var t=e.id;if(!1!==I(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}I(t,"onClosed",t),p(t,"--"),F(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function M(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function j(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),T())}function T(){s=null}function O(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),M(e.id),N((function(){R(e),E("reset","reset",e.iframe,e.id)}),e,"reset")}function R(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&E("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),W(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function N(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function E(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))}),u[i].warningTimeout)))}function A(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function C(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=A(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&S(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){E("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&O({iframe:t,height:0,width:0,type:"init"})})),E("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:S.bind(null,u[f].iframe),removeListeners:F.bind(null,u[f].iframe),resize:E.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){E("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){E("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function W(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function L(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),W((function(){H("Tab Visible","resize")}),16))}function H(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&E(e,n,u[t].iframe,t)}))}function P(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),C(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",z),w(window,"resize",(function(){p("window","Trigger event: resize"),W((function(){H("Window resize","resize")}),16)})),w(document,"visibilitychange",L),w(document,"-webkit-visibilitychange",L),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const z=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"ecddfb4d179827cff3373a379a34da18fa1a09e5",class:"form-group d-flex flex-column"},n("div",{key:"b19d2290c3a67433a58f0156bdd88f3eb0dd015f",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"30a49b71d2e590fde1c14294078c38dc424e26b8",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"d485f9ce44de38330a611ccbd6d4569dad8e3790",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"92607fa74dc6564b53616c2985e42cd605719ca4",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"c94856c9b819ad651a69b93f0fea1443003b9054",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{b as hidden_input,z as iframe_input}
|
|
1
|
+
import{r as e,h as n,H as t,c as i,g as o}from"./p-DOjVAAtq.js";import{c as r}from"./p-DdMxswn1.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-Dj_zevuD.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-D9Yus-je.js";import{p as h}from"./p-yiqa5abX.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:b}=m,g=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();b("fontStyles",e);const n=await this.getFocusedStyles();b("focused",n);const t=await this.getFocusedAndInvalidStyles();b("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"3c8f4bc2dac1852fa61e372b0077bfb4883c3b31"},n("input",{key:"f53ad76227d125d411c85ef980a902d0d4e0f91d",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){A(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=P(),window.iFrameResize=window.iFrameResize||P()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function b(e,n,t){e.removeEventListener(n,t,!1)}function g(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,g(e))}function v(e,n){x("info",e,n,g(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function z(e){function n(){t("Height"),t("Width"),C((function(){R(W),j(H),l("onResized",W)}),W,"init")}function t(e){var n=Number(u[H]["max"+e]),t=Number(u[H]["min"+e]),i=e.toLowerCase(),o=Number(W[i]);p(H,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(H,"Set "+i+" to min value")),o>n&&(o=n,p(H,"Set "+i+" to max value")),W[i]=""+o}function i(e){return A.slice(A.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;E("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=W.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return M(H),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(W.iframe):{x:0,y:0},t={x:Number(W.width)+n.x,y:Number(W.height)+n.y};p(H,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(H,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(H,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?T():j(H)}function f(e){var n={};if(0===Number(W.width)&&0===Number(W.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:W.width,y:W.height};l(e,{iframe:W.iframe,screenX:Number(n.x),screenY:Number(n.y),type:W.type})}function l(e,n){return I(H,e,n)}var m,g,y,x,z,F,A=e.data,W={},H=null;"[iFrameResizerChild]Ready"===A?function(){for(var e in u)E("iFrame requested init",N(e),u[e].iframe,e)}():a===(""+A).slice(0,13)&&A.slice(13).split(":")[0]in u?(x=(y=A.slice(13).split(":"))[1]?parseInt(y[1],10):0,z=u[y[0]]&&u[y[0]].iframe,F=getComputedStyle(z),W={iframe:z,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(F)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(F),width:y[2],type:y[3]},u[H=W.id]&&(u[H].loaded=!0),(g=W.type in{true:1,false:1,undefined:1})&&p(H,"Ignoring init message from meta parent page"),!g&&function(e){var n=!0;return u[e]||(n=!1,k(W.type+" No settings for "+e+". Message was: "+A)),n}(H)&&(p(H,"Received: "+A),m=!0,null===W.iframe&&(k(H,"IFrame ("+W.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[H]&&u[H].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(H,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(H,"Checking connection is from: "+(n=u[H]&&u[H].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+W.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[H]&&u[H].firstRun&&u[H]&&(u[H].firstRun=!1),W.type){case"close":S(W.iframe);break;case"message":m=i(6),p(H,"onMessage passed: {iframe: "+W.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:W.iframe,message:JSON.parse(m)}),p(H,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[H].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[H]&&u[H].iframe,H),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",b)}var t=H;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[H]&&u[H].stopPageInfo&&(u[H].stopPageInfo(),delete u[H].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(H,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(H,"--")):window.top===window.self?p(H,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(H,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":O(W);break;case"init":n(),l("onInit",W.iframe);break;default:0===Number(W.width)&&0===Number(W.height)?k("Unsupported message received ("+W.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(H,"Ignored: "+A)}function I(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function F(e){delete u[e.id]}function S(e){var t=e.id;if(!1!==I(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}I(t,"onClosed",t),p(t,"--"),F(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function M(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function j(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),T())}function T(){s=null}function O(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),M(e.id),C((function(){R(e),E("reset","reset",e.iframe,e.id)}),e,"reset")}function R(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&E("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),W(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function C(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function E(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))}),u[i].warningTimeout)))}function N(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function A(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=N(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&S(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){E("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&O({iframe:t,height:0,width:0,type:"init"})})),E("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:S.bind(null,u[f].iframe),removeListeners:F.bind(null,u[f].iframe),resize:E.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){E("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){E("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function W(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function H(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),W((function(){L("Tab Visible","resize")}),16))}function L(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&E(e,n,u[t].iframe,t)}))}function P(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),A(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",z),w(window,"resize",(function(){p("window","Trigger event: resize"),W((function(){L("Window resize","resize")}),16)})),w(document,"visibilitychange",H),w(document,"-webkit-visibilitychange",H),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const z=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"4782aa46a4967ef9097809122cfea52cf5845675",class:"form-group d-flex flex-column"},n("div",{key:"adf5212bb0a32d593fb9e5ea93a378a49a63ba5b",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"309cb76edb80f3fca7264a5a1f2d2c8397c8b0f4",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"0f19c6d4f1851a6655e765f3ac021313c72ee106",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"f0db24e9a41fc5bcb06d84f0b5c7d0a9adea87b1",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"0e0c98836f067f78af85e124a96dce7b39cf4b27",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{g as hidden_input,z as iframe_input}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as r}from"./p-DOjVAAtq.js";import{A as o}from"./p-ty1sI-fI.js";import{C as i,a as e}from"./p-Cjcsf8ku.js";import"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{g as a,a as n}from"./p-D2muobcE.js";import{E as p}from"./p-DSCBoCn-.js";import{c as h,J as c}from"./p-DfsX5bt_.js";import"./p-a6tcNl_T.js";import"./p-DdMxswn1.js";import"./p-BS7OgSQe.js";import"./p-HXpYMWUU.js";import"./p-Dj_zevuD.js";import"./p-yiqa5abX.js";const m=o();class u{async fetchGrossVolumeChartData(t,s){return m.get({endpoint:`account/${t}/reports/gross_volume`,authToken:s})}}const d=class{constructor(r){t(this,r),this.errorEvent=s(this,"error-event"),this.errorMessage=null,this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)}}componentWillLoad(){h(),this.analytics=new c(this),this.initializeGetGrossPayment()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetGrossPayment()}initializeGetGrossPayment(){this.accountId&&this.authToken?this.getGrossPayment=(({id:t,authToken:s,service:r})=>async({onSuccess:o,onError:e})=>{var p;try{const h=await r.fetchGrossVolumeChartData(t,s);h.error?e({error:n(h.error),code:a(null===(p=h.error)||void 0===p?void 0:p.code),severity:i.ERROR}):o(h.data)}catch(t){const s=a(null==t?void 0:t.code);e({error:n(t),code:s,severity:i.ERROR})}})({id:this.accountId,authToken:this.authToken,service:new u}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:e.MISSING_PROPS,message:this.errorMessage,severity:i.ERROR}))}render(){return this.errorMessage?p(this.errorMessage):r("gross-payment-chart-core",{getGrossPayment:this.getGrossPayment,"onError-event":this.handleErrorEvent})}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{d as justifi_gross_payment_chart}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as a,H as i}from"./p-DOjVAAtq.js";import{I as e}from"./p-Ce_F4E0f.js";import{C as r}from"./p-CVaOFfrI.js";import{a4 as h,l as o,V as c,b as n,U as l,a as f}from"./p-Dj_zevuD.js";import{F as d}from"./p-Dy3-IlQ3.js";import{F as p}from"./p-D9Yus-je.js";import"./p-CZfYo5-1.js";const m=class{constructor(a){t(this,a),this.formControlInput=s(this,"formControlInput"),this.formControlBlur=s(this,"formControlBlur"),this.imask=null,this.isFocused=!1,this.maskOptions=r.DECIMAL,this.initializeIMask=()=>{this.textInput&&(this.imask=e(this.textInput,this.maskOptions),this.imask.on("accept",(()=>{const t=this.imask.unmaskedValue;this.inputHandler(this.name,t),this.formControlInput.emit({name:this.name,value:t})})),this.textInput.addEventListener("blur",(()=>this.formControlBlur.emit())))},this.handleFormControlInput=t=>{const s=t.target.getAttribute("name");this.formControlInput.emit({name:s,value:this.imask.unmaskedValue})},this.updateInput=t=>{this.imask&&(this.imask.value=String(t))}}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.initializeIMask(),this.updateInput(this.defaultValue)}disconnectedCallback(){var t;null===(t=this.imask)||void 0===t||t.destroy()}get inputPart(){let t=h;return this.errorText&&(t=n),this.disabled&&(t=l),this.isFocused&&(t=f),t}render(){return a(i,{key:"12d04cf0bc1dbc85acd1006148c411e00941ab70"},a("div",{key:"08d92fd3c4c764295cf291fc983f63ab58e4312e",class:"form-group d-flex flex-column"},a("label",{key:"1c7bddbfc094535558b24d3988dafe91f0cbde0a",part:o,class:"form-label",htmlFor:this.name},this.label),a("div",{key:"a1dfb4ab2de228f7ad138c12eb37403e9578c001",class:"input-group"},a("span",{key:"94e9009f2a6c782798dccaf6dfae472391f43078",class:"input-group-text",part:c},"$"),a("input",{key:"ebbc696bc1b695d20a758039465ae37a66be974a",ref:t=>this.textInput=t,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.inputPart,class:this.errorText?"form-control monetary is-invalid":"form-control monetary",type:"text",disabled:this.disabled})),a(d,{key:"58f0977b34ab42051b1d4af9e5754d57d60e2fb5",helpText:this.helpText,name:this.name}),a(p,{key:"b3cdaa58f30edb185e2c89bca5d02a86c52cc8d0",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{m as form_control_monetary_provisioning}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as i}from"./p-DOjVAAtq.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{C as o,a as r}from"./p-Cjcsf8ku.js";import{C as e}from"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{g as c,a}from"./p-D2muobcE.js";import{c as n,J as p}from"./p-DfsX5bt_.js";import{C as h}from"./p-B9MN_vv4.js";import{m,S as u}from"./p-CTAOJGVx.js";import{S as d}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{d as j}from"./p-F6TcNeK4.js";import"./p-DdMxswn1.js";import"./p-BS7OgSQe.js";import"./p-yiqa5abX.js";import"./p-ty1sI-fI.js";import"./p-Bm8T-MOQ.js";import"./p-Dj_zevuD.js";const f=class{constructor(i){t(this,i),this.errorEvent=s(this,"error-event"),this.errorMessage=null,this.columns=j,this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)}}componentWillLoad(){n(),this.analytics=new p(this),this.initializeGetData()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetData()}initializeGetData(){this.initializeGetCheckouts(),this.initializeGetSubAccounts()}initializeGetCheckouts(){this.accountId&&this.authToken?this.getCheckouts=(({accountId:t,authToken:s,service:i})=>async({params:r,onSuccess:n,onError:p})=>{var h,m;try{const u=await i.fetchCheckouts(t,s,r);if(u.error)return p({error:a(u.error),code:c(null===(m=u.error)||void 0===m?void 0:m.code),severity:o.ERROR});{const t=Object.assign({},u.page_info);n({checkouts:(null===(h=u.data)||void 0===h?void 0:h.map((t=>new e(t))))||[],pagingInfo:t})}}catch(t){const s=c(null==t?void 0:t.code);return p({error:t.message||t,code:s,severity:o.ERROR})}})({accountId:this.accountId,authToken:this.authToken,service:new h}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:r.MISSING_PROPS,message:this.errorMessage,severity:o.ERROR}))}initializeGetSubAccounts(){this.accountId&&this.authToken&&(this.getSubAccounts=m({accountId:this.accountId,authToken:this.authToken,service:new u}))}render(){return i(d,{key:"f20c74e616c92115985587dc56d6ef62e86fbf02"},i("checkouts-list-core",{key:"e3afd6af4d8db35f4119d93cc550a1827e1d52cb",getCheckouts:this.getCheckouts,getSubAccounts:this.getSubAccounts,"onError-event":this.handleErrorEvent,columns:this.columns}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{f as justifi_checkouts_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as e}from"./p-DOjVAAtq.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import"./p-CPKSE7M4.js";import{p as i}from"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{T as a,a as r,b as h,c,d as o,e as n,f as p,g as d,h as u,i as b,j as m,k as f,l as g}from"./p-UUJudj_5.js";import{T as j}from"./p-CZfYo5-1.js";import{c as y,a as k}from"./p-F6TcNeK4.js";import{o as l,g as C}from"./p-lKnUT24T.js";import"./p-DdMxswn1.js";import"./p-BS7OgSQe.js";import"./p-Dj_zevuD.js";import"./p-CVtpEQBE.js";import"./p-Bm8T-MOQ.js";const S=class{constructor(e){t(this,e),this.clickEvent=s(this,"click-event"),this.errorEvent=s(this,"error-event"),this.checkouts=[],this.subAccounts=[],this.loading=!0,this.paging=i,this.pagingParams={},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:j.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:j.next})},this.rowClickHandler=t=>{const s=t.target.closest("tr").dataset.rowEntityId;if(!s)return;const e=this.checkouts.find((t=>t.id===s));this.clickEvent.emit({name:j.row,data:e})}}updateOnPropChange(){this.fetchData()}componentWillLoad(){this.checkoutsTable=new a(this.checkouts,this.columns,y,k),this.getCheckouts&&this.getSubAccounts&&this.fetchData(),l("set",(()=>{this.pagingParams={}})),l("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}fetchData(){this.loading=!0,this.getCheckouts({params:this.checkoutParams,onSuccess:async({checkouts:t,pagingInfo:s})=>{this.checkouts=t,this.paging=s,this.checkoutsTable.collectionData=this.checkouts,this.checkoutsTable.columnKeys.includes("sub_account_name")?await this.fetchSubAccounts():this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}async fetchSubAccounts(){this.getSubAccounts({params:this.subAccountParams,onSuccess:({subAccounts:t})=>{this.subAccounts=t,this.checkouts=this.checkouts.map((t=>{var s;return t.sub_account_name=null===(s=this.subAccounts.find((s=>s.id===t.account_id)))||void 0===s?void 0:s.name,t})),this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}get checkoutParams(){const t=C();return Object.assign(Object.assign({},t),this.pagingParams)}get subAccountParams(){let t=this.checkouts.map((t=>t.account_id));return{sub_account_id:[...new Set(t)].join(",")}}get entityId(){return this.checkouts.map((t=>t.id))}get showEmptyState(){return!this.loading&&!this.errorMessage&&this.checkoutsTable.rowData.length<1}get showErrorState(){return!this.loading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.loading}render(){return e(g,{key:"a227a356ba08e39e4b60849d8615a5b1cd845739"},e(r,{key:"51b96d4be5773975397eadfc6c3c0ec983bdb38f"},e(h,{key:"868cf524b90bcc2671fc487dc5c7f9c71756d24f"},e(c,{key:"3bc7b727e4e3c8f0a61b55993c965779c0fac73b"},this.checkoutsTable.columnData.map((t=>t)))),e(o,{key:"06adebe1455360d37d3eed7a27af2698b35047b4"},e(n,{key:"241f49bd2ed6d3548e286de8f75f1cc92ffae23f",columnSpan:this.checkoutsTable.columnKeys.length,isLoading:this.loading}),e(p,{key:"9739415d15f73457aa5125c85be88566e70d233b",isEmpty:this.showEmptyState,columnSpan:this.checkoutsTable.columnKeys.length}),e(d,{key:"43b1fa74ba01c89b2d22fc238295c343bf6379b6",columnSpan:this.checkoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.checkoutsTable.rowData.map(((t,s)=>e(u,{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},t)))),this.paging&&e(b,{key:"3a4b974a07bbe7d0fe246ad93724be2bec449166"},e(m,{key:"6ec16663674ea87026fc3400d164fa2d9907c35a"},e(f,{key:"1eb2943ba2e6885a1a520430eb257e7499553c80",colSpan:this.checkoutsTable.columnData.length},e("pagination-menu",{key:"d4719b9e2166d0577e620a5575303294127833a9",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})}))))))}static get watchers(){return{pagingParams:["updateOnPropChange"],getCheckouts:["updateOnPropChange"],getSubAccounts:["updateOnPropChange"],columns:["updateOnPropChange"]}}};export{S as checkouts_list_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as s,H as i}from"./p-DOjVAAtq.js";import{I as a}from"./p-Ce_F4E0f.js";import{b as d,U as o,a as r,c as l,l as c}from"./p-Dj_zevuD.js";import{F as n}from"./p-D9Yus-je.js";import"./p-CZfYo5-1.js";import{C as h}from"./p-B5rtFhtR.js";import{n as f}from"./p-BnjCmwMr.js";import{b as u,c as b}from"./p-DfKxeSrC.js";const m=class{constructor(s){e(this,s),this.formControlInput=t(this,"formControlInput"),this.formControlBlur=t(this,"formControlBlur"),this.imask=null,this.isFocused=!1,this.initializeIMask=()=>{this.textInput&&(this.imask=a(this.textInput,{mask:this.mask}),this.imask.on("accept",(()=>{var e;const t=null===(e=this.imask)||void 0===e?void 0:e.unmaskedValue;void 0!==t&&this.inputHandler(this.name,t)})),this.textInput.addEventListener("blur",(()=>this.formControlBlur.emit())))},this.handleFormControlInput=e=>{var t;const s=e.target,i=s.getAttribute("name"),a=(null===(t=this.imask)||void 0===t?void 0:t.unmaskedValue)||s.value;this.formControlInput.emit({name:i,value:a})},this.updateInput=e=>{this.imask&&e&&(this.imask.value=String(e))}}handleDefaultValueChange(e){this.initializeIMask(),this.updateInput(e)}disconnectedCallback(){var e;null===(e=this.imask)||void 0===e||e.destroy()}componentDidLoad(){this.textInput&&(this.initializeIMask(),this.updateInput(this.defaultValue))}get part(){return this.errorText?d:this.disabled?o:this.isFocused?r:l}render(){return s(i,{key:"df43b2ce1fa351d04852fbc8a93ee14eeacab874"},s("div",{key:"e3b22cde550073e8ccac88ce2f6a0533cae6d781",class:"form-group d-flex flex-column"},s("div",{key:"c42151be8f9311c197a972dd5d0c15e09b884690",class:"d-flex align-items-start gap-2"},s("label",{key:"603866f6c5202290c07490a7a3303b1fce13e375",part:c,class:"form-label",htmlFor:this.name},this.label),s("form-control-tooltip",{key:"878b2797d1acb8030f5881c47f08c647e605b335",helpText:this.helpText})),s("input",{key:"04e22f86c574d85190c55ee828c4df02c4652b91",ref:e=>this.textInput=e,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",type:"text",disabled:this.disabled}),s(n,{key:"57b6c4a907ae8089981faaf2359a8120963d875f",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},v=class{constructor(t){e(this,t),this.country=h.USA}render(){var e,t,a,d,o,r,l,c,n,m;const v=b[this.country],p=u[this.country];return s(i,{key:"429dd1250553f6d25f9db6d6c1379af0290718c6"},s("div",{key:"91b9d7199bea1620c7614efd25c0421d3f85c19d",class:"row gy-3"},s("div",{key:"13dd91b17d387ef9c8bc97b44a273f0984758a3a",class:"col-12"},s("form-control-text",{key:"52ecc715696aed27a6f4329971e90e90ebb971fa",name:"line1",label:"Street Address",inputHandler:this.inputHandler,defaultValue:null===(e=this.defaultValues)||void 0===e?void 0:e.line1,errorText:null===(t=this.errors)||void 0===t?void 0:t.line1,helpText:"No PO Boxes."})),s("div",{key:"64bc39361d02b10c75dfc8389915ce192b9f7606",class:"col-12"},s("form-control-text",{key:"a835f2f9706664dd195daa5436fe49aea2c54968",name:"line2",label:"Address Line 2 (optional)",inputHandler:this.inputHandler,defaultValue:null===(a=this.defaultValues)||void 0===a?void 0:a.line2,errorText:null===(d=this.errors)||void 0===d?void 0:d.line2})),s("div",{key:"ef9b02103d0d1469da092d8965d021b049e54cb5",class:"col-12"},s("form-control-text",{key:"9263360f47c6e833a904aab2e8b30d4a35d50e75",name:"city",label:"City",inputHandler:this.inputHandler,defaultValue:null===(o=this.defaultValues)||void 0===o?void 0:o.city,errorText:null===(r=this.errors)||void 0===r?void 0:r.city})),s("div",{key:"4609534e39659ed47350e68a64fee58616320da4",class:"col-12"},s("form-control-select",{key:"a7f94fa5ea2642cae82729951198771fd1f31380",name:"state",label:v.stateLabel,options:p.stateOptions,inputHandler:this.inputHandler,defaultValue:null===(l=this.defaultValues)||void 0===l?void 0:l.state,errorText:null===(c=this.errors)||void 0===c?void 0:c.state})),s("div",{key:"eadf0a6e2e2cfbe8e476ba8abb25eab4b2b005fb",class:"col-12"},s("form-control-text",{key:"2708d2a47c8afccc470203775d494683f133174b",name:"postal_code",label:v.postalLabel,inputHandler:this.inputHandler,defaultValue:null===(n=this.defaultValues)||void 0===n?void 0:n.postal_code,errorText:null===(m=this.errors)||void 0===m?void 0:m.postal_code,maxLength:this.country===h.USA?5:7,keyDownHandler:this.country===h.USA?f:void 0}))))}},p=class{constructor(t){e(this,t),this.address={},this.inputHandler=(e,t)=>{this.address[e]=t,this.address=Object.assign({},this.address)}}handleAddressChange(e){this.handleFormUpdate(e)}render(){return s(i,{key:"c9b75fa8c884fb755cd26be4433022f278794e4e"},s("justifi-form-address-fields",{key:"2f9cfa3fc695de214d9203c680e6cb115d714b82",country:this.country,errors:this.errors,defaultValues:this.defaultValues,inputHandler:this.inputHandler}))}static get watchers(){return{address:["handleAddressChange"]}}};export{m as form_control_number_masked,v as justifi_form_address_fields,p as justifi_identity_address_form}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as e,c as a}from"./p-DOjVAAtq.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{C as s,a as i}from"./p-Cjcsf8ku.js";import{g as n}from"./p-CPKSE7M4.js";import{p as r}from"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{c as o,J as c}from"./p-DfsX5bt_.js";import{g as p,a as h}from"./p-D2muobcE.js";import{P as d}from"./p-DqPvh0aN.js";import{T as f,l,a as u,b as m,c as y,d as b,e as _,f as j,g,h as T,i as k,j as w,k as v}from"./p-UUJudj_5.js";import{S as C}from"./p-BhCH9S0e.js";import{T as D}from"./p-CZfYo5-1.js";import{a as S}from"./p-BS7OgSQe.js";import{S as E,T as F}from"./p-Dj_zevuD.js";import"./p-DdMxswn1.js";import"./p-yiqa5abX.js";import"./p-ty1sI-fI.js";import"./p-CVtpEQBE.js";const I={created_at:()=>t("th",{part:E,scope:"col",title:"The date and time each transaction was made"},"Processed On"),type:()=>t("th",{part:E,scope:"col",title:"The type of each transaction"},"Type"),id:()=>t("th",{part:E,scope:"col",title:"The unique identifier of each transaction"},"ID"),amount:()=>t("th",{part:E,scope:"col",title:"The dollar amount of each transaction",class:"text-end"},"Amount"),balance:()=>t("th",{part:E,scope:"col",title:"The running total amount of this payment that belongs to you",class:"text-end"},"Balance"),currency:()=>t("th",{part:E,scope:"col",title:"The currency of each transaction"},"Currency"),financial_transaction_id:()=>t("th",{part:E,scope:"col",title:"The unique identifier of the financial transaction associated with the payment balance transaction"},"Financial Transaction ID"),payment_id:()=>t("th",{part:E,scope:"col",title:"The unique identifier of the payment associated with the payment balance transaction"},"Payment ID"),payment_balance_txn_type:()=>t("th",{part:E,scope:"col",title:"The type of the payment balance transaction"},"Transaction Type"),source_id:()=>t("th",{part:E,scope:"col",title:"The unique identifier of the source object associated with the payment balance transaction"},"Source ID"),source_type:()=>t("th",{part:E,scope:"col",title:"The type of the source object associated with the payment balance transaction"},"Source Type")},R={ach_return:"ACH Return",ach_return_fee:"ACH Return Fee",dispute:"Dispute",dispute_fee:"Dispute Fee",dispute_fee_refund:"Dispute Fee Refund",dispute_refund:"Dispute Refund",payment:"Payment",payment_fee:"Fee",refund:"Refund",fee_refund:"Fee Refund",application_fee_returned:"Application Fee Returned",refund_failure:"Refund Failure",void:"Void"},x={created_at:(e,a)=>t("td",{part:F(a)},t("div",{class:"fw-bold"},S(e.created_at,{showDisplayDate:!0})),t("div",{class:"fw-bold"},S(e.created_at,{showTime:!0}))),type:(e,a)=>t("td",{part:F(a)},R[e.payment_balance_txn_type]),id:(e,a)=>t("td",{part:F(a)},e.id),amount:(e,a)=>t("td",{part:F(a),class:"text-end"},e.formattedPaymentAmount(e.amount)),balance:(e,a)=>t("td",{part:F(a),class:"text-end"},e.formattedPaymentAmount(e.balance)),currency:(e,a)=>t("td",{part:F(a)},e.currency),financial_transaction_id:(e,a)=>t("td",{part:F(a)},e.financial_transaction_id),payment_id:(e,a)=>t("td",{part:F(a)},e.payment_id),payment_balance_txn_type:(e,a)=>t("td",{part:F(a)},e.payment_balance_txn_type),source_id:(e,a)=>t("td",{part:F(a)},e.source_id),source_type:(e,a)=>t("td",{part:F(a)},e.source_type)},q=class{constructor(t){e(this,t),this.clickEvent=a(this,"click-event"),this.errorEvent=a(this,"error-event"),this.balanceTransactions=[],this.isLoading=!0,this.errorMessage=null,this.paging=r,this.pagingParams={},this.columns="created_at,type,id,amount,balance",this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:D.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:D.next})},this.rowClickHandler=t=>{const e=t.target.closest("tr").dataset.rowEntityId;if(!e)return;const a=this.balanceTransactions.find((t=>t.id===e));this.clickEvent.emit({name:D.row,data:a})}}componentWillLoad(){this.transactionsTable=new f(this.balanceTransactions,this.columns,I,x),o(),this.analytics=new c(this),this.initializeApi()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeApi()}handleError(t,e,a){this.isLoading=!1,this.errorEvent.emit({errorCode:t,message:e,severity:a})}initializeApi(){this.paymentId&&this.authToken?(({id:t,authToken:e,service:a})=>async({params:i,onSuccess:r,onError:o,final:c})=>{var d;try{const c=await a.fetchPaymentTransactions(t,e,i);c.error?o({error:h(c.error),code:p(null===(d=c.error)||void 0===d?void 0:d.code),severity:s.ERROR}):r({balanceTransactions:c.data.map((t=>new n(t))),pagingInfo:Object.assign({},c.page_info)})}catch(t){const e=p(null==t?void 0:t.code);o({error:h(t),code:e,severity:s.ERROR})}finally{c()}})({id:this.paymentId,authToken:this.authToken,service:new d})({params:this.pagingParams,onSuccess:({balanceTransactions:t,pagingInfo:e})=>{this.balanceTransactions=t,this.paging=e,this.transactionsTable.collectionData=this.balanceTransactions},onError:({error:t,code:e,severity:a})=>{this.errorMessage=t.message,this.handleError(t,e,a)},final:()=>{this.isLoading=!1}}):(this.errorMessage="payment-id and auth-token props are required",this.handleError(i.MISSING_PROPS,this.errorMessage,s.ERROR))}get entityId(){return this.balanceTransactions.map((t=>t.id))}get showEmptyState(){return!this.isLoading&&!this.errorMessage&&this.transactionsTable.rowData.length<1}get showErrorState(){return!this.isLoading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.isLoading}render(){return t(C,{key:"f5a7946c22e065b9fb73c42f2e8bd338fe9f5b75"},t(l,{key:"3cac49cde086dc78b15583ab2725a6196987c123"},t(u,{key:"7588b31adad3bd0804a95a61e656af24faf21857"},t(m,{key:"56d2e0f7b65f621e23db4f04b1768427553d077b"},t(y,{key:"7be2399aa3dda6337c94e4e9d95e1d1d73b0702e"},this.transactionsTable.columnData.map((t=>t)))),t(b,{key:"e30961bb03921a1cb491c7fcd09df51eafbad3a6"},t(_,{key:"c26d53a4901ce5e3e42ff05ad627f08020a7a71c",columnSpan:this.transactionsTable.columnKeys.length,isLoading:this.isLoading}),t(j,{key:"5ed524b2d07316bad2814328f02ddefe1f263fc6",isEmpty:this.showEmptyState,columnSpan:this.transactionsTable.columnKeys.length}),t(g,{key:"99cf81edbf8fde0cf96c55f62bd9dca3342d958d",columnSpan:this.transactionsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.transactionsTable.rowData.map(((e,a)=>t(T,{"data-test-id":"table-row","data-row-entity-id":this.entityId[a],onClick:this.rowClickHandler},e)))),this.paging&&t(k,{key:"816ce49013c603d64af1b8534e062df6dabde41b"},t(w,{key:"96786a7547c39275184c44d7da55069802ca8c22"},t(v,{key:"204328804873c7ff440cbeb889948dc0365d508c",colSpan:this.transactionsTable.columnData.length},t("pagination-menu",{key:"4a4ecc86248e59d8e5cf3982a49abf514fe073a8",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})})))))))}static get watchers(){return{pagingParams:["propChanged"],paymentId:["propChanged"],authToken:["propChanged"]}}};export{q as justifi_payment_transactions_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as e,H as a}from"./p-DOjVAAtq.js";import{b as i,U as o,a as r,c as h,l as f,V as n}from"./p-Dj_zevuD.js";import{F as d}from"./p-Dy3-IlQ3.js";import{F as l}from"./p-D9Yus-je.js";import"./p-CZfYo5-1.js";import{f as c}from"./p-BS7OgSQe.js";import"./p-HXpYMWUU.js";const p=class{constructor(e){t(this,e),this.formControlInput=s(this,"formControlInput"),this.formControlBlur=s(this,"formControlBlur"),this.isFocused=!1,this.defaultValue="0",this.formatRawValue=t=>t.replace(/\D/g,""),this.formatDisplayValue=t=>c(+t,void 0,!0),this.updateInput=t=>{const s=this.formControl.name,e=this.formatRawValue(t);this.formControl.value=this.formatDisplayValue(e),this.inputHandler(s,e),this.formControlInput.emit({name:s,value:e})}}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get inputPart(){return this.errorText?i:this.disabled?o:this.isFocused?r:h}render(){return e(a,{key:"befed81330399d097413f8b769d01df6b315d707"},e("div",{key:"570688783902a60e43689dc542e69008d52ee376",class:"form-group d-flex flex-column"},e("label",{key:"0def0a1b40891a7f6ca3d8886e0b32197beab464",part:f,class:"form-label",htmlFor:this.name},this.label),e(d,{key:"637edfe671dabaed1b82ce8f2b165ca2a574522b",name:this.name,helpText:this.helpText}),e("div",{key:"6b38281e577bfb6f8dfacc29574a3b0cb9183c56",class:"input-group"},e("span",{key:"63d1f8596630e7f3922e02f099b9298ff83bb487",class:"input-group-text",part:n},"$"),e("input",{key:"a23391ec4ede5bd11d7d2e552eac76544aa855ae",ref:t=>this.formControl=t,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:t=>this.updateInput(t.target.value),onKeyDown:this.keyDownHandler,onPaste:this.keyDownHandler,maxLength:this.maxLength,part:this.inputPart,class:this.errorText?"form-control is-invalid":"form-control",type:"text",disabled:this.disabled})),e(l,{key:"5f8175edeff6bc80c9f2fb815d89205d69b413a3",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{p as form_control_monetary}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as s,c as e}from"./p-DOjVAAtq.js";import{a as i,c as r,b as o}from"./p-C6g4MbnB.js";import{F as n,c as a,a as h,b as l}from"./p-DiJD6Iqx.js";import{A as c,C as d,e as u,R as m,f as p}from"./p-B5rtFhtR.js";import{C as f,P as b}from"./p-CVaOFfrI.js";import{G as v,l as y,U as g,_}from"./p-Dj_zevuD.js";import{S as w}from"./p-BIcS6lTe.js";import"./p-CZfYo5-1.js";import{b as j,r as x,s as O,c as k}from"./p-CPpUGsw5.js";import{a as C,B as S}from"./p-XYgDHrVL.js";import{E as T,l as D,m as E}from"./p-CPKSE7M4.js";import{B as L,C as B,z as H,D as P,E as V,F as A,G as W}from"./p-DxVCqvBt.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{C as I,a as F}from"./p-Cjcsf8ku.js";import"./p-CLHwhyvu.js";import"./p-BH0Xfn-F.js";import{c as q}from"./p-DfKxeSrC.js";import{B as U}from"./p-CJ9qo7_g.js";import{d as M,e as R}from"./p-DzWLLt4t.js";import"./p-BFTU3MAI.js";import"./p-BS7OgSQe.js";import"./p-DdMxswn1.js";class Y{constructor(t){this.id=t.id,this.account_owner_name=t.account_owner_name,this.full_name=t.full_name,this.account_type=t.account_type,this.account_number=t.account_number,this.acct_last_four=t.acct_last_four,this.account_number_last4=t.account_number_last4,this.routing_number=t.routing_number,this.institution_number=t.institution_number,this.transit_number=t.transit_number,this.bank_name=t.bank_name,this.country=t.country,this.currency=t.currency,this.nickname=t.nickname,this.metadata=t.metadata,this.business_id=t.business_id,this.platform_account_id=t.platform_account_id,this.created_at=t.created_at,this.updated_at=t.updated_at}get payload(){return{account_owner_name:this.account_owner_name||"",account_type:this.account_type||"",account_number:this.account_number||"",routing_number:this.routing_number||"",institution_number:this.institution_number||"",transit_number:this.transit_number||"",bank_name:this.bank_name||"",nickname:this.nickname||"",business_id:this.business_id||""}}}const G=()=>t("div",{class:"row gap-3"},t("div",{class:"col-12"},t(w,{width:"25%"})),t("div",{class:"col-12"},t(w,{width:"100%"})),t("div",{class:"col-12 d-flex gap-3"},t(w,{width:"50%"}),t(w,{width:"50%"})),t("div",{class:"col-12 d-flex gap-3"},t(w,{width:"65%"}),t(w,{width:"35%"}))),N=()=>t("div",{class:"row gap-5"},t("div",{class:"col-12"},t(w,{width:"40%",height:"40px"})),t(G,null),t(G,null),t(G,null)),X=class{constructor(t){s(this,t),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.errors={},this.additional_questions={},this.recurringPayments=!1,this.isLoading=!1,this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.additional_questions=new c(t.data.additional_questions||{}),this.formController.setInitialValues(Object.assign({},this.additional_questions))},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=t=>{let s;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{s=e,t()},onError:({error:t,code:e,severity:i})=>{s=t,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:C.additionalQuestions}),this.formLoading.emit(!1)}})},this.inputHandler=(t,s)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s})),this.additional_questions=new c(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s}))}}recurringPaymentsWatcher(t){this.recurringPayments="Yes"===(null==t?void 0:t.business_recurring_payments)}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return{additional_questions:new c(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new n(i(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}render(){var s,e,i,r,o,n,a;const h=this.formController.getInitialValues();return this.isLoading?t(N,null):t("form",null,t("fieldset",null,t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Additional Questions"),t("form-control-tooltip",{helpText:"This information helps us understand the business and identify and monitor trends to safeguard you and your customers."})),t("hr",{class:"mt-2"}),t("div",{class:"row gy-3"},t("div",{class:"col-12 col-md-6"},t("form-control-monetary-provisioning",{name:"business_revenue",label:"What is your business’ estimated annual revenue from its primary business activities?",inputHandler:this.inputHandler,errorText:null===(s=this.errors)||void 0===s?void 0:s.business_revenue,defaultValue:null==h?void 0:h.business_revenue,maskOptions:f.WHOLE})),t("div",{class:"col-12 col-md-6"},t("form-control-monetary-provisioning",{name:"business_payment_volume",label:"What is your business' annual credit card & ACH volume anticipated to process?",inputHandler:this.inputHandler,errorText:null===(e=this.errors)||void 0===e?void 0:e.business_payment_volume,defaultValue:null==h?void 0:h.business_payment_volume,maskOptions:f.WHOLE})),t("div",{class:"col-12"},t("form-control-select",{name:"business_when_service_received",label:"On average, how long after paying will your customers typically receive their goods or services?",inputHandler:this.inputHandler,errorText:null===(i=this.errors)||void 0===i?void 0:i.business_when_service_received,options:j,defaultValue:null==h?void 0:h.business_when_service_received})),t("div",{class:"col-12"},t("form-control-select",{name:"business_recurring_payments",label:"Does your business offer recurring payments?",inputHandler:this.inputHandler,errorText:null===(r=this.errors)||void 0===r?void 0:r.business_recurring_payments,options:x,defaultValue:null==h?void 0:h.business_recurring_payments})),t("div",{class:"col-12",hidden:!this.recurringPayments},t("form-control-text",{name:"business_recurring_payments_percentage",label:"What percent of revenue is generated from each recurring payment type offered?",inputHandler:this.inputHandler,errorText:null===(o=this.errors)||void 0===o?void 0:o.business_recurring_payments_percentage,defaultValue:null==h?void 0:h.business_recurring_payments_percentage,helpText:"For example: 50% monthly, 50% annual."})),t("div",{class:"col-12"},t("form-control-select",{name:"business_seasonal",label:"Is this business seasonal?",inputHandler:this.inputHandler,errorText:null===(n=this.errors)||void 0===n?void 0:n.business_seasonal,options:O,defaultValue:null==h?void 0:h.business_seasonal})),t("div",{class:"col-12"},t("form-control-text",{name:"business_other_payment_details",label:"Is there anything else you would like us to know about how your customers pay the business? (optional)",inputHandler:this.inputHandler,errorText:null===(a=this.errors)||void 0===a?void 0:a.business_other_payment_details,defaultValue:null==h?void 0:h.business_other_payment_details})))))}static get watchers(){return{additional_questions:["recurringPaymentsWatcher"]}}},z=(t,s)=>t.some((t=>t.document_type===s)),J=t=>t?{bank_name:V.nullable(),nickname:P.nullable(),account_owner_name:H.nullable(),account_type:B.nullable(),account_number:L.nullable()}:{bank_name:V.required("Enter bank name"),nickname:P.required("Enter nickname"),account_owner_name:H.required("Enter account owner name"),account_type:B.required("Select account type"),account_number:L.required("Enter account number")},K=(t,s)=>{if(s)return{voided_check:l().nullable(),bank_statement:l().nullable()};const e=z(t,T.voidedCheck),i=z(t,T.bankStatement),r=e||i,o="Please upload either a voided check or a bank statement. Only one is required.";return{voided_check:l().when("bank_statement",{is:t=>!t&&!r,then:t=>t.required(o),otherwise:t=>t.notRequired()}),bank_statement:l().when("voided_check",{is:t=>!t&&!r,then:t=>t.required(o),otherwise:t=>t.notRequired()})}},Q={[d.USA]:(t,s=[])=>((t,s)=>{const e=Object.assign(Object.assign(Object.assign({},J(s)),(t=>t?{routing_number:W.nullable()}:{routing_number:W.required("Enter routing number")})(s)),K(t,s));return a().shape(e,[["voided_check","bank_statement"]])})(s,t),[d.CAN]:(t,s=[])=>((t,s)=>{const e=Object.assign(Object.assign(Object.assign({},J(s)),(t=>{const s=h().length(3,"Institution number must be 3 digits").matches(A,"Enter valid institution number"),e=h().length(5,"Transit number must be 5 digits").matches(A,"Enter valid transit number");return t?{institution_number:s.nullable(),transit_number:e.nullable()}:{institution_number:s.required("Enter institution number"),transit_number:e.required("Enter transit number")}})(s)),K(t,s));return a().shape(e,[["voided_check","bank_statement"]])})(s,t)},Z=class{constructor(t){s(this,t),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.errors={},this.bankAccount={},this.existingDocuments=[],this.documentData=new D,this.isLoading=!1,this.getSchema=()=>(0,Q[this.country])(this.allowOptionalFields,this.existingDocuments),this.initializeFormController=()=>{this.formController=new n(this.getSchema()),this.formController.setInitialValues(Object.assign({},this.bankAccount)),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))},this.inputHandler=(t,s)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s}))},this.storeFiles=t=>{const s=Array.from(t.detail.fileList),e=t.detail.document_type,i=s.map((t=>new E({file:t,document_type:e},this.businessId)));this.documentData[e]=i},this.getData=()=>{this.isLoading=!0,this.getBusiness({onSuccess:t=>{t.data.bank_accounts.length>0?this.bankAccount=new Y(t.data.bank_accounts[0]):(this.bankAccount=new Y({}),this.bankAccount.business_id=this.businessId),this.existingDocuments=t.data.documents},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.initializeFormController(),this.isLoading=!1}})},this.postDocumentRecordData=async t=>{this.isLoading=!0;const s=t.record_data;return new Promise((e=>{this.postDocumentRecord({payload:s,onSuccess:s=>{e(this.handleDocRecordResponse(t,s))},onError:({error:t,code:s,severity:i})=>{this.errorEvent.emit({message:t,errorCode:s,severity:i}),e(!1)}})}))},this.handleDocRecordResponse=(t,s)=>s.error?(this.errorEvent.emit({errorCode:F.POST_ERROR,message:s.error.message,severity:I.ERROR,data:s.error}),!1):(t.setPresignedUrl(s.data.presigned_url),!0),this.uploadDocument=async t=>{if(!t.presigned_url)throw new Error("Presigned URL is not set");const s=await t.getFileData(),e=await fetch(t.presigned_url,{method:"PUT",body:s});return this.handleUploadResponse(e)},this.handleUploadResponse=t=>!t.error||(this.errorEvent.emit({errorCode:F.POST_ERROR,message:t.error.message,severity:I.ERROR,data:t.error}),!1)}watchHandler(t){this.formLoading.emit(t)}async validateAndSubmit({onSuccess:t}){this.existingBankAccount?this.sendData(t):this.formController.validateAndSubmit((()=>this.sendData(t)))}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new n(this.getSchema())}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}get postPayload(){const t=this.formController.values.getValue();return new Y(t).payload}get existingBankAccount(){var t;return!!(null===(t=this.bankAccount)||void 0===t?void 0:t.id)}async sendData(t){try{if(!this.existingBankAccount&&!await this.postBankAccountData())return;if(!await this.postBusinessDocuments())return;t()}catch(t){this.errorEvent.emit({message:t,errorCode:F.POST_ERROR,severity:I.ERROR})}}async postBankAccountData(){let t;return this.isLoading=!0,new Promise((s=>{let e=!1;this.postBankAccount({payload:this.postPayload,onSuccess:s=>{t=s,e=!0},onError:({error:t,code:s,severity:i})=>{e=!1,this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:C.bankAccount}),this.isLoading=!1,s(e)}})}))}async postBusinessDocuments(){this.isLoading=!0;try{const t=Object.values(this.documentData).flat();return!t.length||!(await Promise.all(t.map((t=>this.postDocumentRecordData(t))))).includes(!1)&&!(await Promise.all(t.map((t=>this.uploadDocument(t))))).includes(!1)}finally{this.isLoading=!1}}render(){const s=this.formController.getInitialValues();return this.isLoading?t(N,null):t("form",null,t("fieldset",{class:"mb-4"},t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Bank Account Info"),t("form-control-tooltip",{helpText:"This direct deposit account is the designated bank account where incoming funds will be deposited. The name of this account must match the registered business name exactly. We are not able to accept personal accounts unless your business is a registered sole proprietorship."})),t("hr",{class:"mt-2"}),t(this.country===d.CAN?"bank-account-form-inputs-canada":"bank-account-form-inputs",{defaultValue:s,errors:this.errors,inputHandler:this.inputHandler,formDisabled:this.existingBankAccount})),t("fieldset",{class:"mt-4"},t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Document Uploads"),t("form-control-tooltip",{helpText:"One document (voided check or bank statement) is required for underwriting purposes. It needs to visibly show the name tied to the account and the account number. Various file formats such as PDF, DOC, DOCX, JPEG are accepted. Multiple files can be uploaded for each document category."})),t("hr",{class:"mt-2"}),t("business-documents-on-file",{documents:this.existingDocuments,isLoading:this.isLoading}),t("bank-account-document-form-inputs",{inputHandler:this.inputHandler,errors:this.errors,storeFiles:this.storeFiles})))}static get watchers(){return{isLoading:["watchHandler"]}}},$=class{constructor(t){s(this,t),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.errors={},this.coreInfo={},this.isLoading=!1,this.isEditingTaxId=!1,this.getData=()=>{this.getBusiness&&(this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.coreInfo=new u(t.data),this.formController.setInitialValues(Object.assign({},this.coreInfo))},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let s;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{s=e,t(),this.isEditingTaxId=!1},onError:({error:t,code:e,severity:i})=>{s=t,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:C.businessInfo}),this.formLoading.emit(!1)}})},this.inputHandler=(t,s)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s}))}}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return new u(this.formController.values.getValue()).payload}componentWillLoad(){const t=this.country===d.CAN?r(this.allowOptionalFields):o(this.allowOptionalFields);this.formController=new n(t),this.getData()}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}render(){var s,e;const i=this.formController.getInitialValues();return this.isLoading?t(N,null):t("form",null,t("fieldset",null,t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Business Information")),t("hr",{class:"mt-2"}),t("div",{class:"row gy-3"},t("div",{class:"col-12"},t("form-control-text",{name:"legal_name",label:"Business Name",defaultValue:i.legal_name,errorText:this.errors.legal_name,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (don't use acronyms or abbreviations unless you registered that way)."})),t("div",{class:"col-12"},t("form-control-text",{name:"doing_business_as",label:"Doing Business As (DBA)",defaultValue:i.doing_business_as,errorText:this.errors.doing_business_as,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (leave blank if you don't have a registered DBA/trade name)"})),t("div",{class:"col-12 col-md-8"},t("form-control-select",{name:"classification",label:"Business Classification",options:k,defaultValue:i.classification,errorText:this.errors.classification,inputHandler:this.inputHandler})),t("div",{class:"col-12 col-md-4"},t("form-control-date",{name:"date_of_incorporation",label:"Date of Incorporation",defaultValue:i.date_of_incorporation,errorText:this.errors.date_of_incorporation,inputHandler:this.inputHandler})),t("div",{class:"col-12 col-md-6"},t("form-control-text",{name:"industry",label:"Industry",defaultValue:i.industry,errorText:this.errors.industry,inputHandler:this.inputHandler,helpText:"Describe what you sell"})),t("div",{class:"col-12 col-md-6"},!(null===(s=this.coreInfo)||void 0===s?void 0:s.tax_id_last4)||this.isEditingTaxId?t("form-control-number-masked",{name:"tax_id",label:q[this.country].taxIdLabel,defaultValue:this.isEditingTaxId?"":i.tax_id,errorText:this.errors.tax_id,inputHandler:this.inputHandler,mask:"000000000",helpText:q[this.country].taxIdHelpText}):t("div",null,t("label",{class:"form-label",part:y},q[this.country].taxIdLabel),t("div",{class:"input-group mb-3"},t("input",{type:"text",class:"form-control",part:g,value:`****${null===(e=this.coreInfo)||void 0===e?void 0:e.tax_id_last4}`,disabled:!0}),t("button",{class:"btn btn-secondary",type:"button",part:_,onClick:()=>{this.isEditingTaxId=!0,this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{tax_id:"",tax_id_last4:null}))}},"Change")))),t("div",{class:"col-12"},t("form-control-text",{name:"website_url",label:"Business Website URL",defaultValue:i.website_url,errorText:this.errors.website_url,inputHandler:this.inputHandler,helpText:"Don't have a live website? You can use your social media business page, app store link, or staging site URL."})),t("div",{class:"col-12 col-md-6"},t("form-control-text",{name:"email",label:"Business Email Address",defaultValue:i.email,errorText:this.errors.email,inputHandler:this.inputHandler})),t("div",{class:"col-12 col-md-6"},t("form-control-number-masked",{name:"phone",label:"Business Phone Number",defaultValue:i.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:b.US})))))}},tt=class{constructor(t){s(this,t),this.clickEvent=e(this,"click-event"),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.ownersPayload=[],this.refs=[],this.isLoading=!1,this.matchRef=(t,s)=>{const e=this.refs.findIndex((t=>t===s));-1!==e&&(this.refs[e]=t)},this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{t.data.owners.length?this.ownersPayload=t.data.owners.map((t=>({id:t.id}))):this.addOwnerForm()},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1,this.manageRefs()}})},this.sendData=async t=>{let s;this.formLoading.emit(!0),this.patchBusiness({payload:{owners:this.ownersPayload},onSuccess:e=>{s=e,t()},onError:({error:t,code:e,severity:i})=>{s=t,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:C.owners}),this.formLoading.emit(!1)}})},this.addOwnerForm=t=>{this.newFormOpen=!0,this.ownersPayload=[...this.ownersPayload,{id:""}],t&&this.clickEvent.emit({name:S.addOwnerForm})},this.removeOwnerForm=t=>{this.ownersPayload=this.ownersPayload.filter((s=>s.id!==t)),this.newFormOpen&&(this.newFormOpen=!1)}}get showAddOwnerButton(){return this.ownersPayload.length<4&&!this.newFormOpen}manageRefs(){this.refs=this.ownersPayload.map((t=>t.id))}async validateAndSubmit({onSuccess:t}){const s=this.refs.map((t=>t.validate()));if(!(await Promise.all(s)).every((t=>t)))return;const e=this.refs.map((t=>t.submit()));(await Promise.all(e)).every((t=>t))&&this.sendData(t)}componentWillLoad(){this.getBusiness&&this.getData()}ownersWatcher(){this.manageRefs()}handleOwnerSubmit(t){const s=t.detail,e=this.ownersPayload.map((t=>t.id===s.id?s:t));e.includes(s)||(e[this.ownersPayload.findIndex((t=>!t.id))]=s,this.newFormOpen&&(this.newFormOpen=!1)),this.ownersPayload=e}render(){return this.isLoading?t(N,null):t("div",null,t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Owners"),t("form-control-tooltip",{helpText:"For partnerships, LLCs or privately held corporations, the business is required to apply with all individuals with 25% or more ownership to the application. For charities and registered non-profits, the business is required to apply with 1 individual with substantial control over the entity, such as a board member or director."})),t("hr",{class:"mt-2"}),t("div",{class:"row gy-3"},this.ownersPayload.map((s=>t("justifi-owner-form",{key:s.id,authToken:this.authToken,businessId:this.businessId,ownerId:s.id,removeOwner:this.removeOwnerForm,newFormOpen:this.newFormOpen,ownersLength:this.ownersPayload.length,country:this.country,allowOptionalFields:this.allowOptionalFields,ref:t=>this.matchRef(t,s.id)})))),t("div",{class:"d-flex justify-content-start"},t("div",{class:"gap-2"},t(U,{variant:"primary",onClick:()=>this.addOwnerForm(!0),hidden:!this.showAddOwnerButton},"Add Owner"))))}static get watchers(){return{ownersPayload:["ownersWatcher"]}}},st=class{constructor(t){s(this,t),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.errors={},this.representative={},this.isLoading=!1,this.getData=()=>{this.getBusiness&&(this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.representative=new m(t.data.representative||{}),this.representative.address.country=this.country,this.formController.setInitialValues(Object.assign({},this.representative))},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let s;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{s=e,t()},onError:({error:t,code:e,severity:i})=>{s=t,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:C.representative}),this.formLoading.emit(!1)}})}}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return{representative:new m(this.formController.values.getValue()).payload}}componentWillLoad(){this.formController=new n((0,M[this.country])("representative",this.allowOptionalFields)),this.getData()}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}render(){return this.isLoading?t(N,null):t("justifi-business-representative-form-inputs",{representativeDefaultValue:this.formController.getInitialValues(),errors:this.errors,formController:this.formController,country:this.country})}},et=class{constructor(t){s(this,t),this.stepCompleteEvent=e(this,"complete-form-step-event"),this.errorEvent=e(this,"error-event"),this.formLoading=e(this,"formLoading"),this.errors={},this.legal_address={},this.isLoading=!1,this.getData=()=>{this.getBusiness&&(this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{const s=new p((t.data||{}).legal_address||{});this.legal_address=Object.assign(Object.assign({},s),{country:this.country}),this.formController.setInitialValues(Object.assign({},this.legal_address))},onError:({error:t,code:s,severity:e})=>{this.errorEvent.emit({message:t,errorCode:s,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let s;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{s=e,t()},onError:({error:t,code:e,severity:i})=>{s=t,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:C.legalAddress}),this.formLoading.emit(!1)}})},this.inputHandler=(t,s)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s}))}}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return{legal_address:new p(this.formController.values.getValue()).payload}}componentWillLoad(){this.formController=new n((0,R[this.country])(this.allowOptionalFields)),this.getData()}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}render(){const s=this.formController.getInitialValues();return this.isLoading?t(N,null):t("form",null,t("fieldset",null,t("div",{class:"d-flex align-items-center gap-2"},t("legend",{class:"mb-0",part:v},"Legal Address of your Business"),t("form-control-tooltip",{helpText:"No PO Boxes."})),t("hr",{class:"mt-2"}),t("justifi-form-address-fields",{country:this.country,errors:this.errors,defaultValues:s,inputHandler:this.inputHandler})))}};export{X as justifi_additional_questions_form_step_core,Z as justifi_business_bank_account_form_step_core,$ as justifi_business_core_info_form_step_core,tt as justifi_business_owners_form_step_core,st as justifi_business_representative_form_step_core,et as justifi_legal_address_form_step_core}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,h as i,H as o}from"./p-DOjVAAtq.js";import{C as s}from"./p-ZpPDShvP.js";import{r as a}from"./p-
|
|
1
|
+
import{r as t,c as e,h as i,H as o}from"./p-DOjVAAtq.js";import{C as s}from"./p-ZpPDShvP.js";import{r as a}from"./p-Dj_zevuD.js";import"./p-HXpYMWUU.js";const r=class{constructor(i){t(this,i),this.paymentMethodOptionSelected=e(this,"paymentMethodOptionSelected"),this.onPaymentMethodOptionClick=t=>{t.preventDefault(),this.paymentMethodOptionSelected.emit(this.paymentMethodOption)}}async resolvePaymentMethod(t){var e;return t.isValid?{token:null===(e=this.paymentMethodOption)||void 0===e?void 0:e.id}:{validationError:!0}}render(){var t,e,r;return i(o,{key:"2636f9038b83a384a2a3bc4bbc7695ff237a6584",class:"payment-method"},i("div",{key:"2995201b40f93a916fe6a32c2d27bc43cd22d8d1",class:"radio-list-item p-3",part:a,onClick:this.onPaymentMethodOptionClick},i("form-control-radio",{key:"7f8382f0d3cbc596c329fc32badc6c4b40e4493f",name:"paymentMethodType",value:null===(t=this.paymentMethodOption)||void 0===t?void 0:t.id,checked:this.isSelected,label:`${s[null===(e=this.paymentMethodOption)||void 0===e?void 0:e.brand]||""} *${null===(r=this.paymentMethodOption)||void 0===r?void 0:r.acct_last_four}`})))}};export{r as justifi_saved_payment_method}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as i,H as s}from"./p-DOjVAAtq.js";import{c as a,F as d}from"./p-DiJD6Iqx.js";import{q as r,H as c,k as n,l,n as o,z as h}from"./p-DxVCqvBt.js";import{r as f,az as b}from"./p-Dj_zevuD.js";import{S as m}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{S as u}from"./p-BIcS6lTe.js";import{c as p,J as y}from"./p-DfsX5bt_.js";import{w as v,c as k}from"./p-a6tcNl_T.js";import{P as g}from"./p-DCIW8z1f.js";import{H as _}from"./p-Dyk0thEr.js";import{n as j}from"./p-BnjCmwMr.js";import{S as w}from"./p-B5rtFhtR.js";import{B as x}from"./p-CJ9qo7_g.js";import{c as V}from"./p-DGsXKF67.js";import"./p-BFTU3MAI.js";import"./p-DfKxeSrC.js";import"./p-CPpUGsw5.js";import"./p-yiqa5abX.js";import"./p-ty1sI-fI.js";import"./p-BS7OgSQe.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import"./p-CPKSE7M4.js";import"./p-BH0Xfn-F.js";import"./p-CLHwhyvu.js";import"./p-DdMxswn1.js";const C=class{constructor(i){e(this,i),this.radioClick=t(this,"radio-click"),this.checked=!1,this.hidden=!1,this.handleClick=()=>{this.radioClick.emit(this.value)}}render(){return i(m,{key:"b0501b66bcfdd697d88c01835b8f97fb2c0861ab"},i("div",{key:"ada4dda7868086b1ea4cadd6c8824f87d3cb2301",class:`radio-list-item p-3 ${this.class||""}`,part:f,onClick:this.handleClick,hidden:this.hidden},i("form-control-radio",{key:"72c6d07dd2a664ca6bd2be9b446584d7344bc2b0",name:this.name,value:this.value,checked:this.checked,label:this.label,inputHandler:()=>null})))}},H=class{constructor(t){e(this,t),this.errors={},this.inputHandler=(e,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[e]:t}))}}componentWillLoad(){this.formController=new d(a({name:h.required("Enter full name"),address_line1:o.nullable(),address_line2:l.nullable(),address_city:n.nullable(),address_state:c.nullable(),address_postal_code:r.nullable()}))}componentDidLoad(){this.formController.values.subscribe((e=>this.billingInfo=Object.assign({},e))),this.formController.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}async getValues(){return this.formController.values.getValue()}async fill(e){this.formController.setInitialValues(e)}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){const e=this.formController.getInitialValues();return i(m,{key:"674a080063df249018a8601cea7680b06208d2fb"},i("div",{key:"c282a7c8ed0316edf0a92abd2f8c69a927c79f00",part:b,class:"mt-4"},i("form",{key:"843548c8b0239dcce2b611b215112024acfb6413"},i("fieldset",{key:"2e49050377413910e47bea94e8900f902e26b814"},this.legend&&i("legend",{key:"960da7d3f797db0517b3a14559a025a497ca3ad2"},this.legend),i("div",{key:"56636731c41c7bcaf6d4a7c3eb7e9517157c4929",class:"row gy-3"},i("div",{key:"b6028f7001044423d72a134c01a0395ade1496b8",class:"col-12"},i("form-control-text",{key:"b2fe6dc8c69cd87ac07b99f9a6619f5069f2dc5c",name:"name",label:"Full Name",defaultValue:e.name,errorText:this.errors.name,inputHandler:this.inputHandler})))))))}},O=e=>{const{isReady:t}=e;return t?null:i("div",{class:"container-fluid p-0"},i("div",{class:"row mb-3"},i("div",{class:"col-12 align-content-end"},i(u,{height:"18px",width:"120px"}),i(u,{height:"36px"}))),i("div",{class:"row"},i("div",{class:"col-12 align-content-end"},i(u,{height:"18px",width:"110px"}),i(u,{height:"36px"}))))},D=class{constructor(t){e(this,t),this.isReady=!1}async componentWillLoad(){await v(),this.iframeOrigin=k.iframeOrigin,p(),this.analytics=new y(this)}componentDidRender(){Promise.all([this.accountNumberIframeElement,this.routingNumberIframeElement].map((e=>new Promise((t=>{e.addEventListener("iframeLoaded",(()=>{t()}))}))))).then((()=>{this.isReady=!0}))}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.cleanup()}async validate(){const e=await this.accountNumberIframeElement.validate(),t=await this.routingNumberIframeElement.validate();return e&&t}async tokenize({clientId:e,paymentMethodMetadata:t,account:i}){return this.accountNumberIframeElement.tokenize(e,t,i)}render(){return i(m,{key:"1396c82eb048077e956a6cfa0954c969830a3e4e"},i(O,{key:"90439488c391f7dcb62c9b3aadeeeb9e22b476fe",isReady:this.isReady}),i("hidden-input",{key:"ab5ab9990cd03e493551dae5dc18717ed144558b"}),i("div",{key:"7031dcaa20b3d017b3a3064d5e6f2e9ec5f3c3de",class:"container-fluid p-0",style:{opacity:this.isReady?"1":"0",height:this.isReady?"auto":"0"}},i("div",{key:"cf64b23918c17c525be517fa3506bc5a99de4472",class:"row mb-3"},i("iframe-input",{key:"1a0bad102f68437d751a123ab14db53d0308b02a",inputId:"accountNumber",ref:e=>this.accountNumberIframeElement=e,label:"Account Number",iframeOrigin:`${this.iframeOrigin}/v2/accountNumber`})),i("div",{key:"332cf9bc370f6bbddaf717c4debbd90bc557d808",class:"row"},i("iframe-input",{key:"878379906a0efb39c7a236941fda8d399d3a8baf",inputId:"routingNumber",ref:e=>this.routingNumberIframeElement=e,label:"Routing Number",iframeOrigin:`${this.iframeOrigin}/v2/routingNumber`}))))}},S=class{constructor(t){e(this,t)}get showSimpleCardBillingForm(){return this.paymentMethodType===g.NEW_CARD&&this.hideCardBillingForm}get showSimpleBankAccountBillingForm(){return this.paymentMethodType===g.NEW_BANK_ACCOUNT&&this.hideBankAccountBillingForm}async getValues(){var e;return null===(e=this.selectedFormRef)||void 0===e?void 0:e.getValues()}async fill(e){var t;null===(t=this.selectedFormRef)||void 0===t||t.fill(e)}async validate(){var e;return null===(e=this.selectedFormRef)||void 0===e?void 0:e.validate()}render(){return i(s,null,i(this.showSimpleBankAccountBillingForm?"justifi-bank-account-billing-form-simple":this.showSimpleCardBillingForm?"justifi-card-billing-form-simple":"justifi-billing-form-full",{legend:this.legend,ref:e=>this.selectedFormRef=e}))}},I=class{constructor(t){e(this,t),this.errors={},this.inputHandler=(e,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[e]:t}))}}componentWillLoad(){this.formController=new d(a({name:h.required("Enter full name"),address_line1:o.required("Enter street address"),address_line2:l.nullable(),address_city:n.required("Enter city"),address_state:c.required("Select state"),address_postal_code:r.required("Enter postal code")})),this.formController.values.subscribe((e=>this.billingInfo=Object.assign({},e))),this.formController.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}async getValues(){return this.formController.values.getValue()}async fill(e){this.formController.setInitialValues(e)}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){if(!this.formController)return null;const e=this.formController.getInitialValues();return i(m,null,i("div",{part:b,class:"mt-4"},i(_,{text:"Billing address",class:"fs-6 fw-bold lh-lg mb-4"}),i("form",null,i("fieldset",null,this.legend&&i("legend",null,this.legend),i("div",{class:"row gy-3"},i("div",{class:"col-12"},i("form-control-text",{name:"name",label:"Full Name",defaultValue:e.name,errorText:this.errors.name,inputHandler:this.inputHandler})),i("div",{class:"col-12"},i("form-control-text",{name:"address_line1",label:"Street Address",defaultValue:e.address_line1,errorText:this.errors.address_line1,inputHandler:this.inputHandler})),i("div",{class:"col-12"},i("form-control-text",{name:"address_line2",label:"Apartment, Suite, etc. (optional)",defaultValue:e.address_line2,errorText:this.errors.address_line2,inputHandler:this.inputHandler})),i("div",{class:"col-12"},i("form-control-text",{name:"address_city",label:"City",defaultValue:e.address_city,errorText:this.errors.address_city,inputHandler:this.inputHandler})),i("div",{class:"col-12"},i("form-control-select",{name:"address_state",label:"State",options:w,defaultValue:e.address_state,errorText:this.errors.address_state,inputHandler:this.inputHandler})),i("div",{class:"col-12"},i("form-control-text",{name:"address_postal_code",label:"ZIP",defaultValue:e.address_postal_code,errorText:this.errors.address_postal_code,inputHandler:this.inputHandler,maxLength:5,keyDownHandler:j})))))))}},N=class{constructor(t){e(this,t),this.variant="primary",this.type="button"}render(){return i(m,{key:"101d2233002f9d316fae078dd77d43358c937291"},i(x,{key:"d7e3c0a41d862572eb47a22e3c7178e8a172d990",variant:this.variant,isLoading:this.isLoading,clickHandler:this.clickHandler,class:this.class,type:this.type,disabled:this.disabled,style:this.customStyle},this.text))}},M=class{constructor(t){e(this,t),this.errors={},this.inputHandler=(e,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[e]:t}))}}componentWillLoad(){this.formController=new d(a({name:h.nullable(),address_line1:o.nullable(),address_line2:l.nullable(),address_city:n.nullable(),address_state:c.nullable(),address_postal_code:r.required("Enter postal code")}))}componentDidLoad(){this.formController.values.subscribe((e=>this.billingInfo=Object.assign({},e))),this.formController.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}async getValues(){return this.formController.values.getValue()}async fill(e){this.formController.setInitialValues(e)}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){const e=this.formController.getInitialValues();return i(m,{key:"f1f3be2d16211cbb384246470a495076b8cc99bf"},i("div",{key:"aabd6ec4293a89fa65e65440bcc399a3c91ccbf6",part:b},i("form",{key:"4212a38db263ec874feba69b44aa4ca53c4b6971"},i("fieldset",{key:"a669e28f6cb8974b1a6a358809c6c1c88d8dc5cb"},this.legend&&i("legend",{key:"b01fa92477ad324a059474b86835ad984addd48f"},this.legend),i("div",{key:"6c1f9a93de580ce2d931aedae3083e015b8e5f07",class:"row gy-3"},i("div",{key:"bbc6ba15ce56756db54338cd114376d57a9c6546",class:"col-12"},i("form-control-text",{key:"74848920343434f7677d8454b7bf0ec0e8055427",name:"address_postal_code",label:"ZIP",defaultValue:e.address_postal_code,errorText:this.errors.address_postal_code,inputHandler:this.inputHandler,maxLength:5,keyDownHandler:j})))))))}},B=e=>{const{isReady:t}=e;return t?null:i("div",{class:"container-fluid p-0"},i("div",{class:"mb-3"},i(u,{height:"18px",width:"100px"}),i(u,{height:"36px"})),i("div",{class:"row"},i("div",{class:"col-4 align-content-end"},i(u,{height:"18px",width:"80px"}),i(u,{height:"36px"})),i("div",{class:"col-4 align-content-end"},i(u,{height:"36px"})),i("div",{class:"col-4 align-content-end"},i(u,{height:"18px",width:"30px"}),i(u,{height:"36px"}))))},L=class{constructor(t){e(this,t),this.isReady=!1}async componentWillLoad(){await v(),this.iframeOrigin=k.iframeOrigin,p(),this.analytics=new y(this)}componentDidRender(){Promise.all([this.cardNumberIframeElement,this.expirationMonthIframeElement,this.expirationYearIframeElement,this.cvvIframeElement].map((e=>new Promise((t=>{e.addEventListener("iframeLoaded",(()=>{t()}))}))))).then((()=>{this.isReady=!0}))}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.cleanup()}async validate(){const e=await this.cardNumberIframeElement.validate(),t=await this.expirationMonthIframeElement.validate(),i=await this.expirationYearIframeElement.validate(),s=await this.cvvIframeElement.validate();return e&&t&&i&&s}async tokenize({clientId:e,paymentMethodMetadata:t,account:i}){return this.cardNumberIframeElement.tokenize(e,t,i)}render(){return i(m,{key:"def25049fc30e1755194750bad8ebff0c578dac2"},i(B,{key:"81a0ec8218a76e51962fac0e8f628b243bd6d33e",isReady:this.isReady}),i("hidden-input",{key:"6145fba4b8164ff1cec1d1b5707063cdf26faa82"}),i("div",{key:"febcd1d5dbbde0216d7286842f35d58984f3c292",class:"container-fluid p-0",style:{opacity:this.isReady?"1":"0",height:this.isReady?"auto":"0"}},i("div",{key:"6e305988144bd44753ab202b29de295cc3dd7b20",class:"mb-3"},i("iframe-input",{key:"79348433ff2860a30d387b9a64c258a91c220363",inputId:"cardNumber",ref:e=>this.cardNumberIframeElement=e,label:"Card Number",iframeOrigin:`${this.iframeOrigin}/v2/cardNumber`})),i("div",{key:"11eee27f7aa34c120aed348acd1fc51e46b77628",class:"row"},i("div",{key:"0bb1153c58433514b889fe20d9cf77c7b7f8b867",class:"col-4 align-content-end"},i("iframe-input",{key:"f07c79907822a83cbc29eb4748f952b1a2079990",inputId:"expirationMonth",ref:e=>this.expirationMonthIframeElement=e,label:"Expiration",iframeOrigin:`${this.iframeOrigin}/v2/expirationMonth`})),i("div",{key:"6c2e81715c918978f688d00ae960f2673e092248",class:"col-4 align-content-end"},i("iframe-input",{key:"96d3656d4a26f96889ab5c6569e0144a76293627",inputId:"expirationYear",ref:e=>this.expirationYearIframeElement=e,label:"",iframeOrigin:`${this.iframeOrigin}/v2/expirationYear`})),i("div",{key:"e186614da2a5ef5836e251ac1f8f247c18cff7e6",class:"col-4 align-content-end"},i("iframe-input",{key:"d9f6c2d2f669fde22b18845a47f5bdeb8a62abe7",inputId:"CVV",ref:e=>this.cvvIframeElement=e,label:"CVV",iframeOrigin:`${this.iframeOrigin}/v2/CVV`})))))}},P=class{constructor(i){e(this,i),this.checkboxChanged=t(this,"checkboxChanged"),this.label="Save New Payment Method",this.isChecked=!1,this.handleCheckboxChange=(e,t)=>{this.isChecked=t,V.savePaymentMethod=t,this.checkboxChanged.emit(this.isChecked)}}render(){return i(m,{key:"e40e77b8ef70b343c870a4cb0b6cf3fa51543ff9"},i("form-control-checkbox",{key:"1429e670405e0d43eef2d3b5ed2d071db339129d",label:this.label||"Save New Payment Method",name:"saveNewPaymentMethod",checked:this.isChecked,inputHandler:this.handleCheckboxChange}))}};export{H as justifi_bank_account_billing_form_simple,D as justifi_bank_account_form,S as justifi_billing_form,I as justifi_billing_form_full,N as justifi_button,M as justifi_card_billing_form_simple,L as justifi_card_form,C as justifi_radio_list_item,P as justifi_save_new_payment_method}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as s,r as t,c as i}from"./p-DOjVAAtq.js";import{A as e}from"./p-ty1sI-fI.js";import{C as r,a as o}from"./p-Cjcsf8ku.js";import"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{g as a,a as n}from"./p-D2muobcE.js";import{c,J as l}from"./p-DfsX5bt_.js";import{c as h}from"./p-DGsXKF67.js";import{p as d,f as p,r as u,j as v}from"./p-BS7OgSQe.js";import{v as m,i as y,a as f,H as j}from"./p-DxnXyWPn.js";import{D as _,E as g}from"./p-Dj_zevuD.js";import{S as b}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{S as k}from"./p-BIcS6lTe.js";import"./p-a6tcNl_T.js";import"./p-DdMxswn1.js";import"./p-yiqa5abX.js";import"./p-DCIW8z1f.js";import"./p-HXpYMWUU.js";const w=e();class C{async fetchQuote(s,t){return w.post({endpoint:"insurance/quotes",body:t,authToken:s})}async toggleCoverage(s,t,i){return w.post({endpoint:`insurance/quotes/${t}/toggle`,body:i,authToken:s})}}const T=()=>s("div",{class:"row gap-3"},s("div",{class:"col-12"},s(k,{width:"35%",height:"30px"})),s("div",{class:"col-12"},s(k,{width:"70%"})),s("div",{class:"col-12"},s(k,{width:"40%"})),s("div",{class:"col-12"},s(k,{width:"40%"})),s("div",{class:"col-12"},s(k,{width:"100%"})),s("div",{class:"col-12"},s(k,{width:"80%"}))),D=class{constructor(s){t(this,s),this.insuranceUpdated=i(this,"insurance-updated"),this.errorEvent=i(this,"error-event"),this.isLoading=!0}async validate(){return m()}processHTMLContent(s){return d(s,[s=>u(s,"style"),s=>v(s,"a","part",_),s=>v(s,"p","part",_)])}componentWillLoad(){c(),this.analytics=new l(this),this.initializeServiceMethods(),this.getQuote&&this.fetchData()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}initializeServiceMethods(){const s=this.authToken||h.authToken;if(!s)return void this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:"Missing authToken",severity:r.ERROR});const t={authToken:s,service:new C};this.getQuote=(({authToken:s,service:t})=>async({payload:i,onSuccess:e,onError:o})=>{var c;try{const l=await t.fetchQuote(s,i);if(l.error)return o({error:n(l.error),code:a(null===(c=l.error)||void 0===c?void 0:c.code),severity:r.ERROR});e({quote:l.data})}catch(s){const t=a(null==s?void 0:s.code);return o({error:s.message||s,code:t,severity:r.ERROR})}})(t),this.toggleCoverage=(({authToken:s,service:t})=>async({quoteId:i,payload:e,onSuccess:o,onError:c})=>{var l;try{const h=await t.toggleCoverage(s,i,e);if(h.error)return c({error:n(h.error),code:a(null===(l=h.error)||void 0===l?void 0:l.code),severity:r.ERROR});o({quote:h.data})}catch(s){const t=a(null==s?void 0:s.code);return c({error:s.message||s,code:t,severity:r.ERROR})}})(t)}fetchData(){this.isLoading=!0,this.getQuote({payload:{checkout_id:this.checkoutId||h.checkoutId,policy_type:"season_interruption",primary_identity:{state:this.primaryIdentityState,email:this.primaryIdentityEmailAddress,first_name:this.primaryIdentityFirstName,last_name:this.primaryIdentityLastName,postal_code:this.primaryIdentityPostalCode,country:this.primaryIdentityCountry},policy_attributes:{insurable_amount:this.policyAttributesInsurableAmount,start_date:this.policyAttributesStartDate,end_date:this.policyAttributesEndDate,covered_identity:{first_name:this.coveredIdentityFirstName,last_name:this.coveredIdentityLastName}}},onSuccess:({quote:s})=>{this.quote=s,this.quote.product.description=this.processHTMLContent(this.quote.product.description),this.quote.product.legal_disclaimer=this.processHTMLContent(this.quote.product.legal_disclaimer),y[s.policy_type]=s.accepted,this.isLoading=!1},onError:({error:s,code:t,severity:i})=>{this.isLoading=!1,this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}onChangeHandler(s,t){this.accepted=t,f[this.quote.policy_type]=!1,this.toggleCoverage({quoteId:this.quote.id,payload:{accepted:this.accepted},onSuccess:()=>{this.insuranceUpdated.emit(),y[this.quote.policy_type]=this.accepted},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}get error(){var s;return f[null===(s=this.quote)||void 0===s?void 0:s.policy_type]}render(){var t,i,e,r;return h&&!1===h.insuranceEnabled?(console.warn("[justifi-season-interruption-insurance] Insurance is disabled for this checkout (payment_settings.insurance_payments=false)."),null):s(b,null,this.isLoading?s(T,null):s("div",null,s(j,{text:null===(t=this.quote)||void 0===t?void 0:t.product.title,class:"fs-5 fw-bold pb-3"}),s("small",{part:_,innerHTML:null===(i=this.quote)||void 0===i?void 0:i.product.description}),s("form-control-radio",{label:`Accept coverage for ${p(null===(e=this.quote)||void 0===e?void 0:e.total_cents)}`,name:"opt-in",value:"true",checked:"true"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("form-control-radio",{label:"Decline coverage",name:"opt-in",value:"false",checked:"false"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("div",{class:"invalid-feedback",style:{display:this.error?"block":"none"},part:g},"Please select an option"),s("small",{part:_,innerHTML:null===(r=this.quote)||void 0===r?void 0:r.product.legal_disclaimer})))}};export{D as justifi_season_interruption_insurance}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as r}from"./p-DOjVAAtq.js";import{P as i}from"./p-DqPvh0aN.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{C as o,a as e}from"./p-Cjcsf8ku.js";import{P as a}from"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{g as p,a as n}from"./p-D2muobcE.js";import{c,J as m}from"./p-DfsX5bt_.js";import{S as h}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{d}from"./p-BYrSeoci.js";import"./p-ty1sI-fI.js";import"./p-BS7OgSQe.js";import"./p-DdMxswn1.js";import"./p-yiqa5abX.js";import"./p-BdmYH_IK.js";import"./p-Bm8T-MOQ.js";import"./p-Dj_zevuD.js";const f=class{constructor(r){t(this,r),this.errorEvent=s(this,"error-event"),this.errorMessage=null,this.columns=d,this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)}}componentWillLoad(){c(),this.analytics=new m(this),this.initializeGetPayments()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetPayments()}initializeGetPayments(){this.accountId&&this.authToken?this.getPayments=(({id:t,authToken:s,service:r})=>async({params:i,onSuccess:e,onError:c,final:m})=>{var h,d;try{const m=await r.fetchPayments(t,s,i);if(m.error)return c({error:n(m.error),code:p(null===(d=m.error)||void 0===d?void 0:d.code),severity:o.ERROR});{const t=Object.assign({},m.page_info);e({payments:(null===(h=m.data)||void 0===h?void 0:h.map((t=>new a(t))))||[],pagingInfo:t})}}catch(t){const s=p(null==t?void 0:t.code);return c({error:t.message||t,code:s,severity:o.ERROR})}finally{return m()}})({id:this.accountId,authToken:this.authToken,service:new i}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:e.MISSING_PROPS,message:this.errorMessage,severity:o.ERROR}))}render(){return r(h,{key:"600a899641ac8e2bbada4cc2f7f5c8477f16f5c9"},r("payments-list-core",{key:"903ca5197fd56b9f0dfb141d09f92e27cd35f651",getPayments:this.getPayments,"onError-event":this.handleErrorEvent,columns:this.columns}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{f as justifi_payments_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as s,c as i,h as t}from"./p-DOjVAAtq.js";import{c as o,J as r}from"./p-DfsX5bt_.js";import{C as e,a as n}from"./p-Cjcsf8ku.js";import{m as p,a}from"./p-5aA7gjr5.js";import{B as h}from"./p-DIdnZUSh.js";import{A as m}from"./p-ty1sI-fI.js";import"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import"./p-yiqa5abX.js";import"./p-D2muobcE.js";import"./p-a6tcNl_T.js";import"./p-DdMxswn1.js";import"./p-BS7OgSQe.js";import"./p-HXpYMWUU.js";const d=m();class c{async postProvisioning(s,i,t){return d.post({endpoint:"entities/provisioning",body:{business_id:i,product_category:t},authToken:s})}}const u=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event"),this.allowOptionalFields=!1,this.formTitle="Business Information"}propChanged(){this.initializeApi()}componentWillLoad(){o(),this.analytics=new r(this),this.initializeApi()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=p({authToken:this.authToken,businessId:this.businessId,service:new h}),this.postProvisioning=a({authToken:this.authToken,businessId:this.businessId,product:"payment",service:new c})):this.errorEvent.emit({message:"auth-token and business-id are required",errorCode:n.MISSING_PROPS,severity:e.ERROR})}render(){return t("justifi-payment-provisioning-core",{key:"41e96a931c082212f43bdd84dd5c948fac1eddfc",businessId:this.businessId,authToken:this.authToken,allowOptionalFields:this.allowOptionalFields,formTitle:this.formTitle,getBusiness:this.getBusiness,postProvisioning:this.postProvisioning})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}};export{u as justifi_payment_provisioning}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as a}from"./p-DOjVAAtq.js";import{X as c,Y as s,Z as d}from"./p-Dj_zevuD.js";const i=class{constructor(a){e(this,a),this.selectedQuantityChange=t(this,"selectedQuantityChange"),this.limit=1/0,this.selectedQuantity=0,this.removeUnit=()=>{this.selectedQuantity>0&&(this.selectedQuantity--,this.selectedQuantityChange.emit({modelName:this.modelName,quantity:this.selectedQuantity}))},this.addUnit=()=>{this.limit>0&&(this.selectedQuantity++,this.selectedQuantityChange.emit({modelName:this.modelName,quantity:this.selectedQuantity}))}}render(){return a("div",{key:"3e2c9aac5322205108924c346a1f5bed41a673e6",class:"rounded shadow-sm card p-2",part:d},a("div",{key:"010ef8e5ecacabdbde46e15c01b68bc89450f8c2",class:"d-flex gap-3"},a("div",{key:"9a7a9215dffbe59d9a3ebee2ed40bfea1f838e7a",class:"d-flex align-items-center"},a("img",{key:"51e5919f4c76ac372f6caaca35d5e16bc99c4766",src:this.imageUrl,alt:this.modelName,height:75,width:75,part:c})),a("div",{key:"23c5c813f0a427bef785d8f48d03ffa4c6d94aad",class:"d-flex flex-column flex-grow-1 gap-3 p-4 justify-content-center"},a("div",{key:"2eb6df9a235030b347dcea3e398961761586b36e",class:"row"},a("div",{key:"cb5daf84d7ba9c1f41b3d2a78ae5c5d90cfc6817",class:"col-6 d-flex gap-2"},this.modelName,a("form-control-tooltip",{key:"fdeb46a05efdab7bd1ff5c1540f968cd9a868bec",helpText:this.description})),a("div",{key:"f89be0d4e9ec16363acac6706a122657219746bf",class:"col-6 d-flex justify-content-end align-items-center"},a("button",{key:"55c367a543f03d0e05835781a7e775497be0d782",class:"p-0 minus btn",onClick:this.removeUnit,part:s},"-"),a("div",{key:"77cabef1a1f3c912dca9d90e4f63e9004e20c829",class:"w-25 text-center"},this.selectedQuantity),a("button",{key:"2ecc0d4c5022045e618049fc3edcf9f07d882f64",class:"p-0 plus btn",onClick:this.addUnit,part:s},"+"))))))}};export{i as terminal_quantity_selector}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as e}from"./p-DOjVAAtq.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{C as i,a}from"./p-Cjcsf8ku.js";import"./p-CPKSE7M4.js";import{p as r}from"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{T as h,a as o,b as c,c as n,d as p,e as d,f,g as m,h as u,i as b,j as g,k as y,l as j}from"./p-UUJudj_5.js";import{T as l}from"./p-CZfYo5-1.js";import{p as k,a as C}from"./p-BkaPXFTl.js";import{o as S,g as v}from"./p-NwmOm8Pg.js";import"./p-DdMxswn1.js";import"./p-BS7OgSQe.js";import"./p-Dj_zevuD.js";import"./p-CVtpEQBE.js";import"./p-IYf7zn5J.js";import"./p-Bm8T-MOQ.js";const w=class{constructor(e){t(this,e),this.clickEvent=s(this,"click-event"),this.errorEvent=s(this,"error-event"),this.payouts=[],this.subAccounts=[],this.loading=!0,this.paging=r,this.pagingParams={},this.downloadCSV=t=>{this.getPayoutCSV({payoutId:t,onError:()=>{this.errorEvent.emit({errorCode:a.FETCH_ERROR,message:"Failed to download CSV",severity:i.ERROR})}})},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:l.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:l.next})},this.rowClickHandler=t=>{const s=t.target.closest("tr"),e=s.dataset.rowEntityId;if(!e)return;if(s.querySelector("a")===t.target)return;const i=this.payouts.find((t=>t.id===e));this.clickEvent.emit({name:l.row,data:i})}}updateOnPropChange(){this.fetchData()}componentWillLoad(){this.payoutsTable=new h(this.payouts,this.columns,k,C(this.downloadCSV)),this.getPayouts&&this.getSubAccounts&&this.fetchData(),S("set",(()=>{this.pagingParams={}})),S("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}fetchData(){this.loading=!0,this.getPayouts({params:this.payoutParams,onSuccess:({payouts:t,pagingInfo:s})=>{this.payouts=t,this.paging=s,this.payoutsTable.collectionData=this.payouts,this.payoutsTable.columnKeys.includes("sub_account_name")?this.fetchSubAccounts():this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}async fetchSubAccounts(){this.getSubAccounts({params:this.subAccountParams,onSuccess:({subAccounts:t})=>{this.subAccounts=t,this.payouts=this.payouts.map((t=>{var s;return t.sub_account_name=null===(s=this.subAccounts.find((s=>s.id===t.account_id)))||void 0===s?void 0:s.name,t})),this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}get payoutParams(){const t=v();return Object.assign(Object.assign({},t),this.pagingParams)}get subAccountParams(){let t=this.payouts.map((t=>t.account_id));return{sub_account_id:[...new Set(t)].join(",")}}get entityId(){return this.payouts.map((t=>t.id))}get showEmptyState(){return!this.loading&&!this.errorMessage&&this.payoutsTable.rowData.length<1}get showErrorState(){return!this.loading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.loading}render(){return e(j,{key:"cdf6daaa40985bc3925c6f5d5b618102f5168ee0"},e(o,{key:"52e74b98af14199c22442fe8b70d2af8c48da931"},e(c,{key:"65e21eb180a339b71f861c9130e89ad55cda138c"},e(n,{key:"b1e2c439fdce4d235fa54560d1952ee84bdfbffa"},this.payoutsTable.columnData.map((t=>t)))),e(p,{key:"c3113938a3c99f1fe52b7526f9e3d4a0f3f36ba5"},e(d,{key:"eda682acb4f576e34d0068ca2ebbec0561bec0e8",columnSpan:this.payoutsTable.columnKeys.length,isLoading:this.loading}),e(f,{key:"4aee9df94af9135ab87ce32fc3fb3eec4c27990f",isEmpty:this.showEmptyState,columnSpan:this.payoutsTable.columnKeys.length}),e(m,{key:"413d3362c4c3fd0dbae32b7c56d3c45a0f228285",columnSpan:this.payoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.payoutsTable.rowData.map(((t,s)=>e(u,{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},t)))),this.paging&&e(b,{key:"8d528bd87a55c41dc3327dfff1aaed84593b70c3"},e(g,{key:"1cd949eaafefe2fadfebcd1320cf4d47f8401d47"},e(y,{key:"057e0a48bf6e2fe35754eb11a53b0179adb08e1f",colSpan:this.payoutsTable.columnData.length},e("pagination-menu",{key:"7eb638922c2403586e6737e8696aced00d0188ea",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})}))))))}static get watchers(){return{pagingParams:["updateOnPropChange"],getPayouts:["updateOnPropChange"],getSubAccounts:["updateOnPropChange"]}}};export{w as payouts_list_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as e,h as s,H as a,g as i}from"./p-DOjVAAtq.js";import{F as r}from"./p-D9Yus-je.js";import{i as o,b as l,a as h,U as c,c as n,l as f}from"./p-Dj_zevuD.js";const d=class{constructor(s){t(this,s),this.formControlInput=e(this,"formControlInput"),this.formControlBlur=e(this,"formControlBlur")}render(){return s(a,{key:"4d69131cba0d3529b5e8d3344085400a0e491f7a",exportparts:"label,input,input-invalid"},s("div",{key:"91ef14e863262efef2ca6478dddcbe06fed2c3de",class:"form-group d-flex flex-column"},s("div",{key:"46fab1c0db5685d8ea5f84f1517a129894a4ba62",class:"d-flex align-items-start gap-2"},s("label",{key:"e43d7049b5ce9265e27d30e6edca60b877ce7207",part:"label",class:"form-label",htmlFor:this.name},this.label),s("form-control-tooltip",{key:"4a6298c1b36cf0bbef8ebb383398168cf99af362",helpText:this.helpText})),s("input",{key:"1ec274c8399390dcc08b708218485be030df3e4a",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=""}),s(r,{key:"154e2193272229f617555a5a1804c334d5214d53",errorText:this.errorText,name:this.name})))}get el(){return i(this)}},b=class{constructor(s){t(this,s),this.formControlInput=e(this,"formControlInput"),this.formControlBlur=e(this,"formControlBlur"),this.isFocused=!1,this.handleFormControlInput=t=>{const e=t.target,s=e.getAttribute("name");this.inputHandler(s,e.value),this.formControlInput.emit({name:s,value:e.value})},this.updateInput=t=>{const e=this.el.querySelector("textarea");e&&(e.value=t||"")}}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.isFocused&&this.errorText?o:this.errorText?l:this.isFocused?h:this.disabled?c:n}render(){return s(a,{key:"8b45f46328cd09457814bf8d9f474a1f1f1b4384"},s("div",{key:"a10735e0d15b641d2ab79ca6930cb22e91c89147",class:"form-group d-flex flex-column"},s("label",{key:"fc72fe91f841c8fe1525eb87fc270492660d1932",part:f,class:"form-label",htmlFor:this.name},this.label),s("textarea",{key:"237ec248e7c68d97dcb035984783347bb6eb1092",id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,onKeyDown:this.keyDownHandler,onPaste:this.keyDownHandler,maxLength:this.maxLength,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",disabled:this.disabled}),s("form-control-help-text",{key:"e12fd273b27a74c07de1f043dc7cdb927c8b19d8",helpText:this.helpText,name:this.name}),s("form-control-error-text",{key:"e5e0fec72f54ddde7e72c465f8c97fef2df0ef85",errorText:this.errorText,name:this.name})))}get el(){return i(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{d as form_control_file_v2,b as form_control_textarea}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as a}from"./p-DOjVAAtq.js";import{f as t,p as s,c as r}from"./p-0fgTPVV0.js";import{q as l,u as d,v as i,w as o,x as p}from"./p-Dj_zevuD.js";import{S as b}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import"./p-a6tcNl_T.js";import{c,a as f}from"./p-BS7OgSQe.js";import"./p-Cjcsf8ku.js";import{T as n,b as m}from"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import"./p-DdMxswn1.js";import"./p-HXpYMWUU.js";const u=class{constructor(a){e(this,a),this.setParamsOnChange=(e,a)=>{t[e]=a},this.handleDateInput=(e,a)=>{const t=c(a,{setExactTime:!0});this.setParamsOnChange(e,t)}}componentWillLoad(){Object.entries({order_status:this.orderStatus,order_type:this.orderType,created_after:this.createdAfter,created_before:this.createdBefore}).forEach((([e,a])=>{a&&(s[e]=a)}))}get terminalOrderStatusOptions(){return[{label:"All",value:""},{label:"Created",value:n.created},{label:"Completed",value:n.completed},{label:"Submitted",value:n.submitted},{label:"In Progress",value:n.in_progress},{label:"On Hold",value:n.on_hold},{label:"Canceled",value:n.canceled}]}get terminalOrderTypeOptions(){return[{label:"All",value:""},{label:"Boarding Only",value:m.boardingOnly},{label:"Boarding Shipping",value:m.boardingShipping}]}render(){const e=Object.assign({},t);return a(b,{key:"1df2679852a2c3795bd5c9a90ec2d08ea124ab63"},a("table-filters-menu",{key:"2836ae98e62ac6ee5dbb00b2d5115b0b49795576",params:e,clearParams:r,part:l},a("div",{key:"bd993ac7ed2e2b6a83d787dc2456ab4184bf85a7",class:"grid-cols-2 gap-3 p-1"},a("div",{key:"b03fc2cdd1931f0dbf7873735152f277c823498b",class:"p-2"},a("form-control-select",{key:"8796b887cda1645323a68de9ab34cfefbb144fbe",name:"order_status",label:"Order Status",options:this.terminalOrderStatusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.orderStatus||t.order_status||"",disabled:!!this.orderStatus,part:d})),a("div",{key:"575764ad238bba204780582d45e694fb57fca521",class:"p-2"},a("form-control-select",{key:"4dd9fb99dc251fc519d9484cd9820b190effa1de",name:"order_type",label:"Order Type",options:this.terminalOrderTypeOptions,inputHandler:this.setParamsOnChange,defaultValue:this.orderType||t.order_type||"",disabled:!!this.orderType,part:i})),a("div",{key:"4581e4f414e0acf62b61f3b343ec0dbc462aeb71",class:"p-2"},a("form-control-date",{key:"2c9373178da8fdd87f99843cb18634b00fbc7724",name:"created_after",label:"Created After",inputHandler:this.handleDateInput,defaultValue:f(this.createdAfter,{showInputDateTime:!0})||f(t.created_after,{showInputDateTime:!0}),showTime:!0,disabled:!!this.createdAfter,part:o})),a("div",{key:"882a33df41cdf11e5a0ec84ffefdb8eab8026a19",class:"p-2"},a("form-control-date",{key:"2915ce84bbf61c73548112f8fdb894593f0c5695",name:"created_before",label:"Created Before",inputHandler:this.handleDateInput,defaultValue:f(this.createdBefore,{showInputDateTime:!0})||f(t.created_before,{showInputDateTime:!0}),showTime:!0,disabled:!!this.createdBefore,part:p})))))}};export{u as justifi_terminal_orders_list_filters}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as s,c as t,h as i}from"./p-DOjVAAtq.js";import{C as e,a as r}from"./p-Cjcsf8ku.js";import{C as o,B as h,c as a}from"./p-B5rtFhtR.js";import{D as n}from"./p-Dj_zevuD.js";import{S as c}from"./p-BhCH9S0e.js";import{H as d}from"./p-BXMAoCNA.js";import"./p-CZfYo5-1.js";import{B as p}from"./p-XYgDHrVL.js";const f=class{constructor(i){s(this,i),this.clickEvent=t(this,"click-event"),this.errorEvent=t(this,"error-event"),this.submitEvent=t(this,"submit-event"),this.loading=!1,this.businessProvisioned=!1,this.currentStep=0,this.country=o.USA,this.allowOptionalFields=!1,this.setBusinessProvisioned=()=>new Promise((s=>{this.getBusiness({onSuccess:t=>{const i=new h(t.data);this.businessProvisioned=a(i),this.country=i.country_of_establishment,this.businessProvisioned&&this.errorEvent.emit({message:"A request to provision payments for this business has already been submitted.",errorCode:r.PROVISIONING_REQUESTED,severity:e.INFO}),s()},onError:({error:t,code:i,severity:e})=>{this.errorEvent.emit({message:t,errorCode:i,severity:e}),s()}})})),this.postProvisioningData=()=>{this.postProvisioning({onSuccess:s=>{this.submitEvent.emit({response:s})},onError:({error:s,code:t,severity:i})=>{this.submitEvent.emit({response:{error:s}}),this.errorEvent.emit({message:s,errorCode:t,severity:i})}})},this.refs=[],this.incrementSteps=()=>{if(this.currentStep<this.totalSteps)return this.currentStep++},this.decrementSteps=()=>this.currentStep--,this.previousStepButtonOnClick=()=>{this.clickEvent.emit({name:p.previousStep}),this.decrementSteps()},this.nextStepButtonOnClick=(s,t)=>{s.preventDefault(),this.clickEvent.emit({name:t}),this.refs[this.currentStep].validateAndSubmit({onSuccess:this.incrementSteps})}}handleFormCompleted(){this.postProvisioningData()}async componentWillLoad(){this.getBusiness&&await this.setBusinessProvisioned(),this.refs=[this.coreInfoRef,this.legalAddressRef,this.additionalQuestionsRef,this.representativeRef,this.ownersRef,this.bankAccountRef,this.termsRef]}get businessEndpoint(){return`entities/business/${this.businessId}`}get formDisabled(){return this.loading||this.businessProvisioned}get totalSteps(){return this.refs.length-1}get stepCounter(){return`${this.currentStep+1} of ${this.totalSteps+1}`}handleFormLoading(s){this.loading=s.detail}render(){return i(c,{key:"f7206f7fa5c0b2052b524737e86b622f92dcd07e"},i("div",{key:"65cd3a37191f1bdef3380b1c5ceebc260b846b6a",class:"row gap-3"},i(d,{key:"05fd7dff0691a80ad7c1dc9152a5fd4d851a292d",text:this.formTitle}),i("justifi-payment-provisioning-form-steps",{key:"57f9b35aa0a1fa2205a43cb90c274fa211f7c359",businessId:this.businessId,authToken:this.authToken,refs:this.refs,currentStep:this.currentStep,allowOptionalFields:this.allowOptionalFields,country:this.country,handleFormLoading:this.handleFormLoading}),i("div",{key:"94fd88a0aa9114677a2a1325e14bd059a08b6d72",class:"d-flex justify-content-between align-items-center"},i("div",{key:"bb0ba1762a15c92dbb71f98722b01b1b0324ebcf",class:"d-flex align-items-center",part:n},this.stepCounter),i("justifi-payment-provisioning-form-buttons",{key:"a3cab2c2c655a1bc6d1771c7b759e2b0adc971b0",currentStep:this.currentStep,totalSteps:this.totalSteps,formLoading:this.loading,formDisabled:this.formDisabled,previousStepButtonOnClick:this.previousStepButtonOnClick,nextStepButtonOnClick:this.nextStepButtonOnClick}))))}};export{f as justifi_payment_provisioning_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as a}from"./p-DOjVAAtq.js";import{c as t,a as c,F as i}from"./p-DiJD6Iqx.js";import{an as d}from"./p-Dj_zevuD.js";import"./p-BFTU3MAI.js";const s=t({additional_statement:c().nullable()});var o,l;!function(e){e.disputeReason="dispute_reason",e.productOrService="product_or_service",e.customerDetails="customer_details",e.cancellationPolicy="cancellation_policy",e.refundPolicy="refund_policy",e.duplicateCharge="duplicate_charge",e.electronicEvidence="electronic_evidence",e.shippingDetails="shipping_details",e.additionalStatement="additional_statement"}(o||(o={})),function(e){e.activity_log="activity_log",e.cancellationPolicy="cancellation_policy",e.customerCommunication="customer_communication",e.customerSignature="customer_signature",e.duplicateChargeDocumentation="duplicate_charge_documentation",e.receipt="receipt",e.refundPolicy="refund_policy",e.serviceDocumentation="service_documentation",e.shippingDocumentation="shipping_documentation",e.uncategorizedFile="uncategorized_file"}(l||(l={}));class n{set presignedUrl(e){this._presignedUrl=e}get presignedUrl(){return this._presignedUrl}async getFileString(){const e=new Promise(((e,a)=>{const t=new FileReader;t.onload=a=>{e(a.target.result)},t.onerror=()=>{a(new Error("Error reading file"))},t.readAsArrayBuffer(this._file)}));return await e}constructor(e,a){this._file=e,this.file_name=e.name,this.file_type=e.type,this.dispute_evidence_type=a}}const r=(e,a)=>{const t=e.target,c=t.name,i=t.files;a[c]=[];for(const e of i)a[c].push(new n(e,c))},f=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.acceptedTerms=!1,this.documents={uncategorized_file:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.additionalStatement)))}componentWillLoad(){this.form=new i(s)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t;return a("div",{key:"a03e78a3610b5bf23bf9611ed2225e839da41c5d"},a("div",{key:"235029013598b89a4d92c06cc468b1fb4147fc4c",class:"row gy-3"},a("div",{key:"f18cdb52f20817dc6dc3d16e91b4fee09ccda690",class:"col-12"},a("h2",{key:"37a18cbc0027cb3fd170fa5afad295d57cfc0f19",class:"h5",part:d},"Additional Evidence")),a("div",{key:"9cc4ef86508b8232e343f46fc64ccc78b42ac22f",class:"col-12"},a("form-control-textarea",{key:"93fb66f2e4ee72b58ff53c5010b1e5e16e9abbd7",label:"Is there anything else you would like to say about this dispute?",name:"additional_statement",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.additional_statement,inputHandler:this.inputHandler,errorText:this.errors.additional_statement})),a("div",{key:"cb3fe8f241e08df1984fc47820e723f00d34641d",class:"col-12"},a("form-control-file-v2",{key:"eeae63012b624078bfc3fa34553ed7aa8288a24b",label:"Additional files",name:"uncategorized_file",multiple:!0,helpText:"Upload any additional pieces of evidence that have not already been provided.",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.uncategorized_file}))))}},b=t({cancellation_policy_disclosure:c().nullable(),cancellation_rebuttal:c().nullable()}),h=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={cancellation_policy:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.cancellationPolicy)))}componentWillLoad(){this.form=new i(b)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c;return a("div",{key:"37c63086ec0dece44992be20f44d0b0f06ce3996"},a("div",{key:"0aab4b70d17ce769d847470b74cd2f0946845ed2",class:"row gy-3"},a("div",{key:"7cacadffe3a11231d9791dd3b536686e7cc2d539",class:"col-12"},a("h2",{key:"09c8227375b4231c4135a18d31667f069c5c847d",class:"h5",part:d},"Cancellation Policy")),a("div",{key:"4636e5b456294e6493e09859cf4d001d7e7b6c1a",class:"col-12"},a("form-control-textarea",{key:"e5e7be99ae8b18016c28388e7d165321b7aae062",label:"Cancellation Policy Disclosure",name:"cancellation_policy_disclosure",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.cancellation_policy_disclosure,inputHandler:this.inputHandler,errorText:this.errors.cancellation_policy_disclosure})),a("div",{key:"0885ca69088851f240ae22b5106a9989b4321f96",class:"col-12"},a("form-control-textarea",{key:"80ebcdae7bbf223109820735dacb4d2a8c1c8809",label:"Cancellation Rebuttal",name:"cancellation_rebuttal",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.cancellation_rebuttal,inputHandler:this.inputHandler,errorText:this.errors.cancellation_rebuttal})),a("div",{key:"3ddc4eaa4f086eee2758c2b53172a0f43622e741",class:"col-12"},a("form-control-file-v2",{key:"cb975ba4e455d2fc5959319a781a084b5af7b9f8",label:"Upload Cancellation Policy",name:"cancellation_policy",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.cancellation_policy}))))}},u=t({customer_name:c().nullable(),customer_email_address:c().nullable(),customer_billing_address:c().nullable()}),v=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={customer_signature:[],customer_communication:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.customerDetails)))}componentWillLoad(){this.form=new i(u)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c,i,s;return a("div",{key:"858dcd8508a6ef974faf5b97c04cbd224cea93c0"},a("div",{key:"7aef1bf1aaf5838e8f555b9f8680bc89f255d52c",class:"row gy-3"},a("div",{key:"f206b1c9958b39b242dfe2c899a0a98f16731dff",class:"col-12"},a("h2",{key:"92916cf3952026ce406e52ac70be08cbb9c0e2a4",class:"h5",part:d},"Customer Details")),a("div",{key:"f80d3f7624484c70380035ad1bed0c292d7524b6",class:"col-12"},a("form-control-text",{key:"1f762101dcda20301e4207e26e32d0d9808f141e",label:"Full Name",name:"customer_name",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.customer_name,inputHandler:this.inputHandler,errorText:this.errors.customer_name})),a("div",{key:"dc7b267094e7ff05194b96d5886788f56e31cae6",class:"col-12"},a("form-control-text",{key:"64abb76bb8f9cf640bb4b367facb43355194db2d",label:"Email",name:"customer_email_address",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.customer_email_address,inputHandler:this.inputHandler,errorText:this.errors.customer_email_address})),a("div",{key:"8774802d03a56029ee6611820b077496c0032d9e",class:"col-12"},a("form-control-textarea",{key:"2ffdd3ece9bbd6f7206508d96ba6a09e9b51e7e3",label:"Billing Address",name:"customer_billing_address",defaultValue:null===(c=this.disputeResponse)||void 0===c?void 0:c.customer_billing_address,inputHandler:this.inputHandler,errorText:this.errors.customer_billing_address})),a("div",{key:"481cc546dcf904bd2414c096aafe9b034be548c2",class:"col-12"},a("form-control-file-v2",{key:"763c89f78cf205bdf5f30cce01d8d96debfd12b0",label:"Customer Signature",name:"customer_signature",onChange:e=>r(e,this.documents),errorText:null===(i=this.documentErrors)||void 0===i?void 0:i.customer_signature})),a("div",{key:"bf358ed8e708f439877de74f18cb488b3fe65ecd",class:"col-12"},a("form-control-file-v2",{key:"e4c72136e11514b2dddac44a584b343a1846b077",label:"Customer Communication",name:"customer_communication",onChange:e=>r(e,this.documents),errorText:null===(s=this.documentErrors)||void 0===s?void 0:s.customer_communication}))))}},p=t({duplicate_charge_original_payment_id:c().nullable(),duplicate_charge_explanation:c().nullable()}),m=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={duplicate_charge_documentation:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.duplicateCharge)))}componentWillLoad(){this.form=new i(p)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c;return a("div",{key:"a2c44551e8089f9d9f30e99e93c146c160e78f45"},a("div",{key:"9eb60cf652ebfbb37336a350552666b30bd87e1d",class:"row gy-3"},a("div",{key:"ec776dee0a386b87851aca4a275b5aec09f2f78a",class:"col-12"},a("h2",{key:"e6c60f82ded8750f7211ffa7b2790d8572bf67c7",class:"h5",part:d},"Duplicate Charge")),a("div",{key:"6380b5a5be60a61d3bb2adcffad781388da2b6d2",class:"col-12"},a("form-control-text",{key:"b976b506913584ae88d35a30cfc42efb6a20a9e7",label:"Original Payment ID",name:"duplicate_charge_original_payment_id",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.duplicate_charge_original_payment_id,inputHandler:this.inputHandler,errorText:this.errors.duplicate_charge_original_payment_id})),a("div",{key:"f9ae261fbe01a5f4de3491b8ac2c7a1cd59a184d",class:"col-12"},a("form-control-textarea",{key:"cd3bf73a8374411113068c310b14101e8d9ab7fe",label:"Duplicate Charge Explanation",name:"duplicate_charge_explanation",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.duplicate_charge_explanation,inputHandler:this.inputHandler,errorText:this.errors.duplicate_charge_explanation})),a("div",{key:"f730411437abd1c6a5950e7a768390df2ea2102e",class:"col-12"},a("form-control-file-v2",{key:"8021ee00e94803edf3eb27ec834e05353ba985d5",label:"Duplicate Charge Documentation",name:"duplicate_charge_documentation",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.duplicate_charge_documentation}))))}},y=t({customer_purchase_ip_address:c().nullable()}),_=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={activity_log:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.electronicEvidence)))}componentWillLoad(){this.form=new i(y)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t;return a("div",{key:"b7ccea47ef4631e72192680468e9b5c370089766"},a("div",{key:"b33edf7018fe897a1b6d66edfbdf696fe4c4ad5d",class:"row gy-3"},a("div",{key:"3f191923eb587c7efcdeec93afa830f7045e5ca5",class:"col-12"},a("h2",{key:"6019125067e94159de463ff467f3a26a83efadb6",class:"h5",part:d},"Electronic Evidence")),a("div",{key:"36169fba21ebe835eccbbdfa61665dbbf1922d22",class:"col-12"},a("form-control-text",{key:"5cdd785662b43d8ac46b7ffa165fbf7b1d3008ae",label:"Purchase IP Address",name:"customer_purchase_ip_address",helpText:"The IP address used by the customer during the purchase.",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.customer_purchase_ip_address,inputHandler:this.inputHandler,errorText:this.errors.customer_purchase_ip_address})),a("div",{key:"b2b3fdabb36b09c369c887779519000b1f9eb40e",class:"col-12"},a("form-control-file-v2",{key:"f112588b597277444e3d826cd8d94f8699dafc22",label:"Activity Logs",name:"activity_log",helpText:"Any server or activity logs that provide evidence of the customer's access to or download of the purchased digital product. This information should encompass IP addresses, relevant timestamps, and any detailed records of activity.",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.activity_log}))))}},k=t({product_description:c().nullable(),service_date:c().nullable()}),g=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={service_documentation:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.productOrService)))}componentWillLoad(){this.form=new i(k)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c;return a("div",{key:"116c8109ff66ee49f71dd2942afd87802f0a7c55"},a("div",{key:"ad46e75181ecd8c30ba60c11f4d841ced13e77f0",class:"row gy-3"},a("div",{key:"7247495b2134d3abe73c65f115f82467b0ffbb74",class:"col-12"},a("h2",{key:"c9e1e882662d10242bf287c426fa976580521af8",class:"h5",part:d},"Product & Service Details")),a("div",{key:"4bf80f0e5bbf2fa8f2722bcf55f21339afb6e650",class:"col-12"},a("form-control-text",{key:"0c29fe5584bcaf6329efa1d24eb1a731459a99f6",label:"Product Description",name:"product_description",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.product_description,inputHandler:this.inputHandler,errorText:this.errors.product_description})),a("div",{key:"5a9338d6d046ecc9e9df64cab31c7ba50ce88e7d",class:"col-12"},a("form-control-date",{key:"51e2d0983faf533fa188e0d679446c2b1b17a9ee",label:"Service Date",name:"service_date",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.service_date,inputHandler:this.inputHandler,errorText:this.errors.service_date})),a("div",{key:"237e39cb91eef0d6e5ddcb6c0ff0d4bccb64cfe2",class:"col-12"},a("form-control-file-v2",{key:"5eee43125a7ded5640735f25c9713fc98666df98",label:"Service Documentation",name:"service_documentation",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.service_documentation}))))}},x=t({refund_policy_disclosure:c().nullable(),refund_refusal_explanation:c().nullable()}),j=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={refund_policy:[],receipt:[]},this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.refundPolicy)))}componentWillLoad(){this.form=new i(x)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c,i;return a("div",{key:"70c6484a73b7bb3c794703f08eee51aaedc564f2"},a("div",{key:"26743bb218cfdaaf8f99f75582afc06b45a45584",class:"row gy-3"},a("div",{key:"d9fca9e6a0985cf2c8746b54f26c8fcd4c198382",class:"col-12"},a("h2",{key:"428b73ad90c7f6b73980ff51ce7936dd7fe40217",class:"h5",part:d},"Refund Policy and Receipt")),a("div",{key:"7cbca206b3d9aa7669242b33fdd84712f6d6a49d",class:"col-12"},a("form-control-textarea",{key:"5d7cadc32a5c6f95c0cefc89eb81e1f5d62dafac",label:"Refund Policy Disclosure",name:"refund_policy_disclosure",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.refund_policy_disclosure,inputHandler:this.inputHandler})),a("div",{key:"bd1bfcea8114595f34bb477c88d18dc9d4094821",class:"col-12"},a("form-control-textarea",{key:"cb08d0e1e206079e97929d4008fc8f5d7561b342",label:"Refund Refusal Explanation",name:"refund_refusal_explanation",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.refund_refusal_explanation,inputHandler:this.inputHandler})),a("div",{key:"b692266abea088b1818ade9243ffff67d556a196",class:"col-12"},a("form-control-file-v2",{key:"79fe63b4949a3181a4afffffb8ab5676c175774c",label:"Upload Refund Policy",name:"refund_policy",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.refund_policy})),a("div",{key:"ce43bc526887e61e58c30aed49e75d23c04d74d1",class:"col-12"},a("form-control-file-v2",{key:"6f743b261c533985aedc5d3dc0d4e706f9ad9a71",label:"Upload Receipt",name:"receipt",onChange:e=>r(e,this.documents),errorText:null===(i=this.documentErrors)||void 0===i?void 0:i.receipt}))))}},O=t({shipping_carrier:c().nullable(),shipping_tracking_number:c().nullable(),shipping_date:c().nullable(),shipping_address:c().nullable()}),T=class{constructor(a){e(this,a),this.documentErrors={},this.errors={},this.documents={shipping_documentation:[]},this.documentList=[],this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((t=>e(t,a,o.shippingDetails)))}componentWillLoad(){this.form=new i(O)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,t,c,i,s;return a("div",{key:"0cf5535a17c98e536665690e19857e6cad62a6dd"},a("div",{key:"bb42bc4f9732c68b59d29b520fa8b72cf0169d60",class:"row gy-3"},a("div",{key:"aff7c671db0b966b128ab05ff574be7f65ae89ae",class:"col-12"},a("h2",{key:"8910100bf94d4ac11f8a252c03d8fa09b4b016ac",class:"h5",part:d},"Shipping Details")),a("div",{key:"392d3d1ca2fb607d3e82b35813e5a39254bb5598",class:"col-12"},a("form-control-text",{key:"c857a5e60c66a1476c509937ccf5907ddb8bb69b",label:"Shipping Carrier Name",name:"shipping_carrier",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.shipping_carrier,inputHandler:this.inputHandler,errorText:this.errors.shipping_carrier})),a("div",{key:"e98ee583d1333752dc20a8aa34d06680910d868b",class:"col-12"},a("form-control-text",{key:"07a9d25aac27fe726cfb216e77c937678f7fa592",label:"Tracking Number",name:"shipping_tracking_number",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.shipping_tracking_number,inputHandler:this.inputHandler,errorText:this.errors.shipping_tracking_number})),a("div",{key:"f58bb675c12b21dfcabf0e0ef1194627b5652d29",class:"col-12"},a("form-control-date",{key:"546063536d78767b2e81ae7c686a7e761602ee3b",label:"Date Shipped",name:"shipping_date",defaultValue:null===(c=this.disputeResponse)||void 0===c?void 0:c.shipping_date,inputHandler:this.inputHandler,errorText:this.errors.shipping_date})),a("div",{key:"c197611cc502e5cfaf67461eee9cb606d9cdc14a",class:"col-12"},a("form-control-textarea",{key:"2afe4380f738553f308aec1c747152e9f6289d26",label:"Shipping Address",name:"shipping_address",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.shipping_address,inputHandler:this.inputHandler,errorText:this.errors.shipping_address})),a("div",{key:"98b0312297d02c4146ad6db2ce3b52235b8c9bb2",class:"col-12"},a("form-control-file-v2",{key:"1781b796e35fdeb9a11485273cc667fca33dedd4",label:"Shipping Documentation",name:"shipping_documentation",onChange:e=>r(e,this.documents),errorText:null===(s=this.documentErrors)||void 0===s?void 0:s.shipping_documentation}))))}};export{f as justifi_additional_statement,h as justifi_cancellation_policy,v as justifi_customer_details,m as justifi_duplicate_charge,_ as justifi_electronic_evidence,g as justifi_product_or_service,j as justifi_refund_policy,T as justifi_shipping_details}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as s}from"./p-DOjVAAtq.js";import{f as i}from"./p-BS7OgSQe.js";import{D as a,am as r}from"./p-Dj_zevuD.js";import{B as c}from"./p-CJ9qo7_g.js";import{S as d}from"./p-BhCH9S0e.js";import{S as o}from"./p-BIcS6lTe.js";import"./p-CZfYo5-1.js";import{C as n,a as h}from"./p-Cjcsf8ku.js";import{g as p,a as f}from"./p-D2muobcE.js";import{D as l}from"./p-i--LPP1s.js";import{D as u}from"./p-Bg2SZArf.js";import{c as b,J as y}from"./p-DfsX5bt_.js";import"./p-HXpYMWUU.js";import"./p-ty1sI-fI.js";import"./p-a6tcNl_T.js";import"./p-DdMxswn1.js";import"./p-CPKSE7M4.js";import"./p-BH0Xfn-F.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-yiqa5abX.js";const m=({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:c=()=>{}})=>{var d;try{const c=await s.submitDisputeResponse(t,e,i);if(c.error){return r({error:f(c.error),code:p(null===(d=c.error)||void 0===d?void 0:d.code),severity:n.ERROR})}a(c)}catch(e){const t=p(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return c()}},v=class{constructor(s){e(this,s),this.clickEvent=t(this,"click-event"),this.errorEvent=t(this,"error-event"),this.submitEvent=t(this,"submit-event")}acceptDispute(){m({disputeId:this.dispute.id,authToken:this.authToken,service:new l})({payload:{forfeit:!0},onSuccess:e=>{this.submitEvent.emit({response:e})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}})}initiateRespondToDispute(){this.clickEvent.emit({name:u.respondToDispute})}render(){var e,t,n,h,p,f,l;return s(d,{key:"d268295bb070b948984332bd763407dd2abe8467"},this.isLoading&&s("div",{key:"e9083c5f4f8cb88a348dc5099be678cf0c44c6fd",style:{marginBottom:"8px"}},s(o,{key:"dd847619a087adcf9ca142bd705073b5bd2cbb38",height:"28px",width:"70%",styles:{marginBottom:"16px"}}),s(o,{key:"abce0be539824cabcdc91cc1935acda2928738be",height:"18px",styles:{marginBottom:"8px"}}),s(o,{key:"fd50de2ce4ff82a99bd9435438f8714173f07a63",height:"18px",styles:{marginBottom:"8px"}})),(null===(e=this.dispute)||void 0===e?void 0:e.needsResponse)&&s("div",{key:"44d88a0e658669f0cb703e7a80008788957b4075",part:a},s("h1",{key:"cbcf492cd4cb236f8241a03e9a722650c4a86a33",class:"h4",part:r},"This payment is disputed"),s("p",{key:"c30d8f5246aaf75415e6334acc2d3ab53fb200c5"},"The cardholder is disputing this payment. You may accept this dispute, or proceed to provide evidence in a counter dispute."),s("h2",{key:"929bdc03a93e66cd95ad0985df42cee6e1448ee1",class:"h5"},"Dispute details"),s("div",{key:"71ace963ec6035edfadb8e3391c2a025203ffb8b",class:"d-table gap-2"},s("div",{key:"13feb89ef8720eb97fb58bb5a01c650339b044a0",class:"d-table-row gap-2"},s("span",{key:"f53edd37be55640f22d6fc8418c2c7a2fb68d4eb",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Amount"),s("span",{key:"ee91d5ecc2c3c921106fed6437b0122d87ffc590",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},i(null===(t=this.dispute)||void 0===t?void 0:t.amount))),s("div",{key:"f8d03855088572719cc69eb70846baaca626873f",class:"d-table-row gap-2"},s("span",{key:"1da829c98c3799d5f426078084d472fe21ea8714",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Reason"),s("span",{key:"66251cc54a379c54d1f10de9b63c3acc8441102e",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},null===(n=this.dispute)||void 0===n?void 0:n.reason)),s("div",{key:"75fb4722061c2ce1552aaf019cd55fe2e18d69bc",class:"d-table-row gap-2"},s("span",{key:"0e1207c6ec9b5e0a1987c3dc27c7237b829c0e24",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Due Date"),s("span",{key:"f59cee5df009fbe55a5afc7c862d127dcf9c39bc",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},null===(h=this.dispute)||void 0===h?void 0:h.due_date))),s("div",{key:"843db57269e37dc9a6fe870efaac3345acd69f8c",class:"d-flex gap-2 mt-4 justify-content-end"},s(c,{key:"6bc8dc5a4d5b5fb3b4bd060f869cc154b5f38911",variant:"secondary",onClick:()=>this.acceptDispute()},"Accept dispute"),s(c,{key:"ece8a6e944501b889d9d881ae08181261aa630c1",variant:"primary",onClick:()=>this.initiateRespondToDispute()},"Counter dispute"))),(null===(p=this.dispute)||void 0===p?void 0:p.underReview)&&s("div",{key:"5801625ebc25850e4001d9961e20b9f589ba071a"},s("h1",{key:"6a20320f19deea6e4cd2ad391ef6e3adf16d9272",class:"h4"},"This payment is disputed and under review"),s("p",{key:"5fbfbe7a8c80674f1d65fa5f989a2db428dcce73"},"The cardholder is disputing this payment. A counter dispute has been submitted and is under review.")),(null===(f=this.dispute)||void 0===f?void 0:f.won)&&s("div",{key:"7531e3e361613accf7f6b6085ba94dbaafcb4915"},s("h1",{key:"6f613bf334d77f89ff9fff4fb95bcb60b81154fd",class:"h4"},"This payment was disputed"),s("p",{key:"148b60d2220cdd181cc4fa7692b524c1da049aea"},"The cardholder disputed this payment and the card issuer has settled it in your favor.")),(null===(l=this.dispute)||void 0===l?void 0:l.lost)&&s("div",{key:"905c1f81c5d4d0e2dac524fa11cb7ae977bd8c35"},s("h1",{key:"de0004f4f08d07e3bbeb224e900c5f89d58f3ecd",class:"h4"},"This payment was disputed"),s("p",{key:"40f37c79108a79989b7e5a6d2d90a855b37ea2a3"},"The cardholder disputed this payment and the card issuer has settled it in their favor.")))}},k=class{constructor(s){e(this,s),this.errorEvent=t(this,"error-event"),this.errorMessage=null,this.apiOrigin="https://wc-proxy.justifi.ai",this.handleErrorEvent=e=>{this.errorMessage=e.detail.message,this.errorEvent.emit(e.detail)}}componentWillLoad(){b(),this.analytics=new y(this),this.initializeDisputeServiceMethods()}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.cleanup()}propChanged(){this.initializeDisputeServiceMethods()}initializeDisputeServiceMethods(){this.disputeId&&this.authToken?(this.updateDisputeResponse=(({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:c=()=>{}})=>{var d;try{const c=await s.updateDisputeResponse(t,e,i);if(c.error)return r({error:f(c.error),code:p(null===(d=c.error)||void 0===d?void 0:d.code),severity:n.ERROR});a(c)}catch(e){const t=p(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return c()}})({disputeId:this.disputeId,authToken:this.authToken,service:new l}),this.createDisputeEvidence=(({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:c=()=>{}})=>{var d;try{const c=await s.createDisputeEvidence(t,e,i);if(c.error)return r({error:f(c.error),code:p(null===(d=c.error)||void 0===d?void 0:d.code),severity:n.ERROR});a(c)}catch(e){const t=p(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return c()}})({disputeId:this.disputeId,authToken:this.authToken,service:new l}),this.submitDisputeResponse=m({disputeId:this.disputeId,authToken:this.authToken,service:new l})):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:h.MISSING_PROPS,message:this.errorMessage,severity:n.ERROR}))}render(){return s(d,{key:"4a6fcddbe3275068b9699dfc5c60adeff77f2192"},s("justifi-dispute-response-core",{key:"80bd93d2ec9c64695d8b1d8bb7a4b59b2418a14f","onError-event":this.handleErrorEvent,"dispute-id":this.disputeId,disputeResponse:this.disputeResponse,createDisputeEvidence:this.createDisputeEvidence,updateDisputeResponse:this.updateDisputeResponse,submitDisputeResponse:this.submitDisputeResponse}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}},j=class{constructor(i){e(this,i),this.clickEvent=t(this,"click-event"),this.errorEvent=t(this,"error-event"),this.stepCompleteEvent=t(this,"complete-form-step-event"),this.submitEvent=t(this,"submit-event"),this.disputeResponse={},this.isLoading=!1,this.documentList=[],this.documentErrors={},this.currentStep=0,this.componentStepMapping=[()=>s("justifi-product-or-service",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-customer-details",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-cancellation-policy",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-refund-policy",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-duplicate-charge",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-electronic-evidence",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-shipping-details",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-additional-statement",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors})],this.saveData=async(e,t)=>{if(Object.keys(e).length)return this.isLastStep?this.submitDisputeResponse({payload:e,onSuccess:e=>{this.submitEvent.emit({response:e}),this.stepCompleteEvent.emit({response:e,formStep:t})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}}):this.updateDisputeResponse({payload:e,onSuccess:e=>{this.disputeResponse=Object.assign({},e.data),this.stepCompleteEvent.emit({response:e,formStep:t})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}});this.stepCompleteEvent.emit({response:null,formStep:t})},this.initializeMakePresignedURLs=async()=>{const e=this.documentList.map((e=>this.getPresignedFileUrl(e)));return await Promise.all(e)},this.initializeFileUploads=async()=>{const e=this.documentList.map((e=>this.uploadDocument(e)));return Promise.all(e)},this.getPresignedFileUrl=async e=>this.createDisputeEvidence({payload:{file_name:e.file_name,file_type:e.file_type,dispute_evidence_type:e.dispute_evidence_type},onSuccess:t=>{e.presignedUrl=t.data.presigned_url},onError:({error:t,code:s,severity:i})=>{const a={[e.dispute_evidence_type]:t};this.documentErrors=Object.assign(Object.assign({},this.documentErrors),a),this.errorEvent.emit({errorCode:s,message:t,severity:i})}}),this.uploadDocument=async e=>{const t=await e.getFileString();if(!e.presignedUrl)throw new Error("Presigned URL is not set");return await fetch(e.presignedUrl,{method:"PUT",body:t})},this.handleSubmit=async(e,t,s)=>{if(this.isLoading=!0,t.length){if(this.documentErrors={},this.documentList=t,await this.initializeMakePresignedURLs(),Object.keys(this.documentErrors).length)throw this.isLoading=!1,new Error("Could not presign all documents");await this.initializeFileUploads()}await this.saveData(e,s),this.isLoading=!1},this.onCancel=()=>{this.clickEvent.emit({name:u.cancelDispute})},this.onBack=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.previousStep}),await this.handleSubmit(e,t,s),this.currentStep--}))},this.onNext=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.nextStep}),await this.handleSubmit(e,t,s),this.currentStep++}))},this.onSubmit=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.submit});const i=Object.assign(Object.assign({},e),{forfeit:!1});await this.handleSubmit(i,t,s)}))}}get currentStepComponent(){return this.componentStepMapping[this.currentStep]()}get isLastStep(){return this.currentStep===this.componentStepMapping.length-1}get isFirstStep(){return 0===this.currentStep}render(){return s("div",{key:"f8aa436de4217a890cb2c30d3e27aae405c69275",class:"row gy-3"},s("div",{key:"a49685c530a74ddc0c001f7aaa93a88083d050fa",class:"col-12"},s("h1",{key:"15344ecf9317a883ca035637b943435d51663ad6",class:"h4",part:r},"Counter dispute")),s("div",{key:"84005717b34e9f4a346bbd21c43f849f8238b452",class:"col-12"},this.currentStepComponent),s("div",{key:"f210b5351166085cc1638b4170af6e20c50080f2",class:"col-12"},s("div",{key:"8294937c85b26845a9b22d5fd7afcb0caa7dbad1",class:"d-flex gap-2 mt-4 justify-content-end"},this.isFirstStep?s(c,{variant:"secondary",onClick:()=>this.onCancel(),disabled:this.isLoading,isLoading:this.isLoading},"Cancel"):s(c,{variant:"secondary",onClick:()=>this.onBack(),disabled:this.isLoading,isLoading:this.isLoading},"Back"),this.isLastStep?s(c,{variant:"primary",onClick:()=>this.onSubmit(),disabled:this.isLoading,isLoading:this.isLoading},"Submit Counter Dispute"):s(c,{variant:"primary",onClick:()=>this.onNext(),disabled:this.isLoading,isLoading:this.isLoading},"Next"))))}};export{v as justifi_dispute_notification,k as justifi_dispute_response,j as justifi_dispute_response_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as i}from"./p-DOjVAAtq.js";import{C as r,a as e}from"./p-Cjcsf8ku.js";import{c as o,J as a}from"./p-DfsX5bt_.js";import{T as n}from"./p-CQQ0H4Pb.js";import"./p-a6tcNl_T.js";import"./p-HXpYMWUU.js";import{e as p}from"./p-CPKSE7M4.js";import"./p-CLHwhyvu.js";import"./p-B5rtFhtR.js";import"./p-BH0Xfn-F.js";import{g as c,a as h}from"./p-D2muobcE.js";import{m,S as u}from"./p-CTAOJGVx.js";import{S as d}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";import{d as l}from"./p-890S0Nwr.js";import"./p-yiqa5abX.js";import"./p-ty1sI-fI.js";import"./p-BS7OgSQe.js";import"./p-DdMxswn1.js";import"./p-Bm8T-MOQ.js";import"./p-Dj_zevuD.js";const j=class{constructor(i){t(this,i),this.errorEvent=s(this,"error-event"),this.errorMessage=null,this.columns=l,this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)}}componentWillLoad(){o(),this.analytics=new a(this),this.initializeGetData()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetData()}initializeGetData(){this.initializeGetTerminals(),this.initializeGetSubAccounts()}initializeGetTerminals(){this.accountId&&this.authToken?this.getTerminals=(({id:t,authToken:s,service:i})=>async({params:e,onSuccess:o,onError:a})=>{var n,m;try{const u=await i.fetchTerminals(t,s,e);if(u.error)return a({error:h(u.error),code:c(null===(m=u.error)||void 0===m?void 0:m.code),severity:r.ERROR});{const t=Object.assign({},u.page_info);o({terminals:(null===(n=u.data)||void 0===n?void 0:n.map((t=>new p(t))))||[],pagingInfo:t})}}catch(t){const s=c(null==t?void 0:t.code);return a({error:t.message||t,code:s,severity:r.ERROR})}})({id:this.accountId,authToken:this.authToken,service:new n}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:e.MISSING_PROPS,message:this.errorMessage,severity:r.ERROR}))}initializeGetSubAccounts(){this.accountId&&this.authToken&&(this.getSubAccounts=m({accountId:this.accountId,authToken:this.authToken,service:new u}))}render(){return i(d,{key:"52dcea711707c73644e44b53ef7ae5a695e9b6d4"},i("terminals-list-core",{key:"d804664cf67f0e8f4f3eedc653f2679794184798",getTerminals:this.getTerminals,getSubAccounts:this.getSubAccounts,"onError-event":this.handleErrorEvent,columns:this.columns}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{j as justifi_terminals_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as a,h as e,H as s}from"./p-DOjVAAtq.js";import{E as c}from"./p-CLHwhyvu.js";import{aa as t,ab as i,ac as b,ad as d,ae as f}from"./p-Dj_zevuD.js";const n=class{constructor(e){a(this,e),this.paging=c,this.params={}}render(){return e(s,{key:"67ec7328221f28064498ebc359ec2100b33df423"},e("nav",{key:"503d4f3c3e236797a1ef6309edb00d8d0c2be345","aria-label":"Table pagination",class:"d-flex justify-content-end gap-3"},e("ul",{key:"9573011f1775928268a0b0932890a6c25050e3fe",class:"pagination m-0"},e("li",{key:"0247aa3068849046f8282124e7e168c381fd6340",class:"page-item "+(this.paging.has_previous?"":" disabled")},e("button",{key:"5608ce502116c96e9400fdfeb0cfb4e64bc25a55",class:"page-link",onClick:a=>{a.preventDefault(),this.paging.handleClickPrevious(this.paging.start_cursor)},part:this.paging.has_previous?t:i},e("span",{key:"7c08295d1c5edd4950bb577272a8745e3cd3d692",class:"me-1",part:b},"«"),e("span",{key:"cd766ba6a6e6c31509442537a4f8345f2cd16251",part:d},"Previous"))),e("li",{key:"54c810056bc6d74be7245a47f54c8d4b75068feb",class:"page-item "+(this.paging.has_next?"":" disabled")},e("button",{key:"5ff8d8621accf87017980b527823640061b27c18",class:"page-link",onClick:a=>{a.preventDefault(),this.paging.handleClickNext(this.paging.end_cursor)},part:this.paging.has_next?t:i},e("span",{key:"2dc934a96eb1be000eb7e016507ddc926c68db2a",part:d},"Next"),e("span",{key:"4e7cbcbfd2e29969f2019eacde0a24d07a72cbb3",class:"ms-1",part:f},"»"))))))}};export{n as pagination_menu}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as t}from"./p-DOjVAAtq.js";import{r as o}from"./p-Dj_zevuD.js";import{S as s}from"./p-BhCH9S0e.js";import"./p-CZfYo5-1.js";const c=class{constructor(t){e(this,t)}render(){return t(s,{key:"e9d2508bca7640c281b2d7c1240d906f91118027",class:"payment-method"},t("div",{key:"e6cc572415e9eea51645081c70463b51effcd7ef",class:"radio-list-item p-3",part:o,onClick:this.clickHandler,hidden:this.radioButtonHidden},t("form-control-radio",{key:"e57c30cc26f956eedf5511bd8f8c028b4bf08fee",name:"paymentMethodType",value:this.paymentMethodOptionId,checked:this.isSelected,label:this.label})))}};export{c as payment_method_option}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,h as s,H as a}from"./p-DOjVAAtq.js";import{c as i,l as r,b as o,U as h,a as
|
|
1
|
+
import{r as t,c as e,h as s,H as a}from"./p-DOjVAAtq.js";import{c as i,l as r,b as o,U as h,a as c}from"./p-Dj_zevuD.js";import{F as l}from"./p-D9Yus-je.js";import"./p-CZfYo5-1.js";const d=class{constructor(s){t(this,s),this.formControlInput=e(this,"formControlInput"),this.formControlBlur=e(this,"formControlBlur"),this.isFocused=!1,this.maxDate=this.currentDate,this.handleFormControlInput=t=>{const e=t.target.value;this.inputHandler(this.name,e),this.formControlInput.emit({name:this.name,value:e})}}handleDefaultValueChange(t){this.updateInput(t)}get currentDate(){return this.showTime?(new Date).toISOString().slice(0,16):(new Date).toISOString().split("T")[0]}componentDidLoad(){this.updateInput(this.defaultValue)}updateInput(t){this.dateInput.value=t}get part(){let t=i;return this.errorText&&(t=o),this.disabled&&(t=h),this.isFocused&&(t=c),t}render(){return s(a,{key:"8e5820c8f07562ce28e3b95c4948cb7c311d48d6"},s("div",{key:"1dd0cbd495d132064808cc81bc272b92f7df95af",class:"form-group d-flex flex-column"},s("div",{key:"82f27392fd4bdbb106db3ea4219eeb75d99a7c78",class:"d-flex gap-2"},s("label",{key:"a6ab3679c84b6f22e4c27ac4cb9764e77f97eed3",part:r,class:"form-label",htmlFor:this.name},this.label),s("form-control-tooltip",{key:"f481b59809157482acd955d8f2bdb60e5a91e164",helpText:this.helpText})),s("input",{key:"6803e25bbd12858678fa08a8230ca91268541624",type:this.showTime?"datetime-local":"date",ref:t=>this.dateInput=t,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",disabled:this.disabled,max:this.maxDate}),s(l,{key:"0237d93c756aaea690eda467b0497ce2c0d8c904",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{d as form_control_date}
|