@taxbit/react-sdk 0.0.16 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +225 -4
- package/dist/basic.css +32 -6
- package/dist/components/Page/Page.d.ts +3 -1
- package/dist/components/index.d.ts +0 -1
- package/dist/contexts/FormUI/useFormUI.d.ts +3 -2
- package/dist/contexts/FormUI/useFormUIContext.d.ts +4 -8
- package/dist/contexts/TaxDocumentation/TaxBitFormProvider.d.ts +1 -2
- package/dist/contexts/TaxDocumentation/useTaxDocumentation.d.ts +3 -3
- package/dist/contexts/TaxDocumentation/useTaxDocumentationContext.d.ts +10 -12
- package/dist/entry/index.d.ts +2 -3
- package/dist/i18n/i18n.d.ts +1 -1
- package/dist/i18n/index.d.ts +1 -2
- package/dist/i18n/locales/bg-bg.d.ts +2 -0
- package/dist/i18n/locales/cs-cz.d.ts +2 -0
- package/dist/i18n/locales/el-gr.d.ts +2 -0
- package/dist/i18n/locales/et-ee.d.ts +2 -0
- package/dist/i18n/locales/hu-hu.d.ts +2 -0
- package/dist/i18n/locales/index.d.ts +9 -0
- package/dist/i18n/locales/mt-mt.d.ts +2 -0
- package/dist/i18n/locales/ro-ro.d.ts +2 -0
- package/dist/i18n/locales/sk-sk.d.ts +2 -0
- package/dist/i18n/locales/sl-si.d.ts +2 -0
- package/dist/i18n/types/LocalizationKey.d.ts +3 -2
- package/dist/i18n/types/PropertyFile.d.ts +6 -2
- package/dist/i18n/types/index.d.ts +0 -1
- package/dist/i18n/utils/getText.d.ts +16 -15
- package/dist/index.css +4 -0
- package/dist/inline.css +33 -6
- package/dist/lookups/dayOptions.d.ts +1 -1
- package/dist/lookups/index.d.ts +3 -2
- package/dist/lookups/localeOptions.d.ts +4 -0
- package/dist/minimal.css +0 -1
- package/dist/taxbit-react-sdk.es.js +8541 -3165
- package/dist/taxbit-react-sdk.umd.js +10 -10
- package/dist/types/Locale.d.ts +1 -0
- package/dist/types/TaxDocumentation.d.ts +0 -1
- package/dist/types/external/ComprehensiveTaxDocumentation.d.ts +13 -6
- package/dist/types/index.d.ts +1 -0
- package/dist/ui/HideShowButton/HideShowButton.d.ts +5 -0
- package/dist/ui/HideShowButton/index.d.ts +1 -0
- package/dist/ui/MaskedContent/MaskedContent.d.ts +4 -0
- package/dist/ui/MaskedContent/index.d.ts +1 -0
- package/dist/ui/MaskedInput/MaskedInput.d.ts +10 -0
- package/dist/ui/MaskedInput/index.d.ts +1 -0
- package/dist/ui/Password/Password.d.ts +11 -0
- package/dist/ui/Password/index.d.ts +1 -0
- package/dist/ui/TextInput/TextInput.d.ts +2 -1
- package/dist/ui/index.d.ts +2 -0
- package/dist/utils/getHintKeyMap.d.ts +0 -1
- package/dist/utils/getMonthlyDayCount.d.ts +1 -0
- package/dist/utils/getPromptKeyMap.d.ts +0 -1
- package/dist/utils/getRequiredFields.d.ts +103 -0
- package/dist/utils/getValidationMessages.d.ts +104 -0
- package/dist/utils/index.d.ts +2 -1
- package/dist/utils/transformOutbound/convertYesNoToBoolean.d.ts +2 -0
- package/dist/utils/transformOutbound/transformOutbound.d.ts +3 -0
- package/dist/utils/transformOutbound/transformToOutboundAccoutHolder.d.ts +3 -0
- package/dist/utils/transformOutbound/transformToOutboundAddress.d.ts +6 -0
- package/dist/utils/transformOutbound/transformToOutboundRegardedOwner.d.ts +3 -0
- package/dist/utils/transformOutbound/transformToOutboundTaxResidenceFields.d.ts +4 -0
- package/dist/validations/index.d.ts +1 -0
- package/dist/validations/requiredFields.d.ts +7 -0
- package/dist/widgets/TaxBitForm/TaxBitDAC7Form.d.ts +1 -1
- package/dist/widgets/TaxBitForm/TaxBitForm.d.ts +1 -2
- package/dist/wizard/LanguageSelector/LanguageSelector.d.ts +2 -0
- package/dist/wizard/LanguageSelector/index.d.ts +1 -0
- package/dist/{paths → wizard}/RowInput/CheckBoxRow/CheckBoxRow.d.ts +2 -2
- package/dist/wizard/RowInput/MaskedInputRow/MaskedInputRow.d.ts +10 -0
- package/dist/wizard/RowInput/MaskedInputRow/index.d.ts +1 -0
- package/dist/{paths → wizard}/RowInput/TextInputRow/TextInputRow.d.ts +3 -1
- package/dist/{paths → wizard}/RowInput/index.d.ts +1 -1
- package/dist/{paths → wizard}/TaxBitFormUI/TaxBitDAC7FormUI.d.ts +1 -2
- package/dist/{paths → wizard}/TaxBitFormUI/TaxBitFormUI.d.ts +1 -2
- package/package.json +2 -1
- package/dist/components/Title/Title.d.ts +0 -5
- package/dist/components/Title/index.d.ts +0 -1
- package/dist/i18n/types/Locale.d.ts +0 -1
- package/dist/paths/FinancialAccountInput/FinancialAccountInput.d.ts +0 -2
- package/dist/paths/FinancialAccountInput/index.d.ts +0 -1
- package/dist/paths/RowInput/ErrorRow/ErrorRow.d.ts +0 -2
- package/dist/paths/RowInput/ErrorRow/index.d.ts +0 -1
- package/dist/paths/VatInput/VatInput.d.ts +0 -8
- package/dist/paths/VatInput/index.d.ts +0 -1
- package/dist/utils/transformOutbound.d.ts +0 -3
- /package/dist/{paths → wizard}/AddressInput/AddressInput.d.ts +0 -0
- /package/dist/{paths → wizard}/AddressInput/index.d.ts +0 -0
- /package/dist/{paths → wizard}/PlaceOfBirthInput/PlaceOfBirthInput.d.ts +0 -0
- /package/dist/{paths → wizard}/PlaceOfBirthInput/index.d.ts +0 -0
- /package/dist/{paths → wizard}/ResidenceInput/ResidenceInput.d.ts +0 -0
- /package/dist/{paths → wizard}/ResidenceInput/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/CheckBoxRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/DateOfBirthRow/DateOfBirthRow.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/DateOfBirthRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/RadioButtonRow/RadioButtonRow.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/RadioButtonRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/SelectRow/SelectRow.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/SelectRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/TextInputRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/ToggleButtonRow/ToggleButtonRow.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/ToggleButtonRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/VisibleRow/VisibleRow.d.ts +0 -0
- /package/dist/{paths → wizard}/RowInput/VisibleRow/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderClassification/AccountHolderClassification.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderClassification/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderContact/AccountHolderContact.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderContact/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderTax/AccountHolderTax.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderTax/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderTaxClarification/AccountHolderTaxClarification.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/AccountHolderTaxClarification/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/Exemptions/Exemptions.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/Exemptions/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerClassification/RegardedOwnerClassification.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerClassification/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerContact/RegardedOwnerContact.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerContact/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerTax/RegardedOwnerTax.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/RegardedOwnerTax/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/Summary/Recap.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/Summary/Summary.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/Summary/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/index.d.ts +0 -0
- /package/dist/{paths → wizard}/TaxBitFormUI/steps.d.ts +0 -0
- /package/dist/{paths → wizard}/index.d.ts +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type Locale = "bg-bg" | "cs-cz" | "de-de" | "el-gr" | "en-gb" | "en-us" | "es-es" | "et-ee" | "fr-fr" | "hu-hu" | "it-it" | "mt-mt" | "nl-nl" | "no-no" | "pt-pt" | "ro-ro" | "sk-sk" | "sl-si" | "sv-se";
|
|
@@ -38,7 +38,6 @@ export type AccountHolderContactData = {
|
|
|
38
38
|
export type AccountHolderTaxData = {
|
|
39
39
|
accountHolderFinancialAccountIdentifier?: string;
|
|
40
40
|
accountHolderFinancialAccountName?: string;
|
|
41
|
-
accountHolderFinancialAccountNameSameAsAccountHolderName?: Yes;
|
|
42
41
|
accountHolderForeignTin?: string;
|
|
43
42
|
accountHolderForeignTinIsNotRequired?: Yes;
|
|
44
43
|
accountHolderTaxResidenceCountry1?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { CamelCasedPropertiesDeep } from "type-fest";
|
|
2
|
-
type Address = {
|
|
2
|
+
export type Address = {
|
|
3
3
|
city?: string;
|
|
4
4
|
country?: string;
|
|
5
5
|
state_or_province?: string;
|
|
@@ -7,7 +7,7 @@ type Address = {
|
|
|
7
7
|
second_line?: string;
|
|
8
8
|
postal_code?: string;
|
|
9
9
|
};
|
|
10
|
-
type AccountHolderTaxDocumentation = {
|
|
10
|
+
export type AccountHolderTaxDocumentation = {
|
|
11
11
|
address?: Address;
|
|
12
12
|
country_of_citizenship?: string;
|
|
13
13
|
date_of_birth?: string;
|
|
@@ -17,7 +17,6 @@ type AccountHolderTaxDocumentation = {
|
|
|
17
17
|
name?: string;
|
|
18
18
|
city_of_birth?: string;
|
|
19
19
|
country_of_birth?: string;
|
|
20
|
-
business_registration_number?: string;
|
|
21
20
|
financial_account_identifier?: string;
|
|
22
21
|
financial_account_name?: string;
|
|
23
22
|
ftin?: string;
|
|
@@ -46,7 +45,7 @@ type AccountHolderTaxDocumentation = {
|
|
|
46
45
|
foreign_trust_classification?: string;
|
|
47
46
|
foreign_other_classification?: string;
|
|
48
47
|
};
|
|
49
|
-
type RegardedOwnerTaxDocumentation = {
|
|
48
|
+
export type RegardedOwnerTaxDocumentation = {
|
|
50
49
|
address?: Address;
|
|
51
50
|
country_of_citizenship?: string;
|
|
52
51
|
date_of_birth?: string;
|
|
@@ -75,8 +74,16 @@ export type SignedComprehensiveTaxDocumentation = {
|
|
|
75
74
|
} & {
|
|
76
75
|
has_certified?: boolean;
|
|
77
76
|
is_not_subject_backup_withholding?: boolean;
|
|
78
|
-
signature
|
|
77
|
+
signature?: string;
|
|
79
78
|
document_type: "COMPREHENSIVE";
|
|
80
79
|
};
|
|
80
|
+
export declare enum ComprehensiveStatus {
|
|
81
|
+
Undocumented = "UNDOCUMENTED",
|
|
82
|
+
Undetermined = "UNDETERMINED"
|
|
83
|
+
}
|
|
84
|
+
export declare enum ComprehensiveFormStatus {
|
|
85
|
+
Collected = "COLLECTED",
|
|
86
|
+
NotCollected = "NOT_COLLECTED",
|
|
87
|
+
PartiallyCollected = "PARTIALLY_COLLECTED"
|
|
88
|
+
}
|
|
81
89
|
export type ClientTaxDocumentation = CamelCasedPropertiesDeep<AccountHolderTaxDocumentation>;
|
|
82
|
-
export {};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./HideShowButton";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./MaskedContent";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { TaxDocumentationKey } from "types/TaxDocumentation";
|
|
3
|
+
export type MaskedInputProps = {
|
|
4
|
+
name: TaxDocumentationKey;
|
|
5
|
+
className?: string;
|
|
6
|
+
onChange?: (val: string) => string;
|
|
7
|
+
hint?: true;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
};
|
|
10
|
+
export declare const MaskedInput: ({ name, className, onChange, hint, children, }: MaskedInputProps) => React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./MaskedInput.tsx";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
type PasswordProps = {
|
|
3
|
+
value?: string;
|
|
4
|
+
mask?: string;
|
|
5
|
+
timeout?: number;
|
|
6
|
+
onChange?: (val: string) => void;
|
|
7
|
+
show?: boolean;
|
|
8
|
+
className?: string;
|
|
9
|
+
};
|
|
10
|
+
export declare const Password: ({ value, mask, timeout, onChange, show, ...inputProps }: PasswordProps) => React.JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Password";
|
|
@@ -7,5 +7,6 @@ export type TextInputProps = {
|
|
|
7
7
|
hint?: true;
|
|
8
8
|
disabled?: boolean;
|
|
9
9
|
children?: React.ReactNode;
|
|
10
|
+
syncName?: TaxDocumentationKey;
|
|
10
11
|
};
|
|
11
|
-
export declare const TextInput: ({ name, className, onChange, hint, children, disabled, }: TextInputProps) => React.JSX.Element;
|
|
12
|
+
export declare const TextInput: ({ name, className, onChange, hint, children, disabled, syncName, }: TextInputProps) => React.JSX.Element;
|
package/dist/ui/index.d.ts
CHANGED
|
@@ -38,7 +38,6 @@ export declare const getHintKeyMap: () => {
|
|
|
38
38
|
accountHolderName?: "dateOfBirth" | undefined;
|
|
39
39
|
accountHolderFinancialAccountIdentifier?: "dateOfBirth" | undefined;
|
|
40
40
|
accountHolderFinancialAccountName?: "dateOfBirth" | undefined;
|
|
41
|
-
accountHolderFinancialAccountNameSameAsAccountHolderName?: "dateOfBirth" | undefined;
|
|
42
41
|
accountHolderForeignTin?: "dateOfBirth" | undefined;
|
|
43
42
|
accountHolderForeignTinIsNotRequired?: "dateOfBirth" | undefined;
|
|
44
43
|
accountHolderTaxResidenceCountry1?: "dateOfBirth" | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const getMonthlyDayCount: (month: number, year?: number) => number;
|
|
@@ -38,7 +38,6 @@ export declare const getPromptKeyMap: (data: TaxDocumentation) => {
|
|
|
38
38
|
accountHolderName?: PromptKey | undefined;
|
|
39
39
|
accountHolderFinancialAccountIdentifier?: PromptKey | undefined;
|
|
40
40
|
accountHolderFinancialAccountName?: PromptKey | undefined;
|
|
41
|
-
accountHolderFinancialAccountNameSameAsAccountHolderName?: PromptKey | undefined;
|
|
42
41
|
accountHolderForeignTin?: PromptKey | undefined;
|
|
43
42
|
accountHolderForeignTinIsNotRequired?: PromptKey | undefined;
|
|
44
43
|
accountHolderTaxResidenceCountry1?: PromptKey | undefined;
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { TaxDocumentation, TaxDocumentationKey } from "../types";
|
|
2
|
+
export declare const getRequiredFields: (fields: TaxDocumentation) => {
|
|
3
|
+
exemptPayeeCode: boolean | undefined;
|
|
4
|
+
exemptFatcaCode: boolean | undefined;
|
|
5
|
+
iAcknowlegeESignIsOk: boolean | undefined;
|
|
6
|
+
iAmACitizenOfTheUs: boolean | undefined;
|
|
7
|
+
iAmExemptFromFatcaReporting: boolean | undefined;
|
|
8
|
+
iAmNotSubjectToBackupWithholding: boolean | undefined;
|
|
9
|
+
iAuthorizeWithholdingAgent: boolean | undefined;
|
|
10
|
+
iCertifyToAll: boolean | undefined;
|
|
11
|
+
iConfirmIncomeIsNonUs: boolean | undefined;
|
|
12
|
+
iConfirmTheBeneficialOwnerIsExempt: boolean | undefined;
|
|
13
|
+
iConfirmTheEntityIsNotAUsPerson: boolean | undefined;
|
|
14
|
+
iConfirmTheEntityIsTheBeneficialOwner: boolean | undefined;
|
|
15
|
+
iConfirmTheTaxIdIsCorrect: boolean | undefined;
|
|
16
|
+
iHaveLegalCapacityToSign: boolean | undefined;
|
|
17
|
+
regardedOwnerUsPerson: boolean | undefined;
|
|
18
|
+
signature: boolean | undefined;
|
|
19
|
+
accountHolderAddressCity: boolean | undefined;
|
|
20
|
+
accountHolderAddressCountry: boolean | undefined;
|
|
21
|
+
accountHolderAddressState: boolean | undefined;
|
|
22
|
+
accountHolderAddressStreet2: boolean | undefined;
|
|
23
|
+
accountHolderAddressStreet: boolean | undefined;
|
|
24
|
+
accountHolderAddressZip: boolean | undefined;
|
|
25
|
+
accountHolderCityOfBirth: boolean | undefined;
|
|
26
|
+
accountHolderCountryOfBirth: boolean | undefined;
|
|
27
|
+
accountHolderCountryOfCitizenship: boolean | undefined;
|
|
28
|
+
accountHolderDateOfBirth: boolean | undefined;
|
|
29
|
+
accountHolderDbaName: boolean | undefined;
|
|
30
|
+
accountHolderMailingAddressCity: boolean | undefined;
|
|
31
|
+
accountHolderMailingAddressCountry: boolean | undefined;
|
|
32
|
+
accountHolderMailingAddressIsDifferent: boolean | undefined;
|
|
33
|
+
accountHolderMailingAddressState: boolean | undefined;
|
|
34
|
+
accountHolderMailingAddressStreet2: boolean | undefined;
|
|
35
|
+
accountHolderMailingAddressStreet: boolean | undefined;
|
|
36
|
+
accountHolderMailingAddressZip: boolean | undefined;
|
|
37
|
+
accountHolderName: boolean | undefined;
|
|
38
|
+
accountHolderFinancialAccountIdentifier: boolean | undefined;
|
|
39
|
+
accountHolderFinancialAccountName: boolean | undefined;
|
|
40
|
+
accountHolderForeignTin: boolean | undefined;
|
|
41
|
+
accountHolderForeignTinIsNotRequired: boolean | undefined;
|
|
42
|
+
accountHolderTaxResidenceCountry1: boolean | undefined;
|
|
43
|
+
accountHolderTaxResidenceForeignTin1: boolean | undefined;
|
|
44
|
+
accountHolderTaxResidenceForeignTin1IsNotRequired: boolean | undefined;
|
|
45
|
+
accountHolderTaxResidenceCountry2: boolean | undefined;
|
|
46
|
+
accountHolderTaxResidenceForeignTin2: boolean | undefined;
|
|
47
|
+
accountHolderTaxResidenceForeignTin2IsNotRequired: boolean | undefined;
|
|
48
|
+
accountHolderTaxResidenceCountry3: boolean | undefined;
|
|
49
|
+
accountHolderTaxResidenceForeignTin3: boolean | undefined;
|
|
50
|
+
accountHolderTaxResidenceForeignTin3IsNotRequired: boolean | undefined;
|
|
51
|
+
accountHolderTaxResidenceCountry4: boolean | undefined;
|
|
52
|
+
accountHolderTaxResidenceForeignTin4: boolean | undefined;
|
|
53
|
+
accountHolderTaxResidenceForeignTin4IsNotRequired: boolean | undefined;
|
|
54
|
+
accountHolderTaxResidenceCountry5: boolean | undefined;
|
|
55
|
+
accountHolderTaxResidenceForeignTin5: boolean | undefined;
|
|
56
|
+
accountHolderTaxResidenceForeignTin5IsNotRequired: boolean | undefined;
|
|
57
|
+
accountHolderShowTaxResidence2: boolean | undefined;
|
|
58
|
+
accountHolderShowTaxResidence3: boolean | undefined;
|
|
59
|
+
accountHolderShowTaxResidence4: boolean | undefined;
|
|
60
|
+
accountHolderShowTaxResidence5: boolean | undefined;
|
|
61
|
+
accountHolderUsTin: boolean | undefined;
|
|
62
|
+
accountHolderVatIdentificationNumber: boolean | undefined;
|
|
63
|
+
accountHolderVatIdentificationNumberIsNotRequired: boolean | undefined;
|
|
64
|
+
accountHolderVatCountry: boolean | undefined;
|
|
65
|
+
accountHolderIsIndividual: boolean | undefined;
|
|
66
|
+
accountHolderIsEuResident: boolean | undefined;
|
|
67
|
+
accountHolderUsPerson: boolean | undefined;
|
|
68
|
+
accountHolderUsAccountType: boolean | undefined;
|
|
69
|
+
accountHolderUsSmllcElection: boolean | undefined;
|
|
70
|
+
accountHolderUsLlcClassification: boolean | undefined;
|
|
71
|
+
accountHolderUsOtherClassification: boolean | undefined;
|
|
72
|
+
accountHolderUsTrustEstateEin: boolean | undefined;
|
|
73
|
+
accountHolderForeignAccountType: boolean | undefined;
|
|
74
|
+
accountHolderForeignTrustClassification: boolean | undefined;
|
|
75
|
+
accountHolderForeignOtherClassification: boolean | undefined;
|
|
76
|
+
regardedOwnerAddressCity: boolean | undefined;
|
|
77
|
+
regardedOwnerAddressCountry: boolean | undefined;
|
|
78
|
+
regardedOwnerAddressState: boolean | undefined;
|
|
79
|
+
regardedOwnerAddressStreet2: boolean | undefined;
|
|
80
|
+
regardedOwnerAddressStreet: boolean | undefined;
|
|
81
|
+
regardedOwnerAddressZip: boolean | undefined;
|
|
82
|
+
regardedOwnerCountryOfCitizenship: boolean | undefined;
|
|
83
|
+
regardedOwnerDateOfBirth: boolean | undefined;
|
|
84
|
+
regardedOwnerDbaName: boolean | undefined;
|
|
85
|
+
regardedOwnerMailingAddressCity: boolean | undefined;
|
|
86
|
+
regardedOwnerMailingAddressCountry: boolean | undefined;
|
|
87
|
+
regardedOwnerMailingAddressIsDifferent: boolean | undefined;
|
|
88
|
+
regardedOwnerMailingAddressState: boolean | undefined;
|
|
89
|
+
regardedOwnerMailingAddressStreet2: boolean | undefined;
|
|
90
|
+
regardedOwnerMailingAddressStreet: boolean | undefined;
|
|
91
|
+
regardedOwnerMailingAddressZip: boolean | undefined;
|
|
92
|
+
regardedOwnerName: boolean | undefined;
|
|
93
|
+
regardedOwnerUsAccountType: boolean | undefined;
|
|
94
|
+
regardedOwnerUsLlcClassification: boolean | undefined;
|
|
95
|
+
regardedOwnerUsOtherClassification: boolean | undefined;
|
|
96
|
+
regardedOwnerUsTrustEstateEin: boolean | undefined;
|
|
97
|
+
regardedOwnerForeignAccountType: boolean | undefined;
|
|
98
|
+
regardedOwnerForeignTrustClassification: boolean | undefined;
|
|
99
|
+
regardedOwnerForeignOtherClassification: boolean | undefined;
|
|
100
|
+
regardedOwnerForeignTin: boolean | undefined;
|
|
101
|
+
regardedOwnerForeignTinIsNotRequired: boolean | undefined;
|
|
102
|
+
regardedOwnerUsTin: boolean | undefined;
|
|
103
|
+
};
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { TaxDocumentation, TaxDocumentationKey } from "../types";
|
|
2
|
+
import { ErrorKey } from "../i18n/types";
|
|
3
|
+
export declare const getValidationMessages: (fields: TaxDocumentation) => {
|
|
4
|
+
exemptPayeeCode: ErrorKey | undefined;
|
|
5
|
+
exemptFatcaCode: ErrorKey | undefined;
|
|
6
|
+
iAcknowlegeESignIsOk: ErrorKey | undefined;
|
|
7
|
+
iAmACitizenOfTheUs: ErrorKey | undefined;
|
|
8
|
+
iAmExemptFromFatcaReporting: ErrorKey | undefined;
|
|
9
|
+
iAmNotSubjectToBackupWithholding: ErrorKey | undefined;
|
|
10
|
+
iAuthorizeWithholdingAgent: ErrorKey | undefined;
|
|
11
|
+
iCertifyToAll: ErrorKey | undefined;
|
|
12
|
+
iConfirmIncomeIsNonUs: ErrorKey | undefined;
|
|
13
|
+
iConfirmTheBeneficialOwnerIsExempt: ErrorKey | undefined;
|
|
14
|
+
iConfirmTheEntityIsNotAUsPerson: ErrorKey | undefined;
|
|
15
|
+
iConfirmTheEntityIsTheBeneficialOwner: ErrorKey | undefined;
|
|
16
|
+
iConfirmTheTaxIdIsCorrect: ErrorKey | undefined;
|
|
17
|
+
iHaveLegalCapacityToSign: ErrorKey | undefined;
|
|
18
|
+
regardedOwnerUsPerson: ErrorKey | undefined;
|
|
19
|
+
signature: ErrorKey | undefined;
|
|
20
|
+
accountHolderAddressCity: ErrorKey | undefined;
|
|
21
|
+
accountHolderAddressCountry: ErrorKey | undefined;
|
|
22
|
+
accountHolderAddressState: ErrorKey | undefined;
|
|
23
|
+
accountHolderAddressStreet2: ErrorKey | undefined;
|
|
24
|
+
accountHolderAddressStreet: ErrorKey | undefined;
|
|
25
|
+
accountHolderAddressZip: ErrorKey | undefined;
|
|
26
|
+
accountHolderCityOfBirth: ErrorKey | undefined;
|
|
27
|
+
accountHolderCountryOfBirth: ErrorKey | undefined;
|
|
28
|
+
accountHolderCountryOfCitizenship: ErrorKey | undefined;
|
|
29
|
+
accountHolderDateOfBirth: ErrorKey | undefined;
|
|
30
|
+
accountHolderDbaName: ErrorKey | undefined;
|
|
31
|
+
accountHolderMailingAddressCity: ErrorKey | undefined;
|
|
32
|
+
accountHolderMailingAddressCountry: ErrorKey | undefined;
|
|
33
|
+
accountHolderMailingAddressIsDifferent: ErrorKey | undefined;
|
|
34
|
+
accountHolderMailingAddressState: ErrorKey | undefined;
|
|
35
|
+
accountHolderMailingAddressStreet2: ErrorKey | undefined;
|
|
36
|
+
accountHolderMailingAddressStreet: ErrorKey | undefined;
|
|
37
|
+
accountHolderMailingAddressZip: ErrorKey | undefined;
|
|
38
|
+
accountHolderName: ErrorKey | undefined;
|
|
39
|
+
accountHolderFinancialAccountIdentifier: ErrorKey | undefined;
|
|
40
|
+
accountHolderFinancialAccountName: ErrorKey | undefined;
|
|
41
|
+
accountHolderForeignTin: ErrorKey | undefined;
|
|
42
|
+
accountHolderForeignTinIsNotRequired: ErrorKey | undefined;
|
|
43
|
+
accountHolderTaxResidenceCountry1: ErrorKey | undefined;
|
|
44
|
+
accountHolderTaxResidenceForeignTin1: ErrorKey | undefined;
|
|
45
|
+
accountHolderTaxResidenceForeignTin1IsNotRequired: ErrorKey | undefined;
|
|
46
|
+
accountHolderTaxResidenceCountry2: ErrorKey | undefined;
|
|
47
|
+
accountHolderTaxResidenceForeignTin2: ErrorKey | undefined;
|
|
48
|
+
accountHolderTaxResidenceForeignTin2IsNotRequired: ErrorKey | undefined;
|
|
49
|
+
accountHolderTaxResidenceCountry3: ErrorKey | undefined;
|
|
50
|
+
accountHolderTaxResidenceForeignTin3: ErrorKey | undefined;
|
|
51
|
+
accountHolderTaxResidenceForeignTin3IsNotRequired: ErrorKey | undefined;
|
|
52
|
+
accountHolderTaxResidenceCountry4: ErrorKey | undefined;
|
|
53
|
+
accountHolderTaxResidenceForeignTin4: ErrorKey | undefined;
|
|
54
|
+
accountHolderTaxResidenceForeignTin4IsNotRequired: ErrorKey | undefined;
|
|
55
|
+
accountHolderTaxResidenceCountry5: ErrorKey | undefined;
|
|
56
|
+
accountHolderTaxResidenceForeignTin5: ErrorKey | undefined;
|
|
57
|
+
accountHolderTaxResidenceForeignTin5IsNotRequired: ErrorKey | undefined;
|
|
58
|
+
accountHolderShowTaxResidence2: ErrorKey | undefined;
|
|
59
|
+
accountHolderShowTaxResidence3: ErrorKey | undefined;
|
|
60
|
+
accountHolderShowTaxResidence4: ErrorKey | undefined;
|
|
61
|
+
accountHolderShowTaxResidence5: ErrorKey | undefined;
|
|
62
|
+
accountHolderUsTin: ErrorKey | undefined;
|
|
63
|
+
accountHolderVatIdentificationNumber: ErrorKey | undefined;
|
|
64
|
+
accountHolderVatIdentificationNumberIsNotRequired: ErrorKey | undefined;
|
|
65
|
+
accountHolderVatCountry: ErrorKey | undefined;
|
|
66
|
+
accountHolderIsIndividual: ErrorKey | undefined;
|
|
67
|
+
accountHolderIsEuResident: ErrorKey | undefined;
|
|
68
|
+
accountHolderUsPerson: ErrorKey | undefined;
|
|
69
|
+
accountHolderUsAccountType: ErrorKey | undefined;
|
|
70
|
+
accountHolderUsSmllcElection: ErrorKey | undefined;
|
|
71
|
+
accountHolderUsLlcClassification: ErrorKey | undefined;
|
|
72
|
+
accountHolderUsOtherClassification: ErrorKey | undefined;
|
|
73
|
+
accountHolderUsTrustEstateEin: ErrorKey | undefined;
|
|
74
|
+
accountHolderForeignAccountType: ErrorKey | undefined;
|
|
75
|
+
accountHolderForeignTrustClassification: ErrorKey | undefined;
|
|
76
|
+
accountHolderForeignOtherClassification: ErrorKey | undefined;
|
|
77
|
+
regardedOwnerAddressCity: ErrorKey | undefined;
|
|
78
|
+
regardedOwnerAddressCountry: ErrorKey | undefined;
|
|
79
|
+
regardedOwnerAddressState: ErrorKey | undefined;
|
|
80
|
+
regardedOwnerAddressStreet2: ErrorKey | undefined;
|
|
81
|
+
regardedOwnerAddressStreet: ErrorKey | undefined;
|
|
82
|
+
regardedOwnerAddressZip: ErrorKey | undefined;
|
|
83
|
+
regardedOwnerCountryOfCitizenship: ErrorKey | undefined;
|
|
84
|
+
regardedOwnerDateOfBirth: ErrorKey | undefined;
|
|
85
|
+
regardedOwnerDbaName: ErrorKey | undefined;
|
|
86
|
+
regardedOwnerMailingAddressCity: ErrorKey | undefined;
|
|
87
|
+
regardedOwnerMailingAddressCountry: ErrorKey | undefined;
|
|
88
|
+
regardedOwnerMailingAddressIsDifferent: ErrorKey | undefined;
|
|
89
|
+
regardedOwnerMailingAddressState: ErrorKey | undefined;
|
|
90
|
+
regardedOwnerMailingAddressStreet2: ErrorKey | undefined;
|
|
91
|
+
regardedOwnerMailingAddressStreet: ErrorKey | undefined;
|
|
92
|
+
regardedOwnerMailingAddressZip: ErrorKey | undefined;
|
|
93
|
+
regardedOwnerName: ErrorKey | undefined;
|
|
94
|
+
regardedOwnerUsAccountType: ErrorKey | undefined;
|
|
95
|
+
regardedOwnerUsLlcClassification: ErrorKey | undefined;
|
|
96
|
+
regardedOwnerUsOtherClassification: ErrorKey | undefined;
|
|
97
|
+
regardedOwnerUsTrustEstateEin: ErrorKey | undefined;
|
|
98
|
+
regardedOwnerForeignAccountType: ErrorKey | undefined;
|
|
99
|
+
regardedOwnerForeignTrustClassification: ErrorKey | undefined;
|
|
100
|
+
regardedOwnerForeignOtherClassification: ErrorKey | undefined;
|
|
101
|
+
regardedOwnerForeignTin: ErrorKey | undefined;
|
|
102
|
+
regardedOwnerForeignTinIsNotRequired: ErrorKey | undefined;
|
|
103
|
+
regardedOwnerUsTin: ErrorKey | undefined;
|
|
104
|
+
};
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -11,4 +11,5 @@ export * from "./getUsAccountType";
|
|
|
11
11
|
export * from "./getVisibleQuestions";
|
|
12
12
|
export * from "./isBlank";
|
|
13
13
|
export * from "./transformInbound";
|
|
14
|
-
export * from "./transformOutbound";
|
|
14
|
+
export * from "./transformOutbound/transformOutbound.ts";
|
|
15
|
+
export * from "./getMonthlyDayCount.ts";
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { TaxDocumentation } from "types";
|
|
2
|
+
import { Address } from "types/external";
|
|
3
|
+
export declare const transformToOutboundAccountHolderAddress: (data: TaxDocumentation) => Address | undefined;
|
|
4
|
+
export declare const transformToOutboundRegardedOwnerAddress: (data: TaxDocumentation) => Address | undefined;
|
|
5
|
+
export declare const transformToOutboundAccountHolderMailingAddress: (data: TaxDocumentation) => Address | undefined;
|
|
6
|
+
export declare const transformToOutboundRegardedOwnerMailingAddress: (data: TaxDocumentation) => Address | undefined;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { TaxDocumentation } from "types";
|
|
2
|
+
import { AccountHolderTaxDocumentation } from "types/external";
|
|
3
|
+
export declare const transformToOutboundAccountHolderTaxResidences: (data: TaxDocumentation) => AccountHolderTaxDocumentation["tax_residences"] | undefined;
|
|
4
|
+
export declare const transformToOutboundAccountHolderShowTaxResidence: (data: TaxDocumentation) => AccountHolderTaxDocumentation["show_tax_residence"] | undefined;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { TaxDocumentation, TaxDocumentationKey } from "types/TaxDocumentation";
|
|
2
|
+
import { TaxForm } from "../types";
|
|
3
|
+
export type FormUIRequired = ((fields: TaxDocumentation, taxForms?: TaxForm[]) => boolean | undefined) | (() => boolean | undefined);
|
|
4
|
+
export type FormUIRequiredFields = {
|
|
5
|
+
[key in TaxDocumentationKey]?: FormUIRequired;
|
|
6
|
+
};
|
|
7
|
+
export declare const requiredFields: FormUIRequiredFields;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import
|
|
3
|
-
import { TaxForm } from "../../types";
|
|
2
|
+
import { Locale, TaxForm } from "../../types";
|
|
4
3
|
import { ClientTaxDocumentation } from "../../types/external";
|
|
5
4
|
type TaxBitFormProps = {
|
|
6
5
|
data?: ClientTaxDocumentation;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./LanguageSelector";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { CheckBoxProps } from "ui";
|
|
3
3
|
type CheckBoxRowProps = {
|
|
4
|
-
label?:
|
|
5
|
-
subLabel?:
|
|
4
|
+
label?: boolean;
|
|
5
|
+
subLabel?: boolean;
|
|
6
6
|
};
|
|
7
7
|
export declare const CheckBoxRow: ({ name, label, subLabel, onClick, }: CheckBoxProps & CheckBoxRowProps) => React.JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { MaskedInputProps } from "ui";
|
|
3
|
+
type MaskedInputRowProps = {
|
|
4
|
+
label?: true;
|
|
5
|
+
subLabel?: true;
|
|
6
|
+
hint?: true;
|
|
7
|
+
onChange?: (val: string) => string;
|
|
8
|
+
};
|
|
9
|
+
export declare const MaskedInputRow: ({ name, label, hint, subLabel, onChange, }: MaskedInputProps & MaskedInputRowProps) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./MaskedInputRow";
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { TextInputProps } from "ui";
|
|
3
|
+
import { TaxDocumentationKey } from "types";
|
|
3
4
|
type TextInputRowProps = {
|
|
4
5
|
label?: true;
|
|
5
6
|
subLabel?: true;
|
|
6
7
|
hint?: true;
|
|
7
8
|
onChange?: (val: string) => string;
|
|
9
|
+
syncName?: TaxDocumentationKey;
|
|
8
10
|
};
|
|
9
|
-
export declare const TextInputRow: ({ name, label, hint, subLabel, onChange, disabled, }: TextInputProps & TextInputRowProps) => React.JSX.Element;
|
|
11
|
+
export declare const TextInputRow: ({ name, label, hint, subLabel, onChange, disabled, syncName, }: TextInputProps & TextInputRowProps) => React.JSX.Element;
|
|
10
12
|
export {};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { Locale } from "../../
|
|
3
|
-
import type { TaxDocumentation } from "../../types";
|
|
2
|
+
import type { Locale, TaxDocumentation } from "../../types";
|
|
4
3
|
import { ClientTaxDocumentation } from "../../types/external";
|
|
5
4
|
type TaxDocumentationDAC7PathProps = {
|
|
6
5
|
data?: ClientTaxDocumentation;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { Locale } from "../../
|
|
3
|
-
import type { TaxForm, TaxDocumentation } from "../../types";
|
|
2
|
+
import type { Locale, TaxForm, TaxDocumentation } from "../../types";
|
|
4
3
|
import { ClientTaxDocumentation } from "../../types/external";
|
|
5
4
|
type TaxBitFormUIProps = {
|
|
6
5
|
data?: ClientTaxDocumentation;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@taxbit/react-sdk",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "TaxBit Tax Documentation",
|
|
5
5
|
"author": "TaxBit",
|
|
6
6
|
"type": "module",
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@types/node": "^18.17.0",
|
|
41
41
|
"@types/react": "^18.2.15",
|
|
42
|
+
"@types/react-better-password": "^1.0.3",
|
|
42
43
|
"@types/react-dom": "^18.2.7",
|
|
43
44
|
"@typescript-eslint/eslint-plugin": "^6.0.0",
|
|
44
45
|
"@typescript-eslint/parser": "^6.0.0",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './Title.tsx';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type Locale = "en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es" | "pt-pt";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./FinancialAccountInput";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./ErrorRow";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./VatInput";
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|