@authing/react-ui-components 3.1.19-hep.2 → 3.1.19-hep.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 CHANGED
@@ -428,10 +428,9 @@ declare module '@authing/react-ui-components/components/AuthingGuard/ToggleLang/
428
428
 
429
429
  }
430
430
  declare module '@authing/react-ui-components/components/AuthingGuard/api/appConfig' {
431
- import { Lang, LoginMethods, Protocol } from '@authing/react-ui-components/components/AuthingGuard/types/index';
431
+ import { Lang, LoginMethods, Protocol, RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
432
432
  import { IAzureAdConnectionConfig, ICasConnectionConfig, IOAuthConnectionConfig, ISamlConnectionConfig, OIDCConnectionConfig, SocialConnectionItem } from '@authing/react-ui-components/components/AuthingGuard/api/userPoolConfig';
433
433
  import { PasswordStrength } from '@authing/react-ui-components/components/_utils/index';
434
- import { NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
435
434
  export enum ApplicationMfaType {
436
435
  SMS = "SMS",
437
436
  EMAIL = "EMAIL"
@@ -516,8 +515,8 @@ declare module '@authing/react-ui-components/components/AuthingGuard/api/appConf
516
515
  [x: string]: string;
517
516
  };
518
517
  registerTypeConfig: {
519
- emailRegisterType?: NewRegisterMethods[];
520
- phoneRegisterType?: NewRegisterMethods[];
518
+ emailRegisterType?: RegisterMethods[];
519
+ phoneRegisterType?: RegisterMethods[];
521
520
  };
522
521
  };
523
522
  qrcodeTabsSettings: QrcodeTabsSettings;
@@ -691,7 +690,7 @@ declare module '@authing/react-ui-components/components/AuthingGuard/api/userPoo
691
690
 
692
691
  }
693
692
  declare module '@authing/react-ui-components/components/AuthingGuard/constants' {
694
- import { UserConfig, LoginMethods, RegisterMethods, LocalesConfig } from '@authing/react-ui-components/components/AuthingGuard/types/index';
693
+ import { UserConfig, LoginMethods, LocalesConfig } from '@authing/react-ui-components/components/AuthingGuard/types/index';
695
694
  export const OTP_MFA_CODE = 1635;
696
695
  export const APP_MFA_CODE = 1636;
697
696
  export const NEED_CAPTCHA = 2000;
@@ -704,10 +703,7 @@ declare module '@authing/react-ui-components/components/AuthingGuard/constants'
704
703
  ad: string;
705
704
  "wechatmp-qrcode": string;
706
705
  };
707
- export const REGISTER_METHODS_MAP: () => {
708
- email: string;
709
- phone: string;
710
- };
706
+ export const REGISTER_METHODS_MAP: any;
711
707
  export const HIDE_SOCIALS: string[];
712
708
  export const HIDE_SOCIALS_SHOWIN_ENTERPRISE: string[];
713
709
  export enum ApplicationMfaType {
@@ -881,7 +877,8 @@ declare module '@authing/react-ui-components/components/AuthingGuard/types/Guard
881
877
  }
882
878
  export enum RegisterMethods {
883
879
  Email = "email",
884
- Phone = "phone"
880
+ Phone = "phone",
881
+ EmailCode = "emailCode"
885
882
  }
886
883
  export enum GuardScenes {
887
884
  Login = "login",
@@ -1392,6 +1389,8 @@ declare module '@authing/react-ui-components/components/CompleteInfo/interface'
1392
1389
  export interface RegisterCompleteInfoInitData {
1393
1390
  content: any;
1394
1391
  businessRequestName: 'registerByEmail' | 'registerByPhoneCode' | 'registerByEmailCode';
1392
+ onRegisterFailed: Function;
1393
+ onRegisterSuccess: Function;
1395
1394
  }
1396
1395
  export interface RegisterCompletePasswordInitData extends RegisterCompleteInfoInitData {
1397
1396
  isChangeComplete: boolean;
@@ -1461,7 +1460,10 @@ declare module '@authing/react-ui-components/components/DownloadAuthenticator/in
1461
1460
  declare module '@authing/react-ui-components/components/Error/index' {
1462
1461
  import React from 'react';
1463
1462
  import './styles.less';
1464
- export const GuardErrorView: React.FC;
1463
+ export interface ErrorProps {
1464
+ error?: Error;
1465
+ }
1466
+ export const GuardErrorView: React.FC<ErrorProps>;
1465
1467
 
1466
1468
  }
1467
1469
  declare module '@authing/react-ui-components/components/Error/interface' {
@@ -1555,6 +1557,7 @@ declare module '@authing/react-ui-components/components/Guard/GuardModule/stateM
1555
1557
  private changeModuleEvent;
1556
1558
  private stateMachineLog;
1557
1559
  constructor(changeModuleEvent: ChangeModuleEvent, initData: ModuleState);
1560
+ uninstallPopstate: () => void;
1558
1561
  globalWindow: () => Window | undefined;
1559
1562
  next: (nextModule: GuardModuleType, initData: any) => void;
1560
1563
  back: (initData?: any) => void;
@@ -1562,8 +1565,9 @@ declare module '@authing/react-ui-components/components/Guard/GuardModule/stateM
1562
1565
  historyPush: (data: ModuleState, actionType?: ActionType) => void;
1563
1566
  historyBack: (data: ModuleState) => void;
1564
1567
  setConfig: (config: GuardLocalConfig) => void;
1568
+ isUseHistoryHijack: () => boolean;
1569
+ onPopstate: () => void;
1565
1570
  }
1566
- export const useHistoryHijack: (back?: (() => void) | undefined) => ((state?: any) => void)[];
1567
1571
  export const initGuardStateMachine: (changeMouleEvent: ChangeModuleEvent, initData: ModuleState) => GuardStateMachine;
1568
1572
  export const getGuardStateMachine: () => GuardStateMachine;
1569
1573
  export const useGuardStateMachine: () => GuardStateMachine;
@@ -1782,6 +1786,19 @@ declare module '@authing/react-ui-components/components/Guard/sso' {
1782
1786
  }
1783
1787
  export const trackSession: () => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<SessionData>>;
1784
1788
 
1789
+ }
1790
+ declare module '@authing/react-ui-components/components/GuardButton/GuardButton' {
1791
+ import React from 'react';
1792
+ import { ButtonProps } from 'antd/lib/button';
1793
+ import './styles.less';
1794
+ export interface GuardButtonProps extends ButtonProps {
1795
+ }
1796
+ export const GuardButton: React.FC<GuardButtonProps>;
1797
+
1798
+ }
1799
+ declare module '@authing/react-ui-components/components/GuardButton/index' {
1800
+ export * from '@authing/react-ui-components/components/GuardButton/GuardButton';
1801
+
1785
1802
  }
1786
1803
  declare module '@authing/react-ui-components/components/IconFont/iconfont' {
1787
1804
  export const GenerateSvg: (guardDocument: Document, svgString: string) => void;
@@ -2040,6 +2057,7 @@ declare module '@authing/react-ui-components/components/Login/core/withPassword/
2040
2057
  agreements: Agreement[];
2041
2058
  loginWay?: LoginMethods;
2042
2059
  submitButText?: string;
2060
+ saveIdentify?: (type: LoginMethods, identity: string) => void;
2043
2061
  }
2044
2062
  export const LoginWithPassword: (props: LoginWithPasswordProps) => JSX.Element;
2045
2063
  export {};
@@ -2051,8 +2069,9 @@ declare module '@authing/react-ui-components/components/Login/core/withVerifyCod
2051
2069
  import { VerifyLoginMethods } from '@authing/react-ui-components/components/AuthingGuard/api/index';
2052
2070
  export interface FormItemIdentifyProps extends FormItemProps {
2053
2071
  checkRepeat?: boolean;
2072
+ checkExist?: boolean;
2054
2073
  methods: VerifyLoginMethods[];
2055
- currentMethod?: 'phone-code' | 'email-code';
2074
+ currentMethod: 'phone-code' | 'email-code';
2056
2075
  areaCode?: string;
2057
2076
  }
2058
2077
  export const FormItemIdentify: React.FC<FormItemIdentifyProps>;
@@ -2157,6 +2176,11 @@ declare module '@authing/react-ui-components/components/Login/interface' {
2157
2176
  export interface GuardLoginViewProps extends GuardLoginProps, IG2FCViewProps {
2158
2177
  config: LoginConfig;
2159
2178
  }
2179
+ export interface GuardLoginInitData {
2180
+ specifyDefaultLoginMethod?: LoginMethods;
2181
+ _firstItemInitialValue?: string;
2182
+ _lockMethod?: string;
2183
+ }
2160
2184
  export const getDefaultLoginConfig: () => LoginConfig;
2161
2185
 
2162
2186
  }
@@ -2518,6 +2542,21 @@ declare module '@authing/react-ui-components/components/Register/components/Agre
2518
2542
  }
2519
2543
  export const Agreements: FC<AgreementsProps>;
2520
2544
 
2545
+ }
2546
+ declare module '@authing/react-ui-components/components/Register/core/WithCode' {
2547
+ import React from 'react';
2548
+ import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
2549
+ export interface RegisterWithCodeProps {
2550
+ onRegisterSuccess: Function;
2551
+ onRegisterFailed: Function;
2552
+ onBeforeRegister?: Function;
2553
+ agreements: Agreement[];
2554
+ publicConfig?: ApplicationConfig;
2555
+ registeContext?: any;
2556
+ methods: any[];
2557
+ }
2558
+ export const RegisterWithCode: React.FC<RegisterWithCodeProps>;
2559
+
2521
2560
  }
2522
2561
  declare module '@authing/react-ui-components/components/Register/core/WithEmail' {
2523
2562
  import React from 'react';
@@ -2566,13 +2605,13 @@ declare module '@authing/react-ui-components/components/Register/index' {
2566
2605
 
2567
2606
  }
2568
2607
  declare module '@authing/react-ui-components/components/Register/interface' {
2569
- import { IG2FCProps, IG2Config, IG2Events, NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
2570
- import { AuthenticationClient, User, EmailRegisterParams, PhoneRegisterParams } from '@authing/react-ui-components/components/index';
2608
+ import { IG2FCProps, IG2Config, IG2Events } from '@authing/react-ui-components/components/Type/index';
2609
+ import { AuthenticationClient, User, EmailRegisterParams, PhoneRegisterParams, RegisterMethods } from '@authing/react-ui-components/components/index';
2571
2610
  import { Agreement } from '@authing/react-ui-components/components/AuthingGuard/api/index';
2572
2611
  export interface RegisterConfig extends IG2Config {
2573
2612
  disableRegister?: boolean;
2574
- registerMethods?: NewRegisterMethods[];
2575
- defaultRegisterMethod?: NewRegisterMethods;
2613
+ registerMethods?: RegisterMethods[];
2614
+ defaultRegisterMethod?: RegisterMethods;
2576
2615
  publicKey?: string;
2577
2616
  agreementEnabled?: boolean;
2578
2617
  agreements?: Agreement[];
@@ -2582,7 +2621,7 @@ declare module '@authing/react-ui-components/components/Register/interface' {
2582
2621
  onBeforeRegister?: (registerInfo: EmailRegisterParams | PhoneRegisterParams, authClient: AuthenticationClient) => boolean | Promise<boolean>;
2583
2622
  onRegister?: (user: User, authClient: AuthenticationClient) => void;
2584
2623
  onRegisterError?: (error: any) => void;
2585
- onRegisterTabChange?: (activeTab: NewRegisterMethods) => void;
2624
+ onRegisterTabChange?: (activeTab: RegisterMethods) => void;
2586
2625
  }
2587
2626
  export interface GuardRegisterProps extends IG2FCProps, RegisterEvents {
2588
2627
  config?: Partial<RegisterConfig>;
@@ -2598,12 +2637,14 @@ declare module '@authing/react-ui-components/components/Register/utils' {
2598
2637
 
2599
2638
  }
2600
2639
  declare module '@authing/react-ui-components/components/SelfUnlock/core/selfUnlock' {
2601
- /// <reference types="react" />
2640
+ import React from 'react';
2602
2641
  export enum InputMethodMap {
2603
2642
  email = "email-code",
2604
2643
  phone = "phone-code"
2605
2644
  }
2606
- export const SelfUnlock: () => JSX.Element;
2645
+ export const SelfUnlock: ({ identifyRef, }: {
2646
+ identifyRef?: React.MutableRefObject<string> | undefined;
2647
+ }) => JSX.Element;
2607
2648
 
2608
2649
  }
2609
2650
  declare module '@authing/react-ui-components/components/SelfUnlock/index' {
@@ -2712,7 +2753,8 @@ declare module '@authing/react-ui-components/components/SingleComponent/index' {
2712
2753
  }
2713
2754
  declare module '@authing/react-ui-components/components/SubmitButton/index' {
2714
2755
  import React from 'react';
2715
- interface SubmitButtonProps {
2756
+ import { ButtonProps } from 'antd/lib/button';
2757
+ interface SubmitButtonProps extends ButtonProps {
2716
2758
  text?: string;
2717
2759
  className?: string;
2718
2760
  onClick?: any;
@@ -2812,11 +2854,6 @@ declare module '@authing/react-ui-components/components/Type/index' {
2812
2854
  showChangeLanguage: boolean;
2813
2855
  };
2814
2856
  }
2815
- export enum NewRegisterMethods {
2816
- Email = "email",
2817
- Phone = "phone",
2818
- EmailCode = "emailCode"
2819
- }
2820
2857
  export enum EmailScene {
2821
2858
  WELCOME_EMAIL = "WELCOME_EMAIL",
2822
2859
  FIRST_CREATED_USER = "FIRST_CREATED_USER",
@@ -2858,12 +2895,11 @@ declare module '@authing/react-ui-components/components/ValidatorRules/index' {
2858
2895
  export interface ValidatorFormItemProps extends FormItemProps {
2859
2896
  form?: FormInstance;
2860
2897
  checkRepeat?: boolean;
2898
+ checkExist?: boolean;
2861
2899
  areaCode?: string;
2862
2900
  isCheckI18nSms?: boolean;
2863
2901
  }
2864
2902
  export interface ValidatorFormItemMetaProps extends ValidatorFormItemProps {
2865
- form?: FormInstance;
2866
- checkRepeat?: boolean;
2867
2903
  method: 'email' | 'phone' | 'username';
2868
2904
  }
2869
2905
  export interface PasswordFormItemProps extends FormItemProps {
@@ -2929,8 +2965,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
2929
2965
  import { ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
2930
2966
  import { GuardComponentConfig, GuardLocalConfig } from '@authing/react-ui-components/components/Guard/config';
2931
2967
  import { GuardHttp } from '@authing/react-ui-components/components/_utils/guardHttp';
2932
- import { NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
2933
2968
  import { GuardPageConfig } from '@authing/react-ui-components/components/Type/index';
2969
+ import { RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
2934
2970
  export const getPublicConfig: (appId: string) => ApplicationConfig;
2935
2971
  export const setPublicConfig: (appId: string, config: ApplicationConfig) => ApplicationConfig;
2936
2972
  export const useMergeDefaultConfig: (defaultConfig: GuardLocalConfig, config?: GuardComponentConfig | undefined) => GuardLocalConfig | undefined;
@@ -2944,8 +2980,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
2944
2980
  openEventsMapping?: boolean | undefined;
2945
2981
  _qrCodeScanOptions?: Record<import("@authing/react-ui-components/components/Guard/config").QrCodeScanType, import("../../Guard/config").QrCodeScanOptions> | undefined;
2946
2982
  disableRegister?: boolean | undefined;
2947
- registerMethods?: NewRegisterMethods[] | undefined;
2948
- defaultRegisterMethod?: NewRegisterMethods | undefined;
2983
+ registerMethods?: RegisterMethods[] | undefined;
2984
+ defaultRegisterMethod?: RegisterMethods | undefined;
2949
2985
  publicKey?: string | undefined;
2950
2986
  agreementEnabled?: boolean | undefined;
2951
2987
  agreements?: import("@authing/react-ui-components/components/AuthingGuard/api/index").Agreement[] | undefined;
@@ -2955,7 +2991,7 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
2955
2991
  lang: string;
2956
2992
  langRange: string[];
2957
2993
  isHost?: boolean | undefined;
2958
- mode: import("@authing/react-ui-components/components/index").GuardMode;
2994
+ mode: import("@authing/react-ui-components/components/AuthingGuard/types/index").GuardMode;
2959
2995
  clickCloseable: boolean;
2960
2996
  escCloseable: boolean;
2961
2997
  userpool?: string | undefined;
@@ -2966,8 +3002,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
2966
3002
  __unAuthFlow__?: boolean | undefined;
2967
3003
  autoRegister?: boolean | undefined;
2968
3004
  disableResetPwd?: boolean | undefined;
2969
- defaultLoginMethod?: import("@authing/react-ui-components/components/index").LoginMethods | undefined;
2970
- loginMethods?: import("@authing/react-ui-components/components/index").LoginMethods[] | undefined;
3005
+ defaultLoginMethod?: import("@authing/react-ui-components/components/AuthingGuard/types/index").LoginMethods | undefined;
3006
+ loginMethods?: import("@authing/react-ui-components/components/AuthingGuard/types/index").LoginMethods[] | undefined;
2971
3007
  passwordLoginMethods?: import("@authing/react-ui-components/components/AuthingGuard/api/index").PasswordLoginMethods[] | undefined;
2972
3008
  socialConnections?: import("authing-js-sdk").SocialConnectionProvider[] | undefined;
2973
3009
  socialConnectionsBtnShape?: "default" | "button" | "icon" | undefined;
@@ -3056,6 +3092,14 @@ declare module '@authing/react-ui-components/components/_utils/context' {
3056
3092
  }>;
3057
3093
  Consumer: React.Consumer<IGuardContext>;
3058
3094
  };
3095
+ export interface IGuardContextProvider {
3096
+ spin: boolean;
3097
+ spinChange: (spin: boolean) => void;
3098
+ }
3099
+ export const useGuardButtonContext: () => {
3100
+ GuardButtonProvider: React.FC<{}>;
3101
+ };
3102
+ export const useGuardButtonState: () => IGuardContextProvider;
3059
3103
  export const useGuardPublicConfig: () => ApplicationConfig;
3060
3104
  export const useGuardHttpClient: () => GuardHttp;
3061
3105
  export const useGuardDefaultMergedConfig: () => GuardLocalConfig;
@@ -3105,7 +3149,8 @@ declare module '@authing/react-ui-components/components/_utils/errorFace' {
3105
3149
  }
3106
3150
  declare module '@authing/react-ui-components/components/_utils/facePlugin/index' {
3107
3151
  import { FacePlugin } from '@authing/react-ui-components/components/_utils/facePlugin/interface';
3108
- export const getFacePlugin: () => FacePlugin;
3152
+ export const getFacePlugin: () => FacePlugin | undefined;
3153
+ export const useFacePlugin: () => FacePlugin | undefined;
3109
3154
  export const initFacePlugin: (facePlugin: FacePlugin) => FacePlugin;
3110
3155
 
3111
3156
  }
@@ -3191,6 +3236,10 @@ declare module '@authing/react-ui-components/components/_utils/hooks/index' {
3191
3236
  countryCode: string | undefined;
3192
3237
  phoneNumber: string;
3193
3238
  };
3239
+ export enum SocialConnectionEvent {
3240
+ Message = "message",
3241
+ Auth = "auth"
3242
+ }
3194
3243
  /**
3195
3244
  *
3196
3245
  * @param config
@@ -3243,7 +3292,7 @@ declare module '@authing/react-ui-components/components/_utils/index' {
3243
3292
  import { User } from 'authing-js-sdk';
3244
3293
  import { ApplicationConfig, ComplateFiledsPlace } from '@authing/react-ui-components/components/AuthingGuard/api/index';
3245
3294
  import { GuardProps } from '@authing/react-ui-components/components/Guard/index';
3246
- import { NewRegisterMethods } from '@authing/react-ui-components/components/Type/index';
3295
+ import { LoginMethods, RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
3247
3296
  export * from '@authing/react-ui-components/components/_utils/popupCenter';
3248
3297
  export * from '@authing/react-ui-components/components/_utils/clipboard';
3249
3298
  export const VALIDATE_PATTERN: {
@@ -3312,12 +3361,20 @@ declare module '@authing/react-ui-components/components/_utils/index' {
3312
3361
  export const getPasswordValidate: (strength?: PasswordStrength, customPasswordStrength?: any, fieldRequiredRuleMessage?: string | undefined) => Rule[];
3313
3362
  export const sleep: (delay: number) => Promise<unknown>;
3314
3363
  export const shoudGoToComplete: (user: User, contextType: ComplateFiledsPlace, config: ApplicationConfig | undefined, autoRegister?: boolean | undefined) => boolean;
3315
- export const tabSort: (defaultValue: NewRegisterMethods, tabList: NewRegisterMethods[]) => NewRegisterMethods[];
3364
+ export const tabSort: (defaultValue: any, tabList: RegisterMethods[]) => RegisterMethods[];
3316
3365
  export const mailDesensitization: (mail: string) => string;
3317
3366
  export const phoneDesensitization: (phone: string) => string;
3318
3367
  export const getHundreds: (num: number) => number;
3319
3368
  export const GuardPropsFilter: (pre: GuardProps, current: GuardProps) => boolean;
3320
3369
  export const getDocumentNode: (node: Node & ParentNode) => Document;
3370
+ export const getLoginTypePipe: (publicConfig: ApplicationConfig, registerMethod: RegisterMethods) => {
3371
+ specifyDefaultLoginMethod: LoginMethods;
3372
+ lockMethod: string;
3373
+ } | {
3374
+ specifyDefaultLoginMethod: LoginMethods;
3375
+ lockMethod?: undefined;
3376
+ } | undefined;
3377
+ export const getPasswordIdentify: (identity: string) => string;
3321
3378
 
3322
3379
  }
3323
3380
  declare module '@authing/react-ui-components/components/_utils/initAppId' {
@@ -3514,7 +3571,7 @@ declare module '@authing/react-ui-components/components/version/index' {
3514
3571
 
3515
3572
  }
3516
3573
  declare module '@authing/react-ui-components/components/version/version' {
3517
- const _default: "3.1.19-hep.2";
3574
+ const _default: "3.1.19-hep.3";
3518
3575
  export default _default;
3519
3576
 
3520
3577
  }