@justifi/webcomponents 4.14.0 → 4.15.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.
Files changed (217) hide show
  1. package/dist/cjs/{Payment-eceed10f.js → Payment-24f22eca.js} +2 -1
  2. package/dist/cjs/{SubAccount-b3902202.js → SubAccount-f1eda5da.js} +1 -1
  3. package/dist/cjs/additional-questions-details_5.cjs.entry.js +1 -1
  4. package/dist/cjs/business-additional-questions-schema-e7dd7bc3.js +57 -0
  5. package/dist/cjs/gross-payment-chart-core.cjs.entry.js +1 -1
  6. package/dist/cjs/{index.esm-d25bd7bf.js → index.esm-a32e1831.js} +727 -0
  7. package/dist/cjs/justifi-additional-questions-form-step_5.cjs.entry.js +14 -11
  8. package/dist/cjs/justifi-additional-questions_4.cjs.entry.js +4 -1
  9. package/dist/cjs/justifi-billing-form_2.cjs.entry.js +1796 -0
  10. package/dist/cjs/justifi-business-form.cjs.entry.js +6 -6
  11. package/dist/cjs/justifi-business-list.cjs.entry.js +2 -2
  12. package/dist/cjs/justifi-checkout-core.cjs.entry.js +7 -3
  13. package/dist/cjs/justifi-checkout.cjs.entry.js +6 -2
  14. package/dist/cjs/justifi-new-payment-method_4.cjs.entry.js +13 -11
  15. package/dist/cjs/justifi-owner-form.cjs.entry.js +10 -6
  16. package/dist/cjs/justifi-payment-balance-transactions.cjs.entry.js +2 -2
  17. package/dist/cjs/justifi-payment-details.cjs.entry.js +2 -2
  18. package/dist/cjs/justifi-payment-form.cjs.entry.js +3 -3
  19. package/dist/cjs/justifi-payment-method-selector.cjs.entry.js +1 -1
  20. package/dist/cjs/justifi-payments-list.cjs.entry.js +2 -2
  21. package/dist/cjs/justifi-payout-details.cjs.entry.js +2 -2
  22. package/dist/cjs/justifi-payouts-list.cjs.entry.js +2 -2
  23. package/dist/cjs/justifi-proceeds-list.cjs.entry.js +2 -2
  24. package/dist/cjs/justifi-refund-form.cjs.entry.js +3 -4
  25. package/dist/cjs/justifi-subaccount-details.cjs.entry.js +3 -3
  26. package/dist/cjs/justifi-subaccounts-list.cjs.entry.js +3 -3
  27. package/dist/cjs/loader.cjs.js +1 -1
  28. package/dist/cjs/payload-parsers-c2df4b29.js +95 -0
  29. package/dist/cjs/payment-details-core.cjs.entry.js +1 -1
  30. package/dist/cjs/{payment.service-019157e9.js → payment.service-35298e95.js} +1 -1
  31. package/dist/cjs/payments-list-core.cjs.entry.js +2 -2
  32. package/dist/cjs/payout-details-core.cjs.entry.js +1 -1
  33. package/dist/cjs/{payout.service-7203762f.js → payout.service-eec372aa.js} +1 -1
  34. package/dist/cjs/payouts-list-core.cjs.entry.js +2 -2
  35. package/dist/cjs/{payload-parsers-6c4b5323.js → schema-validations-3c70335c.js} +15 -89
  36. package/dist/cjs/select-input.cjs.entry.js +31 -0
  37. package/dist/cjs/subaccount-account-details_4.cjs.entry.js +1 -1
  38. package/dist/cjs/text-input.cjs.entry.js +30 -0
  39. package/dist/cjs/{utils-6f62f7a1.js → utils-e58fe016.js} +0 -2
  40. package/dist/cjs/webcomponents.cjs.js +1 -1
  41. package/dist/collection/api/Payment.js +2 -1
  42. package/dist/collection/collection-manifest.json +1 -1
  43. package/dist/collection/components/billing-form/billing-form-schema.js +8 -8
  44. package/dist/collection/components/billing-form/billing-form.js +49 -89
  45. package/dist/collection/components/billing-form/test/billing-form.spec.js +2 -1
  46. package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +4 -1
  47. package/dist/collection/components/business-forms/owner-form/owner-form.js +5 -1
  48. package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +4 -1
  49. package/dist/collection/components/business-forms/schemas/business-identity-schema.js +4 -2
  50. package/dist/collection/components/business-forms/schemas/schema-validations.js +5 -0
  51. package/dist/collection/components/checkout/checkout-core.js +74 -2
  52. package/dist/collection/components/checkout/checkout.js +73 -1
  53. package/dist/collection/components/checkout/payment-method-options.css +6 -6
  54. package/dist/collection/components/checkout/payment-method-options.js +42 -6
  55. package/dist/collection/components/checkout/{sezzel-payment-method.js → sezzle-payment-method.js} +2 -2
  56. package/dist/collection/components/checkout/test/checkout-core.spec.js +1 -1
  57. package/dist/collection/components/payment-form/payment-form.js +2 -3
  58. package/dist/collection/components/payment-form/payment-method-selector.js +1 -1
  59. package/dist/collection/components/payment-form/test/payment-form.spec.js +1 -1
  60. package/dist/collection/components/payment-method-form/payment-method-form.js +1 -1
  61. package/dist/docs.json +265 -80
  62. package/dist/esm/{Payment-ef9fc1ae.js → Payment-3e94da9c.js} +2 -1
  63. package/dist/esm/{SubAccount-f4ae9809.js → SubAccount-80d46814.js} +1 -1
  64. package/dist/esm/additional-questions-details_5.entry.js +1 -1
  65. package/dist/esm/{business-additional-questions-schema-e96b0509.js → business-additional-questions-schema-1fdc5c40.js} +2 -2
  66. package/dist/esm/gross-payment-chart-core.entry.js +1 -1
  67. package/dist/esm/{index.esm-22b47398.js → index.esm-d98bc080.js} +727 -1
  68. package/dist/esm/justifi-additional-questions-form-step_5.entry.js +10 -7
  69. package/dist/esm/justifi-additional-questions_4.entry.js +4 -1
  70. package/dist/esm/justifi-billing-form_2.entry.js +1791 -0
  71. package/dist/esm/justifi-business-form.entry.js +5 -5
  72. package/dist/esm/justifi-business-list.entry.js +2 -2
  73. package/dist/esm/justifi-checkout-core.entry.js +7 -3
  74. package/dist/esm/justifi-checkout.entry.js +6 -2
  75. package/dist/esm/justifi-new-payment-method_4.entry.js +13 -11
  76. package/dist/esm/justifi-owner-form.entry.js +9 -5
  77. package/dist/esm/justifi-payment-balance-transactions.entry.js +2 -2
  78. package/dist/esm/justifi-payment-details.entry.js +2 -2
  79. package/dist/esm/justifi-payment-form.entry.js +3 -3
  80. package/dist/esm/justifi-payment-method-selector.entry.js +1 -1
  81. package/dist/esm/justifi-payments-list.entry.js +2 -2
  82. package/dist/esm/justifi-payout-details.entry.js +2 -2
  83. package/dist/esm/justifi-payouts-list.entry.js +2 -2
  84. package/dist/esm/justifi-proceeds-list.entry.js +2 -2
  85. package/dist/esm/justifi-refund-form.entry.js +2 -3
  86. package/dist/esm/justifi-subaccount-details.entry.js +3 -3
  87. package/dist/esm/justifi-subaccounts-list.entry.js +3 -3
  88. package/dist/esm/loader.js +1 -1
  89. package/dist/esm/payload-parsers-fd35eeca.js +88 -0
  90. package/dist/esm/payment-details-core.entry.js +1 -1
  91. package/dist/esm/{payment.service-03e274d7.js → payment.service-c62d82d3.js} +1 -1
  92. package/dist/esm/payments-list-core.entry.js +2 -2
  93. package/dist/esm/payout-details-core.entry.js +1 -1
  94. package/dist/esm/{payout.service-9823d66d.js → payout.service-28b9594f.js} +1 -1
  95. package/dist/esm/payouts-list-core.entry.js +2 -2
  96. package/dist/esm/{payload-parsers-32028700.js → schema-validations-31feaa53.js} +7 -84
  97. package/dist/{module/select-input2.js → esm/select-input.entry.js} +7 -30
  98. package/dist/esm/subaccount-account-details_4.entry.js +1 -1
  99. package/dist/{module/text-input2.js → esm/text-input.entry.js} +7 -29
  100. package/dist/esm/{utils-243abdb4.js → utils-37533368.js} +1 -2
  101. package/dist/esm/webcomponents.js +1 -1
  102. package/dist/module/Payment.js +2 -1
  103. package/dist/module/billing-form.js +41 -62
  104. package/dist/module/business-additional-questions-form-step.js +1 -1
  105. package/dist/module/business-additional-questions-schema.js +1 -1
  106. package/dist/module/business-address-schema.js +1 -1
  107. package/dist/module/business-core-info-form-step.js +1 -1
  108. package/dist/module/business-core-info-schema.js +1 -1
  109. package/dist/module/business-form-types.js +1 -154
  110. package/dist/module/business-identity-schema.js +5 -3
  111. package/dist/module/business-representative-form-step.js +5 -2
  112. package/dist/module/business-representative.js +4 -1
  113. package/dist/module/checkout-core.js +27 -19
  114. package/dist/module/identity-address-form.js +1 -1
  115. package/dist/module/index.esm.js +727 -1
  116. package/dist/module/justifi-business-details.js +1 -1
  117. package/dist/module/justifi-business-form.js +3 -4
  118. package/dist/module/justifi-checkout.js +29 -21
  119. package/dist/module/justifi-gross-payment-chart.js +1 -1
  120. package/dist/module/justifi-payment-details.js +1 -1
  121. package/dist/module/justifi-payment-form.js +13 -13
  122. package/dist/module/justifi-payment-provisioning.js +2 -2
  123. package/dist/module/justifi-payments-list.js +1 -1
  124. package/dist/module/justifi-payout-details.js +1 -1
  125. package/dist/module/justifi-payouts-list.js +1 -1
  126. package/dist/module/justifi-refund-form.js +1 -2
  127. package/dist/module/justifi-sezzle-payment-method.d.ts +11 -0
  128. package/dist/module/justifi-sezzle-payment-method.js +6 -0
  129. package/dist/module/legal-address-form-step.js +2 -2
  130. package/dist/module/legal-address-form.js +1 -1
  131. package/dist/module/new-payment-method.js +9 -9
  132. package/dist/module/owner-form.js +8 -4
  133. package/dist/module/payment-method-form.js +1 -1
  134. package/dist/module/payment-method-options.js +26 -22
  135. package/dist/module/schema-validations.js +159 -0
  136. package/dist/module/select-input.js +48 -1
  137. package/dist/module/{sezzel-payment-method.js → sezzle-payment-method.js} +6 -6
  138. package/dist/module/text-input.js +46 -1
  139. package/dist/module/utils2.js +1 -2
  140. package/dist/module/utils3.js +12 -21
  141. package/dist/module/utils4.js +21 -12
  142. package/dist/types/api/Payment.d.ts +2 -1
  143. package/dist/types/components/billing-form/billing-form.d.ts +8 -15
  144. package/dist/types/components/business-forms/business-form/business-representative/business-representative.d.ts +1 -0
  145. package/dist/types/components/business-forms/owner-form/owner-form.d.ts +1 -0
  146. package/dist/types/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.d.ts +1 -0
  147. package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +3 -1
  148. package/dist/types/components/business-forms/schemas/business-identity-schema.d.ts +2 -0
  149. package/dist/types/components/checkout/checkout-core.d.ts +4 -0
  150. package/dist/types/components/checkout/checkout.d.ts +4 -0
  151. package/dist/types/components/checkout/payment-method-options.d.ts +2 -0
  152. package/dist/types/components/checkout/{sezzel-payment-method.d.ts → sezzle-payment-method.d.ts} +1 -1
  153. package/dist/types/components.d.ts +35 -28
  154. package/dist/webcomponents/{p-96a86f04.entry.js → p-0603a526.entry.js} +1 -1
  155. package/dist/webcomponents/{p-3917edbf.entry.js → p-09a6df17.entry.js} +1 -1
  156. package/dist/webcomponents/{p-7da249b8.entry.js → p-1367c4c7.entry.js} +1 -1
  157. package/dist/webcomponents/{p-a6f170ba.entry.js → p-1f23c9d5.entry.js} +1 -1
  158. package/dist/webcomponents/p-21f301a0.entry.js +1 -0
  159. package/dist/webcomponents/p-243caf7c.entry.js +1 -0
  160. package/dist/webcomponents/{p-c6e207f6.entry.js → p-27ea1f3f.entry.js} +1 -1
  161. package/dist/webcomponents/{p-28b38699.js → p-3cd675e7.js} +1 -1
  162. package/dist/webcomponents/{p-c48a99b9.entry.js → p-55d37253.entry.js} +1 -1
  163. package/dist/webcomponents/{p-0b8c1ffc.entry.js → p-60ea8fd1.entry.js} +1 -1
  164. package/dist/webcomponents/p-624ed594.entry.js +1 -0
  165. package/dist/webcomponents/{p-598bb67c.entry.js → p-62bbcdfb.entry.js} +1 -1
  166. package/dist/webcomponents/p-76e74f01.js +1 -0
  167. package/dist/webcomponents/p-7ca334d6.entry.js +1 -0
  168. package/dist/webcomponents/p-7d6c67bb.js +1 -0
  169. package/dist/webcomponents/{p-5dac370e.entry.js → p-7ea5b11c.entry.js} +1 -1
  170. package/dist/webcomponents/p-83ae34bf.js +1 -0
  171. package/dist/webcomponents/p-84aea66c.entry.js +1 -0
  172. package/dist/webcomponents/{p-4824018b.entry.js → p-8960e936.entry.js} +1 -1
  173. package/dist/webcomponents/{p-28181471.entry.js → p-8d53f1de.entry.js} +1 -1
  174. package/dist/webcomponents/p-969572f2.entry.js +1 -0
  175. package/dist/webcomponents/{p-fce2b224.entry.js → p-9a36fca6.entry.js} +1 -1
  176. package/dist/webcomponents/p-a38fdda7.entry.js +1 -0
  177. package/dist/webcomponents/{p-1334f776.entry.js → p-adc9ae0f.entry.js} +1 -1
  178. package/dist/webcomponents/p-b53d7b7f.js +1 -0
  179. package/dist/webcomponents/p-b8d70349.entry.js +1 -0
  180. package/dist/webcomponents/p-b9db1c52.entry.js +1 -0
  181. package/dist/webcomponents/{p-edb66ae0.js → p-ca39c89f.js} +1 -1
  182. package/dist/webcomponents/{p-02993072.entry.js → p-d6b980a3.entry.js} +1 -1
  183. package/dist/webcomponents/p-dd609661.js +1 -0
  184. package/dist/webcomponents/{p-7c5f15f8.entry.js → p-de4ffaa1.entry.js} +1 -1
  185. package/dist/webcomponents/{p-9f529959.entry.js → p-e1a3a670.entry.js} +1 -1
  186. package/dist/webcomponents/{p-d2fcc58b.entry.js → p-e4be71ee.entry.js} +1 -1
  187. package/dist/webcomponents/p-e8706cc4.js +1 -0
  188. package/dist/webcomponents/{p-65510838.js → p-f4dec164.js} +1 -1
  189. package/dist/webcomponents/p-f942f90b.entry.js +1 -0
  190. package/dist/webcomponents/p-fea93cb9.entry.js +1 -0
  191. package/dist/webcomponents/{p-f76283a5.entry.js → p-fee64d38.entry.js} +1 -1
  192. package/dist/webcomponents/webcomponents.css +1 -1
  193. package/dist/webcomponents/webcomponents.esm.js +1 -1
  194. package/package.json +1 -1
  195. package/dist/cjs/business-additional-questions-schema-0a35f597.js +0 -57
  196. package/dist/cjs/form-2ad3d374.js +0 -729
  197. package/dist/cjs/justifi-billing-form_4.cjs.entry.js +0 -1864
  198. package/dist/esm/form-5279c05a.js +0 -727
  199. package/dist/esm/justifi-billing-form_4.entry.js +0 -1857
  200. package/dist/module/form.js +0 -727
  201. package/dist/module/justifi-sezzel-payment-method.d.ts +0 -11
  202. package/dist/module/justifi-sezzel-payment-method.js +0 -6
  203. package/dist/webcomponents/p-02fa533c.js +0 -1
  204. package/dist/webcomponents/p-132ba228.js +0 -1
  205. package/dist/webcomponents/p-230b96df.entry.js +0 -1
  206. package/dist/webcomponents/p-3d2f2937.entry.js +0 -1
  207. package/dist/webcomponents/p-3da23f21.js +0 -1
  208. package/dist/webcomponents/p-617caf03.entry.js +0 -1
  209. package/dist/webcomponents/p-64710363.entry.js +0 -1
  210. package/dist/webcomponents/p-70d43109.entry.js +0 -1
  211. package/dist/webcomponents/p-9b4b91ba.js +0 -1
  212. package/dist/webcomponents/p-ade12f56.js +0 -1
  213. package/dist/webcomponents/p-c1be3378.entry.js +0 -1
  214. package/dist/webcomponents/p-c211d068.js +0 -1
  215. package/dist/webcomponents/p-c3d5f7de.entry.js +0 -1
  216. package/dist/webcomponents/p-d57f5f01.entry.js +0 -1
  217. package/dist/webcomponents/p-f5ae07c4.entry.js +0 -1
@@ -1,20 +1,20 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host } from './index-83dcf934.js';
2
- import { F as FormController } from './form-5279c05a.js';
2
+ import { F as FormController } from './index.esm-d98bc080.js';
3
3
  import { A as AdditionalQuestions, C as CoreBusinessInfo, O as Owner, R as Representative, d as deconstructDate, c as Address } from './Business-d83fbdb4.js';
4
4
  import { A as Api } from './Api-b09a2f6a.js';
5
5
  import './Pagination-afc8f96d.js';
6
- import './Payment-ef9fc1ae.js';
6
+ import './Payment-3e94da9c.js';
7
7
  import './Payout-dfe15b00.js';
8
8
  import { c as config } from './config-476c7241.js';
9
- import { a as additionalQuestionsSchema, b as businessCoreInfoSchema } from './business-additional-questions-schema-e96b0509.js';
9
+ import { a as additionalQuestionsSchema, b as businessCoreInfoSchema } from './business-additional-questions-schema-1fdc5c40.js';
10
10
  import { B as BusinessFormServerErrors, O as OwnerFormClickActions } from './business-form-types-0d76133c.js';
11
11
  import { C as CURRENCY_MASK, T as TAX_ID_MASKS, P as PHONE_MASKS, S as SSN_MASK } from './form-input-masks-0e18300f.js';
12
12
  import { c as businessServiceReceivedOptions, r as recurringPaymentsOptions, s as seasonalBusinessOptions, b as businessTypeOptions, a as businessStructureOptions } from './business-form-options-de11bc46.js';
13
- import { q as parseCoreInfo, u as parseIdentityInfo, i as identitySchema, v as parseAddressInfo, a as addressSchema } from './payload-parsers-32028700.js';
14
- import { e as flattenNestedObject } from './utils-243abdb4.js';
13
+ import { b as parseCoreInfo, c as parseIdentityInfo, i as identitySchema, d as parseAddressInfo, a as addressSchema } from './payload-parsers-fd35eeca.js';
14
+ import { e as flattenNestedObject } from './utils-37533368.js';
15
15
  import { S as StateOptions } from './state-options-a356fb11.js';
16
16
  import { f as filterPostalInput } from './utils-6f05d9d7.js';
17
- import './index.esm-22b47398.js';
17
+ import './schema-validations-31feaa53.js';
18
18
 
19
19
  const AdditionalQuestionsFormStep = class {
20
20
  constructor(hostRef) {
@@ -386,6 +386,9 @@ const BusinessRepresentativeFormStep = class {
386
386
  get businessEndpoint() {
387
387
  return `entities/business/${this.businessId}`;
388
388
  }
389
+ get identificationNumberLabel() {
390
+ return this.representative.ssn_last4 ? 'Update SSN (optional)' : 'SSN';
391
+ }
389
392
  handleResponse(response, onSuccess) {
390
393
  if (response.error) {
391
394
  this.serverError.emit({ data: response.error, message: BusinessFormServerErrors.patchData });
@@ -416,7 +419,7 @@ const BusinessRepresentativeFormStep = class {
416
419
  }
417
420
  render() {
418
421
  const representativeDefaultValue = this.formController.getInitialValues();
419
- 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-masked", { name: "identification_number", label: "SSN", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler, mask: SSN_MASK })), 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 })))))));
422
+ 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-masked", { name: "identification_number", label: this.identificationNumberLabel, defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler, mask: SSN_MASK })), 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 })))))));
420
423
  }
421
424
  };
422
425
  BusinessRepresentativeFormStep.style = businessRepresentativeFormStepCss;
@@ -72,13 +72,16 @@ const BusinessRepresentative = class {
72
72
  this.errors = {};
73
73
  this.representative = {};
74
74
  }
75
+ get identificationNumberLabel() {
76
+ return this.representative.ssn_last4 ? 'Update SSN (optional)' : 'SSN';
77
+ }
75
78
  componentDidLoad() {
76
79
  this.formController.errors.subscribe(errors => (this.errors = Object.assign({}, errors.representative)));
77
80
  this.formController.values.subscribe(values => (this.representative = Object.assign({}, values.representative)));
78
81
  }
79
82
  render() {
80
83
  const representativeDefaultValue = this.formController.getInitialValues().representative;
81
- 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-masked", { name: "identification_number", label: "SSN", defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler, mask: SSN_MASK })), 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 }))))));
84
+ 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-masked", { name: "identification_number", label: this.identificationNumberLabel, defaultValue: representativeDefaultValue === null || representativeDefaultValue === void 0 ? void 0 : representativeDefaultValue.identification_number, error: this.errors.identification_number, inputHandler: this.inputHandler, mask: SSN_MASK })), 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 }))))));
82
85
  }
83
86
  };
84
87
  BusinessRepresentative.style = businessRepresentativeCss;