@nibssplc/cams-sdk-react 0.0.1-beta.99 → 1.0.0-rc.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.
- package/dist/components/ADLoginModal.d.ts +3 -1
- package/dist/components/CAMSMSALProvider.d.ts +1 -0
- package/dist/components/DefaultLoginPage.d.ts +4 -1
- package/dist/components/MFAGate.d.ts +3 -1
- package/dist/components/UnifiedCAMSProvider.d.ts +1 -0
- package/dist/hooks/useCAMSMSALAuth.d.ts +1 -0
- package/dist/hooks/useOTPHandler.d.ts +2 -7
- package/dist/index.cjs.js +222 -121
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.esm.js +222 -121
- package/dist/index.esm.js.map +1 -1
- package/dist/lib/actions/Axiosinstance.d.ts +1 -0
- package/dist/utils/DeviceID.d.ts +4 -1
- package/package.json +1 -1
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
interface ADLoginModalProps {
|
|
2
2
|
open: boolean;
|
|
3
|
+
isLoading: boolean;
|
|
4
|
+
setIsLoading: React.Dispatch<React.SetStateAction<boolean>>;
|
|
3
5
|
onOpenChange: (open: boolean) => void;
|
|
4
6
|
onLogin: (credentials: Credentials) => Promise<void>;
|
|
5
7
|
}
|
|
6
|
-
export declare const ADLoginModal: ({ open, onOpenChange, onLogin, }: ADLoginModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const ADLoginModal: ({ open, isLoading, setIsLoading, onOpenChange, onLogin, }: ADLoginModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
9
|
export {};
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
+
import "../utils/crypto-polyfill";
|
|
1
2
|
import { MFAEndpoints } from "./MFAGate";
|
|
2
3
|
interface LoginPageProps {
|
|
3
4
|
usePassKey?: boolean;
|
|
5
|
+
CredentialsAuthEndpoint?: string;
|
|
6
|
+
useADLogin?: boolean;
|
|
4
7
|
MFAEndpoints: MFAEndpoints;
|
|
5
8
|
PassKeysRegisterProps?: Record<string, unknown>;
|
|
6
9
|
}
|
|
7
|
-
declare const DefaultLoginPage: ({ usePassKey, MFAEndpoints, PassKeysRegisterProps, }: LoginPageProps) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare const DefaultLoginPage: ({ usePassKey, useADLogin, MFAEndpoints, CredentialsAuthEndpoint, PassKeysRegisterProps, }: LoginPageProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
11
|
export default DefaultLoginPage;
|
|
@@ -11,8 +11,10 @@ interface MFAGateProps {
|
|
|
11
11
|
children: React.ReactNode;
|
|
12
12
|
fallback?: React.ReactNode;
|
|
13
13
|
usePassKey?: boolean;
|
|
14
|
+
useADLogin?: boolean;
|
|
15
|
+
CredentialsAuthEndpoint?: string;
|
|
14
16
|
PassKeysRegisterProps?: Record<string, unknown>;
|
|
15
17
|
MFAEndpoints?: MFAEndpoints;
|
|
16
18
|
}
|
|
17
|
-
declare const MFAGate: ({ children, fallback, usePassKey, PassKeysRegisterProps, MFAEndpoints, }: MFAGateProps) => string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null;
|
|
19
|
+
declare const MFAGate: ({ children, fallback, usePassKey, useADLogin, CredentialsAuthEndpoint, PassKeysRegisterProps, MFAEndpoints, }: MFAGateProps) => string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<import("react").ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null;
|
|
18
20
|
export default MFAGate;
|
|
@@ -15,13 +15,8 @@ export declare const useOTPHandler: ({ provider, accessToken, idToken, appCode,
|
|
|
15
15
|
resetAttempts: () => void;
|
|
16
16
|
remainingAttempts: number;
|
|
17
17
|
};
|
|
18
|
-
export declare const useCredentialsHandler: (
|
|
19
|
-
handleSubmitCredentials: (
|
|
20
|
-
username: string;
|
|
21
|
-
password: string;
|
|
22
|
-
MFACode: string;
|
|
23
|
-
appCode: string;
|
|
24
|
-
}) => Promise<boolean>;
|
|
18
|
+
export declare const useCredentialsHandler: (onAuthComplete: (state: boolean, data: UserValidatedResponse | null) => void) => {
|
|
19
|
+
handleSubmitCredentials: (CredAuthEndpoint: string, credentials: Credentials, appCode: string) => Promise<boolean>;
|
|
25
20
|
loading: boolean;
|
|
26
21
|
setLoading: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
27
22
|
attemptCount: number;
|