@bytexbyte/berifyme-react-sdk 1.0.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 +20 -0
- package/dist/BerifymeModal/MainModal.js +29 -0
- package/dist/BerifymeModal/index.js +331 -0
- package/dist/api/api.js +1337 -0
- package/dist/api/client.js +21 -0
- package/dist/api/index.js +96 -0
- package/dist/common.js +216 -0
- package/dist/components/AllSet/index.js +169 -0
- package/dist/components/AuthenticationLogs.js +148 -0
- package/dist/components/Clear.js +107 -0
- package/dist/components/Footer/index.js +11 -0
- package/dist/components/Layout.js +9 -0
- package/dist/components/Login/authid/authid.js +196 -0
- package/dist/components/Login/authid/index.js +13 -0
- package/dist/components/Login/clear.js +35 -0
- package/dist/components/Login/clearAllSet.js +96 -0
- package/dist/components/Login/incode/Login.js +129 -0
- package/dist/components/Login/incode/index.js +16 -0
- package/dist/components/OnBoarding/authId/authIdSelectType.js +82 -0
- package/dist/components/OnBoarding/authId/idOrPassport.js +30 -0
- package/dist/components/OnBoarding/authId/index.js +323 -0
- package/dist/components/OnBoarding/clear/clearAllSet.js +118 -0
- package/dist/components/OnBoarding/clear/index.js +36 -0
- package/dist/components/OnBoarding/incode/BackId.js +25 -0
- package/dist/components/OnBoarding/incode/FinishOnboarding.js +26 -0
- package/dist/components/OnBoarding/incode/FrontId.js +27 -0
- package/dist/components/OnBoarding/incode/Passport.js +27 -0
- package/dist/components/OnBoarding/incode/ProcessFace.js +22 -0
- package/dist/components/OnBoarding/incode/ProcessId.js +22 -0
- package/dist/components/OnBoarding/incode/SelectType.js +68 -0
- package/dist/components/OnBoarding/incode/Selfie.js +25 -0
- package/dist/components/OnBoarding/incode/Steps.js +7 -0
- package/dist/components/OnBoarding/incode/UserConsent.js +30 -0
- package/dist/components/OnBoarding/incode/index.js +234 -0
- package/dist/components/OnBoarding/vender/grid/authIdGrid.js +94 -0
- package/dist/components/OnBoarding/vender/grid/clearGrid.js +14 -0
- package/dist/components/OnBoarding/vender/grid/incodeGrid.js +14 -0
- package/dist/components/OnBoarding/vender/grid/index.js +118 -0
- package/dist/components/OnBoarding/vender/grid/sumsubGrid.js +14 -0
- package/dist/components/OnBoarding/vender/grid/veriffGrid.js +14 -0
- package/dist/components/OnBoarding/vender/grid/yotiGrid.js +14 -0
- package/dist/components/OnBoarding/vender/index.js +123 -0
- package/dist/components/RedirectToMobile/index.js +139 -0
- package/dist/components/ScreenRotation.js +11 -0
- package/dist/components/SendSns/index.js +341 -0
- package/dist/components/SendSns/style.css +1 -0
- package/dist/components/TryAgain.js +16 -0
- package/dist/components/TryAgainInModal.js +15 -0
- package/dist/components/VerifyWithPhoneNumber/NewUser/index.js +189 -0
- package/dist/components/VerifyWithPhoneNumber/User/index.js +322 -0
- package/dist/components/createDeveloperLog.js +60 -0
- package/dist/components/phoneNumberProcesser.js +32 -0
- package/dist/components/speedTest/SpeedProvider.js +57 -0
- package/dist/components/theme.js +120 -0
- package/dist/enum/index.js +24 -0
- package/dist/index.js +7 -0
- package/dist/lib/environmentDomains.js +12 -0
- package/dist/lib/webauthb.js +158 -0
- package/dist/state.js +23 -0
- package/dist/theme.js +120 -0
- package/dist/types/BerifymeModal/MainModal.d.ts +7 -0
- package/dist/types/BerifymeModal/index.d.ts +12 -0
- package/dist/types/api/api.d.ts +606 -0
- package/dist/types/api/client.d.ts +2 -0
- package/dist/types/api/index.d.ts +16 -0
- package/dist/types/common.d.ts +3 -0
- package/dist/types/components/AllSet/index.d.ts +8 -0
- package/dist/types/components/AuthenticationLogs.d.ts +19 -0
- package/dist/types/components/Clear.d.ts +9 -0
- package/dist/types/components/Footer/index.d.ts +3 -0
- package/dist/types/components/Layout.d.ts +5 -0
- package/dist/types/components/Login/authid/authid.d.ts +11 -0
- package/dist/types/components/Login/authid/index.d.ts +9 -0
- package/dist/types/components/Login/clear.d.ts +7 -0
- package/dist/types/components/Login/clearAllSet.d.ts +6 -0
- package/dist/types/components/Login/incode/Login.d.ts +13 -0
- package/dist/types/components/Login/incode/index.d.ts +9 -0
- package/dist/types/components/OnBoarding/authId/authIdSelectType.d.ts +6 -0
- package/dist/types/components/OnBoarding/authId/idOrPassport.d.ts +7 -0
- package/dist/types/components/OnBoarding/authId/index.d.ts +11 -0
- package/dist/types/components/OnBoarding/clear/clearAllSet.d.ts +6 -0
- package/dist/types/components/OnBoarding/clear/index.d.ts +8 -0
- package/dist/types/components/OnBoarding/incode/BackId.d.ts +11 -0
- package/dist/types/components/OnBoarding/incode/FinishOnboarding.d.ts +11 -0
- package/dist/types/components/OnBoarding/incode/FrontId.d.ts +10 -0
- package/dist/types/components/OnBoarding/incode/Passport.d.ts +10 -0
- package/dist/types/components/OnBoarding/incode/ProcessFace.d.ts +11 -0
- package/dist/types/components/OnBoarding/incode/ProcessId.d.ts +11 -0
- package/dist/types/components/OnBoarding/incode/SelectType.d.ts +6 -0
- package/dist/types/components/OnBoarding/incode/Selfie.d.ts +11 -0
- package/dist/types/components/OnBoarding/incode/Steps.d.ts +7 -0
- package/dist/types/components/OnBoarding/incode/UserConsent.d.ts +8 -0
- package/dist/types/components/OnBoarding/incode/index.d.ts +9 -0
- package/dist/types/components/OnBoarding/vender/grid/authIdGrid.d.ts +8 -0
- package/dist/types/components/OnBoarding/vender/grid/clearGrid.d.ts +5 -0
- package/dist/types/components/OnBoarding/vender/grid/incodeGrid.d.ts +5 -0
- package/dist/types/components/OnBoarding/vender/grid/index.d.ts +10 -0
- package/dist/types/components/OnBoarding/vender/grid/sumsubGrid.d.ts +5 -0
- package/dist/types/components/OnBoarding/vender/grid/veriffGrid.d.ts +5 -0
- package/dist/types/components/OnBoarding/vender/grid/yotiGrid.d.ts +5 -0
- package/dist/types/components/OnBoarding/vender/index.d.ts +9 -0
- package/dist/types/components/RedirectToMobile/index.d.ts +7 -0
- package/dist/types/components/ScreenRotation.d.ts +3 -0
- package/dist/types/components/SendSns/index.d.ts +16 -0
- package/dist/types/components/TryAgain.d.ts +6 -0
- package/dist/types/components/TryAgainInModal.d.ts +6 -0
- package/dist/types/components/VerifyWithPhoneNumber/NewUser/index.d.ts +11 -0
- package/dist/types/components/VerifyWithPhoneNumber/User/index.d.ts +13 -0
- package/dist/types/components/createDeveloperLog.d.ts +11 -0
- package/dist/types/components/phoneNumberProcesser.d.ts +6 -0
- package/dist/types/components/speedTest/SpeedProvider.d.ts +9 -0
- package/dist/types/components/theme.d.ts +9 -0
- package/dist/types/enum/index.d.ts +22 -0
- package/dist/types/index.d.ts +12 -0
- package/dist/types/lib/environmentDomains.d.ts +7 -0
- package/dist/types/lib/webauthb.d.ts +18 -0
- package/dist/types/state.d.ts +11 -0
- package/dist/types/theme.d.ts +9 -0
- package/dist/types/vender/incode/incode.d.ts +8 -0
- package/dist/vender/incode/incode.js +13 -0
- package/index.css +52 -0
- package/package.json +49 -0
- package/public/US-UK_Add_to_Apple_Wallet_RGB_101421.svg +259 -0
- package/public/berify-title.webp +0 -0
- package/public/clearme.svg +39 -0
- package/public/idme.svg +13 -0
- package/public/incode.svg +9 -0
- package/public/scan.svg +8 -0
- package/public/trackablehealth-one-logo-1024x229.jpg +0 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
3
|
+
declare function LoginComponent({ onSuccess, onError, user, setUser, token, }: ProccessFacePropTypes): React.JSX.Element;
|
|
4
|
+
type ProccessFacePropTypes = {
|
|
5
|
+
onSuccess: () => void;
|
|
6
|
+
onError: (e: {
|
|
7
|
+
type: string;
|
|
8
|
+
}) => void;
|
|
9
|
+
user?: UserWithAgeAndFullName;
|
|
10
|
+
setUser: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
11
|
+
token: string;
|
|
12
|
+
};
|
|
13
|
+
export { LoginComponent };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
3
|
+
declare const IncodeLogin: React.FC<{
|
|
4
|
+
goToAllSet: () => void;
|
|
5
|
+
user?: UserWithAgeAndFullName;
|
|
6
|
+
setUser: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
7
|
+
token?: string;
|
|
8
|
+
}>;
|
|
9
|
+
export { IncodeLogin };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
declare const AuthIdSelectType: ({ setSelectedIdType, setError, }: {
|
|
3
|
+
setSelectedIdType: React.Dispatch<React.SetStateAction<string>>;
|
|
4
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5
|
+
}) => React.JSX.Element;
|
|
6
|
+
export default AuthIdSelectType;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
declare const IdOrPassport: ({ setError, setPageStatus, setSelectedIdType, }: {
|
|
3
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
4
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
5
|
+
setSelectedIdType: React.Dispatch<React.SetStateAction<string>>;
|
|
6
|
+
}) => React.JSX.Element;
|
|
7
|
+
export default IdOrPassport;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
3
|
+
declare const AuthID: ({ goToAllSet, setError, userId, setUser, selectedIdType, token }: {
|
|
4
|
+
goToAllSet: () => void;
|
|
5
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
6
|
+
userId: string;
|
|
7
|
+
setUser?: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
8
|
+
selectedIdType: string;
|
|
9
|
+
token?: string;
|
|
10
|
+
}) => React.JSX.Element;
|
|
11
|
+
export default AuthID;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare const BackId: ({ session, onSuccess, onError, }: BackIdPropTypes) => React.JSX.Element;
|
|
4
|
+
type BackIdPropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
onError: (e: {
|
|
8
|
+
type: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
};
|
|
11
|
+
export { BackId };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare function FinishOnboarding({ session, onSuccess, onError }: FinishOnboardingPropTypes): React.JSX.Element;
|
|
4
|
+
type FinishOnboardingPropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
onError: (e: {
|
|
8
|
+
type: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
};
|
|
11
|
+
export { FinishOnboarding };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare const FrontId: ({ session, onSuccess, onError }: {
|
|
4
|
+
session: SessionType;
|
|
5
|
+
onSuccess: () => void;
|
|
6
|
+
onError: (e: {
|
|
7
|
+
type: string;
|
|
8
|
+
}) => void;
|
|
9
|
+
}) => React.JSX.Element;
|
|
10
|
+
export { FrontId };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare const Passport: ({ session, onSuccess, onError }: {
|
|
4
|
+
session: SessionType;
|
|
5
|
+
onSuccess: () => void;
|
|
6
|
+
onError: (e: {
|
|
7
|
+
type: string;
|
|
8
|
+
}) => void;
|
|
9
|
+
}) => React.JSX.Element;
|
|
10
|
+
export { Passport };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare function ProcessFace({ session, onSuccess, onError }: ProccessFacePropTypes): React.JSX.Element;
|
|
4
|
+
type ProccessFacePropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
onError: (e: {
|
|
8
|
+
type: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
};
|
|
11
|
+
export { ProcessFace };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare function ProcessId({ session, onSuccess, onError }: ProccessIdPropTypes): React.JSX.Element;
|
|
4
|
+
type ProccessIdPropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
onError: (e: {
|
|
8
|
+
type: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
};
|
|
11
|
+
export { ProcessId };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare function Selfie({ session, onSuccess, onError }: SelfiePropTypes): React.JSX.Element;
|
|
4
|
+
type SelfiePropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
onError: (e: {
|
|
8
|
+
type: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
};
|
|
11
|
+
export { Selfie };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type SessionType } from "../../../vender/incode/incode";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare function UserConsent({ session, onSuccess }: UserConsentPropTypes): React.JSX.Element;
|
|
4
|
+
type UserConsentPropTypes = {
|
|
5
|
+
session: SessionType;
|
|
6
|
+
onSuccess: () => void;
|
|
7
|
+
};
|
|
8
|
+
export { UserConsent };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
3
|
+
declare const IncodeOnBoarding: React.FC<{
|
|
4
|
+
user: UserWithAgeAndFullName;
|
|
5
|
+
setUser: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
6
|
+
goToAllSet: () => void;
|
|
7
|
+
token?: string;
|
|
8
|
+
}>;
|
|
9
|
+
export { IncodeOnBoarding };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../../api/api";
|
|
3
|
+
declare const AuthIdGrid: ({ setPageStatus, setError, user, }: {
|
|
4
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
6
|
+
user?: UserWithAgeAndFullName;
|
|
7
|
+
}) => React.JSX.Element;
|
|
8
|
+
export default AuthIdGrid;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../../api/api";
|
|
3
|
+
declare const VenderGrid: ({ setPageStatus, setError, user, showMore, setShowMore }: {
|
|
4
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
6
|
+
user?: UserWithAgeAndFullName;
|
|
7
|
+
showMore: boolean;
|
|
8
|
+
setShowMore: React.Dispatch<React.SetStateAction<boolean>>;
|
|
9
|
+
}) => React.JSX.Element;
|
|
10
|
+
export default VenderGrid;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
2
|
+
import React from "react";
|
|
3
|
+
declare const Vender: ({ setPageStatus, setError, user, setModalHeight, }: {
|
|
4
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
5
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
6
|
+
user?: UserWithAgeAndFullName;
|
|
7
|
+
setModalHeight: React.Dispatch<React.SetStateAction<string>>;
|
|
8
|
+
}) => React.JSX.Element;
|
|
9
|
+
export default Vender;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Environment } from '../../enum';
|
|
3
|
+
import './style.css';
|
|
4
|
+
import { User } from '../../api/api';
|
|
5
|
+
declare const SendSns: ({ token, inputValue, setInputValue, setError, setPageStatus, setProcessedPhoneNumber, setModalHeight, setUser, environment, }: {
|
|
6
|
+
token: string | undefined;
|
|
7
|
+
inputValue: string;
|
|
8
|
+
setInputValue: React.Dispatch<React.SetStateAction<string>>;
|
|
9
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
10
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
11
|
+
setProcessedPhoneNumber: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
12
|
+
setModalHeight: React.Dispatch<React.SetStateAction<string>>;
|
|
13
|
+
setUser: React.Dispatch<React.SetStateAction<User | undefined>>;
|
|
14
|
+
environment: Environment;
|
|
15
|
+
}) => React.JSX.Element;
|
|
16
|
+
export default SendSns;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
3
|
+
import { Environment } from "../../../enum";
|
|
4
|
+
declare const VerifyNewUser: ({ token, inputValue, setPageStatus, setUser, environment, }: {
|
|
5
|
+
token: string | undefined;
|
|
6
|
+
inputValue: string;
|
|
7
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
8
|
+
setUser: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
9
|
+
environment: Environment;
|
|
10
|
+
}) => React.JSX.Element;
|
|
11
|
+
export default VerifyNewUser;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Environment } from "../../../enum";
|
|
3
|
+
import { UserWithAgeAndFullName } from "../../../api/api";
|
|
4
|
+
declare const VerifyUser: ({ token, inputValue, setError, setPageStatus, setUser, setModalHeight, environment, }: {
|
|
5
|
+
token: string | undefined;
|
|
6
|
+
inputValue: string;
|
|
7
|
+
setError: React.Dispatch<React.SetStateAction<string | undefined>>;
|
|
8
|
+
setPageStatus: React.Dispatch<React.SetStateAction<number>>;
|
|
9
|
+
setUser: React.Dispatch<React.SetStateAction<UserWithAgeAndFullName | undefined>>;
|
|
10
|
+
setModalHeight: React.Dispatch<React.SetStateAction<string>>;
|
|
11
|
+
environment: Environment;
|
|
12
|
+
}) => React.JSX.Element;
|
|
13
|
+
export default VerifyUser;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { User } from "../api/api";
|
|
2
|
+
export declare const createDeveloperLog: ({ userId, sessionToken, action, firstDetail, secondDetail, userDataJson, source, browser, }: {
|
|
3
|
+
userId?: string;
|
|
4
|
+
sessionToken?: string;
|
|
5
|
+
action?: string;
|
|
6
|
+
firstDetail?: string;
|
|
7
|
+
secondDetail?: string;
|
|
8
|
+
userDataJson?: User;
|
|
9
|
+
source?: "FRONTEND" | "BACKEND";
|
|
10
|
+
browser?: string;
|
|
11
|
+
}) => Promise<void>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const SpeedProvider: ({ children }: {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
}) => React.JSX.Element;
|
|
5
|
+
export declare const useSpeedTest: () => {
|
|
6
|
+
speed: string | null;
|
|
7
|
+
stopSpeedTest: () => void;
|
|
8
|
+
startSpeedTest: () => void;
|
|
9
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export declare enum Environment {
|
|
2
|
+
Sandbox = "sandbox",
|
|
3
|
+
Staging = "staging",
|
|
4
|
+
Idv = "idv"
|
|
5
|
+
}
|
|
6
|
+
export declare enum PageStatus {
|
|
7
|
+
Loading = -1,
|
|
8
|
+
SendSns = 0,
|
|
9
|
+
VerifyNewUser = 1,
|
|
10
|
+
Vender = 1.1,
|
|
11
|
+
IdOrPassport = 1.2,
|
|
12
|
+
VerifyUser = 1.5,
|
|
13
|
+
AuthIdOnboarding = 2,
|
|
14
|
+
ClearOnboarding = 2.1,
|
|
15
|
+
IncodeOnBoarding = 2.2,
|
|
16
|
+
AuthidLogin = 3,
|
|
17
|
+
ClearLogin = 4,
|
|
18
|
+
IncodeLogin = 5,
|
|
19
|
+
ClearLoginAllSet = 6,
|
|
20
|
+
ClearOnboardingAllSet = 7,
|
|
21
|
+
AllSet = 10
|
|
22
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Environment } from "./enum";
|
|
2
|
+
export declare const berifyme: {
|
|
3
|
+
environment: typeof Environment;
|
|
4
|
+
modal: import("react").FC<{
|
|
5
|
+
apiKeyId: string;
|
|
6
|
+
secretKey: string;
|
|
7
|
+
redirectUrl: string;
|
|
8
|
+
initialPhoneNumber?: string;
|
|
9
|
+
environment: Environment;
|
|
10
|
+
forceQrcode?: boolean;
|
|
11
|
+
}>;
|
|
12
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
declare const webauthn: {
|
|
2
|
+
login: ({ phoneNumber, backendDomain, frontendDomain, frontendDomainName, }: {
|
|
3
|
+
phoneNumber: string;
|
|
4
|
+
backendDomain?: string;
|
|
5
|
+
frontendDomain?: string;
|
|
6
|
+
frontendDomainName?: string;
|
|
7
|
+
}) => Promise<{
|
|
8
|
+
user: any;
|
|
9
|
+
success: boolean;
|
|
10
|
+
}>;
|
|
11
|
+
register: ({ phoneNumber, backendDomain, frontendDomain, frontendDomainName, }: {
|
|
12
|
+
phoneNumber: string;
|
|
13
|
+
backendDomain?: string;
|
|
14
|
+
frontendDomain?: string;
|
|
15
|
+
frontendDomainName?: string;
|
|
16
|
+
}) => Promise<void>;
|
|
17
|
+
};
|
|
18
|
+
export default webauthn;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
declare class SDKState {
|
|
2
|
+
private static instance;
|
|
3
|
+
private data;
|
|
4
|
+
private constructor();
|
|
5
|
+
static getInstance(): SDKState;
|
|
6
|
+
set(key: string, value: any): void;
|
|
7
|
+
get(key: string): any;
|
|
8
|
+
getAll(): Record<string, any>;
|
|
9
|
+
}
|
|
10
|
+
export declare const sdkState: SDKState;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { create } from "@incodetech/welcome";
|
|
2
|
+
var apiURL = 'https://saas-api.incodesmile.com/0';
|
|
3
|
+
var loginApiURL = 'https://saas-api.incodesmile.com';
|
|
4
|
+
var incode = create({
|
|
5
|
+
apiURL: apiURL,
|
|
6
|
+
lang: 'en-US',
|
|
7
|
+
});
|
|
8
|
+
var incodeLogin = create({
|
|
9
|
+
apiURL: loginApiURL,
|
|
10
|
+
clientId: 'berifyprod883',
|
|
11
|
+
apiKey: 'ca8626ee3fdb329af413088b13d034bc6896b678',
|
|
12
|
+
});
|
|
13
|
+
export { incode, incodeLogin };
|
package/index.css
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
|
|
2
|
+
a {
|
|
3
|
+
color: #000000;
|
|
4
|
+
}
|
|
5
|
+
.img-contain {
|
|
6
|
+
width: 100%;
|
|
7
|
+
height: 100%;
|
|
8
|
+
object-fit: contain;
|
|
9
|
+
}
|
|
10
|
+
body {
|
|
11
|
+
overflow: hidden;
|
|
12
|
+
}
|
|
13
|
+
/* .berifyme {
|
|
14
|
+
background-color: #282c34;
|
|
15
|
+
min-height: 100vh;
|
|
16
|
+
display: flex;
|
|
17
|
+
flex-direction: column;
|
|
18
|
+
align-items: center;
|
|
19
|
+
justify-content: center;
|
|
20
|
+
font-size: calc(10px + 2vmin);
|
|
21
|
+
color: red;
|
|
22
|
+
} */
|
|
23
|
+
|
|
24
|
+
.default {
|
|
25
|
+
box-sizing: border-box; /* 確保邊框和內邊距不會影響元素的尺寸 */
|
|
26
|
+
margin: 0; /* 去除所有元素的外邊距 */
|
|
27
|
+
padding: 0; /* 去除所有元素的內邊距 */
|
|
28
|
+
font-family: Arial, sans-serif; /* 設置預設字體 */
|
|
29
|
+
color: black; /* 設置字體顏色為黑色 */
|
|
30
|
+
background-color: white; /* 設置背景顏色為白色 */
|
|
31
|
+
text-decoration: none; /* 去除所有文本的裝飾(如下劃線) */
|
|
32
|
+
border: none; /* 去除所有元素的邊框 */
|
|
33
|
+
outline: none; /* 去除所有元素的外邊框 */
|
|
34
|
+
line-height: 1.5; /* 設置行高 */
|
|
35
|
+
font-size: 16px; /* 設置字體大小為16px */
|
|
36
|
+
word-wrap: break-word; /* 讓長單詞換行 */
|
|
37
|
+
white-space: normal; /* 確保文本換行 */
|
|
38
|
+
text-align: left; /* 預設文本對齊方式為左對齊 */
|
|
39
|
+
vertical-align: baseline; /* 設置垂直對齊基線 */
|
|
40
|
+
list-style: none; /* 去除列表項目標記 */
|
|
41
|
+
display: inline-block; /* 設置元素為內聯區塊 */
|
|
42
|
+
cursor: default; /* 設置預設鼠標指標 */
|
|
43
|
+
background-attachment: scroll; /* 預設背景附著方式為滾動 */
|
|
44
|
+
box-shadow: none; /* 去除所有元素的陰影 */
|
|
45
|
+
opacity: 1; /* 預設不透明度為 1 */
|
|
46
|
+
transform: none; /* 去除所有元素的轉換效果 */
|
|
47
|
+
visibility: visible; /* 預設元素可見 */
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.berifyme-container * {
|
|
51
|
+
all: unset;
|
|
52
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@bytexbyte/berifyme-react-sdk",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/types/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
9
|
+
"build": "tsc && copyfiles -u 1 'src/**/*.{css,svg}' dist",
|
|
10
|
+
"webpack": "webpack",
|
|
11
|
+
"esbuild": "node esbuild.config.js"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [],
|
|
14
|
+
"author": "",
|
|
15
|
+
"license": "ISC",
|
|
16
|
+
"dependencies": {
|
|
17
|
+
"@authid/react-component": "^1.4.0",
|
|
18
|
+
"@emotion/react": "^11.13.0",
|
|
19
|
+
"@emotion/styled": "^11.13.0",
|
|
20
|
+
"@fontsource/inter": "^5.1.0",
|
|
21
|
+
"@fontsource/roboto": "^5.0.13",
|
|
22
|
+
"@incodetech/welcome": "^1.73.1",
|
|
23
|
+
"@mui/icons-material": "^5.16.5",
|
|
24
|
+
"@mui/material": "^5.16.5",
|
|
25
|
+
"@mui/x-data-grid": "^7.8.0",
|
|
26
|
+
"@simplewebauthn/browser": "^10.0.0",
|
|
27
|
+
"@types/node": "^22.0.0",
|
|
28
|
+
"@types/uuid": "^10.0.0",
|
|
29
|
+
"axios": "^1.7.2",
|
|
30
|
+
"react": "^18.3.1",
|
|
31
|
+
"react-dom": "^18.3.1",
|
|
32
|
+
"react-internet-meter": "^1.1.1",
|
|
33
|
+
"react-phone-input-2": "^2.15.1",
|
|
34
|
+
"react-qr-code": "^2.0.15",
|
|
35
|
+
"react-router-dom": "^6.25.1",
|
|
36
|
+
"styled-components": "^6.1.11",
|
|
37
|
+
"uuid": "^10.0.0"
|
|
38
|
+
},
|
|
39
|
+
"devDependencies": {
|
|
40
|
+
"@types/react": "^18.3.3",
|
|
41
|
+
"@types/react-dom": "^18.3.0",
|
|
42
|
+
"copyfiles": "^2.4.1",
|
|
43
|
+
"css-loader": "^7.1.2",
|
|
44
|
+
"file-loader": "^6.2.0",
|
|
45
|
+
"style-loader": "^4.0.0",
|
|
46
|
+
"ts-loader": "^9.5.1",
|
|
47
|
+
"typescript": "^5.5.4"
|
|
48
|
+
}
|
|
49
|
+
}
|