@authing/react-ui-components 3.1.19 → 3.1.20-rc.3
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/lib/index.d.ts +48 -40
- package/lib/index.min.css +1 -1
- package/lib/index.min.js +1 -1
- package/package.json +1 -1
package/lib/index.d.ts
CHANGED
|
@@ -378,10 +378,9 @@ declare module '@authing/react-ui-components/components/AuthingGuard/ToggleLang/
|
|
|
378
378
|
|
|
379
379
|
}
|
|
380
380
|
declare module '@authing/react-ui-components/components/AuthingGuard/api/appConfig' {
|
|
381
|
-
import { Lang, LoginMethods, Protocol } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
381
|
+
import { Lang, LoginMethods, Protocol, RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
382
382
|
import { IAzureAdConnectionConfig, ICasConnectionConfig, IOAuthConnectionConfig, ISamlConnectionConfig, OIDCConnectionConfig, SocialConnectionItem } from '@authing/react-ui-components/components/AuthingGuard/api/userPoolConfig';
|
|
383
383
|
import { PasswordStrength } from '@authing/react-ui-components/components/_utils/index';
|
|
384
|
-
import { NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
|
|
385
384
|
export enum ApplicationMfaType {
|
|
386
385
|
SMS = "SMS",
|
|
387
386
|
EMAIL = "EMAIL"
|
|
@@ -466,8 +465,8 @@ declare module '@authing/react-ui-components/components/AuthingGuard/api/appConf
|
|
|
466
465
|
[x: string]: string;
|
|
467
466
|
};
|
|
468
467
|
registerTypeConfig: {
|
|
469
|
-
emailRegisterType?:
|
|
470
|
-
phoneRegisterType?:
|
|
468
|
+
emailRegisterType?: RegisterMethods[];
|
|
469
|
+
phoneRegisterType?: RegisterMethods[];
|
|
471
470
|
};
|
|
472
471
|
};
|
|
473
472
|
qrcodeTabsSettings: QrcodeTabsSettings;
|
|
@@ -638,7 +637,7 @@ declare module '@authing/react-ui-components/components/AuthingGuard/api/userPoo
|
|
|
638
637
|
|
|
639
638
|
}
|
|
640
639
|
declare module '@authing/react-ui-components/components/AuthingGuard/constants' {
|
|
641
|
-
import { UserConfig, LoginMethods,
|
|
640
|
+
import { UserConfig, LoginMethods, LocalesConfig } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
642
641
|
export const OTP_MFA_CODE = 1635;
|
|
643
642
|
export const APP_MFA_CODE = 1636;
|
|
644
643
|
export const NEED_CAPTCHA = 2000;
|
|
@@ -651,10 +650,7 @@ declare module '@authing/react-ui-components/components/AuthingGuard/constants'
|
|
|
651
650
|
ad: string;
|
|
652
651
|
"wechatmp-qrcode": string;
|
|
653
652
|
};
|
|
654
|
-
export const REGISTER_METHODS_MAP:
|
|
655
|
-
email: string;
|
|
656
|
-
phone: string;
|
|
657
|
-
};
|
|
653
|
+
export const REGISTER_METHODS_MAP: any;
|
|
658
654
|
export const HIDE_SOCIALS: string[];
|
|
659
655
|
export const HIDE_SOCIALS_SHOWIN_ENTERPRISE: string[];
|
|
660
656
|
export enum ApplicationMfaType {
|
|
@@ -828,7 +824,8 @@ declare module '@authing/react-ui-components/components/AuthingGuard/types/Guard
|
|
|
828
824
|
}
|
|
829
825
|
export enum RegisterMethods {
|
|
830
826
|
Email = "email",
|
|
831
|
-
Phone = "phone"
|
|
827
|
+
Phone = "phone",
|
|
828
|
+
EmailCode = "emailCode"
|
|
832
829
|
}
|
|
833
830
|
export enum GuardScenes {
|
|
834
831
|
Login = "login",
|
|
@@ -1333,6 +1330,8 @@ declare module '@authing/react-ui-components/components/CompleteInfo/interface'
|
|
|
1333
1330
|
export interface RegisterCompleteInfoInitData {
|
|
1334
1331
|
content: any;
|
|
1335
1332
|
businessRequestName: 'registerByEmail' | 'registerByPhoneCode' | 'registerByEmailCode';
|
|
1333
|
+
onRegisterFailed: Function;
|
|
1334
|
+
onRegisterSuccess: Function;
|
|
1336
1335
|
}
|
|
1337
1336
|
export interface RegisterCompletePasswordInitData extends RegisterCompleteInfoInitData {
|
|
1338
1337
|
isChangeComplete: boolean;
|
|
@@ -2094,6 +2093,11 @@ declare module '@authing/react-ui-components/components/Login/interface' {
|
|
|
2094
2093
|
export interface GuardLoginViewProps extends GuardLoginProps, IG2FCViewProps {
|
|
2095
2094
|
config: LoginConfig;
|
|
2096
2095
|
}
|
|
2096
|
+
export interface GuardLoginInitData {
|
|
2097
|
+
specifyDefaultLoginMethod?: LoginMethods;
|
|
2098
|
+
_firstItemInitialValue?: string;
|
|
2099
|
+
_lockMethod?: string;
|
|
2100
|
+
}
|
|
2097
2101
|
export const getDefaultLoginConfig: () => LoginConfig;
|
|
2098
2102
|
|
|
2099
2103
|
}
|
|
@@ -2455,45 +2459,47 @@ declare module '@authing/react-ui-components/components/Register/components/Agre
|
|
|
2455
2459
|
export const Agreements: FC<AgreementsProps>;
|
|
2456
2460
|
|
|
2457
2461
|
}
|
|
2458
|
-
declare module '@authing/react-ui-components/components/Register/core/
|
|
2462
|
+
declare module '@authing/react-ui-components/components/Register/core/WithCode' {
|
|
2459
2463
|
import React from 'react';
|
|
2460
2464
|
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2461
|
-
export interface
|
|
2465
|
+
export interface RegisterWithCodeProps {
|
|
2462
2466
|
onRegisterSuccess: Function;
|
|
2463
2467
|
onRegisterFailed: Function;
|
|
2464
2468
|
onBeforeRegister?: Function;
|
|
2465
|
-
publicConfig?: ApplicationConfig;
|
|
2466
2469
|
agreements: Agreement[];
|
|
2470
|
+
publicConfig?: ApplicationConfig;
|
|
2467
2471
|
registeContext?: any;
|
|
2472
|
+
methods: any[];
|
|
2468
2473
|
}
|
|
2469
|
-
export const
|
|
2474
|
+
export const RegisterWithCode: React.FC<RegisterWithCodeProps>;
|
|
2470
2475
|
|
|
2471
2476
|
}
|
|
2472
|
-
declare module '@authing/react-ui-components/components/Register/core/
|
|
2477
|
+
declare module '@authing/react-ui-components/components/Register/core/WithEmail' {
|
|
2473
2478
|
import React from 'react';
|
|
2474
2479
|
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2475
|
-
export interface
|
|
2480
|
+
export interface RegisterWithEmailProps {
|
|
2476
2481
|
onRegisterSuccess: Function;
|
|
2477
2482
|
onRegisterFailed: Function;
|
|
2478
2483
|
onBeforeRegister?: Function;
|
|
2479
|
-
agreements: Agreement[];
|
|
2480
2484
|
publicConfig?: ApplicationConfig;
|
|
2485
|
+
agreements: Agreement[];
|
|
2481
2486
|
registeContext?: any;
|
|
2482
2487
|
}
|
|
2483
|
-
export const
|
|
2488
|
+
export const RegisterWithEmail: React.FC<RegisterWithEmailProps>;
|
|
2484
2489
|
|
|
2485
2490
|
}
|
|
2486
|
-
declare module '@authing/react-ui-components/components/Register/core/
|
|
2491
|
+
declare module '@authing/react-ui-components/components/Register/core/WithEmailCode' {
|
|
2487
2492
|
import React from 'react';
|
|
2488
2493
|
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2489
|
-
export interface
|
|
2494
|
+
export interface RegisterWithEmailCodeProps {
|
|
2490
2495
|
onRegisterSuccess: Function;
|
|
2491
2496
|
onRegisterFailed: Function;
|
|
2497
|
+
onBeforeRegister?: Function;
|
|
2492
2498
|
agreements: Agreement[];
|
|
2493
2499
|
publicConfig?: ApplicationConfig;
|
|
2494
2500
|
registeContext?: any;
|
|
2495
2501
|
}
|
|
2496
|
-
export const
|
|
2502
|
+
export const RegisterWithEmailCode: React.FC<RegisterWithEmailCodeProps>;
|
|
2497
2503
|
|
|
2498
2504
|
}
|
|
2499
2505
|
declare module '@authing/react-ui-components/components/Register/index' {
|
|
@@ -2502,13 +2508,13 @@ declare module '@authing/react-ui-components/components/Register/index' {
|
|
|
2502
2508
|
|
|
2503
2509
|
}
|
|
2504
2510
|
declare module '@authing/react-ui-components/components/Register/interface' {
|
|
2505
|
-
import { IG2FCProps, IG2Config, IG2Events
|
|
2506
|
-
import { AuthenticationClient, User, EmailRegisterParams, PhoneRegisterParams } from '@authing/react-ui-components/components/index';
|
|
2511
|
+
import { IG2FCProps, IG2Config, IG2Events } from '@authing/react-ui-components/components/Type/index';
|
|
2512
|
+
import { AuthenticationClient, User, EmailRegisterParams, PhoneRegisterParams, RegisterMethods } from '@authing/react-ui-components/components/index';
|
|
2507
2513
|
import { Agreement } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2508
2514
|
export interface RegisterConfig extends IG2Config {
|
|
2509
2515
|
disableRegister?: boolean;
|
|
2510
|
-
registerMethods?:
|
|
2511
|
-
defaultRegisterMethod?:
|
|
2516
|
+
registerMethods?: RegisterMethods[];
|
|
2517
|
+
defaultRegisterMethod?: RegisterMethods;
|
|
2512
2518
|
publicKey?: string;
|
|
2513
2519
|
agreementEnabled?: boolean;
|
|
2514
2520
|
agreements?: Agreement[];
|
|
@@ -2518,7 +2524,7 @@ declare module '@authing/react-ui-components/components/Register/interface' {
|
|
|
2518
2524
|
onBeforeRegister?: (registerInfo: EmailRegisterParams | PhoneRegisterParams, authClient: AuthenticationClient) => boolean | Promise<boolean>;
|
|
2519
2525
|
onRegister?: (user: User, authClient: AuthenticationClient) => void;
|
|
2520
2526
|
onRegisterError?: (error: any) => void;
|
|
2521
|
-
onRegisterTabChange?: (activeTab:
|
|
2527
|
+
onRegisterTabChange?: (activeTab: RegisterMethods) => void;
|
|
2522
2528
|
}
|
|
2523
2529
|
export interface GuardRegisterProps extends IG2FCProps, RegisterEvents {
|
|
2524
2530
|
config?: Partial<RegisterConfig>;
|
|
@@ -2716,11 +2722,6 @@ declare module '@authing/react-ui-components/components/Type/index' {
|
|
|
2716
2722
|
showChangeLanguage: boolean;
|
|
2717
2723
|
};
|
|
2718
2724
|
}
|
|
2719
|
-
export enum NewRegisterMethods {
|
|
2720
|
-
Email = "email",
|
|
2721
|
-
Phone = "phone",
|
|
2722
|
-
EmailCode = "emailCode"
|
|
2723
|
-
}
|
|
2724
2725
|
export enum EmailScene {
|
|
2725
2726
|
WELCOME_EMAIL = "WELCOME_EMAIL",
|
|
2726
2727
|
FIRST_CREATED_USER = "FIRST_CREATED_USER",
|
|
@@ -2832,8 +2833,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
2832
2833
|
import { ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2833
2834
|
import { GuardComponentConfig, GuardLocalConfig } from '@authing/react-ui-components/components/Guard/config';
|
|
2834
2835
|
import { GuardHttp } from '@authing/react-ui-components/components/_utils/guardHttp';
|
|
2835
|
-
import { NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
|
|
2836
2836
|
import { GuardPageConfig } from '@authing/react-ui-components/components/Type/index';
|
|
2837
|
+
import { RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
2837
2838
|
export const getPublicConfig: (appId: string) => ApplicationConfig;
|
|
2838
2839
|
export const setPublicConfig: (appId: string, config: ApplicationConfig) => ApplicationConfig;
|
|
2839
2840
|
export const useMergeDefaultConfig: (defaultConfig: GuardLocalConfig, config?: GuardComponentConfig | undefined) => GuardLocalConfig | undefined;
|
|
@@ -2847,8 +2848,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
2847
2848
|
openEventsMapping?: boolean | undefined;
|
|
2848
2849
|
_qrCodeScanOptions?: Record<import("@authing/react-ui-components/components/Guard/config").QrCodeScanType, import("../../Guard/config").QrCodeScanOptions> | undefined;
|
|
2849
2850
|
disableRegister?: boolean | undefined;
|
|
2850
|
-
registerMethods?:
|
|
2851
|
-
defaultRegisterMethod?:
|
|
2851
|
+
registerMethods?: RegisterMethods[] | undefined;
|
|
2852
|
+
defaultRegisterMethod?: RegisterMethods | undefined;
|
|
2852
2853
|
publicKey?: string | undefined;
|
|
2853
2854
|
agreementEnabled?: boolean | undefined;
|
|
2854
2855
|
agreements?: import("@authing/react-ui-components/components/AuthingGuard/api/index").Agreement[] | undefined;
|
|
@@ -2858,7 +2859,7 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
2858
2859
|
lang: string;
|
|
2859
2860
|
langRange: string[];
|
|
2860
2861
|
isHost?: boolean | undefined;
|
|
2861
|
-
mode: import("@authing/react-ui-components/components/index").GuardMode;
|
|
2862
|
+
mode: import("@authing/react-ui-components/components/AuthingGuard/types/index").GuardMode;
|
|
2862
2863
|
clickCloseable: boolean;
|
|
2863
2864
|
escCloseable: boolean;
|
|
2864
2865
|
userpool?: string | undefined;
|
|
@@ -2869,8 +2870,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
2869
2870
|
__unAuthFlow__?: boolean | undefined;
|
|
2870
2871
|
autoRegister?: boolean | undefined;
|
|
2871
2872
|
disableResetPwd?: boolean | undefined;
|
|
2872
|
-
defaultLoginMethod?: import("@authing/react-ui-components/components/index").LoginMethods | undefined;
|
|
2873
|
-
loginMethods?: import("@authing/react-ui-components/components/index").LoginMethods[] | undefined;
|
|
2873
|
+
defaultLoginMethod?: import("@authing/react-ui-components/components/AuthingGuard/types/index").LoginMethods | undefined;
|
|
2874
|
+
loginMethods?: import("@authing/react-ui-components/components/AuthingGuard/types/index").LoginMethods[] | undefined;
|
|
2874
2875
|
passwordLoginMethods?: import("@authing/react-ui-components/components/AuthingGuard/api/index").PasswordLoginMethods[] | undefined;
|
|
2875
2876
|
socialConnections?: import("authing-js-sdk").SocialConnectionProvider[] | undefined;
|
|
2876
2877
|
socialConnectionsBtnShape?: "default" | "button" | "icon" | undefined;
|
|
@@ -3146,7 +3147,7 @@ declare module '@authing/react-ui-components/components/_utils/index' {
|
|
|
3146
3147
|
import { User } from 'authing-js-sdk';
|
|
3147
3148
|
import { ApplicationConfig, ComplateFiledsPlace } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
3148
3149
|
import { GuardProps } from '@authing/react-ui-components/components/Guard/index';
|
|
3149
|
-
import {
|
|
3150
|
+
import { LoginMethods, RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
3150
3151
|
export * from '@authing/react-ui-components/components/_utils/popupCenter';
|
|
3151
3152
|
export * from '@authing/react-ui-components/components/_utils/clipboard';
|
|
3152
3153
|
export const VALIDATE_PATTERN: {
|
|
@@ -3215,12 +3216,19 @@ declare module '@authing/react-ui-components/components/_utils/index' {
|
|
|
3215
3216
|
export const getPasswordValidate: (strength?: PasswordStrength, customPasswordStrength?: any, fieldRequiredRuleMessage?: string | undefined) => Rule[];
|
|
3216
3217
|
export const sleep: (delay: number) => Promise<unknown>;
|
|
3217
3218
|
export const shoudGoToComplete: (user: User, contextType: ComplateFiledsPlace, config: ApplicationConfig | undefined, autoRegister?: boolean | undefined) => boolean;
|
|
3218
|
-
export const tabSort: (defaultValue:
|
|
3219
|
+
export const tabSort: (defaultValue: any, tabList: RegisterMethods[]) => RegisterMethods[];
|
|
3219
3220
|
export const mailDesensitization: (mail: string) => string;
|
|
3220
3221
|
export const phoneDesensitization: (phone: string) => string;
|
|
3221
3222
|
export const getHundreds: (num: number) => number;
|
|
3222
3223
|
export const GuardPropsFilter: (pre: GuardProps, current: GuardProps) => boolean;
|
|
3223
3224
|
export const getDocumentNode: (node: Node & ParentNode) => Document;
|
|
3225
|
+
export const getLoginTypePipe: (publicConfig: ApplicationConfig, registerMethod: RegisterMethods) => {
|
|
3226
|
+
specifyDefaultLoginMethod: LoginMethods;
|
|
3227
|
+
lockMethod: string;
|
|
3228
|
+
} | {
|
|
3229
|
+
specifyDefaultLoginMethod: LoginMethods;
|
|
3230
|
+
lockMethod?: undefined;
|
|
3231
|
+
} | undefined;
|
|
3224
3232
|
|
|
3225
3233
|
}
|
|
3226
3234
|
declare module '@authing/react-ui-components/components/_utils/initAppId' {
|
|
@@ -3414,7 +3422,7 @@ declare module '@authing/react-ui-components/components/version/index' {
|
|
|
3414
3422
|
|
|
3415
3423
|
}
|
|
3416
3424
|
declare module '@authing/react-ui-components/components/version/version' {
|
|
3417
|
-
const _default: "3.1.
|
|
3425
|
+
const _default: "3.1.20-rc.3";
|
|
3418
3426
|
export default _default;
|
|
3419
3427
|
|
|
3420
3428
|
}
|