@propellerads/kyc-form 4.1.8 → 5.0.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.
- package/README.md +10 -10
- package/dist/index.d.ts +110 -11
- package/dist/index.js +379 -6
- package/dist/index.js.map +1 -0
- package/package.json +25 -20
- package/dist/KYCDocumentParts/index.d.ts +0 -8
- package/dist/KYCDocumentParts/style.d.ts +0 -10
- package/dist/KYCDocumentParts/types.d.ts +0 -34
- package/dist/KYCErrorLabel/index.d.ts +0 -4
- package/dist/KYCErrorLabel/style.d.ts +0 -4
- package/dist/KYCErrorLabel/types.d.ts +0 -7
- package/dist/KYCFormItem/index.d.ts +0 -4
- package/dist/KYCFormItem/style.d.ts +0 -4
- package/dist/KYCFormItem/types.d.ts +0 -13
- package/dist/KYCStatusScreen/index.d.ts +0 -10
- package/dist/KYCStatusScreen/style.d.ts +0 -6
- package/dist/KYCStatusScreen/types.d.ts +0 -21
- package/dist/allowJavaScriptModules.d.ts +0 -1
- package/dist/constants.d.ts +0 -16
- package/dist/document.types.d.ts +0 -39
- package/dist/kyc-form.cjs.development.js +0 -643
- package/dist/kyc-form.cjs.development.js.map +0 -1
- package/dist/kyc-form.cjs.production.min.js +0 -2
- package/dist/kyc-form.cjs.production.min.js.map +0 -1
- package/dist/kyc-form.esm.js +0 -631
- package/dist/kyc-form.esm.js.map +0 -1
- package/dist/labels.types.d.ts +0 -35
- package/dist/style.d.ts +0 -5
- package/dist/types.d.ts +0 -17
- package/dist/utils.d.ts +0 -9
package/package.json
CHANGED
|
@@ -1,41 +1,46 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@propellerads/kyc-form",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"
|
|
3
|
+
"version": "5.0.1",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"types": "dist/index.d.ts",
|
|
6
|
+
"exports": {
|
|
7
|
+
".": {
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"import": "./dist/index.js"
|
|
10
|
+
}
|
|
11
|
+
},
|
|
7
12
|
"files": [
|
|
8
13
|
"dist"
|
|
9
14
|
],
|
|
10
15
|
"repository": "https://github.com/propellerads/ui-components.git",
|
|
11
16
|
"author": "r.akhtyamov@propellerads.net",
|
|
12
17
|
"license": "MIT",
|
|
13
|
-
"private": false,
|
|
14
18
|
"bugs": {
|
|
15
19
|
"url": "https://github.com/propellerads/ui-components/issues"
|
|
16
20
|
},
|
|
17
|
-
"homepage": "https://github.com/propellerads/ui-components#readme",
|
|
18
21
|
"scripts": {
|
|
19
|
-
"
|
|
20
|
-
"build": "tsdx build"
|
|
21
|
-
},
|
|
22
|
-
"peerDependencies": {
|
|
23
|
-
"react": ">=18 <19",
|
|
24
|
-
"styled-components": "5.1.1"
|
|
22
|
+
"build": "tsc && vite build && bunx rollup -c rollup.dts.config.mjs"
|
|
25
23
|
},
|
|
24
|
+
"homepage": "https://github.com/propellerads/ui-components#readme",
|
|
25
|
+
"private": false,
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@propellerads/button": "^9.0.3",
|
|
28
|
-
"@propellerads/icon": "^
|
|
28
|
+
"@propellerads/icon": "^8.0.0",
|
|
29
29
|
"@propellerads/image-uploader": "^4.0.0",
|
|
30
30
|
"@propellerads/stylevariables": "^2.0.2",
|
|
31
|
-
"@propellerads/success-label": "4.0.
|
|
32
|
-
"@propellerads/textarea": "^5.0.
|
|
31
|
+
"@propellerads/success-label": "^4.0.1",
|
|
32
|
+
"@propellerads/textarea": "^5.0.3"
|
|
33
|
+
},
|
|
34
|
+
"peerDependencies": {
|
|
35
|
+
"react": "^18.0.0 || ^19.0.0",
|
|
36
|
+
"styled-components": "^5.1.1 || ^6.0.0"
|
|
33
37
|
},
|
|
34
38
|
"devDependencies": {
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
39
|
+
"@types/react": "^19.2.14",
|
|
40
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
41
|
+
"rollup": "^4.60.3",
|
|
42
|
+
"rollup-plugin-dts": "^6.4.1",
|
|
43
|
+
"typescript": "^6.0.3",
|
|
44
|
+
"vite": "^8.0.10"
|
|
40
45
|
}
|
|
41
46
|
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { KYCFormItemFileExtraPartProps, KYCFormItemFileProps, KYCFormItemTextProps } from './types';
|
|
3
|
-
declare const _default: {
|
|
4
|
-
KYCFormItemFileExtraPart: (props: KYCFormItemFileExtraPartProps) => React.JSX.Element;
|
|
5
|
-
KYCFormItemFile: (props: KYCFormItemFileProps) => React.JSX.Element;
|
|
6
|
-
KYCFormItemText: (props: KYCFormItemTextProps) => React.JSX.Element;
|
|
7
|
-
};
|
|
8
|
-
export default _default;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
declare const StyledKYCFormItem: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
|
-
declare const StyledKYCFormItemFileTitle: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
3
|
-
declare const StyledKYCFormItemFilePreview: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
4
|
-
declare const StyledKYCFormItemFilePreviewName: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
5
|
-
declare const StyledKYCFormItemFilePreviewRemove: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
6
|
-
declare const StyledKYCFormItemFileUploaderContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
7
|
-
declare const StyledKYCFormItemFileExtraPart: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
8
|
-
declare const StyledKYCDocumentPartImgMiniature: import("styled-components").StyledComponent<"img", any, {}, never>;
|
|
9
|
-
declare const StyledKYCDocumentPartIconMiniature: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
10
|
-
export { StyledKYCFormItem, StyledKYCFormItemFilePreview, StyledKYCFormItemFilePreviewName, StyledKYCFormItemFilePreviewRemove, StyledKYCFormItemFileTitle, StyledKYCFormItemFileUploaderContainer, StyledKYCFormItemFileExtraPart, StyledKYCDocumentPartImgMiniature, StyledKYCDocumentPartIconMiniature, };
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { KYCFile, KYCFileData } from '../document.types';
|
|
3
|
-
import { UploaderLabels } from '../labels.types';
|
|
4
|
-
export interface KYCDocumentPartMiniatureProps {
|
|
5
|
-
data?: KYCFileData;
|
|
6
|
-
}
|
|
7
|
-
export interface KYCFormItemFileExtraPartProps {
|
|
8
|
-
elementId: string;
|
|
9
|
-
title?: string;
|
|
10
|
-
uploaderLabels: UploaderLabels;
|
|
11
|
-
onFileAdd: (file: File) => void;
|
|
12
|
-
}
|
|
13
|
-
export interface KYCFormItemFileProps extends KYCFile {
|
|
14
|
-
title?: string;
|
|
15
|
-
name?: string;
|
|
16
|
-
elementId: string;
|
|
17
|
-
uploaderLabels: UploaderLabels;
|
|
18
|
-
error?: string;
|
|
19
|
-
onFileChange: (file: File) => void;
|
|
20
|
-
onFileRemove: () => void;
|
|
21
|
-
}
|
|
22
|
-
export interface KYCFormItemTextProps {
|
|
23
|
-
value: string | undefined;
|
|
24
|
-
onFeedbackChange: (data: string) => void;
|
|
25
|
-
}
|
|
26
|
-
declare class KYCFormItemFileExtraPart extends React.Component<KYCFormItemFileExtraPartProps> {
|
|
27
|
-
}
|
|
28
|
-
declare class KYCFormItemFile extends React.Component<KYCFormItemFileProps> {
|
|
29
|
-
}
|
|
30
|
-
declare const _default: {
|
|
31
|
-
KYCFormItemFileExtraPart: typeof KYCFormItemFileExtraPart;
|
|
32
|
-
KYCFormItemFile: typeof KYCFormItemFile;
|
|
33
|
-
};
|
|
34
|
-
export default _default;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
declare const StyledKYCErrorLabel: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
|
-
declare const StyledKYCErrorLabelIcon: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
3
|
-
declare const StyledKYCErrorLabelText: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
4
|
-
export { StyledKYCErrorLabel, StyledKYCErrorLabelIcon, StyledKYCErrorLabelText };
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
declare const StyledKYCFormItem: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
|
-
declare const StyledKYCFormItemTitle: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
3
|
-
declare const StyledKYCFormItemDescription: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
4
|
-
export { StyledKYCFormItem, StyledKYCFormItemTitle, StyledKYCFormItemDescription };
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { KYCDocument } from '../document.types';
|
|
3
|
-
import { UploaderLabels, DocumentLabels } from '../labels.types';
|
|
4
|
-
export interface KYCFormItemProps extends KYCDocument {
|
|
5
|
-
uploaderLabels: UploaderLabels;
|
|
6
|
-
documentLabels?: DocumentLabels;
|
|
7
|
-
elementId: string;
|
|
8
|
-
index: number;
|
|
9
|
-
errors?: Record<string, string>;
|
|
10
|
-
onDocumentChange: (document: KYCDocument) => void;
|
|
11
|
-
}
|
|
12
|
-
export default class KYCFormItem extends React.Component<KYCFormItemProps> {
|
|
13
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { ACCEPT_FORMATS, AVAILABLE_EXTRA_PARTS_DOCUMENTS, MAX_EXTRA_PARTS_COUNT, MAX_FILE_SIZE, PDF_MIME_TYPE } from '../constants';
|
|
3
|
-
import { DOCUMENT_TYPES, PART_TYPES } from '../document.types';
|
|
4
|
-
import { KYCFailScreenProps, KYCSucessScreenProps } from './types';
|
|
5
|
-
declare const _default: {
|
|
6
|
-
KYCSucessScreen: (props: KYCSucessScreenProps) => React.JSX.Element;
|
|
7
|
-
KYCFailScreen: (props: KYCFailScreenProps) => React.JSX.Element;
|
|
8
|
-
};
|
|
9
|
-
export default _default;
|
|
10
|
-
export { ACCEPT_FORMATS, AVAILABLE_EXTRA_PARTS_DOCUMENTS, DOCUMENT_TYPES, MAX_EXTRA_PARTS_COUNT, MAX_FILE_SIZE, PART_TYPES, PDF_MIME_TYPE, };
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
declare const StyledKYCSucessScreen: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
|
-
declare const StyledKYCSucessScreenItem: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
3
|
-
declare const StyledKYCSucessScreenSuppport: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
4
|
-
declare const StyledKYCFailScreen: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
5
|
-
declare const StyledKYCFailScreenItem: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
6
|
-
export { StyledKYCSucessScreen, StyledKYCSucessScreenItem, StyledKYCSucessScreenSuppport, StyledKYCFailScreen, StyledKYCFailScreenItem, };
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
export interface KYCSucessScreenProps {
|
|
3
|
-
elementId: string;
|
|
4
|
-
title: string;
|
|
5
|
-
description?: ReactNode;
|
|
6
|
-
support?: ReactNode;
|
|
7
|
-
}
|
|
8
|
-
export interface KYCFailScreenProps {
|
|
9
|
-
elementId: string;
|
|
10
|
-
title: string;
|
|
11
|
-
support?: ReactNode;
|
|
12
|
-
}
|
|
13
|
-
declare class KYCSucessScreen extends React.Component<KYCSucessScreenProps> {
|
|
14
|
-
}
|
|
15
|
-
declare class KYCFailScreen extends React.Component<KYCFailScreenProps> {
|
|
16
|
-
}
|
|
17
|
-
declare const _default: {
|
|
18
|
-
KYCSucessScreen: typeof KYCSucessScreen;
|
|
19
|
-
KYCFailScreen: typeof KYCFailScreen;
|
|
20
|
-
};
|
|
21
|
-
export default _default;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
declare module '*';
|
package/dist/constants.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { ImageUploaderProps } from '@propellerads/image-uploader';
|
|
2
|
-
import { DOCUMENT_TYPES, PART_TYPES } from './document.types';
|
|
3
|
-
export declare const MAX_FILE_SIZE = 5242880;
|
|
4
|
-
export declare const MAX_EXTRA_PARTS_COUNT = 3;
|
|
5
|
-
export declare const PDF_MIME_TYPE = "application/pdf";
|
|
6
|
-
export declare const HEIC_MIME_TYPE = "image/heic";
|
|
7
|
-
export declare const ACCEPT_FORMATS: ImageUploaderProps['acceptFormats'];
|
|
8
|
-
export declare const AVAILABLE_EXTRA_PARTS_DOCUMENTS: DOCUMENT_TYPES[];
|
|
9
|
-
export declare const OPTIONAL_DOCUMENT_PARTS: {
|
|
10
|
-
id: {
|
|
11
|
-
parts: PART_TYPES[];
|
|
12
|
-
};
|
|
13
|
-
id_extra: {
|
|
14
|
-
parts: PART_TYPES[];
|
|
15
|
-
};
|
|
16
|
-
};
|
package/dist/document.types.d.ts
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
export declare enum DOCUMENT_TYPES {
|
|
2
|
-
ID = "id",
|
|
3
|
-
UB = "ub",
|
|
4
|
-
ID_EXTRA = "id_extra",
|
|
5
|
-
CARD = "bank_card",
|
|
6
|
-
PAYMENT_SYSTEM_SCREEN = "payment_system_screen",
|
|
7
|
-
ONLINE_BANKING_STATEMENT = "online_banking_statement",
|
|
8
|
-
COMPANY_REGISTRATION_DOCUMENT = "company_registration_document",
|
|
9
|
-
SELFIE_WITH_ID_CARD = "selfie_with_id_card_or_bank_card",
|
|
10
|
-
PAYPAL_DETAILS_PAGE = "pay_pal_details_page",
|
|
11
|
-
BANK_WIRE_DETAILS = "bank_wire_details",
|
|
12
|
-
TRANSACTION_CONFIRMATION = "transaction_confirmation",
|
|
13
|
-
OTHER = "other",
|
|
14
|
-
FEEDBACK = "feedback"
|
|
15
|
-
}
|
|
16
|
-
export declare enum PART_TYPES {
|
|
17
|
-
ID_FRONT = "id_front",
|
|
18
|
-
ID_BACK = "id_back",
|
|
19
|
-
UB = "ub_item",
|
|
20
|
-
CARD = "card_item",
|
|
21
|
-
PAYMENT_SYSTEM_SCREEN = "screen_item",
|
|
22
|
-
ONLINE_BANKING_STATEMENT = "obs_item",
|
|
23
|
-
COMPANY_REGISTRATION_DOCUMENT = "crd_item",
|
|
24
|
-
SELFIE_WITH_ID_CARD = "selfie_item",
|
|
25
|
-
PAYPAL_DETAILS_PAGE_IMAGE = "pay_pal_details_page_image",
|
|
26
|
-
BANK_WIRE_DETAILS_PAGE = "bank_wire_details_image",
|
|
27
|
-
TRANSACTION_CONFIRMATION_IMAGE = "transaction_confirmation_image",
|
|
28
|
-
OTHER_IMAGE = "other_image",
|
|
29
|
-
FEEDBACK = "feedback"
|
|
30
|
-
}
|
|
31
|
-
export declare type KYCFileData = string | undefined;
|
|
32
|
-
export declare type KYCFile = {
|
|
33
|
-
type: PART_TYPES;
|
|
34
|
-
data?: KYCFileData;
|
|
35
|
-
};
|
|
36
|
-
export declare type KYCDocument = {
|
|
37
|
-
type: DOCUMENT_TYPES;
|
|
38
|
-
parts: KYCFile[];
|
|
39
|
-
};
|