@taxbit/react-sdk 0.0.10 → 0.0.11

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.
@@ -1,13 +1,13 @@
1
1
  import React from "react";
2
2
  import type { Locale } from "i18n";
3
- import type { Form } from "types/Form";
3
+ import type { TaxForm } from "types/TaxForm";
4
4
  import type { TaxDocumentation } from "types";
5
5
  type TaxDocumentationProviderProps = {
6
6
  data?: TaxDocumentation;
7
7
  onSubmit: (data: TaxDocumentation) => void;
8
8
  language?: Locale;
9
9
  children: React.ReactNode;
10
- forms?: Form[];
10
+ taxForms?: TaxForm[];
11
11
  };
12
- export declare const TaxBitFormProvider: ({ data, onSubmit, language, forms, children, }: TaxDocumentationProviderProps) => React.JSX.Element;
12
+ export declare const TaxBitFormProvider: ({ data, onSubmit, language, taxForms, children, }: TaxDocumentationProviderProps) => React.JSX.Element;
13
13
  export {};
@@ -1,14 +1,14 @@
1
1
  /// <reference types="react" />
2
- import type { Form, TaxDocumentation } from "types";
2
+ import type { TaxForm, TaxDocumentation } from "types";
3
3
  import { Locale } from "i18n";
4
4
  type InputStep = "AccountHolderClassification" | "AccountHolderContact" | "AccountHolderTax" | "AccountHolderTaxClarification" | "Exemptions" | "RegardedOwnerClassification" | "RegardedOwnerContact" | "RegardedOwnerTax" | "Summary";
5
5
  type UseTaxDocumentationProps = {
6
- initialData: TaxDocumentation;
6
+ data: TaxDocumentation;
7
7
  onSubmit: (transformedData: TaxDocumentation) => void;
8
- initialLanguage?: Locale;
9
- supportedForms?: Form[];
8
+ language?: Locale;
9
+ taxForms?: TaxForm[];
10
10
  };
11
- export declare const useTaxDocumentation: ({ initialData, onSubmit, initialLanguage, supportedForms, }: UseTaxDocumentationProps) => {
11
+ export declare const useTaxDocumentation: ({ data: initialData, onSubmit, language: initialLanguage, taxForms: supportedForms, }: UseTaxDocumentationProps) => {
12
12
  isW9: boolean;
13
13
  isW8: boolean;
14
14
  isW8Ben: boolean;
@@ -27,7 +27,7 @@ export declare const useTaxDocumentation: ({ initialData, onSubmit, initialLangu
27
27
  data: TaxDocumentation;
28
28
  setLanguage: import("react").Dispatch<import("react").SetStateAction<"en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es">>;
29
29
  language: "en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es";
30
- supportedForms: Form[];
31
- setSupportedForms: import("react").Dispatch<import("react").SetStateAction<Form[]>>;
30
+ supportedForms: TaxForm[];
31
+ setSupportedForms: import("react").Dispatch<import("react").SetStateAction<TaxForm[]>>;
32
32
  };
33
33
  export {};
@@ -18,8 +18,8 @@ export declare const useTaxDocumentationContext: () => {
18
18
  data: import("../../types/TaxDocumentation.ts").TaxDocumentation;
19
19
  setLanguage: import("react").Dispatch<import("react").SetStateAction<"en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es">>;
20
20
  language: "en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es";
21
- supportedForms: import("../../types/Form.ts").Form[];
22
- setSupportedForms: import("react").Dispatch<import("react").SetStateAction<import("../../types/Form.ts").Form[]>>;
21
+ supportedForms: import("../../types/TaxForm.ts").TaxForm[];
22
+ setSupportedForms: import("react").Dispatch<import("react").SetStateAction<import("../../types/TaxForm.ts").TaxForm[]>>;
23
23
  }, TaxDocumentationContextProvider: import("react").Provider<{
24
24
  isW9: boolean;
25
25
  isW8: boolean;
@@ -39,6 +39,6 @@ export declare const useTaxDocumentationContext: () => {
39
39
  data: import("../../types/TaxDocumentation.ts").TaxDocumentation;
40
40
  setLanguage: import("react").Dispatch<import("react").SetStateAction<"en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es">>;
41
41
  language: "en-us" | "de-de" | "en-gb" | "it-it" | "nl-nl" | "no-no" | "sv-se" | "fr-fr" | "es-es";
42
- supportedForms: import("../../types/Form.ts").Form[];
43
- setSupportedForms: import("react").Dispatch<import("react").SetStateAction<import("../../types/Form.ts").Form[]>>;
42
+ supportedForms: import("../../types/TaxForm.ts").TaxForm[];
43
+ setSupportedForms: import("react").Dispatch<import("react").SetStateAction<import("../../types/TaxForm.ts").TaxForm[]>>;
44
44
  } | undefined>;
@@ -1,5 +1,5 @@
1
1
  import { TaxDocumentation } from "types";
2
- export declare const useTaxBit: (environment: "PRODUCTION" | "STAGING", bearerToken: string) => {
3
- submitTaxDocumentation: (taxDocumentation: TaxDocumentation) => void;
4
- taxDocumentationStatus: string | undefined;
2
+ export declare const useTaxBit: (bearerToken: string, staging?: true) => {
3
+ submitForm: (taxDocumentation: TaxDocumentation) => void;
4
+ formStatus: string | undefined;
5
5
  };
@@ -2,9 +2,9 @@ import React from "react";
2
2
  import type { Locale } from "i18n";
3
3
  import type { TaxDocumentation } from "types";
4
4
  type TaxDocumentationDAC7PathProps = {
5
- initialData?: TaxDocumentation;
5
+ data?: TaxDocumentation;
6
6
  onSubmit: (data: TaxDocumentation) => void;
7
- initialLanguage?: Locale;
7
+ language?: Locale;
8
8
  };
9
- export declare const TaxBitDAC7FormUI: ({ initialData, onSubmit, initialLanguage, }: TaxDocumentationDAC7PathProps) => React.JSX.Element;
9
+ export declare const TaxBitDAC7FormUI: ({ data, onSubmit, language, }: TaxDocumentationDAC7PathProps) => React.JSX.Element;
10
10
  export {};
@@ -1,12 +1,12 @@
1
1
  import React from "react";
2
2
  import type { Locale } from "i18n";
3
- import type { Form } from "types/Form";
3
+ import type { TaxForm } from "types/TaxForm";
4
4
  import type { TaxDocumentation } from "types";
5
5
  type TaxBitFormUIProps = {
6
- initialData?: TaxDocumentation;
6
+ data?: TaxDocumentation;
7
7
  onSubmit: (data: TaxDocumentation) => void;
8
- initialLanguage?: Locale;
9
- forms?: Form[];
8
+ language?: Locale;
9
+ taxForms?: TaxForm[];
10
10
  };
11
- export declare const TaxBitFormUI: ({ initialData, onSubmit, initialLanguage, forms, }: TaxBitFormUIProps) => React.JSX.Element;
11
+ export declare const TaxBitFormUI: ({ data, onSubmit, language, taxForms, }: TaxBitFormUIProps) => React.JSX.Element;
12
12
  export {};