@justifi/webcomponents 6.12.3 → 6.12.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Analytics-DcqsdFaD.js → Analytics-BERGweGK.js} +2 -3
- package/dist/cjs/{Plaid-BlSGeGpn.js → Plaid-BRSyOOuw.js} +60 -4
- package/dist/cjs/additional-questions-form-step_14.cjs.entry.js +151 -19
- package/dist/cjs/{justifi-additional-statement_8.cjs.entry.js → additional-statement_8.cjs.entry.js} +24 -24
- package/dist/cjs/bank-account-form.cjs.entry.js +2 -2
- package/dist/cjs/{business-identity-schema-DWWtSiUF.js → business-identity-schema-DI9XFbaD.js} +67 -0
- package/dist/cjs/{business.service-BheJs82v.js → business.service-Z9OACEQL.js} +1 -2
- package/dist/cjs/card-form.cjs.entry.js +2 -2
- package/dist/cjs/{check-pkg-version-DFTQGZz1.js → check-pkg-version-ByKpJklZ.js} +1 -1
- package/dist/cjs/{checkout.service-DZKdHQQq.js → checkout.service-BZOyqXgW.js} +1 -2
- package/dist/cjs/custom-popper_2.cjs.entry.js +2 -2
- package/dist/cjs/{justifi-dispute-notification_3.cjs.entry.js → dispute-notification_2.cjs.entry.js} +67 -90
- package/dist/cjs/{event-types-BWQT2lwu.js → event-types-AU1B76Vm.js} +30 -0
- package/dist/cjs/form-address-fields_3.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-file.cjs.entry.js +2 -2
- package/dist/cjs/form-control-monetary.cjs.entry.js +2 -2
- package/dist/cjs/form-control-number_2.cjs.entry.js +89 -0
- package/dist/cjs/form-control-radio.cjs.entry.js +2 -2
- package/dist/cjs/form-control-select_2.cjs.entry.js +4 -4
- package/dist/cjs/{get-business-TFzhaBXn.js → get-business-aR-C83KX.js} +2 -2
- package/dist/cjs/{get-payment-details-DL5FmIyF.js → get-payment-details-dwhA02Zl.js} +2 -3
- package/dist/cjs/{get-subaccounts-CVK4O7th.js → get-subaccounts-B1jmSa2d.js} +2 -3
- package/dist/cjs/hidden-input_2.cjs.entry.js +5 -5
- package/dist/cjs/internal-button.cjs.entry.js +1 -1
- package/dist/cjs/justifi-apple-pay_11.cjs.entry.js +12 -13
- package/dist/cjs/justifi-bank-account-billing-form-simple.cjs.entry.js +5 -6
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +5 -6
- package/dist/cjs/justifi-billing-form-full.cjs.entry.js +1 -1
- package/dist/cjs/justifi-business-details.cjs.entry.js +7 -8
- package/dist/cjs/justifi-business-form.cjs.entry.js +10 -12
- package/dist/cjs/justifi-card-billing-form-simple.cjs.entry.js +1 -1
- package/dist/cjs/justifi-card-form.cjs.entry.js +5 -6
- package/dist/cjs/justifi-checkout.cjs.entry.js +4 -5
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +3 -4
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +190 -27
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +65 -18
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +11071 -23
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +9 -10
- package/dist/cjs/justifi-payment-details.cjs.entry.js +16 -17
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +2 -2
- package/dist/cjs/justifi-payments-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payout-details.cjs.entry.js +10 -11
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +7 -8
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +3 -4
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +9 -10
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +7 -8
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +5 -6
- package/dist/cjs/justifi-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +4 -5
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +178 -24
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +2 -3
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +8 -9
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{package-bM0MyhTf.js → package-B6L3zyfG.js} +1 -1
- package/dist/cjs/payment-method-option.cjs.entry.js +1 -1
- package/dist/cjs/{payment-provisioning-actions-BO7dzIm1.js → payment-provisioning-actions-BiSpysjW.js} +2 -2
- package/dist/cjs/{payment.service-sZKlg2Jq.js → payment.service-ByrgA_QZ.js} +1 -2
- package/dist/cjs/{payout.service-BcQVsMCS.js → payout.service-CnQm_BpU.js} +1 -2
- package/dist/cjs/{payouts-status-CwgOMz-S.js → payouts-status-AuS3Mp0V.js} +2 -2
- package/dist/cjs/{plaid.service-BcgO2VXC.js → plaid.service-Dlb8EUR8.js} +1 -2
- package/dist/cjs/radio-list-item.cjs.entry.js +1 -1
- package/dist/cjs/table-filters-menu.cjs.entry.js +1 -1
- package/dist/cjs/terminal-quantity-selector.cjs.entry.js +1 -1
- package/dist/cjs/{terminal.service-CjMMWSh3.js → terminal.service-BdwHQ3Vv.js} +1 -2
- package/dist/cjs/{utils-DbTucCTO.js → utils-FVGp6se3.js} +1 -1
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/api/Terminal.js +1 -1
- package/dist/collection/collection-manifest.json +10 -16
- package/dist/collection/components/business-forms/owner-form/owner-form-inputs.js +2 -2
- package/dist/collection/components/business-forms/owner-form/owner-form.js +226 -12
- package/dist/collection/components/checkouts-list/checkouts-list-filters.js +2 -2
- package/dist/collection/components/checkouts-list/justifi-checkouts-list.js +166 -16
- package/dist/collection/components/dispute-management/{justifi-dispute-notification.js → dispute-notification.js} +5 -6
- package/dist/collection/components/dispute-management/dispute-response/{justifi-additional-statement.js → additional-statement.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-cancellation-policy.js → cancellation-policy.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-customer-details.js → customer-details.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{dispute-response-core.js → dispute-response.js} +105 -77
- package/dist/collection/components/dispute-management/dispute-response/{justifi-duplicate-charge.js → duplicate-charge.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-electronic-evidence.js → electronic-evidence.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-product-or-service.js → product-or-service.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-refund-policy.js → refund-policy.js} +3 -3
- package/dist/collection/components/dispute-management/dispute-response/{justifi-shipping-details.js → shipping-details.js} +3 -3
- package/dist/collection/components/dispute-management/justifi-dispute-management.js +78 -11
- package/dist/collection/components/filters/table-filters-menu.js +1 -1
- package/dist/collection/components/gross-payment-chart/justifi-gross-payment-chart.js +79 -15
- package/dist/collection/components/modular-checkout/justifi-modular-checkout.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-bank-account-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-bank-account-form.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-billing-form-full.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-card-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-card-form.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/justifi-checkout-summary.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/payment-method-option.js +1 -1
- package/dist/collection/components/order-terminals/justifi-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/justifi-payment-details.js +8 -8
- package/dist/collection/components/payment-transactions-list/justifi-payment-transactions-list.js +1 -1
- package/dist/collection/components/payments-list/justifi-payments-list-filters.js +2 -2
- package/dist/collection/components/payments-list/justifi-payments-list.js +1 -1
- package/dist/collection/components/payout-details/justifi-payout-details.js +3 -3
- package/dist/collection/components/payout-transactions-list/justifi-payout-transactions-list.js +1 -1
- package/dist/collection/components/payouts-list/justifi-payouts-list-filters.js +2 -2
- package/dist/collection/components/payouts-list/justifi-payouts-list.js +1 -1
- package/dist/collection/components/terminal-orders-list/justifi-terminal-orders-list-filters.js +3 -3
- package/dist/collection/components/terminal-orders-list/justifi-terminal-orders-list.js +134 -10
- package/dist/collection/components/terminals-list/justifi-terminals-list-filters.js +1 -1
- package/dist/collection/components/terminals-list/justifi-terminals-list.js +1 -1
- package/dist/collection/components/tokenize-payment-method/justifi-tokenize-payment-method.js +1 -1
- package/dist/collection/ui-components/custom-popper/custom-popper.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/internal-button.js +1 -1
- package/dist/collection/ui-components/radio-list-item.js +1 -1
- 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-skeleton.js +1 -1
- package/dist/docs.json +5763 -6945
- package/dist/esm/{Analytics-Cyc3ZLPx.js → Analytics-B1bQP71R.js} +2 -3
- package/dist/esm/{Plaid-BuKEVgbB.js → Plaid-l6nNIjab.js} +58 -3
- package/dist/esm/additional-questions-details_5.entry.js +2 -2
- package/dist/esm/additional-questions-form-step_14.entry.js +156 -24
- package/dist/esm/additional-questions_5.entry.js +2 -2
- package/dist/esm/{justifi-additional-statement_8.entry.js → additional-statement_8.entry.js} +19 -19
- package/dist/esm/{badge-B6dp1XGV.js → badge-Dlcl9qdm.js} +1 -1
- package/dist/esm/bank-account-billing-form-simple_4.entry.js +5 -5
- package/dist/esm/bank-account-form.entry.js +4 -4
- package/dist/esm/bank-account-read-only-value.entry.js +1 -1
- package/dist/esm/business-identity-schema-D-Nk9aGV.js +163 -0
- package/dist/esm/{business.service-BPbZ5fxQ.js → business.service-C31wbMVs.js} +1 -2
- package/dist/esm/{button-DRdaAudE.js → button-BvzOzV4l.js} +1 -1
- package/dist/esm/card-form.entry.js +4 -4
- package/dist/esm/{check-pkg-version-6iGDh82c.js → check-pkg-version-CNwUC4SV.js} +1 -1
- package/dist/esm/{checkout.service-CJMfFKyS.js → checkout.service-cVdOGDuI.js} +1 -2
- package/dist/esm/{country-config-P042rrI3.js → country-config-B_fuF6JU.js} +1 -1
- package/dist/esm/custom-popper_2.entry.js +3 -3
- package/dist/esm/{justifi-dispute-notification_3.entry.js → dispute-notification_2.entry.js} +68 -90
- package/dist/esm/{event-types-Bg2SZArf.js → event-types-DalU_6SB.js} +29 -1
- package/dist/esm/form-address-fields_3.entry.js +5 -5
- package/dist/esm/form-control-checkbox.entry.js +3 -3
- package/dist/esm/form-control-date.entry.js +4 -4
- package/dist/esm/{form-control-error-text-DVedKyhp.js → form-control-error-text-Di9QePY5.js} +1 -1
- package/dist/esm/form-control-file-v2_2.entry.js +5 -5
- package/dist/esm/form-control-file.entry.js +4 -4
- package/dist/esm/{form-control-help-text-D-349cNw.js → form-control-help-text-DGMpMuAm.js} +1 -1
- package/dist/esm/form-control-monetary-provisioning.entry.js +3 -3
- package/dist/esm/form-control-monetary.entry.js +5 -5
- package/dist/esm/form-control-number_2.entry.js +86 -0
- package/dist/esm/form-control-radio.entry.js +3 -3
- package/dist/esm/form-control-select_2.entry.js +6 -6
- package/dist/esm/{get-business-DIpEbczl.js → get-business-Gg6qn5on.js} +2 -2
- package/dist/esm/{get-payment-details-DjBou5Fu.js → get-payment-details-BiWgSJau.js} +2 -3
- package/dist/esm/{get-subaccounts-CgDWE_5o.js → get-subaccounts-CkjZeR9U.js} +2 -3
- package/dist/esm/{header-1-Bl7MHW0w.js → header-1-evYxFIGN.js} +1 -1
- package/dist/esm/{header-3-C7JJVnMG.js → header-3-BUDap2xY.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +7 -7
- package/dist/esm/{index.esm-BHdVU4hV.js → index.esm-CgNcFueq.js} +1 -1
- package/dist/esm/{insurance-state-qTdpe84i.js → insurance-state-CLGc1-_4.js} +1 -1
- package/dist/esm/internal-button.entry.js +3 -3
- package/dist/esm/justifi-apple-pay_11.entry.js +17 -18
- package/dist/esm/justifi-bank-account-billing-form-simple.entry.js +5 -6
- package/dist/esm/justifi-bank-account-form.entry.js +5 -6
- package/dist/esm/justifi-billing-form-full.entry.js +1 -1
- package/dist/esm/justifi-business-details.entry.js +10 -11
- package/dist/esm/justifi-business-form.entry.js +15 -17
- package/dist/esm/justifi-card-billing-form-simple.entry.js +1 -1
- package/dist/esm/justifi-card-form.entry.js +5 -6
- package/dist/esm/justifi-checkout.entry.js +5 -6
- package/dist/esm/justifi-checkouts-list-filters.entry.js +4 -5
- package/dist/esm/justifi-checkouts-list.entry.js +190 -27
- package/dist/esm/justifi-details.entry.js +2 -2
- package/dist/esm/justifi-dispute-management.entry.js +64 -17
- package/dist/esm/justifi-gross-payment-chart.entry.js +11071 -23
- package/dist/esm/justifi-order-terminals.entry.js +11 -12
- package/dist/esm/justifi-payment-details.entry.js +20 -21
- package/dist/esm/justifi-payment-provisioning.entry.js +11 -12
- package/dist/esm/justifi-payment-transactions-list.entry.js +10 -11
- package/dist/esm/justifi-payments-list-filters.entry.js +3 -3
- package/dist/esm/justifi-payments-list.entry.js +12 -13
- package/dist/esm/justifi-payout-details.entry.js +15 -16
- package/dist/esm/justifi-payout-transactions-list.entry.js +10 -11
- package/dist/esm/justifi-payouts-list-filters.entry.js +4 -5
- package/dist/esm/justifi-payouts-list.entry.js +13 -14
- package/dist/esm/justifi-refund-payment.entry.js +11 -12
- package/dist/esm/justifi-saved-payment-method.entry.js +1 -1
- package/dist/esm/justifi-season-interruption-insurance.entry.js +8 -9
- package/dist/esm/justifi-skeleton.entry.js +3 -3
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +5 -6
- package/dist/esm/justifi-terminal-orders-list.entry.js +175 -21
- package/dist/esm/justifi-terminals-list-filters.entry.js +3 -4
- package/dist/esm/justifi-terminals-list.entry.js +12 -13
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{package-beXEDfB9.js → package-OGt0dCJl.js} +1 -1
- package/dist/esm/pagination-menu.entry.js +1 -1
- package/dist/esm/{parts-DnrawQn3.js → parts-CPKMvyV_.js} +1 -1
- package/dist/esm/payment-method-option.entry.js +2 -2
- package/dist/esm/{payment-provisioning-actions-Dr0YIShV.js → payment-provisioning-actions-cl5xIYnF.js} +2 -2
- package/dist/esm/payment-provisioning-form-buttons_2.entry.js +2 -2
- package/dist/esm/{payment-provisioning-loading-DI2wDkhm.js → payment-provisioning-loading-Dve2xQA4.js} +1 -1
- package/dist/esm/{payment.service-Ckbb7gXA.js → payment.service-5_u-UzTY.js} +1 -2
- package/dist/esm/{payments-status-BIDoGw-m.js → payments-status-BlVUt4C1.js} +1 -1
- package/dist/esm/{payout.service-BgFKxEoL.js → payout.service-D2zS5y8N.js} +1 -2
- package/dist/esm/{payouts-status-1T2NZBoE.js → payouts-status-DCjCGTaa.js} +3 -3
- package/dist/esm/{plaid.service-BLguQHs_.js → plaid.service-BiJ65YG8.js} +1 -2
- package/dist/esm/radio-list-item.entry.js +2 -2
- package/dist/esm/{schema-validations-v6WGlZkq.js → schema-validations-u9_XnlUL.js} +2 -2
- package/dist/esm/{skeleton-CXGFVqDf.js → skeleton-BEHo2ypu.js} +1 -1
- package/dist/esm/{spinner-kSw6PcwU.js → spinner-DIiQZd6_.js} +1 -1
- package/dist/esm/{table-CcyuIutB.js → table-DqGfsdys.js} +3 -3
- package/dist/esm/table-filters-menu.entry.js +3 -3
- package/dist/esm/terminal-quantity-selector.entry.js +2 -2
- package/dist/esm/{terminal.service-0oISl5j-.js → terminal.service-CIxDfM7V.js} +1 -2
- package/dist/esm/{utils-DcfpJGDZ.js → utils-C1B2hVAB.js} +1 -1
- package/dist/esm/{utils-BxYS3WDw.js → utils-CX6puxwf.js} +1 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/module/Plaid.js +2 -2
- package/dist/module/{justifi-refund-policy.d.ts → additional-statement.d.ts} +4 -4
- package/dist/module/additional-statement.js +6 -0
- package/dist/module/{justifi-additional-statement2.js → additional-statement2.js} +8 -8
- package/dist/module/badge.js +1 -1
- package/dist/module/bank-account-billing-form-simple2.js +1 -1
- package/dist/module/billing-form-full2.js +1 -1
- package/dist/module/business-bank-account-form-step2.js +1 -1
- package/dist/module/business-owners-form-step2.js +20 -26
- package/dist/module/button.js +1 -1
- package/dist/module/cancellation-policy.d.ts +11 -0
- package/dist/module/cancellation-policy.js +6 -0
- package/dist/module/{justifi-cancellation-policy2.js → cancellation-policy2.js} +8 -8
- package/dist/module/card-billing-form-simple2.js +1 -1
- package/dist/module/custom-popper2.js +2 -2
- package/dist/module/{checkouts-list-core.d.ts → customer-details.d.ts} +4 -4
- package/dist/module/customer-details.js +6 -0
- package/dist/module/{justifi-customer-details2.js → customer-details2.js} +8 -8
- package/dist/module/dispute-notification.d.ts +11 -0
- package/dist/module/dispute-notification.js +6 -0
- package/dist/module/dispute-notification2.js +82 -0
- package/dist/module/dispute-response.d.ts +11 -0
- package/dist/module/dispute-response.js +6 -0
- package/dist/module/{dispute-response-core.js → dispute-response2.js} +105 -53
- package/dist/module/duplicate-charge.d.ts +11 -0
- package/dist/module/duplicate-charge.js +6 -0
- package/dist/module/{justifi-duplicate-charge2.js → duplicate-charge2.js} +8 -8
- package/dist/module/electronic-evidence.d.ts +11 -0
- package/dist/module/electronic-evidence.js +6 -0
- package/dist/module/{justifi-electronic-evidence2.js → electronic-evidence2.js} +8 -8
- package/dist/module/event-types3.js +119 -1
- package/dist/module/form-alert2.js +1 -1
- package/dist/module/form-control-date2.js +2 -2
- package/dist/module/form-control-file-v22.js +1 -1
- package/dist/module/form-control-file2.js +2 -2
- package/dist/module/form-control-monetary2.js +2 -2
- package/dist/module/form-control-number-masked2.js +2 -2
- package/dist/module/form-control-number2.js +3 -3
- 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 +3 -3
- package/dist/module/get-payment-details.js +1 -1
- package/dist/module/hidden-input2.js +2 -2
- package/dist/module/iframe-input2.js +4 -4
- package/dist/module/internal-button2.js +1 -1
- package/dist/module/justifi-bank-account-billing-form-simple.js +1 -1
- package/dist/module/justifi-bank-account-form.js +1 -1
- package/dist/module/justifi-billing-form-full.js +1 -1
- package/dist/module/justifi-button2.js +1 -1
- package/dist/module/justifi-card-billing-form-simple.js +1 -1
- package/dist/module/justifi-card-form.js +1 -1
- package/dist/module/justifi-checkout-summary2.js +1 -1
- package/dist/module/justifi-checkouts-list-filters.js +3 -3
- package/dist/module/justifi-checkouts-list.js +197 -28
- package/dist/module/justifi-dispute-management.js +103 -62
- package/dist/module/justifi-gross-payment-chart.js +11074 -24
- package/dist/module/justifi-header2.js +1 -1
- package/dist/module/justifi-modular-checkout2.js +2 -2
- package/dist/module/justifi-order-terminals.js +4 -4
- package/dist/module/justifi-payment-details.js +9 -9
- package/dist/module/justifi-payment-provisioning.js +53 -59
- package/dist/module/justifi-payment-transactions-list.js +2 -2
- package/dist/module/justifi-payments-list-filters.js +2 -2
- package/dist/module/justifi-payments-list.js +2 -2
- package/dist/module/justifi-payout-details.js +4 -4
- package/dist/module/justifi-payout-transactions-list.js +2 -2
- package/dist/module/justifi-payouts-list-filters.js +3 -3
- package/dist/module/justifi-payouts-list.js +2 -2
- package/dist/module/justifi-season-interruption-insurance.js +1 -1
- package/dist/module/justifi-skeleton.js +1 -1
- package/dist/module/justifi-terminal-orders-list-filters.js +4 -4
- package/dist/module/justifi-terminal-orders-list.js +184 -22
- package/dist/module/justifi-terminals-list-filters.js +2 -2
- package/dist/module/justifi-terminals-list.js +3 -3
- package/dist/module/justifi-tokenize-payment-method2.js +1 -1
- package/dist/module/owner-form-inputs2.js +2 -2
- package/dist/module/owner-form2.js +177 -33
- package/dist/module/package.js +1 -1
- package/dist/module/pagination-menu2.js +1 -1
- package/dist/module/parts.js +1 -1
- package/dist/module/payment-method-option.js +1 -1
- package/dist/module/payment-provisioning-form-steps2.js +52 -58
- package/dist/module/product-or-service.d.ts +11 -0
- package/dist/module/product-or-service.js +6 -0
- package/dist/module/{justifi-product-or-service2.js → product-or-service2.js} +8 -8
- package/dist/module/radio-list-item2.js +1 -1
- package/dist/module/{owner-form-core.d.ts → refund-policy.d.ts} +4 -4
- package/dist/module/refund-policy.js +6 -0
- package/dist/module/{justifi-refund-policy2.js → refund-policy2.js} +8 -8
- package/dist/module/shipping-details.d.ts +11 -0
- package/dist/module/shipping-details.js +6 -0
- package/dist/module/{justifi-shipping-details2.js → shipping-details2.js} +8 -8
- package/dist/module/spinner.js +1 -1
- package/dist/module/table-filters-menu2.js +1 -1
- package/dist/module/terminal-quantity-selector2.js +1 -1
- package/dist/module/utils2.js +1 -1
- package/dist/types/api/Terminal.d.ts +1 -1
- package/dist/types/components/business-forms/owner-form/owner-form.d.ts +69 -5
- package/dist/types/components/checkouts-list/justifi-checkouts-list.d.ts +28 -6
- package/dist/types/components/dispute-management/{justifi-dispute-notification.d.ts → dispute-notification.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-additional-statement.d.ts → additional-statement.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-cancellation-policy.d.ts → cancellation-policy.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-customer-details.d.ts → customer-details.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{dispute-response-core.d.ts → dispute-response.d.ts} +21 -10
- package/dist/types/components/dispute-management/dispute-response/{justifi-duplicate-charge.d.ts → duplicate-charge.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-electronic-evidence.d.ts → electronic-evidence.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-product-or-service.d.ts → product-or-service.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-refund-policy.d.ts → refund-policy.d.ts} +1 -1
- package/dist/types/components/dispute-management/dispute-response/{justifi-shipping-details.d.ts → shipping-details.d.ts} +1 -1
- package/dist/types/components/dispute-management/justifi-dispute-management.d.ts +10 -2
- package/dist/types/components/gross-payment-chart/justifi-gross-payment-chart.d.ts +13 -2
- package/dist/types/components/terminal-orders-list/justifi-terminal-orders-list.d.ts +21 -3
- package/dist/types/components.d.ts +304 -551
- package/dist/webcomponents/p-0708cb76.entry.js +1 -0
- package/dist/webcomponents/p-07236291.entry.js +1 -0
- package/dist/webcomponents/p-12ae030d.entry.js +1 -0
- package/dist/webcomponents/p-215c6b6b.entry.js +1 -0
- package/dist/webcomponents/{p-256c5509.entry.js → p-22d19755.entry.js} +1 -1
- package/dist/webcomponents/{p-2425a375.entry.js → p-2dfdecbb.entry.js} +1 -1
- package/dist/webcomponents/p-31452258.entry.js +1 -0
- package/dist/webcomponents/p-35dd1fc0.entry.js +1 -0
- package/dist/webcomponents/{p-4d21df48.entry.js → p-383b8317.entry.js} +1 -1
- package/dist/webcomponents/{p-1e877e0a.entry.js → p-3d6b9434.entry.js} +1 -1
- package/dist/webcomponents/p-3f5e9afb.entry.js +1 -0
- package/dist/webcomponents/p-45c0fb53.entry.js +1 -0
- package/dist/webcomponents/p-46477dfe.entry.js +1 -0
- package/dist/webcomponents/{p-31e74a5a.entry.js → p-49a4123c.entry.js} +1 -1
- package/dist/webcomponents/{p-befe01ef.entry.js → p-49c13952.entry.js} +1 -1
- package/dist/webcomponents/p-4ccf9cd7.entry.js +1 -0
- package/dist/webcomponents/p-4ec433f4.entry.js +1 -0
- package/dist/webcomponents/p-58b5e08e.entry.js +1 -0
- package/dist/webcomponents/p-5G1OMxZz.js +1 -0
- package/dist/webcomponents/{p-8253ef9f.entry.js → p-605bd107.entry.js} +1 -1
- package/dist/webcomponents/p-6220a384.entry.js +1 -0
- package/dist/webcomponents/p-63b7abf3.entry.js +1 -0
- package/dist/webcomponents/p-69fdd137.entry.js +1 -0
- package/dist/webcomponents/p-6RTf1SXX.js +1 -0
- package/dist/webcomponents/{p-3c046adc.entry.js → p-70dcd833.entry.js} +1 -1
- package/dist/webcomponents/p-7119fddd.entry.js +1 -0
- package/dist/webcomponents/p-7ebed752.entry.js +1 -0
- package/dist/webcomponents/p-8964f4ca.entry.js +1 -0
- package/dist/webcomponents/p-89cd31f2.entry.js +1 -0
- package/dist/webcomponents/p-8aa53ef2.entry.js +1 -0
- package/dist/webcomponents/p-8d173a7c.entry.js +1 -0
- package/dist/webcomponents/p-9153c121.entry.js +1 -0
- package/dist/webcomponents/p-91aef5bf.entry.js +1 -0
- package/dist/webcomponents/p-9b944aa4.entry.js +1 -0
- package/dist/webcomponents/p-9d021e10.entry.js +1 -0
- package/dist/webcomponents/{p-bc2af6b4.entry.js → p-9fc7714d.entry.js} +1 -1
- package/dist/webcomponents/{p-CR_-qIuN.js → p-APOabprT.js} +1 -1
- package/dist/webcomponents/p-Aacb4jqT.js +1 -0
- package/dist/webcomponents/p-B5gBiARs.js +1 -0
- package/dist/webcomponents/{p-bn_huKYG.js → p-BICxxa69.js} +1 -1
- package/dist/webcomponents/p-BJu1-9kE.js +1 -0
- package/dist/webcomponents/{p-Cej-1bD6.js → p-BXyADlAH.js} +1 -1
- package/dist/webcomponents/p-Ba8jdOkX.js +1 -0
- package/dist/webcomponents/p-BxKbnILQ.js +1 -0
- package/dist/webcomponents/{p-2LVpxCS_.js → p-CHo7TfsM.js} +1 -1
- package/dist/webcomponents/p-CHw7tICr.js +1 -0
- package/dist/webcomponents/{p-DnrawQn3.js → p-CPKMvyV_.js} +1 -1
- package/dist/webcomponents/p-Ce_W43gc.js +1 -0
- package/dist/webcomponents/{p-B5vVjDc_.js → p-Cm9f5fyh.js} +1 -1
- package/dist/webcomponents/p-CqiVXthx.js +1 -0
- package/dist/webcomponents/{p-x9fFFf7F.js → p-Cu7hgXL1.js} +1 -1
- package/dist/webcomponents/p-Cz_7BuGW.js +1 -0
- package/dist/webcomponents/p-D-zwk1J3.js +1 -0
- package/dist/webcomponents/{p-D1D2eC05.js → p-D1_eip6x.js} +1 -1
- package/dist/webcomponents/p-DSclFZ32.js +1 -0
- package/dist/webcomponents/p-DYHjzFnJ.js +1 -0
- package/dist/webcomponents/p-Dk26hk5T.js +1 -0
- package/dist/webcomponents/{p-CKiAlBsU.js → p-DwoT0UoX.js} +1 -1
- package/dist/webcomponents/{p-_-2E_vYf.js → p-DyucNSA4.js} +1 -1
- package/dist/webcomponents/p-KXLYEe1D.js +1 -0
- package/dist/webcomponents/p-NZS8uCtH.js +1 -0
- package/dist/webcomponents/p-OGt0dCJl.js +1 -0
- package/dist/webcomponents/p-a1dcdc8b.entry.js +20 -0
- package/dist/webcomponents/{p-10be75b8.entry.js → p-a80f69a9.entry.js} +1 -1
- package/dist/webcomponents/{p-9581d6a1.entry.js → p-a9695714.entry.js} +1 -1
- package/dist/webcomponents/{p-c9e1df15.entry.js → p-ae91fc9b.entry.js} +1 -1
- package/dist/webcomponents/p-av6jyzyC.js +1 -0
- package/dist/webcomponents/p-b0b6083f.entry.js +1 -0
- package/dist/webcomponents/p-b272a29d.entry.js +1 -0
- package/dist/webcomponents/p-b341efd6.entry.js +1 -0
- package/dist/webcomponents/{p-e6e56dbb.entry.js → p-b62ff001.entry.js} +1 -1
- package/dist/webcomponents/p-c1539656.entry.js +1 -0
- package/dist/webcomponents/p-c8f3656f.entry.js +1 -0
- package/dist/webcomponents/p-c9fe4f33.entry.js +1 -0
- package/dist/webcomponents/{p-09d2efad.entry.js → p-ca87c609.entry.js} +1 -1
- package/dist/webcomponents/p-cde76bf8.entry.js +1 -0
- package/dist/webcomponents/p-d24240a5.entry.js +1 -0
- package/dist/webcomponents/p-d79c5ee4.entry.js +1 -0
- package/dist/webcomponents/p-daaa2a99.entry.js +1 -0
- package/dist/webcomponents/{p-9db1444f.entry.js → p-db09f306.entry.js} +1 -1
- package/dist/webcomponents/{p-354fb3c4.entry.js → p-e020f003.entry.js} +1 -1
- package/dist/webcomponents/p-e4cb7c21.entry.js +1 -0
- package/dist/webcomponents/p-e5c2215a.entry.js +1 -0
- package/dist/webcomponents/p-ea0d7a98.entry.js +1 -0
- package/dist/webcomponents/p-ef85717f.entry.js +1 -0
- package/dist/webcomponents/p-f1b9cbf0.entry.js +1 -0
- package/dist/webcomponents/p-f30069ea.entry.js +1 -0
- package/dist/webcomponents/p-f3ff7e00.entry.js +1 -0
- package/dist/webcomponents/p-f9aafb21.entry.js +1 -0
- package/dist/webcomponents/p-fE5A37L5.js +1 -0
- package/dist/webcomponents/p-jIDKmNHy.js +1 -0
- package/dist/webcomponents/{p-DgH-jcIo.js → p-mF5zKtkx.js} +1 -1
- package/dist/webcomponents/p-nb_LhbJq.js +1 -0
- package/dist/webcomponents/p-oTtn8xDw.js +1 -0
- package/dist/webcomponents/p-uZ5KAseb.js +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/Dispute-CruQTF6_.js +0 -59
- package/dist/cjs/business-additional-questions-schema-CI80eZLJ.js +0 -73
- package/dist/cjs/checkouts-list-core.cjs.entry.js +0 -146
- package/dist/cjs/checkouts-table-CCxrsy0x.js +0 -55
- package/dist/cjs/dispute.service-BbtwY673.js +0 -32
- package/dist/cjs/form-control-number_3.cjs.entry.js +0 -249
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +0 -11075
- package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +0 -61
- package/dist/cjs/terminal-orders-list-core.cjs.entry.js +0 -108
- package/dist/cjs/terminal-orders-table-Cz6qvzVE.js +0 -83
- package/dist/collection/components/business-forms/owner-form/owner-form-core.js +0 -523
- package/dist/collection/components/checkouts-list/checkouts-list-core.js +0 -262
- package/dist/collection/components/dispute-management/dispute-management-core.js +0 -169
- package/dist/collection/components/dispute-management/dispute-response/justifi-dispute-response.js +0 -190
- package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +0 -139
- package/dist/collection/components/terminal-orders-list/terminal-orders-list-core.js +0 -199
- package/dist/esm/Dispute-BH0Xfn-F.js +0 -57
- package/dist/esm/business-additional-questions-schema-DKudYaoE.js +0 -69
- package/dist/esm/business-identity-schema-CFhSc0cA.js +0 -99
- package/dist/esm/checkouts-list-core.entry.js +0 -144
- package/dist/esm/checkouts-table-C8sPHeTm.js +0 -51
- package/dist/esm/dispute.service-vlYGy0nR.js +0 -30
- package/dist/esm/form-control-number_3.entry.js +0 -245
- package/dist/esm/gross-payment-chart-core.entry.js +0 -11073
- package/dist/esm/justifi-dispute-management-core.entry.js +0 -59
- package/dist/esm/terminal-orders-list-core.entry.js +0 -106
- package/dist/esm/terminal-orders-table-C7KOcRpq.js +0 -79
- package/dist/module/checkouts-list-core.js +0 -6
- package/dist/module/checkouts-list-core2.js +0 -227
- package/dist/module/dispute-management-core.js +0 -193
- package/dist/module/dispute-response-actions.js +0 -119
- package/dist/module/gross-payment-chart-core.d.ts +0 -11
- package/dist/module/gross-payment-chart-core.js +0 -6
- package/dist/module/gross-payment-chart-core2.js +0 -11096
- package/dist/module/justifi-additional-statement.d.ts +0 -11
- package/dist/module/justifi-additional-statement.js +0 -6
- package/dist/module/justifi-cancellation-policy.d.ts +0 -11
- package/dist/module/justifi-cancellation-policy.js +0 -6
- package/dist/module/justifi-customer-details.d.ts +0 -11
- package/dist/module/justifi-customer-details.js +0 -6
- package/dist/module/justifi-dispute-management-core.d.ts +0 -11
- package/dist/module/justifi-dispute-management-core.js +0 -6
- package/dist/module/justifi-dispute-notification.d.ts +0 -11
- package/dist/module/justifi-dispute-notification.js +0 -6
- package/dist/module/justifi-dispute-notification2.js +0 -85
- package/dist/module/justifi-dispute-response-core.d.ts +0 -11
- package/dist/module/justifi-dispute-response-core.js +0 -6
- package/dist/module/justifi-dispute-response.d.ts +0 -11
- package/dist/module/justifi-dispute-response.js +0 -6
- package/dist/module/justifi-dispute-response2.js +0 -198
- package/dist/module/justifi-duplicate-charge.d.ts +0 -11
- package/dist/module/justifi-duplicate-charge.js +0 -6
- package/dist/module/justifi-electronic-evidence.d.ts +0 -11
- package/dist/module/justifi-electronic-evidence.js +0 -6
- package/dist/module/justifi-product-or-service.d.ts +0 -11
- package/dist/module/justifi-product-or-service.js +0 -6
- package/dist/module/justifi-refund-policy.js +0 -6
- package/dist/module/justifi-shipping-details.d.ts +0 -11
- package/dist/module/justifi-shipping-details.js +0 -6
- package/dist/module/owner-form-core.js +0 -6
- package/dist/module/owner-form-core2.js +0 -262
- package/dist/module/terminal-orders-list-core.d.ts +0 -11
- package/dist/module/terminal-orders-list-core.js +0 -6
- package/dist/module/terminal-orders-list-core2.js +0 -209
- package/dist/types/components/business-forms/owner-form/owner-form-core.d.ts +0 -88
- package/dist/types/components/checkouts-list/checkouts-list-core.d.ts +0 -34
- package/dist/types/components/dispute-management/dispute-management-core.d.ts +0 -18
- package/dist/types/components/dispute-management/dispute-response/justifi-dispute-response.d.ts +0 -35
- package/dist/types/components/gross-payment-chart/gross-payment-chart-core.d.ts +0 -21
- package/dist/types/components/terminal-orders-list/terminal-orders-list-core.d.ts +0 -28
- package/dist/webcomponents/p--e0ff06z.js +0 -1
- package/dist/webcomponents/p-032b4553.entry.js +0 -1
- package/dist/webcomponents/p-042daaf8.entry.js +0 -1
- package/dist/webcomponents/p-0638f0bd.entry.js +0 -1
- package/dist/webcomponents/p-0b3f4f22.entry.js +0 -1
- package/dist/webcomponents/p-1c4f5f1d.entry.js +0 -1
- package/dist/webcomponents/p-1e8135f0.entry.js +0 -1
- package/dist/webcomponents/p-24935254.entry.js +0 -1
- package/dist/webcomponents/p-2a755daf.entry.js +0 -1
- package/dist/webcomponents/p-3488951f.entry.js +0 -1
- package/dist/webcomponents/p-437a99dc.entry.js +0 -1
- package/dist/webcomponents/p-49c0cd3a.entry.js +0 -1
- package/dist/webcomponents/p-50f5e313.entry.js +0 -1
- package/dist/webcomponents/p-52908814.entry.js +0 -1
- package/dist/webcomponents/p-587886f1.entry.js +0 -1
- package/dist/webcomponents/p-5ef355ce.entry.js +0 -1
- package/dist/webcomponents/p-5ef854e0.entry.js +0 -1
- package/dist/webcomponents/p-67498c25.entry.js +0 -1
- package/dist/webcomponents/p-6917aa3c.entry.js +0 -1
- package/dist/webcomponents/p-6d81822f.entry.js +0 -1
- package/dist/webcomponents/p-6f0c582a.entry.js +0 -1
- package/dist/webcomponents/p-80652cf8.entry.js +0 -1
- package/dist/webcomponents/p-82fe02e4.entry.js +0 -1
- package/dist/webcomponents/p-83147f23.entry.js +0 -1
- package/dist/webcomponents/p-8c2427ed.entry.js +0 -1
- package/dist/webcomponents/p-92de00d7.entry.js +0 -1
- package/dist/webcomponents/p-94306884.entry.js +0 -1
- package/dist/webcomponents/p-9937e2e7.entry.js +0 -1
- package/dist/webcomponents/p-9dca1331.entry.js +0 -1
- package/dist/webcomponents/p-9f74d7ea.entry.js +0 -1
- package/dist/webcomponents/p-B--N37zY.js +0 -1
- package/dist/webcomponents/p-BH0Xfn-F.js +0 -1
- package/dist/webcomponents/p-Bg2SZArf.js +0 -1
- package/dist/webcomponents/p-BovgIz83.js +0 -1
- package/dist/webcomponents/p-BsQy297i.js +0 -1
- package/dist/webcomponents/p-CDf5H0TB.js +0 -1
- package/dist/webcomponents/p-CUI41_5y.js +0 -1
- package/dist/webcomponents/p-CX36GHQP.js +0 -1
- package/dist/webcomponents/p-Cf6HoQKl.js +0 -1
- package/dist/webcomponents/p-CsdYMTrc.js +0 -1
- package/dist/webcomponents/p-D4OlsyTo.js +0 -1
- package/dist/webcomponents/p-D8EGHc_m.js +0 -1
- package/dist/webcomponents/p-DPmnGTmg.js +0 -1
- package/dist/webcomponents/p-DWevPe7C.js +0 -1
- package/dist/webcomponents/p-Dbg501Lu.js +0 -1
- package/dist/webcomponents/p-DcBvJu0k.js +0 -1
- package/dist/webcomponents/p-DkdzUTnl.js +0 -1
- package/dist/webcomponents/p-HT_4DkD0.js +0 -1
- package/dist/webcomponents/p-MDZuGvsl.js +0 -1
- package/dist/webcomponents/p-XrKLre8M.js +0 -1
- package/dist/webcomponents/p-a75d76ff.entry.js +0 -1
- package/dist/webcomponents/p-a7778957.entry.js +0 -1
- package/dist/webcomponents/p-a9d7cdae.entry.js +0 -1
- package/dist/webcomponents/p-b060a9c9.entry.js +0 -1
- package/dist/webcomponents/p-b06910b0.entry.js +0 -1
- package/dist/webcomponents/p-b483e71b.entry.js +0 -1
- package/dist/webcomponents/p-bdf21f71.entry.js +0 -1
- package/dist/webcomponents/p-be5d1005.entry.js +0 -1
- package/dist/webcomponents/p-beXEDfB9.js +0 -1
- package/dist/webcomponents/p-bfe2583d.entry.js +0 -1
- package/dist/webcomponents/p-c09fccd3.entry.js +0 -1
- package/dist/webcomponents/p-c827cbc9.entry.js +0 -1
- package/dist/webcomponents/p-cc5b7c27.entry.js +0 -1
- package/dist/webcomponents/p-d878df6c.entry.js +0 -1
- package/dist/webcomponents/p-ddf699e6.entry.js +0 -20
- package/dist/webcomponents/p-e0b3735f.entry.js +0 -1
- package/dist/webcomponents/p-ea30cf08.entry.js +0 -1
- package/dist/webcomponents/p-edf5a854.entry.js +0 -1
- package/dist/webcomponents/p-ef89824b.entry.js +0 -1
- package/dist/webcomponents/p-fc7ba195.entry.js +0 -1
- package/dist/webcomponents/p-hhdRync5.js +0 -1
- package/dist/webcomponents/p-niGr4RT2.js +0 -1
- package/dist/webcomponents/p-pL4dNfsl.js +0 -1
- package/dist/webcomponents/p-qcQTYcr3.js +0 -1
- package/dist/webcomponents/p-qrNmDp6K.js +0 -1
- package/dist/webcomponents/p-uCg79W3M.js +0 -1
- package/dist/webcomponents/p-zi3ljCdQ.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as i,r as s,c as t}from"./p-CV0Pyo1O.js";import{a9 as e,a8 as r,a1 as o,t as l}from"./p-CPKMvyV_.js";import{S as d}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{c as n}from"./p-mF5zKtkx.js";import{J as a}from"./p-Cz_7BuGW.js";import{m as h,C as c,n as u,c as v,e as m}from"./p-NZS8uCtH.js";import{B as p}from"./p-BJu1-9kE.js";import{B as f}from"./p-BcNb9bVO.js";import{m as w}from"./p-Aacb4jqT.js";import{S as b}from"./p-uZ5KAseb.js";import"./p-DVJaoI_m.js";import"./p-HXpYMWUU.js";import"./p-CLHwhyvu.js";import{g as y,a as x}from"./p-Cm9f5fyh.js";import{T as g}from"./p-Ba8jdOkX.js";import{l as j}from"./p-BRnBHsdq.js";import"./p-OGt0dCJl.js";import"./p-CYQvLgSs.js";import"./p-D8GTwl9v.js";const C=()=>i("div",{class:"row gap-3"},i("div",{class:"col-12"},i(b,{width:"25%"})),i("div",{class:"col-12"},i(b,{width:"100%"})),i("div",{class:"col-12 d-flex gap-3"},i(b,{width:"50%"}),i(b,{width:"50%"})),i("div",{class:"col-12 d-flex gap-3"},i(b,{width:"65%"}),i(b,{width:"35%"}))),S=()=>i("div",{class:"row gap-5"},i("div",{class:"col-12"},i(b,{width:"40%",height:"40px"})),i(C,null)),k=()=>i("div",{class:"terminal-selector-skeleton mt-4 rounded shadow-sm"},i("div",{class:"d-flex align-items-center gap-3"},i(b,{width:"125px",height:"125px",styles:{borderRadius:"8px"}}),i("div",{class:"flex-grow-1"},i("div",{class:"d-flex row flex-row"},i("div",{class:"col-6 flex-column"},i(b,null),i(b,{width:"60%"})),i("div",{class:"d-flex justify-content-end align-items-center gap-2 col-6"},i(b,{width:"32px",height:"32px",styles:{borderRadius:"50%"}}),i(b,{width:"80px",height:"32px"}),i(b,{width:"32px",height:"32px",styles:{borderRadius:"50%"}}))),i("div",{class:"mt-4"},i("div",{class:"d-flex flex-column gap-2"},i(b,null),i(b,null)))))),B=class{constructor(i){s(this,i),this.errorEvent=t(this,"error-event",7),this.submitted=t(this,"submit-event",7),this.shipping=!1,this.submitButtonText="Submit Order",this.loading={business:!0,terminals:!0},this.submitting=!1,this.error=null,this.totalQuantity=0}componentWillLoad(){this.order=new u({business_id:this.businessId,sub_account_id:this.accountId,order_type:this.shipping?v.boardingShipping:v.boardingOnly}),n(),this.analytics=new a(this),this.loadData()}disconnectedCallback(){var i;null===(i=this.analytics)||void 0===i||i.cleanup()}handleError(i,s,t){this.error={message:i,code:s,severity:t},this.errorEvent.emit({errorCode:s,message:i,severity:t})}loadData(){this.businessId&&this.authToken?(this.initializeGetBusiness(),this.initializeGetTerminalModels()):this.handleError("Invalid business id or auth token",m.MISSING_PROPS,c.ERROR)}initializeGetBusiness(){w({id:this.businessId,authToken:this.authToken,service:new p})({onSuccess:({business:i})=>{this.business=new f(i)},onError:({error:i,code:s,severity:t})=>{this.handleError(i,s,t)},final:()=>{this.loading.business=!1}})}initializeGetTerminalModels(){(({id:i,authToken:s,service:t})=>async({onSuccess:e,onError:r})=>{var o,l,d,n;try{const a=await t.fetchTerminalModels(i,s);if(a.error)return r({error:x(a.error),code:y(null===(n=a.error)||void 0===n?void 0:n.code),severity:c.ERROR});e({terminals:(null===(l=null===(o=a.data)||void 0===o?void 0:o.terminal_order_models)||void 0===l?void 0:l.map((i=>new h(i))))||[],orderLimit:null===(d=a.data)||void 0===d?void 0:d.order_limit})}catch(i){const s=y(null==i?void 0:i.code);return r({error:i.message||i,code:s,severity:c.ERROR})}})({id:this.accountId,authToken:this.authToken,service:new g})({onSuccess:({terminals:i,orderLimit:s})=>{this.terminalModels=i,this.orderLimit=s,this.loading.terminals=!1},onError:({error:i,code:s,severity:t})=>{this.handleError(i,s,t),this.loading.terminals=!1}})}submitOrder(){const i=(({authToken:i,service:s,apiOrigin:t="https://wc-proxy.justifi.ai"})=>async({terminalOrder:e,onSuccess:r,onError:o})=>{var l;try{const d=await s.orderTerminals(i,e,t);if(d.error)return o({error:x(d.error),code:y(null===(l=d.error)||void 0===l?void 0:l.code),severity:c.ERROR});{const{data:i}=d;r({data:i})}}catch(i){const s=y(null==i?void 0:i.code);return o({error:i.message||i,code:s,severity:c.ERROR})}})({authToken:this.authToken,service:new g});this.submitting=!0,i({terminalOrder:this.order.payload,onSuccess:({data:i})=>{this.submitted.emit(i),this.submitting=!1},onError:({error:i,code:s,severity:t})=>{this.handleError(i,s,t),this.submitting=!1}})}onSelectedQuantityChange(i){this.order.updateTerminal(i.detail.modelName,i.detail.quantity),this.totalQuantity=this.order.totalQuantity}renderLoading(){return i("div",null,this.loading.business&&i(S,null),this.loading.terminals&&i("div",{class:"mt-5"},i(k,null),i(k,null),i(k,null)))}renderBusinessDetails(){var s,t,o,l,d,n,a,h;if(!this.loading.business&&this.business)return i("div",{class:"d-flex flex-column gap-4 mb-5 pt-5"},i("div",{class:"row"},i("div",{class:"col-12"},i("h2",{part:r},this.business.legal_name))),i("div",{class:"row"},i("div",{class:"col-6"},i("h5",{part:e},"Representative:"),i("div",null,i("div",null,null===(t=null===(s=this.business)||void 0===s?void 0:s.representative)||void 0===t?void 0:t.name),i("div",null,null===(l=null===(o=this.business)||void 0===o?void 0:o.representative)||void 0===l?void 0:l.title),i("div",null,null===(n=null===(d=this.business)||void 0===d?void 0:d.representative)||void 0===n?void 0:n.email),i("div",null,j(null===(h=null===(a=this.business)||void 0===a?void 0:a.representative)||void 0===h?void 0:h.phone)))),i("div",{class:"col-6"},i("h5",{part:e},this.shipping?"Shipping Address:":"Business Address:"),i("div",null,this.business.legal_address.line1,this.business.legal_address.line2?`, ${this.business.legal_address.line2}`:"",i("br",null),this.business.legal_address.city,", ",this.business.legal_address.state," ",this.business.legal_address.postal_code))))}renderTerminals(){if(!this.loading.terminals&&this.terminalModels)return i("div",{class:"d-flex flex-column gap-2 mt-5"},this.terminalModels.map((s=>i("terminal-quantity-selector",{modelName:s.model_name,description:s.description,imageUrl:s.image_url,helpUrl:s.help_url,limit:this.orderLimit-this.order.totalQuantity,onSelectedQuantityChange:this.onSelectedQuantityChange.bind(this)}))))}renderOrderSection(){return i("div",{class:"mt-3"},i("div",{class:"text-end"},"Order limit: ",this.orderLimit),i("div",{class:"d-flex justify-content-end mt-3"},i("button",{class:"btn btn-primary submit-btn",onClick:this.submitOrder.bind(this),disabled:0===this.order.totalQuantity||this.submitting,part:o},this.submitting?"Submitting...":this.submitButtonText)))}render(){return i(d,{key:"a6d128c8f7075ba4bf6dc033e357dac187cdb965"},i("div",{key:"9e726c70efc7e9b9163ded2ca1e88dc4303b2f21",part:l},this.renderLoading(),this.renderBusinessDetails(),this.renderTerminals(),this.renderOrderSection()))}};export{B as justifi_order_terminals}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as s,H as a,g as i}from"./p-CV0Pyo1O.js";import{a3 as r,v as l,q as o,w as d,x as c,u as f,a0 as n}from"./p-CPKMvyV_.js";import{F as h}from"./p-B5gBiARs.js";import{F as b}from"./p-Ce_W43gc.js";import"./p-CZfYo5-1.js";import{I as u,P as m}from"./p-CVaOFfrI.js";import{u as p,a as y,b as k}from"./p-C6o0liMT.js";import{a as v}from"./p-DyucNSA4.js";import"./p-BcNb9bVO.js";const x=class{constructor(s){e(this,s),this.formControlInput=t(this,"formControlInput",7),this.formControlBlur=t(this,"formControlBlur",7),this.isFocused=!1,this.disabled=!1,this.handleFormControlInput=e=>{const t=e.target,s=t.getAttribute("name");this.inputHandler(s,t.value),this.formControlInput.emit({name:s,value:t.value})},this.updateInput=e=>{const t=this.el.querySelector("input");t&&(t.value=e||"")}}handleDefaultValueChange(e){this.updateInput(e)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.isFocused&&this.errorText?r:this.isFocused?l:this.errorText?o:d}render(){return s(a,{key:"07b767b8c9091079f121d1df2b552c7d406f47b1"},s("div",{key:"1c6c234435bb5571d3bbf5123f6f47cf51b095d6",class:"form-group d-flex flex-column"},s("label",{key:"883c05703351e32c7e12dbf7d984f888825606e3",part:c,class:"form-label",htmlFor:this.name},this.label),s("input",{key:"9b841736efd2971cf93c1167ec1fd1c1d5045ec9",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:"number",disabled:this.disabled}),s(h,{key:"26133a236b3c8b2cc14dce1c1244f3b1a9163605",helpText:this.helpText,name:this.name}),s(b,{key:"e69f03f593e1632fada2d1f6dd56aaf5612a2da7",errorText:this.errorText,name:this.name})))}get el(){return i(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},T=class{constructor(t){e(this,t),this.isEditingIdentification=!1,this.inputHandler=(e,t)=>{p(this.formController,{[e]:t})},this.onAddressFormUpdate=e=>{y(this.formController,Object.assign(Object.assign({},this.formController.values.getValue().address),e))}}render(){var e,t,a;return s("div",{key:"d2cd6a317c81991b6108751d7fafe6eb0f785572",class:"row gy-3"},s("div",{key:"58b5f28247b266fb5928a4cc54992978a0382389",class:"col-12 col-md-8"},s("form-control-text",{key:"8755d9f2c3e4f1753f33f06e96b060e3f1bfb7b8",name:"name",label:"Full Name",defaultValue:this.ownerDefaultValue.name,errorText:this.errors.name,inputHandler:this.inputHandler})),s("div",{key:"c5930506a02c94b2752a50b1db5d375fe8e73791",class:"col-12 col-md-4"},s("form-control-text",{key:"f93c736bd2315bcc33971286303e0eb2c995b83d",name:"title",label:"Title",defaultValue:this.ownerDefaultValue.title,errorText:this.errors.title,inputHandler:this.inputHandler,helpText:"Role at your business, e.g. President, CEO, Treasurer."})),s("div",{key:"421d8dce34b3f45dc859aa37de740f1578817ba0",class:"col-12 col-md-6"},s("form-control-text",{key:"183dcf682886be6c07a6e0f5ff6f3e8ebd5193bc",name:"email",label:"Email Address",defaultValue:this.ownerDefaultValue.email,errorText:this.errors.email,inputHandler:this.inputHandler})),s("div",{key:"678bc220f7415da8cb83edf303919688cef75c29",class:"col-12 col-md-6"},s("form-control-number-masked",{key:"f763d5b0596926c4044de25f181a8d562ef67d0f",name:"phone",label:"Phone Number",defaultValue:this.ownerDefaultValue.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:m.US})),s("div",{key:"958af034510d699ef84d7f22ff755ec088dbe4bc",class:"col-12 col-md-3"},s("form-control-date",{key:"7a2d6f7dce48e5343296256eb407c638f3505bf6",name:"dob_full",label:"Birth Date",defaultValue:this.ownerDefaultValue.dob_full,errorText:this.errors.dob_full,inputHandler:this.inputHandler,onFormControlInput:e=>k(e,this.formController),helpText:"Must be 18 or older."})),s("div",{key:"12c82f41a9d60ff5a52e64ea34d69fd24d3102bb",class:"col-12 col-md-3"},s("form-control-number",{key:"035d4d0d2e036b1a86c2f179f39330b48de26005",name:"ownership_percentage",label:"% of Ownership",defaultValue:null===(e=this.ownerDefaultValue)||void 0===e?void 0:e.ownership_percentage,errorText:this.errors.ownership_percentage,inputHandler:this.inputHandler})),s("div",{key:"108cbb8692dc71b7d038315bf8be3b35efee0fa3",class:"col-12 col-md-6"},!(null===(t=this.ownerDefaultValue)||void 0===t?void 0:t.ssn_last4)||this.isEditingIdentification?s("form-control-number-masked",{name:"identification_number",label:v[this.country].idNumberLabel,defaultValue:this.isEditingIdentification?"":this.ownerDefaultValue.identification_number,errorText:this.errors.identification_number,inputHandler:this.inputHandler,mask:u[this.country],helpText:v[this.country].identityHelpText}):s("div",null,s("label",{class:"form-label",part:c},v[this.country].idNumberLabel),s("div",{class:"input-group mb-3"},s("input",{type:"text",class:"form-control",part:f,value:`****${null===(a=this.ownerDefaultValue)||void 0===a?void 0:a.ssn_last4}`,disabled:!0}),s("button",{class:"btn btn-secondary",type:"button",part:n,onClick:()=>{this.isEditingIdentification=!0,p(this.formController,{ssn_last4:null,identification_number:""})}},"Change")))),s("div",{key:"834b3ffaaec1e2dfec16b278b39e505782c0d785",class:"col-12"},s("identity-address-form",{key:"7f6f356e116ce4bc1d9014dc7823b86b00af40b6",errors:this.errors.address,defaultValues:this.ownerDefaultValue.address,handleFormUpdate:this.onAddressFormUpdate,country:this.country})))}};export{x as form_control_number,T as owner_form_inputs}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r,h as i}from"./p-CV0Pyo1O.js";import{S as e}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";const s=class{constructor(i){r(this,i)}async getValues(){var r,i;return null!==(i=null===(r=this.cardBillingFormSimpleRef)||void 0===r?void 0:r.getValues())&&void 0!==i?i:{}}async validate(){var r,i;return null!==(i=null===(r=this.cardBillingFormSimpleRef)||void 0===r?void 0:r.validate())&&void 0!==i?i:{isValid:!1,errors:{}}}render(){return i(e,{key:"
|
|
1
|
+
import{r,h as i}from"./p-CV0Pyo1O.js";import{S as e}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";const s=class{constructor(i){r(this,i)}async getValues(){var r,i;return null!==(i=null===(r=this.cardBillingFormSimpleRef)||void 0===r?void 0:r.getValues())&&void 0!==i?i:{}}async validate(){var r,i;return null!==(i=null===(r=this.cardBillingFormSimpleRef)||void 0===r?void 0:r.validate())&&void 0!==i?i:{isValid:!1,errors:{}}}render(){return i(e,{key:"1e25de93c795dd6c8ec2979918a5b10389a55354"},i("card-billing-form-simple",{key:"d9db1793b83e5fa216f72bfe7803d968ee499ac7",legend:this.legend,ref:r=>this.cardBillingFormSimpleRef=r}))}};export{s as justifi_card_billing_form_simple}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as e,h as s,H as a,g as i}from"./p-CV0Pyo1O.js";import{w as o,x as h,q as r,u as c,v as l}from"./p-CPKMvyV_.js";import{F as f}from"./p-Ce_W43gc.js";import"./p-CZfYo5-1.js";const n=class{constructor(s){t(this,s),this.formControlInput=e(this,"formControlInput",7),this.formControlBlur=e(this,"formControlBlur",7),this.isFocused=!1,this.handleFormControlInput=t=>{const e=t.target,s=e.getAttribute("name");this.inputHandler(s,e.value),this.formControlInput.emit(e.value)},this.updateInput=t=>{this.selectElement.value=t}}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){let t=o;return this.errorText&&(t=r),this.disabled&&(t=c),this.isFocused&&(t=l),t}render(){var t;return s(a,{key:"9499d7c542341eabf4e5571dec7c9083d13b7666"},s("div",{key:"c9967fd597028fcac9582ac39121c9a445330712",class:"form-group d-flex flex-column"},s("div",{key:"213e629f9364a9e2a2796cfca0c008fd7bf1e212",class:"d-flex align-items-start gap-2"},s("label",{key:"c9d68b3dcc00ca877a80a8464478fd9ac38bd40c",part:h,class:"form-label",htmlFor:this.name},this.label),s("form-control-tooltip",{key:"e655af202b042934dba8ce2a003af3bef9a74df9",helpText:this.helpText})),s("select",{key:"4b4e4ccb7cc36b1ce5f48d0b11c5e036256267b9",ref:t=>this.selectElement=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-select is-invalid":"form-select",disabled:this.disabled},null===(t=this.options)||void 0===t?void 0:t.map((t=>s("option",{value:t.value},t.label)))),s(f,{key:"a9ea85db5af5a500e50c87ba83c5e64a43c422fa",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},d=class{constructor(s){t(this,s),this.formControlInput=e(this,"formControlInput",7),this.formControlBlur=e(this,"formControlBlur",7),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("input");e&&(e.value=t||"")}}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.errorText?r:this.disabled?c:this.isFocused?l:o}render(){return s(a,{key:"4ab9e7a2c6312b568de8a8ee429ef02f3f792173"},s("div",{key:"e273e0bc062be883505fe3047d41a741eaf23a44",class:"form-group d-flex flex-column"},s("div",{key:"a7496dd4f6b5549f26752ca2de35a34c5261e439",class:"d-flex align-items-start gap-2"},s("label",{key:"97480c49cb0fcd3c75d123c6033df4880755baf0",part:h,class:"form-label",htmlFor:this.name},this.label),s("form-control-tooltip",{key:"e2a53e4e15be4f9f739a79afeaf28c3671c14a4d",helpText:this.helpText})),s("input",{key:"1571553d763734454026b2c4feaa88a9535f2057",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",type:"text",disabled:this.disabled}),s(f,{key:"44f7c7847a2255ff3ddd83f542ff6690d1aed798",errorText:this.errorText,name:this.name})))}get el(){return i(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{n as form_control_select,d as form_control_text}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as e,c as s}from"./p-CV0Pyo1O.js";import"./p-DVJaoI_m.js";import"./p-HXpYMWUU.js";import{k as a,C as i,e as o}from"./p-NZS8uCtH.js";import{p as r}from"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{g as c,a as h}from"./p-Cm9f5fyh.js";import{c as n}from"./p-mF5zKtkx.js";import{J as p}from"./p-Cz_7BuGW.js";import{C as d}from"./p-fE5A37L5.js";import{m as u,S as m}from"./p-BxKbnILQ.js";import{S as f}from"./p-BqNNwq6C.js";import{T as b,a as l,b as y,c as k,d as g,e as C,f as v,g as j,h as _,i as w,j as S,k as T,l as x}from"./p-BICxxa69.js";import{T as I}from"./p-CZfYo5-1.js";import{d as P,b as A}from"./p-BRnBHsdq.js";import{B as O,a as E}from"./p-CHw7tICr.js";import{a6 as B,a7 as D}from"./p-CPKMvyV_.js";import{o as G,g as H}from"./p-CpGEMRkH.js";import"./p-D8GTwl9v.js";import"./p-OGt0dCJl.js";import"./p-CYQvLgSs.js";import"./p-CqiVXthx.js";const L={created_at:()=>t("th",{part:B,scope:"col",title:"The date each checkout occurred"},"Processed On"),payment_amount:()=>t("th",{part:B,scope:"col",title:"The dollar amount of each checkout"},"Payment Amount"),payment_description:()=>t("th",{part:B,scope:"col",title:"The description of each checkout"},"Payment Description"),sub_account_name:()=>t("th",{part:B,scope:"col",title:"The sub account associated with the checkout"},"Sub Account"),payment_mode:()=>t("th",{part:B,scope:"col",title:"The payment mode of each checkout"},"Payment Mode"),status:()=>t("th",{part:B,scope:"col",title:"The current status of each checkout"},"Status")},q={created_at:(e,s)=>t("td",{part:D(s)},t("div",{class:"fw-bold"},A(e.created_at)),t("div",{class:"fw-bold"},P(e.created_at))),payment_amount:(e,s)=>t("td",{part:D(s)},e.formattedPaymentAmount(e.payment_amount)),payment_description:(e,s)=>t("td",{part:D(s)},e.payment_description),sub_account_name:(e,s)=>t("td",{part:D(s)},e.sub_account_name),payment_mode:(e,s)=>t("td",{part:D(s)},e.payment_mode),status:(e,s)=>t("td",{part:D(s)},t(E,Object.assign({},{created:{variant:O.PRIMARY,title:"The checkout has been created",text:"Created"},completed:{variant:O.SUCCESS,title:"The checkout has been completed",text:"Completed"},attempted:{variant:O.SECONDARY,title:"The checkout has been attempted",text:"Attempted"},expired:{variant:O.DANGER,title:"The checkout has expired",text:"Expired"}}[e.status])))},z=class{constructor(t){e(this,t),this.clickEvent=s(this,"click-event",7),this.errorEvent=s(this,"error-event",7),this.columns="created_at,payment_amount,payment_description,payment_mode,status",this.checkouts=[],this.subAccounts=[],this.loading=!0,this.paging=r,this.pagingParams={},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:I.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:I.next})},this.rowClickHandler=t=>{const e=t.target.closest("tr").dataset.rowEntityId;if(!e)return;const s=this.checkouts.find((t=>t.id===e));this.clickEvent.emit({name:I.row,data:s})}}componentWillLoad(){n(),this.analytics=new p(this),this.checkoutsTable=new b(this.checkouts,this.columns,L,q),this.initializeGetData(),this.getCheckouts&&this.fetchData(),G("set",(()=>{this.pagingParams={}})),G("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}authPropChanged(){this.initializeGetData(),this.getCheckouts&&this.fetchData()}pagingOrColumnsChanged(){this.getCheckouts&&this.fetchData()}initializeGetData(){this.initializeGetCheckouts(),this.initializeGetSubAccounts()}initializeGetCheckouts(){const t=this.subAccountId||this.accountId;t&&this.authToken?this.getCheckouts=(({accountId:t,authToken:e,service:s})=>async({params:o,onSuccess:r,onError:n})=>{var p,d;try{const u=await s.fetchCheckouts(t,e,o);if(u.error)return n({error:h(u.error),code:c(null===(d=u.error)||void 0===d?void 0:d.code),severity:i.ERROR});{const t=Object.assign({},u.page_info);r({checkouts:(null===(p=u.data)||void 0===p?void 0:p.map((t=>new a(t))))||[],pagingInfo:t})}}catch(t){const e=c(null==t?void 0:t.code);return n({error:t.message||t,code:e,severity:i.ERROR})}})({accountId:t,authToken:this.authToken,service:new d}):(this.errorMessage="Account ID/Sub Account ID and Auth Token are required",this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:this.errorMessage,severity:i.ERROR}))}initializeGetSubAccounts(){this.accountId&&this.authToken&&(this.getSubAccounts=u({primaryAccountId:this.accountId,authToken:this.authToken,service:new m}))}fetchData(){this.getCheckouts&&(this.loading=!0,this.getCheckouts({params:this.checkoutParams,onSuccess:async({checkouts:t,pagingInfo:e})=>{this.checkouts=t,this.paging=e,this.checkoutsTable.collectionData=this.checkouts,this.checkoutsTable.columnKeys.includes("sub_account_name")?await this.fetchSubAccounts():this.loading=!1},onError:({error:t,code:e,severity:s})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:e,message:t,severity:s}),this.loading=!1}}))}async fetchSubAccounts(){this.getSubAccounts?this.getSubAccounts({params:this.subAccountParams,onSuccess:({subAccounts:t})=>{this.subAccounts=t,this.checkouts=this.checkouts.map((t=>{var e;return t.sub_account_name=null===(e=this.subAccounts.find((e=>e.id===t.account_id)))||void 0===e?void 0:e.name,t})),this.loading=!1},onError:({error:t,code:e,severity:s})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:e,message:t,severity:s}),this.loading=!1}}):this.loading=!1}get checkoutParams(){const t=H();return Object.assign(Object.assign({},t),this.pagingParams)}get subAccountParams(){const 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 t(f,{key:"2f9efac8723333029415ef131516946912bb313c"},t(l,{key:"024c7a532533721acda9740a0888b1c15fa624fe"},t(y,{key:"06bf1c6db731eb5857b08615222ca47a85ffc4a8"},t(k,{key:"0754f9cd87a3b32a5368e7fb7538071cf6be0505"},t(g,{key:"5db4c5beea0e6e9afc29e16b5789a32ad94509dd"},this.checkoutsTable.columnData.map((t=>t)))),t(C,{key:"9140294035b04b549578d74374271f8a9fd78162"},t(v,{key:"bf495d00b9bc4ee28b67c8f1b3258306f9202142",columnSpan:this.checkoutsTable.columnKeys.length,isLoading:this.loading}),t(j,{key:"92f8a1245cc022fa3b254bb1fe8d659f75c62923",isEmpty:this.showEmptyState,columnSpan:this.checkoutsTable.columnKeys.length}),t(_,{key:"2e6ab100026afb29f199dd33e52de5ae77e6576c",columnSpan:this.checkoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.checkoutsTable.rowData.map(((e,s)=>t(w,{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},e)))),this.paging&&t(S,{key:"3a1b55572eb0fc2ffcef1a39f6bfae5693056752"},t(T,{key:"f61a3cc86fda3ec95075381403916f5fb1c46ca6"},t(x,{key:"7d937a0d228062f42f49dca5bdb436d54354563e",colSpan:this.checkoutsTable.columnData.length},t("pagination-menu",{key:"05454876b7faeeb73fb8f896a2425e5f9db12ee3",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})})))))))}static get watchers(){return{accountId:["authPropChanged"],authToken:["authPropChanged"],subAccountId:["authPropChanged"],pagingParams:["pagingOrColumnsChanged"],columns:["pagingOrColumnsChanged"]}}};export{z as justifi_checkouts_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as e,c as s}from"./p-CV0Pyo1O.js";import{a as r,c as i,F as n}from"./p-DwoT0UoX.js";import{f as o}from"./p-BRnBHsdq.js";import"./p-DVJaoI_m.js";import{R as a,C as u,e as h,o as l}from"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{B as c}from"./p-CHo7TfsM.js";import{S as m}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{P as d}from"./p-nb_LhbJq.js";import{m as p}from"./p-5G1OMxZz.js";import{J as f}from"./p-Cz_7BuGW.js";import{c as v}from"./p-mF5zKtkx.js";import{g as y,a as j}from"./p-Cm9f5fyh.js";import{A as b}from"./p-CYQvLgSs.js";import{S as w}from"./p-uZ5KAseb.js";import"./p-BFTU3MAI.js";import"./p-HXpYMWUU.js";import"./p-D8GTwl9v.js";import"./p-CPKMvyV_.js";import"./p-OGt0dCJl.js";const C=t=>{const e=+t;return i().required("Amount is required").test("max-amount",`Refund amount cannot be more than payment amount: ${o(e)}`,(function(t){return+t<=+e})).test("min-amount","Refund amount must be greater than 0",(function(t){return+t>0}))},T=t=>{if(t)return r({amount:C(t),description:i().optional(),reason:i().optional().oneOf([a.customerRequest,a.duplicate,a.fraudulent],"Select a reason")})},g=[{label:"Select a reason",value:""},{label:"Customer requested a refund",value:"customer_request"},{label:"Customer was double-charged",value:"duplicate"},{label:"Payment was reported as fraud",value:"fraudulent"}],S=b();class x{async postRefund(t,e,s,r){return S.post({endpoint:`payments/${t}/refunds`,headers:{"Sub-Account":e},body:r,authToken:s})}}const I=b();class k{async postVoid(t,e,s){return I.post({endpoint:`payments/${t}/void`,headers:{"Sub-Account":e},authToken:s})}}const A=()=>t("div",{class:"row gap-3"},t("div",{class:"col-12"},t(w,{width:"100%",height:"40px"}))),P=()=>t(m,null,t("div",{class:"row gap-5"},t(A,null),t(A,null),t(A,null))),R=class{constructor(t){e(this,t),this.errorEvent=s(this,"error-event",7),this.submitEvent=s(this,"submit-event",7),this.refundPayload={},this.displayAmount="",this.errors={},this.paymentLoading=!0,this.refundLoading=!1,this.hideSubmitButton=!1,this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}componentWillLoad(){v(),this.analytics=new f(this),this.initializeApi(),this.formController=new n(T())}handleError(t,e,s){this.errorEvent.emit({errorCode:t,message:e,severity:s})}checkAmount(t){return t>0}handleInvalidAmount(){this.submitDisabled=!0,this.handleError(h.INVALID_REFUND_AMOUNT,"Refund amount must be greater than 0",u.ERROR)}isPaymentCreatedWithin25Minutes(){var t;if(!this.payment||!(null===(t=this.payment)||void 0===t?void 0:t.created_at))return!1;const e=new Date(this.payment.created_at);return((new Date).getTime()-e.getTime())/6e4<=25}initializeFormController(){const t=this.refundPayload.amount,e=t?t.toString():"0";this.formController=new n(T(e)),this.formController.setInitialValues({amount:e}),this.formController.values.subscribe((t=>{this.refundPayload=Object.assign({},t)})),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.paymentId&&this.authToken?p({id:this.paymentId,authToken:this.authToken,service:new d})({onSuccess:({payment:t})=>{this.payment=t,this.refundPayload=new l({amount:t.amount_refundable})},onError:({error:t,code:e,severity:s})=>{this.handleError(e,t,s)},final:()=>{this.checkAmount(this.refundPayload.amount)?this.initializeFormController():this.handleInvalidAmount(),this.paymentLoading=!1}}):this.handleError(h.MISSING_PROPS,"Payment ID and Auth Token are required",u.ERROR)}async refundPayment(t){if(t&&t.preventDefault(),!await this.formController.validate())return;const e=this.formController.values.getValue();return this.refundLoading=!0,this.isPaymentCreatedWithin25Minutes()?this.tryVoidPayment():this.processRefund(e)}async tryVoidPayment(){const t=(({authToken:t,accountId:e,paymentId:s,service:r})=>async({onSuccess:i,onError:n,final:o})=>{var a;try{const o=await r.postVoid(s,e,t);if(o.error)return n({error:j(o.error),code:y(null===(a=o.error)||void 0===a?void 0:a.code),severity:u.ERROR});i(o)}catch(t){const e=y(null==t?void 0:t.code);return n({error:t.message||t,code:e,severity:u.ERROR})}finally{return o()}})({authToken:this.authToken,accountId:this.accountId,paymentId:this.paymentId,service:new k});return new Promise((e=>{let s,r=!1;const i=this.formController.values.getValue();t({onSuccess:t=>{s=t,r=!0},onError:({error:t,code:s,severity:n})=>{r=!0,this.handleError(t,s,n),this.processRefund(i).then(e)},final:()=>{s&&!s.error&&r&&(this.submitEvent.emit({response:s}),this.submitDisabled=!0,this.refundLoading=!1,e(s.data))}})}))}async processRefund(t){const e=(({authToken:t,accountId:e,paymentId:s,service:r})=>async({refundBody:i,onSuccess:n,onError:o,final:a})=>{var h;try{const a=await r.postRefund(s,e,t,i);if(a.error)return o({error:j(a.error),code:y(null===(h=a.error)||void 0===h?void 0:h.code),severity:u.ERROR});n(a)}catch(t){const e=y(null==t?void 0:t.code);return o({error:t.message||t,code:e,severity:u.ERROR})}finally{return a()}})({authToken:this.authToken,accountId:this.accountId,paymentId:this.paymentId,service:new x});return new Promise((s=>{let r;e({refundBody:t,onSuccess:t=>{r=t},onError:({error:t,code:e,severity:s})=>{r=t,this.handleError(t,e,s)},final:()=>{this.submitEvent.emit({response:r}),this.submitDisabled=!0,this.refundLoading=!1,s(r.data)}})}))}render(){if(this.paymentLoading)return t(P,null);const e=this.formController.getInitialValues(),s=this.refundPayload.amount;return t(m,null,t("form",null,t("fieldset",null,t("div",{class:"row gy-3"},t("div",{class:"col-12"},t("form-control-monetary",{name:"amount",label:"Refund Amount",defaultValue:e.amount,inputHandler:this.inputHandler,errorText:this.errors.amount})),t("div",{class:"col-12"},t("form-control-select",{name:"reason",label:"Reason for refund (optional)",defaultValue:e.reason,inputHandler:this.inputHandler,options:g,errorText:this.errors.reason})),t("div",{class:"col-12"},t("form-control-textarea",{name:"description",label:"Note (optional)",defaultValue:e.description,inputHandler:this.inputHandler,maxLength:250,errorText:this.errors.description})),t("div",{class:"form-group d-flex flex-row-reverse"},t(c,{variant:"primary",type:"submit",onClick:this.refundPayment.bind(this),isLoading:this.paymentLoading||this.refundLoading,hidden:this.hideSubmitButton,disabled:this.submitDisabled},`Refund ${o(+s)}`))))))}};export{R as justifi_refund_payment}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s,h as t}from"./p-CV0Pyo1O.js";import{C as i}from"./p-BcNb9bVO.js";import{B as e}from"./p-XYgDHrVL.js";import{B as o}from"./p-
|
|
1
|
+
import{r as s,h as t}from"./p-CV0Pyo1O.js";import{C as i}from"./p-BcNb9bVO.js";import{B as e}from"./p-XYgDHrVL.js";import{B as o}from"./p-CHo7TfsM.js";import"./p-CZfYo5-1.js";import"./p-CPKMvyV_.js";const n=class{constructor(t){s(this,t)}get showPreviousStepButton(){return this.currentStep>0}get showNextStepButton(){return this.currentStep<this.totalSteps}get showSubmitButton(){return this.currentStep===this.totalSteps}render(){return t("div",{key:"6fac4d1e92b732da3e7e867c091f23e9e3b7d6ab",class:"d-flex gap-2"},t(o,{key:"a96025bed24ade707d7f28561a12a9bcf62401e8",variant:"secondary",type:"button",onClick:()=>this.previousStepButtonOnClick(),disabled:this.formDisabled,hidden:!this.showPreviousStepButton},"Previous"),t(o,{key:"c4bd0d4a7f79942b307a4587e77c73158d4b704d",variant:"primary",type:"button",onClick:s=>this.nextStepButtonOnClick(s,e.nextStep),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showNextStepButton},"Next"),t(o,{key:"5fa56e168646f4fa266fde124c78dc2564a6c311",variant:"primary",type:"submit",onClick:s=>this.nextStepButtonOnClick(s,e.submit),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showSubmitButton},"Submit"))}},r=class{constructor(e){s(this,e),this.allowOptionalFields=!1,this.country=i.USA,this.componentStepMapping={0:()=>t("business-core-info-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[0]=s,allowOptionalFields:this.allowOptionalFields,country:this.country}),1:()=>t("legal-address-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[1]=s,allowOptionalFields:this.allowOptionalFields,country:this.country}),2:()=>t("additional-questions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[2]=s,allowOptionalFields:this.allowOptionalFields}),3:()=>t("business-representative-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[3]=s,allowOptionalFields:this.allowOptionalFields,country:this.country}),4:()=>t("business-owners-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[4]=s,allowOptionalFields:this.allowOptionalFields,country:this.country}),5:()=>t("business-bank-account-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[5]=s,allowOptionalFields:this.allowOptionalFields,country:this.country}),6:()=>t("business-terms-conditions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[6]=s,onFormLoading:this.handleFormLoading,allowOptionalFields:this.allowOptionalFields})}}get currentStepComponent(){return this.componentStepMapping[this.currentStep]()}render(){return t("div",{key:"6bd8ebe91fefb364dd29a741e2cdf8a90aa1351b",class:"col-12 mb-4"},this.currentStepComponent)}};export{n as payment_provisioning_form_buttons,r as payment_provisioning_form_steps}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as e,r as t}from"./p-CV0Pyo1O.js";import{S as i}from"./p-uZ5KAseb.js";import{w as a,c as s}from"./p-DVJaoI_m.js";import{e as c}from"./p-BRnBHsdq.js";import{c as d}from"./p-mF5zKtkx.js";import"./p-CPKMvyV_.js";import"./p-D8GTwl9v.js";import"./p-HXpYMWUU.js";import"./p-OGt0dCJl.js";const r=t=>{const{isReady:a}=t;return a?null:e("div",{class:"container-fluid p-0"},e("div",{class:"row mb-3"},e("div",{class:"col-12 align-content-end"},e(i,{height:"18px",width:"120px"}),e(i,{height:"36px"}))),e("div",{class:"row"},e("div",{class:"col-12 align-content-end"},e(i,{height:"18px",width:"110px"}),e(i,{height:"36px"}))))},o=class{constructor(e){t(this,e),this.isReady=!1}async componentWillLoad(){await a(),this.iframeOrigin=s.iframeOrigin,this.tabId=c(),d()}componentDidRender(){Promise.all([this.accountNumberIframeElement,this.routingNumberIframeElement].map((e=>new Promise((t=>{e.addEventListener("iframeLoaded",(()=>{t()}))}))))).then((()=>{this.isReady=!0}))}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 await this.accountNumberIframeElement.tokenize(e,t,i)}render(){return e("div",{key:"85e116539bb4721484d9877706ff93de1a68ec59"},e(r,{key:"b12a13d02b004e2957a55eb00fb38178dc283a92",isReady:this.isReady}),e("hidden-input",{key:"657ed7946158788e9291906ec0966eb3bd3c544c"}),e("div",{key:"321fddef9af616686d525af94dc4a65b5a4c18e6",class:"container-fluid p-0",style:{opacity:this.isReady?"1":"0",height:this.isReady?"auto":"0"}},e("div",{key:"cee2dcc5bf8032ca95dc6b46e6a2bb47b371986b",class:"row mb-3"},e("iframe-input",{key:"50dfad1fc1eb41a87f2964e80d39036da1fc89ce",inputId:"accountNumber",ref:e=>this.accountNumberIframeElement=e,label:"Account Number",iframeOrigin:`${this.iframeOrigin}/v2/accountNumber?tabId=${this.tabId}`})),e("div",{key:"bd47ac6ff7c687ce9eb7e6ea2a66628392f73cdc",class:"row"},e("iframe-input",{key:"bbe98adda61bc72925e77714139b604d2959e156",inputId:"routingNumber",ref:e=>this.routingNumberIframeElement=e,label:"Routing Number",iframeOrigin:`${this.iframeOrigin}/v2/routingNumber?tabId=${this.tabId}`}))))}};export{o as bank_account_form}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,h as o}from"./p-CV0Pyo1O.js";import{c as a}from"./p-mF5zKtkx.js";import{J as s}from"./p-Cz_7BuGW.js";import{w as r}from"./p-DVJaoI_m.js";import{S as p}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import"./p-OGt0dCJl.js";import"./p-CYQvLgSs.js";import"./p-BRnBHsdq.js";import"./p-HXpYMWUU.js";import"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import"./p-D8GTwl9v.js";const i=class{constructor(o){t(this,o)}async componentWillLoad(){await r(),a(),this.analytics=new s(this)}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}async validate(){return this.bankAccountFormElement.validate()}async tokenize({clientId:t,paymentMethodMetadata:o,account:a}){return this.bankAccountFormElement.tokenize({clientId:t,paymentMethodMetadata:o,account:a})}render(){return o(p,{key:"3a267a32b400d122cd124245979218ffc45453ee"},o("bank-account-form",{key:"72044965224da0d85455ad7688b3d1852a46126e",ref:t=>this.bankAccountFormElement=t}))}};export{i as justifi_bank_account_form}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as a,h as e}from"./p-CV0Pyo1O.js";import{f as t,p as s,c as l}from"./p-AMVhBsGv.js";import{f as r,a as f}from"./p-CPKMvyV_.js";import{S as d}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{c as i,a as o}from"./p-BRnBHsdq.js";import"./p-DVJaoI_m.js";import{P as c}from"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import"./p-D8GTwl9v.js";import"./p-HXpYMWUU.js";const p=class{constructor(e){a(this,e),this.setParamsOnChange=(a,e)=>{t[a]=e},this.handleDateInput=(a,e)=>{const t=i(e,{setEndOfDay:!0});this.setParamsOnChange(a,t)}}componentWillLoad(){Object.entries({status:this.status,created_after:this.createdAfter,created_before:this.createdBefore}).forEach((([a,e])=>{e&&(s[a]=e)}))}get statusOptions(){return[{label:"All",value:""},{label:c.paid,value:"paid"},{label:c.failed,value:"failed"},{label:c.forwarded,value:"forwarded"},{label:c.scheduled,value:"scheduled"},{label:c.in_transit,value:"in_transit"},{label:c.canceled,value:"canceled"}]}render(){const a=Object.assign({},t);return e(d,{key:"3625f5efccbe6a0715abb425731f53ab4ff89b05"},e("table-filters-menu",{key:"ce1fad33a28dd75075ec382e73f1822170061215",params:a,clearParams:l,part:r},e("div",{key:"613d95baab2642c7e9d032476dbf66529a64f10f",class:"grid-cols-2 gap-3 p-1"},e("div",{key:"39096bd7917514f0f7fddc98520ff78b1ac38e99",class:"p-2"},e("form-control-select",{key:"dd93b57d82296c2ea79a76a52e499123bffcf346",name:"status",label:"Status",options:this.statusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.status||t.status||"",disabled:!!this.status,part:f})),e("div",{key:"323b2e91854d75266135cf6af37aacb86c9776d1",class:"p-2"},e("form-control-date",{key:"b3c67ec5e63fc5484a153689bbd56666d7679a4c",name:"created_after",label:"Created After",inputHandler:this.handleDateInput,defaultValue:o(this.createdAfter,{showInputDate:!0})||o(t.created_after,{showInputDate:!0}),disabled:!!this.createdAfter,part:f})),e("div",{key:"6a949567f2c4183f4431ffb07fbcbb61b33f1044",class:"p-2"},e("form-control-date",{key:"8ad670d02f45ea839c712b2cfe5cf7bade503554",name:"created_before",label:"Created Before",inputHandler:this.handleDateInput,defaultValue:o(this.createdBefore,{showInputDate:!0})||o(t.created_before,{showInputDate:!0}),disabled:!!this.createdBefore,part:f})))))}};export{p as justifi_payouts_list_filters}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as e,r as t,c as a}from"./p-CV0Pyo1O.js";import{P as s}from"./p-nb_LhbJq.js";import{m as i}from"./p-5G1OMxZz.js";import{C as d,e as c,g as f,f as l}from"./p-NZS8uCtH.js";import{J as r}from"./p-Cz_7BuGW.js";import{c as h}from"./p-mF5zKtkx.js";import"./p-DVJaoI_m.js";import{b as o,d as b,s as p}from"./p-BRnBHsdq.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{P as n,M as m}from"./p-D1_eip6x.js";import{a as y,b as u,D as v,c as k,C,E as j}from"./p-Cu7hgXL1.js";import{S as g}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{S as w}from"./p-uZ5KAseb.js";import{a as x,B as D}from"./p-CHw7tICr.js";import"./p-CYQvLgSs.js";import"./p-HXpYMWUU.js";import"./p-Cm9f5fyh.js";import"./p-OGt0dCJl.js";import"./p-D8GTwl9v.js";import"./p-CPKMvyV_.js";const P=()=>e("div",{class:"row gap-3"},e("div",{class:"col-12"},e(w,{width:"35%",height:"30px"})),e("div",{class:"col-12"},e(w,{width:"70%"})),e("div",{class:"col-12"},e(w,{width:"40%"})),e("div",{class:"col-12"},e(w,{width:"40%"})),e("div",{class:"col-12"},e(w,{width:"100%"})),e("div",{class:"col-12"},e(w,{width:"80%"}))),N=class{constructor(e){t(this,e),this.errorEvent=a(this,"error-event",7),this.recordClickEvent=a(this,"record-click-event",7),this.loading=!0}componentWillLoad(){h(),this.analytics=new r(this),this.initializeGetPaymentDetails()}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.cleanup()}propChanged(){this.initializeGetPaymentDetails()}initializeGetPaymentDetails(){this.paymentId&&this.authToken?(this.getPaymentDetails=i({id:this.paymentId,authToken:this.authToken,service:new s}),this.fetchData()):(this.errorMessage="Payment ID and Auth Token are required",this.errorEvent.emit({message:this.errorMessage,errorCode:c.MISSING_PROPS,severity:d.ERROR}))}updateOnPropChange(){this.getPaymentDetails&&this.fetchData()}fetchData(){this.loading=!0,this.getPaymentDetails({onSuccess:({payment:e})=>{this.payment=e,this.errorMessage=null},onError:({error:e,code:t,severity:a})=>{this.errorMessage=e,this.errorEvent.emit({errorCode:t,message:e,severity:a})},final:()=>{this.loading=!1}})}get PaymentStatus(){return this.payment.status===f.disputed&&this.payment.disputes.some((e=>e.status===l.lost))?n.DISPUTE_LOST:this.payment.status}render(){return e(g,{key:"f4952600aea69aae085ac57364e96397d1a20e51"},this.loading&&e(P,{key:"2f819c97a1a6ddb9df2a11e0cd6a5bc013ed19ae"}),!this.loading&&this.errorMessage&&j(this.errorMessage),!this.loading&&!this.errorMessage&&this.payment&&e("justifi-details",{key:"35a58e3917bdc3133f02374c0e031374be7c728c",errorMessage:this.errorMessage},e(y,{key:"dad5f79ea18ef718b92bf2c2abbbba34542d6caa",slot:"head-info",badge:e("div",{class:"d-flex gap-1"},m(this.PaymentStatus),this.payment.expedited?e(x,{variant:D.WARNING,title:"Expedited",text:"Expedited"}):null),title:this.payment.formattedPaymentAmount(this.payment.amount)},e(u,{key:"12e7cfb4f4f56a1af8403b935cb51db3751f1395",classes:"border-1 border-end",title:"Updated At",value:`${o(this.payment.updated_at)} ${b(this.payment.updated_at)}`}),e(u,{key:"023945353c0cbab340f4f510951164f110045ea5",classes:"border-1 border-end",title:"Created At",value:`${o(this.payment.created_at)} ${b(this.payment.created_at)}`}),e(u,{key:"dcb261f7c4faf53eb686cfd5c8e0ade39a72bdea",title:"ID",value:this.payment.id})),e("div",{key:"a7774df4ece900dc67494377cf648bf64f558490",slot:"detail-sections"},e(v,{key:"ef4a9197d4eb47d81c11c7f974f1e4058d5e3166",sectionTitle:"Details"}),e("div",{key:"17ef105d1b37ad34cce4bdd17cbf2e4023c0e2e5",class:"d-flex flex-column gap-2 w-100"},e(k,{key:"dbb764a1a6cbe949d2e281334e2f420f957b98fe",title:"Amount",value:this.payment.formattedPaymentAmount(this.payment.amount)}),e(k,{key:"7a3547ade7107456956618c72a95056a0771d219",title:"Fees",value:this.payment.formattedPaymentAmount(this.payment.fee_amount)}),e(k,{key:"94df0647f7286a4a7c9001f9e82b4277fe0f8457",title:"Refunded",value:this.payment.formattedPaymentAmount(this.payment.amount_refunded)}),e(k,{key:"59c13e257938124af50adfaa73571f152c402bd4",title:"Net",value:this.payment.formattedPaymentAmount(this.payment.balance)}),e(k,{key:"6abf719a072a3a1ea5878d999e517dafb7ba19d5",title:"Status",value:m(this.PaymentStatus)}),e(k,{key:"c494d2b4be8c9e13747f0299a618ea6c9ff723d7",title:"Payment ID",value:this.payment.id}),e(k,{key:"1024b282558896dcb2c4ab7718045d98a6f6853e",title:"Processing Fees",value:this.payment.formattedPaymentAmount(this.payment.fee_amount)}),e(k,{key:"6bf6fb7f648609fdeaa4e5a0b6f3d4c7bcd4af97",title:"Statement Descriptor",value:this.payment.statement_descriptor}),e(k,{key:"43da8b6ab1aa87b6b938f1d0fd95708399cb9cc0",title:"Description",value:this.payment.description}),e(k,{key:"e6180466f4341e2c438f09cc42feb518f59aded4",title:"Expedited",value:this.payment.expedited?"Yes":"No"})),this.payment.payment_method.card&&[e(v,{key:"289f80acfa3cd41f82637e8f9d9e63dac4c11b5b",sectionTitle:"Payment Method"}),e("div",{key:"616a2e7ae000581dd481725c57a644fc3e0a9b7c",class:"d-flex flex-column gap-2 w-100"},e(k,{key:"2c13ea8a771e2f155a9e3d5dbae78c7800f31adb",title:"ID",value:this.payment.payment_method.card.id}),e(k,{key:"62700836b3bd9656d07dc58d0d07d164c091cd74",title:"Payment Type",value:"Card"}),e(k,{key:"528ad4dddccaa7f5bc274b3b297557f659d46789",title:"Last 4 Numbers",value:this.payment.payment_method.lastFourDigits}),e(k,{key:"fdf2ad89e4e7ad253e16bff9038dc79da5a71b19",title:"Brand",value:p(this.payment.payment_method.card.brand)}),e(k,{key:"0b2c505e1fae49414414d5e839b1bdc849290c41",title:"Cardholder",value:this.payment.payment_method.payersName}))],this.payment.payment_method.bank_account&&[e(v,{key:"2a04be5ee508a547661e1ff947c2c9b40da2a192",sectionTitle:"Payment Method"}),e("div",{key:"1316f9c749960ca0ab4967ff03697583e690007d",class:"d-flex flex-column gap-2 w-100"},e(k,{key:"46fe5297825ef0b9e3f34fdee6f47f3dd3b9272d",title:"ID",value:this.payment.payment_method.bank_account.id}),e(k,{key:"44f1f47522b94ce5e403d766ee71645b4285d675",title:"Last 4 Numbers",value:this.payment.last_four_digits}),e(k,{key:"f03369474996dc0ae52c7d909ac1bba51e291668",title:"Bank Name",value:this.payment.payment_method.bank_account.brand}),e(k,{key:"d697a0e2a954f0e4efb4cec27dcae9c57fa0ce54",title:"Account Owner",value:this.payment.payment_method.payersName}))],this.payment.metadata&&[e(v,{key:"7cdd88cc59c7852574b05e1709f85afe3bf7367e",sectionTitle:"Metadata"}),e("div",{key:"bde3519c811862185b0757fd7c8a2a0a05117466",class:"d-table gap-2 w-100"},e(C,{key:"7675f134c9580381d495a1d7534e73b77583cb8b",metadata:this.payment.metadata}))])))}static get watchers(){return{paymentId:["propChanged"],authToken:["propChanged"],getPaymentDetails:["updateOnPropChange"]}}};export{N as justifi_payment_details}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a,h as e,H as s}from"./p-CV0Pyo1O.js";import{E as c}from"./p-CLHwhyvu.js";import{
|
|
1
|
+
import{r as a,h as e,H as s}from"./p-CV0Pyo1O.js";import{E as c}from"./p-CLHwhyvu.js";import{K as t,L as i,M as b,N as d,O as f}from"./p-CPKMvyV_.js";const n=class{constructor(e){a(this,e),this.paging=c,this.params={}}render(){return e(s,{key:"7b821154b627026ef8624af6e4759e2176004676"},e("nav",{key:"7990aee285d0cc3e6f83cb59bb216439e5364df5","aria-label":"Table pagination",class:"d-flex justify-content-end gap-3"},e("ul",{key:"02c68163934ce1aabf4abd607cc28e549e20ebe1",class:"pagination m-0"},e("li",{key:"aab661ae85fc61eecd230d058f135483796769c0",class:"page-item "+(this.paging.has_previous?"":" disabled")},e("button",{key:"ef42a41831a9890186c333418b161877761674e1",class:"page-link",onClick:a=>{a.preventDefault(),this.paging.handleClickPrevious(this.paging.start_cursor)},part:this.paging.has_previous?t:i},e("span",{key:"a898a92687e4a5fec37d9dab4208430260a9f274",class:"me-1",part:b},"«"),e("span",{key:"ecc2eeedc064d405ad178b9a98ed088e12f1b2fb",part:d},"Previous"))),e("li",{key:"56569cd9f9803ead8b1180e2f982a98d7009be1f",class:"page-item "+(this.paging.has_next?"":" disabled")},e("button",{key:"c39d389ab89609e8ce11b3dd81eb5c4a50d3521f",class:"page-link",onClick:a=>{a.preventDefault(),this.paging.handleClickNext(this.paging.end_cursor)},part:this.paging.has_next?t:i},e("span",{key:"6a01458a048a524931b03df6a964fa4a0ac403ac",part:d},"Next"),e("span",{key:"f4cb3d084647c00dff30b99f751180564463443f",class:"ms-1",part:f},"»"))))))}};export{n as pagination_menu}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as
|
|
1
|
+
import{r as t,c as s,h as e,H as i}from"./p-CV0Pyo1O.js";import{I as a}from"./p-Ce_F4E0f.js";import{C as h}from"./p-CVaOFfrI.js";import{E as r,x as o,y as n,q as l,u as c,v as d}from"./p-CPKMvyV_.js";import{F as p}from"./p-B5gBiARs.js";import{F as f}from"./p-Ce_W43gc.js";import"./p-CZfYo5-1.js";const m=class{constructor(e){t(this,e),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.imask=null,this.isFocused=!1,this.errorText="",this.defaultValue="0",this.inputHandler=()=>{},this.maskOptions=h.DECIMAL,this.disabled=!1,this.initializeIMask=()=>{this.textInput&&(this.imask=a(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=r;return this.errorText&&(t=l),this.disabled&&(t=c),this.isFocused&&(t=d),t}render(){return e(i,{key:"8ecc68592c7e6ef4418301935dde43e4ea10404d"},e("div",{key:"ba267bd049287c297aa67b761214b9d60503e605",class:"form-group d-flex flex-column"},e("label",{key:"b020e228d70145d758bf58298914ed2b3384bbbc",part:o,class:"form-label",htmlFor:this.name},this.label),e("div",{key:"08415f471180958426563cf0e47e016b292108c7",class:"input-group"},e("span",{key:"dc22d1181a2a23e77003ee67212e724e48c2201e",class:"input-group-text",part:n},"$"),e("input",{key:"3cdedc0317df58360601186dd744bcb721a68ec7",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})),e(p,{key:"1315bdeefe7a551fbbb30680d289743a22a3792d",helpText:this.helpText,name:this.name}),e(f,{key:"7212797f21917530b6bb093f146f1ebead4c232b",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,h as e,H as s}from"./p-CV0Pyo1O.js";import{a,F as i}from"./p-DwoT0UoX.js";import{y as l,z as r,h as d,l as o,j as n,v as c}from"./p-KXLYEe1D.js";import{al as h}from"./p-CPKMvyV_.js";import{c as f,o as m}from"./p-BArmtmkq.js";import{P as b}from"./p-DkoufM1t.js";import{H as u}from"./p-DYHjzFnJ.js";import"./p-CZfYo5-1.js";import{S as p}from"./p-BcNb9bVO.js";import"./p-BFTU3MAI.js";import"./p-DyucNSA4.js";import"./p-Bt4GjEWL.js";import"./p-D8GTwl9v.js";const _=class{constructor(e){t(this,e),this.errors={},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}componentWillLoad(){this.formController=new i(a({name:c.required("Enter full name"),address_line1:n.nullable(),address_line2:o.nullable(),address_city:d.nullable(),address_state:r.nullable(),address_postal_code:l.nullable()}));const t=f.billingFormFields;t&&Object.keys(t).some((e=>t[e]))&&this.formController.setInitialValues(t)}componentDidLoad(){this.formController.values.subscribe((t=>this.billingInfo=Object.assign({},t))),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)})),this.unsubscribeFromStore=m("billingFormFields",(t=>{this.formController.setInitialValues(t)}))}disconnectedCallback(){var t;null===(t=this.unsubscribeFromStore)||void 0===t||t.call(this)}async getValues(){return this.formController.values.getValue()}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){const t=this.formController.getInitialValues();return e("div",{key:"aad27826f1ad84e4f4f7ccb6199d7bd64dde61fc",part:h,class:"mt-4"},e("form",{key:"208146fcf8c96dc78d3ede31178df8fabada001f"},e("fieldset",{key:"ba7b72b8a49b7c0720a449f71fd8a675093e52c3"},this.legend&&e("legend",{key:"ed0d19198e69ae3fa043411f08b1c333cee11329"},this.legend),e("div",{key:"3941aaf9b5abac0b5fe8a72aaebeec448bacb49b",class:"row gy-3"},e("div",{key:"6f9cb3621fdf2519e2167f4407ba0e3322c64c52",class:"col-12"},e("form-control-text",{key:"a7cf909f36506826f112f189cd9409d05a535da0",name:"name",label:"Full Name",defaultValue:t.name,errorText:this.errors.name,inputHandler:this.inputHandler}))))))}},y=class{constructor(e){t(this,e)}get showSimpleCardBillingForm(){return this.paymentMethodType===b.NEW_CARD&&this.hideCardBillingForm}get showSimpleBankAccountBillingForm(){return this.paymentMethodType===b.NEW_BANK_ACCOUNT&&this.hideBankAccountBillingForm}async getValues(){var t;return null===(t=this.selectedFormRef)||void 0===t?void 0:t.getValues()}async validate(){var t;return null===(t=this.selectedFormRef)||void 0===t?void 0:t.validate()}render(){return e(s,null,e(this.showSimpleBankAccountBillingForm?"bank-account-billing-form-simple":this.showSimpleCardBillingForm?"card-billing-form-simple":"billing-form-full",{legend:this.legend,ref:t=>this.selectedFormRef=t}))}},v=class{constructor(e){t(this,e),this.errors={},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}componentWillLoad(){this.formController=new i(a({name:c.required("Enter full name"),address_line1:n.required("Enter street address"),address_line2:o.nullable(),address_city:d.required("Enter city"),address_state:r.required("Select state"),address_postal_code:l.required("Enter postal code")}));const t=f.billingFormFields;t&&Object.keys(t).some((e=>t[e]))&&this.formController.setInitialValues(t),this.formController.values.subscribe((t=>this.billingInfo=Object.assign({},t))),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}componentDidLoad(){this.unsubscribeFromStore=m("billingFormFields",(t=>{this.formController.setInitialValues(t)}))}disconnectedCallback(){var t;null===(t=this.unsubscribeFromStore)||void 0===t||t.call(this)}async getValues(){return this.formController.values.getValue()}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){if(!this.formController)return null;const t=this.formController.getInitialValues();return e("div",{part:h,class:"mt-4"},e(u,{text:"Billing address",class:"fs-6 fw-bold lh-lg mb-4"}),e("form",null,e("fieldset",null,this.legend&&e("legend",null,this.legend),e("div",{class:"row gy-3"},e("div",{class:"col-12"},e("form-control-text",{name:"name",label:"Full Name",defaultValue:t.name,errorText:this.errors.name,inputHandler:this.inputHandler})),e("div",{class:"col-12"},e("form-control-text",{name:"address_line1",label:"Street Address",defaultValue:t.address_line1,errorText:this.errors.address_line1,inputHandler:this.inputHandler})),e("div",{class:"col-12"},e("form-control-text",{name:"address_line2",label:"Apartment, Suite, etc. (optional)",defaultValue:t.address_line2,errorText:this.errors.address_line2,inputHandler:this.inputHandler})),e("div",{class:"col-12"},e("form-control-text",{name:"address_city",label:"City",defaultValue:t.address_city,errorText:this.errors.address_city,inputHandler:this.inputHandler})),e("div",{class:"col-12"},e("form-control-select",{name:"address_state",label:"State",options:p,defaultValue:t.address_state,errorText:this.errors.address_state,inputHandler:this.inputHandler})),e("div",{class:"col-12"},e("form-control-text",{name:"address_postal_code",label:"Postal Code",defaultValue:t.address_postal_code,errorText:this.errors.address_postal_code,inputHandler:this.inputHandler,maxLength:7}))))))}},j=class{constructor(e){t(this,e),this.errors={},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}componentWillLoad(){this.formController=new i(a({name:c.nullable(),address_line1:n.nullable(),address_line2:o.nullable(),address_city:d.nullable(),address_state:r.nullable(),address_postal_code:l.required("Enter postal code")}));const t=f.billingFormFields;t&&Object.keys(t).some((e=>t[e]))&&this.formController.setInitialValues(t)}componentDidLoad(){this.formController.values.subscribe((t=>this.billingInfo=Object.assign({},t))),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)})),this.unsubscribeFromStore=m("billingFormFields",(t=>{this.formController.setInitialValues(t)}))}disconnectedCallback(){var t;null===(t=this.unsubscribeFromStore)||void 0===t||t.call(this)}async getValues(){return this.formController.values.getValue()}async validate(){return{isValid:await this.formController.validate(),errors:this.formController.errors.getValue()}}render(){const t=this.formController.getInitialValues();return e("div",{key:"c067c5a1aab63baa994322346b7cc3d71fca5157",part:h},e("form",{key:"72a74580a254d4c940579e0c5fa781e00a6a80d6"},e("fieldset",{key:"6beea66d6a8c863e228aafbd9e7ff78f5e19b033"},this.legend&&e("legend",{key:"ba5bb1b6b8d703898424113e5787a0ffb7f534af"},this.legend),e("div",{key:"cc3bc3446e475822c45d2ae261cdfb755e6313db",class:"row gy-3"},e("div",{key:"5dd21759753d2a5378d6dcc0b3b7ffb436c052db",class:"col-12"},e("form-control-text",{key:"033d5598a3ba198712189597ed1d1efe0dc09802",name:"address_postal_code",label:"Postal Code",defaultValue:t.address_postal_code,errorText:this.errors.address_postal_code,inputHandler:this.inputHandler,maxLength:7}))))))}};export{_ as bank_account_billing_form_simple,y as billing_form,v as billing_form_full,j as card_billing_form_simple}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as i,c as s,h as e,H as t}from"./p-CV0Pyo1O.js";import{r as a}from"./p-CPKMvyV_.js";const r=class{constructor(e){i(this,e),this.radioClick=s(this,"radio-click",7),this.checked=!1,this.hidden=!1,this.handleClick=()=>{this.radioClick.emit(this.value)}}render(){return e(t,{key:"72ed5a0699e0777e0e9fe64fcf4384ee3a6f1d1b"},e("div",{key:"0f6565adcc8fecd970e44ee5cd06f15d21cd2feb",class:`radio-list-item p-3 ${this.class||""}`,part:a,onClick:this.handleClick,hidden:this.hidden},e("form-control-radio",{key:"017390d5dc479fb85b3d4fa493f3aaf292bce7b5",name:this.name,value:this.value,checked:this.checked,label:this.label,inputHandler:()=>null})))}};export{r as radio_list_item}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as a}from"./p-CV0Pyo1O.js";import{J as i}from"./p-Cz_7BuGW.js";import{c as s}from"./p-mF5zKtkx.js";import{c as d}from"./p-BArmtmkq.js";import{c}from"./p-CPKMvyV_.js";import{S as o}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{P as f}from"./p-DkoufM1t.js";import"./p-OGt0dCJl.js";import"./p-CYQvLgSs.js";import"./p-DVJaoI_m.js";import"./p-D8GTwl9v.js";import"./p-BRnBHsdq.js";import"./p-HXpYMWUU.js";import"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const h=class{constructor(a){e(this,a),this.errorEvent=t(this,"error-event",7),this.loadedEvent=t(this,"loaded",7),this.submitEvent=t(this,"submit-event",7),this.availablePaymentMethods=[],this.errorMessage="",this.insuranceToggled=!1,this.disableBankAccount=!1,this.disableBnpl=!1,this.disableCreditCard=!1,this.disablePaymentMethodGroup=!1,this.hideBankAccountBillingForm=!1,this.hideCardBillingForm=!1}propChanged(){this.updateStore()}connectedCallback(){this.authToken&&this.checkoutId&&this.updateStore()}componentWillLoad(){s(),this.analytics=new i(this)}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.cleanup()}checkoutComplete(e){d.isSubmitting=!1}checkoutError(e){d.isSubmitting=!1}checkoutChanged(e){this.availablePaymentMethods=this.disableBnpl?e.detail.availablePaymentMethodTypes.filter((e=>e!==f.SEZZLE)):e.detail.availablePaymentMethodTypes}async fillBillingForm(e){d.billingFormFields=e}async validate(){var e;return{isValid:await(null===(e=this.modularCheckoutRef)||void 0===e?void 0:e.validate())}}updateStore(){d.checkoutId=this.checkoutId,d.authToken=this.authToken,d.disableCreditCard=this.disableCreditCard,d.disableBankAccount=this.disableBankAccount,d.disablePaymentMethodGroup=this.disablePaymentMethodGroup}async submit(e){var t;null===(t=this.modularCheckoutRef)||void 0===t||t.submitCheckout(d.billingFormFields)}get showPaymentTypeHeader(){return!this.disableCreditCard&&!this.disableBankAccount}render(){var e,t;return a(o,{key:"ffd2abaacc7edae588a9abe3a4ff96807b34fcff"},a("justifi-modular-checkout",{key:"9196c278e24353aeb1ac02c85253d629f683522b",ref:e=>{this.modularCheckoutRef=e},authToken:this.authToken,checkoutId:this.checkoutId,preCompleteHook:this.preCompleteHook},a("div",{key:"895298286bc0aa6acbda896a4f148dd4f8d7e7d2",class:"row gy-3 jfi-checkout-core"},a("div",{key:"dd186ed2f0fd479cd60024423b6d55625b962e55",class:"col-12",part:c},a("justifi-header",{key:"920d4eca26846aa1cbc16693fa45a9d8054d95a7",text:"Summary",level:"h2",class:"fs-5 fw-bold pb-3"}),a("section",{key:"560f8c3757a7cf53fd0aa898fd243b16a2f8e8d5"},a("justifi-checkout-summary",{key:"31faa6ca984aa22985927a1f80273c86a67c7025"}))),a("div",{key:"3128ae40a739573da32598213a289d8751503fb0",class:"col-12 mt-4"},a("slot",{key:"4a310881bbc4017734082d5c4f6b41d3d5f2a424",name:"insurance"})),a("div",{key:"8047c4da62e2fd67bd0b3f8654c6a19c0cacc255",class:"col-12 mt-4"},a("justifi-header",{key:"631ff14201f6246906e3e1572515de21a7977773",text:"Payment",level:"h2",class:"fs-5 fw-bold pb-3"}),this.showPaymentTypeHeader&&a("justifi-header",{key:"7fdc560ef42a5c2e8571f332e3c4ce8ff460d235",text:"Select payment type",level:"h3",class:"fs-6 fw-bold lh-lg"}),a("div",{key:"81dcb52c051044adb4dbd92ac73ee3096edc592b",class:"d-flex flex-column"},a("section",{key:"4359903b195009a2e8fb997a1f77880cba40dea4"},a("div",{key:"21728867e6288c3fb7d5e5a6ee3d15974568b866"},this.availablePaymentMethods.includes(f.APPLE_PAY)&&a("div",{key:"bdaa6b6c6d09cba294b2e46b85270241c86d2251",class:"mb-3"},a("justifi-apple-pay",{key:"150d707bff7b79a1d19141f21a9c47e00e54418a"})),this.availablePaymentMethods.includes(f.GOOGLE_PAY)&&a("div",{key:"ce2be06b20a1e7d0159fde68a1c5c349c2d11998",class:"mb-3"},a("justifi-google-pay",{key:"0fc867ce77467eb1f1fd198a62e88bd2795f4914",ref:e=>this.googlePayRef=e})),a("justifi-saved-payment-methods",{key:"0bb1999c093b3837bfdb879134dc54f66c90e164"}),this.availablePaymentMethods.includes(f.SEZZLE)&&a("justifi-radio-list-item",{key:"1599be9bcea7569d822a204c805f08f18a4e00a4",name:"paymentMethodType",value:f.SEZZLE,checked:(null===(e=null==d?void 0:d.selectedPaymentMethod)||void 0===e?void 0:e.type)===f.SEZZLE,label:a("justifi-sezzle-payment-method",{ref:e=>this.sezzlePaymentMethodRef=e}),"onRadio-click":()=>{var e;null===(e=this.sezzlePaymentMethodRef)||void 0===e||e.handleSelectionClick()}}),this.availablePaymentMethods.includes(f.PLAID)&&!this.disableBnpl&&a("justifi-radio-list-item",{key:"c1de230257d290efa05f7a7166c2f069451c71a3",name:"paymentMethodType",value:f.PLAID,checked:(null===(t=null==d?void 0:d.selectedPaymentMethod)||void 0===t?void 0:t.type)===f.PLAID,label:a("justifi-plaid-payment-method",{ref:e=>this.plaidPaymentMethodRef=e}),"onRadio-click":()=>{var e;null===(e=this.plaidPaymentMethodRef)||void 0===e||e.handleSelectionClick()}}),a("justifi-tokenize-payment-method",{key:"44bca4ee57857afd4eee213cef98db2d4bd42490",ref:e=>this.tokenizePaymentMethodRef=e,authToken:this.authToken,accountId:d.accountId,disableCreditCard:this.disableCreditCard,disableBankAccount:this.disableBankAccount,hideCardBillingForm:this.hideCardBillingForm,hideBankAccountBillingForm:this.hideBankAccountBillingForm,hideSubmitButton:!0,paymentMethodGroupId:d.paymentMethodGroupId}))))),a("div",{key:"e5b6b4ac6b0fcec20380082f1b4cc5ba73bb88aa",class:"mt-4"},a("justifi-button",{key:"188a8f46fd37b5f4f2d9b3ba7ff179d44d4a6656",text:"Pay",type:"submit",variant:"primary",clickHandler:e=>this.submit(e),disabled:d.isSubmitting||d.isWalletProcessing,isLoading:d.isSubmitting||d.isWalletProcessing,customStyle:{width:"100%",textAlign:"center"}})))))}static get watchers(){return{authToken:["propChanged"],checkoutId:["propChanged"],disableCreditCard:["propChanged"],disableBankAccount:["propChanged"],disablePaymentMethodGroup:["propChanged"]}}};export{h as justifi_checkout}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as s,c as i}from"./p-CV0Pyo1O.js";import{A as e}from"./p-CYQvLgSs.js";import{C as r,e as o}from"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{g as a,a as n}from"./p-Cm9f5fyh.js";import{J as c}from"./p-Cz_7BuGW.js";import{c as l}from"./p-mF5zKtkx.js";import{c as h}from"./p-BArmtmkq.js";import{p as d,f as p,r as u,j as v}from"./p-BRnBHsdq.js";import{v as m,i as y,a as f,H as j}from"./p-D-zwk1J3.js";import{t as _,z as g}from"./p-CPKMvyV_.js";import{S as C}from"./p-BqNNwq6C.js";import"./p-CZfYo5-1.js";import{S as k}from"./p-uZ5KAseb.js";import"./p-DVJaoI_m.js";import"./p-D8GTwl9v.js";import"./p-OGt0dCJl.js";import"./p-DkoufM1t.js";import"./p-HXpYMWUU.js";const w=e();class b{async fetchQuote(t,s){return w.post({endpoint:"insurance/quotes",body:s,authToken:t})}async toggleCoverage(t,s,i){return w.post({endpoint:`insurance/quotes/${s}/toggle`,body:i,authToken:t})}}const T=()=>t("div",{class:"row gap-3"},t("div",{class:"col-12"},t(k,{width:"35%",height:"30px"})),t("div",{class:"col-12"},t(k,{width:"70%"})),t("div",{class:"col-12"},t(k,{width:"40%"})),t("div",{class:"col-12"},t(k,{width:"40%"})),t("div",{class:"col-12"},t(k,{width:"100%"})),t("div",{class:"col-12"},t(k,{width:"80%"}))),q=class{constructor(t){s(this,t),this.insuranceUpdated=i(this,"insurance-updated",7),this.errorEvent=i(this,"error-event",7),this.isLoading=!0}async validate(){return m()}processHTMLContent(t){return d(t,[t=>u(t,"style"),t=>v(t,"a","part",_),t=>v(t,"p","part",_)])}componentWillLoad(){l(),this.analytics=new c(this),this.initializeServiceMethods(),this.getQuote&&this.fetchData()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}initializeServiceMethods(){const t=this.authToken||h.authToken;if(!t)return void this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:"Missing authToken",severity:r.ERROR});const s={authToken:t,service:new b};this.getQuote=(({authToken:t,service:s})=>async({payload:i,onSuccess:e,onError:o})=>{var c;try{const l=await s.fetchQuote(t,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(t){const s=a(null==t?void 0:t.code);return o({error:t.message||t,code:s,severity:r.ERROR})}})(s),this.toggleCoverage=(({authToken:t,service:s})=>async({quoteId:i,payload:e,onSuccess:o,onError:c})=>{var l;try{const h=await s.toggleCoverage(t,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(t){const s=a(null==t?void 0:t.code);return c({error:t.message||t,code:s,severity:r.ERROR})}})(s)}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:t})=>{this.quote=t,this.quote.product.description=this.processHTMLContent(this.quote.product.description),this.quote.product.legal_disclaimer=this.processHTMLContent(this.quote.product.legal_disclaimer),y[t.policy_type]=t.accepted,this.isLoading=!1},onError:({error:t,code:s,severity:i})=>{this.isLoading=!1,this.errorEvent.emit({errorCode:s,message:t,severity:i})}})}onChangeHandler(t,s){this.accepted=s,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:t,code:s,severity:i})=>{this.errorEvent.emit({errorCode:s,message:t,severity:i})}})}get error(){var t;return f[null===(t=this.quote)||void 0===t?void 0:t.policy_type]}render(){var s,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):t(C,null,this.isLoading?t(T,null):t("div",null,t(j,{text:null===(s=this.quote)||void 0===s?void 0:s.product.title,class:"fs-5 fw-bold pb-3"}),t("small",{part:_,innerHTML:null===(i=this.quote)||void 0===i?void 0:i.product.description}),t("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}),t("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}),t("div",{class:"invalid-feedback",style:{display:this.error?"block":"none"},part:g},"Please select an option"),t("small",{part:_,innerHTML:null===(r=this.quote)||void 0===r?void 0:r.product.legal_disclaimer})))}};export{q as justifi_season_interruption_insurance}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as s,h as t}from"./p-CV0Pyo1O.js";import{S as e}from"./p-BqNNwq6C.js";import{S as o}from"./p-uZ5KAseb.js";import"./p-CPKMvyV_.js";const r=class{constructor(t){s(this,t)}render(){return t(e,{key:"c995981caeae785829f1ef75454b2759243e8adb"},t(o,{key:"9c63cf385499820bb1acd3503e126363485684f6",component:this.component,height:this.height,width:this.width,className:this.class,styles:this.customStyle}))}};export{r as justifi_skeleton}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as e,h as s,H as i}from"./p-CV0Pyo1O.js";import{C as a,e as r,E as n,z as o,B as h,w as l,x as c,y as d}from"./p-NZS8uCtH.js";import{m as u,a as m,c as b,d as p,e as f,f as v,g as y}from"./p-APOabprT.js";import{B as g,a as k,D as w,I as _}from"./p-BJu1-9kE.js";import{a as T,d as x,b as L,g as C,h as j}from"./p-6RTf1SXX.js";import{F as O,a as A,c as E,b as S,d as D}from"./p-DwoT0UoX.js";import{A as H,C as V,e as I,R as P,f as B,O as N}from"./p-BcNb9bVO.js";import{C as M,P as R,I as F}from"./p-CVaOFfrI.js";import{b as W,a0 as q,C as Z,x as U,u as z,D as Y,aa as X,a6 as $,aj as G,am as K,A as J,a1 as Q}from"./p-CPKMvyV_.js";import{P as tt}from"./p-DSclFZ32.js";import{b as et,a as st,c as it}from"./p-Bt4GjEWL.js";import{a as at,B as rt}from"./p-XYgDHrVL.js";import"./p-DVJaoI_m.js";import"./p-HXpYMWUU.js";import"./p-CLHwhyvu.js";import{n as nt}from"./p-BnjCmwMr.js";import{A as ot,B as ht,v as lt,C as ct,D as dt,E as ut,F as mt}from"./p-KXLYEe1D.js";import{B as bt}from"./p-CHo7TfsM.js";import"./p-CZfYo5-1.js";import{a as pt}from"./p-DyucNSA4.js";import{s as ft,b as vt,d as yt}from"./p-BRnBHsdq.js";import{S as gt}from"./p-uZ5KAseb.js";import{u as kt,a as wt,b as _t}from"./p-C6o0liMT.js";import{A as Tt}from"./p-CYQvLgSs.js";import{S as xt}from"./p-BqNNwq6C.js";import{P as Lt}from"./p-av6jyzyC.js";import"./p-Cm9f5fyh.js";import"./p-BFTU3MAI.js";import"./p-D8GTwl9v.js";class Ct{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 jt=class{constructor(s){t(this,s),this.errorEvent=e(this,"error-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.formLoading=e(this,"formLoading",7),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 H(t.data.additional_questions||{}),this.formController.setInitialValues(Object.assign({},this.additional_questions))},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=t=>{let e;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:s=>{e=s,t()},onError:({error:t,code:s,severity:i})=>{e=t,this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:e,formStep:at.additionalQuestions}),this.formLoading.emit(!1)}})},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e})),this.additional_questions=new H(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}propChanged(){this.initializeApi()}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 H(this.formController.values.getValue()).payload}}componentWillLoad(){this.initializeApi(),this.formController=new O(T(this.allowOptionalFields))}componentDidLoad(){this.getBusiness&&this.getData(),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.patchBusiness=m({authToken:this.authToken,businessId:this.businessId,service:new g})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}render(){var t,e,i,a,r;const n=this.formController.getInitialValues();return this.isLoading?s(tt,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Additional Questions"),s("form-control-tooltip",{helpText:"This information helps us understand the business and identify and monitor trends to safeguard you and your customers."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12 col-md-6"},s("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===(t=this.errors)||void 0===t?void 0:t.business_revenue,defaultValue:null==n?void 0:n.business_revenue,maskOptions:M.WHOLE})),s("div",{class:"col-12 col-md-6"},s("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==n?void 0:n.business_payment_volume,maskOptions:M.WHOLE})),s("div",{class:"col-12"},s("form-control-text",{name:"business_average_transaction_amount",label:"What is your average transaction size?",inputHandler:this.inputHandler,errorText:null===(i=this.errors)||void 0===i?void 0:i.business_average_transaction_amount,defaultValue:null==n?void 0:n.business_average_transaction_amount})),s("div",{class:"col-12"},s("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===(a=this.errors)||void 0===a?void 0:a.business_when_service_received,options:et,defaultValue:null==n?void 0:n.business_when_service_received})),s("div",{class:"col-12"},s("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===(r=this.errors)||void 0===r?void 0:r.business_other_payment_details,defaultValue:null==n?void 0:n.business_other_payment_details})))))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"],additional_questions:["recurringPaymentsWatcher"]}}},Ot=class{constructor(e){t(this,e)}render(){return s("div",{key:"d0dacb95d07d3e4ca9bc2c9f23b6c490871da4e9",class:"row gy-3"},s("div",{key:"02ed406f38558badf9f591e076b120d09c71f83b",class:"col-12"},s("form-control-file",{key:"11ff1dc68264b9e5aa561ffe19b423abc1a00c78",name:"voided_check",label:"Voided Check",documentType:n.voidedCheck,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.voided_check,multiple:!0})),s("div",{key:"71d26407522a75a54489155566c18af1a64c1417",class:"col-12"},s("form-control-file",{key:"7ea42e03a44c223a5fedc273e94e635e70d54f4b",name:"bank_statement",label:"Bank Statement",documentType:n.bankStatement,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.bank_statement,multiple:!0})))}},At=class{constructor(e){t(this,e)}render(){var t,e,i,a,r,n;return s("div",{key:"d3445ce89732e19baea2e8f224c42011d5a03998",class:"row gy-3"},s("div",{key:"966e1d8ba6043b4f9b57ae0061ae94c177c12b48",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Bank Name",value:null===(t=this.defaultValue)||void 0===t?void 0:t.bank_name}):s("form-control-text",{name:"bank_name",label:"Bank Name",defaultValue:this.defaultValue.bank_name,errorText:this.errors.bank_name,inputHandler:this.inputHandler})),s("div",{key:"314a4f7e181b978b2ff1fdbfdfc8d9484089829a",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Nickname",value:null===(e=this.defaultValue)||void 0===e?void 0:e.nickname}):s("form-control-text",{name:"nickname",label:"Nickname",defaultValue:this.defaultValue.nickname,errorText:this.errors.nickname,inputHandler:this.inputHandler})),s("div",{key:"45ac55707ce44b208adaf72e944ea3056810183a",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Owner Name",value:null===(i=this.defaultValue)||void 0===i?void 0:i.account_owner_name}):s("form-control-text",{name:"account_owner_name",label:"Account Owner Name",defaultValue:this.defaultValue.account_owner_name,errorText:this.errors.account_owner_name,inputHandler:this.inputHandler})),s("div",{key:"74ce58b36eb3a425d900d7bb0858bda18b2e341c",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Type",value:null===(a=this.defaultValue)||void 0===a?void 0:a.account_type}):s("form-control-select",{name:"account_type",label:"Account Type",options:st,defaultValue:this.defaultValue.account_type,errorText:this.errors.account_type,inputHandler:this.inputHandler})),s("div",{key:"2562105aaaae00d9c46eb61d931a43927d96a8ce",class:"col-6"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Number",value:(null===(r=this.defaultValue)||void 0===r?void 0:r.account_number_last4)?`**** ${this.defaultValue.account_number_last4}`:""}):s("form-control-text",{name:"account_number",label:"Account Number",defaultValue:this.defaultValue.account_number,maxLength:17,errorText:this.errors.account_number,inputHandler:this.inputHandler,keyDownHandler:nt,helpText:"Please copy the account number as shown on your statement/check. Do not include spaces or dashes."})),s("div",{key:"4c7e6cba0ee1e2567dc5b608559b13ebd3fddd07",class:"col-6"},this.formDisabled?s("bank-account-read-only-value",{label:"Routing Number",value:(null===(n=this.defaultValue)||void 0===n?void 0:n.routing_number)||""}):s("form-control-text",{name:"routing_number",label:"Routing Number",defaultValue:this.defaultValue.routing_number,maxLength:9,errorText:this.errors.routing_number,inputHandler:this.inputHandler,keyDownHandler:nt,helpText:"A valid routing number is nine digits. Please include any leading or trailing zeroes."})))}},Et=class{constructor(e){t(this,e)}render(){var t,e,i,a,r,n,o;return s("div",{key:"8de8f05777f72ecb1112328544e75be7cd929e8d",class:"row gy-3"},s("div",{key:"513fb78b434ba3aebe51b636f7494b54e437c65f",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Bank Name",value:null===(t=this.defaultValue)||void 0===t?void 0:t.bank_name}):s("form-control-text",{name:"bank_name",label:"Bank Name",defaultValue:this.defaultValue.bank_name,errorText:this.errors.bank_name,inputHandler:this.inputHandler})),s("div",{key:"37a1ef4ac58fbe1633a93020e786d546cd832867",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Nickname",value:null===(e=this.defaultValue)||void 0===e?void 0:e.nickname}):s("form-control-text",{name:"nickname",label:"Nickname",defaultValue:this.defaultValue.nickname,errorText:this.errors.nickname,inputHandler:this.inputHandler})),s("div",{key:"fc8820e264d14ac3c5a1c6fd171b381c2b6d99e1",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Owner Name",value:null===(i=this.defaultValue)||void 0===i?void 0:i.account_owner_name}):s("form-control-text",{name:"account_owner_name",label:"Account Owner Name",defaultValue:this.defaultValue.account_owner_name,errorText:this.errors.account_owner_name,inputHandler:this.inputHandler})),s("div",{key:"f183b1c5f6a8b0f905c916cd1715448f3e02d26f",class:"col-12"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Type",value:null===(a=this.defaultValue)||void 0===a?void 0:a.account_type}):s("form-control-select",{name:"account_type",label:"Account Type",options:st,defaultValue:this.defaultValue.account_type,errorText:this.errors.account_type,inputHandler:this.inputHandler})),s("div",{key:"8366ebde2f319f6d910a34917f57ad43b3ee234f",class:"col-3"},this.formDisabled?s("bank-account-read-only-value",{label:"Transit Number",value:(null===(r=this.defaultValue)||void 0===r?void 0:r.transit_number)||""}):s("form-control-text",{name:"transit_number",label:"Transit Number",defaultValue:this.defaultValue.transit_number,maxLength:5,errorText:this.errors.transit_number,inputHandler:this.inputHandler,keyDownHandler:nt,helpText:"5 digits"})),s("div",{key:"c91166337c2984048466014634f5d4e59ce2b40a",class:"col-3"},this.formDisabled?s("bank-account-read-only-value",{label:"Institution Number",value:(null===(n=this.defaultValue)||void 0===n?void 0:n.institution_number)||""}):s("form-control-text",{name:"institution_number",label:"Institution Number",defaultValue:this.defaultValue.institution_number,maxLength:3,errorText:this.errors.institution_number,inputHandler:this.inputHandler,keyDownHandler:nt,helpText:"3 digits"})),s("div",{key:"ebce2f50ec265ed2fef7a0b3dae84d33036ad145",class:"col-6"},this.formDisabled?s("bank-account-read-only-value",{label:"Account Number",value:(null===(o=this.defaultValue)||void 0===o?void 0:o.account_number_last4)?`**** ${this.defaultValue.account_number_last4}`:""}):s("form-control-text",{name:"account_number",label:"Account Number",defaultValue:this.defaultValue.account_number,maxLength:17,errorText:this.errors.account_number,inputHandler:this.inputHandler,keyDownHandler:nt,helpText:"Please copy the account number as shown on your statement. Do not include spaces or dashes."})))}},St=(t,e)=>t.some((t=>t.document_type===e)),Dt=t=>t?{bank_name:dt.nullable(),nickname:ct.nullable(),account_owner_name:lt.nullable(),account_type:ht.nullable(),account_number:ot.nullable()}:{bank_name:dt.required("Enter bank name"),nickname:ct.required("Enter nickname"),account_owner_name:lt.required("Enter account owner name"),account_type:ht.required("Select account type"),account_number:ot.required("Enter account number")},Ht=(t,e)=>{if(e)return{voided_check:S().nullable(),bank_statement:S().nullable()};const s=St(t,n.voidedCheck),i=St(t,n.bankStatement),a=s||i,r="Please upload either a voided check or a bank statement. Only one is required.";return{voided_check:S().when("bank_statement",{is:t=>!t&&!a,then:t=>t.required(r),otherwise:t=>t.notRequired()}),bank_statement:S().when("voided_check",{is:t=>!t&&!a,then:t=>t.required(r),otherwise:t=>t.notRequired()})}},Vt={[V.USA]:(t,e=[])=>((t,e)=>{const s=Object.assign(Object.assign(Object.assign({},Dt(e)),(t=>t?{routing_number:mt.nullable()}:{routing_number:mt.required("Enter routing number")})(e)),Ht(t,e));return A().shape(s,[["voided_check","bank_statement"]])})(e,t),[V.CAN]:(t,e=[])=>((t,e)=>{const s=Object.assign(Object.assign(Object.assign({},Dt(e)),(t=>{const e=E().length(3,"Institution number must be 3 digits").matches(ut,"Enter valid institution number"),s=E().length(5,"Transit number must be 5 digits").matches(ut,"Enter valid transit number");return t?{institution_number:e.nullable(),transit_number:s.nullable()}:{institution_number:e.required("Enter institution number"),transit_number:s.required("Enter transit number")}})(e)),Ht(t,e));return A().shape(s,[["voided_check","bank_statement"]])})(e,t)},It=class{constructor(s){t(this,s),this.errorEvent=e(this,"error-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.formLoading=e(this,"formLoading",7),this.errors={},this.bankAccount={},this.existingDocuments=[],this.documentData=new o,this.isLoading=!1,this.viewMode="manual",this.bankAccountVerification=!1,this.platformAccountId=null,this.getSchema=()=>(0,Vt[this.country])(this.allowOptionalFields,this.existingDocuments),this.initializeFormController=()=>{this.formController=new O(this.getSchema()),this.formController.setInitialValues("readonly"===this.viewMode?Object.assign({},this.bankAccount):{business_id:this.businessId}),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))},this.storeFiles=t=>{const e=Array.from(t.detail.fileList),s=t.detail.document_type,i=e.map((t=>new h({file:t,document_type:s},this.businessId)));this.documentData[s]=i},this.getData=()=>{this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.processBusinessResponse(t.data),this.determineViewMode()},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.initializeFormController(),this.isLoading=!1}})},this.handleChangeBankAccount=()=>{this.viewMode=this.plaidAvailable?"plaid":"manual",this.documentData=new o,this.initializeFormController()},this.handleCancel=()=>{this.viewMode=this.existingBankAccount?"readonly":"plaid",this.documentData=new o,this.initializeFormController()},this.handleToggleToManualEntry=()=>{this.viewMode="manual"},this.handleToggleToPlaidVerification=()=>{this.viewMode="plaid"},this.handleSaveBankAccount=async()=>{this.formController.validateAndSubmit((()=>{this.sendData((()=>{}))}))},this.postDocumentRecordData=async t=>{this.isLoading=!0;const e=t.record_data;return new Promise((s=>{this.postDocumentRecord({payload:e,onSuccess:e=>{s(this.handleDocRecordResponse(t,e))},onError:({error:t,code:e,severity:i})=>{this.errorEvent.emit({message:t,errorCode:e,severity:i}),s(!1)}})}))},this.handleDocRecordResponse=(t,e)=>e.error?(this.errorEvent.emit({errorCode:r.POST_ERROR,message:e.error.message,severity:a.ERROR,data:e.error}),!1):(t.setPresignedUrl(e.data.presigned_url),!0),this.uploadDocument=async t=>{if(!t.presigned_url)throw new Error("Presigned URL is not set");const e=await t.getFileData(),s=await fetch(t.presigned_url,{method:"PUT",body:e});return this.handleUploadResponse(s)},this.handleUploadResponse=t=>!t.error||(this.errorEvent.emit({errorCode:r.POST_ERROR,message:t.error.message,severity:a.ERROR,data:t.error}),!1)}propChanged(){this.initializeApi()}watchHandler(t){this.formLoading.emit(t)}async validateAndSubmit({onSuccess:t}){"readonly"===this.viewMode?this.sendData(t):this.formController.validateAndSubmit((()=>this.sendData(t)))}componentWillLoad(){this.initializeApi(),this.getBusiness&&this.getData(),this.formController=new O(this.getSchema())}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.postBankAccount=b({authToken:this.authToken,service:new k}),this.postDocumentRecord=p({authToken:this.authToken,service:new w})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}get postPayload(){const t=this.formController.values.getValue();return new Ct(t).payload}get existingBankAccount(){var t;return!!(null===(t=this.bankAccount)||void 0===t?void 0:t.id)}get plaidAvailable(){return this.bankAccountVerification&&!!this.platformAccountId}get showCancel(){return this.bankAccountVerification||this.existingBankAccount}processBusinessResponse(t){const{bank_accounts:e,documents:s,settings:i,platform_account_id:a}=t;e.length>0?this.bankAccount=new Ct(e[e.length-1]):(this.bankAccount=new Ct({}),this.bankAccount.business_id=this.businessId),this.existingDocuments=s,this.bankAccountVerification=!0===i.bank_account_verification,this.platformAccountId=a}determineViewMode(){this.viewMode=this.existingBankAccount?"readonly":this.plaidAvailable?"plaid":"manual"}async sendData(t){try{if("manual"===this.viewMode&&!await this.postBankAccountData())return;if(!await this.postBusinessDocuments())return;"manual"===this.viewMode&&(this.viewMode="readonly",await this.refreshBankAccountData()),t()}catch(t){this.errorEvent.emit({message:t,errorCode:r.POST_ERROR,severity:a.ERROR})}}async postBankAccountData(){let t;return this.isLoading=!0,new Promise((e=>{let s=!1;this.postBankAccount({payload:this.postPayload,onSuccess:e=>{t=e,s=!0},onError:({error:t,code:e,severity:i})=>{s=!1,this.errorEvent.emit({message:t,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:at.bankAccount}),this.isLoading=!1,e(s)}})}))}async refreshBankAccountData(){return new Promise((t=>{this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.processBusinessResponse(t.data),this.determineViewMode(),this.initializeFormController()},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.isLoading=!1,t()}})}))}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}}renderBankAccountInputs(t){const e=this.formController.getInitialValues();return s(this.country===V.CAN?"bank-account-form-inputs-canada":"bank-account-form-inputs",{defaultValue:e,errors:this.errors,inputHandler:this.inputHandler,formDisabled:t})}renderReadonlyView(){return s("div",null,this.renderBankAccountInputs(!0),s("div",{class:"mt-3"},s(bt,{variant:"secondary",type:"button",onClick:this.handleChangeBankAccount,disabled:this.isLoading,part:q},"Change Bank Account")))}renderPlaidView(){return s("div",{class:"mt-3"},s("plaid-verification",{authToken:this.authToken,accountId:this.platformAccountId,businessId:this.businessId,onPlaidVerificationSuccess:()=>{this.viewMode="readonly",this.refreshBankAccountData()}}),s("div",{class:"mt-3"},s(bt,{type:"button",variant:"link",className:"p-0",onClick:this.handleToggleToManualEntry,disabled:this.isLoading,part:Z},"Enter bank details manually (document upload required)")))}renderManualEntryView(){return s("div",null,this.plaidAvailable&&s("div",{class:"mb-3"},s(bt,{type:"button",variant:"secondary",onClick:this.handleToggleToPlaidVerification,disabled:this.isLoading,part:q},"Link bank account with Plaid instead")),this.renderBankAccountInputs(!1),s("div",{class:"mt-3 d-flex gap-2"},this.showCancel&&s(bt,{variant:"secondary",type:"button",onClick:this.handleCancel,disabled:this.isLoading,part:q},"Cancel"),s(bt,{variant:"primary",type:"button",onClick:this.handleSaveBankAccount,disabled:this.isLoading,isLoading:this.isLoading},"Save Bank Account")))}renderDocumentUploads(){return s("fieldset",{class:"mt-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Document Uploads"),s("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."})),s("hr",{class:"mt-2"}),s("business-documents-on-file",{documents:this.existingDocuments,isLoading:this.isLoading}),s("bank-account-document-form-inputs",{inputHandler:this.inputHandler,errors:this.errors,storeFiles:this.storeFiles}))}render(){return this.isLoading?s(tt,null):s("form",null,s("fieldset",{class:"mb-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Bank Account Info"),s("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."})),s("hr",{class:"mt-2"}),"readonly"===this.viewMode&&this.renderReadonlyView(),"plaid"===this.viewMode&&this.renderPlaidView(),"manual"===this.viewMode&&this.renderManualEntryView()),"plaid"!==this.viewMode&&this.renderDocumentUploads())}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"],isLoading:["watchHandler"]}}},Pt=class{constructor(s){t(this,s),this.errorEvent=e(this,"error-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.formLoading=e(this,"formLoading",7),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 I(t.data),this.formController.setInitialValues(Object.assign({},this.coreInfo))},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let e;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:s=>{e=s,t(),this.isEditingTaxId=!1},onError:({error:t,code:s,severity:i,rawError:a})=>{e=t,a&&"object"==typeof a&&a.param&&this.formController.setFieldError(a.param,a.message),this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:e,formStep:at.businessInfo}),this.formLoading.emit(!1)}})},this.inputHandler=(t,e)=>{this.errors[t]&&this.formController.clearFieldError(t),this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return new I(this.formController.values.getValue()).payload}componentWillLoad(){this.initializeApi();const t=this.country===V.CAN?x(this.allowOptionalFields):L(this.allowOptionalFields);this.formController=new O(t),this.getData()}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.patchBusiness=m({authToken:this.authToken,businessId:this.businessId,service:new g})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}render(){var t,e;const i=this.formController.getInitialValues();return this.isLoading?s(tt,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Business Information")),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12 col-md-6"},s("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)."})),s("div",{class:"col-12 col-md-6"},s("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)"})),s("div",{class:"col-12 col-md-8"},s("form-control-select",{name:"classification",label:"Business Classification",options:it,defaultValue:i.classification,errorText:this.errors.classification,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-4"},s("form-control-date",{name:"date_of_incorporation",label:"Date of Registration",defaultValue:i.date_of_incorporation,errorText:this.errors.date_of_incorporation,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"industry",label:"Industry",defaultValue:i.industry,errorText:this.errors.industry,inputHandler:this.inputHandler,helpText:"Describe what you sell"})),s("div",{class:"col-12 col-md-6"},!(null===(t=this.coreInfo)||void 0===t?void 0:t.tax_id_last4)||this.isEditingTaxId?s("form-control-number-masked",{name:"tax_id",label:pt[this.country].taxIdLabel,defaultValue:this.isEditingTaxId?"":i.tax_id,errorText:this.errors.tax_id,inputHandler:this.inputHandler,mask:"000000000",helpText:pt[this.country].taxIdHelpText}):s("div",null,s("label",{class:"form-label",part:U},pt[this.country].taxIdLabel),s("div",{class:"input-group mb-3"},s("input",{type:"text",class:"form-control",part:z,value:`****${null===(e=this.coreInfo)||void 0===e?void 0:e.tax_id_last4}`,disabled:!0}),s("button",{class:"btn btn-secondary",type:"button",part:q,onClick:()=>{this.isEditingTaxId=!0,this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{tax_id:"",tax_id_last4:null}))}},"Change")))),s("div",{class:"col-12"},s("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."})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"email",label:"Business Email Address",defaultValue:i.email,errorText:this.errors.email,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-number-masked",{name:"phone",label:"Business Phone Number",defaultValue:i.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:R.US})))))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},Bt=class{constructor(e){t(this,e),this.documents=[],this.isLoading=!1}render(){return this.isLoading?s(gt,{height:"50px"}):this.documents.length?s(i,null,s("div",{class:"card",part:Y},s("div",{class:"card-body"},s("h5",{class:"card-title",part:W},"Documents Already on File"),s("div",{class:"table-responsive"},s("table",{class:"table table-sm table-borderless",part:X},s("thead",null,s("tr",null,s("th",{style:{width:"25%"},part:$,scope:"col"},"File Name"),s("th",{style:{width:"25%"},part:$,scope:"col"},"File Type"),s("th",{style:{width:"25%"},part:$,scope:"col"},"Document Type"),s("th",{style:{width:"25%"},part:$,scope:"col"},"Date Uploaded"))),s("tbody",null,this.documents.sort(((t,e)=>t.document_type.localeCompare(e.document_type))).map(((t,e)=>s("tr",{class:0===e?"border-bottom border-top":"border-bottom"},s("td",{part:G},t.file_name),s("td",{part:G},t.file_type),s("td",{part:G},ft(t.document_type)),s("td",{part:G},`${vt(t.created_at)} - ${yt(t.created_at)}`))))))))),s("hr",null)):null}},Nt=class{constructor(s){t(this,s),this.clickEvent=e(this,"click-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.ownersPayload=[],this.refs=[],this.isLoading=!1,this.representativeIsOwner=null,this.matchRef=(t,e)=>{if(null===t)return;const s=this.ownersPayload.findIndex((t=>t.id===e));-1!==s&&(this.refs.length!==this.ownersPayload.length&&this.manageRefs(),this.refs[s]=t)},this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.representative=new P(t.data.representative||{}),t.data.owners.length?this.ownersPayload=t.data.owners.map((t=>({id:t.id}))):this.addOwnerForm()},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1,this.manageRefs()}})},this.sendData=async t=>{let e;this.formLoading.emit(!0),this.patchBusiness({payload:{owners:this.ownersPayload},onSuccess:s=>{e=s,t()},onError:({error:t,code:s,severity:i})=>{e=t,this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:e,formStep:at.owners}),this.formLoading.emit(!1)}})},this.addOwnerForm=t=>{this.newFormOpen=!0,this.ownersPayload=[...this.ownersPayload,{id:""}],t&&this.clickEvent.emit({name:rt.addOwnerForm})},this.removeOwnerForm=t=>{this.ownersPayload=this.ownersPayload.filter((e=>e.id!==t)),this.newFormOpen&&(this.newFormOpen=!1)},this.handleRepresentativeIsOwnerChange=t=>{this.representativeIsOwner=t,this.representativeIsOwner&&(this.formLoading.emit(!0),this.isLoading=!0,this.ownersPayload=this.ownersPayload.filter((t=>""!==t.id)),this.patchBusiness({payload:{owners:[{id:this.representative.id},...this.ownersPayload]},onSuccess:()=>{this.getData(),this.newFormOpen=!1},finally:()=>{this.isLoading=!1,this.formLoading.emit(!1)}}))}}propChanged(){this.initializeApi()}get showAddOwnerButton(){return this.ownersPayload.length<4&&!this.newFormOpen}manageRefs(){this.refs=this.ownersPayload.map((t=>t.id))}async validateAndSubmit({onSuccess:t}){const e=this.refs.map((t=>t.validate()));if(!(await Promise.all(e)).every((t=>t)))return;const s=this.refs.map((t=>t.submit()));(await Promise.all(s)).every((t=>t))&&this.sendData(t)}componentWillLoad(){this.initializeApi(),this.getBusiness&&this.getData()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.patchBusiness=m({authToken:this.authToken,businessId:this.businessId,service:new g})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}ownersWatcher(){this.manageRefs()}handleOwnerSubmit(t){const e=t.detail,s=this.ownersPayload.map((t=>t.id===e.id?e:t));s.includes(e)||(s[this.ownersPayload.findIndex((t=>!t.id))]=e,this.newFormOpen&&(this.newFormOpen=!1)),this.ownersPayload=s}render(){if(this.isLoading)return s(i,null,s(tt,null));const t=this.ownersPayload.some((t=>t.id===this.representative.id)),e=null===this.representativeIsOwner&&!t;return s(i,null,s("div",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Owners"),s("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."})),s("hr",{class:"mt-2"}),e&&s("div",{class:"alert alert-warning mb-3",part:K},s("div",{class:"card-body"},s("div",{class:"d-flex align-items-center mb-3"},s("strong",null,"Is the representative of this business also an owner?")),s("div",{class:"d-flex gap-2"},s(bt,{variant:"primary",onClick:()=>this.handleRepresentativeIsOwnerChange(!0)},"Yes"),s(bt,{variant:"secondary",onClick:()=>this.handleRepresentativeIsOwnerChange(!1)},"No")))),s("div",{class:"row gy-3"},this.ownersPayload.map((t=>s("owner-form",{key:t.id,authToken:this.authToken,businessId:this.businessId,ownerId:t.id,removeOwner:this.removeOwnerForm,newFormOpen:this.newFormOpen,ownersLength:this.ownersPayload.length,country:this.country,allowOptionalFields:this.allowOptionalFields,ref:e=>this.matchRef(e,t.id)})))),s("div",{class:"d-flex justify-content-start"},s("div",{class:"gap-2"},s(bt,{variant:"primary",onClick:()=>this.addOwnerForm(!0),hidden:!this.showAddOwnerButton},"Add Owner")))))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"],ownersPayload:["ownersWatcher"]}}},Mt=class{constructor(e){t(this,e),this.isEditingIdentification=!1,this.inputHandler=(t,e)=>{kt(this.formController,{[t]:e})},this.onAddressFormUpdate=t=>{wt(this.formController,Object.assign(Object.assign({},this.formController.values.getValue().address),t))}}render(){var t,e,i,a,r,n,o,h,l;return s("form",{key:"ef49167cc726b3d4efa128503553a77a7627ebee"},s("fieldset",{key:"3714ce7eab6e9cee062911564d1c2635b68dfc8b"},s("div",{key:"4f27236b0438e29d7449bf5e9f71c00c7245effa",class:"d-flex align-items-center gap-2"},s("legend",{key:"adc144da314549264571b245c5388ab56c1dbbf1",class:"mb-0",part:W},"Representative"),s("form-control-tooltip",{key:"bcc76add04febe984427103a594aa63cab17bd27",helpText:"The representative for your business needs to be someone who has significant control over managing your business's finance. You will have an opportunity to add owners later in the form."})),s("hr",{key:"98bfed19989ee57e451a7005f3e60af16cc5d3b5",class:"mt-2"}),s("div",{key:"8f5e0e3deed2627ecf9f77290f268c0e2ee68bfa",class:"row gy-3"},s("div",{key:"b1205284a54a608b9c3b6be386e134849c9c6b25",class:"col-12 col-md-8"},s("form-control-text",{key:"36fcd91ca263adfd9fb69dc88f15404f93a8bc13",name:"name",label:"Full Name",defaultValue:null===(t=this.representativeDefaultValue)||void 0===t?void 0:t.name,errorText:this.errors.name,inputHandler:this.inputHandler})),s("div",{key:"879337d3c6a120f5dc9de3cd3364b34b9c4689df",class:"col-12 col-md-4"},s("form-control-text",{key:"ff2e4d29e76b93693735b35cbaca4416f0cd28a0",name:"title",label:"Title",defaultValue:null===(e=this.representativeDefaultValue)||void 0===e?void 0:e.title,errorText:this.errors.title,inputHandler:this.inputHandler,helpText:"Role at your business, e.g. President, CEO, Treasurer."})),s("div",{key:"2a011b74b4c203ae4a309d7d76ea8fd0631a5f2c",class:"col-12 col-md-6"},s("form-control-text",{key:"1ef20c59829ed3abe81cc53355bbafd5d4894360",name:"email",label:"Email Address",defaultValue:null===(i=this.representativeDefaultValue)||void 0===i?void 0:i.email,errorText:this.errors.email,inputHandler:this.inputHandler})),s("div",{key:"460dad175238fdfea8c79666343943a95aac0fd5",class:"col-12 col-md-6"},s("form-control-number-masked",{key:"7bd3ad79f6da1d33e38c2246d9c0378c2ef8b7d7",name:"phone",label:"Phone Number",defaultValue:null===(a=this.representativeDefaultValue)||void 0===a?void 0:a.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:R.US})),s("div",{key:"cda84bfc9f88a35177a42b7f9ec4c58292600c0b",class:"col-12 col-md-4"},s("form-control-date",{key:"5ed66fabc97afc94a5839135add25dbcb5237900",name:"dob_full",label:"Birth Date",defaultValue:null===(r=this.representativeDefaultValue)||void 0===r?void 0:r.dob_full,errorText:this.errors.dob_full,inputHandler:this.inputHandler,onFormControlInput:t=>_t(t,this.formController),helpText:"Must be 18 or older."})),s("div",{key:"0e19619fd081ea9dacd0eb25388a4c7b2c993312",class:"col-12 col-md-8"},!(null===(n=this.representativeDefaultValue)||void 0===n?void 0:n.ssn_last4)||this.isEditingIdentification?s("form-control-number-masked",{name:"identification_number",label:pt[this.country].idNumberLabel,defaultValue:this.isEditingIdentification?"":null===(o=this.representativeDefaultValue)||void 0===o?void 0:o.identification_number,errorText:this.errors.identification_number,inputHandler:this.inputHandler,mask:F[this.country],helpText:pt[this.country].identityHelpText}):s("div",null,s("label",{class:"form-label",part:U},pt[this.country].idNumberLabel),s("div",{class:"input-group mb-3"},s("input",{type:"text",class:"form-control",part:z,value:`****${null===(h=this.representativeDefaultValue)||void 0===h?void 0:h.ssn_last4}`,disabled:!0}),s("button",{class:"btn btn-secondary",type:"button",part:q,onClick:()=>{this.isEditingIdentification=!0,kt(this.formController,{identification_number:"",ssn_last4:null})}},"Change")))),s("div",{key:"6647390b209f5a630bf60e8952a7b0e70c92ca8a",class:"col-12"},s("identity-address-form",{key:"9755d0450fc8d83ba0a98a304455df346ff33e7f",errors:this.errors.address,defaultValues:null===(l=this.representativeDefaultValue)||void 0===l?void 0:l.address,handleFormUpdate:this.onAddressFormUpdate,country:this.country})))))}},Rt=class{constructor(s){t(this,s),this.errorEvent=e(this,"error-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.formLoading=e(this,"formLoading",7),this.errors={},this.representative={},this.isLoading=!1,this.getData=()=>{this.getBusiness&&this.formController&&(this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{this.representative=new P(t.data.representative||{}),this.representative.address.country=this.country,this.formController.setInitialValues(Object.assign({},this.representative))},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let e;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:s=>{e=s,t()},onError:({error:t,code:s,severity:i})=>{e=t,this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:e,formStep:at.representative}),this.formLoading.emit(!1)}})}}propChanged(){this.initializeApi(),this.getData()}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}componentWillLoad(){this.initializeApi(),this.initializeForm()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.patchBusiness=m({authToken:this.authToken,businessId:this.businessId,service:new g})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}initializeForm(){const t=C[this.country];t?(this.formController=new O(t("representative",this.allowOptionalFields)),this.getData()):this.errorEvent.emit({message:"Missing schema for selected country",errorCode:r.MISSING_PROPS,severity:a.ERROR})}componentDidLoad(){this.formController&&this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}get patchPayload(){return{representative:new P(this.formController.values.getValue()).payload}}render(){return!this.formController||this.isLoading?s(tt,null):s("business-representative-form-inputs",{representativeDefaultValue:this.formController.getInitialValues(),errors:this.errors,formController:this.formController,country:this.country})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},Ft=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.formCompleted=e(this,"formCompleted",7),this.errors={},this.fetchData=async()=>{this.formLoading.emit(!0);try{const t=await this.api.get({endpoint:this.businessEndpoint,authToken:this.authToken});this.acceptedTermsBefore=t.data.terms_conditions_accepted}catch(t){this.errorEvent.emit({errorCode:r.FETCH_ERROR,message:t.message,severity:a.ERROR,data:t})}finally{this.formLoading.emit(!1)}},this.sendData=async t=>{this.formLoading.emit(!0);try{const e=this.termsPayload,s=await this.api.post({endpoint:this.termsConditionsEndpoint,body:e,authToken:this.authToken});this.handleResponse(s,t)}catch(t){this.errorEvent.emit({errorCode:r.POST_ERROR,message:t.message,severity:a.ERROR,data:t})}finally{this.formLoading.emit(!1)}},this.inputHandler=(t,e)=>{this.acceptedTerms=e,this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}get businessEndpoint(){return`entities/business/${this.businessId}`}get termsConditionsEndpoint(){return"entities/terms_and_conditions"}get formHelperText(){return this.acceptedTermsBefore?"You have already accepted the terms and conditions.":null}get termsPayload(){return{business_id:this.businessId,accepted:this.formController.values.getValue().accepted,user_agent:window.navigator.userAgent}}async componentWillLoad(){this.api=Tt(),this.formController=new O((t=>{const e=A({accepted:D().oneOf([!0],"You must agree to the terms and conditions to continue").required("You must agree to the terms and conditions to continue")}),s=A({accepted:D().nullable()});return t?s:e})(this.allowOptionalFields)),this.businessId&&this.authToken&&this.fetchData()}handleResponse(t,e){t.error?this.errorEvent.emit({errorCode:r.POST_ERROR,message:t.error.message,severity:a.ERROR,data:t.error}):e(),this.stepCompleteEvent.emit({response:t,formStep:at.termsAndConditions}),this.formCompleted.emit()}async validateAndSubmit({onSuccess:t}){this.acceptedTermsBefore?(this.stepCompleteEvent.emit({response:null,formStep:at.termsAndConditions,metadata:"no data submitted"}),this.formCompleted.emit(),t()):this.formController.validateAndSubmit((()=>this.sendData(t)))}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}get merchantAgreementLink(){return s("a",{href:"https://justifi.tech/merchant-agreement/",target:"_blank",rel:"noopener noreferrer"},"merchant agreement")}render(){return s("form",{key:"24b0a8ff0187894cf5e0f56e9e4b28c378e720cb"},s("fieldset",{key:"26fa9159dd6d61edd28b9443a10eeb981f150308"},s("legend",{key:"103bdecbc51f2cccd9105e2f9b271b60760618ec",part:W},"Terms and Conditions"),s("hr",{key:"dfd29fbe609a57d8160df7980ed0e63e75934a86"}),s("div",{key:"61e06597ec652c1d7c6e7e2bd8c9b653d061d076"},s("p",{key:"cd4def71580cd14d6edb5887221ebf6aa80cc2ea"},"Please read and accept the ",this.merchantAgreementLink," to submit your provisioning request.")),s("br",{key:"e3c64733f11a4f702e686e6c5ae7acd7e6bd1c34"}),s("div",{key:"71bd74de3aee69805a2aa1297356ff8b8db3c76c",class:"row-gy-3"},s("div",{key:"94a28c13e3bbc1c89cd1b5ebde2e1732b48f99ea",class:"col-12"},s("form-control-checkbox",{key:"fee95fa42192fee1bbfd544307b4e1c11c0d97f4",name:"accepted",label:"I agree to the terms and conditions",inputHandler:this.inputHandler,errorText:this.errors.accepted,disabled:this.acceptedTermsBefore,helpText:this.formHelperText,checked:this.acceptedTerms})))))}},Wt=class{constructor(s){t(this,s),this.errorEvent=e(this,"error-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.formLoading=e(this,"formLoading",7),this.errors={},this.legal_address={},this.isLoading=!1,this.getData=()=>{this.getBusiness&&(this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:t=>{const e=new B((t.data||{}).legal_address||{});this.legal_address=Object.assign(Object.assign({},e),{country:this.country}),this.formController.setInitialValues(Object.assign({},this.legal_address))},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}}))},this.sendData=t=>{let e;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:s=>{e=s,t()},onError:({error:t,code:s,severity:i})=>{e=t,this.errorEvent.emit({message:t,errorCode:s,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:e,formStep:at.legalAddress}),this.formLoading.emit(!1)}})},this.inputHandler=(t,e)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:e}))}}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:t}){this.formController.validateAndSubmit((()=>this.sendData(t)))}get patchPayload(){return{legal_address:new B(this.formController.values.getValue()).payload}}componentWillLoad(){this.initializeApi(),this.formController=new O((0,j[this.country])(this.allowOptionalFields)),this.getData()}componentDidLoad(){this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=u({authToken:this.authToken,businessId:this.businessId,service:new g}),this.patchBusiness=m({authToken:this.authToken,businessId:this.businessId,service:new g})):this.errorEvent.emit({message:"Missing required props",errorCode:r.MISSING_PROPS,severity:a.ERROR})}render(){var t;const e=null===(t=this.formController)||void 0===t?void 0:t.getInitialValues();return this.isLoading?s(tt,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:W},"Legal Address of your Business"),s("form-control-tooltip",{helpText:"No PO Boxes."})),s("hr",{class:"mt-2"}),s("form-address-fields",{country:this.country,errors:this.errors,defaultValues:e,inputHandler:this.inputHandler})))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},qt=class{loadingWatcher(){this.formLoading.emit(this.isLoading)}constructor(s){t(this,s),this.clickEvent=e(this,"click-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.ownerSubmitted=e(this,"ownerSubmitted",7),this.isLoading=!1,this.errors={},this.owner={},this.getData=()=>{this.getOwner&&(this.isLoading=!0,this.getOwner({onSuccess:t=>{this.instantiateOwner(t.data)},onError:({error:t,code:e,severity:s})=>{this.errorEvent.emit({message:t,errorCode:e,severity:s})},final:()=>this.isLoading=!1}))},this.sendData=()=>(this.isLoading=!0,new Promise((t=>{this.ownerId?this.patchOwner({payload:this.payload,onSuccess:e=>{this.ownerSubmitted.emit({id:e.data.id}),this.instantiateOwner(e.data),t(!0)},onError:({error:e,code:s,severity:i})=>{this.errorEvent.emit({message:e,errorCode:s,severity:i}),t(!1)},final:()=>this.isLoading=!1}):this.postOwner({payload:this.payload,onSuccess:e=>{this.ownerSubmitted.emit({id:e.data.id}),this.instantiateOwner(e.data),t(!0)},onError:({error:e,code:s,severity:i})=>{this.errorEvent.emit({message:e,errorCode:s,severity:i}),t(!1)},final:()=>this.isLoading=!1})}))),this.instantiateOwner=async t=>{this.owner=Object.assign({},new N(t)),await this.formController.setInitialValues(this.owner)},this.handleAddOwner=()=>{this.clickEvent.emit({name:this.ownerId?rt.updateOwner:rt.addOwner})},this.handleRemoveOwner=()=>{this.removeOwner(this.ownerId),this.clickEvent.emit({name:rt.removeOwner})},this.validate=this.validate.bind(this),this.submit=this.submit.bind(this),this.validateAndSubmit=this.validateAndSubmit.bind(this)}async returnOwnerData(){return this.ownerId}async validate(){return this.formController.validate()}async submit(){if(await this.validate())return this.sendData()}async validateAndSubmit(t){t.preventDefault(),await this.validate()&&this.submit()}get payload(){const t=new N(this.formController.values.getValue()).payload;return this.ownerId?t:Object.assign(Object.assign({},t),{business_id:this.businessId})}get formTitle(){return this.ownerId?"Edit Business Owner":"Add Business Owner"}get submitButtonText(){return this.ownerId?"Update":"Add"}get showRemoveButton(){return!(this.ownersLength<=1)&&(!(this.ownerId||!this.newFormOpen)||!(!this.ownerId||this.newFormOpen)||void 0)}componentWillLoad(){this.formController=new O((0,C[this.country])("owner",this.allowOptionalFields)),this.initializeApi(),this.ownerId&&this.getOwner?this.getData():this.instantiateOwner({})}componentDidLoad(){this.formController.errors.subscribe((t=>this.errors=Object.assign({},t)))}initializeApi(){this.authToken&&(this.getOwner=f({authToken:this.authToken,identityId:this.ownerId,service:new _}),this.patchOwner=v({authToken:this.authToken,identityId:this.ownerId,service:new _}),this.postOwner=y({authToken:this.authToken,service:new _}))}render(){return s(i,{key:"1661676befd63f9308edcb02be179db71b7c9d99",style:{display:"block"}},s("form",{key:"4961f358ca8953156477d455cacb19e4dec3cc29",onSubmit:this.validateAndSubmit},s("fieldset",{key:"27ecfec87ae93a1bdec94f3cc925558dc8f0ff23"},s("legend",{key:"4c194cf9e08e6fab9982b95a4b12c3c3a8cecdc3",class:"fw-semibold fs-5",part:J},this.formTitle),s("br",{key:"ef1f9b184dac866d27cfa245106d90db0954fa51"}),s("div",{key:"2936ecc396220f8b80e5d8454bc6f6f70cb3ae73",class:"row gy-3"},s("owner-form-inputs",{key:"f34d38b718ed7fde67102aa1034b5e6377e001f8",ownerDefaultValue:this.formController.getInitialValues(),errors:this.errors,formController:this.formController,country:this.country}),s("div",{key:"2d5266bc1a7f4aeb12cab8a494107f2668b2fb0e",class:"d-flex gap-2 justify-content-start"},s(bt,{key:"39631fd0364221ac2a274d8aa794a1f3c8d28780",variant:"secondary",type:"button",onClick:this.handleRemoveOwner,hidden:!this.showRemoveButton},"Remove"),s(bt,{key:"120fbae294f8f67bd14fe0be5dc1bcf881ffd489",variant:"primary",type:"submit",onClick:this.handleAddOwner,disabled:this.isLoading},this.submitButtonText))),s("hr",{key:"73eccba19a595b67f64139769a495d5a27e02b2f"}))))}static get watchers(){return{isLoading:["loadingWatcher"]}}},Zt=class{constructor(s){t(this,s),this.plaidVerificationSuccess=e(this,"plaidVerificationSuccess",7),this.plaidVerificationError=e(this,"plaidVerificationError",7),this.linkToken=null,this.linkTokenId=null,this.plaidLink=null,this.isAuthenticating=!1,this.isSuccess=!1,this.error=null,this.isLoading=!1,this.plaidService=new Lt,this.abortController=null,this.timeoutId=null,this.initializePlaidLink=async()=>{try{if(void 0===window.Plaid)return void this.handleError({code:d.PLAID_SDK_LOAD_FAILED,message:c[d.PLAID_SDK_LOAD_FAILED],severity:l[d.PLAID_SDK_LOAD_FAILED],retryable:!0,userAction:"Refresh the page and try again"});if(await this.getLinkToken(),!this.linkToken)return void this.handleError({code:d.PLAID_LINK_TOKEN_FAILED,message:c[d.PLAID_LINK_TOKEN_FAILED],severity:l[d.PLAID_LINK_TOKEN_FAILED],retryable:!0,userAction:"Click to try again"});const t=window.Plaid;this.plaidLink=t.create({token:this.linkToken,onSuccess:this.handlePlaidSuccess,onExit:this.handlePlaidExit,onEvent:this.handlePlaidEvent,onLoad:this.handlePlaidLoad})}catch(t){this.handleError({code:d.PLAID_LINK_INIT_FAILED,message:c[d.PLAID_LINK_INIT_FAILED],severity:l[d.PLAID_LINK_INIT_FAILED],originalError:t,retryable:!0,userAction:"Click to try again"})}},this.getLinkToken=async()=>{var t,e,s,i;try{if(!this.authToken||!this.accountId)return void this.handleError({code:d.PLAID_LINK_TOKEN_FAILED,message:"Missing authentication. Please provide authToken and accountId.",severity:a.ERROR,retryable:!1,userAction:"Provide required props"});this.abortController=new AbortController,this.timeoutId=setTimeout((()=>{var t;null===(t=this.abortController)||void 0===t||t.abort()}),3e4);const t=await this.plaidService.getLinkTokenForVerification(this.authToken,this.businessId,this.abortController.signal);if(this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null),t.error)throw new Error("string"==typeof t.error?t.error:t.error.message||"Failed to get link token");this.linkToken=t.data.link_token,this.linkTokenId=t.data.id}catch(a){this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null);let r=d.PLAID_LINK_TOKEN_FAILED,n=c[r],o=!0;"AbortError"===a.name?(r=d.PLAID_TIMEOUT,n=c[r],o=!0):(null===(t=a.message)||void 0===t?void 0:t.includes("network"))||(null===(e=a.message)||void 0===e?void 0:e.includes("fetch"))?(r=d.PLAID_NETWORK_ERROR,n=c[r],o=!0):((null===(s=a.message)||void 0===s?void 0:s.includes("401"))||(null===(i=a.message)||void 0===i?void 0:i.includes("unauthorized")))&&(r=d.PLAID_INVALID_CREDENTIALS,n="Authentication failed. Please check your credentials.",o=!1),this.handleError({code:r,message:n,severity:l[r],originalError:a,retryable:o,userAction:o?"Click to try again":"Check your credentials"})}},this.openPlaidLink=()=>{this.plaidLink&&this.linkToken&&(this.isAuthenticating=!0,this.clearError(),this.plaidLink.open())},this.handlePlaidSuccess=async t=>{var e;this.isAuthenticating=!1,this.isLoading=!0,this.clearError();try{const s=await this.plaidService.postPlaidVerifiedBankAccountData(this.authToken,this.businessId,{public_token:t,link_token_id:this.linkTokenId},null===(e=this.abortController)||void 0===e?void 0:e.signal);if(s.error)throw new Error("string"==typeof s.error?s.error:s.error.message||"Failed to verify bank account");this.isSuccess=!0,this.isLoading=!1,this.plaidVerificationSuccess.emit({publicToken:t,bankAccount:s.data})}catch(t){this.isLoading=!1,this.handleError({code:d.PLAID_AUTHENTICATION_FAILED,message:(null==t?void 0:t.message)||"Failed to verify bank account",severity:l[d.PLAID_AUTHENTICATION_FAILED],originalError:t,retryable:!0,userAction:"Click to try again"})}},this.handlePlaidExit=t=>{this.isAuthenticating=!1,t&&this.handlePlaidError(t)},this.handlePlaidEvent=(t,e)=>{switch(t){case"OPEN":this.isAuthenticating=!0;break;case"CLOSE":this.isAuthenticating=!1;break;case"ERROR":this.handlePlaidError(e)}},this.handlePlaidLoad=()=>{},this.handlePlaidError=t=>{let e=d.PLAID_AUTHENTICATION_FAILED,s=c[e],i=!0,a="Click to try again";if(t.error_code)switch(t.error_code){case"INVALID_CREDENTIALS":e=d.PLAID_INVALID_CREDENTIALS,s=c[e],i=!0;break;case"ITEM_LOGIN_REQUIRED":e=d.PLAID_INVALID_CREDENTIALS,s="Your bank requires re-authentication. Please try again.",i=!0;break;case"ITEM_LOCKED":e=d.PLAID_ACCOUNT_LOCKED,s=c[e],i=!1,a="Contact your bank";break;case"INSTITUTION_NOT_RESPONDING":e=d.PLAID_MAINTENANCE,s=c[e],i=!0;break;case"RATE_LIMIT_EXCEEDED":e=d.PLAID_RATE_LIMITED,s=c[e],i=!0;break;default:t.error_message&&(s=t.error_message)}this.handleError({code:e,message:s,severity:l[e],originalError:t,retryable:i,userAction:a}),this.isAuthenticating=!1},this.handleError=t=>{this.error=t,this.isLoading=!1,this.plaidVerificationError.emit(t),console.error("Plaid verification error:",t)},this.clearError=()=>{this.error&&(this.error=null)}}componentDidRender(){this.scriptRef&&(this.scriptRef.onload=()=>{this.initializePlaidLink()},this.scriptRef.onerror=()=>{this.handleError({code:d.PLAID_SDK_LOAD_FAILED,message:c[d.PLAID_SDK_LOAD_FAILED],severity:l[d.PLAID_SDK_LOAD_FAILED],retryable:!0,userAction:"Refresh the page and try again"})})}disconnectedCallback(){this.timeoutId&&clearTimeout(this.timeoutId),this.abortController&&this.abortController.abort()}render(){const t=s("svg",{class:"plaid-logo-img",height:"20",width:"20",viewBox:"0 0 28 29",xmlns:"http://www.w3.org/2000/svg",style:{display:"inline",marginLeft:"5px",marginRight:"5px",marginTop:"-2px"}},s("g",{fill:"#fff","fill-rule":"evenodd"},s("path",{d:"M25.7629 26.2628L28 17.5309L24.9691 14.5001L27.9999 11.4691L25.7628 2.73706L17.0309 0.5L14.0001 3.531L10.969 0.50014L2.23706 2.73734L0 11.4691L3.03128 14.4999L0.00014 17.531L2.2372 26.2629L10.9691 28.5L14.0001 25.469L17.031 28.4999L25.7629 26.2628ZM15.7321 23.7371L18.6186 20.8505L22.2912 24.5233L17.6956 25.7007L15.7321 23.7371ZM11.1136 9.88154L14.0003 6.99502L16.8868 9.8814L14.0001 12.7679L11.1136 9.88154ZM12.2682 14.5L9.38154 17.3865L6.49502 14.5L9.38154 11.6135L12.2682 14.5ZM18.6187 11.6133L21.5053 14.5L18.6186 17.3865L15.7321 14.5L18.6187 11.6133ZM16.8867 19.1186L14.0001 22.0051L11.1135 19.1185L14.0001 16.2319L16.8867 19.1186ZM10.3044 25.7007L5.70864 24.5233L9.38154 20.8504L12.2682 23.7371L10.3044 25.7007ZM4.76308 16.2319L7.6496 19.1185L3.9767 22.7914L2.7993 18.1957L4.76308 16.2319ZM3.9767 6.20836L7.64974 9.8814L4.76308 12.7681L2.7993 10.8041L3.9767 6.20836ZM12.2683 5.26294L9.38168 8.1496L5.70892 4.4767L10.3047 3.2993L12.2683 5.26294ZM17.6959 3.2993L22.2915 4.4767L18.6186 8.14946L15.7321 5.26294L17.6959 3.2993ZM23.2372 12.7681L20.3505 9.8814L24.0233 6.20878L25.2007 10.8046L23.2372 12.7681ZM24.0233 22.7914L20.3505 19.1186L23.2372 16.2321L25.2007 18.1957L24.0233 22.7914Z"})));return s(xt,null,s("script",{src:"https://cdn.plaid.com/link/v2/stable/link-initialize.js",async:!0,ref:t=>this.scriptRef=t}),s("div",null,s("div",{class:"mb-3"},s(bt,{variant:"primary",type:"button",onClick:t=>{t.preventDefault(),this.openPlaidLink()},disabled:this.isLoading,part:Q},"Connect with Plaid ",t," (instant verification)")),(()=>this.error?s("div",{class:(this.error.severity===a.ERROR?"text-danger":this.error.severity===a.WARNING?"text-warning":"text-info")+" mt-2"},s("small",null,this.error.message),s("br",null),this.error.userAction&&s("small",{class:"text-muted"},this.error.userAction)):null)(),(()=>this.error?null:this.isLoading?s("div",{class:"text-info mt-2"},s("small",null,"Verifying bank account...")):this.isSuccess?s("div",{class:"text-success mt-2"},s("small",null,"✓ Bank account verified successfully")):this.isAuthenticating?s("div",{class:"text-info mt-2"},s("small",null,"Connecting to your bank...")):null)()))}};export{jt as additional_questions_form_step,Ot as bank_account_document_form_inputs,At as bank_account_form_inputs,Et as bank_account_form_inputs_canada,It as business_bank_account_form_step,Pt as business_core_info_form_step,Bt as business_documents_on_file,Nt as business_owners_form_step,Mt as business_representative_form_inputs,Rt as business_representative_form_step,Ft as business_terms_conditions_form_step,Wt as legal_address_form_step,qt as owner_form,Zt as plaid_verification}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t,r as s,c as e}from"./p-CV0Pyo1O.js";import{i as a,C as i,e as o}from"./p-NZS8uCtH.js";import{J as r}from"./p-Cz_7BuGW.js";import{c as h}from"./p-mF5zKtkx.js";import{P as c}from"./p-Dk26hk5T.js";import"./p-DVJaoI_m.js";import"./p-HXpYMWUU.js";import{p as n}from"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{g as p,a as d}from"./p-Cm9f5fyh.js";import{M as u,m}from"./p-BXyADlAH.js";import{m as l,S as f}from"./p-BxKbnILQ.js";import{S as y}from"./p-BqNNwq6C.js";import{T as b,a as v,b as g,c as C,d as j,e as _,f as k,g as w,h as S,i as T,j as P,k as A,l as O}from"./p-BICxxa69.js";import{T as I}from"./p-CZfYo5-1.js";import{a as D}from"./p-BRnBHsdq.js";import{a6 as B,a7 as V}from"./p-CPKMvyV_.js";import{o as x,g as E}from"./p-AMVhBsGv.js";import"./p-OGt0dCJl.js";import"./p-CYQvLgSs.js";import"./p-D8GTwl9v.js";import"./p-CHw7tICr.js";import"./p-CqiVXthx.js";const G={created_at:()=>t("th",{part:B,scope:"col",title:"The date the payout was deposited"},"Created"),sub_account_name:()=>t("th",{part:B,scope:"col",title:"The sub account associated with the payout"},"Sub Account"),payments_total:()=>t("th",{part:B,scope:"col",title:"The total payments amount associated with the payout"},"Payments"),refunds_total:()=>t("th",{part:B,scope:"col",title:"The total refunds amount associated with the payout"},"Refunds"),fees_total:()=>t("th",{part:B,scope:"col",title:"The total fees amount associated with the payout"},"Fees"),other_total:()=>t("th",{part:B,scope:"col",title:"The total other amount"},"Other"),amount:()=>t("th",{part:B,scope:"col",title:"The total amount of the payout"},"Amount"),status:()=>t("th",{part:B,scope:"col",title:"The real-time status of each payout"},"Status"),csv:()=>t("th",{part:B,scope:"col",title:"Export CSV"})},H=class{constructor(t){s(this,t),this.errorEvent=e(this,"error-event",7),this.clickEvent=e(this,"click-event",7),this.errorMessage=null,this.payouts=[],this.subAccounts=[],this.loading=!0,this.paging=n,this.pagingParams={},this.columns="created_at,amount,status,payments_total,refunds_total,fees_total,other_total,csv",this.downloadCSV=t=>{this.getPayoutCSV({payoutId:t,onError:()=>{this.errorEvent.emit({errorCode:o.FETCH_ERROR,message:"Failed to download CSV",severity:i.ERROR})}})},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:I.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:I.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 a=this.payouts.find((t=>t.id===e));this.clickEvent.emit({name:I.row,data:a})}}componentWillLoad(){var s;h(),this.analytics=new r(this),this.initializeGetData(),this.payoutsTable=new b(this.payouts,this.columns,G,(s=this.downloadCSV,{created_at:(s,e)=>t("td",{part:V(e)},t("div",{class:"fw-bold"},D(s.created_at,{showDisplayDate:!0}))),sub_account_name:(s,e)=>t("td",{part:V(e)},s.sub_account_name),payments_total:(s,e)=>t("td",{part:V(e)},s.formattedPaymentAmount(s.payments_total)),refunds_total:(s,e)=>t("td",{part:V(e)},s.formattedPaymentAmount(s.refunds_total)),fees_total:(s,e)=>t("td",{part:V(e)},s.formattedPaymentAmount(s.fees_total)),other_total:(s,e)=>t("td",{part:V(e)},s.formattedPaymentAmount(s.other_total)),amount:(s,e)=>t("td",{part:V(e)},s.formattedPaymentAmount(s.amount)),status:(s,e)=>t("td",{part:V(e)},u(s.status)),csv:(e,a)=>t("td",{part:V(a)},t("a",{href:"#",onClick:t=>{t.preventDefault(),s(e.id)}},"CSV"))})),this.getPayouts&&this.getSubAccounts&&this.fetchData(),x("set",(()=>{this.pagingParams={}})),x("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetData()}updateOnPropChange(){this.fetchData()}initializeGetData(){this.initializePayoutsServices(),this.initializeGetSubAccounts()}initializePayoutsServices(){if(this.accountId&&this.authToken){const t={id:this.accountId,authToken:this.authToken,service:new c};this.getPayouts=(({id:t,authToken:s,service:e})=>async({params:o,onSuccess:r,onError:h})=>{var c,n;try{const u=await e.fetchPayouts(t,s,o);if(u.error)return h({error:d(u.error),code:p(null===(n=u.error)||void 0===n?void 0:n.code),severity:i.ERROR});{const t=Object.assign({},u.page_info);r({payouts:(null===(c=u.data)||void 0===c?void 0:c.map((t=>new a(t))))||[],pagingInfo:t})}}catch(t){const s=p(null==t?void 0:t.code);return h({error:t.message||t,code:s,severity:i.ERROR})}})(t),this.getPayoutCSV=m(t)}else this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:this.errorMessage,severity:i.ERROR})}initializeGetSubAccounts(){this.accountId&&this.authToken&&(this.getSubAccounts=l({primaryAccountId:this.accountId,authToken:this.authToken,service:new f}))}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=E();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 t(y,{key:"679d6c6e77a02a30223a98d2acc5904866d19f80"},t(v,{key:"9e26d69955fd836451c6468946d7fa512ad84fde"},t(g,{key:"a73a478f2c40d1b95c5a8bc7039496a2caa4bd40"},t(C,{key:"369b1f0a4827fed6ff8f0c6f030bbe54843e1356"},t(j,{key:"c4be14ee6c9401e8a5e6e3318c7e2754f2457151"},this.payoutsTable.columnData.map((t=>t)))),t(_,{key:"5401abd534d1035ffc5177bb091cb63628e250de"},t(k,{key:"386a988c540a87dea5f6574f0e073ed26607c528",columnSpan:this.payoutsTable.columnKeys.length,isLoading:this.loading}),t(w,{key:"6855b88d7ca2e75f39aee058de13f56fd81f1811",isEmpty:this.showEmptyState,columnSpan:this.payoutsTable.columnKeys.length}),t(S,{key:"186e8f3a48b5362a07b88192617d88d466ae11c2",columnSpan:this.payoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.payoutsTable.rowData.map(((s,e)=>t(T,{"data-test-id":"table-row","data-row-entity-id":this.entityId[e],onClick:this.rowClickHandler},s)))),this.paging&&t(P,{key:"ad5e63f894c990d5b87a5d39e4164d4248bc7b1a"},t(A,{key:"57cab389b166b282bbf6506d08a368f0cc4c750b"},t(O,{key:"8f8893d6f3ffe796ebe77fb33e1e0f6a3f364408",colSpan:this.payoutsTable.columnData.length},t("pagination-menu",{key:"640555ff74d52f27b06d3588f411e235b23436ad",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})})))))))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"],pagingParams:["updateOnPropChange"],getPayouts:["updateOnPropChange"],getSubAccounts:["updateOnPropChange"]}}};export{H as justifi_payouts_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as i,H as e,g as o}from"./p-CV0Pyo1O.js";import{w as a,x as r,q as h,u as f,v as c}from"./p-CPKMvyV_.js";import{F as l}from"./p-Ce_W43gc.js";import"./p-CZfYo5-1.js";const d=class{constructor(i){t(this,i),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.fileSelected=s(this,"fileSelected",7),this.isFocused=!1,this.errorText="",this.inputHandler=()=>{},this.disabled=!1,this.handleFormControlInput=t=>{const s=t.target,i=s.getAttribute("name");this.inputHandler(i,s.value),this.formControlInput.emit({name:i,value:s.value})},this.changeHandler=()=>{const t=this.fileInput.files;t&&this.fileSelected.emit({fileList:t,document_type:this.documentType})}}componentDidLoad(){this.fileInput=this.el.querySelector("input")}get part(){let t=a;return this.errorText&&(t=h),this.disabled&&(t=f),this.isFocused&&(t=c),t}render(){return i(e,{key:"1f5c8bdc73c664cf40acb4f5b61db454bbda36a0"},i("div",{key:"77f0007875132d26dd8df91dfb53386da9e15ce4",class:"form-group d-flex flex-column"},i("div",{key:"a6885165580120dbaffaedf60edf2e2cc9883a9f",class:"d-flex align-items-start gap-2"},i("label",{key:"489b6d49a60f8339722537084f64746e5625297d",part:r,class:"form-label",htmlFor:this.name},this.label),i("form-control-tooltip",{key:"fc581e32bfb8935e79648c0a670bcb26bf225fe4",helpText:this.helpText})),i("input",{key:"34ddfe0796848feadcd6249ed861c5fa623840d4",ref:t=>this.fileInput=t,type:"file",name:this.name,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",multiple:this.multiple,disabled:this.disabled,onChange:this.changeHandler,onInput:this.handleFormControlInput,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()}}),i(l,{key:"4a0c1869b8b19a01273d8f1ca3f3cd92134ddb58",errorText:this.errorText,name:this.name})))}get el(){return o(this)}};export{d as form_control_file}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{A as t}from"./p-CYQvLgSs.js";import"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const e=t();class o{async fetchCheckout(t,o){return e.get({endpoint:`checkouts/${o}`,authToken:t})}async fetchCheckouts(t,o,c){return e.get({endpoint:"checkouts",params:c,headers:{Account:t},authToken:o})}async complete(t,o,c){const s=`checkouts/${o}/complete`,n={payment_mode:c.payment_mode};return c.payment_token&&(n.payment_token=c.payment_token),e.post({endpoint:s,body:n,authToken:t})}}export{o as C}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as o}from"./p-CV0Pyo1O.js";import{h as r}from"./p-CPKMvyV_.js";const s=s=>o("h1",{class:`header-1 ${null==s?void 0:s.class}`,part:r},s.text);export{s as H}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e}from"./p-
|
|
1
|
+
import{p as e}from"./p-OGt0dCJl.js";const s="__JUSTIFI_WC_VERSION__",o=async()=>{var o,t;if((()=>{if("undefined"==typeof globalThis)return;const o=e.version,t=globalThis[s];t&&t!==o?console.error(`@justifi/webcomponents: Multiple versions detected. Version ${t} was loaded first and registered all components. Version ${o} is also present but its components will NOT be used. To fix this, add to your package.json:\n"pnpm": { "overrides": { "@justifi/webcomponents": "${o}" } }`):globalThis[s]=o})(),"undefined"!=typeof process&&("test"===(null===(o=process.env)||void 0===o?void 0:o.NODE_ENV)||(null===(t=process.env)||void 0===t?void 0:t.JEST_WORKER_ID)))return;const i=e.version,n=e.name,a=await(async e=>{const s=await fetch("https://registry.npmjs.org/"+e+"/latest");return(await s.json()).version})(n),r=a.replace(/-rc.*/,""),l=i.split("."),p=a.split(".");l[0]!==p[0]&&console.warn(`The package ${n} is out of date. The latest version is ${r}. Please update.`)};export{o as c}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{A as t}from"./p-CYQvLgSs.js";import"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const n=t();class a{async fetchPayments(t,a,s){return n.get({endpoint:`account/${t}/payments`,params:s,authToken:a})}async fetchPayment(t,a){return n.get({endpoint:`payments/${t}`,authToken:a})}async fetchPaymentTransactions(t,a,s){return n.get({endpoint:`payments/${t}/payment_balance_transactions`,params:s,authToken:a})}}export{a as P}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{A as e}from"./p-CYQvLgSs.js";import"./p-NZS8uCtH.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const t=e();class s{async fetchDispute(e,s){return t.get({endpoint:`disputes/${e}`,authToken:s})}async updateDisputeResponse(e,s,n){return t.patch({endpoint:`disputes/${e}/response`,body:n,authToken:s})}async submitDisputeResponse(e,s,n){return t.post({endpoint:`disputes/${e}/response`,body:n,authToken:s})}async createDisputeEvidence(e,s,n){return t.put({endpoint:`disputes/${e}/evidence`,body:n,authToken:s})}}var n,i;!function(e){e.nextStep="nextStep",e.previousStep="previousStep",e.cancelDispute="cancelDispute",e.respondToDispute="respondToDispute",e.submit="submit"}(n||(n={})),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"}(i||(i={}));export{n as D,s as a}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t}from"./p-CV0Pyo1O.js";import{s}from"./p-CPKMvyV_.js";const e=({component:e="div",height:o,width:r,className:i,styles:a={}})=>{const c=Object.assign(Object.assign({},a),{width:r,height:o});return t(e,{class:`${i} skeleton`,style:c,part:s,"aria-hidden":"true"})};export{e as S}
|