@justifi/webcomponents 4.10.0 → 4.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Business-663db337.js → Business-7ae04d4f.js} +46 -1
- package/dist/cjs/business-additional-questions-schema-18a82d19.js +47 -0
- package/dist/cjs/business-details-core.cjs.entry.js +7 -2
- package/dist/cjs/{business-form-types-3cdd5447.js → business-form-types-29b2bad9.js} +7 -0
- package/dist/cjs/{form-control-datepart_3.cjs.entry.js → form-control-datepart_4.cjs.entry.js} +59 -12
- package/dist/cjs/{form-control-number_3.cjs.entry.js → form-control-select_2.cjs.entry.js} +3 -45
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +7 -1
- package/dist/cjs/justifi-additional-questions-form-step_5.cjs.entry.js +24 -20
- package/dist/cjs/justifi-additional-questions_4.cjs.entry.js +6 -8
- package/dist/cjs/justifi-billing-form_4.cjs.entry.js +1 -1
- package/dist/cjs/justifi-business-details.cjs.entry.js +21 -4
- package/dist/cjs/justifi-business-form.cjs.entry.js +60 -51
- package/dist/cjs/justifi-business-list.cjs.entry.js +1 -1
- package/dist/cjs/justifi-checkout.cjs.entry.js +1 -1
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +29 -5
- package/dist/cjs/justifi-owner-form.cjs.entry.js +20 -12
- package/dist/cjs/justifi-payment-details.cjs.entry.js +25 -4
- package/dist/cjs/justifi-payment-form.cjs.entry.js +16 -3
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +16 -16
- package/dist/cjs/justifi-payments-list.cjs.entry.js +25 -5
- package/dist/cjs/justifi-payout-details.cjs.entry.js +27 -7
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +26 -6
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/payload-parsers-f437272e.js +132 -0
- package/dist/cjs/payment-details-core.cjs.entry.js +7 -1
- package/dist/cjs/payments-list-core.cjs.entry.js +8 -2
- package/dist/cjs/payout-details-core.cjs.entry.js +8 -3
- package/dist/cjs/payouts-list-core.cjs.entry.js +8 -2
- package/dist/cjs/{utils-df5167a8.js → utils-87435719.js} +7 -0
- package/dist/cjs/utils-f8079741.js +41 -0
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/api/Business.js +2 -1
- package/dist/collection/api/ComponentError.js +14 -0
- package/dist/collection/api/services/utils.js +11 -0
- package/dist/collection/api/shared.js +11 -1
- package/dist/collection/collection-manifest.json +1 -2
- package/dist/collection/components/business-details/additional-questions-details/test/additional-questions.spec.js +1 -1
- package/dist/collection/components/business-details/business-details-core.js +30 -2
- package/dist/collection/components/business-details/business-details.js +30 -0
- package/dist/collection/components/business-details/generic-info-details/test/generic-info-details.spec.js +1 -1
- package/dist/collection/components/business-details/get-business.js +15 -3
- package/dist/collection/components/business-details/legal-address-details/test/legal-address-details.spec.js +1 -1
- package/dist/collection/components/business-details/owner-details/test/owner-details.spec.js +1 -1
- package/dist/collection/components/business-details/representative-details/test/representative-details.spec.js +1 -1
- package/dist/collection/components/business-details/test/busines-details-core.spec.js +56 -16
- package/dist/collection/components/business-details/test/business-details.spec.js +20 -4
- package/dist/collection/components/business-details/test/get-business.spec.js +13 -6
- package/dist/collection/components/business-forms/business-form/business-form.js +79 -50
- package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +1 -4
- package/dist/collection/components/business-forms/business-form/legal-address-form/legal-address-form.js +4 -2
- package/dist/collection/components/business-forms/{business-form/business-address/business-address-form.js → owner-form/identity-address/identity-address-form.js} +13 -10
- package/dist/collection/components/business-forms/owner-form/identity-address/test/identity-address.e2e.js +9 -0
- package/dist/collection/components/business-forms/{business-form/business-address/test/business-address.spec.js → owner-form/identity-address/test/identity-address.spec.js} +21 -14
- package/dist/collection/components/business-forms/owner-form/owner-form.js +54 -8
- package/dist/collection/components/business-forms/payment-provisioning/additional-questions/business-additional-questions-form-step.js +20 -2
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +19 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +44 -4
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +21 -6
- package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +23 -4
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning.js +32 -14
- package/dist/collection/components/business-forms/schemas/business-additional-questions-schema.js +15 -6
- package/dist/collection/components/business-forms/schemas/business-address-schema.js +47 -12
- package/dist/collection/components/business-forms/schemas/business-core-info-schema.js +24 -12
- package/dist/collection/components/business-forms/schemas/business-form-schema.js +4 -4
- package/dist/collection/components/business-forms/schemas/business-identity-schema.js +29 -34
- package/dist/collection/components/business-forms/utils/business-form-types.js +7 -0
- package/dist/collection/components/business-forms/utils/helpers.js +2 -0
- package/dist/collection/components/form/form-control-text.js +35 -1
- package/dist/collection/components/form/utils.js +6 -0
- package/dist/collection/components/gross-payment-chart/get-gross-payment-chart-data.js +17 -2
- package/dist/collection/components/gross-payment-chart/gross-payment-chart-core.js +30 -1
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.js +35 -1
- package/dist/collection/components/gross-payment-chart/test/get-gross-payment-chart-data.spec.js +26 -8
- package/dist/collection/components/gross-payment-chart/test/gross-payment-chart-core.spec.js +51 -11
- package/dist/collection/components/gross-payment-chart/test/gross-payment-chart.spec.js +55 -3
- package/dist/collection/components/payment-details/get-payment-details.js +15 -3
- package/dist/collection/components/payment-details/payment-details-core.js +30 -1
- package/dist/collection/components/payment-details/payment-details.js +35 -1
- package/dist/collection/components/payment-details/test/get-payment-details.spec.js +11 -3
- package/dist/collection/components/payment-details/test/payment-details-core.spec.js +55 -12
- package/dist/collection/components/payment-details/test/payment-details.spec.js +69 -3
- package/dist/collection/components/payment-form/payment-form.js +54 -3
- package/dist/collection/components/payment-form/test/payment-form.spec.js +60 -1
- package/dist/collection/components/payments-list/get-payments.js +15 -4
- package/dist/collection/components/payments-list/payments-list-core.js +28 -2
- package/dist/collection/components/payments-list/payments-list.js +35 -1
- package/dist/collection/components/payments-list/test/get-payments.spec.js +11 -3
- package/dist/collection/components/payments-list/test/payments-list-core.spec.js +43 -28
- package/dist/collection/components/payments-list/test/payments-list.spec.js +31 -3
- package/dist/collection/components/payout-details/get-payout-details.js +17 -6
- package/dist/collection/components/payout-details/payout-details-core.js +31 -3
- package/dist/collection/components/payout-details/payout-details.js +35 -1
- package/dist/collection/components/payout-details/test/get-payout-details.spec.js +15 -5
- package/dist/collection/components/payout-details/test/payout-details-core.spec.js +54 -16
- package/dist/collection/components/payout-details/test/payout-details.spec.js +50 -1
- package/dist/collection/components/payouts-list/get-payouts.js +17 -5
- package/dist/collection/components/payouts-list/payouts-list-core.js +28 -2
- package/dist/collection/components/payouts-list/payouts-list.js +34 -1
- package/dist/collection/components/payouts-list/test/get-payouts.spec.js +11 -3
- package/dist/collection/components/payouts-list/test/payouts-list-core.spec.js +42 -29
- package/dist/collection/components/payouts-list/test/payouts-list.spec.js +33 -0
- package/dist/docs.json +753 -354
- package/dist/esm/{Business-6cc4e473.js → Business-91caaccb.js} +45 -2
- package/dist/esm/business-additional-questions-schema-b642a2b7.js +44 -0
- package/dist/esm/business-details-core.entry.js +8 -3
- package/dist/esm/{business-form-types-de9f38cd.js → business-form-types-0d76133c.js} +8 -1
- package/dist/esm/{form-control-datepart_3.entry.js → form-control-datepart_4.entry.js} +59 -13
- package/dist/esm/{form-control-number_3.entry.js → form-control-select_2.entry.js} +4 -45
- package/dist/esm/gross-payment-chart-core.entry.js +8 -2
- package/dist/esm/justifi-additional-questions-form-step_5.entry.js +22 -18
- package/dist/esm/justifi-additional-questions_4.entry.js +6 -8
- package/dist/esm/justifi-billing-form_4.entry.js +1 -1
- package/dist/esm/justifi-business-details.entry.js +22 -5
- package/dist/esm/justifi-business-form.entry.js +60 -51
- package/dist/esm/justifi-business-list.entry.js +1 -1
- package/dist/esm/justifi-checkout.entry.js +1 -1
- package/dist/esm/justifi-gross-payment-chart.entry.js +28 -4
- package/dist/esm/justifi-owner-form.entry.js +19 -11
- package/dist/esm/justifi-payment-details.entry.js +26 -5
- package/dist/esm/justifi-payment-form.entry.js +16 -3
- package/dist/esm/justifi-payment-provisioning.entry.js +16 -16
- package/dist/esm/justifi-payments-list.entry.js +26 -6
- package/dist/esm/justifi-payout-details.entry.js +28 -8
- package/dist/esm/justifi-payouts-list.entry.js +27 -7
- package/dist/esm/loader.js +1 -1
- package/dist/esm/payload-parsers-920f49dd.js +123 -0
- package/dist/esm/payment-details-core.entry.js +8 -2
- package/dist/esm/payments-list-core.entry.js +8 -2
- package/dist/esm/payout-details-core.entry.js +9 -4
- package/dist/esm/payouts-list-core.entry.js +8 -2
- package/dist/esm/utils-4609f32c.js +38 -0
- package/dist/esm/{utils-2828201a.js → utils-684d2e47.js} +7 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/module/Business.js +45 -2
- package/dist/module/business-additional-questions-form-step.js +4 -2
- package/dist/module/business-additional-questions-schema.js +16 -7
- package/dist/module/business-address-schema.js +49 -14
- package/dist/module/business-core-info-form-step.js +3 -1
- package/dist/module/business-core-info-schema.js +24 -12
- package/dist/module/business-details-core2.js +8 -3
- package/dist/module/business-form-types.js +8 -1
- package/dist/module/business-identity-schema.js +30 -35
- package/dist/module/business-owners-form-step.js +12 -8
- package/dist/module/business-representative-form-step.js +9 -10
- package/dist/module/business-representative.js +4 -7
- package/dist/module/form-control-text2.js +5 -1
- package/dist/module/gross-payment-chart-core2.js +8 -2
- package/dist/module/helpers.js +4 -0
- package/dist/module/{business-address-form.js → identity-address-form.js} +17 -20
- package/dist/module/justifi-business-details.js +21 -4
- package/dist/module/justifi-business-form.js +65 -56
- package/dist/module/justifi-gross-payment-chart.js +28 -4
- package/dist/module/justifi-identity-address-form.d.ts +11 -0
- package/dist/module/justifi-identity-address-form.js +6 -0
- package/dist/module/justifi-payment-details.js +26 -5
- package/dist/module/justifi-payment-form.js +18 -4
- package/dist/module/justifi-payment-provisioning.js +24 -23
- package/dist/module/justifi-payments-list.js +26 -6
- package/dist/module/justifi-payout-details.js +28 -8
- package/dist/module/justifi-payouts-list.js +27 -7
- package/dist/module/legal-address-form-step.js +8 -11
- package/dist/module/legal-address-form.js +5 -9
- package/dist/module/owner-form.js +22 -12
- package/dist/module/payment-details-core2.js +8 -2
- package/dist/module/payment-method-form.js +1 -1
- package/dist/module/payments-list-core2.js +8 -2
- package/dist/module/payout-details-core2.js +9 -4
- package/dist/module/payouts-list-core2.js +8 -2
- package/dist/module/utils3.js +31 -1
- package/dist/module/utils4.js +7 -1
- package/dist/types/api/ComponentError.d.ts +18 -0
- package/dist/types/api/services/utils.d.ts +2 -0
- package/dist/types/api/shared.d.ts +9 -0
- package/dist/types/components/business-details/business-details-core.d.ts +3 -0
- package/dist/types/components/business-details/business-details.d.ts +3 -0
- package/dist/types/components/business-forms/business-form/business-form.d.ts +4 -2
- package/dist/types/components/business-forms/owner-form/identity-address/identity-address-form.d.ts +10 -0
- package/dist/types/components/business-forms/owner-form/owner-form.d.ts +5 -1
- package/dist/types/components/business-forms/payment-provisioning/additional-questions/business-additional-questions-form-step.d.ts +1 -0
- package/dist/types/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.d.ts +1 -0
- package/dist/types/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.d.ts +3 -1
- package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.d.ts +1 -0
- package/dist/types/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.d.ts +1 -0
- package/dist/types/components/business-forms/payment-provisioning/payment-provisioning.d.ts +3 -2
- package/dist/types/components/business-forms/schemas/business-additional-questions-schema.d.ts +1 -1
- package/dist/types/components/business-forms/schemas/business-address-schema.d.ts +1 -12
- package/dist/types/components/business-forms/schemas/business-core-info-schema.d.ts +1 -1
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +7 -3
- package/dist/types/components/business-forms/schemas/business-identity-schema.d.ts +5 -31
- package/dist/types/components/business-forms/utils/business-form-types.d.ts +10 -0
- package/dist/types/components/business-forms/utils/helpers.d.ts +2 -0
- package/dist/types/components/form/form-control-text.d.ts +2 -0
- package/dist/types/components/form/utils.d.ts +1 -0
- package/dist/types/components/gross-payment-chart/get-gross-payment-chart-data.d.ts +5 -8
- package/dist/types/components/gross-payment-chart/gross-payment-chart-core.d.ts +3 -0
- package/dist/types/components/gross-payment-chart/gross-payment-chart.d.ts +4 -0
- package/dist/types/components/payment-details/payment-details-core.d.ts +3 -0
- package/dist/types/components/payment-details/payment-details.d.ts +4 -0
- package/dist/types/components/payment-form/payment-form.d.ts +4 -1
- package/dist/types/components/payments-list/payments-list-core.d.ts +2 -0
- package/dist/types/components/payments-list/payments-list.d.ts +4 -0
- package/dist/types/components/payout-details/payout-details-core.d.ts +3 -0
- package/dist/types/components/payout-details/payout-details.d.ts +4 -0
- package/dist/types/components/payouts-list/payouts-list-core.d.ts +2 -0
- package/dist/types/components/payouts-list/payouts-list.d.ts +4 -0
- package/dist/types/components.d.ts +217 -43
- package/dist/webcomponents/p-091f9732.entry.js +1 -0
- package/dist/webcomponents/p-0b76c770.entry.js +1 -0
- package/dist/webcomponents/p-0d81883d.entry.js +1 -0
- package/dist/webcomponents/{p-cb8f9cb8.entry.js → p-102b593a.entry.js} +1 -1
- package/dist/webcomponents/p-28cd23c8.entry.js +1 -0
- package/dist/webcomponents/p-2b8368d2.js +1 -0
- package/dist/webcomponents/p-436d27b9.entry.js +1 -0
- package/dist/webcomponents/p-448063ba.entry.js +1 -0
- package/dist/webcomponents/p-5341321d.entry.js +1 -0
- package/dist/webcomponents/p-5b262705.entry.js +1 -0
- package/dist/webcomponents/p-5e503d7d.entry.js +1 -0
- package/dist/webcomponents/p-6047b960.entry.js +1 -0
- package/dist/webcomponents/p-6f294d5d.js +1 -0
- package/dist/webcomponents/p-7294eb89.entry.js +1 -0
- package/dist/webcomponents/p-746bfba6.entry.js +1 -0
- package/dist/webcomponents/p-7c6a355f.entry.js +1 -0
- package/dist/webcomponents/p-935d6f55.js +1 -0
- package/dist/webcomponents/{p-e924f2e1.entry.js → p-959250e3.entry.js} +1 -1
- package/dist/webcomponents/{p-b37d6888.entry.js → p-a130a884.entry.js} +1 -1
- package/dist/webcomponents/p-ac670a3e.js +1 -0
- package/dist/webcomponents/p-ae21ed6f.entry.js +19 -0
- package/dist/webcomponents/p-c071d8c1.entry.js +1 -0
- package/dist/webcomponents/p-c340b60f.js +1 -0
- package/dist/webcomponents/p-d5aab6b5.entry.js +1 -0
- package/dist/webcomponents/p-d5c80489.entry.js +1 -0
- package/dist/webcomponents/p-d776fe10.entry.js +1 -0
- package/dist/webcomponents/p-d8679fad.entry.js +1 -0
- package/dist/webcomponents/p-e84b3616.entry.js +1 -0
- package/dist/webcomponents/p-ea2cca2a.js +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/Identity-1c4528b8.js +0 -49
- package/dist/cjs/business-additional-questions-schema-cbac27f2.js +0 -26
- package/dist/cjs/justifi-business-address-form-step.cjs.entry.js +0 -35
- package/dist/cjs/payload-parsers-9e72e80f.js +0 -99
- package/dist/cjs/utils-f5d82f21.js +0 -10
- package/dist/collection/api/mockData/MockOnboardingData.js +0 -117
- package/dist/collection/api/mockData/MockPayments.js +0 -243
- package/dist/collection/api/mockData/MockSubAccount.js +0 -102
- package/dist/collection/api/mockData/mockGrossVolumeReport.js +0 -125
- package/dist/collection/components/business-forms/business-form/business-address/test/business-address.e2e.js +0 -9
- package/dist/collection/components/business-forms/payment-provisioning/business-address/business-address-form-step.css +0 -2536
- package/dist/collection/components/business-forms/payment-provisioning/business-address/business-address-form-step.js +0 -97
- package/dist/collection/components/business-forms/payment-provisioning/business-address/test/business-address-form-step.spec.js +0 -97
- package/dist/collection/components/business-forms/schemas/business-owners-schema.js +0 -16
- package/dist/collection/components/card-form/test/card-form.e2e.js +0 -13
- package/dist/esm/Identity-5f8f916f.js +0 -46
- package/dist/esm/business-additional-questions-schema-2cb80f70.js +0 -23
- package/dist/esm/justifi-business-address-form-step.entry.js +0 -31
- package/dist/esm/payload-parsers-caea809d.js +0 -91
- package/dist/esm/utils-546ca6aa.js +0 -8
- package/dist/module/Identity.js +0 -46
- package/dist/module/justifi-business-address-form-step.d.ts +0 -11
- package/dist/module/justifi-business-address-form-step.js +0 -75
- package/dist/module/justifi-business-address-form.d.ts +0 -11
- package/dist/module/justifi-business-address-form.js +0 -6
- package/dist/types/api/mockData/MockOnboardingData.d.ts +0 -8
- package/dist/types/api/mockData/MockPayments.d.ts +0 -3
- package/dist/types/api/mockData/MockSubAccount.d.ts +0 -3
- package/dist/types/components/business-forms/business-form/business-address/business-address-form.d.ts +0 -9
- package/dist/types/components/business-forms/payment-provisioning/business-address/business-address-form-step.d.ts +0 -9
- package/dist/types/components/business-forms/schemas/business-owners-schema.d.ts +0 -33
- package/dist/webcomponents/p-03b1d0d5.entry.js +0 -1
- package/dist/webcomponents/p-0e189d6a.entry.js +0 -1
- package/dist/webcomponents/p-16dcf053.entry.js +0 -1
- package/dist/webcomponents/p-17d72f4a.js +0 -1
- package/dist/webcomponents/p-38ba2848.entry.js +0 -1
- package/dist/webcomponents/p-41870765.entry.js +0 -1
- package/dist/webcomponents/p-461f42b8.entry.js +0 -1
- package/dist/webcomponents/p-48c2400e.js +0 -1
- package/dist/webcomponents/p-491ca87f.js +0 -1
- package/dist/webcomponents/p-5be4e217.entry.js +0 -1
- package/dist/webcomponents/p-60714f2a.entry.js +0 -1
- package/dist/webcomponents/p-65500b31.entry.js +0 -19
- package/dist/webcomponents/p-6ed680e9.js +0 -1
- package/dist/webcomponents/p-7ec301b5.entry.js +0 -1
- package/dist/webcomponents/p-9207ccb2.entry.js +0 -1
- package/dist/webcomponents/p-9e4b81ad.entry.js +0 -1
- package/dist/webcomponents/p-a141c531.js +0 -1
- package/dist/webcomponents/p-a2dbe90f.entry.js +0 -1
- package/dist/webcomponents/p-a68519e5.entry.js +0 -1
- package/dist/webcomponents/p-af8363a1.entry.js +0 -1
- package/dist/webcomponents/p-b1bc23af.entry.js +0 -1
- package/dist/webcomponents/p-b5a3bf86.entry.js +0 -1
- package/dist/webcomponents/p-b8f22856.js +0 -1
- package/dist/webcomponents/p-d0761829.entry.js +0 -1
- package/dist/webcomponents/p-dbe32e75.entry.js +0 -1
- package/dist/webcomponents/p-e0c1cba8.js +0 -1
- package/dist/webcomponents/p-eed5f4ad.entry.js +0 -1
- package/dist/webcomponents/p-fe8a94c1.entry.js +0 -1
- /package/dist/collection/components/business-forms/{business-form/business-address/business-address-form.css → owner-form/identity-address/identity-address-form.css} +0 -0
- /package/dist/types/{api → home/runner/work/web-component-library/web-component-library/packages/webcomponents/.stencil}/mockData/mockGrossVolumeReport.d.ts +0 -0
- /package/dist/types/home/runner/work/web-component-library/web-component-library/packages/webcomponents/.stencil/{config.d.ts → packages/webcomponents/config.d.ts} +0 -0
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-df86d9a2.js';
|
|
1
|
+
import { r as registerInstance, c as createEvent, h } from './index-df86d9a2.js';
|
|
2
2
|
import { P as PaymentService } from './payment.service-f274ef98.js';
|
|
3
3
|
import './Pagination-afc8f96d.js';
|
|
4
4
|
import { a as Payment } from './Payment-55886c86.js';
|
|
5
5
|
import './Payout-dfe15b00.js';
|
|
6
|
-
import { g as getErrorMessage } from './utils-
|
|
6
|
+
import { C as ComponentErrorSeverity, g as getErrorMessage, a as getErrorCode, b as ComponentErrorCodes } from './utils-4609f32c.js';
|
|
7
7
|
import { E as ErrorState } from './utils-d01c5f3a.js';
|
|
8
8
|
import './Api-0e88671c.js';
|
|
9
9
|
import './config-476c7241.js';
|
|
10
10
|
|
|
11
11
|
const makeGetPayments = ({ id, authToken, service }) => async ({ params, onSuccess, onError }) => {
|
|
12
|
-
var _a;
|
|
12
|
+
var _a, _b;
|
|
13
13
|
try {
|
|
14
14
|
const response = await service.fetchPayments(id, authToken, params);
|
|
15
15
|
if (!response.error) {
|
|
@@ -19,17 +19,32 @@ const makeGetPayments = ({ id, authToken, service }) => async ({ params, onSucce
|
|
|
19
19
|
}
|
|
20
20
|
else {
|
|
21
21
|
const responseError = getErrorMessage(response.error);
|
|
22
|
-
|
|
22
|
+
const code = getErrorCode((_b = response.error) === null || _b === void 0 ? void 0 : _b.code);
|
|
23
|
+
return onError({
|
|
24
|
+
error: responseError,
|
|
25
|
+
code,
|
|
26
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
27
|
+
});
|
|
23
28
|
}
|
|
24
29
|
}
|
|
25
30
|
catch (error) {
|
|
26
|
-
|
|
31
|
+
const code = getErrorCode(error === null || error === void 0 ? void 0 : error.code);
|
|
32
|
+
return onError({
|
|
33
|
+
error: error.message || error,
|
|
34
|
+
code,
|
|
35
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
36
|
+
});
|
|
27
37
|
}
|
|
28
38
|
};
|
|
29
39
|
|
|
30
40
|
const PaymentsList = class {
|
|
31
41
|
constructor(hostRef) {
|
|
32
42
|
registerInstance(this, hostRef);
|
|
43
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
44
|
+
this.handleErrorEvent = (event) => {
|
|
45
|
+
this.errorMessage = event.detail.message;
|
|
46
|
+
this.errorEvent.emit(event.detail);
|
|
47
|
+
};
|
|
33
48
|
this.accountId = undefined;
|
|
34
49
|
this.authToken = undefined;
|
|
35
50
|
this.getPayments = undefined;
|
|
@@ -51,13 +66,18 @@ const PaymentsList = class {
|
|
|
51
66
|
}
|
|
52
67
|
else {
|
|
53
68
|
this.errorMessage = 'Account ID and Auth Token are required';
|
|
69
|
+
this.errorEvent.emit({
|
|
70
|
+
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
71
|
+
message: this.errorMessage,
|
|
72
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
73
|
+
});
|
|
54
74
|
}
|
|
55
75
|
}
|
|
56
76
|
render() {
|
|
57
77
|
if (this.errorMessage) {
|
|
58
78
|
return ErrorState(this.errorMessage);
|
|
59
79
|
}
|
|
60
|
-
return (h("payments-list-core", { getPayments: this.getPayments }));
|
|
80
|
+
return (h("payments-list-core", { getPayments: this.getPayments, "onError-event": this.handleErrorEvent }));
|
|
61
81
|
}
|
|
62
82
|
static get watchers() { return {
|
|
63
83
|
"accountId": ["propChanged"],
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-df86d9a2.js';
|
|
1
|
+
import { r as registerInstance, c as createEvent, h } from './index-df86d9a2.js';
|
|
2
2
|
import { P as PayoutService } from './payout.service-af293f61.js';
|
|
3
3
|
import './Pagination-afc8f96d.js';
|
|
4
4
|
import './Payment-55886c86.js';
|
|
5
5
|
import { P as Payout } from './Payout-dfe15b00.js';
|
|
6
|
-
import { g as getErrorMessage } from './utils-
|
|
6
|
+
import { C as ComponentErrorSeverity, g as getErrorMessage, a as getErrorCode, b as ComponentErrorCodes } from './utils-4609f32c.js';
|
|
7
7
|
import { E as ErrorState } from './utils-d01c5f3a.js';
|
|
8
8
|
import './Api-0e88671c.js';
|
|
9
9
|
import './config-476c7241.js';
|
|
10
10
|
|
|
11
11
|
const makeGetPayoutDetails = ({ id, authToken, service }) => async ({ onSuccess, onError }) => {
|
|
12
|
+
var _a;
|
|
12
13
|
try {
|
|
13
14
|
const response = await service.fetchPayout(id, authToken);
|
|
14
15
|
if (!response.error) {
|
|
@@ -16,20 +17,34 @@ const makeGetPayoutDetails = ({ id, authToken, service }) => async ({ onSuccess,
|
|
|
16
17
|
onSuccess(payout);
|
|
17
18
|
}
|
|
18
19
|
else {
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
onError(
|
|
20
|
+
const errorMessage = getErrorMessage(response.error);
|
|
21
|
+
const code = getErrorCode((_a = response.error) === null || _a === void 0 ? void 0 : _a.code);
|
|
22
|
+
onError({
|
|
23
|
+
error: errorMessage,
|
|
24
|
+
code,
|
|
25
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
26
|
+
});
|
|
22
27
|
}
|
|
23
28
|
}
|
|
24
29
|
catch (error) {
|
|
25
|
-
const errorMessage =
|
|
26
|
-
|
|
30
|
+
const errorMessage = getErrorMessage(error);
|
|
31
|
+
const code = getErrorCode(error === null || error === void 0 ? void 0 : error.code);
|
|
32
|
+
onError({
|
|
33
|
+
error: errorMessage,
|
|
34
|
+
code,
|
|
35
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
36
|
+
});
|
|
27
37
|
}
|
|
28
38
|
};
|
|
29
39
|
|
|
30
40
|
const PayoutDetails = class {
|
|
31
41
|
constructor(hostRef) {
|
|
32
42
|
registerInstance(this, hostRef);
|
|
43
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
44
|
+
this.handleErrorEvent = (event) => {
|
|
45
|
+
this.errorMessage = event.detail.message;
|
|
46
|
+
this.errorEvent.emit(event.detail);
|
|
47
|
+
};
|
|
33
48
|
this.payoutId = undefined;
|
|
34
49
|
this.authToken = undefined;
|
|
35
50
|
this.getPayout = undefined;
|
|
@@ -51,13 +66,18 @@ const PayoutDetails = class {
|
|
|
51
66
|
}
|
|
52
67
|
else {
|
|
53
68
|
this.errorMessage = 'Failed to load payout details. payoutId or authToken is not provided.';
|
|
69
|
+
this.errorEvent.emit({
|
|
70
|
+
message: this.errorMessage,
|
|
71
|
+
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
72
|
+
severity: ComponentErrorSeverity.ERROR
|
|
73
|
+
});
|
|
54
74
|
}
|
|
55
75
|
}
|
|
56
76
|
render() {
|
|
57
77
|
if (this.errorMessage) {
|
|
58
78
|
return ErrorState(this.errorMessage);
|
|
59
79
|
}
|
|
60
|
-
return (h("payout-details-core", { getPayout: this.getPayout }));
|
|
80
|
+
return (h("payout-details-core", { getPayout: this.getPayout, "onError-event": this.handleErrorEvent }));
|
|
61
81
|
}
|
|
62
82
|
static get watchers() { return {
|
|
63
83
|
"payoutId": ["propChanged"],
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-df86d9a2.js';
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-df86d9a2.js';
|
|
2
2
|
import { t as tableExportedParts } from './exported-parts-abd4c027.js';
|
|
3
3
|
import { P as PayoutService } from './payout.service-af293f61.js';
|
|
4
4
|
import './Pagination-afc8f96d.js';
|
|
5
5
|
import './Payment-55886c86.js';
|
|
6
6
|
import { P as Payout } from './Payout-dfe15b00.js';
|
|
7
|
-
import { g as getErrorMessage } from './utils-
|
|
7
|
+
import { C as ComponentErrorSeverity, g as getErrorMessage, a as getErrorCode, b as ComponentErrorCodes } from './utils-4609f32c.js';
|
|
8
8
|
import { E as ErrorState } from './utils-d01c5f3a.js';
|
|
9
9
|
import './Api-0e88671c.js';
|
|
10
10
|
import './config-476c7241.js';
|
|
11
11
|
|
|
12
12
|
const makeGetPayouts = ({ id, authToken, service }) => async ({ params, onSuccess, onError }) => {
|
|
13
|
-
var _a;
|
|
13
|
+
var _a, _b;
|
|
14
14
|
try {
|
|
15
15
|
const response = await service.fetchPayouts(id, authToken, params);
|
|
16
16
|
if (!response.error) {
|
|
@@ -19,18 +19,34 @@ const makeGetPayouts = ({ id, authToken, service }) => async ({ params, onSucces
|
|
|
19
19
|
onSuccess({ payouts, pagingInfo });
|
|
20
20
|
}
|
|
21
21
|
else {
|
|
22
|
-
const
|
|
23
|
-
|
|
22
|
+
const error = getErrorMessage(response.error);
|
|
23
|
+
const code = getErrorCode((_b = response.error) === null || _b === void 0 ? void 0 : _b.code);
|
|
24
|
+
return onError({
|
|
25
|
+
error,
|
|
26
|
+
code,
|
|
27
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
28
|
+
});
|
|
24
29
|
}
|
|
25
30
|
}
|
|
26
31
|
catch (error) {
|
|
27
|
-
|
|
32
|
+
const message = getErrorMessage(error);
|
|
33
|
+
const code = getErrorCode(error === null || error === void 0 ? void 0 : error.code);
|
|
34
|
+
return onError({
|
|
35
|
+
error: message,
|
|
36
|
+
code,
|
|
37
|
+
severity: ComponentErrorSeverity.ERROR,
|
|
38
|
+
});
|
|
28
39
|
}
|
|
29
40
|
};
|
|
30
41
|
|
|
31
42
|
const PayoutsList = class {
|
|
32
43
|
constructor(hostRef) {
|
|
33
44
|
registerInstance(this, hostRef);
|
|
45
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
46
|
+
this.handleOnError = (event) => {
|
|
47
|
+
this.errorMessage = event.detail.message;
|
|
48
|
+
this.errorEvent.emit(event.detail);
|
|
49
|
+
};
|
|
34
50
|
this.accountId = undefined;
|
|
35
51
|
this.authToken = undefined;
|
|
36
52
|
this.getPayouts = undefined;
|
|
@@ -52,13 +68,17 @@ const PayoutsList = class {
|
|
|
52
68
|
}
|
|
53
69
|
else {
|
|
54
70
|
this.errorMessage = 'Account ID and Auth Token are required';
|
|
71
|
+
this.errorEvent.emit({
|
|
72
|
+
errorCode: ComponentErrorCodes.MISSING_PROPS,
|
|
73
|
+
message: 'Account ID and Auth Token are required',
|
|
74
|
+
});
|
|
55
75
|
}
|
|
56
76
|
}
|
|
57
77
|
render() {
|
|
58
78
|
if (this.errorMessage) {
|
|
59
79
|
return ErrorState(this.errorMessage);
|
|
60
80
|
}
|
|
61
|
-
return (h(Host, { exportedparts: tableExportedParts }, h("payouts-list-core", { getPayouts: this.getPayouts })));
|
|
81
|
+
return (h(Host, { exportedparts: tableExportedParts }, h("payouts-list-core", { getPayouts: this.getPayouts, "onError-event": this.handleOnError })));
|
|
62
82
|
}
|
|
63
83
|
static get watchers() { return {
|
|
64
84
|
"accountId": ["propChanged"],
|
package/dist/esm/loader.js
CHANGED
|
@@ -3,7 +3,7 @@ export { s as setNonce } from './index-df86d9a2.js';
|
|
|
3
3
|
|
|
4
4
|
const defineCustomElements = (win, options) => {
|
|
5
5
|
if (typeof window === 'undefined') return undefined;
|
|
6
|
-
return bootstrapLazy(JSON.parse("[[\"justifi-payment-provisioning\",[[0,\"justifi-payment-provisioning\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"testMode\":[4,\"test-mode\"],\"hideErrors\":[4,\"hide-errors\"],\"formLoading\":[32],\"errorMessage\":[32],\"currentStep\":[32],\"totalSteps\":[32]}]]],[\"justifi-business-form\",[[0,\"justifi-business-form\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"hideErrors\":[4,\"hide-errors\"],\"isLoading\":[32],\"errorMessage\":[32]}]]],[\"justifi-checkout\",[[1,\"justifi-checkout\",{\"iframeOrigin\":[1,\"iframe-origin\"],\"authToken\":[1,\"auth-token\"],\"checkoutId\":[1,\"checkout-id\"],\"getCheckout\":[32],\"pay\":[32],\"errorMessage\":[32]},null,{\"authToken\":[\"propChanged\"],\"checkoutId\":[\"propChanged\"]}]]],[\"justifi-business-details\",[[1,\"justifi-business-details\",{\"businessId\":[1,\"business-id\"],\"authToken\":[1,\"auth-token\"],\"errorMessage\":[32],\"getBusiness\":[32]}]]],[\"justifi-payment-form\",[[1,\"justifi-payment-form\",{\"bankAccount\":[4,\"bank-account\"],\"card\":[4],\"email\":[1],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"submitButtonText\":[1,\"submit-button-text\"],\"submitButtonEnabled\":[32],\"isLoading\":[32],\"selectedPaymentMethodType\":[32],\"fillBillingForm\":[64],\"enableSubmitButton\":[64]}]]],[\"justifi-subaccount-details\",[[1,\"justifi-subaccount-details\",{\"accountId\":[1,\"account-id\"],\"subaccountId\":[1,\"subaccount-id\"],\"authToken\":[1,\"auth-token\"],\"onboardingData\":[32],\"subaccount\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"subaccountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"]}]]],[\"justifi-business-owners\",[[0,\"justifi-business-owners\",{\"formController\":[16],\"errors\":[32],\"owners\":[32]}]]],[\"justifi-business-address-form-step\",[[1,\"justifi-business-address-form-step\",{\"handleFormUpdate\":[16],\"errors\":[8],\"defaultValues\":[8,\"default-values\"],\"address\":[32]},null,{\"address\":[\"handleAddressChange\"]}]]],[\"justifi-payments-list\",[[1,\"justifi-payments-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getPayments\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-payouts-list\",[[1,\"justifi-payouts-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getPayouts\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-business-list\",[[1,\"justifi-business-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"businesses\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-payment-balance-transactions\",[[1,\"justifi-payment-balance-transactions\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"paymentId\":[1,\"payment-id\"],\"balanceTransactions\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-payment-details\",[[1,\"justifi-payment-details\",{\"paymentId\":[1,\"payment-id\"],\"authToken\":[1,\"auth-token\"],\"getPaymentDetails\":[32],\"errorMessage\":[32]},null,{\"paymentId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-payout-details\",[[1,\"justifi-payout-details\",{\"payoutId\":[1,\"payout-id\"],\"authToken\":[1,\"auth-token\"],\"getPayout\":[32],\"errorMessage\":[32]},null,{\"payoutId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-proceeds-list\",[[1,\"justifi-proceeds-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"proceeds\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-refund-form\",[[1,\"justifi-refund-form\",{\"authToken\":[1,\"auth-token\"],\"paymentId\":[1,\"payment-id\"],\"amount\":[2],\"submitButtonText\":[1,\"submit-button-text\"],\"withButton\":[4,\"with-button\"],\"refundInfoText\":[1,\"refund-info-text\"],\"errors\":[32],\"isSubmitting\":[32]}]]],[\"justifi-subaccounts-list\",[[1,\"justifi-subaccounts-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"subaccounts\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-billing-form_4\",[[1,\"justifi-billing-form\",{\"legend\":[1025],\"billingFields\":[32],\"billingFieldsErrors\":[32],\"fill\":[64],\"validate\":[64],\"getValues\":[64]},[[0,\"fieldReceivedInput\",\"setFormValue\"]]],[1,\"select-input\",{\"name\":[1],\"label\":[1],\"defaultValue\":[1,\"default-value\"],\"error\":[1],\"options\":[16],\"internalValue\":[32]}],[1,\"text-input\",{\"name\":[1],\"label\":[1],\"defaultValue\":[1,\"default-value\"],\"error\":[1],\"internalValue\":[32]}],[0,\"justifi-payment-method-form\",{\"paymentMethodFormType\":[1,\"payment-method-form-type\"],\"paymentMethodFormValidationMode\":[1025,\"payment-method-form-validation-mode\"],\"iframeOrigin\":[1,\"iframe-origin\"],\"singleLine\":[4,\"single-line\"],\"resize\":[64],\"tokenize\":[64],\"validate\":[64]}]]],[\"justifi-bank-account-form\",[[0,\"justifi-bank-account-form\",{\"validationMode\":[1025,\"validation-mode\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"internalStyleOverrides\":[32],\"tokenize\":[64],\"validate\":[64],\"resize\":[64]},[[0,\"paymentMethodFormReady\",\"readyHandler\"],[0,\"paymentMethodFormTokenized\",\"tokenizeHandler\"],[0,\"paymentMethodFormValidated\",\"validateHandler\"]]]]],[\"justifi-card-form\",[[0,\"justifi-card-form\",{\"validationMode\":[1025,\"validation-mode\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"singleLine\":[4,\"single-line\"],\"internalStyleOverrides\":[32],\"tokenize\":[64],\"validate\":[64],\"resize\":[64]},[[0,\"paymentMethodFormReady\",\"readyHandler\"],[0,\"paymentMethodFormTokenized\",\"tokenizeHandler\"],[0,\"paymentMethodFormValidated\",\"validateHandler\"]]]]],[\"justifi-gross-payment-chart\",[[1,\"justifi-gross-payment-chart\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getGrossPayment\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"subaccount-bank-details\",[[1,\"subaccount-bank-details\",{\"data\":[16]}]]],[\"subaccount-terms-details\",[[1,\"subaccount-terms-details\",{\"data\":[16]}]]],[\"justifi-checkout-core\",[[1,\"justifi-checkout-core\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"authToken\":[1,\"auth-token\"],\"getCheckout\":[16],\"pay\":[16],\"checkoutId\":[1,\"checkout-id\"],\"hasLoadedFonts\":[32],\"isLoading\":[32],\"checkout\":[32],\"serverError\":[32],\"errorMessage\":[32],\"creatingNewPaymentMethod\":[32],\"selectedPaymentMethodToken\":[32],\"loadFontsOnParent\":[64]}]]],[\"business-details-core\",[[0,\"business-details-core\",{\"getBusiness\":[16],\"business\":[32],\"renderState\":[32],\"errorMessage\":[32]}]]],[\"payments-list-core\",[[0,\"payments-list-core\",{\"getPayments\":[16],\"payments\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"],\"getPayments\":[\"updateOnPropChange\"]}]]],[\"payouts-list-core\",[[0,\"payouts-list-core\",{\"getPayouts\":[16],\"payouts\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"],\"getPayouts\":[\"updateOnPropChange\"]}]]],[\"payment-details-core\",[[0,\"payment-details-core\",{\"getPaymentDetails\":[16],\"payment\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getPaymentDetails\":[\"updateOnPropChange\"]}]]],[\"payout-details-core\",[[0,\"payout-details-core\",{\"getPayout\":[16],\"payout\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getPayout\":[\"getPayoutWatcher\"]}]]],[\"gross-payment-chart-core\",[[0,\"gross-payment-chart-core\",{\"getGrossPayment\":[16],\"grossVolumeReport\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getGrossPayment\":[\"propChanged\"],\"grossVolumeReport\":[\"grossVolumeReportChanged\"]}]]],[\"justifi-payment-method-selector\",[[1,\"justifi-payment-method-selector\",{\"selectedPaymentMethodType\":[1,\"selected-payment-method-type\"]}]]],[\"form-control-number_3\",[[1,\"form-control-number\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"disabled\":[4],\"input\":[32]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-select\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"options\":[16],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-text\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"disabled\":[4],\"inputHandler\":[16],\"input\":[32]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]],[\"justifi-owner-form\",[[1,\"justifi-owner-form\",{\"authToken\":[1,\"auth-token\"],\"ownerId\":[1,\"owner-id\"],\"businessId\":[1,\"business-id\"],\"removeOwner\":[16],\"newFormOpen\":[4,\"new-form-open\"],\"ownersLength\":[2,\"owners-length\"],\"isLoading\":[32],\"formController\":[32],\"errors\":[32],\"owner\":[32],\"validate\":[64],\"submit\":[64]},null,{\"isLoading\":[\"loadingWatcher\"]}]]],[\"justifi-additional-questions_4\",[[0,\"justifi-business-representative\",{\"formController\":[16],\"errors\":[32],\"representative\":[32]}],[0,\"justifi-business-core-info\",{\"formController\":[16],\"errors\":[32],\"coreInfo\":[32]}],[0,\"justifi-legal-address-form\",{\"formController\":[16],\"errors\":[32],\"legal_address\":[32]}],[0,\"justifi-additional-questions\",{\"formController\":[16],\"errors\":[32],\"additional_questions\":[32]}]]],[\"subaccount-account-details_4\",[[1,\"subaccount-account-details\",{\"subaccount\":[16],\"onboardingData\":[16]}],[1,\"subaccount-merchant-details\",{\"onboardingData\":[16]}],[1,\"subaccount-owners-details\",{\"data\":[16]}],[1,\"subaccount-representative-details\",{\"data\":[16]}]]],[\"form-control-monetary\",[[1,\"form-control-monetary\",{\"label\":[1],\"name\":[1],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]],[\"justifi-additional-questions-form-step_5\",[[0,\"justifi-business-owners-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"owners\":[32],\"newFormOpen\":[32],\"refs\":[32],\"validateAndSubmit\":[64]},null,{\"owners\":[\"onOwnersUpdated\"]}],[0,\"justifi-business-representative-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"formController\":[32],\"errors\":[32],\"representative\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-business-core-info-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"formController\":[32],\"errors\":[32],\"coreInfo\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-legal-address-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"formController\":[32],\"errors\":[32],\"legal_address\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-additional-questions-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"formController\":[32],\"errors\":[32],\"additional_questions\":[32],\"validateAndSubmit\":[64]}]]],[\"justifi-details\",[[1,\"justifi-details\",{\"errorMessage\":[1,\"error-message\"]}]]],[\"justifi-new-payment-method_3\",[[0,\"justifi-payment-method-options\",{\"showCard\":[4,\"show-card\"],\"showAch\":[4,\"show-ach\"],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"savedPaymentMethods\":[16],\"selectedPaymentMethodId\":[1,\"selected-payment-method-id\"],\"paymentMethodOptions\":[32],\"getPaymentMethodToken\":[64]},[[0,\"paymentMethodOptionSelected\",\"paymentMethodOptionSelected\"]],{\"savedPaymentMethods\":[\"paymentMethodsChanged\"]}],[0,\"justifi-new-payment-method\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"paymentMethodOption\":[16],\"isSelected\":[4,\"is-selected\"],\"getPaymentMethodToken\":[64]}],[0,\"justifi-saved-payment-method\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"paymentMethodOption\":[16],\"isSelected\":[4,\"is-selected\"],\"getPaymentMethodToken\":[64]}]]],[\"additional-questions-details_5\",[[1,\"additional-questions-details\",{\"additionalQuestions\":[16]}],[1,\"generic-info-details\",{\"business\":[16]}],[1,\"legal-address-details\",{\"legalAddress\":[16]}],[1,\"owner-details\",{\"owners\":[16]}],[1,\"representative-details\",{\"representative\":[16]}]]],[\"justifi-table_2\",[[1,\"justifi-table\",{\"loading\":[4],\"errorMessage\":[1,\"error-message\"],\"rowData\":[16],\"columnData\":[16],\"paging\":[16],\"params\":[8],\"entityId\":[16],\"rowClickHandler\":[16]}],[1,\"pagination-menu\",{\"paging\":[16],\"params\":[16]}]]],[\"form-control-datepart_3\",[[1,\"justifi-business-address-form\",{\"handleFormUpdate\":[16],\"errors\":[8],\"defaultValues\":[8,\"default-values\"],\"address\":[32]},null,{\"address\":[\"handleAddressChange\"]}],[1,\"form-control-datepart\",{\"label\":[1],\"name\":[1],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"type\":[1],\"inputHandler\":[16],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-number-masked\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"mask\":[1],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]]]"), options);
|
|
6
|
+
return bootstrapLazy(JSON.parse("[[\"justifi-payment-provisioning\",[[0,\"justifi-payment-provisioning\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"testMode\":[4,\"test-mode\"],\"hideErrors\":[4,\"hide-errors\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"formLoading\":[32],\"errorMessage\":[32],\"currentStep\":[32],\"totalSteps\":[32]}]]],[\"justifi-business-form\",[[0,\"justifi-business-form\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"hideErrors\":[4,\"hide-errors\"],\"isLoading\":[32],\"errorMessage\":[32]}]]],[\"justifi-checkout\",[[1,\"justifi-checkout\",{\"iframeOrigin\":[1,\"iframe-origin\"],\"authToken\":[1,\"auth-token\"],\"checkoutId\":[1,\"checkout-id\"],\"getCheckout\":[32],\"pay\":[32],\"errorMessage\":[32]},null,{\"authToken\":[\"propChanged\"],\"checkoutId\":[\"propChanged\"]}]]],[\"justifi-business-details\",[[1,\"justifi-business-details\",{\"businessId\":[1,\"business-id\"],\"authToken\":[1,\"auth-token\"],\"errorMessage\":[32],\"getBusiness\":[32]}]]],[\"justifi-payment-form\",[[1,\"justifi-payment-form\",{\"bankAccount\":[4,\"bank-account\"],\"card\":[4],\"email\":[1],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"submitButtonText\":[1,\"submit-button-text\"],\"submitButtonEnabled\":[32],\"isLoading\":[32],\"selectedPaymentMethodType\":[32],\"fillBillingForm\":[64],\"enableSubmitButton\":[64],\"disableSubmitButton\":[64]}]]],[\"justifi-subaccount-details\",[[1,\"justifi-subaccount-details\",{\"accountId\":[1,\"account-id\"],\"subaccountId\":[1,\"subaccount-id\"],\"authToken\":[1,\"auth-token\"],\"onboardingData\":[32],\"subaccount\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"subaccountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"]}]]],[\"justifi-business-owners\",[[0,\"justifi-business-owners\",{\"formController\":[16],\"errors\":[32],\"owners\":[32]}]]],[\"justifi-payments-list\",[[1,\"justifi-payments-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getPayments\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-payouts-list\",[[1,\"justifi-payouts-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getPayouts\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-business-list\",[[1,\"justifi-business-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"businesses\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-payment-balance-transactions\",[[1,\"justifi-payment-balance-transactions\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"paymentId\":[1,\"payment-id\"],\"balanceTransactions\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-payment-details\",[[1,\"justifi-payment-details\",{\"paymentId\":[1,\"payment-id\"],\"authToken\":[1,\"auth-token\"],\"getPaymentDetails\":[32],\"errorMessage\":[32]},null,{\"paymentId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-payout-details\",[[1,\"justifi-payout-details\",{\"payoutId\":[1,\"payout-id\"],\"authToken\":[1,\"auth-token\"],\"getPayout\":[32],\"errorMessage\":[32]},null,{\"payoutId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"justifi-proceeds-list\",[[1,\"justifi-proceeds-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"proceeds\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-refund-form\",[[1,\"justifi-refund-form\",{\"authToken\":[1,\"auth-token\"],\"paymentId\":[1,\"payment-id\"],\"amount\":[2],\"submitButtonText\":[1,\"submit-button-text\"],\"withButton\":[4,\"with-button\"],\"refundInfoText\":[1,\"refund-info-text\"],\"errors\":[32],\"isSubmitting\":[32]}]]],[\"justifi-subaccounts-list\",[[1,\"justifi-subaccounts-list\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"subaccounts\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"accountId\":[\"updateOnPropChange\"],\"authToken\":[\"updateOnPropChange\"],\"params\":[\"updateOnPropChange\"]}]]],[\"justifi-bank-account-form\",[[0,\"justifi-bank-account-form\",{\"validationMode\":[1025,\"validation-mode\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"internalStyleOverrides\":[32],\"tokenize\":[64],\"validate\":[64],\"resize\":[64]},[[0,\"paymentMethodFormReady\",\"readyHandler\"],[0,\"paymentMethodFormTokenized\",\"tokenizeHandler\"],[0,\"paymentMethodFormValidated\",\"validateHandler\"]]]]],[\"justifi-card-form\",[[0,\"justifi-card-form\",{\"validationMode\":[1025,\"validation-mode\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"singleLine\":[4,\"single-line\"],\"internalStyleOverrides\":[32],\"tokenize\":[64],\"validate\":[64],\"resize\":[64]},[[0,\"paymentMethodFormReady\",\"readyHandler\"],[0,\"paymentMethodFormTokenized\",\"tokenizeHandler\"],[0,\"paymentMethodFormValidated\",\"validateHandler\"]]]]],[\"justifi-gross-payment-chart\",[[1,\"justifi-gross-payment-chart\",{\"accountId\":[1,\"account-id\"],\"authToken\":[1,\"auth-token\"],\"getGrossPayment\":[32],\"errorMessage\":[32]},null,{\"accountId\":[\"propChanged\"],\"authToken\":[\"propChanged\"]}]]],[\"subaccount-bank-details\",[[1,\"subaccount-bank-details\",{\"data\":[16]}]]],[\"subaccount-terms-details\",[[1,\"subaccount-terms-details\",{\"data\":[16]}]]],[\"justifi-checkout-core\",[[1,\"justifi-checkout-core\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"authToken\":[1,\"auth-token\"],\"getCheckout\":[16],\"pay\":[16],\"checkoutId\":[1,\"checkout-id\"],\"hasLoadedFonts\":[32],\"isLoading\":[32],\"checkout\":[32],\"serverError\":[32],\"errorMessage\":[32],\"creatingNewPaymentMethod\":[32],\"selectedPaymentMethodToken\":[32],\"loadFontsOnParent\":[64]}]]],[\"business-details-core\",[[0,\"business-details-core\",{\"getBusiness\":[16],\"business\":[32],\"renderState\":[32],\"errorMessage\":[32]}]]],[\"justifi-table_2\",[[1,\"justifi-table\",{\"loading\":[4],\"errorMessage\":[1,\"error-message\"],\"rowData\":[16],\"columnData\":[16],\"paging\":[16],\"params\":[8],\"entityId\":[16],\"rowClickHandler\":[16]}],[1,\"pagination-menu\",{\"paging\":[16],\"params\":[16]}]]],[\"payments-list-core\",[[0,\"payments-list-core\",{\"getPayments\":[16],\"payments\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"],\"getPayments\":[\"updateOnPropChange\"]}]]],[\"payouts-list-core\",[[0,\"payouts-list-core\",{\"getPayouts\":[16],\"payouts\":[32],\"loading\":[32],\"errorMessage\":[32],\"paging\":[32],\"params\":[32]},null,{\"params\":[\"updateOnPropChange\"],\"getPayouts\":[\"updateOnPropChange\"]}]]],[\"payment-details-core\",[[0,\"payment-details-core\",{\"getPaymentDetails\":[16],\"payment\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getPaymentDetails\":[\"updateOnPropChange\"]}]]],[\"payout-details-core\",[[0,\"payout-details-core\",{\"getPayout\":[16],\"payout\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getPayout\":[\"getPayoutWatcher\"]}]]],[\"gross-payment-chart-core\",[[0,\"gross-payment-chart-core\",{\"getGrossPayment\":[16],\"grossVolumeReport\":[32],\"loading\":[32],\"errorMessage\":[32]},null,{\"getGrossPayment\":[\"propChanged\"],\"grossVolumeReport\":[\"grossVolumeReportChanged\"]}]]],[\"justifi-payment-method-selector\",[[1,\"justifi-payment-method-selector\",{\"selectedPaymentMethodType\":[1,\"selected-payment-method-type\"]}]]],[\"form-control-select_2\",[[1,\"form-control-select\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"options\":[16],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-text\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"keyDownHandler\":[16],\"maxLength\":[2,\"max-length\"],\"disabled\":[4],\"inputHandler\":[16],\"input\":[32]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]],[\"form-control-datepart_4\",[[1,\"justifi-identity-address-form\",{\"handleFormUpdate\":[16],\"errors\":[8],\"defaultValues\":[8,\"default-values\"],\"address\":[32]},null,{\"address\":[\"handleAddressChange\"]}],[1,\"form-control-datepart\",{\"label\":[1],\"name\":[1],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"type\":[1],\"inputHandler\":[16],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-number\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"disabled\":[4],\"input\":[32]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}],[1,\"form-control-number-masked\",{\"label\":[1],\"name\":[8],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16],\"mask\":[1],\"disabled\":[4]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]],[\"justifi-owner-form\",[[1,\"justifi-owner-form\",{\"authToken\":[1,\"auth-token\"],\"ownerId\":[1,\"owner-id\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"removeOwner\":[16],\"newFormOpen\":[4,\"new-form-open\"],\"ownersLength\":[2,\"owners-length\"],\"isLoading\":[32],\"formController\":[32],\"errors\":[32],\"owner\":[32],\"validate\":[64],\"submit\":[64]},null,{\"isLoading\":[\"loadingWatcher\"]}]]],[\"justifi-additional-questions_4\",[[0,\"justifi-business-representative\",{\"formController\":[16],\"errors\":[32],\"representative\":[32]}],[0,\"justifi-business-core-info\",{\"formController\":[16],\"errors\":[32],\"coreInfo\":[32]}],[0,\"justifi-legal-address-form\",{\"formController\":[16],\"errors\":[32],\"legal_address\":[32]}],[0,\"justifi-additional-questions\",{\"formController\":[16],\"errors\":[32],\"additional_questions\":[32]}]]],[\"subaccount-account-details_4\",[[1,\"subaccount-account-details\",{\"subaccount\":[16],\"onboardingData\":[16]}],[1,\"subaccount-merchant-details\",{\"onboardingData\":[16]}],[1,\"subaccount-owners-details\",{\"data\":[16]}],[1,\"subaccount-representative-details\",{\"data\":[16]}]]],[\"form-control-monetary\",[[1,\"form-control-monetary\",{\"label\":[1],\"name\":[1],\"error\":[1],\"defaultValue\":[1,\"default-value\"],\"inputHandler\":[16]},null,{\"defaultValue\":[\"handleDefaultValueChange\"]}]]],[\"justifi-additional-questions-form-step_5\",[[0,\"justifi-business-owners-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"owners\":[32],\"newFormOpen\":[32],\"refs\":[32],\"validateAndSubmit\":[64]},null,{\"owners\":[\"onOwnersUpdated\"]}],[0,\"justifi-business-representative-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"formController\":[32],\"errors\":[32],\"representative\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-business-core-info-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"formController\":[32],\"errors\":[32],\"coreInfo\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-legal-address-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"formController\":[32],\"errors\":[32],\"legal_address\":[32],\"validateAndSubmit\":[64]}],[0,\"justifi-additional-questions-form-step\",{\"authToken\":[1,\"auth-token\"],\"businessId\":[1,\"business-id\"],\"allowOptionalFields\":[4,\"allow-optional-fields\"],\"formController\":[32],\"errors\":[32],\"additional_questions\":[32],\"validateAndSubmit\":[64]}]]],[\"justifi-details\",[[1,\"justifi-details\",{\"errorMessage\":[1,\"error-message\"]}]]],[\"justifi-billing-form_4\",[[1,\"justifi-billing-form\",{\"legend\":[1025],\"billingFields\":[32],\"billingFieldsErrors\":[32],\"fill\":[64],\"validate\":[64],\"getValues\":[64]},[[0,\"fieldReceivedInput\",\"setFormValue\"]]],[1,\"select-input\",{\"name\":[1],\"label\":[1],\"defaultValue\":[1,\"default-value\"],\"error\":[1],\"options\":[16],\"internalValue\":[32]}],[1,\"text-input\",{\"name\":[1],\"label\":[1],\"defaultValue\":[1,\"default-value\"],\"error\":[1],\"internalValue\":[32]}],[0,\"justifi-payment-method-form\",{\"paymentMethodFormType\":[1,\"payment-method-form-type\"],\"paymentMethodFormValidationMode\":[1025,\"payment-method-form-validation-mode\"],\"iframeOrigin\":[1,\"iframe-origin\"],\"singleLine\":[4,\"single-line\"],\"resize\":[64],\"tokenize\":[64],\"validate\":[64]}]]],[\"justifi-new-payment-method_3\",[[0,\"justifi-payment-method-options\",{\"showCard\":[4,\"show-card\"],\"showAch\":[4,\"show-ach\"],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"iframeOrigin\":[1025,\"iframe-origin\"],\"savedPaymentMethods\":[16],\"selectedPaymentMethodId\":[1,\"selected-payment-method-id\"],\"paymentMethodOptions\":[32],\"getPaymentMethodToken\":[64]},[[0,\"paymentMethodOptionSelected\",\"paymentMethodOptionSelected\"]],{\"savedPaymentMethods\":[\"paymentMethodsChanged\"]}],[0,\"justifi-new-payment-method\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"clientId\":[1,\"client-id\"],\"accountId\":[1,\"account-id\"],\"paymentMethodOption\":[16],\"isSelected\":[4,\"is-selected\"],\"getPaymentMethodToken\":[64]}],[0,\"justifi-saved-payment-method\",{\"iframeOrigin\":[1025,\"iframe-origin\"],\"paymentMethodOption\":[16],\"isSelected\":[4,\"is-selected\"],\"getPaymentMethodToken\":[64]}]]],[\"additional-questions-details_5\",[[1,\"additional-questions-details\",{\"additionalQuestions\":[16]}],[1,\"generic-info-details\",{\"business\":[16]}],[1,\"legal-address-details\",{\"legalAddress\":[16]}],[1,\"owner-details\",{\"owners\":[16]}],[1,\"representative-details\",{\"representative\":[16]}]]]]"), options);
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
export { defineCustomElements };
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
import { a as create$6, c as create$3 } from './index.esm-22b47398.js';
|
|
2
|
+
import { S as StateOptions } from './state-options-a356fb11.js';
|
|
3
|
+
|
|
4
|
+
const phoneRegex = /^\d{10}$/;
|
|
5
|
+
const urlRegex = /^(?:http(s)?:\/\/)?(?:www\.)?[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&//=]*)$/;
|
|
6
|
+
|
|
7
|
+
const lineOneValidation = create$6()
|
|
8
|
+
.min(5, 'Address must be at least 5 characters')
|
|
9
|
+
.max(100, 'Address must be less than 100 characters')
|
|
10
|
+
.matches(/^(?!^\s+$)[a-zA-Z0-9\s,.'-]*$/, 'Invalid characters in address')
|
|
11
|
+
.transform((value) => {
|
|
12
|
+
return value === '' ? null : value;
|
|
13
|
+
});
|
|
14
|
+
const lineTwoValidation = create$6()
|
|
15
|
+
.max(100, 'Address must be less than 100 characters')
|
|
16
|
+
.matches(/^(?!^\s+$)[a-zA-Z0-9\s,.'-]*$/, 'Invalid characters in address')
|
|
17
|
+
.transform((value) => {
|
|
18
|
+
return value === '' ? null : value;
|
|
19
|
+
});
|
|
20
|
+
const cityValidation = create$6()
|
|
21
|
+
.min(2, 'City must be at least 2 characters')
|
|
22
|
+
.max(50, 'City must be less than 50 characters')
|
|
23
|
+
.matches(/^(?!^\s+$)[a-zA-Z\s]*$/, 'Invalid characters in city')
|
|
24
|
+
.transform((value) => {
|
|
25
|
+
return value === '' ? null : value;
|
|
26
|
+
});
|
|
27
|
+
const stateValidation = create$6()
|
|
28
|
+
.oneOf(StateOptions.map((option) => option.value), 'Select state')
|
|
29
|
+
.transform((value) => {
|
|
30
|
+
return value === '' ? null : value;
|
|
31
|
+
});
|
|
32
|
+
const postalValidation = create$6()
|
|
33
|
+
.matches(/^[0-9]{5}$/, 'Enter valid postal code')
|
|
34
|
+
.transform((value) => {
|
|
35
|
+
return value === '' ? null : value;
|
|
36
|
+
});
|
|
37
|
+
const addressSchema = (allowOptionalFields) => {
|
|
38
|
+
const schema = create$3({
|
|
39
|
+
line1: lineOneValidation.required('Enter street address'),
|
|
40
|
+
line2: lineTwoValidation.nullable(),
|
|
41
|
+
city: cityValidation.required('Enter city'),
|
|
42
|
+
state: stateValidation.required('Select state'),
|
|
43
|
+
postal_code: postalValidation.required('Enter postal code'),
|
|
44
|
+
country: create$6().required('Select country')
|
|
45
|
+
});
|
|
46
|
+
const easySchema = create$3({
|
|
47
|
+
line1: lineOneValidation.nullable(),
|
|
48
|
+
line2: lineTwoValidation.nullable(),
|
|
49
|
+
city: cityValidation.nullable(),
|
|
50
|
+
state: stateValidation.nullable(),
|
|
51
|
+
postal_code: postalValidation.nullable(),
|
|
52
|
+
country: create$6().required('Select country')
|
|
53
|
+
});
|
|
54
|
+
return allowOptionalFields ? easySchema : schema;
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
const identitySchema = (title, allowOptionalFields) => {
|
|
58
|
+
const schema = create$3({
|
|
59
|
+
name: create$6().required(`Enter ${title} name`),
|
|
60
|
+
email: create$6()
|
|
61
|
+
.email(`Enter valid ${title} email`)
|
|
62
|
+
.required(`Enter ${title} email`),
|
|
63
|
+
phone: create$6().matches(phoneRegex, 'Enter valid phone number').required('Enter phone number'),
|
|
64
|
+
dob_day: create$6().required(`Enter ${title} birth day`),
|
|
65
|
+
dob_month: create$6().required(`Enter ${title} birth month`),
|
|
66
|
+
dob_year: create$6().required(`Enter ${title} birth year`),
|
|
67
|
+
identification_number: create$6(),
|
|
68
|
+
address: addressSchema(allowOptionalFields),
|
|
69
|
+
});
|
|
70
|
+
const easySchema = create$3({
|
|
71
|
+
name: create$6().required(`Enter ${title} name`),
|
|
72
|
+
email: create$6()
|
|
73
|
+
.email(`Enter valid ${title} email`)
|
|
74
|
+
.nullable(),
|
|
75
|
+
phone: create$6().matches(phoneRegex, 'Enter valid phone number').nullable(),
|
|
76
|
+
dob_day: create$6().nullable(),
|
|
77
|
+
dob_month: create$6().nullable(),
|
|
78
|
+
dob_year: create$6().nullable(),
|
|
79
|
+
identification_number: create$6().nullable(),
|
|
80
|
+
address: addressSchema(allowOptionalFields),
|
|
81
|
+
});
|
|
82
|
+
return allowOptionalFields ? easySchema : schema;
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
// These props should not be sent to the server
|
|
86
|
+
// This function is for the larger business form.
|
|
87
|
+
const parseBusiness = (values, initialValues) => {
|
|
88
|
+
var _a;
|
|
89
|
+
parseCoreInfo(values);
|
|
90
|
+
parseAddressInfo(values.legal_address);
|
|
91
|
+
parseIdentityInfo(values.representative);
|
|
92
|
+
((_a = initialValues.owners) === null || _a === void 0 ? void 0 : _a.length) && delete values.owners;
|
|
93
|
+
return values;
|
|
94
|
+
};
|
|
95
|
+
// These functions are for the stepped business form.
|
|
96
|
+
const parseCoreInfo = (values) => {
|
|
97
|
+
delete values.id;
|
|
98
|
+
delete values.documents;
|
|
99
|
+
delete values.bank_accounts;
|
|
100
|
+
delete values.product_categories;
|
|
101
|
+
delete values.created_at;
|
|
102
|
+
delete values.updated_at;
|
|
103
|
+
return values;
|
|
104
|
+
};
|
|
105
|
+
const parseAddressInfo = (values) => {
|
|
106
|
+
delete values.id;
|
|
107
|
+
delete values.created_at;
|
|
108
|
+
delete values.updated_at;
|
|
109
|
+
return values;
|
|
110
|
+
};
|
|
111
|
+
const parseIdentityInfo = (values) => {
|
|
112
|
+
delete values.id;
|
|
113
|
+
delete values.documents;
|
|
114
|
+
delete values.created_at;
|
|
115
|
+
delete values.updated_at;
|
|
116
|
+
delete values.address.id;
|
|
117
|
+
delete values.address.created_at;
|
|
118
|
+
delete values.address.updated_at;
|
|
119
|
+
delete values.business_id;
|
|
120
|
+
return values;
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
export { addressSchema as a, phoneRegex as b, parseCoreInfo as c, parseIdentityInfo as d, parseAddressInfo as e, identitySchema as i, parseBusiness as p, urlRegex as u };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-df86d9a2.js';
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-df86d9a2.js';
|
|
2
2
|
import { i as MapPaymentStatusToBadge, b as formatCurrency, f as formatDate, a as formatTime, s as snakeCaseToHumanReadable } from './utils-d9e90399.js';
|
|
3
3
|
import { a as EntityHeadInfo, b as EntityHeadInfoItem, c as DetailSectionTitle, D as DetailItem, C as CodeBlock, E as ErrorState, L as LoadingState } from './utils-d01c5f3a.js';
|
|
4
4
|
import './state-options-a356fb11.js';
|
|
@@ -8,6 +8,7 @@ const paymentDetailsCss = ":root,[data-bs-theme=light]{--bs-blue:#0d6efd;--bs-in
|
|
|
8
8
|
const PaymentDetailsCore = class {
|
|
9
9
|
constructor(hostRef) {
|
|
10
10
|
registerInstance(this, hostRef);
|
|
11
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
11
12
|
this.getPaymentDetails = undefined;
|
|
12
13
|
this.payment = undefined;
|
|
13
14
|
this.loading = true;
|
|
@@ -29,8 +30,13 @@ const PaymentDetailsCore = class {
|
|
|
29
30
|
this.loading = false;
|
|
30
31
|
this.errorMessage = null;
|
|
31
32
|
},
|
|
32
|
-
onError: (error) => {
|
|
33
|
+
onError: ({ error, code, severity }) => {
|
|
33
34
|
this.errorMessage = error;
|
|
35
|
+
this.errorEvent.emit({
|
|
36
|
+
errorCode: code,
|
|
37
|
+
message: error,
|
|
38
|
+
severity,
|
|
39
|
+
});
|
|
34
40
|
this.loading = false;
|
|
35
41
|
},
|
|
36
42
|
});
|
|
@@ -11,6 +11,7 @@ const PaymentsListCore = class {
|
|
|
11
11
|
constructor(hostRef) {
|
|
12
12
|
registerInstance(this, hostRef);
|
|
13
13
|
this.rowClicked = createEvent(this, "payment-row-clicked", 7);
|
|
14
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
14
15
|
this.handleClickPrevious = (beforeCursor) => {
|
|
15
16
|
const newParams = Object.assign({}, this.params);
|
|
16
17
|
delete newParams.after_cursor;
|
|
@@ -45,8 +46,13 @@ const PaymentsListCore = class {
|
|
|
45
46
|
this.paging = pagingInfo;
|
|
46
47
|
this.loading = false;
|
|
47
48
|
},
|
|
48
|
-
onError: (
|
|
49
|
-
this.errorMessage =
|
|
49
|
+
onError: ({ error, code, severity }) => {
|
|
50
|
+
this.errorMessage = error;
|
|
51
|
+
this.errorEvent.emit({
|
|
52
|
+
errorCode: code,
|
|
53
|
+
message: error,
|
|
54
|
+
severity,
|
|
55
|
+
});
|
|
50
56
|
this.loading = false;
|
|
51
57
|
},
|
|
52
58
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-df86d9a2.js';
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-df86d9a2.js';
|
|
2
2
|
import { j as MapPayoutStatusToBadge, b as formatCurrency, f as formatDate, a as formatTime } from './utils-d9e90399.js';
|
|
3
3
|
import { a as EntityHeadInfo, b as EntityHeadInfoItem, c as DetailSectionTitle, D as DetailItem, C as CodeBlock, E as ErrorState, L as LoadingState } from './utils-d01c5f3a.js';
|
|
4
4
|
import './state-options-a356fb11.js';
|
|
@@ -8,6 +8,7 @@ const payoutDetailsCss = ":root,[data-bs-theme=light]{--bs-blue:#0d6efd;--bs-ind
|
|
|
8
8
|
const PayoutDetailsCore = class {
|
|
9
9
|
constructor(hostRef) {
|
|
10
10
|
registerInstance(this, hostRef);
|
|
11
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
11
12
|
this.getPayout = undefined;
|
|
12
13
|
this.payout = undefined;
|
|
13
14
|
this.loading = true;
|
|
@@ -29,9 +30,13 @@ const PayoutDetailsCore = class {
|
|
|
29
30
|
this.payout = payout;
|
|
30
31
|
this.loading = false;
|
|
31
32
|
},
|
|
32
|
-
onError: (
|
|
33
|
-
this.errorMessage =
|
|
34
|
-
|
|
33
|
+
onError: ({ error, code, severity }) => {
|
|
34
|
+
this.errorMessage = error;
|
|
35
|
+
this.errorEvent.emit({
|
|
36
|
+
message: error,
|
|
37
|
+
errorCode: code,
|
|
38
|
+
severity,
|
|
39
|
+
});
|
|
35
40
|
this.loading = false;
|
|
36
41
|
},
|
|
37
42
|
});
|
|
@@ -12,6 +12,7 @@ const PayoutsListCore = class {
|
|
|
12
12
|
constructor(hostRef) {
|
|
13
13
|
registerInstance(this, hostRef);
|
|
14
14
|
this.rowClicked = createEvent(this, "payout-row-clicked", 7);
|
|
15
|
+
this.errorEvent = createEvent(this, "error-event", 7);
|
|
15
16
|
this.mapStatusToBadge = (status) => {
|
|
16
17
|
switch (status) {
|
|
17
18
|
case PayoutStatuses.scheduled:
|
|
@@ -62,8 +63,13 @@ const PayoutsListCore = class {
|
|
|
62
63
|
this.paging = pagingInfo;
|
|
63
64
|
this.loading = false;
|
|
64
65
|
},
|
|
65
|
-
onError: (
|
|
66
|
-
this.errorMessage =
|
|
66
|
+
onError: ({ error, code, severity }) => {
|
|
67
|
+
this.errorMessage = error;
|
|
68
|
+
this.errorEvent.emit({
|
|
69
|
+
errorCode: code,
|
|
70
|
+
message: error,
|
|
71
|
+
severity
|
|
72
|
+
});
|
|
67
73
|
this.loading = false;
|
|
68
74
|
},
|
|
69
75
|
});
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
var ComponentErrorCodes;
|
|
2
|
+
(function (ComponentErrorCodes) {
|
|
3
|
+
ComponentErrorCodes["MISSING_PROPS"] = "missing-props";
|
|
4
|
+
ComponentErrorCodes["FETCH_ERROR"] = "fetch-error";
|
|
5
|
+
ComponentErrorCodes["UNKNOWN_ERROR"] = "unknown-error";
|
|
6
|
+
ComponentErrorCodes["TOKENIZE_ERROR"] = "tokenize-error";
|
|
7
|
+
ComponentErrorCodes["NOT_AUTHENTICATED"] = "not-authenticated";
|
|
8
|
+
})(ComponentErrorCodes || (ComponentErrorCodes = {}));
|
|
9
|
+
var ComponentErrorSeverity;
|
|
10
|
+
(function (ComponentErrorSeverity) {
|
|
11
|
+
ComponentErrorSeverity["INFO"] = "info";
|
|
12
|
+
ComponentErrorSeverity["WARNING"] = "warning";
|
|
13
|
+
ComponentErrorSeverity["ERROR"] = "error";
|
|
14
|
+
})(ComponentErrorSeverity || (ComponentErrorSeverity = {}));
|
|
15
|
+
|
|
16
|
+
// Errors on [capital]/config/locales/en.yml
|
|
17
|
+
// Add more errors as needed
|
|
18
|
+
const API_ERRORS = {
|
|
19
|
+
NOT_AUTHENTICATED: 'not_authenticated',
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
const getErrorMessage = (error) => {
|
|
23
|
+
if (typeof error === 'string') {
|
|
24
|
+
return error;
|
|
25
|
+
}
|
|
26
|
+
return error.message;
|
|
27
|
+
};
|
|
28
|
+
const getErrorCode = (code) => {
|
|
29
|
+
switch (code) {
|
|
30
|
+
case API_ERRORS.NOT_AUTHENTICATED:
|
|
31
|
+
return ComponentErrorCodes.NOT_AUTHENTICATED;
|
|
32
|
+
// add more cases as needed
|
|
33
|
+
default:
|
|
34
|
+
return ComponentErrorCodes.FETCH_ERROR;
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export { ComponentErrorSeverity as C, getErrorCode as a, ComponentErrorCodes as b, getErrorMessage as g };
|
|
@@ -6,5 +6,11 @@ const FormAlert = (message) => (h("div", { class: 'alert alert-danger d-flex ali
|
|
|
6
6
|
h("div", null, message)));
|
|
7
7
|
const LoadingSpinner = () => (h("div", { class: "spinner-border spinner-border-sm", role: "status" },
|
|
8
8
|
h("span", { class: "visually-hidden" }, "Loading...")));
|
|
9
|
+
const filterPostalInput = (e) => {
|
|
10
|
+
const specialKeys = ['Backspace', 'Tab', 'Enter'];
|
|
11
|
+
if (!/^\d$/.test(e.key) && !specialKeys.includes(e.key)) {
|
|
12
|
+
e.preventDefault();
|
|
13
|
+
}
|
|
14
|
+
};
|
|
9
15
|
|
|
10
|
-
export { FormAlert as F, LoadingSpinner as L };
|
|
16
|
+
export { FormAlert as F, LoadingSpinner as L, filterPostalInput as f };
|