@justifi/webcomponents 4.11.0 → 4.12.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-7ae04d4f.js → Business-f8e37adb.js} +34 -27
- package/dist/cjs/{Payment-89a8bc21.js → Payment-eceed10f.js} +1 -0
- package/dist/cjs/{SubAccount-05867651.js → SubAccount-b3902202.js} +1 -1
- package/dist/cjs/additional-questions-details_5.cjs.entry.js +5 -6
- package/dist/cjs/business-additional-questions-schema-bdfd29c3.js +78 -0
- package/dist/cjs/business-details-core.cjs.entry.js +2 -2
- package/dist/cjs/{business-form-types-29b2bad9.js → business-form-types-61b8196a.js} +26 -0
- package/dist/cjs/{form-control-datepart_4.cjs.entry.js → form-control-date_4.cjs.entry.js} +18 -51
- package/dist/cjs/form-control-datepart.cjs.entry.js +80 -0
- package/dist/cjs/form-control-monetary.cjs.entry.js +1 -1
- package/dist/cjs/form-control-select_2.cjs.entry.js +1 -1
- package/dist/cjs/{form-input-masks-e3bf2614.js → form-input-masks-baa06faf.js} +1 -1
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +3 -4
- package/dist/cjs/{index-69b9386b.js → index-5d5f2219.js} +3 -0
- package/dist/cjs/justifi-additional-questions-form-step_5.cjs.entry.js +20 -12
- package/dist/cjs/justifi-additional-questions_4.cjs.entry.js +17 -16
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +1 -1
- package/dist/cjs/justifi-billing-form_4.cjs.entry.js +5 -5
- package/dist/cjs/justifi-business-details.cjs.entry.js +3 -4
- package/dist/cjs/justifi-business-form.cjs.entry.js +20 -12
- package/dist/cjs/justifi-business-list.cjs.entry.js +4 -6
- package/dist/cjs/justifi-business-owners.cjs.entry.js +2 -2
- package/dist/cjs/justifi-card-form.cjs.entry.js +1 -1
- package/dist/cjs/justifi-checkout-core.cjs.entry.js +34 -24
- package/dist/cjs/justifi-checkout.cjs.entry.js +14 -10
- package/dist/cjs/justifi-details.cjs.entry.js +2 -2
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +2 -2
- package/dist/cjs/{justifi-new-payment-method_3.cjs.entry.js → justifi-new-payment-method_4.cjs.entry.js} +95 -11
- package/dist/cjs/justifi-owner-form.cjs.entry.js +30 -16
- package/dist/cjs/justifi-payment-balance-transactions.cjs.entry.js +3 -4
- package/dist/cjs/justifi-payment-details.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payment-form.cjs.entry.js +3 -4
- package/dist/cjs/justifi-payment-method-selector.cjs.entry.js +2 -2
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +11 -4
- package/dist/cjs/justifi-payments-list.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payout-details.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +4 -4
- package/dist/cjs/justifi-proceeds-list.cjs.entry.js +3 -4
- package/dist/cjs/justifi-refund-form.cjs.entry.js +2 -2
- package/dist/cjs/justifi-subaccount-details.cjs.entry.js +5 -6
- package/dist/cjs/justifi-subaccounts-list.cjs.entry.js +4 -5
- package/dist/cjs/justifi-table_2.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{payload-parsers-f437272e.js → payload-parsers-32c43c76.js} +36 -24
- package/dist/cjs/payment-details-core.cjs.entry.js +3 -4
- package/dist/cjs/{payment.service-0b0086dc.js → payment.service-9db24ab9.js} +1 -1
- package/dist/cjs/payments-list-core.cjs.entry.js +3 -4
- package/dist/cjs/payout-details-core.cjs.entry.js +3 -4
- package/dist/cjs/{payout.service-5cc3b4e9.js → payout.service-a0efb71a.js} +1 -1
- package/dist/cjs/payouts-list-core.cjs.entry.js +3 -4
- package/dist/cjs/subaccount-account-details_4.cjs.entry.js +5 -6
- package/dist/cjs/subaccount-bank-details.cjs.entry.js +2 -2
- package/dist/cjs/subaccount-terms-details.cjs.entry.js +2 -2
- package/dist/cjs/{utils-23e70ef2.js → utils-6e35fa70.js} +1 -1
- package/dist/cjs/{utils-2b9940e1.js → utils-6f62f7a1.js} +0 -7
- package/dist/cjs/{utils-87435719.js → utils-fc72268d.js} +1 -1
- package/dist/cjs/webcomponents.cjs.js +2 -2
- package/dist/collection/api/Business.js +2 -20
- package/dist/collection/api/Checkout.js +6 -1
- package/dist/collection/api/Identity.js +7 -4
- package/dist/collection/api/Payment.js +1 -0
- package/dist/collection/api/services/checkout.service.js +7 -3
- package/dist/collection/collection-manifest.json +2 -0
- package/dist/collection/components/business-details/generic-info-details/generic-info-details.js +2 -2
- package/dist/collection/components/business-forms/business-form/business-core-info/business-core-info.js +2 -2
- package/dist/collection/components/business-forms/business-form/business-form.js +48 -3
- package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +12 -9
- package/dist/collection/components/business-forms/owner-form/owner-form.js +24 -8
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +2 -3
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +11 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning.js +42 -1
- package/dist/collection/components/business-forms/schemas/business-address-schema.js +9 -18
- package/dist/collection/components/business-forms/schemas/business-core-info-schema.js +48 -17
- package/dist/collection/components/business-forms/schemas/business-form-schema.js +1 -1
- package/dist/collection/components/business-forms/schemas/business-identity-schema.js +18 -7
- package/dist/collection/components/business-forms/schemas/schema-helpers.js +8 -0
- package/dist/collection/components/business-forms/utils/business-form-types.js +23 -0
- package/dist/collection/components/business-forms/utils/helpers.js +22 -2
- package/dist/collection/components/business-forms/utils/payload-parsers.js +1 -0
- package/dist/collection/components/business-list/business-list.js +0 -2
- package/dist/collection/components/checkout/checkout-actions.js +2 -2
- package/dist/collection/components/checkout/checkout-core.css +361 -0
- package/dist/collection/components/checkout/checkout-core.js +32 -27
- package/dist/collection/components/checkout/checkout.js +5 -5
- package/dist/collection/components/checkout/new-payment-method.js +12 -6
- package/dist/collection/components/checkout/payment-method-options.css +18 -2
- package/dist/collection/components/checkout/payment-method-options.js +62 -5
- package/dist/collection/components/checkout/payment-method-payload.js +1 -0
- package/dist/collection/components/checkout/saved-payment-method.js +11 -6
- package/dist/collection/components/checkout/sezzel-payment-method.js +247 -0
- package/dist/collection/components/form/form-control-date.css +1803 -0
- package/dist/collection/components/form/form-control-date.js +192 -0
- package/dist/collection/components/payment-form/payment-method-selector.js +1 -1
- package/dist/collection/components/payment-method-form/payment-method-form.js +1 -1
- package/dist/collection/components/select-input/select-input.js +1 -1
- package/dist/collection/components/select-input/test/select-input.spec.js +4 -4
- package/dist/collection/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.js +3 -3
- package/dist/collection/components/text-input/test/text-input.spec.js +4 -4
- package/dist/collection/components/text-input/text-input.js +1 -1
- package/dist/collection/utils/form-input-masks.js +1 -1
- package/dist/collection/utils/utils.js +0 -5
- package/dist/docs.json +670 -93
- package/dist/esm/{Business-91caaccb.js → Business-2410f7e3.js} +31 -25
- package/dist/esm/{Payment-55886c86.js → Payment-ef9fc1ae.js} +1 -0
- package/dist/esm/{SubAccount-61ac70eb.js → SubAccount-f4ae9809.js} +1 -1
- package/dist/esm/additional-questions-details_5.entry.js +5 -6
- package/dist/esm/business-additional-questions-schema-5571d40f.js +75 -0
- package/dist/esm/business-details-core.entry.js +2 -2
- package/dist/esm/{business-form-types-0d76133c.js → business-form-types-46ecd908.js} +25 -1
- package/dist/esm/{form-control-datepart_4.entry.js → form-control-date_4.entry.js} +18 -51
- package/dist/esm/form-control-datepart.entry.js +76 -0
- package/dist/esm/form-control-monetary.entry.js +1 -1
- package/dist/esm/form-control-select_2.entry.js +1 -1
- package/dist/esm/{form-input-masks-a8187c77.js → form-input-masks-850c8cd4.js} +1 -1
- package/dist/esm/gross-payment-chart-core.entry.js +3 -4
- package/dist/esm/{index-df86d9a2.js → index-83dcf934.js} +3 -0
- package/dist/esm/justifi-additional-questions-form-step_5.entry.js +20 -12
- package/dist/esm/justifi-additional-questions_4.entry.js +17 -16
- package/dist/esm/justifi-bank-account-form.entry.js +1 -1
- package/dist/esm/justifi-billing-form_4.entry.js +5 -5
- package/dist/esm/justifi-business-details.entry.js +3 -4
- package/dist/esm/justifi-business-form.entry.js +20 -12
- package/dist/esm/justifi-business-list.entry.js +4 -6
- package/dist/esm/justifi-business-owners.entry.js +2 -2
- package/dist/esm/justifi-card-form.entry.js +1 -1
- package/dist/esm/justifi-checkout-core.entry.js +34 -24
- package/dist/esm/justifi-checkout.entry.js +14 -10
- package/dist/esm/justifi-details.entry.js +2 -2
- package/dist/esm/justifi-gross-payment-chart.entry.js +2 -2
- package/dist/esm/{justifi-new-payment-method_3.entry.js → justifi-new-payment-method_4.entry.js} +95 -12
- package/dist/esm/justifi-owner-form.entry.js +30 -16
- package/dist/esm/justifi-payment-balance-transactions.entry.js +3 -4
- package/dist/esm/justifi-payment-details.entry.js +4 -4
- package/dist/esm/justifi-payment-form.entry.js +3 -4
- package/dist/esm/justifi-payment-method-selector.entry.js +2 -2
- package/dist/esm/justifi-payment-provisioning.entry.js +11 -4
- package/dist/esm/justifi-payments-list.entry.js +4 -4
- package/dist/esm/justifi-payout-details.entry.js +4 -4
- package/dist/esm/justifi-payouts-list.entry.js +4 -4
- package/dist/esm/justifi-proceeds-list.entry.js +3 -4
- package/dist/esm/justifi-refund-form.entry.js +2 -2
- package/dist/esm/justifi-subaccount-details.entry.js +5 -6
- package/dist/esm/justifi-subaccounts-list.entry.js +4 -5
- package/dist/esm/justifi-table_2.entry.js +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{payload-parsers-920f49dd.js → payload-parsers-192e0c3e.js} +33 -25
- package/dist/esm/payment-details-core.entry.js +3 -4
- package/dist/esm/{payment.service-f274ef98.js → payment.service-ec28a959.js} +1 -1
- package/dist/esm/payments-list-core.entry.js +3 -4
- package/dist/esm/payout-details-core.entry.js +3 -4
- package/dist/esm/{payout.service-af293f61.js → payout.service-5fd5986c.js} +1 -1
- package/dist/esm/payouts-list-core.entry.js +3 -4
- package/dist/esm/subaccount-account-details_4.entry.js +5 -6
- package/dist/esm/subaccount-bank-details.entry.js +2 -2
- package/dist/esm/subaccount-terms-details.entry.js +2 -2
- package/dist/esm/{utils-d01c5f3a.js → utils-210fdf39.js} +1 -1
- package/dist/esm/{utils-d9e90399.js → utils-243abdb4.js} +1 -7
- package/dist/esm/{utils-684d2e47.js → utils-6f05d9d7.js} +1 -1
- package/dist/esm/webcomponents.js +3 -3
- package/dist/module/Business.js +9 -25
- package/dist/module/Payment.js +1 -0
- package/dist/module/SubAccount.js +1 -1
- package/dist/module/business-address-schema.js +9 -18
- package/dist/module/business-core-info-form-step.js +2 -3
- package/dist/module/business-core-info-schema.js +49 -18
- package/dist/module/business-core-info.js +2 -2
- package/dist/module/business-form-types.js +25 -1
- package/dist/module/business-identity-schema.js +18 -7
- package/dist/module/business-owners-form-step.js +3 -3
- package/dist/module/business-representative-form-step.js +15 -5
- package/dist/module/business-representative.js +15 -12
- package/dist/module/checkout-core.js +50 -33
- package/dist/module/form-control-date.d.ts +11 -0
- package/dist/module/form-control-date.js +6 -0
- package/dist/module/form-control-date2.js +68 -0
- package/dist/module/form-input-masks.js +1 -1
- package/dist/module/generic-info-details2.js +2 -2
- package/dist/module/helpers.js +24 -3
- package/dist/module/justifi-business-details.js +1 -1
- package/dist/module/justifi-business-form.js +21 -10
- package/dist/module/justifi-business-list.js +1 -3
- package/dist/module/justifi-checkout.js +31 -21
- package/dist/module/justifi-payment-balance-transactions.js +1 -1
- package/dist/module/justifi-payment-provisioning.js +12 -5
- package/dist/module/justifi-sezzel-payment-method.d.ts +11 -0
- package/dist/module/justifi-sezzel-payment-method.js +6 -0
- package/dist/module/justifi-subaccount-details.js +1 -1
- package/dist/module/justifi-subaccounts-list.js +1 -1
- package/dist/module/legal-address-form-step.js +2 -2
- package/dist/module/new-payment-method.js +5 -4
- package/dist/module/owner-form.js +29 -13
- package/dist/module/payload-parsers.js +11 -1
- package/dist/module/payment-details-core2.js +1 -1
- package/dist/module/payment-method-form.js +1 -1
- package/dist/module/payment-method-options.js +34 -12
- package/dist/module/payments-list-core2.js +1 -1
- package/dist/module/payout-details-core2.js +1 -1
- package/dist/module/payouts-list-core2.js +1 -1
- package/dist/module/saved-payment-method.js +4 -4
- package/dist/module/select-input2.js +1 -1
- package/dist/module/sezzel-payment-method.js +99 -0
- package/dist/module/subaccount-merchant-details2.js +3 -3
- package/dist/module/text-input2.js +1 -1
- package/dist/module/utils2.js +1 -7
- package/dist/types/api/Business.d.ts +0 -19
- package/dist/types/api/Checkout.d.ts +63 -2
- package/dist/types/api/Identity.d.ts +2 -0
- package/dist/types/api/Payment.d.ts +2 -1
- package/dist/types/api/SubAccount.d.ts +0 -2
- package/dist/types/api/services/checkout.service.d.ts +8 -2
- package/dist/types/components/business-forms/business-form/business-form.d.ts +5 -0
- package/dist/types/components/business-forms/business-form/business-representative/business-representative.d.ts +3 -3
- package/dist/types/components/business-forms/owner-form/owner-form.d.ts +4 -2
- 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/payment-provisioning.d.ts +3 -0
- package/dist/types/components/business-forms/schemas/business-core-info-schema.d.ts +2 -2
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +4 -8
- package/dist/types/components/business-forms/schemas/business-identity-schema.d.ts +2 -6
- package/dist/types/components/business-forms/schemas/schema-helpers.d.ts +6 -0
- package/dist/types/components/business-forms/utils/business-form-types.d.ts +5 -0
- package/dist/types/components/business-forms/utils/helpers.d.ts +8 -2
- package/dist/types/components/checkout/checkout-actions.d.ts +3 -3
- package/dist/types/components/checkout/checkout-core.d.ts +5 -4
- package/dist/types/components/checkout/checkout.d.ts +1 -1
- package/dist/types/components/checkout/new-payment-method.d.ts +2 -1
- package/dist/types/components/checkout/payment-method-options.d.ts +5 -1
- package/dist/types/components/checkout/payment-method-payload.d.ts +8 -0
- package/dist/types/components/checkout/saved-payment-method.d.ts +2 -1
- package/dist/types/components/checkout/sezzel-payment-method.d.ts +23 -0
- package/dist/types/components/form/form-control-date.d.ts +18 -0
- package/dist/types/components.d.ts +112 -9
- package/dist/types/utils/utils.d.ts +0 -1
- package/dist/webcomponents/p-02fa533c.js +1 -0
- package/dist/webcomponents/p-0315876e.entry.js +1 -0
- package/dist/webcomponents/{p-28cd23c8.entry.js → p-0c269feb.entry.js} +1 -1
- package/dist/webcomponents/{p-0b76c770.entry.js → p-0eb56b44.entry.js} +1 -1
- package/dist/webcomponents/{p-436d27b9.entry.js → p-0eb77101.entry.js} +1 -1
- package/dist/webcomponents/p-1334f776.entry.js +1 -0
- package/dist/webcomponents/p-19001cc5.entry.js +1 -0
- package/dist/webcomponents/p-2319abaf.entry.js +1 -0
- package/dist/webcomponents/p-26fe62d6.entry.js +1 -0
- package/dist/webcomponents/p-28b38699.js +1 -0
- package/dist/webcomponents/{p-4df6174c.entry.js → p-29376518.entry.js} +1 -1
- package/dist/webcomponents/p-2bee72bd.entry.js +1 -0
- package/dist/webcomponents/p-3302bc76.js +1 -0
- package/dist/webcomponents/p-3adc0688.entry.js +1 -0
- package/dist/webcomponents/p-3fe05c4a.entry.js +1 -0
- package/dist/webcomponents/p-41b1ad3a.entry.js +1 -0
- package/dist/webcomponents/{p-7c6a355f.entry.js → p-4616768c.entry.js} +1 -1
- package/dist/webcomponents/p-56780f10.entry.js +1 -0
- package/dist/webcomponents/p-5c269619.js +1 -0
- package/dist/webcomponents/p-5ff7826e.entry.js +1 -0
- package/dist/webcomponents/{p-8482c23f.js → p-65510838.js} +1 -1
- package/dist/webcomponents/{p-4d50d08a.entry.js → p-7d8d2984.entry.js} +1 -1
- package/dist/webcomponents/p-7da249b8.entry.js +1 -0
- package/dist/webcomponents/p-84b9ffc9.entry.js +1 -0
- package/dist/webcomponents/{p-07b326d0.entry.js → p-8657128b.entry.js} +1 -1
- package/dist/webcomponents/p-8abba4c2.entry.js +1 -0
- package/dist/webcomponents/p-8c9d9812.entry.js +1 -0
- package/dist/webcomponents/p-910bb656.js +1 -0
- package/dist/webcomponents/p-9245777b.js +1 -0
- package/dist/webcomponents/{p-221b9504.entry.js → p-927150b4.entry.js} +1 -1
- package/dist/webcomponents/p-96cebc8b.entry.js +1 -0
- package/dist/webcomponents/p-99d6b67e.entry.js +1 -0
- package/dist/webcomponents/p-9e3f9e05.entry.js +1 -0
- package/dist/webcomponents/{p-688bb5da.js → p-9ee8ad4d.js} +1 -1
- package/dist/webcomponents/{p-a46174e0.entry.js → p-9f3facf1.entry.js} +1 -1
- package/dist/webcomponents/p-9f529959.entry.js +1 -0
- package/dist/webcomponents/{p-fb49ef28.entry.js → p-a6f170ba.entry.js} +1 -1
- package/dist/webcomponents/{p-c071d8c1.entry.js → p-a8caec98.entry.js} +1 -1
- package/dist/webcomponents/p-a90f7ca0.js +1 -0
- package/dist/webcomponents/{p-d776fe10.entry.js → p-abc03d5a.entry.js} +1 -1
- package/dist/webcomponents/p-b318b899.js +1 -0
- package/dist/webcomponents/{p-1bfadb9f.entry.js → p-c1b92cec.entry.js} +1 -1
- package/dist/webcomponents/p-c556deda.entry.js +1 -0
- package/dist/webcomponents/{p-3d4aaa4a.entry.js → p-c6e207f6.entry.js} +1 -1
- package/dist/webcomponents/{p-b68f1dd9.entry.js → p-cdfde1ca.entry.js} +1 -1
- package/dist/webcomponents/{p-746bfba6.entry.js → p-d69a485a.entry.js} +1 -1
- package/dist/webcomponents/p-e2ba8d84.entry.js +1 -0
- package/dist/webcomponents/{p-ebf7c70f.entry.js → p-e4342f49.entry.js} +1 -1
- package/dist/webcomponents/{p-ea2cca2a.js → p-ed72a5cc.js} +1 -1
- package/dist/webcomponents/{p-6b51cf97.entry.js → p-f0698778.entry.js} +1 -1
- package/dist/webcomponents/p-f4ae621e.entry.js +1 -0
- package/dist/webcomponents/{p-ae21ed6f.entry.js → p-f76283a5.entry.js} +1 -1
- package/dist/webcomponents/p-fce2b224.entry.js +1 -0
- package/dist/webcomponents/p-fd60d5af.js +1 -0
- package/dist/webcomponents/p-ff211f76.js +1 -0
- package/dist/webcomponents/webcomponents.css +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/business-additional-questions-schema-18a82d19.js +0 -47
- package/dist/cjs/business-form-select-options-7ccd8dca.js +0 -85
- package/dist/collection/components/business-forms/utils/business-form-select-options.js +0 -80
- package/dist/esm/business-additional-questions-schema-b642a2b7.js +0 -44
- package/dist/esm/business-form-select-options-6b9293fe.js +0 -82
- package/dist/module/business-form-select-options.js +0 -82
- package/dist/types/components/business-forms/utils/business-form-select-options.d.ts +0 -11
- package/dist/webcomponents/p-091f9732.entry.js +0 -1
- package/dist/webcomponents/p-0923e39c.js +0 -1
- package/dist/webcomponents/p-0d81883d.entry.js +0 -1
- package/dist/webcomponents/p-102b593a.entry.js +0 -1
- package/dist/webcomponents/p-2b8368d2.js +0 -1
- package/dist/webcomponents/p-2df32b4a.entry.js +0 -1
- package/dist/webcomponents/p-34352d04.js +0 -1
- package/dist/webcomponents/p-448063ba.entry.js +0 -1
- package/dist/webcomponents/p-5341321d.entry.js +0 -1
- package/dist/webcomponents/p-5b262705.entry.js +0 -1
- package/dist/webcomponents/p-5e503d7d.entry.js +0 -1
- package/dist/webcomponents/p-6047b960.entry.js +0 -1
- package/dist/webcomponents/p-60b2344a.js +0 -1
- package/dist/webcomponents/p-63296409.js +0 -1
- package/dist/webcomponents/p-6d39b8bc.entry.js +0 -1
- package/dist/webcomponents/p-7294eb89.entry.js +0 -1
- package/dist/webcomponents/p-7b2cddc7.js +0 -1
- package/dist/webcomponents/p-817211f2.entry.js +0 -1
- package/dist/webcomponents/p-935d6f55.js +0 -1
- package/dist/webcomponents/p-959250e3.entry.js +0 -1
- package/dist/webcomponents/p-975ab96e.js +0 -1
- package/dist/webcomponents/p-9b99370e.js +0 -1
- package/dist/webcomponents/p-a130a884.entry.js +0 -1
- package/dist/webcomponents/p-a4122c35.entry.js +0 -1
- package/dist/webcomponents/p-ac670a3e.js +0 -1
- package/dist/webcomponents/p-c340b60f.js +0 -1
- package/dist/webcomponents/p-d5aab6b5.entry.js +0 -1
- package/dist/webcomponents/p-d5c80489.entry.js +0 -1
- package/dist/webcomponents/p-d8679fad.entry.js +0 -1
- package/dist/webcomponents/p-da34bba7.entry.js +0 -1
- package/dist/webcomponents/p-e84b3616.entry.js +0 -1
- package/dist/webcomponents/p-ea03b424.entry.js +0 -1
- package/dist/webcomponents/p-ec230480.entry.js +0 -1
|
@@ -1,26 +1,57 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { a as create$6, c as create$3 } from './index.esm.js';
|
|
2
|
+
import { a as BusinessTypeOptions } from './business-form-types.js';
|
|
3
|
+
import { b as businessNameRegex, t as transformEmptyString, u as urlRegex, a as phoneRegex, s as stringLettersOnlyRegex, c as taxIdRegex } from './payload-parsers.js';
|
|
3
4
|
|
|
5
|
+
const nameValidation = create$6()
|
|
6
|
+
.min(2, 'Name must be at least 2 characters')
|
|
7
|
+
.max(100, 'Name must be less than 100 characters')
|
|
8
|
+
.matches(businessNameRegex, 'Enter valid business name')
|
|
9
|
+
.transform(transformEmptyString);
|
|
10
|
+
const doingBusinessAsValidation = create$6()
|
|
11
|
+
.min(2, 'Name must be at least 2 characters')
|
|
12
|
+
.max(100, 'Name must be less than 100 characters')
|
|
13
|
+
.matches(businessNameRegex, 'Enter valid doing business as')
|
|
14
|
+
.transform(transformEmptyString);
|
|
15
|
+
const websiteUrlValidation = create$6()
|
|
16
|
+
.matches(urlRegex, 'Enter valid website url')
|
|
17
|
+
.transform(transformEmptyString);
|
|
18
|
+
const emailValidation = create$6()
|
|
19
|
+
.email('Enter valid email')
|
|
20
|
+
.transform(transformEmptyString);
|
|
21
|
+
const phoneValidation = create$6()
|
|
22
|
+
.matches(phoneRegex, 'Enter valid phone number')
|
|
23
|
+
.transform(transformEmptyString);
|
|
24
|
+
const businessTypeValidation = create$6()
|
|
25
|
+
.oneOf(BusinessTypeOptions.map((option) => option.value), 'Select business type')
|
|
26
|
+
.transform(transformEmptyString);
|
|
27
|
+
const industryValidation = create$6()
|
|
28
|
+
.min(2, 'Industry must be at least 2 characters')
|
|
29
|
+
.max(50, 'Industry must be less than 50 characters')
|
|
30
|
+
.matches(stringLettersOnlyRegex, 'Enter valid industry')
|
|
31
|
+
.transform(transformEmptyString);
|
|
32
|
+
const taxIdValidation = create$6()
|
|
33
|
+
.matches(taxIdRegex, 'Enter valid tax id')
|
|
34
|
+
.transform(transformEmptyString);
|
|
4
35
|
const businessCoreInfoSchema = (allowOptionalFields) => {
|
|
5
36
|
const schema = create$3({
|
|
6
|
-
legal_name:
|
|
7
|
-
website_url:
|
|
8
|
-
email:
|
|
9
|
-
phone:
|
|
10
|
-
doing_business_as:
|
|
11
|
-
business_type:
|
|
12
|
-
|
|
13
|
-
|
|
37
|
+
legal_name: nameValidation.required('Enter legal name'),
|
|
38
|
+
website_url: websiteUrlValidation.required('Enter business website url'),
|
|
39
|
+
email: emailValidation.required('Enter business email'),
|
|
40
|
+
phone: phoneValidation.required('Enter phone number'),
|
|
41
|
+
doing_business_as: doingBusinessAsValidation.required('Enter doing business as'),
|
|
42
|
+
business_type: businessTypeValidation.required('Select business type'),
|
|
43
|
+
industry: industryValidation.required('Enter a business industry'),
|
|
44
|
+
tax_id: taxIdValidation.required('Enter tax id'),
|
|
14
45
|
});
|
|
15
46
|
const easySchema = create$3({
|
|
16
|
-
legal_name:
|
|
17
|
-
website_url:
|
|
18
|
-
email:
|
|
19
|
-
phone:
|
|
20
|
-
doing_business_as:
|
|
21
|
-
business_type:
|
|
22
|
-
|
|
23
|
-
|
|
47
|
+
legal_name: nameValidation.required('Enter legal name'),
|
|
48
|
+
website_url: websiteUrlValidation.nullable(),
|
|
49
|
+
email: emailValidation.nullable(),
|
|
50
|
+
phone: phoneValidation.nullable(),
|
|
51
|
+
doing_business_as: doingBusinessAsValidation.nullable(),
|
|
52
|
+
business_type: businessTypeValidation.nullable(),
|
|
53
|
+
industry: industryValidation.nullable(),
|
|
54
|
+
tax_id: taxIdValidation.nullable(),
|
|
24
55
|
});
|
|
25
56
|
return allowOptionalFields ? easySchema : schema;
|
|
26
57
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { a as BusinessTypeOptions } from './business-form-types.js';
|
|
3
3
|
import { T as TAX_ID_MASKS, P as PHONE_MASKS } from './form-input-masks.js';
|
|
4
4
|
import { C as CoreBusinessInfo } from './Business.js';
|
|
5
5
|
import { d as defineCustomElement$3 } from './form-control-number-masked2.js';
|
|
@@ -28,7 +28,7 @@ const BusinessCoreInfo = /*@__PURE__*/ proxyCustomElement(class BusinessCoreInfo
|
|
|
28
28
|
}
|
|
29
29
|
render() {
|
|
30
30
|
const coreInfoDefaultValue = this.formController.getInitialValues();
|
|
31
|
-
return (h(Host, { exportparts: "label,input,input-invalid" }, h("fieldset", null, h("legend", null, "General Info"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12
|
|
31
|
+
return (h(Host, { exportparts: "label,input,input-invalid" }, h("fieldset", null, h("legend", null, "General Info"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12" }, h("form-control-text", { name: "legal_name", label: "Legal Name", defaultValue: coreInfoDefaultValue.legal_name, error: this.errors.legal_name, inputHandler: this.inputHandler })), h("div", { class: "col-12" }, h("form-control-text", { name: "doing_business_as", label: "Doing Business As (DBA)", defaultValue: coreInfoDefaultValue.doing_business_as, error: this.errors.doing_business_as, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-select", { name: "business_type", label: "Business Type", options: BusinessTypeOptions, defaultValue: coreInfoDefaultValue.business_type, error: this.errors.business_type, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "industry", label: "Industry", defaultValue: coreInfoDefaultValue.industry, error: this.errors.industry, inputHandler: this.inputHandler })), h("div", { class: "col-12" }, h("form-control-number-masked", { name: "tax_id", label: "Tax ID", defaultValue: coreInfoDefaultValue.tax_id, error: this.errors.tax_id, inputHandler: this.inputHandler, mask: TAX_ID_MASKS.US })), h("div", { class: "col-12" }, h("form-control-text", { name: "website_url", label: "Website URL", defaultValue: coreInfoDefaultValue.website_url, error: this.errors.website_url, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "email", label: "Email Address", defaultValue: coreInfoDefaultValue.email, error: this.errors.email, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-number-masked", { name: "phone", label: "Phone Number", defaultValue: coreInfoDefaultValue.phone, error: this.errors.phone, inputHandler: this.inputHandler, mask: PHONE_MASKS.US }))))));
|
|
32
32
|
}
|
|
33
33
|
static get style() { return businessCoreInfoCss; }
|
|
34
34
|
}, [0, "justifi-business-core-info", {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { B as BusinessType } from './Business.js';
|
|
2
|
+
|
|
1
3
|
var BusinessFormServerErrors;
|
|
2
4
|
(function (BusinessFormServerErrors) {
|
|
3
5
|
BusinessFormServerErrors["fetchData"] = "Error retrieving business data";
|
|
@@ -22,5 +24,27 @@ var OwnerFormClickActions;
|
|
|
22
24
|
OwnerFormClickActions["addOwnerForm"] = "addOwnerForm";
|
|
23
25
|
OwnerFormClickActions["updateOwner"] = "updateOwner";
|
|
24
26
|
})(OwnerFormClickActions || (OwnerFormClickActions = {}));
|
|
27
|
+
const BusinessTypeOptions = [
|
|
28
|
+
{
|
|
29
|
+
label: 'Choose business type',
|
|
30
|
+
value: '',
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
label: 'Individual',
|
|
34
|
+
value: BusinessType.individual,
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
label: 'For Profit',
|
|
38
|
+
value: BusinessType.for_profit,
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
label: 'Non Profit',
|
|
42
|
+
value: BusinessType.non_profit,
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
label: 'Government Entity',
|
|
46
|
+
value: BusinessType.government_entity,
|
|
47
|
+
},
|
|
48
|
+
];
|
|
25
49
|
|
|
26
|
-
export { BusinessFormServerErrors as B, OwnerFormClickActions as O,
|
|
50
|
+
export { BusinessFormServerErrors as B, OwnerFormClickActions as O, BusinessTypeOptions as a, BusinessFormClickActions as b, OwnerFormServerErrors as c };
|
|
@@ -1,7 +1,22 @@
|
|
|
1
1
|
import { c as create$3, a as create$6 } from './index.esm.js';
|
|
2
2
|
import { a as addressSchema } from './business-address-schema.js';
|
|
3
|
-
import {
|
|
3
|
+
import { a as phoneRegex, t as transformEmptyString } from './payload-parsers.js';
|
|
4
4
|
|
|
5
|
+
const dobValidation = (title) => {
|
|
6
|
+
return (create$6()
|
|
7
|
+
.test('min', 'Enter a valid date', (value) => {
|
|
8
|
+
const date = new Date(value);
|
|
9
|
+
const minDate = new Date('1902-01-01');
|
|
10
|
+
return date >= minDate;
|
|
11
|
+
})
|
|
12
|
+
.test('age', `${title} must be at least 18 years old`, (value) => {
|
|
13
|
+
const date = new Date(value);
|
|
14
|
+
const minAgeDate = new Date();
|
|
15
|
+
minAgeDate.setFullYear(minAgeDate.getFullYear() - 18);
|
|
16
|
+
return date <= minAgeDate;
|
|
17
|
+
})
|
|
18
|
+
.transform(transformEmptyString));
|
|
19
|
+
};
|
|
5
20
|
const identitySchema = (title, allowOptionalFields) => {
|
|
6
21
|
const schema = create$3({
|
|
7
22
|
name: create$6().required(`Enter ${title} name`),
|
|
@@ -9,9 +24,7 @@ const identitySchema = (title, allowOptionalFields) => {
|
|
|
9
24
|
.email(`Enter valid ${title} email`)
|
|
10
25
|
.required(`Enter ${title} email`),
|
|
11
26
|
phone: create$6().matches(phoneRegex, 'Enter valid phone number').required('Enter phone number'),
|
|
12
|
-
|
|
13
|
-
dob_month: create$6().required(`Enter ${title} birth month`),
|
|
14
|
-
dob_year: create$6().required(`Enter ${title} birth year`),
|
|
27
|
+
dob_full: dobValidation(title).required('Enter date of birth'),
|
|
15
28
|
identification_number: create$6(),
|
|
16
29
|
address: addressSchema(allowOptionalFields),
|
|
17
30
|
});
|
|
@@ -21,9 +34,7 @@ const identitySchema = (title, allowOptionalFields) => {
|
|
|
21
34
|
.email(`Enter valid ${title} email`)
|
|
22
35
|
.nullable(),
|
|
23
36
|
phone: create$6().matches(phoneRegex, 'Enter valid phone number').nullable(),
|
|
24
|
-
|
|
25
|
-
dob_month: create$6().nullable(),
|
|
26
|
-
dob_year: create$6().nullable(),
|
|
37
|
+
dob_full: dobValidation(title).nullable('Enter date of birth'),
|
|
27
38
|
identification_number: create$6().nullable(),
|
|
28
39
|
address: addressSchema(allowOptionalFields),
|
|
29
40
|
});
|
|
@@ -6,7 +6,7 @@ import './Payout.js';
|
|
|
6
6
|
import { c as config } from './config.js';
|
|
7
7
|
import { O as Owner } from './Business.js';
|
|
8
8
|
import { B as BusinessFormServerErrors, O as OwnerFormClickActions } from './business-form-types.js';
|
|
9
|
-
import { d as defineCustomElement$7 } from './form-control-
|
|
9
|
+
import { d as defineCustomElement$7 } from './form-control-date2.js';
|
|
10
10
|
import { d as defineCustomElement$6 } from './form-control-number2.js';
|
|
11
11
|
import { d as defineCustomElement$5 } from './form-control-number-masked2.js';
|
|
12
12
|
import { d as defineCustomElement$4 } from './form-control-select2.js';
|
|
@@ -169,14 +169,14 @@ function defineCustomElement() {
|
|
|
169
169
|
if (typeof customElements === "undefined") {
|
|
170
170
|
return;
|
|
171
171
|
}
|
|
172
|
-
const components = ["justifi-business-owners-form-step", "form-control-
|
|
172
|
+
const components = ["justifi-business-owners-form-step", "form-control-date", "form-control-number", "form-control-number-masked", "form-control-select", "form-control-text", "justifi-identity-address-form", "justifi-owner-form"];
|
|
173
173
|
components.forEach(tagName => { switch (tagName) {
|
|
174
174
|
case "justifi-business-owners-form-step":
|
|
175
175
|
if (!customElements.get(tagName)) {
|
|
176
176
|
customElements.define(tagName, BusinessOwnersFormStep);
|
|
177
177
|
}
|
|
178
178
|
break;
|
|
179
|
-
case "form-control-
|
|
179
|
+
case "form-control-date":
|
|
180
180
|
if (!customElements.get(tagName)) {
|
|
181
181
|
defineCustomElement$7();
|
|
182
182
|
}
|
|
@@ -2,12 +2,13 @@ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/
|
|
|
2
2
|
import { F as FormController } from './form.js';
|
|
3
3
|
import { P as PHONE_MASKS } from './form-input-masks.js';
|
|
4
4
|
import { A as Api } from './Api.js';
|
|
5
|
-
import {
|
|
5
|
+
import { e as parseIdentityInfo } from './payload-parsers.js';
|
|
6
6
|
import { i as identitySchema } from './business-identity-schema.js';
|
|
7
7
|
import { c as config } from './config.js';
|
|
8
8
|
import { B as BusinessFormServerErrors } from './business-form-types.js';
|
|
9
9
|
import { R as Representative } from './Business.js';
|
|
10
|
-
import { d as
|
|
10
|
+
import { d as deconstructDate } from './helpers.js';
|
|
11
|
+
import { d as defineCustomElement$6 } from './form-control-date2.js';
|
|
11
12
|
import { d as defineCustomElement$5 } from './form-control-number2.js';
|
|
12
13
|
import { d as defineCustomElement$4 } from './form-control-number-masked2.js';
|
|
13
14
|
import { d as defineCustomElement$3 } from './form-control-select2.js';
|
|
@@ -57,6 +58,15 @@ const BusinessRepresentativeFormStep = /*@__PURE__*/ proxyCustomElement(class Bu
|
|
|
57
58
|
this.onAddressFormUpdate = (values) => {
|
|
58
59
|
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { address: Object.assign(Object.assign({}, this.formController.values.getValue().address), values) }));
|
|
59
60
|
};
|
|
61
|
+
this.onDateOfBirthUpdate = (event) => {
|
|
62
|
+
if (event.detail === '') {
|
|
63
|
+
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { dob_day: null, dob_month: null, dob_year: null }));
|
|
64
|
+
}
|
|
65
|
+
else {
|
|
66
|
+
const dob_values = deconstructDate(event.detail);
|
|
67
|
+
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { dob_day: dob_values.dob_day, dob_month: dob_values.dob_month, dob_year: dob_values.dob_year }));
|
|
68
|
+
}
|
|
69
|
+
};
|
|
60
70
|
this.authToken = undefined;
|
|
61
71
|
this.businessId = undefined;
|
|
62
72
|
this.allowOptionalFields = undefined;
|
|
@@ -97,7 +107,7 @@ const BusinessRepresentativeFormStep = /*@__PURE__*/ proxyCustomElement(class Bu
|
|
|
97
107
|
}
|
|
98
108
|
render() {
|
|
99
109
|
const representativeDefaultValue = this.formController.getInitialValues();
|
|
100
|
-
return (h(Host, { exportparts: "label,input,input-invalid" }, h("form", null, h("fieldset", null, h("legend", null, "Representative"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12 col-md-8" }, h("form-control-text", { name: "name", label: "Full Name", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.name, error: this.errors.name, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-4" }, h("form-control-text", { name: "title", label: "Title", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.title, error: this.errors.title, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "email", label: "Email Address", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.email, error: this.errors.email, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-number-masked", { name: "phone", label: "Phone Number", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.phone, error: this.errors.phone, inputHandler: this.inputHandler, mask: PHONE_MASKS.US })), h("div", { class: "col-12
|
|
110
|
+
return (h(Host, { exportparts: "label,input,input-invalid" }, h("form", null, h("fieldset", null, h("legend", null, "Representative"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12 col-md-8" }, h("form-control-text", { name: "name", label: "Full Name", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.name, error: this.errors.name, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-4" }, h("form-control-text", { name: "title", label: "Title", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.title, error: this.errors.title, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "email", label: "Email Address", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.email, error: this.errors.email, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-number-masked", { name: "phone", label: "Phone Number", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.phone, error: this.errors.phone, inputHandler: this.inputHandler, mask: PHONE_MASKS.US })), h("div", { class: "col-12 col-md-4" }, h("form-control-date", { name: "dob_full", label: "Birth Date", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.dob_full, error: this.errors.dob_full, inputHandler: this.inputHandler, onFormControlInput: this.onDateOfBirthUpdate })), h("div", { class: "col-12 col-md-8" }, h("form-control-number", { name: "identification_number", label: "SSN", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler })), h("div", { class: "col-12" }, h("justifi-identity-address-form", { errors: this.errors.address, defaultValues: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.address, handleFormUpdate: this.onAddressFormUpdate })))))));
|
|
101
111
|
}
|
|
102
112
|
static get style() { return businessRepresentativeFormStepCss; }
|
|
103
113
|
}, [0, "justifi-business-representative-form-step", {
|
|
@@ -113,14 +123,14 @@ function defineCustomElement() {
|
|
|
113
123
|
if (typeof customElements === "undefined") {
|
|
114
124
|
return;
|
|
115
125
|
}
|
|
116
|
-
const components = ["justifi-business-representative-form-step", "form-control-
|
|
126
|
+
const components = ["justifi-business-representative-form-step", "form-control-date", "form-control-number", "form-control-number-masked", "form-control-select", "form-control-text", "justifi-identity-address-form"];
|
|
117
127
|
components.forEach(tagName => { switch (tagName) {
|
|
118
128
|
case "justifi-business-representative-form-step":
|
|
119
129
|
if (!customElements.get(tagName)) {
|
|
120
130
|
customElements.define(tagName, BusinessRepresentativeFormStep);
|
|
121
131
|
}
|
|
122
132
|
break;
|
|
123
|
-
case "form-control-
|
|
133
|
+
case "form-control-date":
|
|
124
134
|
if (!customElements.get(tagName)) {
|
|
125
135
|
defineCustomElement$6();
|
|
126
136
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { P as PHONE_MASKS } from './form-input-masks.js';
|
|
3
|
-
import { d as
|
|
3
|
+
import { d as deconstructDate } from './helpers.js';
|
|
4
|
+
import { d as defineCustomElement$6 } from './form-control-date2.js';
|
|
4
5
|
import { d as defineCustomElement$5 } from './form-control-number2.js';
|
|
5
6
|
import { d as defineCustomElement$4 } from './form-control-number-masked2.js';
|
|
6
7
|
import { d as defineCustomElement$3 } from './form-control-select2.js';
|
|
@@ -13,25 +14,27 @@ const BusinessRepresentative = /*@__PURE__*/ proxyCustomElement(class BusinessRe
|
|
|
13
14
|
constructor() {
|
|
14
15
|
super();
|
|
15
16
|
this.__registerHost();
|
|
17
|
+
this.inputHandler = (name, value) => {
|
|
18
|
+
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { representative: Object.assign(Object.assign({}, this.formController.values.getValue().representative), { [name]: value }) }));
|
|
19
|
+
};
|
|
20
|
+
this.onAddressFormUpdate = (values) => {
|
|
21
|
+
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { representative: Object.assign(Object.assign({}, this.formController.values.getValue().representative), { address: Object.assign(Object.assign({}, this.formController.values.getValue().representative.address), values) }) }));
|
|
22
|
+
};
|
|
23
|
+
this.onDateOfBirthUpdate = (event) => {
|
|
24
|
+
const dob_values = deconstructDate(event.detail);
|
|
25
|
+
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { representative: Object.assign(Object.assign({}, this.formController.values.getValue().representative), { dob_day: dob_values.dob_day, dob_month: dob_values.dob_month, dob_year: dob_values.dob_year }) }));
|
|
26
|
+
};
|
|
16
27
|
this.formController = undefined;
|
|
17
28
|
this.errors = {};
|
|
18
29
|
this.representative = {};
|
|
19
|
-
this.inputHandler = this.inputHandler.bind(this);
|
|
20
|
-
this.onAddressFormUpdate = this.onAddressFormUpdate.bind(this);
|
|
21
30
|
}
|
|
22
31
|
componentDidLoad() {
|
|
23
32
|
this.formController.errors.subscribe(errors => (this.errors = Object.assign({}, errors.representative)));
|
|
24
33
|
this.formController.values.subscribe(values => (this.representative = Object.assign({}, values.representative)));
|
|
25
34
|
}
|
|
26
|
-
inputHandler(name, value) {
|
|
27
|
-
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { representative: Object.assign(Object.assign({}, this.formController.values.getValue().representative), { [name]: value }) }));
|
|
28
|
-
}
|
|
29
|
-
onAddressFormUpdate(values) {
|
|
30
|
-
this.formController.setValues(Object.assign(Object.assign({}, this.formController.values.getValue()), { representative: Object.assign(Object.assign({}, this.formController.values.getValue().representative), { address: Object.assign(Object.assign({}, this.formController.values.getValue().representative.address), values) }) }));
|
|
31
|
-
}
|
|
32
35
|
render() {
|
|
33
36
|
const representativeDefaultValue = this.formController.getInitialValues().representative;
|
|
34
|
-
return (h(Host, { exportparts: "label,input,input-invalid" }, h("fieldset", null, h("legend", null, "Representative"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12 col-md-8" }, h("form-control-text", { name: "name", label: "Full Name", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.name, error: this.errors.name, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-4" }, h("form-control-text", { name: "title", label: "Title", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.title, error: this.errors.title, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "email", label: "Email Address", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.email, error: this.errors.email, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-number-masked", { name: "phone", label: "Phone Number", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.phone, error: this.errors.phone, inputHandler: this.inputHandler, mask: PHONE_MASKS.US })), h("div", { class: "col-12
|
|
37
|
+
return (h(Host, { exportparts: "label,input,input-invalid" }, h("fieldset", null, h("legend", null, "Representative"), h("hr", null), h("div", { class: "row gy-3" }, h("div", { class: "col-12 col-md-8" }, h("form-control-text", { name: "name", label: "Full Name", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.name, error: this.errors.name, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-4" }, h("form-control-text", { name: "title", label: "Title", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.title, error: this.errors.title, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-text", { name: "email", label: "Email Address", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.email, error: this.errors.email, inputHandler: this.inputHandler })), h("div", { class: "col-12 col-md-6" }, h("form-control-number-masked", { name: "phone", label: "Phone Number", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.phone, error: this.errors.phone, inputHandler: this.inputHandler, mask: PHONE_MASKS.US })), h("div", { class: "col-12 col-md-4" }, h("form-control-date", { name: "dob_full", label: "Birth Date", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.dob_full, error: this.errors.dob_full, inputHandler: this.inputHandler, onFormControlInput: this.onDateOfBirthUpdate })), h("div", { class: "col-12 col-md-8" }, h("form-control-number", { name: "identification_number", label: "SSN", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler })), h("div", { class: "col-12" }, h("justifi-identity-address-form", { errors: this.errors.address, defaultValues: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.address, handleFormUpdate: this.onAddressFormUpdate }))))));
|
|
35
38
|
}
|
|
36
39
|
static get style() { return businessRepresentativeCss; }
|
|
37
40
|
}, [0, "justifi-business-representative", {
|
|
@@ -43,14 +46,14 @@ function defineCustomElement() {
|
|
|
43
46
|
if (typeof customElements === "undefined") {
|
|
44
47
|
return;
|
|
45
48
|
}
|
|
46
|
-
const components = ["justifi-business-representative", "form-control-
|
|
49
|
+
const components = ["justifi-business-representative", "form-control-date", "form-control-number", "form-control-number-masked", "form-control-select", "form-control-text", "justifi-identity-address-form"];
|
|
47
50
|
components.forEach(tagName => { switch (tagName) {
|
|
48
51
|
case "justifi-business-representative":
|
|
49
52
|
if (!customElements.get(tagName)) {
|
|
50
53
|
customElements.define(tagName, BusinessRepresentative);
|
|
51
54
|
}
|
|
52
55
|
break;
|
|
53
|
-
case "form-control-
|
|
56
|
+
case "form-control-date":
|
|
54
57
|
if (!customElements.get(tagName)) {
|
|
55
58
|
defineCustomElement$6();
|
|
56
59
|
}
|