@taxbit/react-sdk 0.4.1 → 0.4.2

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/README.md CHANGED
@@ -176,18 +176,7 @@ The TaxBit React SDK provides callbacks for the following events on the `TaxBitD
176
176
 
177
177
  - `onSubmit` - called when the user clicks the submit button
178
178
  - `onSuccess` - called after the server responds with a successful submission
179
- - `onProgress` - called when the user navigates within the TaxBit UI. The function passed here will be passed a Progress object with the following shape:
180
-
181
- ```typescript
182
- type Progress = {
183
- stepNumber: number;
184
- totalSteps: number;
185
- percentComplete: number;
186
- stepTitle: string;
187
- stepId: string;
188
- language: Locale;
189
- };
190
- ```
179
+ - `onProgress` - called when the user navigates within the TaxBit UI. The function passed here will be passed a Progress object (see below for the type definition):
191
180
 
192
181
  The DAC7 sequence, for example, can have a total of 3, 4, or 5 steps, each with a localized `stepTitle` and `stepId`. The `stepNumber` is the current step (1 based), and `percentComplete` is the percentage of the steps that have been completed.
193
182
 
@@ -231,13 +220,29 @@ type Locale =
231
220
  | 'sv-se';
232
221
  ```
233
222
 
223
+ ```typescript
224
+ type StepId =
225
+ | 'accountHolderContactInformation'
226
+ | 'accountHolderTaxInformation'
227
+ | 'accountHolderTaxClarification'
228
+ | 'accountHolderClassification'
229
+ | 'confirmation'
230
+ | 'exemptions'
231
+ | 'regardedOwnerClassification'
232
+ | 'regardedOwnerContactInformation'
233
+ | 'regardedOwnerTaxInformation'
234
+ | 'summary';
235
+ ```
236
+
234
237
  ```typescript
235
238
  type Progress = {
236
239
  language: Locale;
237
240
  percentComplete: number;
238
- stepId: string;
241
+ stepId: StepId;
242
+ stepIndex: number;
239
243
  stepNumber: number;
240
244
  stepTitle: string;
245
+ steps: StepId[];
241
246
  totalSteps: number;
242
247
  };
243
248
  ```
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import type { InputStep, Locale, Progress, TaxDocumentation, TaxForm } from 'types';
3
+ import type { StepId } from 'types/StepId';
3
4
  import { ClientTaxDocumentation } from 'types/client';
4
- import { TitleKey } from '../../i18n/types';
5
5
  type UseTaxDocumentationProps = {
6
6
  data: ClientTaxDocumentation;
7
7
  language?: Locale;
@@ -22,7 +22,7 @@ export declare const useTaxDocumentation: ({ data: initialData, language: initia
22
22
  onResetTaxDocumentation: (data: ClientTaxDocumentation) => void;
23
23
  editTo: (form: InputStep) => void;
24
24
  onCancel: (() => void) | undefined;
25
- getTitleKey: (key: InputStep) => TitleKey;
25
+ getStepId: (key: InputStep) => StepId;
26
26
  goTo: (form: InputStep) => void;
27
27
  goBack: (() => void) | undefined;
28
28
  goToNext: (data: TaxDocumentation) => void;
@@ -11,7 +11,7 @@ export declare const useTaxDocumentationContext: () => {
11
11
  onResetTaxDocumentation: (data: import("../../entry").ClientTaxDocumentation) => void;
12
12
  editTo: (form: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => void;
13
13
  onCancel: (() => void) | undefined;
14
- getTitleKey: (key: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => import("../../i18n/types").TitleKey;
14
+ getStepId: (key: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => import("../../entry").StepId;
15
15
  goTo: (form: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => void;
16
16
  goBack: (() => void) | undefined;
17
17
  goToNext: (data: import("../../types").TaxDocumentation) => void;
@@ -34,7 +34,7 @@ export declare const useTaxDocumentationContext: () => {
34
34
  onResetTaxDocumentation: (data: import("../../entry").ClientTaxDocumentation) => void;
35
35
  editTo: (form: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => void;
36
36
  onCancel: (() => void) | undefined;
37
- getTitleKey: (key: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => import("../../i18n/types").TitleKey;
37
+ getStepId: (key: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => import("../../entry").StepId;
38
38
  goTo: (form: "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Confirmation" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary") => void;
39
39
  goBack: (() => void) | undefined;
40
40
  goToNext: (data: import("../../types").TaxDocumentation) => void;
@@ -1,6 +1,7 @@
1
1
  export * from '../hooks/useTaxBit';
2
2
  export * from '../types/Locale';
3
3
  export * from '../types/Progress';
4
+ export * from '../types/StepId';
4
5
  export * from '../types/TaxForm';
5
6
  export * from '../types/client';
6
7
  export * from '../widgets/TaxBitForm';
@@ -1,9 +1,12 @@
1
1
  import { Locale } from './Locale.ts';
2
+ import type { StepId } from './StepId.ts';
2
3
  export type Progress = {
3
- stepNumber: number;
4
- totalSteps: number;
4
+ language: Locale;
5
5
  percentComplete: number;
6
+ stepId: StepId;
7
+ stepIndex: number;
8
+ stepNumber: number;
6
9
  stepTitle: string;
7
- stepId: string;
8
- language: Locale;
10
+ steps: StepId[];
11
+ totalSteps: number;
9
12
  };
@@ -0,0 +1 @@
1
+ export type StepId = 'accountHolderContactInformation' | 'accountHolderTaxInformation' | 'accountHolderTaxClarification' | 'accountHolderClassification' | 'confirmation' | 'exemptions' | 'regardedOwnerClassification' | 'regardedOwnerContactInformation' | 'regardedOwnerTaxInformation' | 'summary';
@@ -724,7 +724,7 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
724
724
  Za(n)
725
725
  ]
726
726
  )
727
- ), ir = "0.4.1", G = (e) => e === void 0 ? void 0 : e === "yes", nr = (e) => {
727
+ ), ir = "0.4.2", x = (e) => e === void 0 ? void 0 : e === "yes", nr = (e) => {
728
728
  const a = {
729
729
  city: e.accountHolderAddressCity,
730
730
  country: e.accountHolderAddressCountry,
@@ -769,35 +769,35 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
769
769
  {
770
770
  country: e.accountHolderTaxResidenceCountry1,
771
771
  tin: e.accountHolderTaxResidenceForeignTin1,
772
- tinNotRequired: G(
772
+ tinNotRequired: x(
773
773
  e.accountHolderTaxResidenceForeignTin1IsNotRequired
774
774
  )
775
775
  },
776
776
  {
777
777
  country: e.accountHolderTaxResidenceCountry2,
778
778
  tin: e.accountHolderTaxResidenceForeignTin2,
779
- tinNotRequired: G(
779
+ tinNotRequired: x(
780
780
  e.accountHolderTaxResidenceForeignTin2IsNotRequired
781
781
  )
782
782
  },
783
783
  {
784
784
  country: e.accountHolderTaxResidenceCountry3,
785
785
  tin: e.accountHolderTaxResidenceForeignTin3,
786
- tinNotRequired: G(
786
+ tinNotRequired: x(
787
787
  e.accountHolderTaxResidenceForeignTin3IsNotRequired
788
788
  )
789
789
  },
790
790
  {
791
791
  country: e.accountHolderTaxResidenceCountry4,
792
792
  tin: e.accountHolderTaxResidenceForeignTin4,
793
- tinNotRequired: G(
793
+ tinNotRequired: x(
794
794
  e.accountHolderTaxResidenceForeignTin4IsNotRequired
795
795
  )
796
796
  },
797
797
  {
798
798
  country: e.accountHolderTaxResidenceCountry5,
799
799
  tin: e.accountHolderTaxResidenceForeignTin5,
800
- tinNotRequired: G(
800
+ tinNotRequired: x(
801
801
  e.accountHolderTaxResidenceForeignTin5IsNotRequired
802
802
  )
803
803
  }
@@ -812,7 +812,7 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
812
812
  dateOfBirth: e.accountHolderDateOfBirth,
813
813
  dbaName: e.accountHolderDbaName,
814
814
  mailingAddress: rr(e),
815
- mailingAddressIsDifferent: G(
815
+ mailingAddressIsDifferent: x(
816
816
  e.accountHolderMailingAddressIsDifferent
817
817
  ),
818
818
  name: e.accountHolderName,
@@ -821,7 +821,7 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
821
821
  financialAccountIdentifier: e.accountHolderFinancialAccountIdentifier,
822
822
  financialAccountName: e.accountHolderFinancialAccountName,
823
823
  ftin: e.accountHolderForeignTin,
824
- ftinNotLegallyRequired: G(
824
+ ftinNotLegallyRequired: x(
825
825
  e.accountHolderForeignTinIsNotRequired
826
826
  ),
827
827
  taxResidences: sr(e),
@@ -830,17 +830,17 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
830
830
  vatinCountry: e.accountHolderVatCountry,
831
831
  businessRegistrationCountry: e.accountHolderBusinessRegistrationCountry,
832
832
  businessRegistrationNumber: e.accountHolderBusinessRegistrationNumber,
833
- vatinNotRequired: G(e.accountHolderVatIsNotRequired),
833
+ vatinNotRequired: x(e.accountHolderVatIsNotRequired),
834
834
  exemptFatcaCode: e.exemptFatcaCode,
835
835
  exemptPayeeCode: e.exemptPayeeCode,
836
- isIndividual: G(e.accountHolderIsIndividual),
837
- isEuResident: G(e.accountHolderIsEuResident),
838
- isUsPerson: G(e.accountHolderUsPerson),
836
+ isIndividual: x(e.accountHolderIsIndividual),
837
+ isEuResident: x(e.accountHolderIsEuResident),
838
+ isUsPerson: x(e.accountHolderUsPerson),
839
839
  usAccountType: e.accountHolderUsAccountType,
840
- usSmllcElection: G(e.accountHolderUsSmllcElection),
840
+ usSmllcElection: x(e.accountHolderUsSmllcElection),
841
841
  usLlcClassification: e.accountHolderUsLlcClassification,
842
842
  usOtherClassification: e.accountHolderUsOtherClassification,
843
- usTrustEstateEin: G(e.accountHolderUsTrustEstateEin),
843
+ usTrustEstateEin: x(e.accountHolderUsTrustEstateEin),
844
844
  foreignAccountType: e.accountHolderForeignAccountType,
845
845
  foreignTrustClassification: e.accountHolderForeignTrustClassification,
846
846
  foreignOtherClassification: e.accountHolderForeignOtherClassification
@@ -853,22 +853,22 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
853
853
  dateOfBirth: e.regardedOwnerDateOfBirth,
854
854
  dbaName: e.regardedOwnerDbaName,
855
855
  mailingAddress: or(e),
856
- mailingAddressIsDifferent: G(
856
+ mailingAddressIsDifferent: x(
857
857
  e.regardedOwnerMailingAddressIsDifferent
858
858
  ),
859
859
  name: e.regardedOwnerName,
860
860
  ftin: e.regardedOwnerForeignTin,
861
- ftinNotLegallyRequired: G(
861
+ ftinNotLegallyRequired: x(
862
862
  e.regardedOwnerForeignTinIsNotRequired
863
863
  ),
864
864
  tin: e.regardedOwnerUsTin,
865
865
  exemptFatcaCode: e.exemptFatcaCode,
866
866
  exemptPayeeCode: e.exemptPayeeCode,
867
- isUsPerson: G(e.regardedOwnerUsPerson),
867
+ isUsPerson: x(e.regardedOwnerUsPerson),
868
868
  usAccountType: e.regardedOwnerUsAccountType,
869
869
  usLlcClassification: e.regardedOwnerUsLlcClassification,
870
870
  usOtherClassification: e.regardedOwnerUsOtherClassification,
871
- usTrustEstateEin: G(e.regardedOwnerUsTrustEstateEin),
871
+ usTrustEstateEin: x(e.regardedOwnerUsTrustEstateEin),
872
872
  foreignAccountType: e.regardedOwnerForeignAccountType,
873
873
  foreignTrustClassification: e.regardedOwnerForeignTrustClassification,
874
874
  foreignOtherClassification: e.regardedOwnerForeignOtherClassification
@@ -877,11 +877,11 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
877
877
  }, ur = (e) => ({
878
878
  accountHolder: lr(e),
879
879
  regardedOwner: dr(e),
880
- hasCertified: G(e.iCertifyToAll),
881
- isNotSubjectBackupWithholding: G(
880
+ hasCertified: x(e.iCertifyToAll),
881
+ isNotSubjectBackupWithholding: x(
882
882
  e.iAmNotSubjectToBackupWithholding
883
883
  ),
884
- isConfirmedCorrectComplete: G(
884
+ isConfirmedCorrectComplete: x(
885
885
  e.iConfirmTheInformationIsCorrectComplete
886
886
  ),
887
887
  signature: e.signature,
@@ -1384,7 +1384,7 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
1384
1384
  regardedOwnerMailingAddress: e.regardedOwnerMailingAddressIsDifferent === "yes"
1385
1385
  };
1386
1386
  }, Yn = (e, a) => {
1387
- var o, s, l, d, m, h, g, c, p, f, C, N, T, y, R, v, L, J, I, j, x, te, Be, Re, Ae, Z, X, ie, be, ue, Ce, Ie, Se, z, U, Ne, la, da, Pe, we, Te, He, Me, ua, Fe, ca, ma, ye, je, Ke, Ve, Oe, ga, ka, Le, ha, pa, We, Je, pe, va, Ze, qe, Ge, fa, Aa, ba, Ca, Ia, Sa, Na, xe, Ye, ce, Ue, De, _e, Ta, Qe, Ma, Xe, $e, ya, ja, ea, Oa, za, Ea, Ba, t, u, k, b, O, B, M, S, F, w, H, q, me, aa, ne, ei, ai, ii, ni, ti, ri, oi, si, li, di, ui, ci, mi, gi, ki, hi, pi, vi, fi, Ai, bi, Ci, Ii, Si, Ni, Ti, Mi, yi, ji, Oi, zi, Ei, Bi, Ri, Pi, wi, Hi, Li, Gi, xi, Ui, Di, Fi, Ki, Vi, Wi, Ji, Zi, qi, Yi, _i, Qi, Xi, $i, en, an, nn, tn, rn, on, sn, ln, dn, un, cn, mn, gn, kn, hn, pn, vn, fn, An, bn, Cn, In, Sn, Nn, Tn, Mn, yn, jn, On, zn, En, Bn, Rn, Pn, wn, Hn, Ln, Gn, xn;
1387
+ var o, s, l, d, m, h, g, c, p, f, C, N, T, y, R, v, L, J, I, j, G, ie, Be, Re, Ae, Z, X, ne, be, ue, Ce, Ie, Se, z, U, Ne, la, da, Pe, we, Te, He, Me, ua, Fe, ca, ma, ye, je, Ke, Ve, Oe, ga, ka, Le, ha, pa, We, Je, pe, va, Ze, qe, Ge, fa, Aa, ba, Ca, Ia, Sa, Na, xe, Ye, ce, Ue, De, _e, Ta, Qe, Ma, Xe, $e, ya, ja, ea, Oa, za, Ea, Ba, t, u, k, b, O, B, M, S, F, w, H, q, me, aa, te, ei, ai, ii, ni, ti, ri, oi, si, li, di, ui, ci, mi, gi, ki, hi, pi, vi, fi, Ai, bi, Ci, Ii, Si, Ni, Ti, Mi, yi, ji, Oi, zi, Ei, Bi, Ri, Pi, wi, Hi, Li, Gi, xi, Ui, Di, Fi, Ki, Vi, Wi, Ji, Zi, qi, Yi, _i, Qi, Xi, $i, en, an, nn, tn, rn, on, sn, ln, dn, un, cn, mn, gn, kn, hn, pn, vn, fn, An, bn, Cn, In, Sn, Nn, Tn, Mn, yn, jn, On, zn, En, Bn, Rn, Pn, wn, Hn, Ln, Gn, xn;
1388
1388
  if (e == null)
1389
1389
  return {};
1390
1390
  const n = {
@@ -1402,11 +1402,11 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
1402
1402
  accountHolderAddressStreet2: (v = (R = e.accountHolder) == null ? void 0 : R.address) == null ? void 0 : v.secondLine,
1403
1403
  accountHolderAddressCity: (J = (L = e.accountHolder) == null ? void 0 : L.address) == null ? void 0 : J.city,
1404
1404
  accountHolderAddressState: (j = (I = e.accountHolder) == null ? void 0 : I.address) == null ? void 0 : j.stateOrProvince,
1405
- accountHolderAddressZip: (te = (x = e.accountHolder) == null ? void 0 : x.address) == null ? void 0 : te.postalCode,
1405
+ accountHolderAddressZip: (ie = (G = e.accountHolder) == null ? void 0 : G.address) == null ? void 0 : ie.postalCode,
1406
1406
  accountHolderAddressCountry: (Re = (Be = e.accountHolder) == null ? void 0 : Be.address) == null ? void 0 : Re.country,
1407
1407
  accountHolderMailingAddressIsDifferent: (Ae = e.accountHolder) != null && Ae.mailingAddressIsDifferent ? "yes" : void 0,
1408
1408
  accountHolderMailingAddress: (X = (Z = e.accountHolder) == null ? void 0 : Z.mailingAddress) == null ? void 0 : X.country,
1409
- accountHolderMailingAddressStreet: (be = (ie = e.accountHolder) == null ? void 0 : ie.mailingAddress) == null ? void 0 : be.firstLine,
1409
+ accountHolderMailingAddressStreet: (be = (ne = e.accountHolder) == null ? void 0 : ne.mailingAddress) == null ? void 0 : be.firstLine,
1410
1410
  accountHolderMailingAddressStreet2: (Ce = (ue = e.accountHolder) == null ? void 0 : ue.mailingAddress) == null ? void 0 : Ce.secondLine,
1411
1411
  accountHolderMailingAddressCity: (Se = (Ie = e.accountHolder) == null ? void 0 : Ie.mailingAddress) == null ? void 0 : Se.city,
1412
1412
  accountHolderMailingAddressState: (U = (z = e.accountHolder) == null ? void 0 : z.mailingAddress) == null ? void 0 : U.stateOrProvince,
@@ -1449,7 +1449,7 @@ const Ua = (e, a) => `https://api.multi1.enterprise${a === "STAGING" ? "-staging
1449
1449
  accountHolderTaxResidenceCountry1: (b = (k = (u = e.accountHolder) == null ? void 0 : u.taxResidences) == null ? void 0 : k[0]) == null ? void 0 : b.country,
1450
1450
  accountHolderTaxResidenceForeignTin1: (M = (B = (O = e.accountHolder) == null ? void 0 : O.taxResidences) == null ? void 0 : B[0]) != null && M.tinNotRequired || (w = (F = (S = e.accountHolder) == null ? void 0 : S.taxResidences) == null ? void 0 : F[0]) == null ? void 0 : w.tin,
1451
1451
  accountHolderTaxResidenceForeignTin1IsNotRequired: (me = (q = (H = e.accountHolder) == null ? void 0 : H.taxResidences) == null ? void 0 : q[0]) != null && me.tinNotRequired ? "yes" : void 0,
1452
- accountHolderTaxResidenceCountry2: (ei = (ne = (aa = e.accountHolder) == null ? void 0 : aa.taxResidences) == null ? void 0 : ne[1]) == null ? void 0 : ei.country,
1452
+ accountHolderTaxResidenceCountry2: (ei = (te = (aa = e.accountHolder) == null ? void 0 : aa.taxResidences) == null ? void 0 : te[1]) == null ? void 0 : ei.country,
1453
1453
  accountHolderTaxResidenceForeignTin2: (ni = (ii = (ai = e.accountHolder) == null ? void 0 : ai.taxResidences) == null ? void 0 : ii[1]) != null && ni.tinNotRequired || (oi = (ri = (ti = e.accountHolder) == null ? void 0 : ti.taxResidences) == null ? void 0 : ri[1]) == null ? void 0 : oi.tin,
1454
1454
  accountHolderTaxResidenceForeignTin2IsNotRequired: (di = (li = (si = e.accountHolder) == null ? void 0 : si.taxResidences) == null ? void 0 : li[1]) != null && di.tinNotRequired ? "yes" : void 0,
1455
1455
  accountHolderTaxResidenceCountry3: (mi = (ci = (ui = e.accountHolder) == null ? void 0 : ui.taxResidences) == null ? void 0 : ci[2]) == null ? void 0 : mi.country,
@@ -1626,14 +1626,14 @@ function pr() {
1626
1626
  B.unshift("Warning: " + u), Function.prototype.apply.call(console[t], console, B);
1627
1627
  }
1628
1628
  }
1629
- var L = !1, J = !1, I = !1, j = !1, x = !1, te;
1630
- te = Symbol.for("react.module.reference");
1629
+ var L = !1, J = !1, I = !1, j = !1, G = !1, ie;
1630
+ ie = Symbol.for("react.module.reference");
1631
1631
  function Be(t) {
1632
- return !!(typeof t == "string" || typeof t == "function" || t === r || t === s || x || t === o || t === h || t === g || j || t === f || L || J || I || typeof t == "object" && t !== null && (t.$$typeof === p || t.$$typeof === c || t.$$typeof === l || t.$$typeof === d || t.$$typeof === m || // This needs to include all possible module reference object
1632
+ return !!(typeof t == "string" || typeof t == "function" || t === r || t === s || G || t === o || t === h || t === g || j || t === f || L || J || I || typeof t == "object" && t !== null && (t.$$typeof === p || t.$$typeof === c || t.$$typeof === l || t.$$typeof === d || t.$$typeof === m || // This needs to include all possible module reference object
1633
1633
  // types supported by any Flight configuration anywhere since
1634
1634
  // we don't know which Flight build this will end up being used
1635
1635
  // with.
1636
- t.$$typeof === te || t.getModuleId !== void 0));
1636
+ t.$$typeof === ie || t.getModuleId !== void 0));
1637
1637
  }
1638
1638
  function Re(t, u, k) {
1639
1639
  var b = t.displayName;
@@ -1690,13 +1690,13 @@ function pr() {
1690
1690
  }
1691
1691
  return null;
1692
1692
  }
1693
- var X = Object.assign, ie = 0, be, ue, Ce, Ie, Se, z, U;
1693
+ var X = Object.assign, ne = 0, be, ue, Ce, Ie, Se, z, U;
1694
1694
  function Ne() {
1695
1695
  }
1696
1696
  Ne.__reactDisabledLog = !0;
1697
1697
  function la() {
1698
1698
  {
1699
- if (ie === 0) {
1699
+ if (ne === 0) {
1700
1700
  be = console.log, ue = console.info, Ce = console.warn, Ie = console.error, Se = console.group, z = console.groupCollapsed, U = console.groupEnd;
1701
1701
  var t = {
1702
1702
  configurable: !0,
@@ -1714,12 +1714,12 @@ function pr() {
1714
1714
  groupEnd: t
1715
1715
  });
1716
1716
  }
1717
- ie++;
1717
+ ne++;
1718
1718
  }
1719
1719
  }
1720
1720
  function da() {
1721
1721
  {
1722
- if (ie--, ie === 0) {
1722
+ if (ne--, ne === 0) {
1723
1723
  var t = {
1724
1724
  configurable: !0,
1725
1725
  enumerable: !0,
@@ -1749,7 +1749,7 @@ function pr() {
1749
1749
  })
1750
1750
  });
1751
1751
  }
1752
- ie < 0 && R("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
1752
+ ne < 0 && R("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
1753
1753
  }
1754
1754
  }
1755
1755
  var Pe = y.ReactCurrentDispatcher, we;
@@ -1797,29 +1797,29 @@ function pr() {
1797
1797
  }), typeof Reflect == "object" && Reflect.construct) {
1798
1798
  try {
1799
1799
  Reflect.construct(M, []);
1800
- } catch (ne) {
1801
- b = ne;
1800
+ } catch (te) {
1801
+ b = te;
1802
1802
  }
1803
1803
  Reflect.construct(t, [], M);
1804
1804
  } else {
1805
1805
  try {
1806
1806
  M.call();
1807
- } catch (ne) {
1808
- b = ne;
1807
+ } catch (te) {
1808
+ b = te;
1809
1809
  }
1810
1810
  t.call(M.prototype);
1811
1811
  }
1812
1812
  } else {
1813
1813
  try {
1814
1814
  throw Error();
1815
- } catch (ne) {
1816
- b = ne;
1815
+ } catch (te) {
1816
+ b = te;
1817
1817
  }
1818
1818
  t();
1819
1819
  }
1820
- } catch (ne) {
1821
- if (ne && b && typeof ne.stack == "string") {
1822
- for (var S = ne.stack.split(`
1820
+ } catch (te) {
1821
+ if (te && b && typeof te.stack == "string") {
1822
+ for (var S = te.stack.split(`
1823
1823
  `), F = b.stack.split(`
1824
1824
  `), w = S.length - 1, H = F.length - 1; w >= 1 && H >= 0 && S[w] !== F[H]; )
1825
1825
  H--;
@@ -19058,34 +19058,33 @@ const vr = {
19058
19058
  ), { isW9: R, isW8: v, isW8Ben: L, isW8BenE: J, isDac7: I } = xa(
19059
19059
  p,
19060
19060
  m
19061
- ), j = C[C.length - 1], x = ee(() => $n(p), [p]), te = (z) => {
19062
- const U = {
19063
- AccountHolderContact: "accountHolderContactInformation",
19064
- AccountHolderTax: "accountHolderTaxInformation",
19065
- AccountHolderTaxClarification: "accountHolderTaxClarification",
19066
- AccountHolderClassification: "accountHolderClassification",
19067
- Confirmation: "confirmation",
19068
- Exemptions: "exemptions",
19069
- RegardedOwnerClassification: "regardedOwnerClassification",
19070
- RegardedOwnerContact: "regardedOwnerContactInformation",
19071
- RegardedOwnerTax: "regardedOwnerTaxInformation",
19072
- Summary: "summary"
19073
- };
19074
- return U[z] ? U[z] : z;
19075
- };
19061
+ ), j = C[C.length - 1], G = ee(() => $n(p), [p]), ie = (z) => ({
19062
+ AccountHolderContact: "accountHolderContactInformation",
19063
+ AccountHolderTax: "accountHolderTaxInformation",
19064
+ AccountHolderTaxClarification: "accountHolderTaxClarification",
19065
+ AccountHolderClassification: "accountHolderClassification",
19066
+ Confirmation: "confirmation",
19067
+ Exemptions: "exemptions",
19068
+ RegardedOwnerClassification: "regardedOwnerClassification",
19069
+ RegardedOwnerContact: "regardedOwnerContactInformation",
19070
+ RegardedOwnerTax: "regardedOwnerTaxInformation",
19071
+ Summary: "summary"
19072
+ })[z];
19076
19073
  Y(() => {
19077
- const z = x.indexOf(j);
19074
+ const z = G.indexOf(j);
19078
19075
  c({
19079
19076
  stepNumber: z + 1,
19080
- totalSteps: x.length,
19077
+ stepIndex: z,
19078
+ totalSteps: G.length,
19081
19079
  percentComplete: Math.round(
19082
- z / (x.length - 1) * 100
19080
+ z / (G.length - 1) * 100
19083
19081
  ),
19084
- stepTitle: kt(te(j), l),
19085
- stepId: te(j),
19082
+ stepTitle: kt(ie(j), l),
19083
+ stepId: ie(j),
19084
+ steps: G.map((U) => ie(U)),
19086
19085
  language: l
19087
19086
  });
19088
- }, [l, j, x]), Y(() => {
19087
+ }, [l, j, G]), Y(() => {
19089
19088
  g && r && r(g);
19090
19089
  }, [r, g]);
19091
19090
  const Be = {
@@ -19111,17 +19110,17 @@ const vr = {
19111
19110
  }, X = (z) => {
19112
19111
  const U = Z(z);
19113
19112
  U === "Summary" && y(void 0), ue(U);
19114
- }, ie = (z) => {
19113
+ }, ne = (z) => {
19115
19114
  const U = {
19116
19115
  ...p,
19117
19116
  ...z
19118
19117
  };
19119
19118
  f(U), T === void 0 ? X(U) : N(["Summary"]);
19120
19119
  }, be = (z) => {
19121
- p.accountHolderUsAccountType !== z.accountHolderUsAccountType || p.accountHolderForeignAccountType !== z.accountHolderForeignAccountType ? ie({
19120
+ p.accountHolderUsAccountType !== z.accountHolderUsAccountType || p.accountHolderForeignAccountType !== z.accountHolderForeignAccountType ? ne({
19122
19121
  ...z,
19123
19122
  ...Be
19124
- }) : ie(z);
19123
+ }) : ne(z);
19125
19124
  }, ue = (z) => {
19126
19125
  N([...C, z]);
19127
19126
  }, Ce = (z) => {
@@ -19138,12 +19137,12 @@ const vr = {
19138
19137
  isW8BenE: J,
19139
19138
  isDac7: I,
19140
19139
  onPersistAccountHolderData: be,
19141
- onPersistCollectedData: ie,
19140
+ onPersistCollectedData: ne,
19142
19141
  onSubmitTaxDocumentation: Re,
19143
19142
  onResetTaxDocumentation: Ae,
19144
19143
  editTo: Ce,
19145
19144
  onCancel: Ie,
19146
- getTitleKey: te,
19145
+ getStepId: ie,
19147
19146
  goTo: ue,
19148
19147
  goBack: Se,
19149
19148
  goToNext: X,
@@ -19258,20 +19257,20 @@ const vr = {
19258
19257
  const f = it(
19259
19258
  (I, j) => {
19260
19259
  if (/accountHolderShowTaxResidence[234]/.test(I) && j === void 0) {
19261
- const x = parseInt(I.slice(-1));
19262
- j !== r[I] && o(co(r, x));
19260
+ const G = parseInt(I.slice(-1));
19261
+ j !== r[I] && o(co(r, G));
19263
19262
  } else if (/AddressCountry/.test(I)) {
19264
19263
  if (j !== r[I]) {
19265
- const x = I.split("Address")[0] + "Address";
19266
- o((te) => ({
19267
- ...te,
19264
+ const G = I.split("Address")[0] + "Address";
19265
+ o((ie) => ({
19266
+ ...ie,
19268
19267
  [I]: j,
19269
- [x]: j
19268
+ [G]: j
19270
19269
  }));
19271
19270
  }
19272
19271
  } else
19273
- j !== r[I] && o((x) => ({
19274
- ...x,
19272
+ j !== r[I] && o((G) => ({
19273
+ ...G,
19275
19274
  [I]: j
19276
19275
  }));
19277
19276
  },
@@ -19283,8 +19282,8 @@ const vr = {
19283
19282
  }, T = Object.keys(p).length === 0, y = uo(r, e);
19284
19283
  return {
19285
19284
  clearIfNotRequired: (...I) => (j) => {
19286
- j === "yes" && I.forEach((x) => {
19287
- f(x, "");
19285
+ j === "yes" && I.forEach((G) => {
19286
+ f(G, "");
19288
19287
  });
19289
19288
  },
19290
19289
  fields: r,
@@ -19302,7 +19301,7 @@ const vr = {
19302
19301
  visibleFields: h,
19303
19302
  // (must be supported)
19304
19303
  hideField: (I) => {
19305
- d.has(I) && m((j) => new Set([...j].filter((x) => x !== I))), f(I, void 0);
19304
+ d.has(I) && m((j) => new Set([...j].filter((G) => G !== I))), f(I, void 0);
19306
19305
  },
19307
19306
  showField: (I) => {
19308
19307
  d.has(I) || m((j) => /* @__PURE__ */ new Set([...j, I]));
@@ -19967,7 +19966,7 @@ const vr = {
19967
19966
  syncName: l
19968
19967
  }
19969
19968
  ) }), yo = () => {
19970
- const { fields: e, getLocalTitle: a } = E(), { getTitleKey: n, onPersistAccountHolderData: r, onCancel: o } = ae();
19969
+ const { fields: e, getLocalTitle: a } = E(), { getStepId: n, onPersistAccountHolderData: r, onCancel: o } = ae();
19971
19970
  return /* @__PURE__ */ i.jsxs(
19972
19971
  ke,
19973
19972
  {
@@ -20132,7 +20131,7 @@ const vr = {
20132
20131
  label: a,
20133
20132
  subLabel: n
20134
20133
  }) => /* @__PURE__ */ i.jsx(A, { name: e, label: a, subLabel: n, children: /* @__PURE__ */ i.jsx(Ao, { name: e }) }), zo = () => {
20135
- const { onPersistCollectedData: e, goBack: a, onCancel: n, isW9: r, isW8: o, getTitleKey: s } = ae(), { fields: l, getLocalCountry: d, getLocalTitle: m } = E(), h = ee(
20134
+ const { onPersistCollectedData: e, goBack: a, onCancel: n, isW9: r, isW8: o, getStepId: s } = ae(), { fields: l, getLocalCountry: d, getLocalTitle: m } = E(), h = ee(
20136
20135
  () => ra.map((g) => ({
20137
20136
  ...g,
20138
20137
  label: d(g.value)
@@ -20142,9 +20141,7 @@ const vr = {
20142
20141
  return /* @__PURE__ */ i.jsxs(
20143
20142
  ke,
20144
20143
  {
20145
- title: m(
20146
- s(sa("AccountHolderContact"))
20147
- ),
20144
+ title: m(s(sa("AccountHolderContact"))),
20148
20145
  className: "taxbit-form-account-holder-contact-information",
20149
20146
  children: [
20150
20147
  /* @__PURE__ */ i.jsxs("main", { className: "taxbit-page-main", children: [
@@ -20252,7 +20249,7 @@ const vr = {
20252
20249
  r ? /* @__PURE__ */ i.jsx($a, { children: /* @__PURE__ */ i.jsx(So, { name: p }) }) : null
20253
20250
  ] }) : null;
20254
20251
  }, Bo = () => {
20255
- const { onPersistCollectedData: e, goBack: a, onCancel: n, getTitleKey: r } = ae(), {
20252
+ const { onPersistCollectedData: e, goBack: a, onCancel: n, getStepId: r } = ae(), {
20256
20253
  fields: o,
20257
20254
  getLocalTitle: s,
20258
20255
  getLocalSubTitle: l,
@@ -20455,7 +20452,7 @@ const vr = {
20455
20452
  }
20456
20453
  );
20457
20454
  }, wo = () => {
20458
- const { onPersistCollectedData: e, goBack: a, onCancel: n, getTitleKey: r } = ae(), { fields: o, getLocalTitle: s } = E();
20455
+ const { onPersistCollectedData: e, goBack: a, onCancel: n, getStepId: r } = ae(), { fields: o, getLocalTitle: s } = E();
20459
20456
  return /* @__PURE__ */ i.jsxs(
20460
20457
  ke,
20461
20458
  {
@@ -20480,7 +20477,7 @@ const vr = {
20480
20477
  const { getLocalText: e } = E();
20481
20478
  return /* @__PURE__ */ i.jsx("div", { children: e("interviewIsComplete") });
20482
20479
  }, Go = () => /* @__PURE__ */ i.jsx(de, { children: /* @__PURE__ */ i.jsx(Lo, {}) }), xo = () => {
20483
- const { onPersistCollectedData: e, goBack: a, getTitleKey: n } = ae(), { fields: r, getLocalTitle: o } = E();
20480
+ const { onPersistCollectedData: e, goBack: a, getStepId: n } = ae(), { fields: r, getLocalTitle: o } = E();
20484
20481
  return /* @__PURE__ */ i.jsxs(
20485
20482
  ke,
20486
20483
  {