@taxbit/react-sdk 1.1.0-beta.1 → 1.2.0-beta.1

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 (235) hide show
  1. package/README.md +13 -4
  2. package/dist/index.d.ts +1 -1
  3. package/dist/src/App.d.ts +0 -1
  4. package/dist/src/components/Address/Address.d.ts +0 -1
  5. package/dist/src/components/ErrorAlert/ErrorAlert.d.ts +0 -1
  6. package/dist/src/components/ErrorBoundary/ErrorBoundary.d.ts +0 -1
  7. package/dist/src/components/ErrorMessage/ErrorMessage.d.ts +0 -1
  8. package/dist/src/components/Form/Form.d.ts +0 -1
  9. package/dist/src/components/InputStatus/InputStatus.d.ts +0 -1
  10. package/dist/src/components/JsxFromString/JsxFromString.d.ts +0 -1
  11. package/dist/src/components/ProgressStatus/ProgressStatus.d.ts +0 -1
  12. package/dist/src/components/Row/Row.d.ts +0 -1
  13. package/dist/src/components/Section/Section.d.ts +0 -1
  14. package/dist/src/contexts/QuestionnaireStep/QuestionnaireStepProvider.d.ts +0 -1
  15. package/dist/src/contexts/QuestionnaireStep/getLocal.d.ts +4 -4
  16. package/dist/src/contexts/QuestionnaireStep/index.d.ts +0 -1
  17. package/dist/src/contexts/QuestionnaireStep/shiftControllingPerson.d.ts +2 -0
  18. package/dist/src/contexts/QuestionnaireStep/shiftResidence.d.ts +1 -2
  19. package/dist/src/contexts/QuestionnaireStep/useQuestionnaireStep.d.ts +2 -2
  20. package/dist/src/contexts/QuestionnaireStep/useQuestionnaireStepContext.d.ts +4 -2
  21. package/dist/src/contexts/TaxDocumentation/TaxbitQuestionnaireProvider.d.ts +0 -1
  22. package/dist/src/contexts/TaxDocumentation/useTaxDocumentation.d.ts +5 -6
  23. package/dist/src/contexts/TaxDocumentation/useTaxDocumentationContext.d.ts +6 -6
  24. package/dist/src/hooks/useHandleError.d.ts +0 -1
  25. package/dist/src/hooks/useTaxbit/__tests__/clientTaxDocumentation.d.ts +0 -1
  26. package/dist/src/hooks/useTaxbit/__tests__/serverTaxDocumentation.d.ts +0 -1
  27. package/dist/src/hooks/useTaxbit/types/comprehensive.d.ts +0 -1
  28. package/dist/src/hooks/useTaxbit/types/w8.d.ts +0 -1
  29. package/dist/src/hooks/useTaxbit/types/w9.d.ts +0 -1
  30. package/dist/src/hooks/useTaxbit/useTaxbit.d.ts +2 -3
  31. package/dist/src/hooks/useTaxbit/useTaxbitStatus.d.ts +2 -3
  32. package/dist/src/i18n/locales/de.d.ts +2 -3
  33. package/dist/src/i18n/locales/el-cy.d.ts +0 -1
  34. package/dist/src/i18n/locales/el.d.ts +2 -3
  35. package/dist/src/i18n/locales/en-gb.d.ts +0 -1
  36. package/dist/src/i18n/locales/en-nz.d.ts +0 -1
  37. package/dist/src/i18n/locales/en-us.d.ts +0 -1
  38. package/dist/src/i18n/locales/en.d.ts +0 -1
  39. package/dist/src/i18n/locales/es.d.ts +0 -1
  40. package/dist/src/i18n/locales/fr-ca.d.ts +0 -1
  41. package/dist/src/i18n/locales/fr.d.ts +0 -1
  42. package/dist/src/i18n/locales/ga.d.ts +1 -3
  43. package/dist/src/i18n/locales/lt.d.ts +2 -3
  44. package/dist/src/i18n/locales/mergePropertyFiles.d.ts +0 -1
  45. package/dist/src/i18n/locales/nl-be.d.ts +0 -1
  46. package/dist/src/i18n/locales/pl.d.ts +2 -3
  47. package/dist/src/i18n/locales/translation-missing.d.ts +0 -1
  48. package/dist/src/i18n/localizationFileMap.d.ts +0 -1
  49. package/dist/src/i18n/types/LocalizationKey.d.ts +6 -6
  50. package/dist/src/i18n/types/PropertyFile.d.ts +15 -15
  51. package/dist/src/i18n/utils/getText.d.ts +0 -1
  52. package/dist/src/index.d.ts +2 -3
  53. package/dist/src/lookups/activeNonFinancialEntityTypeOptions.d.ts +3 -0
  54. package/dist/src/lookups/controllingPersonRoleOptions.d.ts +3 -0
  55. package/dist/src/lookups/dayOptions.d.ts +1 -1
  56. package/dist/src/lookups/entityTypeOptions.d.ts +3 -0
  57. package/dist/src/lookups/fatcaCodeOptions.d.ts +1 -1
  58. package/dist/src/lookups/financialInstitutionTypeOptions.d.ts +3 -0
  59. package/dist/src/lookups/foreignAccountHolderAccountTypeOptions.d.ts +1 -1
  60. package/dist/src/lookups/foreignOtherClassificationOptions.d.ts +1 -1
  61. package/dist/src/lookups/foreignRegardedOwnerAccountTypeOptions.d.ts +1 -1
  62. package/dist/src/lookups/foreignTrustClassificationOptions.d.ts +1 -1
  63. package/dist/src/lookups/getTreatyCountryLimitationOnBenefitOptions.d.ts +0 -1
  64. package/dist/src/lookups/index.d.ts +7 -0
  65. package/dist/src/lookups/localeOptions.d.ts +0 -1
  66. package/dist/src/lookups/payeeCodeOptions.d.ts +2 -2
  67. package/dist/src/lookups/selfCertificationAccountTypeOptions.d.ts +3 -0
  68. package/dist/src/lookups/signatureCapacityOptions.d.ts +3 -0
  69. package/dist/src/lookups/tinNotRequiredReasonOptions.d.ts +3 -0
  70. package/dist/src/lookups/usAccountHolderAccountTypeOptions.d.ts +1 -1
  71. package/dist/src/lookups/usLlcAccountTypeOptions.d.ts +1 -1
  72. package/dist/src/lookups/usRegardedOwnerAccountTypeOptions.d.ts +1 -1
  73. package/dist/src/services/api.d.ts +5 -3
  74. package/dist/src/services/msw.d.ts +33 -0
  75. package/dist/src/test/Wrapper.d.ts +2 -3
  76. package/dist/src/test/getWrapper.d.ts +2 -3
  77. package/dist/src/test/utils/helpers.d.ts +10 -0
  78. package/dist/src/types/InputStep.d.ts +1 -1
  79. package/dist/src/types/Progress.d.ts +0 -1
  80. package/dist/src/types/QuestionnaireProp.d.ts +1 -0
  81. package/dist/src/types/StepId.d.ts +1 -1
  82. package/dist/src/types/TaxDocumentation.d.ts +87 -51
  83. package/dist/src/types/client/ClientTaxDocumentationStatus.d.ts +4 -0
  84. package/dist/src/types/index.d.ts +1 -1
  85. package/dist/src/types/server/TaxDocumentationStatus.d.ts +4 -0
  86. package/dist/src/ui/ActionButton/ActionButton.d.ts +0 -1
  87. package/dist/src/ui/Actions/Actions.d.ts +0 -1
  88. package/dist/src/ui/CheckBox/CheckBox.d.ts +0 -1
  89. package/dist/src/ui/DateOfBirthInput/DateOfBirthInput.d.ts +0 -1
  90. package/dist/src/ui/DateOfBirthInput/useDateOfBirthInput.d.ts +1 -2
  91. package/dist/src/ui/FormattedInput/FormattedInput.d.ts +0 -1
  92. package/dist/src/ui/HideShowButton/HideShowButton.d.ts +0 -1
  93. package/dist/src/ui/InputValue/InputValue.d.ts +2 -2
  94. package/dist/src/ui/MaskedContent/MaskedContent.d.ts +0 -1
  95. package/dist/src/ui/PasswordInput/PasswordInput.d.ts +0 -1
  96. package/dist/src/ui/RadioButtons/RadioButtons.d.ts +0 -1
  97. package/dist/src/ui/RadioButtons/__tests__/RadioButtons.test.d.ts +0 -1
  98. package/dist/src/ui/Select/Select.d.ts +0 -2
  99. package/dist/src/ui/ShowHideInput/ShowHideInput.d.ts +0 -1
  100. package/dist/src/ui/TextArea/TextArea.d.ts +0 -1
  101. package/dist/src/ui/TextArea/__tests__/TextInput.test.d.ts +0 -1
  102. package/dist/src/ui/TextInput/TextInput.d.ts +0 -1
  103. package/dist/src/ui/TextInput/__tests__/TextInput.test.d.ts +0 -1
  104. package/dist/src/ui/ToggleButton/ToggleButton.d.ts +0 -1
  105. package/dist/src/ui/WithholdingInput/WithholdingInput.d.ts +0 -1
  106. package/dist/src/utils/camelCaseKeys.d.ts +0 -1
  107. package/dist/src/utils/getFieldsState.d.ts +7 -3
  108. package/dist/src/utils/getFormStatus.d.ts +2 -2
  109. package/dist/src/utils/getLanguage.d.ts +2 -3
  110. package/dist/src/utils/index.d.ts +1 -1
  111. package/dist/src/utils/mergeClientTaxDocumentationData.d.ts +0 -1
  112. package/dist/src/utils/promptKeyMapping/getAddressPromptKeyMap.d.ts +5 -0
  113. package/dist/src/utils/promptKeyMapping/getControllingPersonPromptKeyMap.d.ts +3 -0
  114. package/dist/src/utils/{getPromptKeyMap.d.ts → promptKeyMapping/getPromptKeyMap.d.ts} +0 -1
  115. package/dist/src/utils/promptKeyMapping/getTaxResidencesPromptKeyMap.d.ts +5 -0
  116. package/dist/src/utils/transformForClient/convertYesNoToBoolean.d.ts +0 -1
  117. package/dist/src/utils/transformForClient/convertYesNoToBooleanOrUndefined.d.ts +0 -1
  118. package/dist/src/utils/transformForClient/transformForClient.d.ts +2 -3
  119. package/dist/src/utils/transformForClient/transformForClientAccountHolder.d.ts +0 -1
  120. package/dist/src/utils/transformForClient/transformForClientAddress.d.ts +4 -33
  121. package/dist/src/utils/transformForClient/transformForClientRegardedOwner.d.ts +0 -1
  122. package/dist/src/utils/transformForClient/transformForClientTaxResidences.d.ts +10 -0
  123. package/dist/src/utils/transformForClient/transformForControllingPersons.d.ts +3 -0
  124. package/dist/src/utils/transformInbound/getActiveNonFinancialEntityType.d.ts +2 -0
  125. package/dist/src/utils/transformInbound/getCountryCode.d.ts +1 -0
  126. package/dist/src/utils/transformInbound/getEntityType.d.ts +2 -0
  127. package/dist/src/utils/transformInbound/getFinancialInstitutionType.d.ts +2 -0
  128. package/dist/src/utils/transformInbound/getForeignAccountType.d.ts +0 -1
  129. package/dist/src/utils/transformInbound/getForeignOtherClassification.d.ts +0 -1
  130. package/dist/src/utils/transformInbound/getForeignTrustClassification.d.ts +0 -1
  131. package/dist/src/utils/transformInbound/getLLCClassification.d.ts +0 -1
  132. package/dist/src/utils/transformInbound/getSelfCertificationAccountType.d.ts +2 -0
  133. package/dist/src/utils/transformInbound/getUsAccountType.d.ts +0 -1
  134. package/dist/src/utils/transformInbound/transformInbound.d.ts +2 -3
  135. package/dist/src/utils/transformInbound/transformInboundAddress.d.ts +5 -0
  136. package/dist/src/utils/transformInbound/transformInboundControllingPersons.d.ts +439 -0
  137. package/dist/src/utils/transformInbound/transformInboundTaxResidencies.d.ts +6 -0
  138. package/dist/src/validations/getSteps.d.ts +2 -3
  139. package/dist/src/validations/index.d.ts +5 -5
  140. package/dist/src/validations/invalidFields/getInvalidAddressFields.d.ts +4 -0
  141. package/dist/src/validations/invalidFields/getInvalidControllingPersonsFields.d.ts +2 -0
  142. package/dist/src/validations/invalidFields/getInvalidFields.d.ts +4 -0
  143. package/dist/src/validations/invalidFields/getInvalidTaxResidencyFields.d.ts +4 -0
  144. package/dist/src/validations/{invalidFieldRules.d.ts → invalidFields/invalidFieldRules.d.ts} +1 -2
  145. package/dist/src/validations/requiredFields/getRequiredAddressFields.d.ts +6 -0
  146. package/dist/src/validations/requiredFields/getRequiredControllingPersonFields.d.ts +3 -0
  147. package/dist/src/validations/requiredFields/getRequiredFields.d.ts +3 -0
  148. package/dist/src/validations/requiredFields/getRequiredTaxResidenceFields.d.ts +6 -0
  149. package/dist/src/validations/supportedFields/__tests__/generateStrings.d.ts +5 -0
  150. package/dist/src/validations/supportedFields/getSupportedAddressFields.d.ts +7 -0
  151. package/dist/src/validations/supportedFields/getSupportedControllingPersonFields.d.ts +6 -0
  152. package/dist/src/validations/supportedFields/getSupportedFields.d.ts +3 -0
  153. package/dist/src/validations/supportedFields/getSupportedTaxResidenceFields.d.ts +7 -0
  154. package/dist/src/validations/supportedFields/getSupportedTreatyClaimFields.d.ts +3 -0
  155. package/dist/src/validations/visibleFields/getVisibleAddressFields.d.ts +4 -0
  156. package/dist/src/validations/visibleFields/getVisibleControllingPersonFields.d.ts +3 -0
  157. package/dist/src/validations/visibleFields/getVisibleFields.d.ts +3 -0
  158. package/dist/src/validations/visibleFields/getVisibleTaxResidenceFields.d.ts +8 -0
  159. package/dist/src/{entry → widgets}/TaxbitQuestionnaire/TaxbitQuestionnaire.d.ts +3 -4
  160. package/dist/src/widgets/TaxbitQuestionnairePersist/TaxbitQuestionnairePersist.d.ts +0 -1
  161. package/dist/src/widgets/TaxbitQuestionnairePersist/__tests__/TaxbitQuestionnairePersist.complete.test.d.ts +0 -1
  162. package/dist/src/widgets/TaxbitQuestionnairePersist/__tests__/TaxbitQuestionnairePersist.error.test.d.ts +0 -1
  163. package/dist/src/widgets/TaxbitQuestionnairePersist/__tests__/TaxbitQuestionnairePersist.loaded.test.d.ts +0 -1
  164. package/dist/src/widgets/TaxbitQuestionnairePersist/__tests__/TaxbitQuestionnairePersist.loading.test.d.ts +0 -1
  165. package/dist/src/widgets/TaxbitQuestionnairePersist/__tests__/TaxbitQuestionnairePersist.missingBearerToken.test.d.ts +0 -1
  166. package/dist/src/widgets/TaxbitQuestionnairePersist/useTaxbitPersist.d.ts +2 -3
  167. package/dist/src/wizard/AddressInput/AddressInput.d.ts +1 -2
  168. package/dist/src/wizard/ControllingPersonInput/ControllingPersonInput.d.ts +10 -0
  169. package/dist/src/wizard/ControllingPersonInput/index.d.ts +1 -0
  170. package/dist/src/wizard/LanguageSelector/LanguageSelector.d.ts +2 -3
  171. package/dist/src/wizard/ResidenceInput/ResidenceInput.d.ts +2 -2
  172. package/dist/src/wizard/RowInput/AddressRow/AddressRow.d.ts +1 -2
  173. package/dist/src/wizard/RowInput/CheckBoxRow/CheckBoxRow.d.ts +0 -1
  174. package/dist/src/wizard/RowInput/DateOfBirthRow/DateOfBirthRow.d.ts +0 -1
  175. package/dist/src/wizard/RowInput/ErrorRow/ErrorRow.d.ts +0 -1
  176. package/dist/src/wizard/RowInput/HiddenInputRow/HiddenInputRow.d.ts +0 -1
  177. package/dist/src/wizard/RowInput/PercentInputRow/PercentInputRow.d.ts +8 -0
  178. package/dist/src/wizard/RowInput/PercentInputRow/index.d.ts +1 -0
  179. package/dist/src/wizard/RowInput/RadioButtonRow/RadioButtonRow.d.ts +0 -1
  180. package/dist/src/wizard/RowInput/SelectRow/SelectRow.d.ts +2 -2
  181. package/dist/src/wizard/RowInput/ShowHideInputRow/ShowHideInputRow.d.ts +0 -1
  182. package/dist/src/wizard/RowInput/TextAreaRow/TextAreaRow.d.ts +0 -1
  183. package/dist/src/wizard/RowInput/TextInputRow/TextInputRow.d.ts +0 -1
  184. package/dist/src/wizard/RowInput/ToggleButtonRow/ToggleButtonRow.d.ts +0 -1
  185. package/dist/src/wizard/RowInput/VisibleRow/VisibleRow.d.ts +0 -1
  186. package/dist/src/wizard/RowInput/index.d.ts +1 -0
  187. package/dist/src/wizard/TaxbitQuestionnaireUI/AccountHolderClassification/AccountHolderClassification.d.ts +0 -1
  188. package/dist/src/wizard/TaxbitQuestionnaireUI/AccountHolderContact/AccountHolderContact.d.ts +0 -1
  189. package/dist/src/wizard/TaxbitQuestionnaireUI/AccountHolderTax/AccountHolderTax.d.ts +0 -1
  190. package/dist/src/wizard/TaxbitQuestionnaireUI/AccountHolderTaxClarification/AccountHolderTaxClarification.d.ts +0 -1
  191. package/dist/src/wizard/TaxbitQuestionnaireUI/AccountHolderTreatyClaims/AccountHolderTreatyClaims.d.ts +0 -1
  192. package/dist/src/wizard/TaxbitQuestionnaireUI/AppError/AppError.d.ts +0 -1
  193. package/dist/src/wizard/TaxbitQuestionnaireUI/ControllingPersonDetails/ControllingPersonDetails.d.ts +6 -0
  194. package/dist/src/wizard/TaxbitQuestionnaireUI/ControllingPersonDetails/index.d.ts +1 -0
  195. package/dist/src/wizard/TaxbitQuestionnaireUI/Exemptions/Exemptions.d.ts +0 -1
  196. package/dist/src/wizard/TaxbitQuestionnaireUI/RegardedOwnerContact/RegardedOwnerContact.d.ts +0 -1
  197. package/dist/src/wizard/TaxbitQuestionnaireUI/RegardedOwnerTax/RegardedOwnerTax.d.ts +0 -1
  198. package/dist/src/wizard/TaxbitQuestionnaireUI/RegardedOwnerTreatyClaims/RegardedOwnerTreatyClaims.d.ts +0 -1
  199. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/AccountHolder/AccountHolderClassificationSummary.d.ts +2 -0
  200. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/AccountHolder/AccountHolderForeignClassificationSummary.d.ts +5 -0
  201. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/AccountHolder/AccountHolderSelfCertificationClassificationSummary.d.ts +5 -0
  202. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/AccountHolder/AccountHolderUsClassificationSummary.d.ts +5 -0
  203. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/ControllingPerson/ControllingPersonRoleInputValue.d.ts +6 -0
  204. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/ControllingPerson/ControllingPersonSummary.d.ts +6 -0
  205. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/ControllingPerson/ControllingPersonTypeSummary.d.ts +6 -0
  206. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/Recap.d.ts +0 -1
  207. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/RegardedOwner/RegardedOwnerClassificationSummary.d.ts +2 -0
  208. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/RegardedOwner/RegardedOwnerForeignClassificationSummary.d.ts +5 -0
  209. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/RegardedOwner/RegardedOwnerUsClassificationSummary.d.ts +5 -0
  210. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/Summary.d.ts +0 -1
  211. package/dist/src/wizard/TaxbitQuestionnaireUI/Summary/TaxResidency/TaxResidenciesSummary.d.ts +10 -0
  212. package/dist/src/wizard/TaxbitQuestionnaireUI/TaxbitQuestionnaireUI.d.ts +0 -1
  213. package/dist/src/wizard/TaxbitQuestionnaireUI/W8imyInstructions/W8imyInstructions.d.ts +0 -1
  214. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitDPSQuestionnaireUI.test.d.ts +0 -1
  215. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.SelfCert.AccountClassification.test.d.ts +0 -0
  216. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.SelfCert.ControllingPerson.test.d.ts +0 -0
  217. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.SelfCert.NameAndAddress.test.d.ts +0 -0
  218. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.SelfCert.Summary.test.d.ts +0 -0
  219. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.SelfCert.TaxResidencies.test.d.ts +0 -0
  220. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitQuestionnaireUI.test.d.ts +0 -1
  221. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitWFormQuestionnaireUI.test.d.ts +0 -1
  222. package/dist/src/wizard/TaxbitQuestionnaireUI/__tests__/TaxbitWFormQuestionnaireUI.treatyClaims.test.d.ts +0 -1
  223. package/dist/src/wizard/TaxbitQuestionnaireUI/steps.d.ts +1 -0
  224. package/dist/taxbit-react-sdk.js +7290 -6619
  225. package/dist/taxbit-react-sdk.umd.cjs +1 -1
  226. package/package.json +7 -6
  227. package/style/basic.css +4 -0
  228. package/style/inline.css +1 -0
  229. package/dist/src/types/Questionnaire.d.ts +0 -1
  230. package/dist/src/utils/transformForClient/transformForClientTaxResidenceFields.d.ts +0 -7
  231. package/dist/src/validations/getInvalidFields.d.ts +0 -5
  232. package/dist/src/validations/getRequiredFields.d.ts +0 -4
  233. package/dist/src/validations/getSupportedFields.d.ts +0 -7
  234. package/dist/src/validations/getVisibleFields.d.ts +0 -4
  235. /package/dist/src/{entry → widgets}/TaxbitQuestionnaire/index.d.ts +0 -0
@@ -1,5 +1,4 @@
1
1
  import { ButtonKey, ErrorKey, OptionKey, PromptKey, SubOptionKey, SubPromptKey, SubTitleKey, TextKey, TitleKey } from './LocalizationKey';
2
-
3
2
  export type PropertyFile = {
4
3
  button: {
5
4
  [key in ButtonKey]: string;
@@ -29,23 +28,24 @@ export type PropertyFile = {
29
28
  [key in TextKey]: string;
30
29
  };
31
30
  };
32
- export type DPSPropertyFile = {
31
+ export type ForeignPropertyFile = {
33
32
  button: PropertyFile['button'];
34
- prompt: Pick<PropertyFile['prompt'], 'addAdditional' | 'address' | 'businessRegistrationCountry' | 'businessRegistrationNumber' | 'city' | 'cityOfBirth' | 'country' | 'countryOfBirth' | 'dateOfBirth' | 'day' | 'financialAccountIdentifier' | 'financialAccountName' | 'iConfirmTheInformationIsCorrectComplete' | 'isIndividual' | 'month' | 'name' | 'nameOfEntity' | 'nameOfIndividual' | 'province' | 'removeResidence' | 'state' | 'stateProvince' | 'street' | 'street2' | 'taxIdNumber' | 'taxIdNumberIsNotRequired' | 'tin' | 'tinUkCrn' | 'tinUkNino' | 'usTin' | 'vatCountry' | 'vatIdentificationNumber' | 'vatIsNotRequired' | 'year' | 'zip'>;
35
- subPrompt: Pick<PropertyFile['subPrompt'], 'financialAccountIdentifier' | 'financialAccountName' | 'isIndividual' | 'placeOfBirth' | 'streetIsPermanent' | 'vatIdentificationNumber'>;
36
- subTitle: Pick<PropertyFile['subTitle'], 'taxResidences'>;
37
- title: Pick<PropertyFile['title'], 'accountHolder' | 'accountHolderClassification' | 'accountHolderContactInformation' | 'accountHolderTaxInformation' | 'accountHolderTaxClarification' | 'address' | 'confirmation' | 'countryOfCitizenship' | 'countryOfIncorporation' | 'permanentAddress' | 'placeOfBirth' | 'summary' | 'taxResidences' | 'taxResidence1' | 'taxResidence2' | 'taxResidence3' | 'taxResidence4' | 'taxResidence5'>;
33
+ prompt: Pick<PropertyFile['prompt'], 'addAdditionalResidence' | 'addControllingPerson' | 'financialInstitutionType' | 'activeNonFinancialEntityType' | 'passiveEntityType' | 'managedEntityType' | 'investmentEntityManaged' | 'iUnderstandTheInformationIsCovered' | 'iAcknowledgeTheInformationMayBeProvided' | 'iCertifyIAmAccountHolder' | 'iCertifyIAmAuthorizedToSignForAccountHolder' | 'iCertifyIWillNotifyPersons' | 'iDeclareStatementsAreCorrect' | 'iWillNotifyChangeInCircumstanceForIndividual' | 'iWillNotifyChangeInCircumstanceForAccountHolder' | 'otherRole' | 'otherEquivalentRole' | 'ownershipPercentage' | 'relatedCorporation' | 'removeControllingPerson' | 'role' | 'securitiesMarket' | 'taxIdNumberIsNotRequiredReason' | 'taxIdNumberIsNotRequiredReasonOther' | 'address' | 'businessRegistrationCountry' | 'businessRegistrationNumber' | 'city' | 'cityOfBirth' | 'country' | 'countryOfBirth' | 'dateOfBirth' | 'day' | 'financialAccountIdentifier' | 'financialAccountName' | 'iConfirmTheInformationIsCorrectComplete' | 'isIndividual' | 'month' | 'name' | 'nameOfEntity' | 'nameOfIndividual' | 'province' | 'removeResidence' | 'countyRegion' | 'stateProvince' | 'street' | 'street2' | 'signatureCapacity' | 'signatureCapacityOther' | 'taxIdNumber' | 'taxIdNumberIsNotRequired' | 'tin' | 'tinUkCrn' | 'tinUkNino' | 'type' | 'usTin' | 'vatCountry' | 'vatIdentificationNumber' | 'vatIsNotRequired' | 'year' | 'zip'>;
34
+ subPrompt: Pick<PropertyFile['subPrompt'], 'financialAccountIdentifier' | 'financialAccountName' | 'financialInstitutionType' | 'isIndividual' | 'placeOfBirth' | 'relatedCorporation' | 'role' | 'securitiesMarket' | 'signatureCapacityOther' | 'streetIsPermanent' | 'vatIdentificationNumber'>;
35
+ subTitle: Pick<PropertyFile['subTitle'], 'taxResidences' | 'controllingPersonDetails'>;
36
+ title: Pick<PropertyFile['title'], 'carfClassificationDetails' | 'controllingPersonDetails' | 'controllingPersons' | 'controllingPerson1' | 'controllingPerson2' | 'controllingPerson3' | 'controllingPerson4' | 'controllingPerson5' | 'accountHolder' | 'accountHolderClassification' | 'accountHolderContactInformation' | 'accountHolderTaxInformation' | 'accountHolderTaxClarification' | 'address' | 'confirmation' | 'countryOfCitizenship' | 'countryOfIncorporation' | 'permanentAddress' | 'placeOfBirth' | 'summary' | 'taxResidences' | 'taxResidence1' | 'taxResidence2' | 'taxResidence3' | 'taxResidence4' | 'taxResidence5'>;
38
37
  text: Pick<PropertyFile['text'], 'interviewIsComplete' | 'notRequired' | 'notRequiredOrNotIssued' | 'retrievingInterviewStatus' | 'taxDocumentationSaved'>;
39
38
  error: Pick<PropertyFile['error'], 'countryMustBeAResidenceCountry' | 'formHasErrors' | 'invalid' | 'invalidDate' | 'invalidVat' | 'mustBeAtLeast18' | 'mustBeFiveOrNineDigits' | 'mustBeInDateFormat' | 'mustBeInVatinFormat' | 'mustBeNineDigits' | 'mustBeNinoFormat' | 'mustBeCaPostalCodeFormat' | 'mustBeValidBirthDate' | 'mustNotMatchVatin' | 'required' | 'residencesMustIncludeAddressCountry' | 'residencesMustIncludeAnEUCountry' | 'residencesMustIncludeVatCountry' | 'tooLong' | 'tooShort' | 'vatinMustNotMatchResidencyTin'>;
40
- option: Pick<PropertyFile['option'], 'no' | 'yes' | 'isIndividual_yes' | 'isIndividual_no'>;
39
+ option: Pick<PropertyFile['option'], 'no' | 'yes' | 'isIndividual_yes' | 'isIndividual_no' | 'isInvestmentEntityManaged_yes' | 'isInvestmentEntityManaged_no' | 'ACTIVE_NON_FINANCIAL_ENTITY' | 'PASSIVE_NON_FINANCIAL_ENTITY' | 'CUSTODIAL_INSTITUTION' | 'accountHolderActiveNonFinancialEntityType_GOVERNMENT_ENTITY' | 'INSURANCE_COMPANY' | 'INVESTMENT_ENTITY' | 'ENTITY_TYPE_TRUST' | 'ENTITY_TYPE_SIMILAR_TO_TRUST' | 'ENTITY_TYPE_OTHER' | 'accountHolderActiveNonFinancialEntityType_PUBLIC_CORPORATION' | 'accountHolderActiveNonFinancialEntityType_OTHER' | 'accountHolderActiveNonFinancialEntityType_INTERNATIONAL_ORGANIZATION' | 'SIGNATURE_CAPACITY_EXECUTOR' | 'SIGNATURE_CAPACITY_OFFICER' | 'SIGNATURE_CAPACITY_OTHER_CAPACITY' | 'DEPOSITORY_INSTITUTION' | 'FINANCIAL_INSTITUTION' | 'CONTROLLING_PERSON_ROLE_SETTLOR' | 'CONTROLLING_PERSON_ROLE_TRUSTEE' | 'CONTROLLING_PERSON_ROLE_PROTECTOR' | 'CONTROLLING_PERSON_ROLE_BENEFICIARY' | 'CONTROLLING_PERSON_ROLE_OTHER' | 'CONTROLLING_PERSON_ROLE_SETTLOR_EQUIVALENT' | 'CONTROLLING_PERSON_ROLE_TRUSTEE_EQUIVALENT' | 'CONTROLLING_PERSON_ROLE_PROTECTOR_EQUIVALENT' | 'CONTROLLING_PERSON_ROLE_BENEFICIARY_EQUIVALENT' | 'CONTROLLING_PERSON_ROLE_OTHER_EQUIVALENT' | 'CONTROLLING_PERSON_ROLE_OWNER' | 'CONTROLLING_PERSON_ROLE_OTHER_MEANS' | 'CONTROLLING_PERSON_ROLE_SENIOR_MANAGING_OFFICIAL' | 'MISSING_TIN_NOT_REQUIRED_REASON_NOT_ISSUED' | 'MISSING_TIN_NOT_REQUIRED_REASON_NOT_REQUIRED' | 'MISSING_TIN_NOT_REQUIRED_REASON_OTHER'>;
40
+ subOption: Pick<PropertyFile['subOption'], 'accountHolderActiveNonFinancialEntityType_PUBLIC_CORPORATION' | 'accountHolderActiveNonFinancialEntityType_OTHER'>;
41
41
  };
42
42
  export type PartialDPSPropertyFile = {
43
- button?: Partial<DPSPropertyFile['button']>;
44
- prompt?: Partial<DPSPropertyFile['prompt']>;
45
- subPrompt?: Partial<DPSPropertyFile['subPrompt']>;
46
- subTitle?: Partial<DPSPropertyFile['subTitle']>;
47
- title?: Partial<DPSPropertyFile['title']>;
48
- text?: Partial<DPSPropertyFile['text']>;
49
- error?: Partial<DPSPropertyFile['error']>;
50
- option?: Partial<DPSPropertyFile['option']>;
43
+ button?: Partial<ForeignPropertyFile['button']>;
44
+ prompt?: Partial<ForeignPropertyFile['prompt']>;
45
+ subPrompt?: Partial<ForeignPropertyFile['subPrompt']>;
46
+ subTitle?: Partial<ForeignPropertyFile['subTitle']>;
47
+ title?: Partial<ForeignPropertyFile['title']>;
48
+ text?: Partial<ForeignPropertyFile['text']>;
49
+ error?: Partial<ForeignPropertyFile['error']>;
50
+ option?: Partial<ForeignPropertyFile['option']>;
51
51
  };
@@ -1,6 +1,5 @@
1
1
  import { Locale } from '../../types';
2
2
  import { ButtonKey, ErrorKey, OptionKey, PromptKey, SubOptionKey, SubPromptKey, SubTitleKey, TextKey } from '../types';
3
-
4
3
  export declare const getPromptText: (key: PromptKey, locale: Locale | undefined) => string;
5
4
  export declare const getSubPromptText: (key: SubPromptKey, locale: Locale | undefined) => string;
6
5
  export declare const getErrorText: (key: ErrorKey, locale: Locale | undefined) => string;
@@ -1,9 +1,8 @@
1
1
  import { ClientTaxDocumentation } from '@taxbit/utilities';
2
-
3
- export * from './entry/TaxbitQuestionnaire';
4
2
  export * from './hooks/useTaxbit/useTaxbit';
5
3
  export * from './types/client/ClientTaxDocumentationStatus';
6
4
  export * from './types/Locale';
7
5
  export * from './types/Progress';
8
- export * from './types/Questionnaire';
6
+ export * from './types/QuestionnaireProp.ts';
7
+ export * from './widgets/TaxbitQuestionnaire';
9
8
  export type { ClientTaxDocumentation };
@@ -0,0 +1,3 @@
1
+ export declare const activeNonFinancialEntityTypeOptions: {
2
+ value: "OTHER" | "INTERNATIONAL_ORGANIZATION" | "GOVERNMENT_ENTITY" | "PUBLIC_CORPORATION";
3
+ }[];
@@ -0,0 +1,3 @@
1
+ export declare const getControllingPersonRoleOptions: (entityType: string | undefined) => {
2
+ value: "OTHER" | "SETTLOR" | "TRUSTEE" | "PROTECTOR" | "BENEFICIARY" | "SETTLOR_EQUIVALENT" | "TRUSTEE_EQUIVALENT" | "PROTECTOR_EQUIVALENT" | "BENEFICIARY_EQUIVALENT" | "OTHER_EQUIVALENT" | "OWNER" | "OTHER_MEANS" | "SENIOR_MANAGING_OFFICIAL";
3
+ }[];
@@ -1,3 +1,3 @@
1
1
  export declare const dayOptions: {
2
- value: T;
2
+ value: "01" | "02" | "03" | "04" | "05" | "06" | "07" | "08" | "09" | "10" | "11" | "12" | "13" | "14" | "15" | "16" | "17" | "18" | "19" | "20" | "21" | "22" | "23" | "24" | "25" | "26" | "27" | "28" | "29" | "30" | "31";
3
3
  }[];
@@ -0,0 +1,3 @@
1
+ export declare const entityTypeOptions: {
2
+ value: "OTHER" | "TRUST" | "SIMILAR_TO_TRUST";
3
+ }[];
@@ -1,4 +1,4 @@
1
1
  export declare const fatcaCodeOptions: {
2
2
  label: "A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "J" | "K" | "L" | "M";
3
- value: T;
3
+ value: "A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "J" | "K" | "L" | "M";
4
4
  }[];
@@ -0,0 +1,3 @@
1
+ export declare const financialInstitutionTypeOptions: {
2
+ value: "DEPOSITORY_INSTITUTION" | "CUSTODIAL_INSTITUTION" | "INSURANCE_COMPANY" | "INVESTMENT_ENTITY";
3
+ }[];
@@ -1,3 +1,3 @@
1
1
  export declare const foreignAccountHolderAccountTypeOptions: {
2
- value: T;
2
+ value: "INDIVIDUAL" | "PARTNERSHIP" | "OTHER" | "DISREGARDED_ENTITY" | "CORPORATION" | "TRUST";
3
3
  }[];
@@ -1,3 +1,3 @@
1
1
  export declare const foreignOtherClassificationOptions: {
2
- value: T;
2
+ value: "TAX_EXEMPT_ORGANIZATION" | "PRIVATE_FOUNDATION" | "INTERNATIONAL_ORGANIZATION" | "CENTRAL_BANK_OF_ISSUE" | "FOREIGN_GOVERNMENT_CONTROLLED_ENTITY" | "FOREIGN_GOVERNMENT_INTEGRAL_PART" | "ESTATE";
3
3
  }[];
@@ -1,3 +1,3 @@
1
1
  export declare const foreignRegardedOwnerAccountTypeOptions: {
2
- value: T;
2
+ value: "INDIVIDUAL" | "PARTNERSHIP" | "OTHER" | "CORPORATION" | "TRUST";
3
3
  }[];
@@ -1,3 +1,3 @@
1
1
  export declare const foreignTrustClassificationOptions: {
2
- value: T;
2
+ value: "SIMPLE_TRUST" | "COMPLEX_TRUST" | "GRANTOR_TRUST";
3
3
  }[];
@@ -1,5 +1,4 @@
1
1
  import { LimitationOnBenefit } from '@taxbit/utilities';
2
-
3
2
  export declare const getTreatyCountryLimitationOnBenefitOptions: (country?: string) => Array<{
4
3
  value: LimitationOnBenefit;
5
4
  }>;
@@ -1,6 +1,10 @@
1
+ export * from './activeNonFinancialEntityTypeOptions';
2
+ export * from './controllingPersonRoleOptions';
1
3
  export * from './countryOptions';
2
4
  export * from './dayOptions';
5
+ export * from './entityTypeOptions.ts';
3
6
  export * from './fatcaCodeOptions';
7
+ export * from './financialInstitutionTypeOptions';
4
8
  export * from './foreignAccountHolderAccountTypeOptions';
5
9
  export * from './foreignOtherClassificationOptions';
6
10
  export * from './foreignRegardedOwnerAccountTypeOptions';
@@ -8,6 +12,9 @@ export * from './foreignTrustClassificationOptions';
8
12
  export * from './getTreatyCountryLimitationOnBenefitOptions';
9
13
  export * from './localeOptions';
10
14
  export * from './payeeCodeOptions';
15
+ export * from './selfCertificationAccountTypeOptions';
16
+ export * from './signatureCapacityOptions';
17
+ export * from './tinNotRequiredReasonOptions';
11
18
  export * from './typeOfIncomeOptions';
12
19
  export * from './usAccountHolderAccountTypeOptions';
13
20
  export * from './usLlcAccountTypeOptions';
@@ -1,5 +1,4 @@
1
1
  import { Locale } from 'types';
2
-
3
2
  export declare const localeDPSOptions: {
4
3
  value: Locale;
5
4
  label: string;
@@ -1,4 +1,4 @@
1
1
  export declare const payeeCodeOptions: {
2
- label: "10" | "11" | "12" | "13" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9";
3
- value: T;
2
+ label: "1" | "2" | "3" | "4" | "5" | "10" | "11" | "12" | "13" | "6" | "7" | "8" | "9";
3
+ value: "1" | "2" | "3" | "4" | "5" | "10" | "11" | "12" | "13" | "6" | "7" | "8" | "9";
4
4
  }[];
@@ -0,0 +1,3 @@
1
+ export declare const selfCertificationAccountTypeOptions: {
2
+ value: "FINANCIAL_INSTITUTION" | "ACTIVE_NON_FINANCIAL_ENTITY" | "PASSIVE_NON_FINANCIAL_ENTITY";
3
+ }[];
@@ -0,0 +1,3 @@
1
+ export declare const signatureCapacityOptions: {
2
+ value: "OFFICER" | "EXECUTOR" | "OTHER_CAPACITY";
3
+ }[];
@@ -0,0 +1,3 @@
1
+ export declare const tinNotRequiredReasonOptions: {
2
+ value: "OTHER" | "NOT_ISSUED" | "NOT_REQUIRED";
3
+ }[];
@@ -1,3 +1,3 @@
1
1
  export declare const usAccountHolderAccountTypeOptions: {
2
- value: T;
2
+ value: "INDIVIDUAL" | "SOLE_PROPRIETOR" | "LLC" | "SM_LLC" | "C_CORPORATION" | "S_CORPORATION" | "PARTNERSHIP" | "TRUST_ESTATE" | "OTHER" | "DISREGARDED_ENTITY";
3
3
  }[];
@@ -1,3 +1,3 @@
1
1
  export declare const usLlcAccountTypeOptions: {
2
- value: T;
2
+ value: "C_CORPORATION" | "S_CORPORATION" | "PARTNERSHIP";
3
3
  }[];
@@ -1,3 +1,3 @@
1
1
  export declare const usRegardedOwnerAccountTypeOptions: {
2
- value: T;
2
+ value: "INDIVIDUAL" | "LLC" | "C_CORPORATION" | "S_CORPORATION" | "PARTNERSHIP" | "TRUST_ESTATE" | "OTHER";
3
3
  }[];
@@ -1,9 +1,11 @@
1
- import { Questionnaire } from 'types';
2
-
1
+ import { QuestionnaireProp } from 'types';
2
+ export declare const TAX_DOCUMENTATION_SUBMISSIONS_PATH = "tax-documentation/submissions";
3
+ export declare const TAX_DOCUMENTATION_STATUS_PATH = "tax-documentation-status";
4
+ export declare const TAX_DOCUMENT_PATH = "tax-documentation/document";
3
5
  export declare const api: {
4
6
  taxDocumentationSubmissions: {
5
7
  post: (environment: "PRODUCTION" | "STAGING") => string;
6
- get: (environment: "PRODUCTION" | "STAGING", questionnaire: Questionnaire) => string;
8
+ get: (environment: "PRODUCTION" | "STAGING", questionnaire: QuestionnaireProp) => string;
7
9
  };
8
10
  taxDocumentationStatus: {
9
11
  get: (environment: "PRODUCTION" | "STAGING") => string;
@@ -0,0 +1,33 @@
1
+ type ResponseOptions = {
2
+ once?: boolean;
3
+ body?: unknown;
4
+ status?: number;
5
+ };
6
+ export declare const mockApi: {
7
+ taxDocumentationSubmissions: {
8
+ get: {
9
+ success: (options?: ResponseOptions) => import('msw').HttpHandler;
10
+ };
11
+ post: {
12
+ success: (options?: ResponseOptions) => import('msw').HttpHandler;
13
+ unauthorized: (options?: ResponseOptions) => import('msw').HttpHandler;
14
+ };
15
+ };
16
+ taxDocumentationStatus: {
17
+ get: {
18
+ success: (options?: ResponseOptions) => import('msw').HttpHandler;
19
+ unauthorized: (options?: ResponseOptions) => import('msw').HttpHandler;
20
+ };
21
+ };
22
+ taxDocument: {
23
+ post: {
24
+ success: (options?: ResponseOptions) => import('msw').HttpHandler;
25
+ };
26
+ get: {
27
+ success: (options?: ResponseOptions) => import('msw').HttpHandler;
28
+ pending: (options?: ResponseOptions) => import('msw').HttpHandler;
29
+ };
30
+ };
31
+ };
32
+ export declare const successHandlers: import('msw').HttpHandler[];
33
+ export {};
@@ -1,8 +1,7 @@
1
1
  import { ClientTaxDocumentation } from '@taxbit/utilities';
2
2
  import { default as React } from 'react';
3
- import { Questionnaire } from '../types';
4
-
3
+ import { QuestionnaireProp } from '../types';
5
4
  export declare const Wrapper: React.FC<React.PropsWithChildren & {
6
5
  initialData?: ClientTaxDocumentation;
7
- questionnaire?: Questionnaire;
6
+ questionnaire?: QuestionnaireProp;
8
7
  }>;
@@ -1,5 +1,4 @@
1
1
  import { ClientTaxDocumentation } from '@taxbit/utilities';
2
2
  import { default as React } from 'react';
3
- import { Questionnaire } from '../types';
4
-
5
- export declare const getWrapper: (initialData?: ClientTaxDocumentation, questionnaire?: Questionnaire) => ({ children }: React.PropsWithChildren) => React.ReactNode | Promise<React.ReactNode>;
3
+ import { QuestionnaireProp } from '../types';
4
+ export declare const getWrapper: (initialData?: ClientTaxDocumentation, questionnaire?: QuestionnaireProp) => ({ children }: React.PropsWithChildren) => React.ReactNode | Promise<React.ReactNode>;
@@ -1,9 +1,16 @@
1
1
  export declare const expectRowError: (prompt: string) => void;
2
2
  export declare const expectRowErrorText: (prompt: string, text: string) => void;
3
3
  export declare const expectNoRowError: (prompt: string) => void;
4
+ export declare const expectQuestionCount: (count: number) => void;
4
5
  export declare const expectText: (text: string, length?: number) => void;
5
6
  export declare const expectSummaryFieldText: (field: string, text: string) => void;
6
7
  export declare const expectNullInput: (ariaLabel: string) => void;
8
+ export declare const expectVisibleQuestion: (prompt: string) => void;
9
+ export declare const expectNoQuestion: (prompt: string) => void;
10
+ export declare const expectCheckbox: (prompt: string) => void;
11
+ export declare const expectNoCheckbox: (prompt: string) => void;
12
+ export declare const expectSection: (title: string) => void;
13
+ export declare const expectNoSection: (title: string) => void;
7
14
  export declare const expectDisabledInput: (ariaLabel: string) => void;
8
15
  export declare const expectInputValue: (ariaLabel: string, value: string) => void;
9
16
  export declare const clickLabel: (ariaLabel: string) => void;
@@ -16,8 +23,11 @@ export declare const clickNext: () => void;
16
23
  export declare const clickSubmit: () => void;
17
24
  export declare const clickAddAdditionalResidence: () => void;
18
25
  export declare const clickRemoveResidence: (index: 1 | 2 | 3 | 4 | 5) => void;
26
+ export declare const clickAddControllingPerson: () => void;
27
+ export declare const clickRemoveControllingPerson: (index: 1 | 2 | 3 | 4 | 5) => void;
19
28
  export declare const setBusinessNameAndAddress: (prefix?: string) => void;
20
29
  export declare const setIndividualNameAndAddress: (prefix?: string) => void;
21
30
  export declare const setUSIndividualNameAndAddress: (prefix?: string) => void;
22
31
  export declare const setIndividualNameAndAddressAndBirthDate: (prefix?: string) => void;
23
32
  export declare const setUSIndividualNameAndAddressAndBirthDate: (prefix?: string) => void;
33
+ export declare const setIndividualCountryNameAndAddressAndBirthDate: (prefix?: string) => void;
@@ -1,4 +1,4 @@
1
- declare const inputSteps: readonly ["AccountHolderClassification", "AccountHolderContact", "AccountHolderTax", "AccountHolderTaxClarification", "AccountHolderTreatyClaims", "Exemptions", "RegardedOwnerContact", "RegardedOwnerTax", "RegardedOwnerTreatyClaims", "Summary", "W8imyInstructions"];
1
+ declare const inputSteps: readonly ["AccountHolderClassification", "AccountHolderContact", "AccountHolderTax", "AccountHolderTaxClarification", "AccountHolderTreatyClaims", "ControllingPersonDetails1", "ControllingPersonDetails2", "ControllingPersonDetails3", "ControllingPersonDetails4", "ControllingPersonDetails5", "Exemptions", "RegardedOwnerContact", "RegardedOwnerTax", "RegardedOwnerTreatyClaims", "Summary", "W8imyInstructions"];
2
2
  export type InputStep = (typeof inputSteps)[number];
3
3
  export declare const isInputStep: (step: string) => step is InputStep;
4
4
  export declare const confirmInputStep: (step: string) => InputStep;
@@ -1,6 +1,5 @@
1
1
  import { Locale } from './Locale';
2
2
  import { StepId } from './StepId';
3
-
4
3
  export type Progress = {
5
4
  language: Locale;
6
5
  percentComplete: number;
@@ -0,0 +1 @@
1
+ export type QuestionnaireProp = 'W-FORM' | 'DPS' | 'SELF-CERT';
@@ -1 +1 @@
1
- export type StepId = 'accountHolderContactInformation' | 'accountHolderTaxInformation' | 'accountHolderClassification' | 'accountHolderTaxClarification' | 'accountHolderTreatyClaims' | 'confirmation' | 'exemptions' | 'regardedOwnerContactInformation' | 'regardedOwnerTaxInformation' | 'regardedOwnerTreatyClaims' | 'summary' | 'w8imyInstructions';
1
+ export type StepId = 'accountHolderContactInformation' | 'accountHolderTaxInformation' | 'accountHolderClassification' | 'accountHolderTaxClarification' | 'accountHolderTreatyClaims' | 'confirmation' | 'controllingPersonDetails1' | 'controllingPersonDetails2' | 'controllingPersonDetails3' | 'controllingPersonDetails4' | 'controllingPersonDetails5' | 'exemptions' | 'regardedOwnerContactInformation' | 'regardedOwnerTaxInformation' | 'regardedOwnerTreatyClaims' | 'summary' | 'w8imyInstructions';
@@ -1,7 +1,6 @@
1
- import { ForeignAccountHolderAccountType, ForeignOtherClassification, ForeignRegardedOwnerAccountType, ForeignTrustClassification, UsAccountHolderAccountType, UsLLCAccountType, UsRegardedOwnerAccountType } from '@taxbit/utilities';
1
+ import { ActiveNonFinancialEntityType, EntityType, FinancialInstitutionType, ForeignAccountHolderAccountType, ForeignOtherClassification, ForeignRegardedOwnerAccountType, ForeignTrustClassification, SelfCertificationAccountType, UsAccountHolderAccountType, UsLLCAccountType, UsRegardedOwnerAccountType } from '@taxbit/utilities';
2
2
  import { Yes } from './Yes';
3
3
  import { YesNo } from './YesNo';
4
-
5
4
  export type AccountHolderClassificationData = {
6
5
  accountHolderIsIndividual?: YesNo;
7
6
  accountHolderUsPerson?: YesNo;
@@ -15,25 +14,30 @@ export type AccountHolderClassificationData = {
15
14
  accountHolderForeignTrustClassification?: ForeignTrustClassification;
16
15
  accountHolderForeignOtherClassification?: ForeignOtherClassification;
17
16
  };
18
- export type AccountHolderContactData = {
19
- accountHolderAddressCity?: string;
20
- accountHolderAddressCountry?: string;
21
- accountHolderAddressState?: string;
22
- accountHolderAddressStreet2?: string;
23
- accountHolderAddressStreet?: string;
24
- accountHolderAddressZip?: string;
17
+ type Address<Prefix extends string> = {
18
+ [key in `${Prefix}Address`]?: string;
19
+ } & {
20
+ [key in `${Prefix}AddressCity`]?: string;
21
+ } & {
22
+ [key in `${Prefix}AddressCountry`]?: string;
23
+ } & {
24
+ [key in `${Prefix}AddressState`]?: string;
25
+ } & {
26
+ [key in `${Prefix}AddressStreet2`]?: string;
27
+ } & {
28
+ [key in `${Prefix}AddressStreet`]?: string;
29
+ } & {
30
+ [key in `${Prefix}AddressZip`]?: string;
31
+ };
32
+ export type AccountHolderContactData = Address<'accountHolder'> & Address<'accountHolderMailing'> & {
25
33
  accountHolderCityOfBirth?: string;
26
34
  accountHolderCountryOfBirth?: string;
35
+ accountHolderOptionalCityOfBirth?: string;
36
+ accountHolderOptionalCountryOfBirth?: string;
27
37
  accountHolderCountryOfCitizenship?: string;
28
38
  accountHolderDateOfBirth?: string;
29
39
  accountHolderDbaName?: string;
30
- accountHolderMailingAddressCity?: string;
31
- accountHolderMailingAddressCountry?: string;
32
40
  accountHolderMailingAddressIsDifferent?: Yes;
33
- accountHolderMailingAddressState?: string;
34
- accountHolderMailingAddressStreet2?: string;
35
- accountHolderMailingAddressStreet?: string;
36
- accountHolderMailingAddressZip?: string;
37
41
  accountHolderName?: string;
38
42
  };
39
43
  export type AccountHolderTreatyClaimData = {
@@ -58,38 +62,73 @@ export type RegardedOwnerTreatyClaimData = {
58
62
  regardedOwnerTreatyClaimWithholding?: string;
59
63
  regardedOwnerTreatyClaimHasAdditionalConditions?: Yes;
60
64
  };
61
- export type AccountHolderTaxData = {
65
+ type Iterate1_5 = '1' | '2' | '3' | '4' | '5';
66
+ type ResidencesKey<Prefix extends string> = `${Prefix}TaxResidences`;
67
+ type ResidenceCountryKey<Prefix extends string> = `${Prefix}TaxResidenceCountry${Iterate1_5}`;
68
+ type ResidenceTinKey<Prefix extends string> = `${Prefix}TaxResidenceTin${Iterate1_5}`;
69
+ type ResidenceTinNotRequiredKey<Prefix extends string> = `${Prefix}TaxResidenceTinIsNotRequired${Iterate1_5}`;
70
+ type ResidenceTinNotRequiredReasonKey<Prefix extends string> = `${Prefix}TaxResidenceTinIsNotRequiredReason${Iterate1_5}`;
71
+ type ResidenceTinNotRequiredReasonOtherKey<Prefix extends string> = `${Prefix}TaxResidenceTinIsNotRequiredReasonOther${Iterate1_5}`;
72
+ type ResidenceShowKey<Prefix extends string> = `${Prefix}ShowTaxResidence${Iterate1_5}`;
73
+ type Residences<Prefix extends string> = {
74
+ [key in ResidencesKey<Prefix>]?: YesNo;
75
+ } & {
76
+ [key in ResidenceCountryKey<Prefix>]?: string;
77
+ } & {
78
+ [key in ResidenceTinKey<Prefix>]?: string;
79
+ } & {
80
+ [key in ResidenceTinNotRequiredKey<Prefix>]?: Yes;
81
+ } & {
82
+ [key in ResidenceTinNotRequiredReasonKey<Prefix>]?: string;
83
+ } & {
84
+ [key in ResidenceTinNotRequiredReasonOtherKey<Prefix>]?: string;
85
+ } & {
86
+ [key in ResidenceShowKey<Prefix>]?: YesNo;
87
+ };
88
+ export type AccountHolderTaxData = Residences<'accountHolder'> & {
62
89
  accountHolderForeignTin?: string;
63
90
  accountHolderForeignTinIsNotRequired?: Yes;
64
91
  accountHolderUsTin?: string;
65
92
  accountHolderFinancialAccountIdentifier?: string;
66
93
  accountHolderFinancialAccountName?: string;
67
- accountHolderTaxResidenceCountry1?: string;
68
- accountHolderTaxResidenceTin1?: string;
69
- accountHolderTaxResidenceTin1IsNotRequired?: Yes;
70
- accountHolderTaxResidenceCountry2?: string;
71
- accountHolderTaxResidenceTin2?: string;
72
- accountHolderTaxResidenceTin2IsNotRequired?: Yes;
73
- accountHolderTaxResidenceCountry3?: string;
74
- accountHolderTaxResidenceTin3?: string;
75
- accountHolderTaxResidenceTin3IsNotRequired?: Yes;
76
- accountHolderTaxResidenceCountry4?: string;
77
- accountHolderTaxResidenceTin4?: string;
78
- accountHolderTaxResidenceTin4IsNotRequired?: Yes;
79
- accountHolderTaxResidenceCountry5?: string;
80
- accountHolderTaxResidenceTin5?: string;
81
- accountHolderTaxResidenceTin5IsNotRequired?: Yes;
82
- accountHolderShowTaxResidence1?: YesNo;
83
- accountHolderShowTaxResidence2?: YesNo;
84
- accountHolderShowTaxResidence3?: YesNo;
85
- accountHolderShowTaxResidence4?: YesNo;
86
- accountHolderShowTaxResidence5?: YesNo;
87
94
  accountHolderVatIdentificationNumber?: string;
88
95
  accountHolderVatIsNotRequired?: Yes;
89
96
  accountHolderVatCountry?: string;
90
97
  accountHolderBusinessRegistrationNumber?: string;
91
98
  accountHolderBusinessRegistrationCountry?: string;
99
+ accountHolderSelfCertificationAccountType?: SelfCertificationAccountType;
100
+ accountHolderActiveNonFinancialEntityType?: ActiveNonFinancialEntityType;
101
+ accountHolderFinancialInstitutionType?: FinancialInstitutionType;
102
+ accountHolderInvestmentEntityManaged?: YesNo;
103
+ accountHolderEntityType?: EntityType;
104
+ accountHolderSecuritiesMarket?: string;
105
+ accountHolderRelatedCorporation?: string;
92
106
  };
107
+ type ControllingPersonPrefix = `controllingPerson${Iterate1_5}`;
108
+ type ControllingPerson = {
109
+ [key in `${ControllingPersonPrefix}ShowFields`]?: Yes;
110
+ } & {
111
+ [key in `${ControllingPersonPrefix}Name`]?: string;
112
+ } & {
113
+ [key in `${ControllingPersonPrefix}Role`]?: string;
114
+ } & {
115
+ [key in `${ControllingPersonPrefix}RoleOther`]?: string;
116
+ } & {
117
+ [key in `${ControllingPersonPrefix}RoleOtherEquivalent`]?: string;
118
+ } & {
119
+ [key in `${ControllingPersonPrefix}OwnershipPercentage`]?: string;
120
+ } & {
121
+ [key in `${ControllingPersonPrefix}DateOfBirth`]?: string;
122
+ } & {
123
+ [key in `${ControllingPersonPrefix}CityOfBirth`]?: string;
124
+ } & {
125
+ [key in `${ControllingPersonPrefix}CountryOfBirth`]?: string;
126
+ } & {
127
+ [key in `${ControllingPersonPrefix}CountryOfCitizenship`]?: string;
128
+ } & {
129
+ [key in `${ControllingPersonPrefix}MailingAddressIsDifferent`]?: Yes;
130
+ } & Address<ControllingPersonPrefix> & Address<`${ControllingPersonPrefix}Mailing`>;
131
+ export type ControllingPersonClassificationData = Residences<ControllingPersonPrefix> & ControllingPerson;
93
132
  export type RegardedOwnerClassificationData = {
94
133
  regardedOwnerUsPerson?: YesNo;
95
134
  regardedOwnerUsAccountType?: UsRegardedOwnerAccountType;
@@ -100,24 +139,12 @@ export type RegardedOwnerClassificationData = {
100
139
  regardedOwnerForeignOtherClassification?: ForeignOtherClassification;
101
140
  };
102
141
  export type RegardedOwnerContactData = {
103
- regardedOwnerAddressCity?: string;
104
- regardedOwnerAddressCountry?: string;
105
- regardedOwnerAddressState?: string;
106
- regardedOwnerAddressStreet2?: string;
107
- regardedOwnerAddressStreet?: string;
108
- regardedOwnerAddressZip?: string;
109
142
  regardedOwnerCountryOfCitizenship?: string;
110
143
  regardedOwnerDateOfBirth?: string;
111
144
  regardedOwnerDbaName?: string;
112
- regardedOwnerMailingAddressCity?: string;
113
- regardedOwnerMailingAddressCountry?: string;
114
145
  regardedOwnerMailingAddressIsDifferent?: Yes;
115
- regardedOwnerMailingAddressState?: string;
116
- regardedOwnerMailingAddressStreet2?: string;
117
- regardedOwnerMailingAddressStreet?: string;
118
- regardedOwnerMailingAddressZip?: string;
119
146
  regardedOwnerName?: string;
120
- };
147
+ } & Address<'regardedOwner'> & Address<'regardedOwnerMailing'>;
121
148
  export type RegardedOwnerTaxData = {
122
149
  regardedOwnerForeignTin?: string;
123
150
  regardedOwnerForeignTinIsNotRequired?: Yes;
@@ -127,7 +154,6 @@ export type SummaryData = {
127
154
  exemptFatcaCode?: string;
128
155
  exemptPayeeCode?: string;
129
156
  iAcknowledgeESignIsOk?: Yes;
130
- iAgreeWillResubmitIfIncorrect?: Yes;
131
157
  iAmACitizenOfTheUs?: Yes;
132
158
  iAmExemptFromFatcaReporting?: Yes;
133
159
  iAmNotSubjectToBackupWithholding?: Yes;
@@ -141,7 +167,16 @@ export type SummaryData = {
141
167
  iConfirmTheInformationIsCorrectComplete?: Yes;
142
168
  iConfirmTheTaxIdIsCorrect?: Yes;
143
169
  iHaveCapacityToSign?: Yes;
170
+ iWillResubmitIfIncorrect?: Yes;
171
+ iUnderstandTheInformationIsCovered?: Yes;
172
+ iAcknowledgeTheInformationMayBeProvided?: Yes;
173
+ iCertifyIAmAccountHolder?: Yes;
174
+ iCertifyIWillNotifyPersons?: Yes;
175
+ iDeclareStatementsAreCorrect?: Yes;
176
+ iWillNotifyChangeInCircumstance?: Yes;
144
177
  signature?: string;
178
+ signatureCapacity?: string;
179
+ signatureCapacityOther?: string;
145
180
  source?: string;
146
181
  };
147
182
  export type CalculatedData = {
@@ -151,5 +186,6 @@ export type CalculatedData = {
151
186
  regardedOwnerAddress?: string;
152
187
  regardedOwnerMailingAddress?: string;
153
188
  };
154
- export type TaxDocumentation = AccountHolderContactData & AccountHolderTaxData & AccountHolderClassificationData & RegardedOwnerContactData & RegardedOwnerClassificationData & RegardedOwnerTaxData & SummaryData & CalculatedData & AccountHolderTreatyClaimData & RegardedOwnerTreatyClaimData;
189
+ export type TaxDocumentation = AccountHolderContactData & AccountHolderTaxData & AccountHolderClassificationData & RegardedOwnerContactData & RegardedOwnerClassificationData & RegardedOwnerTaxData & SummaryData & CalculatedData & AccountHolderTreatyClaimData & RegardedOwnerTreatyClaimData & ControllingPersonClassificationData;
155
190
  export type TaxDocumentationKey = keyof TaxDocumentation;
191
+ export {};
@@ -13,4 +13,8 @@ export type ClientTaxDocumentationStatus = {
13
13
  tinValidationDate?: string;
14
14
  needsResubmission: boolean;
15
15
  };
16
+ selfCertification?: {
17
+ dataCollectionStatus: 'COMPLETE' | 'INCOMPLETE';
18
+ needsResubmission: boolean;
19
+ };
16
20
  };
@@ -2,7 +2,7 @@ export * from './CamelCaseKeys';
2
2
  export * from './InputStep';
3
3
  export * from './Locale';
4
4
  export * from './Progress';
5
- export * from './Questionnaire';
5
+ export * from './QuestionnaireProp.ts';
6
6
  export * from './TaxDocumentation';
7
7
  export * from './Utilities';
8
8
  export * from './Yes';
@@ -13,4 +13,8 @@ export type TaxDocumentationStatus = {
13
13
  tin_validation_date?: string;
14
14
  needs_resubmission: boolean;
15
15
  };
16
+ self_certification: {
17
+ data_collection_status: 'COMPLETE' | 'INCOMPLETE';
18
+ needs_resubmission: boolean;
19
+ };
16
20
  };
@@ -1,6 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { TaxDocumentationKey } from 'types/TaxDocumentation';
3
-
4
3
  export type ActionButtonProps = {
5
4
  name: TaxDocumentationKey;
6
5
  onClick: () => void;
@@ -1,5 +1,4 @@
1
1
  import { default as React } from 'react';
2
-
3
2
  type ActionsProps = {
4
3
  onBack?: (data: unknown) => void;
5
4
  onNext?: (data: unknown) => void;
@@ -1,7 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
  import { TaxDocumentationKey } from 'types/TaxDocumentation';
3
3
  import { Yes } from 'types/Yes';
4
-
5
4
  export type CheckBoxProps = {
6
5
  label: boolean;
7
6
  subLabel?: boolean;
@@ -1,6 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { TaxDocumentationKey } from 'types/TaxDocumentation';
3
-
4
3
  export type DateOfBirthInputProps = {
5
4
  name: TaxDocumentationKey;
6
5
  className?: string;