@authing/react-ui-components 4.0.4-ynby.0 → 4.0.5-alpha.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@authing/react-ui-components",
3
- "version": "4.0.4-ynby.0",
3
+ "version": "4.0.5-alpha.0",
4
4
  "private": false,
5
5
  "main": "lib/index.min.js",
6
6
  "typings": "types/index.d.ts",
@@ -1,9 +1,8 @@
1
- import { User } from 'authing-js-sdk';
2
1
  import { CompleteInfoRequest, RegisterCompleteInfoInitData } from './interface';
3
2
  export declare enum CompleteInfoAuthFlowAction {
4
3
  Complete = "complete-completion",
5
4
  Skip = "skip-completion"
6
5
  }
7
6
  export declare const authFlow: (action: CompleteInfoAuthFlowAction, data?: CompleteInfoRequest | undefined) => Promise<import("../_utils/http").AuthingGuardResponse<any>>;
8
- export declare const registerSkipMethod: (fnName: RegisterCompleteInfoInitData['businessRequestName'], content: any) => Promise<import("../_utils/http").AuthingGuardResponse<any>> | undefined;
9
- export declare const registerRequest: (action: CompleteInfoAuthFlowAction, registerFnName: RegisterCompleteInfoInitData['businessRequestName'], registerContent: any, registerProfile?: any) => Promise<User | import("../_utils/http").AuthingGuardResponse<any> | undefined>;
7
+ export declare const registerSkipMethod: (fnName: RegisterCompleteInfoInitData['businessRequestName'], content: any) => Promise<import("../_utils/http").AuthingGuardResponse<any>>;
8
+ export declare const registerRequest: (action: CompleteInfoAuthFlowAction, registerFnName: RegisterCompleteInfoInitData['businessRequestName'], registerContent: any, registerProfile?: any) => Promise<import("../_utils/http").AuthingGuardResponse<any> | undefined>;
@@ -2,6 +2,12 @@ import { IG2Config, IG2Events, IG2FCProps, IG2FCViewProps } from '../Type';
2
2
  import { AuthenticationClient, SocialConnectionProvider, User } from 'authing-js-sdk';
3
3
  import { QrCodeAuthenticationClient } from 'authing-js-sdk/build/main/lib/authentication/QrCodeAuthenticationClient';
4
4
  import { Agreement, LoginMethods, PasswordLoginMethods } from '../Type/application';
5
+ export declare enum ConnectionType {
6
+ PASSWORD = "PASSWORD",
7
+ PASSCODE = "PASSCODE",
8
+ LDAP = "LDAP",
9
+ AD = "AD"
10
+ }
5
11
  export interface LoginConfig extends IG2Config {
6
12
  autoRegister?: boolean;
7
13
  disableResetPwd?: boolean;
@@ -7,7 +7,7 @@ import { CodeStatus, UiQrProps } from './UiQrCode';
7
7
  export declare type CodeStatusDescriptions = Partial<Record<Exclude<CodeStatus, 'loading'>, React.ReactNode | ((referQrCode?: () => void) => React.ReactNode)>>;
8
8
  export interface WorkQrCodeRef {
9
9
  referQrCode: () => Promise<{
10
- random: string;
10
+ qrcodeId: string;
11
11
  url: string;
12
12
  } | undefined>;
13
13
  }
@@ -15,7 +15,7 @@ interface WorkQrCodeProps extends Omit<UiQrProps, 'description' | 'status'> {
15
15
  /**
16
16
  * 二维码场景
17
17
  */
18
- scene: 'WXAPP_AUTH' | 'APP_AUTH' | 'WECHATMP_AUTH' | 'LANDRAY_AUTH';
18
+ scene: 'WECHAT_OFFICIAL_ACCOUNT' | 'MOBILE_APP' | 'WECHAT_MINIPROGRAM';
19
19
  /**
20
20
  * 不同状态请求文字
21
21
  */
@@ -11,7 +11,7 @@ export interface QrCodeResponse {
11
11
  /**
12
12
  * 返回的随机值
13
13
  */
14
- random: number;
14
+ qrcodeId: number;
15
15
  /**
16
16
  * 返回的用户信息
17
17
  */
@@ -30,7 +30,7 @@ export interface QrCodeResponse {
30
30
  */
31
31
  interface QrCodeRequest {
32
32
  genCodeRequest?: () => Promise<AuthingGuardResponse<{
33
- random: string;
33
+ qrcodeId: string;
34
34
  url: string;
35
35
  }>>;
36
36
  /**
@@ -16,7 +16,7 @@ export declare type RootState = {
16
16
  /**
17
17
  * 二维码随机值
18
18
  */
19
- random?: string;
19
+ qrcodeId?: string;
20
20
  };
21
21
  /**
22
22
  * QrCode 准备阶段 Hook
@@ -1,5 +1,5 @@
1
1
  import { FC } from 'react';
2
- import { SceneType } from 'authing-js-sdk';
2
+ import { SceneType } from '../_utils/types';
3
3
  import './style.less';
4
4
  import { InputProps } from 'antd/lib/input';
5
5
  export interface SendCodeByPhoneProps extends InputProps {
@@ -7,8 +7,7 @@ export declare enum LoginMethods {
7
7
  PhoneCode = "phone-code",
8
8
  WxMinQr = "wechat-miniprogram-qrcode",
9
9
  AD = "ad",
10
- WechatMpQrcode = "wechatmp-qrcode",
11
- Landray = "landray"
10
+ WechatMpQrcode = "wechatmp-qrcode"
12
11
  }
13
12
  export declare enum OIDCConnectionMode {
14
13
  FRONT_CHANNEL = "FRONT_CHANNEL",
@@ -69,16 +69,12 @@ export interface GuardPageConfig {
69
69
  };
70
70
  }
71
71
  export declare enum EmailScene {
72
- WELCOME_EMAIL = "WELCOME_EMAIL",
73
- FIRST_CREATED_USER = "FIRST_CREATED_USER",
74
- REGISTER_VERIFY_CODE = "REGISTER_VERIFY_CODE",
75
- LOGIN_VERIFY_CODE = "LOGIN_VERIFY_CODE",
76
- MFA_VERIFY_CODE = "MFA_VERIFY_CODE",
77
- INFORMATION_COMPLETION_VERIFY_CODE = "INFORMATION_COMPLETION_VERIFY_CODE",
78
- FIRST_EMAIL_LOGIN_VERIFY = "FIRST_EMAIL_LOGIN_VERIFY",
79
- CONSOLE_CONDUCTED_VERIFY = "CONSOLE_CONDUCTED_VERIFY",
80
- RESET_PASSWORD_VERIFY_CODE = "RESET_PASSWORD_VERIFY_CODE",
81
- EMAIL_BIND_VERIFY_CODE = "EMAIL_BIND_VERIFY_CODE",
82
- EMAIL_UNBIND_VERIFY_CODE = "EMAIL_UNBIND_VERIFY_CODE",
83
- SELF_UNLOCKING_VERIFY_CODE = "SELF_UNLOCKING_VERIFY_CODE"
72
+ REGISTER_VERIFY_CODE = "CHANNEL_REGISTER",
73
+ LOGIN_VERIFY_CODE = "CHANNEL_LOGIN",
74
+ MFA_VERIFY_CODE = "CHANNEL_VERIFY_MFA",
75
+ INFORMATION_COMPLETION_VERIFY_CODE = "CHANNEL_COMPLETE_EMAIL",
76
+ RESET_PASSWORD_VERIFY_CODE = "CHANNEL_RESET_PASSWORD",
77
+ EMAIL_BIND_VERIFY_CODE = "CHANNEL_BIND_EMAIL",
78
+ EMAIL_UNBIND_VERIFY_CODE = "CHANNEL_UNBIND_EMAIL",
79
+ SELF_UNLOCKING_VERIFY_CODE = "CHANNEL_UNLOCK_ACCOUNT"
84
80
  }
@@ -2,7 +2,7 @@
2
2
  import { GuardComponentConfig, GuardLocalConfig } from '../../Guard/config';
3
3
  import { GuardHttp } from '../guardHttp';
4
4
  import { GuardPageConfig } from '../../Type';
5
- import { ApplicationConfig, LoginMethods, RegisterMethods } from '../../Type/application';
5
+ import { ApplicationConfig, RegisterMethods } from '../../Type/application';
6
6
  export declare const getPublicConfig: (appId: string) => ApplicationConfig;
7
7
  export declare const setPublicConfig: (appId: string, config: ApplicationConfig) => ApplicationConfig;
8
8
  export declare const useMergeDefaultConfig: (defaultConfig: GuardLocalConfig, config?: GuardComponentConfig | undefined) => GuardLocalConfig | undefined;
@@ -38,8 +38,8 @@ export declare const useMergePublicConfig: (forceUpdate: number, appId?: string
38
38
  __unAuthFlow__?: boolean | undefined;
39
39
  autoRegister?: boolean | undefined;
40
40
  disableResetPwd?: boolean | undefined;
41
- defaultLoginMethod?: LoginMethods | undefined;
42
- loginMethods?: LoginMethods[] | undefined;
41
+ defaultLoginMethod?: import("../../Type").LoginMethods | undefined;
42
+ loginMethods?: import("../../Type").LoginMethods[] | undefined;
43
43
  passwordLoginMethods?: import("../../Type").PasswordLoginMethods[] | undefined;
44
44
  socialConnections?: import("authing-js-sdk").SocialConnectionProvider[] | undefined;
45
45
  socialConnectionsBtnShape?: "default" | "button" | "icon" | undefined;
@@ -43,6 +43,7 @@ export declare const getUserRegisterParams: (params?: string[] | undefined) => {
43
43
  key: string;
44
44
  value: string | string[] | qs.ParsedQs | qs.ParsedQs[] | undefined;
45
45
  }[];
46
+ export declare const getUserRegisterParam: (params: string) => any;
46
47
  export declare const isWeChatBrowser: () => boolean | null;
47
48
  export declare const isLarkBrowser: () => boolean | null;
48
49
  export declare const isQtWebEngine: () => boolean | null;
@@ -0,0 +1,13 @@
1
+ export declare enum SceneType {
2
+ SCENE_TYPE_LOGIN = "CHANNEL_LOGIN",
3
+ SCENE_TYPE_REGISTER = "CHANNEL_REGISTER",
4
+ SCENE_TYPE_RESET = "CHANNEL_RESET_PASSWORD",
5
+ SCENE_TYPE_BIND = "CHANNEL_BIND_PHONE",
6
+ SCENE_TYPE_UNBIND = "CHANNEL_UNBIND_PHONE",
7
+ SCENE_TYPE_MFA_BIND = "CHANNEL_BIND_MFA",
8
+ SCENE_TYPE_MFA_VERIFY = "CHANNEL_VERIFY_MFA",
9
+ SCENE_TYPE_MFA_UNBIND = "CHANNEL_UNBIND_MFA",
10
+ SCENE_TYPE_COMPLETE_PHONE = "CHANNEL_COMPLETE_PHONE",
11
+ CHANNEL_IDENTITY_VERIFICATION = "CHANNEL_IDENTITY_VERIFICATION",
12
+ CHANNEL_DELETE_ACCOUNT = "CHANNEL_DELETE_ACCOUNT"
13
+ }
@@ -1,2 +1,2 @@
1
- declare const _default: "4.0.4-ynby.0";
1
+ declare const _default: "4.0.5-alpha.0";
2
2
  export default _default;