@authing/react-ui-components 3.1.30-beta.1 → 3.1.31-rc.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/lib/index.d.ts +54 -1226
- package/lib/index.min.css +2 -2
- package/lib/index.min.js +1 -1
- package/lib/index.min.js.LICENSE.txt +0 -25
- package/package.json +2 -4
package/lib/index.d.ts
CHANGED
|
@@ -1102,33 +1102,6 @@ declare module '@authing/react-ui-components/components/Back/index' {
|
|
|
1102
1102
|
}
|
|
1103
1103
|
export const BackCustom: React.FC<BackCustomProps>;
|
|
1104
1104
|
|
|
1105
|
-
}
|
|
1106
|
-
declare module '@authing/react-ui-components/components/BindTotp/api/constant' {
|
|
1107
|
-
export const mfaAuthenticatorUrl: () => string;
|
|
1108
|
-
export const mfaTotpAssociateUrl: () => string;
|
|
1109
|
-
|
|
1110
|
-
}
|
|
1111
|
-
declare module '@authing/react-ui-components/components/BindTotp/api/index' {
|
|
1112
|
-
import { AxiosRequestConfig } from 'axios';
|
|
1113
|
-
export { authFlowByAxios } from 'service/api';
|
|
1114
|
-
/**
|
|
1115
|
-
* 验证是否已登陆
|
|
1116
|
-
* @param data
|
|
1117
|
-
* @param config
|
|
1118
|
-
*/
|
|
1119
|
-
export const mfaTotpAuthenticatorByAxios: (params: {
|
|
1120
|
-
source: string;
|
|
1121
|
-
}, config: AxiosRequestConfig) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1122
|
-
/**
|
|
1123
|
-
* 已登陆 totp 拉取二维码、Secret 信息
|
|
1124
|
-
* @param data
|
|
1125
|
-
* @param config
|
|
1126
|
-
* @returns
|
|
1127
|
-
*/
|
|
1128
|
-
export const mfaTotpAssociateByAxios: (data: {
|
|
1129
|
-
source: string;
|
|
1130
|
-
}, config: AxiosRequestConfig) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1131
|
-
|
|
1132
1105
|
}
|
|
1133
1106
|
declare module '@authing/react-ui-components/components/BindTotp/businessRequest' {
|
|
1134
1107
|
export enum BindTotpBusinessAction {
|
|
@@ -1191,15 +1164,8 @@ declare module '@authing/react-ui-components/components/ChangeLanguage/index' {
|
|
|
1191
1164
|
/// <reference types="react" />
|
|
1192
1165
|
export const ChangeLanguage: (props: any) => JSX.Element | null;
|
|
1193
1166
|
|
|
1194
|
-
}
|
|
1195
|
-
declare module '@authing/react-ui-components/components/ChangePassword/api/index' {
|
|
1196
|
-
import { registerEmailCodeByAxios } from '@authing/react-ui-components/components/Register/api/index';
|
|
1197
|
-
import { authFlowByAxios } from 'service/api';
|
|
1198
|
-
export { authFlowByAxios, registerEmailCodeByAxios };
|
|
1199
|
-
|
|
1200
1167
|
}
|
|
1201
1168
|
declare module '@authing/react-ui-components/components/ChangePassword/businessRequest' {
|
|
1202
|
-
import { AxiosRequestConfig } from 'axios';
|
|
1203
1169
|
export enum ChangePasswordBusinessAction {
|
|
1204
1170
|
ResetPassword = "reset-password-first-time",
|
|
1205
1171
|
FirstLoginReset = "reset-password-forced",
|
|
@@ -1208,7 +1174,7 @@ declare module '@authing/react-ui-components/components/ChangePassword/businessR
|
|
|
1208
1174
|
export const authFlow: (action: ChangePasswordBusinessAction, content: {
|
|
1209
1175
|
password: string;
|
|
1210
1176
|
oldPassword?: string;
|
|
1211
|
-
}
|
|
1177
|
+
}) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1212
1178
|
|
|
1213
1179
|
}
|
|
1214
1180
|
declare module '@authing/react-ui-components/components/ChangePassword/core/PasswordNotSafeReset' {
|
|
@@ -1222,12 +1188,6 @@ declare module '@authing/react-ui-components/components/ChangePassword/core/Pass
|
|
|
1222
1188
|
}
|
|
1223
1189
|
declare module '@authing/react-ui-components/components/ChangePassword/core/completePassword' {
|
|
1224
1190
|
import React from 'react';
|
|
1225
|
-
/**
|
|
1226
|
-
* 注册补全密码
|
|
1227
|
-
* 进入流程:
|
|
1228
|
-
* 1. 控制台登陆方式 短信验证码 && 手机号密码
|
|
1229
|
-
* 2. 注册方式 短信验证码
|
|
1230
|
-
*/
|
|
1231
1191
|
export const CompletePassword: React.FC;
|
|
1232
1192
|
|
|
1233
1193
|
}
|
|
@@ -1256,63 +1216,23 @@ declare module '@authing/react-ui-components/components/ChangePassword/index' {
|
|
|
1256
1216
|
title: string;
|
|
1257
1217
|
explain: string;
|
|
1258
1218
|
}>;
|
|
1259
|
-
/**
|
|
1260
|
-
* 首次登陆重制密码
|
|
1261
|
-
* @returns
|
|
1262
|
-
*/
|
|
1263
1219
|
export const GuardFirstLoginPasswordResetView: React.FC;
|
|
1264
1220
|
export const GuardPasswordNotSafeResetView: React.FC;
|
|
1265
1221
|
export const GuardForcedPasswordResetView: React.FC;
|
|
1266
|
-
/**
|
|
1267
|
-
* 提示修改密码
|
|
1268
|
-
* @returns
|
|
1269
|
-
*/
|
|
1270
1222
|
export const GuardNoticePasswordResetView: React.FC;
|
|
1271
|
-
/**
|
|
1272
|
-
* 注册密码补全
|
|
1273
|
-
* @returns
|
|
1274
|
-
*/
|
|
1275
1223
|
export const GuardRegisterCompletePasswordView: React.FC;
|
|
1276
1224
|
|
|
1277
|
-
}
|
|
1278
|
-
declare module '@authing/react-ui-components/components/CompleteInfo/api/constant' {
|
|
1279
|
-
export const getCompletionMetaDataUrl: () => string;
|
|
1280
|
-
|
|
1281
|
-
}
|
|
1282
|
-
declare module '@authing/react-ui-components/components/CompleteInfo/api/index' {
|
|
1283
|
-
import { authFlowByAxios, getCountryLists, validateAccountByAxios, validateEmailCodeByAxios, validatePhoneCodeByAxios } from 'service/api';
|
|
1284
|
-
import { registerEmailCodeByAxios } from '@authing/react-ui-components/components/Register/api/index';
|
|
1285
|
-
import { getRegisterMetadata } from '@authing/react-ui-components/components/CompleteInfo/api/request';
|
|
1286
|
-
export { registerEmailCodeByAxios, authFlowByAxios, getCountryLists, validateAccountByAxios, validateEmailCodeByAxios, validatePhoneCodeByAxios, getRegisterMetadata, };
|
|
1287
|
-
|
|
1288
|
-
}
|
|
1289
|
-
declare module '@authing/react-ui-components/components/CompleteInfo/api/request' {
|
|
1290
|
-
import { AxiosRequestConfig } from 'axios';
|
|
1291
|
-
/**
|
|
1292
|
-
* 获取注册信息补全元数据
|
|
1293
|
-
* @param params
|
|
1294
|
-
* @param config
|
|
1295
|
-
* @returns
|
|
1296
|
-
*/
|
|
1297
|
-
export const getRegisterMetadata: (params?: any, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1298
|
-
|
|
1299
1225
|
}
|
|
1300
1226
|
declare module '@authing/react-ui-components/components/CompleteInfo/businessRequest' {
|
|
1301
|
-
import {
|
|
1227
|
+
import { User } from 'authing-js-sdk';
|
|
1302
1228
|
import { CompleteInfoRequest, RegisterCompleteInfoInitData } from '@authing/react-ui-components/components/CompleteInfo/interface';
|
|
1303
1229
|
export enum CompleteInfoAuthFlowAction {
|
|
1304
1230
|
Complete = "complete-completion",
|
|
1305
1231
|
Skip = "skip-completion"
|
|
1306
1232
|
}
|
|
1307
|
-
export const authFlow: (action: CompleteInfoAuthFlowAction, data?: CompleteInfoRequest | undefined
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
* @param fnName
|
|
1311
|
-
* @param content
|
|
1312
|
-
* @returns
|
|
1313
|
-
*/
|
|
1314
|
-
export const registerSkipMethod: (fnName: RegisterCompleteInfoInitData['businessRequestName'], content: any) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>> | Promise<import("authing-js-sdk").User> | undefined;
|
|
1315
|
-
export const registerRequest: (action: CompleteInfoAuthFlowAction, registerFnName: RegisterCompleteInfoInitData['businessRequestName'], registerContent: any, registerProfile?: any) => Promise<import("authing-js-sdk").User | import("../_utils/http").AuthingGuardResponse<any> | undefined>;
|
|
1233
|
+
export const authFlow: (action: CompleteInfoAuthFlowAction, data?: CompleteInfoRequest | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1234
|
+
export const registerSkipMethod: (fnName: RegisterCompleteInfoInitData['businessRequestName'], content: any) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>> | Promise<User> | undefined;
|
|
1235
|
+
export const registerRequest: (action: CompleteInfoAuthFlowAction, registerFnName: RegisterCompleteInfoInitData['businessRequestName'], registerContent: any, registerProfile?: any) => Promise<User | import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any> | undefined>;
|
|
1316
1236
|
|
|
1317
1237
|
}
|
|
1318
1238
|
declare module '@authing/react-ui-components/components/CompleteInfo/core/completeInfo' {
|
|
@@ -1326,11 +1246,6 @@ declare module '@authing/react-ui-components/components/CompleteInfo/core/comple
|
|
|
1326
1246
|
key: string;
|
|
1327
1247
|
options: any;
|
|
1328
1248
|
}
|
|
1329
|
-
/**
|
|
1330
|
-
* 信息补全
|
|
1331
|
-
* @param props
|
|
1332
|
-
* @returns
|
|
1333
|
-
*/
|
|
1334
1249
|
export const CompleteInfo: React.FC<CompleteInfoProps>;
|
|
1335
1250
|
|
|
1336
1251
|
}
|
|
@@ -1339,23 +1254,12 @@ declare module '@authing/react-ui-components/components/CompleteInfo/index' {
|
|
|
1339
1254
|
import { CompleteInfoMetaData, CompleteInfoRequest } from '@authing/react-ui-components/components/CompleteInfo/interface';
|
|
1340
1255
|
import './styles.less';
|
|
1341
1256
|
import { CompleteInfoAuthFlowAction } from '@authing/react-ui-components/components/CompleteInfo/businessRequest';
|
|
1342
|
-
/**
|
|
1343
|
-
* 登录时信息补全
|
|
1344
|
-
* @param param0
|
|
1345
|
-
* @returns
|
|
1346
|
-
*/
|
|
1347
1257
|
export const GuardCompleteInfo: React.FC<{
|
|
1348
1258
|
metaData: CompleteInfoMetaData[];
|
|
1349
1259
|
skipComplateFileds: boolean;
|
|
1350
1260
|
businessRequest: (action: CompleteInfoAuthFlowAction, data?: CompleteInfoRequest) => Promise<void>;
|
|
1351
1261
|
}>;
|
|
1352
|
-
/**
|
|
1353
|
-
* 登录信息补全
|
|
1354
|
-
*/
|
|
1355
1262
|
export const GuardLoginCompleteInfoView: React.FC;
|
|
1356
|
-
/**
|
|
1357
|
-
* 注册信息补全
|
|
1358
|
-
*/
|
|
1359
1263
|
export const GuardRegisterCompleteInfoView: React.FC;
|
|
1360
1264
|
|
|
1361
1265
|
}
|
|
@@ -1528,41 +1432,6 @@ declare module '@authing/react-ui-components/components/Error/interface' {
|
|
|
1528
1432
|
export interface GuardErrorViewProps extends GuardErrorProps {
|
|
1529
1433
|
}
|
|
1530
1434
|
|
|
1531
|
-
}
|
|
1532
|
-
declare module '@authing/react-ui-components/components/ForgetPassword/api/constant' {
|
|
1533
|
-
export const resetPasswordUrl: () => string;
|
|
1534
|
-
|
|
1535
|
-
}
|
|
1536
|
-
declare module '@authing/react-ui-components/components/ForgetPassword/api/index' {
|
|
1537
|
-
export * from '@authing/react-ui-components/components/ForgetPassword/api/request';
|
|
1538
|
-
|
|
1539
|
-
}
|
|
1540
|
-
declare module '@authing/react-ui-components/components/ForgetPassword/api/request' {
|
|
1541
|
-
import { AxiosRequestConfig } from 'axios';
|
|
1542
|
-
/**
|
|
1543
|
-
* 忘记密码-重置密码 邮箱
|
|
1544
|
-
* @param data
|
|
1545
|
-
* @param config
|
|
1546
|
-
* @returns
|
|
1547
|
-
*/
|
|
1548
|
-
export const resetPwdEmailByAxios: (data: {
|
|
1549
|
-
email: string;
|
|
1550
|
-
code: string;
|
|
1551
|
-
newPassword: string;
|
|
1552
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1553
|
-
/**
|
|
1554
|
-
* 忘记密码-重置密码 手机号
|
|
1555
|
-
* @param data
|
|
1556
|
-
* @param config
|
|
1557
|
-
* @returns
|
|
1558
|
-
*/
|
|
1559
|
-
export const restPwdPhoneByAxios: (data: {
|
|
1560
|
-
phone: string;
|
|
1561
|
-
code: string;
|
|
1562
|
-
newPassword: string;
|
|
1563
|
-
phoneCountryCode?: string;
|
|
1564
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1565
|
-
|
|
1566
1435
|
}
|
|
1567
1436
|
declare module '@authing/react-ui-components/components/ForgetPassword/core/resetPassword' {
|
|
1568
1437
|
/// <reference types="react" />
|
|
@@ -1582,9 +1451,6 @@ declare module '@authing/react-ui-components/components/ForgetPassword/core/rese
|
|
|
1582
1451
|
}
|
|
1583
1452
|
declare module '@authing/react-ui-components/components/ForgetPassword/index' {
|
|
1584
1453
|
import React from 'react';
|
|
1585
|
-
/**
|
|
1586
|
-
* 忘记密码
|
|
1587
|
-
*/
|
|
1588
1454
|
export const GuardForgetPassword: React.FC;
|
|
1589
1455
|
|
|
1590
1456
|
}
|
|
@@ -1662,27 +1528,6 @@ declare module '@authing/react-ui-components/components/Guard/GuardModule/stateM
|
|
|
1662
1528
|
export const getGuardStateMachine: () => GuardStateMachine;
|
|
1663
1529
|
export const useGuardStateMachine: () => GuardStateMachine;
|
|
1664
1530
|
|
|
1665
|
-
}
|
|
1666
|
-
declare module '@authing/react-ui-components/components/Guard/api/constant' {
|
|
1667
|
-
export const publishConfig: (appId: string) => string;
|
|
1668
|
-
export const pageConfig: (appId: string) => string;
|
|
1669
|
-
|
|
1670
|
-
}
|
|
1671
|
-
declare module '@authing/react-ui-components/components/Guard/api/index' {
|
|
1672
|
-
import { AxiosRequestConfig } from 'axios';
|
|
1673
|
-
/**
|
|
1674
|
-
* 获取应用配置信息
|
|
1675
|
-
* @param appId 当前应用配置信息
|
|
1676
|
-
* @returns
|
|
1677
|
-
*/
|
|
1678
|
-
export const getPublishConfigByAxios: <T>(appId: string, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
1679
|
-
/**
|
|
1680
|
-
* 获取页面配置
|
|
1681
|
-
* @param appId 当前应用配置信息
|
|
1682
|
-
* @returns
|
|
1683
|
-
*/
|
|
1684
|
-
export const getPageConfigByAxios: <T>(appId: string, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
1685
|
-
|
|
1686
1531
|
}
|
|
1687
1532
|
declare module '@authing/react-ui-components/components/Guard/authClient' {
|
|
1688
1533
|
import { AuthenticationClient } from 'authing-js-sdk';
|
|
@@ -1730,107 +1575,6 @@ declare module '@authing/react-ui-components/components/Guard/config' {
|
|
|
1730
1575
|
}
|
|
1731
1576
|
export const getDefaultGuardLocalConfig: () => GuardLocalConfig;
|
|
1732
1577
|
|
|
1733
|
-
}
|
|
1734
|
-
declare module '@authing/react-ui-components/components/Guard/core/componentsMapping' {
|
|
1735
|
-
import React from 'react';
|
|
1736
|
-
import { GuardModuleType } from '@authing/react-ui-components/components/Guard/module';
|
|
1737
|
-
/**
|
|
1738
|
-
* 组件映射表
|
|
1739
|
-
* TODO: 斟酌下是否和上层 module.ts 放在一起的单个文件夹中 感觉可放可不放
|
|
1740
|
-
*/
|
|
1741
|
-
const ComponentsMapping: Record<GuardModuleType, (key: string) => React.ReactNode>;
|
|
1742
|
-
export default ComponentsMapping;
|
|
1743
|
-
|
|
1744
|
-
}
|
|
1745
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useBusinessRequest' {
|
|
1746
|
-
import { AuthenticationClient } from 'authing-js-sdk';
|
|
1747
|
-
import { GuardLocalConfig } from 'components/Guard/config';
|
|
1748
|
-
import { GuardEvents } from 'components/Guard/event';
|
|
1749
|
-
import { GuardHttp } from 'components/_utils/guardHttp';
|
|
1750
|
-
export default function useBusinessRequestByAxios(appId: string | undefined, options: {
|
|
1751
|
-
events?: GuardEvents;
|
|
1752
|
-
tenantId?: string;
|
|
1753
|
-
sdkClient?: AuthenticationClient;
|
|
1754
|
-
defaultMergedConfig?: GuardLocalConfig;
|
|
1755
|
-
httpClient?: GuardHttp;
|
|
1756
|
-
finallyConfig?: any;
|
|
1757
|
-
}): {
|
|
1758
|
-
axiosClient: boolean | undefined;
|
|
1759
|
-
};
|
|
1760
|
-
|
|
1761
|
-
}
|
|
1762
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useCss' {
|
|
1763
|
-
/**
|
|
1764
|
-
* 自定义 CSS 相关,finallyConfig 类型待补充
|
|
1765
|
-
* @param finallyConfig
|
|
1766
|
-
*/
|
|
1767
|
-
export default function useCss(finallyConfig: any): void;
|
|
1768
|
-
|
|
1769
|
-
}
|
|
1770
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useEvents' {
|
|
1771
|
-
/// <reference types="react" />
|
|
1772
|
-
import { GuardEvents } from '@authing/react-ui-components/components/Guard/event';
|
|
1773
|
-
import { GuardProps } from '@authing/react-ui-components/components/Guard/Guard';
|
|
1774
|
-
/**
|
|
1775
|
-
* 初始化事件
|
|
1776
|
-
* @param guardProps
|
|
1777
|
-
* @param openEventsMapping
|
|
1778
|
-
* @returns
|
|
1779
|
-
*/
|
|
1780
|
-
export default function useEvents(guardProps: GuardProps, openEventsMapping?: boolean): {
|
|
1781
|
-
events: GuardEvents | undefined;
|
|
1782
|
-
setEvents: import("react").Dispatch<import("react").SetStateAction<GuardEvents | undefined>>;
|
|
1783
|
-
initEvents: () => void;
|
|
1784
|
-
};
|
|
1785
|
-
|
|
1786
|
-
}
|
|
1787
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useFDA' {
|
|
1788
|
-
/// <reference types="react" />
|
|
1789
|
-
import { GuardEvents } from '@authing/react-ui-components/components/Guard/event';
|
|
1790
|
-
import { GuardStateMachine, ModuleState } from '@authing/react-ui-components/components/Guard/GuardModule/stateMachine';
|
|
1791
|
-
import { GuardModuleType } from '@authing/react-ui-components/components/Guard/module';
|
|
1792
|
-
import { ChangeModuleCore } from '@authing/react-ui-components/components/Guard/core/hooks/useModule';
|
|
1793
|
-
/**
|
|
1794
|
-
* 初始化 FDA ,后续 Guard 渲染全部按照 FDA API 执行
|
|
1795
|
-
* @param onChangeModule FDA 内部更新组件核心方法
|
|
1796
|
-
* @param initState 初始化状态
|
|
1797
|
-
* @returns { guardStateMachine,setGuardStateMachine }
|
|
1798
|
-
*/
|
|
1799
|
-
export default function useFDA(onChangeModule: ChangeModuleCore, initState: ModuleState, events?: GuardEvents, authFlow?: boolean): {
|
|
1800
|
-
isAuthFlow: boolean;
|
|
1801
|
-
guardStateMachine: GuardStateMachine | undefined;
|
|
1802
|
-
setGuardStateMachine: import("react").Dispatch<import("react").SetStateAction<GuardStateMachine | undefined>>;
|
|
1803
|
-
moduleEvents: {
|
|
1804
|
-
changeModule: (moduleName: GuardModuleType, initData?: any) => Promise<void>;
|
|
1805
|
-
backModule: () => void;
|
|
1806
|
-
} | undefined;
|
|
1807
|
-
};
|
|
1808
|
-
|
|
1809
|
-
}
|
|
1810
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useI18n' {
|
|
1811
|
-
import { GuardLocalConfig } from 'components/Guard/config';
|
|
1812
|
-
const useI18i: (config?: Partial<GuardLocalConfig> | undefined) => void;
|
|
1813
|
-
export { useI18i };
|
|
1814
|
-
|
|
1815
|
-
}
|
|
1816
|
-
declare module '@authing/react-ui-components/components/Guard/core/hooks/useModule' {
|
|
1817
|
-
import { GuardEvents } from '@authing/react-ui-components/components/Guard/event';
|
|
1818
|
-
import { ModuleState } from '@authing/react-ui-components/components/Guard/GuardModule/stateMachine';
|
|
1819
|
-
import { GuardModuleType } from '@authing/react-ui-components/components/Guard/module';
|
|
1820
|
-
export interface ChangeModuleCore {
|
|
1821
|
-
(type: GuardModuleType, initData?: any): Promise<void>;
|
|
1822
|
-
}
|
|
1823
|
-
/**
|
|
1824
|
-
* Guard 组件渲染状态
|
|
1825
|
-
* @param initializeState 初始化数据
|
|
1826
|
-
* @param events Guard 事件对象
|
|
1827
|
-
* @returns moduleState 组件当前渲染状态,onChangeModule 切换状态方法
|
|
1828
|
-
*/
|
|
1829
|
-
export default function useModule(initializeState: ModuleState, events?: GuardEvents): {
|
|
1830
|
-
moduleState: ModuleState;
|
|
1831
|
-
onChangeModule: ChangeModuleCore;
|
|
1832
|
-
};
|
|
1833
|
-
|
|
1834
1578
|
}
|
|
1835
1579
|
declare module '@authing/react-ui-components/components/Guard/core/index' {
|
|
1836
1580
|
/// <reference types="react" />
|
|
@@ -1843,7 +1587,7 @@ declare module '@authing/react-ui-components/components/Guard/core/index' {
|
|
|
1843
1587
|
export const GuardCore: (props: GuardCoreProps) => JSX.Element;
|
|
1844
1588
|
|
|
1845
1589
|
}
|
|
1846
|
-
declare module '@authing/react-ui-components/components/Guard/core/renderContext
|
|
1590
|
+
declare module '@authing/react-ui-components/components/Guard/core/renderContext' {
|
|
1847
1591
|
import { GuardProps } from '@authing/react-ui-components/components/Guard/index';
|
|
1848
1592
|
import React from 'react';
|
|
1849
1593
|
import { ModuleState } from '@authing/react-ui-components/components/Guard/GuardModule/stateMachine';
|
|
@@ -2033,21 +1777,8 @@ declare module '@authing/react-ui-components/components/IconFont/useGuardIconfon
|
|
|
2033
1777
|
declare module '@authing/react-ui-components/components/IdentityBinding/IdentityBinding' {
|
|
2034
1778
|
import React from 'react';
|
|
2035
1779
|
import './styles.less';
|
|
2036
|
-
/**
|
|
2037
|
-
* 身份源绑定 第三方登陆时
|
|
2038
|
-
* 需要身份源绑定相关 Authing 账号
|
|
2039
|
-
* @returns
|
|
2040
|
-
*/
|
|
2041
1780
|
export const GuardIdentityBindingView: React.FC;
|
|
2042
1781
|
|
|
2043
|
-
}
|
|
2044
|
-
declare module '@authing/react-ui-components/components/IdentityBinding/api/index' {
|
|
2045
|
-
export * from '@authing/react-ui-components/components/IdentityBinding/api/request';
|
|
2046
|
-
|
|
2047
|
-
}
|
|
2048
|
-
declare module '@authing/react-ui-components/components/IdentityBinding/api/request' {
|
|
2049
|
-
export { authFlowByAxios } from 'service/api';
|
|
2050
|
-
|
|
2051
1782
|
}
|
|
2052
1783
|
declare module '@authing/react-ui-components/components/IdentityBinding/businessRequest' {
|
|
2053
1784
|
export enum IdentityBindingBusinessAction {
|
|
@@ -2075,10 +1806,13 @@ declare module '@authing/react-ui-components/components/IdentityBinding/business
|
|
|
2075
1806
|
BindByPhoneCode = "bind-identity-by-phone-code",
|
|
2076
1807
|
BindByEmailCode = "bind-identity-by-email-code"
|
|
2077
1808
|
}
|
|
1809
|
+
export const PhoneCode: (params: PhoneCodeParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1810
|
+
export const EmailCode: (params: EmailCodeParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1811
|
+
export const Password: (params: PasswordParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2078
1812
|
export const useIdentityBindingBusinessRequest: () => {
|
|
2079
|
-
"phone-code": (
|
|
2080
|
-
"emial-code": (
|
|
2081
|
-
password: (
|
|
1813
|
+
"phone-code": (params: PhoneCodeParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1814
|
+
"emial-code": (params: EmailCodeParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
1815
|
+
password: (params: PasswordParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2082
1816
|
};
|
|
2083
1817
|
|
|
2084
1818
|
}
|
|
@@ -2122,18 +1856,6 @@ declare module '@authing/react-ui-components/components/IdentityBindingAsk/Ident
|
|
|
2122
1856
|
import './styles.less';
|
|
2123
1857
|
export const GuardIdentityBindingAskView: React.FC;
|
|
2124
1858
|
|
|
2125
|
-
}
|
|
2126
|
-
declare module '@authing/react-ui-components/components/IdentityBindingAsk/api/index' {
|
|
2127
|
-
import { AxiosRequestConfig } from 'axios';
|
|
2128
|
-
/**
|
|
2129
|
-
* 状态机
|
|
2130
|
-
* @param action
|
|
2131
|
-
* @param config
|
|
2132
|
-
* @returns
|
|
2133
|
-
*/
|
|
2134
|
-
const authFlow: (action: string, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2135
|
-
export { authFlow };
|
|
2136
|
-
|
|
2137
1859
|
}
|
|
2138
1860
|
declare module '@authing/react-ui-components/components/IdentityBindingAsk/index' {
|
|
2139
1861
|
export * from '@authing/react-ui-components/components/IdentityBindingAsk/IdentityBindingAsk';
|
|
@@ -2195,136 +1917,6 @@ declare module '@authing/react-ui-components/components/InputPassword/index' {
|
|
|
2195
1917
|
import React from 'react';
|
|
2196
1918
|
export const InputPassword: React.ForwardRefExoticComponent<PasswordProps & React.RefAttributes<React.RefObject<Input>>>;
|
|
2197
1919
|
|
|
2198
|
-
}
|
|
2199
|
-
declare module '@authing/react-ui-components/components/Login/api/constant' {
|
|
2200
|
-
export const loginUrlByPassword: (isAdWay: boolean) => "/api/v2/login/ad-all-in-one" | "/api/v2/login/account";
|
|
2201
|
-
export const loginUrlByPhoneCode: () => string;
|
|
2202
|
-
export const loginUrlByEmailCode: () => string;
|
|
2203
|
-
export const loginUrlByAD: () => string;
|
|
2204
|
-
export const loginUrlByLDAP: () => string;
|
|
2205
|
-
export const preLoginUrlByOIDC: () => string;
|
|
2206
|
-
|
|
2207
|
-
}
|
|
2208
|
-
declare module '@authing/react-ui-components/components/Login/api/index' {
|
|
2209
|
-
export * from '@authing/react-ui-components/components/Login/api/request';
|
|
2210
|
-
|
|
2211
|
-
}
|
|
2212
|
-
declare module '@authing/react-ui-components/components/Login/api/request' {
|
|
2213
|
-
import { AxiosRequestConfig } from 'axios';
|
|
2214
|
-
export interface LoginParams<T = any> {
|
|
2215
|
-
/**
|
|
2216
|
-
* 登陆自定义参数
|
|
2217
|
-
*/
|
|
2218
|
-
customData: T;
|
|
2219
|
-
/**
|
|
2220
|
-
* 是否自动注册
|
|
2221
|
-
*/
|
|
2222
|
-
autoRegister?: boolean;
|
|
2223
|
-
/**
|
|
2224
|
-
* 是否携带自定义数据
|
|
2225
|
-
*/
|
|
2226
|
-
withCustomData?: boolean;
|
|
2227
|
-
}
|
|
2228
|
-
/**
|
|
2229
|
-
* 密码登陆请求参数
|
|
2230
|
-
*/
|
|
2231
|
-
export interface LoginParamsWithPassword<T = any> extends LoginParams<T> {
|
|
2232
|
-
/**
|
|
2233
|
-
* 账号
|
|
2234
|
-
*/
|
|
2235
|
-
account: string;
|
|
2236
|
-
/**
|
|
2237
|
-
* 密码
|
|
2238
|
-
*/
|
|
2239
|
-
password: string;
|
|
2240
|
-
/**
|
|
2241
|
-
* 验证码
|
|
2242
|
-
*/
|
|
2243
|
-
captchaCode: string;
|
|
2244
|
-
}
|
|
2245
|
-
/**
|
|
2246
|
-
* 密码登陆
|
|
2247
|
-
*/
|
|
2248
|
-
export const loginRequestByAxios: <T>(data: LoginParams, way?: boolean, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
2249
|
-
/**
|
|
2250
|
-
* 手机登陆请求参数
|
|
2251
|
-
*/
|
|
2252
|
-
export interface LoginParamsWithPhone<T = any> extends LoginParams<T> {
|
|
2253
|
-
/**
|
|
2254
|
-
* 手机号
|
|
2255
|
-
*/
|
|
2256
|
-
phone: string;
|
|
2257
|
-
/**
|
|
2258
|
-
* 验证码
|
|
2259
|
-
*/
|
|
2260
|
-
code: string;
|
|
2261
|
-
/**
|
|
2262
|
-
* 手机前位数
|
|
2263
|
-
*/
|
|
2264
|
-
phoneCountryCode?: number;
|
|
2265
|
-
}
|
|
2266
|
-
/**
|
|
2267
|
-
* 手机验证码登陆
|
|
2268
|
-
* @param data
|
|
2269
|
-
* @returns
|
|
2270
|
-
*/
|
|
2271
|
-
export const mobileLoginByAxios: (data: LoginParamsWithPhone, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2272
|
-
/**
|
|
2273
|
-
* 手机登陆请求参数
|
|
2274
|
-
*/
|
|
2275
|
-
export interface LoginParamsWithEmail<T = any> extends LoginParams<T> {
|
|
2276
|
-
/**
|
|
2277
|
-
* 邮箱号
|
|
2278
|
-
*/
|
|
2279
|
-
email: string;
|
|
2280
|
-
/**
|
|
2281
|
-
* 验证码
|
|
2282
|
-
*/
|
|
2283
|
-
code: string;
|
|
2284
|
-
}
|
|
2285
|
-
/**
|
|
2286
|
-
* 邮箱登陆
|
|
2287
|
-
* @param data
|
|
2288
|
-
* @param config
|
|
2289
|
-
* @returns
|
|
2290
|
-
*/
|
|
2291
|
-
export const emailLoginByAxios: (data: LoginParamsWithEmail, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2292
|
-
/**
|
|
2293
|
-
* AD 登陆
|
|
2294
|
-
* @param data
|
|
2295
|
-
* @returns
|
|
2296
|
-
*/
|
|
2297
|
-
export const adLoginByAxios: (data: {
|
|
2298
|
-
username: string;
|
|
2299
|
-
password: string;
|
|
2300
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2301
|
-
/**
|
|
2302
|
-
* LDAP 登陆
|
|
2303
|
-
* @param data
|
|
2304
|
-
* @returns
|
|
2305
|
-
*/
|
|
2306
|
-
export const ldapLoginByAxios: (data: {
|
|
2307
|
-
username: string;
|
|
2308
|
-
password: string;
|
|
2309
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2310
|
-
interface PreOIDCParams {
|
|
2311
|
-
state: string;
|
|
2312
|
-
protocol: string;
|
|
2313
|
-
userPoolId: string;
|
|
2314
|
-
appId: string;
|
|
2315
|
-
referer: string;
|
|
2316
|
-
connection: {
|
|
2317
|
-
providerIentifier: any;
|
|
2318
|
-
};
|
|
2319
|
-
}
|
|
2320
|
-
/**
|
|
2321
|
-
* IDO -> OIDC 登陆前校验
|
|
2322
|
-
* @param data
|
|
2323
|
-
* @returns
|
|
2324
|
-
*/
|
|
2325
|
-
export const preLoginOIDCByAxios: (data: PreOIDCParams, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2326
|
-
export {};
|
|
2327
|
-
|
|
2328
1920
|
}
|
|
2329
1921
|
declare module '@authing/react-ui-components/components/Login/codemap' {
|
|
2330
1922
|
import { GuardModuleAction } from '@authing/react-ui-components/components/Guard/module';
|
|
@@ -2380,11 +1972,6 @@ declare module '@authing/react-ui-components/components/Login/core/withPassword/
|
|
|
2380
1972
|
export interface FormItemAccountProps extends FormItemProps {
|
|
2381
1973
|
passwordLoginMethods: PasswordLoginMethods[];
|
|
2382
1974
|
}
|
|
2383
|
-
/**
|
|
2384
|
-
* 根据对应的配置:邮箱/用户名/Email渲染FormItem
|
|
2385
|
-
* @param props
|
|
2386
|
-
* @returns
|
|
2387
|
-
*/
|
|
2388
1975
|
export const FormItemAccount: React.FC<FormItemAccountProps>;
|
|
2389
1976
|
|
|
2390
1977
|
}
|
|
@@ -2395,11 +1982,6 @@ declare module '@authing/react-ui-components/components/Login/core/withPassword/
|
|
|
2395
1982
|
verifyCodeUrl: string;
|
|
2396
1983
|
changeCode: () => void;
|
|
2397
1984
|
}
|
|
2398
|
-
/**
|
|
2399
|
-
* 图形验证码
|
|
2400
|
-
* @param props
|
|
2401
|
-
* @returns
|
|
2402
|
-
*/
|
|
2403
1985
|
export const GraphicVerifyCode: React.FC<GraphicVerifyCodeProps>;
|
|
2404
1986
|
|
|
2405
1987
|
}
|
|
@@ -2407,10 +1989,6 @@ declare module '@authing/react-ui-components/components/Login/core/withPassword/
|
|
|
2407
1989
|
import { InputProps } from 'antd/lib/input';
|
|
2408
1990
|
import React from 'react';
|
|
2409
1991
|
import { PasswordLoginMethods } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2410
|
-
/**
|
|
2411
|
-
* 账号输入框
|
|
2412
|
-
* 根据邮箱/手机号/密码配置自适应
|
|
2413
|
-
*/
|
|
2414
1992
|
export interface InputAccountProps extends InputProps {
|
|
2415
1993
|
passwordLoginMethods: PasswordLoginMethods[];
|
|
2416
1994
|
}
|
|
@@ -2436,11 +2014,6 @@ declare module '@authing/react-ui-components/components/Login/core/withPassword/
|
|
|
2436
2014
|
submitButText?: string;
|
|
2437
2015
|
saveIdentify?: (type: LoginMethods, identity: string) => void;
|
|
2438
2016
|
}
|
|
2439
|
-
/**
|
|
2440
|
-
* 密码登陆
|
|
2441
|
-
* @param props
|
|
2442
|
-
* @returns
|
|
2443
|
-
*/
|
|
2444
2017
|
export const LoginWithPassword: (props: LoginWithPasswordProps) => JSX.Element;
|
|
2445
2018
|
export {};
|
|
2446
2019
|
|
|
@@ -2624,23 +2197,6 @@ declare module '@authing/react-ui-components/components/MFA/VerifyCodeInput/inde
|
|
|
2624
2197
|
export const VerifyCodeInput: FC<VerifyCodeInputProps>;
|
|
2625
2198
|
export {};
|
|
2626
2199
|
|
|
2627
|
-
}
|
|
2628
|
-
declare module '@authing/react-ui-components/components/MFA/api/constant' {
|
|
2629
|
-
export const uploadFaceUrl: () => string;
|
|
2630
|
-
|
|
2631
|
-
}
|
|
2632
|
-
declare module '@authing/react-ui-components/components/MFA/api/index' {
|
|
2633
|
-
export { sendEmailCodeByAxios } from 'service/api';
|
|
2634
|
-
export * from '@authing/react-ui-components/components/MFA/api/request';
|
|
2635
|
-
|
|
2636
|
-
}
|
|
2637
|
-
declare module '@authing/react-ui-components/components/MFA/api/request' {
|
|
2638
|
-
import { AxiosRequestConfig } from 'axios';
|
|
2639
|
-
/**
|
|
2640
|
-
* 上传绑定人脸识别的照片
|
|
2641
|
-
*/
|
|
2642
|
-
export const uploadFaceImageByAxios: <T = any>(data: FormData, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
2643
|
-
|
|
2644
2200
|
}
|
|
2645
2201
|
declare module '@authing/react-ui-components/components/MFA/businessRequest' {
|
|
2646
2202
|
export enum MfaBusinessAction {
|
|
@@ -2684,19 +2240,8 @@ declare module '@authing/react-ui-components/components/MFA/businessRequest' {
|
|
|
2684
2240
|
export const useMfaBusinessRequest: () => {
|
|
2685
2241
|
"verify-email": (content: VerifyEmailContent) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2686
2242
|
"verify-sms": (content: VerifySmsContent) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2687
|
-
/**
|
|
2688
|
-
* Totp 状态请求
|
|
2689
|
-
* @param content
|
|
2690
|
-
* @returns
|
|
2691
|
-
*/
|
|
2692
2243
|
"verify-totp": (content: VerifyTotpContent) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2693
|
-
/**
|
|
2694
|
-
* 人脸验证
|
|
2695
|
-
*/
|
|
2696
2244
|
"verify-face": (content: VerifyFaceContent) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2697
|
-
/**
|
|
2698
|
-
* 人脸绑定
|
|
2699
|
-
*/
|
|
2700
2245
|
"associate-face": (content: AssociateFaceContent) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2701
2246
|
};
|
|
2702
2247
|
export {};
|
|
@@ -2715,11 +2260,6 @@ declare module '@authing/react-ui-components/components/MFA/core/email' {
|
|
|
2715
2260
|
onBind: (email: string) => void;
|
|
2716
2261
|
config: any;
|
|
2717
2262
|
}
|
|
2718
|
-
/**
|
|
2719
|
-
* 绑定邮箱页面
|
|
2720
|
-
* @param param0
|
|
2721
|
-
* @returns
|
|
2722
|
-
*/
|
|
2723
2263
|
export const BindMFAEmail: React.FC<BindMFAEmailProps>;
|
|
2724
2264
|
interface VerifyMFAEmailProps {
|
|
2725
2265
|
email: string;
|
|
@@ -2728,17 +2268,7 @@ declare module '@authing/react-ui-components/components/MFA/core/email' {
|
|
|
2728
2268
|
sendCodeRef: React.RefObject<HTMLButtonElement>;
|
|
2729
2269
|
codeLength: number;
|
|
2730
2270
|
}
|
|
2731
|
-
/**
|
|
2732
|
-
* 验证邮箱
|
|
2733
|
-
* @param param0
|
|
2734
|
-
* @returns
|
|
2735
|
-
*/
|
|
2736
2271
|
export const VerifyMFAEmail: React.FC<VerifyMFAEmailProps>;
|
|
2737
|
-
/**
|
|
2738
|
-
* 邮箱验证方式
|
|
2739
|
-
* @param param0
|
|
2740
|
-
* @returns
|
|
2741
|
-
*/
|
|
2742
2272
|
export const MFAEmail: React.FC<{
|
|
2743
2273
|
mfaToken: string;
|
|
2744
2274
|
email?: string;
|
|
@@ -2750,11 +2280,6 @@ declare module '@authing/react-ui-components/components/MFA/core/email' {
|
|
|
2750
2280
|
}
|
|
2751
2281
|
declare module '@authing/react-ui-components/components/MFA/core/face' {
|
|
2752
2282
|
/// <reference types="react" />
|
|
2753
|
-
/**
|
|
2754
|
-
* 面部认证
|
|
2755
|
-
* @param props
|
|
2756
|
-
* @returns
|
|
2757
|
-
*/
|
|
2758
2283
|
export const MFAFace: (props: any) => JSX.Element;
|
|
2759
2284
|
|
|
2760
2285
|
}
|
|
@@ -2766,13 +2291,7 @@ declare module '@authing/react-ui-components/components/MFA/core/face_deps' {
|
|
|
2766
2291
|
};
|
|
2767
2292
|
};
|
|
2768
2293
|
export const FACE_SCORE = 0.65;
|
|
2769
|
-
/**
|
|
2770
|
-
* 人脸检测配置
|
|
2771
|
-
*/
|
|
2772
2294
|
export function getFaceDetectorOptions(): any;
|
|
2773
|
-
/**
|
|
2774
|
-
* 获取 facePlugin tinyFaceDetector 微型人脸探测(三种方式之一)
|
|
2775
|
-
*/
|
|
2776
2295
|
export function getCurrentFaceDetectionNet(): any;
|
|
2777
2296
|
export function isFaceDetectionModelLoaded(): boolean;
|
|
2778
2297
|
export function dataURItoBlob(base64Data: any): Blob;
|
|
@@ -2789,11 +2308,6 @@ declare module '@authing/react-ui-components/components/MFA/core/sms' {
|
|
|
2789
2308
|
setAreaCode: (areaCode: string) => void;
|
|
2790
2309
|
isInternationSms: boolean;
|
|
2791
2310
|
}
|
|
2792
|
-
/**
|
|
2793
|
-
* 绑定手机号
|
|
2794
|
-
* @param param0
|
|
2795
|
-
* @returns
|
|
2796
|
-
*/
|
|
2797
2311
|
export const BindMFASms: React.FC<BindMFASmsProps>;
|
|
2798
2312
|
export interface VerifyMFASmsProps {
|
|
2799
2313
|
mfaToken: string;
|
|
@@ -2807,11 +2321,6 @@ declare module '@authing/react-ui-components/components/MFA/core/sms' {
|
|
|
2807
2321
|
userPhone?: string;
|
|
2808
2322
|
}
|
|
2809
2323
|
export const VerifyMFASms: React.FC<VerifyMFASmsProps>;
|
|
2810
|
-
/**
|
|
2811
|
-
* 手机 MFA
|
|
2812
|
-
* @param param0
|
|
2813
|
-
* @returns
|
|
2814
|
-
*/
|
|
2815
2324
|
export const MFASms: React.FC<{
|
|
2816
2325
|
mfaLogin: any;
|
|
2817
2326
|
config: MFAConfig;
|
|
@@ -2826,22 +2335,12 @@ declare module '@authing/react-ui-components/components/MFA/core/totp' {
|
|
|
2826
2335
|
initData: GuardMFAInitData;
|
|
2827
2336
|
changeModule: any;
|
|
2828
2337
|
}
|
|
2829
|
-
/**
|
|
2830
|
-
* 绑定 ToTp 页面 跳转 Totp
|
|
2831
|
-
* @param param0
|
|
2832
|
-
* @returns
|
|
2833
|
-
*/
|
|
2834
2338
|
export const BindMFATotp: React.FC<BindMFATotpProps>;
|
|
2835
2339
|
export interface VerifyMFATotpProps {
|
|
2836
2340
|
mfaToken: string;
|
|
2837
2341
|
mfaLogin: any;
|
|
2838
2342
|
changeModule: any;
|
|
2839
2343
|
}
|
|
2840
|
-
/**
|
|
2841
|
-
* Totp 验证页面
|
|
2842
|
-
* @param param0
|
|
2843
|
-
* @returns
|
|
2844
|
-
*/
|
|
2845
2344
|
export const VerifyMFATotp: React.FC<VerifyMFATotpProps>;
|
|
2846
2345
|
export interface MFATotpProps {
|
|
2847
2346
|
changeModule: any;
|
|
@@ -2849,13 +2348,6 @@ declare module '@authing/react-ui-components/components/MFA/core/totp' {
|
|
|
2849
2348
|
initData: GuardMFAInitData;
|
|
2850
2349
|
mfaLogin: any;
|
|
2851
2350
|
}
|
|
2852
|
-
/**
|
|
2853
|
-
* MFA Totp 页面
|
|
2854
|
-
* 开启 => 渲染 VerifyMFATotp 绑定
|
|
2855
|
-
* 不开启 => 渲染绑定页面
|
|
2856
|
-
* @param param
|
|
2857
|
-
* @returns
|
|
2858
|
-
*/
|
|
2859
2351
|
export const MFATotp: React.FC<MFATotpProps>;
|
|
2860
2352
|
|
|
2861
2353
|
}
|
|
@@ -2867,10 +2359,6 @@ declare module '@authing/react-ui-components/components/MFA/index' {
|
|
|
2867
2359
|
mfaBackState: string;
|
|
2868
2360
|
}
|
|
2869
2361
|
export const MFABackStateContext: React.Context<MFABackStateContextType | undefined>;
|
|
2870
|
-
/**
|
|
2871
|
-
* MFA 相关页面
|
|
2872
|
-
* @returns
|
|
2873
|
-
*/
|
|
2874
2362
|
export const GuardMFAView: React.FC;
|
|
2875
2363
|
export {};
|
|
2876
2364
|
|
|
@@ -2928,29 +2416,6 @@ declare module '@authing/react-ui-components/components/MFA/mfaMethods/index' {
|
|
|
2928
2416
|
}
|
|
2929
2417
|
export const MFAMethods: React.FC<MFAMethodsProps>;
|
|
2930
2418
|
|
|
2931
|
-
}
|
|
2932
|
-
declare module '@authing/react-ui-components/components/NeedHelpView/api/constant' {
|
|
2933
|
-
export const feedbackUrl: () => string;
|
|
2934
|
-
|
|
2935
|
-
}
|
|
2936
|
-
declare module '@authing/react-ui-components/components/NeedHelpView/api/index' {
|
|
2937
|
-
export * from '@authing/react-ui-components/components/NeedHelpView/api/request';
|
|
2938
|
-
|
|
2939
|
-
}
|
|
2940
|
-
declare module '@authing/react-ui-components/components/NeedHelpView/api/request' {
|
|
2941
|
-
/**
|
|
2942
|
-
* 问题反馈
|
|
2943
|
-
* @param data
|
|
2944
|
-
* @returns
|
|
2945
|
-
*/
|
|
2946
|
-
export const feedbackByAxios: (data: {
|
|
2947
|
-
type: number;
|
|
2948
|
-
description: string;
|
|
2949
|
-
phone: string;
|
|
2950
|
-
images: string[];
|
|
2951
|
-
appId: string;
|
|
2952
|
-
}) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2953
|
-
|
|
2954
2419
|
}
|
|
2955
2420
|
declare module '@authing/react-ui-components/components/NeedHelpView/core/describeQuestions' {
|
|
2956
2421
|
/// <reference types="react" />
|
|
@@ -2967,34 +2432,13 @@ declare module '@authing/react-ui-components/components/NeedHelpView/index' {
|
|
|
2967
2432
|
/// <reference types="react" />
|
|
2968
2433
|
export const GuardNeedHelpView: (props: any) => JSX.Element;
|
|
2969
2434
|
|
|
2970
|
-
}
|
|
2971
|
-
declare module '@authing/react-ui-components/components/RecoveryCode/api/constant' {
|
|
2972
|
-
export const recoverCodeUrl: () => string;
|
|
2973
|
-
|
|
2974
|
-
}
|
|
2975
|
-
declare module '@authing/react-ui-components/components/RecoveryCode/api/index' {
|
|
2976
|
-
export { authFlowByAxios } from 'service/api';
|
|
2977
|
-
|
|
2978
|
-
}
|
|
2979
|
-
declare module '@authing/react-ui-components/components/RecoveryCode/api/request' {
|
|
2980
|
-
import { AxiosRequestConfig } from 'axios';
|
|
2981
|
-
/**
|
|
2982
|
-
* 不在流程中(AuthFlow)请求恢复 Totp 请求
|
|
2983
|
-
* @param data
|
|
2984
|
-
* @param config
|
|
2985
|
-
* @returns
|
|
2986
|
-
*/
|
|
2987
|
-
export const recoverCodeByAxios: (data: {
|
|
2988
|
-
recoveryCode: string;
|
|
2989
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
2990
|
-
|
|
2991
2435
|
}
|
|
2992
2436
|
declare module '@authing/react-ui-components/components/RecoveryCode/businessRequest' {
|
|
2993
2437
|
export enum TotpRecoveryCodeBusinessAction {
|
|
2994
2438
|
RecoveryTotp = "recovery-totp",
|
|
2995
2439
|
ConfirmTotpRecoveryCode = "confirm-totp-recovery-code"
|
|
2996
2440
|
}
|
|
2997
|
-
export function authFlow<T>(action: TotpRecoveryCodeBusinessAction,
|
|
2441
|
+
export function authFlow<T>(action: TotpRecoveryCodeBusinessAction, content: any): Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
2998
2442
|
|
|
2999
2443
|
}
|
|
3000
2444
|
declare module '@authing/react-ui-components/components/RecoveryCode/core/saveCode' {
|
|
@@ -3019,9 +2463,6 @@ declare module '@authing/react-ui-components/components/RecoveryCode/index' {
|
|
|
3019
2463
|
import React from 'react';
|
|
3020
2464
|
import './style.less';
|
|
3021
2465
|
export const RecoveryCode: React.FC;
|
|
3022
|
-
/**
|
|
3023
|
-
* authFlow 中恢复
|
|
3024
|
-
*/
|
|
3025
2466
|
export const RecoveryCodeAuthFlow: React.FC;
|
|
3026
2467
|
export const GuardRecoveryCodeView: React.FC;
|
|
3027
2468
|
|
|
@@ -3036,37 +2477,6 @@ declare module '@authing/react-ui-components/components/RecoveryCode/interface'
|
|
|
3036
2477
|
onLogin?: (user: User, authClient: AuthenticationClient) => void;
|
|
3037
2478
|
}
|
|
3038
2479
|
|
|
3039
|
-
}
|
|
3040
|
-
declare module '@authing/react-ui-components/components/Register/api/constant' {
|
|
3041
|
-
export const registerEmailCodeUrl: () => string;
|
|
3042
|
-
|
|
3043
|
-
}
|
|
3044
|
-
declare module '@authing/react-ui-components/components/Register/api/index' {
|
|
3045
|
-
import { registerEmailCodeByAxios } from '@authing/react-ui-components/components/Register/api/request';
|
|
3046
|
-
import { validatePhoneCodeByAxios, validateEmailCodeByAxios } from 'service/api';
|
|
3047
|
-
export { validatePhoneCodeByAxios, validateEmailCodeByAxios, registerEmailCodeByAxios, };
|
|
3048
|
-
|
|
3049
|
-
}
|
|
3050
|
-
declare module '@authing/react-ui-components/components/Register/api/request' {
|
|
3051
|
-
import { AxiosRequestConfig } from 'axios';
|
|
3052
|
-
/**
|
|
3053
|
-
* 邮箱注册
|
|
3054
|
-
* @param data
|
|
3055
|
-
* @param config
|
|
3056
|
-
* @returns
|
|
3057
|
-
*/
|
|
3058
|
-
export const registerEmailCodeByAxios: (data: {
|
|
3059
|
-
email: string;
|
|
3060
|
-
code: string;
|
|
3061
|
-
profile: {
|
|
3062
|
-
browser: string | null;
|
|
3063
|
-
device: string | null | undefined;
|
|
3064
|
-
};
|
|
3065
|
-
context: string;
|
|
3066
|
-
generateToken: boolean;
|
|
3067
|
-
password?: string;
|
|
3068
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
3069
|
-
|
|
3070
2480
|
}
|
|
3071
2481
|
declare module '@authing/react-ui-components/components/Register/codemap' {
|
|
3072
2482
|
import { GuardModuleAction } from '@authing/react-ui-components/components/Guard/module';
|
|
@@ -3090,43 +2500,58 @@ declare module '@authing/react-ui-components/components/Register/components/Agre
|
|
|
3090
2500
|
declare module '@authing/react-ui-components/components/Register/core/WithCode' {
|
|
3091
2501
|
import React from 'react';
|
|
3092
2502
|
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
3093
|
-
import { GetRegisterEvent } from '@authing/react-ui-components/components/Register/interface';
|
|
3094
2503
|
export interface RegisterWithCodeProps {
|
|
3095
2504
|
onRegisterSuccess: Function;
|
|
3096
2505
|
onRegisterFailed: Function;
|
|
3097
|
-
onBeforeRegister?:
|
|
2506
|
+
onBeforeRegister?: Function;
|
|
3098
2507
|
agreements: Agreement[];
|
|
3099
2508
|
publicConfig?: ApplicationConfig;
|
|
3100
2509
|
registeContext?: any;
|
|
3101
2510
|
methods: any[];
|
|
3102
2511
|
}
|
|
3103
|
-
/**
|
|
3104
|
-
* 验证码方式注册
|
|
3105
|
-
* @param param
|
|
3106
|
-
* @returns
|
|
3107
|
-
*/
|
|
3108
2512
|
export const RegisterWithCode: React.FC<RegisterWithCodeProps>;
|
|
3109
2513
|
|
|
3110
2514
|
}
|
|
3111
2515
|
declare module '@authing/react-ui-components/components/Register/core/WithEmail' {
|
|
3112
2516
|
import React from 'react';
|
|
3113
2517
|
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
3114
|
-
import { GetRegisterEvent } from '@authing/react-ui-components/components/Register/interface';
|
|
3115
2518
|
export interface RegisterWithEmailProps {
|
|
3116
2519
|
onRegisterSuccess: Function;
|
|
3117
2520
|
onRegisterFailed: Function;
|
|
3118
|
-
onBeforeRegister?:
|
|
2521
|
+
onBeforeRegister?: Function;
|
|
3119
2522
|
publicConfig?: ApplicationConfig;
|
|
3120
2523
|
agreements: Agreement[];
|
|
3121
2524
|
registeContext?: any;
|
|
3122
2525
|
}
|
|
3123
|
-
/**
|
|
3124
|
-
* 邮箱 + 密码注册 头部显示密码注册
|
|
3125
|
-
* @param param
|
|
3126
|
-
* @returns
|
|
3127
|
-
*/
|
|
3128
2526
|
export const RegisterWithEmail: React.FC<RegisterWithEmailProps>;
|
|
3129
2527
|
|
|
2528
|
+
}
|
|
2529
|
+
declare module '@authing/react-ui-components/components/Register/core/WithEmailCode' {
|
|
2530
|
+
import React from 'react';
|
|
2531
|
+
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2532
|
+
export interface RegisterWithEmailCodeProps {
|
|
2533
|
+
onRegisterSuccess: Function;
|
|
2534
|
+
onRegisterFailed: Function;
|
|
2535
|
+
onBeforeRegister?: Function;
|
|
2536
|
+
agreements: Agreement[];
|
|
2537
|
+
publicConfig?: ApplicationConfig;
|
|
2538
|
+
registeContext?: any;
|
|
2539
|
+
}
|
|
2540
|
+
export const RegisterWithEmailCode: React.FC<RegisterWithEmailCodeProps>;
|
|
2541
|
+
|
|
2542
|
+
}
|
|
2543
|
+
declare module '@authing/react-ui-components/components/Register/core/WithPhone' {
|
|
2544
|
+
import React from 'react';
|
|
2545
|
+
import { Agreement, ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
2546
|
+
export interface RegisterWithPhoneProps {
|
|
2547
|
+
onRegisterSuccess: Function;
|
|
2548
|
+
onRegisterFailed: Function;
|
|
2549
|
+
agreements: Agreement[];
|
|
2550
|
+
publicConfig?: ApplicationConfig;
|
|
2551
|
+
registeContext?: any;
|
|
2552
|
+
}
|
|
2553
|
+
export const RegisterWithPhone: React.FC<RegisterWithPhoneProps>;
|
|
2554
|
+
|
|
3130
2555
|
}
|
|
3131
2556
|
declare module '@authing/react-ui-components/components/Register/index' {
|
|
3132
2557
|
import React from 'react';
|
|
@@ -3135,7 +2560,7 @@ declare module '@authing/react-ui-components/components/Register/index' {
|
|
|
3135
2560
|
}
|
|
3136
2561
|
declare module '@authing/react-ui-components/components/Register/interface' {
|
|
3137
2562
|
import { IG2FCProps, IG2Config, IG2Events } from '@authing/react-ui-components/components/Type/index';
|
|
3138
|
-
import { AuthenticationClient, User, RegisterMethods } from '@authing/react-ui-components/components/index';
|
|
2563
|
+
import { AuthenticationClient, User, EmailRegisterParams, PhoneRegisterParams, RegisterMethods } from '@authing/react-ui-components/components/index';
|
|
3139
2564
|
import { Agreement } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
3140
2565
|
export interface RegisterConfig extends IG2Config {
|
|
3141
2566
|
disableRegister?: boolean;
|
|
@@ -3146,24 +2571,8 @@ declare module '@authing/react-ui-components/components/Register/interface' {
|
|
|
3146
2571
|
agreements?: Agreement[];
|
|
3147
2572
|
registerContext?: any;
|
|
3148
2573
|
}
|
|
3149
|
-
export type SupportRegisterMethods = 'email' | 'email-code' | 'phone-code';
|
|
3150
|
-
/**
|
|
3151
|
-
* 注册前回调事件接受参数
|
|
3152
|
-
*/
|
|
3153
|
-
export interface onBeforeRegisterParams {
|
|
3154
|
-
type: SupportRegisterMethods;
|
|
3155
|
-
data: {
|
|
3156
|
-
account: string;
|
|
3157
|
-
password?: string;
|
|
3158
|
-
code?: string;
|
|
3159
|
-
};
|
|
3160
|
-
}
|
|
3161
|
-
/**
|
|
3162
|
-
* 获取用户注册事件的类型
|
|
3163
|
-
*/
|
|
3164
|
-
export type GetRegisterEvent<T extends keyof RegisterEvents> = RegisterEvents[T];
|
|
3165
2574
|
export interface RegisterEvents extends IG2Events {
|
|
3166
|
-
onBeforeRegister?: (registerInfo:
|
|
2575
|
+
onBeforeRegister?: (registerInfo: EmailRegisterParams | PhoneRegisterParams, authClient: AuthenticationClient) => boolean | Promise<boolean>;
|
|
3167
2576
|
onRegister?: (user: User, authClient: AuthenticationClient) => void;
|
|
3168
2577
|
onRegisterError?: (error: any) => void;
|
|
3169
2578
|
onRegisterTabChange?: (activeTab: RegisterMethods) => void;
|
|
@@ -3180,10 +2589,6 @@ declare module '@authing/react-ui-components/components/Register/interface' {
|
|
|
3180
2589
|
declare module '@authing/react-ui-components/components/Register/utils' {
|
|
3181
2590
|
export const useIsChangeComplete: (currentMode: 'phone' | 'email') => boolean;
|
|
3182
2591
|
|
|
3183
|
-
}
|
|
3184
|
-
declare module '@authing/react-ui-components/components/SelfUnlock/api/index' {
|
|
3185
|
-
export { authFlowByAxios } from 'service/api';
|
|
3186
|
-
|
|
3187
2592
|
}
|
|
3188
2593
|
declare module '@authing/react-ui-components/components/SelfUnlock/core/selfUnlock' {
|
|
3189
2594
|
import React from 'react';
|
|
@@ -3198,10 +2603,6 @@ declare module '@authing/react-ui-components/components/SelfUnlock/core/selfUnlo
|
|
|
3198
2603
|
}
|
|
3199
2604
|
declare module '@authing/react-ui-components/components/SelfUnlock/index' {
|
|
3200
2605
|
import React from 'react';
|
|
3201
|
-
/**
|
|
3202
|
-
* 自助解锁
|
|
3203
|
-
* @returns
|
|
3204
|
-
*/
|
|
3205
2606
|
export const GuardUnlockView: React.FC;
|
|
3206
2607
|
|
|
3207
2608
|
}
|
|
@@ -3254,7 +2655,7 @@ declare module '@authing/react-ui-components/components/SendCode/SendCodeByEmail
|
|
|
3254
2655
|
}
|
|
3255
2656
|
declare module '@authing/react-ui-components/components/SendCode/SendCodeByPhone' {
|
|
3256
2657
|
import { FC } from 'react';
|
|
3257
|
-
import { SceneType } from '
|
|
2658
|
+
import { SceneType } from 'authing-js-sdk';
|
|
3258
2659
|
import './style.less';
|
|
3259
2660
|
import { InputProps } from 'antd/lib/input';
|
|
3260
2661
|
export interface SendCodeByPhoneProps extends InputProps {
|
|
@@ -3269,10 +2670,6 @@ declare module '@authing/react-ui-components/components/SendCode/SendCodeByPhone
|
|
|
3269
2670
|
}
|
|
3270
2671
|
export const SendCodeByPhone: FC<SendCodeByPhoneProps>;
|
|
3271
2672
|
|
|
3272
|
-
}
|
|
3273
|
-
declare module '@authing/react-ui-components/components/SendCode/api/index' {
|
|
3274
|
-
export { sendEmailCodeByAxios } from 'service/api';
|
|
3275
|
-
|
|
3276
2673
|
}
|
|
3277
2674
|
declare module '@authing/react-ui-components/components/SendCode/index' {
|
|
3278
2675
|
import { FC } from 'react';
|
|
@@ -3347,10 +2744,6 @@ declare module '@authing/react-ui-components/components/SubmitSuccess/interface'
|
|
|
3347
2744
|
|
|
3348
2745
|
}
|
|
3349
2746
|
declare module '@authing/react-ui-components/components/Type/index' {
|
|
3350
|
-
export * from '@authing/react-ui-components/components/Type/interface';
|
|
3351
|
-
|
|
3352
|
-
}
|
|
3353
|
-
declare module '@authing/react-ui-components/components/Type/interface' {
|
|
3354
2747
|
import { AuthenticationClient, CommonMessage } from 'authing-js-sdk';
|
|
3355
2748
|
import { Lang } from 'authing-js-sdk/build/main/types';
|
|
3356
2749
|
import { ApplicationConfig } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
@@ -3429,20 +2822,6 @@ declare module '@authing/react-ui-components/components/Type/interface' {
|
|
|
3429
2822
|
EMAIL_UNBIND_VERIFY_CODE = "EMAIL_UNBIND_VERIFY_CODE",
|
|
3430
2823
|
SELF_UNLOCKING_VERIFY_CODE = "SELF_UNLOCKING_VERIFY_CODE"
|
|
3431
2824
|
}
|
|
3432
|
-
/**
|
|
3433
|
-
* 验证码场景类型
|
|
3434
|
-
*/
|
|
3435
|
-
export enum SceneType {
|
|
3436
|
-
SCENE_TYPE_LOGIN = "login",
|
|
3437
|
-
SCENE_TYPE_REGISTER = "register",
|
|
3438
|
-
SCENE_TYPE_RESET = "reset",
|
|
3439
|
-
SCENE_TYPE_BIND = "bind",
|
|
3440
|
-
SCENE_TYPE_UNBIND = "unbind",
|
|
3441
|
-
SCENE_TYPE_MFA_BIND = "mfa-bind",
|
|
3442
|
-
SCENE_TYPE_MFA_VERIFY = "mfa-verify",
|
|
3443
|
-
SCENE_TYPE_MFA_UNBIND = "mfa-unbind",
|
|
3444
|
-
SCENE_TYPE_COMPLETE_PHONE = "complete-phone"
|
|
3445
|
-
}
|
|
3446
2825
|
|
|
3447
2826
|
}
|
|
3448
2827
|
declare module '@authing/react-ui-components/components/ValidatorRules/PasswordFormItem' {
|
|
@@ -3461,10 +2840,6 @@ declare module '@authing/react-ui-components/components/ValidatorRules/Validator
|
|
|
3461
2840
|
export const PhoneFormItem: React.FC<ValidatorFormItemProps>;
|
|
3462
2841
|
export const UserNameFormItem: React.FC<ValidatorFormItemProps>;
|
|
3463
2842
|
|
|
3464
|
-
}
|
|
3465
|
-
declare module '@authing/react-ui-components/components/ValidatorRules/api/index' {
|
|
3466
|
-
export { validateAccountByAxios } from 'service/api';
|
|
3467
|
-
|
|
3468
2843
|
}
|
|
3469
2844
|
declare module '@authing/react-ui-components/components/ValidatorRules/index' {
|
|
3470
2845
|
import { FormInstance, FormItemProps } from 'antd/lib/form';
|
|
@@ -3476,7 +2851,10 @@ declare module '@authing/react-ui-components/components/ValidatorRules/index' {
|
|
|
3476
2851
|
checkRepeat?: boolean;
|
|
3477
2852
|
checkExist?: boolean;
|
|
3478
2853
|
areaCode?: string;
|
|
3479
|
-
|
|
2854
|
+
/**
|
|
2855
|
+
* 控制内部FormItem组件关于pattern的校验规则
|
|
2856
|
+
*/
|
|
2857
|
+
isCheckPattern?: boolean;
|
|
3480
2858
|
}
|
|
3481
2859
|
export interface ValidatorFormItemMetaProps extends ValidatorFormItemProps {
|
|
3482
2860
|
method: 'email' | 'phone' | 'username';
|
|
@@ -3527,32 +2905,6 @@ declare module '@authing/react-ui-components/components/_utils/GuardErrorCode' {
|
|
|
3527
2905
|
ACCOUNT_LOCK = 2005
|
|
3528
2906
|
}
|
|
3529
2907
|
|
|
3530
|
-
}
|
|
3531
|
-
declare module '@authing/react-ui-components/components/_utils/actions/index' {
|
|
3532
|
-
/**
|
|
3533
|
-
* Response Action 是否为渲染信息
|
|
3534
|
-
* @param parseStatusCode
|
|
3535
|
-
* @returns
|
|
3536
|
-
*/
|
|
3537
|
-
export const isRenderMessageByStatusCode: (parseStatusCode: number) => boolean;
|
|
3538
|
-
/**
|
|
3539
|
-
* Response Action 是否为内部流程状态处理(交由业务处理)
|
|
3540
|
-
* @param parseStatusCode
|
|
3541
|
-
* @param apiCode
|
|
3542
|
-
*/
|
|
3543
|
-
export const isFlowBusinessByStatusCode: (parseStatusCode: number) => boolean;
|
|
3544
|
-
/**
|
|
3545
|
-
* Response Action 是否为流程结束
|
|
3546
|
-
* @param parseStatusCode
|
|
3547
|
-
* @param apiCode
|
|
3548
|
-
*/
|
|
3549
|
-
export const isFlowEndByStatusCode: (parseStatusCode: number, apiCode: number) => boolean;
|
|
3550
|
-
/**
|
|
3551
|
-
* Response Action 是否为下个流程
|
|
3552
|
-
* @param parseStatusCode
|
|
3553
|
-
*/
|
|
3554
|
-
export const isNextFlowByStatusCode: (parseStatusCode: number, apiCode: number) => boolean;
|
|
3555
|
-
|
|
3556
2908
|
}
|
|
3557
2909
|
declare module '@authing/react-ui-components/components/_utils/appendConfig' {
|
|
3558
2910
|
import { GuardAppendConfig } from '@authing/react-ui-components/components/index';
|
|
@@ -3575,14 +2927,6 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
3575
2927
|
export const getPublicConfig: (appId: string) => ApplicationConfig;
|
|
3576
2928
|
export const setPublicConfig: (appId: string, config: ApplicationConfig) => ApplicationConfig;
|
|
3577
2929
|
export const useMergeDefaultConfig: (defaultConfig: GuardLocalConfig, config?: GuardComponentConfig | undefined) => GuardLocalConfig | undefined;
|
|
3578
|
-
/**
|
|
3579
|
-
*
|
|
3580
|
-
* @param appId
|
|
3581
|
-
* @param config 默认配置
|
|
3582
|
-
* @param httpClient
|
|
3583
|
-
* @param setError
|
|
3584
|
-
* @returns 合并后的 finallyConfig
|
|
3585
|
-
*/
|
|
3586
2930
|
export const useMergePublicConfig: (appId?: string | undefined, config?: GuardLocalConfig | undefined, httpClient?: GuardHttp | undefined, setError?: any) => {
|
|
3587
2931
|
host: string;
|
|
3588
2932
|
isSSO?: boolean | undefined;
|
|
@@ -3667,8 +3011,8 @@ declare module '@authing/react-ui-components/components/_utils/config/index' {
|
|
|
3667
3011
|
} | undefined;
|
|
3668
3012
|
export const getPageConfig: (appId: string) => GuardPageConfig;
|
|
3669
3013
|
export const setPageConfig: (appId: string, config: GuardPageConfig) => GuardPageConfig;
|
|
3670
|
-
export const requestGuardPageConfig: (appId: string,
|
|
3671
|
-
export const useGuardPageConfig: (appId?: string | undefined,
|
|
3014
|
+
export const requestGuardPageConfig: (appId: string, httpClient: GuardHttp) => Promise<GuardPageConfig>;
|
|
3015
|
+
export const useGuardPageConfig: (appId?: string | undefined, httpClient?: GuardHttp | undefined, serError?: any) => GuardPageConfig | undefined;
|
|
3672
3016
|
|
|
3673
3017
|
}
|
|
3674
3018
|
declare module '@authing/react-ui-components/components/_utils/context' {
|
|
@@ -3863,489 +3207,13 @@ declare module '@authing/react-ui-components/components/_utils/hooks/index' {
|
|
|
3863
3207
|
publicConfig: ApplicationConfig;
|
|
3864
3208
|
}) => any;
|
|
3865
3209
|
|
|
3866
|
-
}
|
|
3867
|
-
declare module '@authing/react-ui-components/components/_utils/http/api/constant' {
|
|
3868
|
-
export const authFlowUrl: () => string;
|
|
3869
|
-
export const VerifyEmailUrl: () => string;
|
|
3870
|
-
export const validateAccountUrl: () => string;
|
|
3871
|
-
export const countryListsUrl: () => string;
|
|
3872
|
-
export const validatePhoneCodeUrl: () => string;
|
|
3873
|
-
export const validateEmailCodeUrl: () => string;
|
|
3874
|
-
export const sendPhoneCodeUrl: () => string;
|
|
3875
|
-
|
|
3876
|
-
}
|
|
3877
|
-
declare module '@authing/react-ui-components/components/_utils/http/api/index' {
|
|
3878
|
-
export * from '@authing/react-ui-components/components/_utils/http/api/request';
|
|
3879
|
-
|
|
3880
|
-
}
|
|
3881
|
-
declare module '@authing/react-ui-components/components/_utils/http/api/request' {
|
|
3882
|
-
import { AxiosRequestConfig } from 'axios';
|
|
3883
|
-
import { EmailScene } from 'components/Type';
|
|
3884
|
-
import { SceneType } from '@authing/react-ui-components/components/Type/index';
|
|
3885
|
-
/**
|
|
3886
|
-
* AuthFlow 相关请求
|
|
3887
|
-
* @param data
|
|
3888
|
-
*/
|
|
3889
|
-
export const authFlowByAxios: <A = string, T = any>(data: {
|
|
3890
|
-
action: A;
|
|
3891
|
-
data?: any;
|
|
3892
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
3893
|
-
/**
|
|
3894
|
-
* 发送邮箱验证码
|
|
3895
|
-
* @param data
|
|
3896
|
-
*/
|
|
3897
|
-
export const sendEmailCodeByAxios: (data: {
|
|
3898
|
-
email: string;
|
|
3899
|
-
scene: EmailScene;
|
|
3900
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
3901
|
-
/**
|
|
3902
|
-
* 账号登陆前置校验
|
|
3903
|
-
*/
|
|
3904
|
-
export interface ValidateAccountParams<T = any> {
|
|
3905
|
-
/**
|
|
3906
|
-
* publicConfig.userPoolId
|
|
3907
|
-
*/
|
|
3908
|
-
userPoolId?: string;
|
|
3909
|
-
/**
|
|
3910
|
-
* 校验的输入值
|
|
3911
|
-
*/
|
|
3912
|
-
key: T;
|
|
3913
|
-
/**
|
|
3914
|
-
* 本次校验类型
|
|
3915
|
-
*/
|
|
3916
|
-
type: 'phone' | 'email' | 'username';
|
|
3917
|
-
}
|
|
3918
|
-
/**
|
|
3919
|
-
* 登陆/注册 前置,校验(用户/手机/邮箱)是否存在/用户是否不存在
|
|
3920
|
-
* @param params
|
|
3921
|
-
* @returns {Promise<boolean>} 是否通过
|
|
3922
|
-
*/
|
|
3923
|
-
export const validateAccountByAxios: <T = boolean>(params: ValidateAccountParams) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<T>>;
|
|
3924
|
-
/**
|
|
3925
|
-
* 拉取国家列表
|
|
3926
|
-
*/
|
|
3927
|
-
export const getCountryLists: <T extends string>() => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<Record<T, {
|
|
3928
|
-
zh: {
|
|
3929
|
-
[props: string]: string;
|
|
3930
|
-
};
|
|
3931
|
-
cn: {
|
|
3932
|
-
[props: string]: string;
|
|
3933
|
-
};
|
|
3934
|
-
}>>>;
|
|
3935
|
-
/**
|
|
3936
|
-
* 验证手机号验证码是否正确
|
|
3937
|
-
*/
|
|
3938
|
-
export const validatePhoneCodeByAxios: (data: {
|
|
3939
|
-
phone: number | string;
|
|
3940
|
-
phoneCode: number | string;
|
|
3941
|
-
phoneCountryCode?: number | string;
|
|
3942
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
3943
|
-
/**
|
|
3944
|
-
* 验证邮箱验证码是否正确
|
|
3945
|
-
*/
|
|
3946
|
-
export const validateEmailCodeByAxios: (data: {
|
|
3947
|
-
email: number | string;
|
|
3948
|
-
emailCode: number | string;
|
|
3949
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
3950
|
-
export const sendSmsCodeByAxios: (data: {
|
|
3951
|
-
phone: string;
|
|
3952
|
-
phoneCountryCode?: string;
|
|
3953
|
-
scene?: SceneType;
|
|
3954
|
-
}, config?: AxiosRequestConfig<any> | undefined) => Promise<import("@authing/react-ui-components/components/_utils/http").AuthingGuardResponse<any>>;
|
|
3955
|
-
|
|
3956
|
-
}
|
|
3957
|
-
declare module '@authing/react-ui-components/components/_utils/http/base/index' {
|
|
3958
|
-
import { AuthenticationClient } from 'authing-js-sdk';
|
|
3959
|
-
/**
|
|
3960
|
-
* 修改 baseUrl 配置
|
|
3961
|
-
*/
|
|
3962
|
-
export const setBaseUrl: (baseUrl: string) => void;
|
|
3963
|
-
export const setAuthClient: (client: AuthenticationClient) => void;
|
|
3964
|
-
/**
|
|
3965
|
-
* 设置加密公钥
|
|
3966
|
-
*/
|
|
3967
|
-
export const setPublishByEncrypt: (publishKey?: string | undefined) => void;
|
|
3968
|
-
|
|
3969
|
-
}
|
|
3970
|
-
declare module '@authing/react-ui-components/components/_utils/http/constant' {
|
|
3971
|
-
import { AuthingResponse } from '@authing/react-ui-components/components/_utils/http/interceptors/response';
|
|
3972
|
-
import { GuardModuleType } from '@authing/react-ui-components/components/Guard/module';
|
|
3973
|
-
import JSEncrypt from 'jsencrypt';
|
|
3974
|
-
/**
|
|
3975
|
-
* 加密实例
|
|
3976
|
-
*/
|
|
3977
|
-
export const encryptedInstance: JSEncrypt;
|
|
3978
|
-
export enum CodeAction {
|
|
3979
|
-
CHANGE_MODULE = "changeModule",
|
|
3980
|
-
RENDER_MESSAGE = "renderMessage",
|
|
3981
|
-
INNER_MODULE = "innerModule",
|
|
3982
|
-
FLOW_END = "flowEnd"
|
|
3983
|
-
}
|
|
3984
|
-
export enum ApiCode {
|
|
3985
|
-
IDENTITY_BINDING_ASK = 1641,
|
|
3986
|
-
IDENTITY_BINDING = 1640,
|
|
3987
|
-
APP_MFA = 1636,
|
|
3988
|
-
MFA = 1635,
|
|
3989
|
-
ABORT_FLOW = 1699,
|
|
3990
|
-
COMPLETE_INFO = 1642,
|
|
3991
|
-
UNLOCK = 1643,
|
|
3992
|
-
FLOW_END = 1600,
|
|
3993
|
-
FIRST_LOGIN_PASSWORD = 1639,
|
|
3994
|
-
FORCED_PASSWORD_RESET = 2058
|
|
3995
|
-
}
|
|
3996
|
-
/**
|
|
3997
|
-
* APi Code 对应的模块映射
|
|
3998
|
-
*/
|
|
3999
|
-
export const ChangeModuleApiCodeMapping: Record<string, GuardModuleType>;
|
|
4000
|
-
/**
|
|
4001
|
-
* 高阶函数 记录每次请求的 responseData
|
|
4002
|
-
* 同时根据返回的 apiCode 对应的 action 处理
|
|
4003
|
-
* @param responseData
|
|
4004
|
-
* @returns
|
|
4005
|
-
*/
|
|
4006
|
-
export const getCodeActionMapping: (responseData: AuthingResponse) => {
|
|
4007
|
-
/**
|
|
4008
|
-
* 返回的 apiCode 匹配跳转模块时
|
|
4009
|
-
* @param responseData
|
|
4010
|
-
* @returns
|
|
4011
|
-
*/
|
|
4012
|
-
changeModule: () => CodeAction;
|
|
4013
|
-
renderMessage: () => CodeAction;
|
|
4014
|
-
innerModule: () => CodeAction;
|
|
4015
|
-
flowEnd: () => CodeAction;
|
|
4016
|
-
};
|
|
4017
|
-
|
|
4018
|
-
}
|
|
4019
|
-
declare module '@authing/react-ui-components/components/_utils/http/events/index' {
|
|
4020
|
-
import { AxiosRequestConfig, AxiosResponse } from 'axios';
|
|
4021
|
-
import { AuthingGuardResponse } from 'components/_utils/http';
|
|
4022
|
-
import { setLoginEvents, setRegisterEvents } from '@authing/react-ui-components/components/_utils/http/events/utils';
|
|
4023
|
-
/**
|
|
4024
|
-
* 请求前置事件处理
|
|
4025
|
-
* 比如 beforeLogin / beforeRegister
|
|
4026
|
-
* @param config
|
|
4027
|
-
* @returns
|
|
4028
|
-
*/
|
|
4029
|
-
const processBeforeRequestEvent: (config: AxiosRequestConfig) => Promise<boolean>;
|
|
4030
|
-
/**
|
|
4031
|
-
* 响应器拦截 Events
|
|
4032
|
-
* @param response
|
|
4033
|
-
*/
|
|
4034
|
-
const processEventsByResponse: (response: AxiosResponse<AuthingGuardResponse>) => void;
|
|
4035
|
-
export { setLoginEvents, setRegisterEvents, processEventsByResponse, processBeforeRequestEvent, };
|
|
4036
|
-
|
|
4037
|
-
}
|
|
4038
|
-
declare module '@authing/react-ui-components/components/_utils/http/events/modal/login' {
|
|
4039
|
-
import { AuthenticationClient } from 'authing-js-sdk';
|
|
4040
|
-
import { AuthingResponse } from 'service/interceptors/response';
|
|
4041
|
-
class LoginEventsManage {
|
|
4042
|
-
private static instance;
|
|
4043
|
-
private successEvent;
|
|
4044
|
-
private failEvent;
|
|
4045
|
-
private constructor();
|
|
4046
|
-
/**
|
|
4047
|
-
* 设置登录成功的回调函数
|
|
4048
|
-
*/
|
|
4049
|
-
private setSuccessEvent;
|
|
4050
|
-
/**
|
|
4051
|
-
* 设置失败成功的回调函数
|
|
4052
|
-
*/
|
|
4053
|
-
private setFailEvent;
|
|
4054
|
-
/**
|
|
4055
|
-
* 获取登录成功的回调函数
|
|
4056
|
-
*/
|
|
4057
|
-
private getSuccessEvents;
|
|
4058
|
-
/**
|
|
4059
|
-
* 获取失败成功的回调函数
|
|
4060
|
-
*/
|
|
4061
|
-
private getFailEvents;
|
|
4062
|
-
/**
|
|
4063
|
-
* 判断本次响应是否算做成功的方法
|
|
4064
|
-
*/
|
|
4065
|
-
private isLoginSuccess;
|
|
4066
|
-
/**
|
|
4067
|
-
* 触发登录成功事件
|
|
4068
|
-
* @param responseData
|
|
4069
|
-
*/
|
|
4070
|
-
private emitSuccessEvent;
|
|
4071
|
-
/**
|
|
4072
|
-
* 触发登录失败事件
|
|
4073
|
-
* @param responseData
|
|
4074
|
-
*/
|
|
4075
|
-
private emitFailEvent;
|
|
4076
|
-
/**
|
|
4077
|
-
* 当前是否请求失败
|
|
4078
|
-
* statusCode 4xx 5xx 请求失败
|
|
4079
|
-
*/
|
|
4080
|
-
private isLoginFail;
|
|
4081
|
-
/**
|
|
4082
|
-
* 统一触发事件
|
|
4083
|
-
* @param responseData
|
|
4084
|
-
* @param client
|
|
4085
|
-
*/
|
|
4086
|
-
private emitEvents;
|
|
4087
|
-
/**
|
|
4088
|
-
* 获取登录事件实例
|
|
4089
|
-
*/
|
|
4090
|
-
static getInstance: () => LoginEventsManage;
|
|
4091
|
-
getCallableMethod(): {
|
|
4092
|
-
getSuccessEvents: () => ((user: import("authing-js-sdk").User, authClient: AuthenticationClient) => void) | null | undefined;
|
|
4093
|
-
setSuccessEvent: (successEvents: ((user: import("authing-js-sdk").User, authClient: AuthenticationClient) => void) | undefined) => void;
|
|
4094
|
-
setFailEvent: (failEvent: ((errorMessages: any) => void) | undefined) => void;
|
|
4095
|
-
emitSuccessEvent: (responseData: AuthingResponse<any>, client: AuthenticationClient) => void;
|
|
4096
|
-
emitFailEvent: (responseData: AuthingResponse<any>) => void;
|
|
4097
|
-
emitEvents: (responseData: AuthingResponse<any>, client: AuthenticationClient) => void;
|
|
4098
|
-
};
|
|
4099
|
-
}
|
|
4100
|
-
export { LoginEventsManage };
|
|
4101
|
-
|
|
4102
|
-
}
|
|
4103
|
-
declare module '@authing/react-ui-components/components/_utils/http/events/modal/register' {
|
|
4104
|
-
import { AuthenticationClient } from 'authing-js-sdk';
|
|
4105
|
-
import { AuthingResponse } from 'service/interceptors/response';
|
|
4106
|
-
type ConditionTypeFunction = (responseData: AuthingResponse) => boolean;
|
|
4107
|
-
class RegisterEventsManage {
|
|
4108
|
-
private static instance;
|
|
4109
|
-
private successEvent;
|
|
4110
|
-
private failEvent;
|
|
4111
|
-
private constructor();
|
|
4112
|
-
/**
|
|
4113
|
-
* 设置注册成功的回调函数
|
|
4114
|
-
*/
|
|
4115
|
-
private setSuccessEvent;
|
|
4116
|
-
/**
|
|
4117
|
-
* 设置失败成功的回调函数
|
|
4118
|
-
*/
|
|
4119
|
-
private setFailEvent;
|
|
4120
|
-
/**
|
|
4121
|
-
* 获取注册成功的回调函数
|
|
4122
|
-
*/
|
|
4123
|
-
private getSuccessEvents;
|
|
4124
|
-
/**
|
|
4125
|
-
* 获取失败成功的回调函数
|
|
4126
|
-
*/
|
|
4127
|
-
private getFailEvents;
|
|
4128
|
-
/**
|
|
4129
|
-
* 内置校验:判断本次响应是否算做成功的方法
|
|
4130
|
-
*/
|
|
4131
|
-
private isRegisterSuccess;
|
|
4132
|
-
/**
|
|
4133
|
-
* 触发注册成功事件
|
|
4134
|
-
* @param responseData
|
|
4135
|
-
* @param successCondition 自定义的注册成功事件
|
|
4136
|
-
*/
|
|
4137
|
-
private emitSuccessEvent;
|
|
4138
|
-
/**
|
|
4139
|
-
* 触发注册失败事件
|
|
4140
|
-
* @param responseData
|
|
4141
|
-
* @param failCondition 自定义的请求失败条件
|
|
4142
|
-
*/
|
|
4143
|
-
private emitFailEvent;
|
|
4144
|
-
/**
|
|
4145
|
-
* 内置校验:当前是否请求失败
|
|
4146
|
-
*/
|
|
4147
|
-
private isRegisterFail;
|
|
4148
|
-
/**
|
|
4149
|
-
* 统一触发事件
|
|
4150
|
-
* @param responseData
|
|
4151
|
-
* @param client
|
|
4152
|
-
*/
|
|
4153
|
-
private emitEvents;
|
|
4154
|
-
/**
|
|
4155
|
-
* 获取注册事件实例
|
|
4156
|
-
*/
|
|
4157
|
-
static getInstance: () => RegisterEventsManage;
|
|
4158
|
-
getCallableMethod(): {
|
|
4159
|
-
setSuccessEvent: (successEvents: ((user: import("authing-js-sdk").User, authClient: AuthenticationClient) => void) | undefined) => void;
|
|
4160
|
-
setFailEvent: (failEvent: ((error: any) => void) | undefined) => void;
|
|
4161
|
-
emitSuccessEvent: (params: {
|
|
4162
|
-
responseData: AuthingResponse<any>;
|
|
4163
|
-
client: AuthenticationClient;
|
|
4164
|
-
condition?: ConditionTypeFunction | undefined;
|
|
4165
|
-
}) => void;
|
|
4166
|
-
emitFailEvent: (params: {
|
|
4167
|
-
responseData: AuthingResponse<any>;
|
|
4168
|
-
condition?: ConditionTypeFunction | undefined;
|
|
4169
|
-
}) => void;
|
|
4170
|
-
emitEvents: (responseData: AuthingResponse<any>, client: AuthenticationClient, options?: {
|
|
4171
|
-
successCondition?: ConditionTypeFunction | undefined;
|
|
4172
|
-
failCondition?: ConditionTypeFunction | undefined;
|
|
4173
|
-
} | undefined) => void;
|
|
4174
|
-
};
|
|
4175
|
-
}
|
|
4176
|
-
export { RegisterEventsManage };
|
|
4177
|
-
|
|
4178
|
-
}
|
|
4179
|
-
declare module '@authing/react-ui-components/components/_utils/http/events/utils' {
|
|
4180
|
-
import { LoginEventsManage } from '@authing/react-ui-components/components/_utils/http/events/modal/login';
|
|
4181
|
-
import { RegisterEventsManage } from '@authing/react-ui-components/components/_utils/http/events/modal/register';
|
|
4182
|
-
/**
|
|
4183
|
-
* 内置的登录类型
|
|
4184
|
-
*/
|
|
4185
|
-
export const instanceEventMap: {
|
|
4186
|
-
login: typeof LoginEventsManage;
|
|
4187
|
-
register: typeof RegisterEventsManage;
|
|
4188
|
-
};
|
|
4189
|
-
/**
|
|
4190
|
-
* 设置登录事件
|
|
4191
|
-
* @returns
|
|
4192
|
-
*/
|
|
4193
|
-
export const setLoginEvents: () => {
|
|
4194
|
-
setSuccessEvent: ((successEvents: ((user: import("authing-js-sdk").User, authClient: import("authing-js-sdk").AuthenticationClient) => void) | undefined) => void) | ((successEvents: ((user: import("authing-js-sdk").User, authClient: import("authing-js-sdk").AuthenticationClient) => void) | undefined) => void);
|
|
4195
|
-
setFailEvent: ((failEvent: ((errorMessages: any) => void) | undefined) => void) | ((failEvent: ((error: any) => void) | undefined) => void);
|
|
4196
|
-
};
|
|
4197
|
-
/**
|
|
4198
|
-
* 设置注册事件
|
|
4199
|
-
* @returns
|
|
4200
|
-
*/
|
|
4201
|
-
export const setRegisterEvents: () => {
|
|
4202
|
-
setSuccessEvent: ((successEvents: ((user: import("authing-js-sdk").User, authClient: import("authing-js-sdk").AuthenticationClient) => void) | undefined) => void) | ((successEvents: ((user: import("authing-js-sdk").User, authClient: import("authing-js-sdk").AuthenticationClient) => void) | undefined) => void);
|
|
4203
|
-
setFailEvent: ((failEvent: ((errorMessages: any) => void) | undefined) => void) | ((failEvent: ((error: any) => void) | undefined) => void);
|
|
4204
|
-
};
|
|
4205
|
-
|
|
4206
|
-
}
|
|
4207
|
-
declare module '@authing/react-ui-components/components/_utils/http/header/index' {
|
|
4208
|
-
/**
|
|
4209
|
-
* 设置 version
|
|
4210
|
-
* @param value
|
|
4211
|
-
* @param key
|
|
4212
|
-
*/
|
|
4213
|
-
export const setVersionByHeader: (value: string, key?: string) => void;
|
|
4214
|
-
/**
|
|
4215
|
-
* 设置 sdk version
|
|
4216
|
-
* @param value
|
|
4217
|
-
* @param key
|
|
4218
|
-
*/
|
|
4219
|
-
export const setSdkVersionByHeader: (value: string, key?: string) => void;
|
|
4220
|
-
/**
|
|
4221
|
-
* 设置 AppId
|
|
4222
|
-
* @param value
|
|
4223
|
-
* @param key
|
|
4224
|
-
*/
|
|
4225
|
-
export const setAppIdByRequestHeader: (value: string, key?: string) => void;
|
|
4226
|
-
/**
|
|
4227
|
-
* 设置 x-authing-app-tenant-id 请求头
|
|
4228
|
-
* @param value
|
|
4229
|
-
* @param key
|
|
4230
|
-
*/
|
|
4231
|
-
export const setTenantIdByRequestHeader: (value?: string | undefined, key?: string) => void;
|
|
4232
|
-
/**
|
|
4233
|
-
* 根据 publishConfig 中的 userid 设置
|
|
4234
|
-
* @param value
|
|
4235
|
-
* @param key
|
|
4236
|
-
*/
|
|
4237
|
-
export const setUserPoolIdByRequestHeader: (value: string, key?: string) => void;
|
|
4238
|
-
export const setLanguageInRequestHeader: () => void;
|
|
4239
|
-
/**
|
|
4240
|
-
* 获取当前所有 headers
|
|
4241
|
-
*/
|
|
4242
|
-
export const getHeader: () => import("axios").HeadersDefaults;
|
|
4243
|
-
/**
|
|
4244
|
-
* 修改/设置请求头
|
|
4245
|
-
* @param key
|
|
4246
|
-
* @param value
|
|
4247
|
-
*/
|
|
4248
|
-
export const _setRequestHeader: (key: string, value: string) => void;
|
|
4249
|
-
|
|
4250
|
-
}
|
|
4251
|
-
declare module '@authing/react-ui-components/components/_utils/http/index' {
|
|
4252
|
-
import instance from '@authing/react-ui-components/components/_utils/http/instance';
|
|
4253
|
-
import * as httpHeaderMethods from '@authing/react-ui-components/components/_utils/http/header/index';
|
|
4254
|
-
import * as httpEvents from '@authing/react-ui-components/components/_utils/http/events/index';
|
|
4255
|
-
import * as httpBaseConfig from '@authing/react-ui-components/components/_utils/http/base/index';
|
|
4256
|
-
import * as commonRequest from '@authing/react-ui-components/components/_utils/http/api/index';
|
|
4257
|
-
export { instance, httpHeaderMethods, httpEvents, httpBaseConfig, commonRequest, };
|
|
4258
|
-
|
|
4259
|
-
}
|
|
4260
|
-
declare module '@authing/react-ui-components/components/_utils/http/instance' {
|
|
4261
|
-
const instance: import("axios").AxiosInstance;
|
|
4262
|
-
export default instance;
|
|
4263
|
-
|
|
4264
|
-
}
|
|
4265
|
-
declare module '@authing/react-ui-components/components/_utils/http/interceptors/request' {
|
|
4266
|
-
import { AxiosInstance } from 'axios';
|
|
4267
|
-
/**
|
|
4268
|
-
* 初始化请求拦截器
|
|
4269
|
-
* @param instance
|
|
4270
|
-
*/
|
|
4271
|
-
export const initRequestInterceptors: (instance: AxiosInstance) => void;
|
|
4272
|
-
|
|
4273
|
-
}
|
|
4274
|
-
declare module '@authing/react-ui-components/components/_utils/http/interceptors/response' {
|
|
4275
|
-
import { AxiosInstance } from 'axios';
|
|
4276
|
-
export interface AuthingResponse<T = any> {
|
|
4277
|
-
/**
|
|
4278
|
-
* 错误码
|
|
4279
|
-
*/
|
|
4280
|
-
code?: number;
|
|
4281
|
-
/**
|
|
4282
|
-
* 返回状态
|
|
4283
|
-
* 3XX:状态机流转
|
|
4284
|
-
* 4XX|6XX:错误处理
|
|
4285
|
-
*/
|
|
4286
|
-
statusCode?: number;
|
|
4287
|
-
/**
|
|
4288
|
-
* statusCode 3XX 时下个阶段的 code 码
|
|
4289
|
-
*/
|
|
4290
|
-
apiCode?: number;
|
|
4291
|
-
/**
|
|
4292
|
-
* 返回的数据
|
|
4293
|
-
*/
|
|
4294
|
-
data?: T;
|
|
4295
|
-
/**
|
|
4296
|
-
*
|
|
4297
|
-
*/
|
|
4298
|
-
messages?: string;
|
|
4299
|
-
/**
|
|
4300
|
-
*
|
|
4301
|
-
*/
|
|
4302
|
-
message?: string;
|
|
4303
|
-
/**
|
|
4304
|
-
* 当前流程 ID
|
|
4305
|
-
* ResponseData 返回则更新当前流程 ID
|
|
4306
|
-
*/
|
|
4307
|
-
flowHandle?: string;
|
|
4308
|
-
/**
|
|
4309
|
-
* 响应是否为当前业务内小状态处理
|
|
4310
|
-
* statusCode === 200 下进入该状态
|
|
4311
|
-
*/
|
|
4312
|
-
isBusiness?: boolean;
|
|
4313
|
-
}
|
|
4314
|
-
/**
|
|
4315
|
-
* 初始化响应拦截器
|
|
4316
|
-
*/
|
|
4317
|
-
export const initResponseInterceptors: (instance: AxiosInstance) => void;
|
|
4318
|
-
|
|
4319
|
-
}
|
|
4320
|
-
declare module '@authing/react-ui-components/components/_utils/http/utils' {
|
|
4321
|
-
import { AxiosRequestConfig, AxiosResponse } from 'axios';
|
|
4322
|
-
import { AuthingResponse } from '@authing/react-ui-components/components/_utils/http/interceptors/response';
|
|
4323
|
-
/**
|
|
4324
|
-
* 根据 Response 中的 apiCode & statusCode 做拦截
|
|
4325
|
-
* @param response
|
|
4326
|
-
* @returns
|
|
4327
|
-
*/
|
|
4328
|
-
export const processCodeByResponse: (response: AxiosResponse<AuthingResponse>) => AuthingResponse<any>;
|
|
4329
|
-
/**
|
|
4330
|
-
* 处理请求加密字段
|
|
4331
|
-
* @param config
|
|
4332
|
-
* @returns
|
|
4333
|
-
*/
|
|
4334
|
-
export const processEncryptRequestKey: (config: AxiosRequestConfig) => Promise<any>;
|
|
4335
|
-
/**
|
|
4336
|
-
* 处理 flowHandler
|
|
4337
|
-
* @param response
|
|
4338
|
-
* @returns
|
|
4339
|
-
*/
|
|
4340
|
-
export const processFlowHandler: (response: AuthingResponse) => AuthingResponse<any>;
|
|
4341
|
-
|
|
4342
3210
|
}
|
|
4343
3211
|
declare module '@authing/react-ui-components/components/_utils/http' {
|
|
4344
3212
|
import { CodeAction } from '@authing/react-ui-components/components/_utils/responseManagement/interface';
|
|
4345
3213
|
import { AxiosRequestConfig } from 'axios';
|
|
4346
3214
|
export const requestClient: {
|
|
4347
3215
|
(input: RequestInfo, init?: RequestInit | undefined): Promise<any>;
|
|
4348
|
-
get<T>(path: string, query?: Record<string, any>, init?: AxiosRequestConfig
|
|
3216
|
+
get<T>(path: string, query?: Record<string, any>, init?: AxiosRequestConfig | undefined): Promise<AuthingResponse<T>>;
|
|
4349
3217
|
post<T_1>(path: string, data: any, config?: {
|
|
4350
3218
|
headers: any;
|
|
4351
3219
|
} | undefined): Promise<AuthingResponse<T_1>>;
|
|
@@ -4371,36 +3239,18 @@ declare module '@authing/react-ui-components/components/_utils/http' {
|
|
|
4371
3239
|
flowHandle?: string;
|
|
4372
3240
|
}
|
|
4373
3241
|
export interface AuthingGuardResponse<T = any> extends AuthingResponse<T> {
|
|
4374
|
-
/**
|
|
4375
|
-
* 根据 Server 返回状态进行的状态流转函数
|
|
4376
|
-
* 默认响应拦截器中自动调用
|
|
4377
|
-
*/
|
|
4378
3242
|
onGuardHandling?: () => CodeAction;
|
|
4379
|
-
/**
|
|
4380
|
-
* Response 返回 actions 是否需要模块内部处理
|
|
4381
|
-
* 根据 status === 200 判断
|
|
4382
|
-
*/
|
|
4383
|
-
isBusiness?: boolean;
|
|
4384
|
-
/**
|
|
4385
|
-
* 流程是否结束(兼容老版本字段)
|
|
4386
|
-
*/
|
|
4387
3243
|
isFlowEnd?: boolean;
|
|
4388
|
-
/**
|
|
4389
|
-
* 本次响应 Action 类型
|
|
4390
|
-
* see: packages/react-components/components/_utils/responseManagement/interface.ts
|
|
4391
|
-
*/
|
|
4392
|
-
responseActionType?: CodeAction;
|
|
4393
3244
|
}
|
|
4394
3245
|
|
|
4395
3246
|
}
|
|
4396
3247
|
declare module '@authing/react-ui-components/components/_utils/index' {
|
|
4397
|
-
import {
|
|
3248
|
+
import { Rule } from 'antd/lib/form';
|
|
4398
3249
|
import qs from 'qs';
|
|
4399
3250
|
import { User } from 'authing-js-sdk';
|
|
4400
3251
|
import { ApplicationConfig, ComplateFiledsPlace } from '@authing/react-ui-components/components/AuthingGuard/api/index';
|
|
4401
3252
|
import { GuardProps } from '@authing/react-ui-components/components/Guard/index';
|
|
4402
3253
|
import { LoginMethods, RegisterMethods } from '@authing/react-ui-components/components/AuthingGuard/types/index';
|
|
4403
|
-
import { InputMethod } from 'components';
|
|
4404
3254
|
export * from '@authing/react-ui-components/components/_utils/popupCenter';
|
|
4405
3255
|
export * from '@authing/react-ui-components/components/_utils/clipboard';
|
|
4406
3256
|
export const VALIDATE_PATTERN: {
|
|
@@ -4413,20 +3263,6 @@ declare module '@authing/react-ui-components/components/_utils/index' {
|
|
|
4413
3263
|
export const validate: (type: keyof typeof VALIDATE_PATTERN, val: string) => boolean;
|
|
4414
3264
|
export const getRequiredRules: (msg: string) => Rule[];
|
|
4415
3265
|
export const fieldRequiredRule: (fieldRequiredRule: string, fieldRequiredRuleMessage?: string | undefined) => Rule[];
|
|
4416
|
-
/**
|
|
4417
|
-
* 验证码是否正确
|
|
4418
|
-
* @param form form 实例
|
|
4419
|
-
* @param key 当前 FormItem 对应值的 key,比如当前为邮箱验证码就传入邮箱输入框的 formItem name
|
|
4420
|
-
* @returns Array
|
|
4421
|
-
*/
|
|
4422
|
-
export const fieldCodeCorrect: (form: FormInstance, key: string | undefined, options: {
|
|
4423
|
-
currentMethod: InputMethod;
|
|
4424
|
-
areaCode: string;
|
|
4425
|
-
isInternationSms?: boolean | undefined;
|
|
4426
|
-
}) => {
|
|
4427
|
-
validateTrigger: string[];
|
|
4428
|
-
validator: (rule: RuleObject, value: string) => Promise<void>;
|
|
4429
|
-
}[];
|
|
4430
3266
|
export function getDeviceName(): string | null | undefined;
|
|
4431
3267
|
export type STYLE_RECORD_KEY = 'appConfig' | 'userConfig';
|
|
4432
3268
|
export const insertStyles: (styles: string | any, recordKey?: "userConfig" | "appConfig" | undefined) => void;
|
|
@@ -4574,12 +3410,6 @@ declare module '@authing/react-ui-components/components/_utils/popupCenter' {
|
|
|
4574
3410
|
declare module '@authing/react-ui-components/components/_utils/responseManagement/index' {
|
|
4575
3411
|
import { AuthingGuardResponse, AuthingResponse } from '@authing/react-ui-components/components/_utils/http';
|
|
4576
3412
|
import { CodeAction } from '@authing/react-ui-components/components/_utils/responseManagement/interface';
|
|
4577
|
-
/**
|
|
4578
|
-
* 全局的错误拦截器
|
|
4579
|
-
* @param res
|
|
4580
|
-
* @param callBack
|
|
4581
|
-
* @returns
|
|
4582
|
-
*/
|
|
4583
3413
|
export const errorCodeInterceptor: (res: AuthingResponse<any>, callBack: (code: CodeAction, res: AuthingResponse) => AuthingGuardResponse) => AuthingResponse<any>;
|
|
4584
3414
|
|
|
4585
3415
|
}
|
|
@@ -4707,7 +3537,7 @@ declare module '@authing/react-ui-components/components/version/index' {
|
|
|
4707
3537
|
|
|
4708
3538
|
}
|
|
4709
3539
|
declare module '@authing/react-ui-components/components/version/version' {
|
|
4710
|
-
const _default: "3.1.
|
|
3540
|
+
const _default: "3.1.31-rc.0";
|
|
4711
3541
|
export default _default;
|
|
4712
3542
|
|
|
4713
3543
|
}
|
|
@@ -4836,13 +3666,11 @@ declare module '@authing/react-ui-components/config/webpack.config' {
|
|
|
4836
3666
|
modules: string[];
|
|
4837
3667
|
extensions: string[];
|
|
4838
3668
|
alias: {
|
|
4839
|
-
service: string;
|
|
4840
3669
|
src?: undefined;
|
|
4841
3670
|
'react-dom$'?: string;
|
|
4842
3671
|
'scheduler/tracing'?: string;
|
|
4843
3672
|
'react-native': string;
|
|
4844
3673
|
} | {
|
|
4845
|
-
service: string;
|
|
4846
3674
|
src: string;
|
|
4847
3675
|
'react-dom$'?: string;
|
|
4848
3676
|
'scheduler/tracing'?: string;
|