@authing/guard-shim-react 4.5.11-alpha.3 → 4.5.11-alpha.5

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.
@@ -13,7 +13,7 @@ export declare const QR_CODE_WAY: LoginWay[];
13
13
  * 登录时所有支持的登录列表(前端定义列表)
14
14
  * 这里稍微有点乱 因为Login中的登录方式和这里的不匹配,暂时放在了一起
15
15
  */
16
- export declare type LoginWay = 'email' | 'phone' | 'password' | 'phone-code' | 'email-code' | 'social' | 'wechat-miniprogram-qrcode' | 'wechatmp-qrcode' | 'app-qrcode' | 'zjzwfw-qrcode' | 'ad' | 'ldap' | 'ldap-password' | 'ldap-email' | 'ldap-phone' | 'authing-otp-push';
16
+ export declare type LoginWay = 'email' | 'phone' | 'password' | 'phone-code' | 'email-code' | 'social' | 'wechat-miniprogram-qrcode' | 'wechatmp-qrcode' | 'app-qrcode' | 'ad' | 'ldap' | 'ldap-password' | 'ldap-email' | 'ldap-phone' | 'authing-otp-push';
17
17
  /**
18
18
  * when: 多账号页面跳转进入登录页面
19
19
  * 携带的回填数据信息
@@ -1,5 +1,5 @@
1
1
  import { React } from 'shim-react';
2
- import { GuardMFAInitData, MFAConfig } from '../interface';
2
+ import { GuardMFAInitData, MFAConfig, MFAType } from '../interface';
3
3
  export interface BindMFASmsProps {
4
4
  mfaToken: string;
5
5
  onBind: (phone: string) => void;
@@ -7,6 +7,7 @@ export interface BindMFASmsProps {
7
7
  areaCode: string;
8
8
  setAreaCode: (areaCode: string) => void;
9
9
  isInternationSms: boolean;
10
+ mfaConfigsMap: Map<MFAType, boolean>;
10
11
  }
11
12
  export declare const BindMFASms: React.FC<BindMFASmsProps>;
12
13
  export interface VerifyMFASmsProps {
@@ -25,4 +26,5 @@ export declare const MFASms: React.FC<{
25
26
  mfaLogin: any;
26
27
  config: MFAConfig;
27
28
  initData: GuardMFAInitData;
29
+ mfaConfigsMap: Map<MFAType, boolean>;
28
30
  }>;
@@ -48,5 +48,4 @@ export interface UiQrProps {
48
48
  onMaskContent?: (status: CodeStatus) => void;
49
49
  }
50
50
  declare const UiQrCode: React.NamedExoticComponent<UiQrProps>;
51
- declare const LinkQrcode: React.FC<UiQrProps>;
52
- export { UiQrCode, LinkQrcode };
51
+ export { UiQrCode };
@@ -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' | 'ZJ_AUTH';
18
+ scene: 'WXAPP_AUTH' | 'APP_AUTH' | 'WECHATMP_AUTH';
19
19
  /**
20
20
  * 不同状态请求文字
21
21
  */
@@ -38,7 +38,4 @@ interface WorkQrCodeProps extends Omit<UiQrProps, 'description' | 'status'> {
38
38
  qrCodeScanOptions?: any;
39
39
  }
40
40
  declare const WorkQrCode: React.ForwardRefExoticComponent<WorkQrCodeProps & React.RefAttributes<any>>;
41
- declare const WorkGeneQrCode: React.ForwardRefExoticComponent<WorkQrCodeProps & {
42
- authorizationUrl?: string | undefined;
43
- } & React.RefAttributes<any>>;
44
- export { WorkQrCode, WorkGeneQrCode };
41
+ export { WorkQrCode };
@@ -33,7 +33,6 @@ interface QrCodeRequest {
33
33
  random: string;
34
34
  url: string;
35
35
  }>>;
36
- getAuthUrlRequest?: () => Promise<any>;
37
36
  /**
38
37
  * 未扫码下的请求方法
39
38
  */
@@ -17,14 +17,6 @@ export declare type RootState = {
17
17
  * 二维码随机值
18
18
  */
19
19
  random?: string;
20
- /**
21
- * 用于与浙里办交换的认证码
22
- */
23
- authCode?: string;
24
- /**
25
- * 浙里办的认证地址
26
- */
27
- authUrl?: string;
28
20
  };
29
21
  /**
30
22
  * QrCode 准备阶段 Hook
@@ -1,11 +1,7 @@
1
- import { UiQrCode, LinkQrcode } from './UiQrCode';
2
- import { WorkQrCode, WorkGeneQrCode } from './WorkQrCode';
1
+ import { UiQrCode } from './UiQrCode';
2
+ import { WorkQrCode } from './WorkQrCode';
3
3
  declare type IQrCode = typeof WorkQrCode & {
4
4
  UI: typeof UiQrCode;
5
5
  };
6
- declare type IGeneQrCode = typeof WorkGeneQrCode & {
7
- UI: typeof LinkQrcode;
8
- };
9
6
  declare const QrCode: IQrCode;
10
- declare const GeneQrcode: IGeneQrCode;
11
- export { QrCode, GeneQrcode };
7
+ export { QrCode };
@@ -1,4 +1,5 @@
1
1
  export declare type Lang = 'zh-CN' | 'en-US' | 'zh-TW' | 'ja-JP';
2
+ import { MFAType } from 'src/MFA/interface';
2
3
  import { PasswordStrength } from '../_utils';
3
4
  export * from 'authing-js-sdk';
4
5
  export declare enum LoginMethods {
@@ -13,8 +14,7 @@ export declare enum LoginMethods {
13
14
  AuthingOtpPush = "authing-otp-push",
14
15
  WechatworkCorpQrconnect = "wechatwork-corp-qrconnect",
15
16
  DingTalkQrcode = "dingtalk-qrcode",
16
- Passkey = "passkey",
17
- ZJZWFWQrcode = "zjzwfw-qrcode"
17
+ Passkey = "passkey"
18
18
  }
19
19
  export declare enum OIDCConnectionMode {
20
20
  FRONT_CHANNEL = "FRONT_CHANNEL",
@@ -126,7 +126,6 @@ export interface QrCodeItem {
126
126
  redirectUrl: string;
127
127
  identifier: string;
128
128
  clientId?: string;
129
- authorizationUrl?: string;
130
129
  };
131
130
  }
132
131
  export declare type QrcodeTabsSettings = Record<LoginMethods, Array<QrCodeItem>>;
@@ -358,4 +357,8 @@ export interface ApplicationConfig {
358
357
  defaultAppId: string;
359
358
  enableCreateTenant: boolean;
360
359
  enableJoinTenant: boolean;
360
+ mfaBindConfigs?: {
361
+ mfa: MFAType;
362
+ changeable: boolean;
363
+ }[];
361
364
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@authing/guard-shim-react",
3
- "version": "4.5.11-alpha.3",
3
+ "version": "4.5.11-alpha.5",
4
4
  "description": "Guard shim for react 16 / 17, only be used to internal",
5
5
  "types": "dist/typings/src/index.d.ts",
6
6
  "module": "dist/guard.min.js",
@@ -1,11 +0,0 @@
1
- import { StoreInstance } from '../../Guard/core/hooks/useMultipleAccounts';
2
- import { QrCodeItem } from '../..';
3
- interface LoginWithAppQrcodeProps {
4
- onLoginSuccess: any;
5
- canLoop: boolean;
6
- multipleInstance?: StoreInstance;
7
- qrConfig: QrCodeItem['QRConfig'];
8
- qrCodeScanOptions: any;
9
- }
10
- export declare const LoginWithZjQrcode: (props: LoginWithAppQrcodeProps) => JSX.Element | null;
11
- export {};