halo-fe 1.0.4 → 1.0.5
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/main.js +255 -247
- package/esm/drivers/bridges/IBridge.d.ts +5 -0
- package/esm/drivers/factories/index.d.ts +21 -2
- package/esm/drivers/ssos/ISso.d.ts +1 -1
- package/esm/drivers/ssos/implements/BearerSso.d.ts +1 -1
- package/esm/drivers/videos/VideoFactory.d.ts +0 -0
- package/esm/drivers/voices/IVoice.d.ts +14 -0
- package/esm/drivers/voices/VoiceFactory.d.ts +1 -0
- package/esm/drivers/voices/implement/DefaultVoice.d.ts +6 -0
- package/esm/drivers/voices/implement/TencentVoice.d.ts +9 -0
- package/esm/helpers/time-helper.d.ts +7 -3
- package/esm/main.d.ts +4 -4
- package/esm/plugins/index.d.ts +1 -0
- package/esm/plugins/types/IMessager.d.ts +34 -0
- package/esm/plugins/types/index.d.ts +7 -0
- package/esm/services/index.d.ts +1 -8
- package/esm/services/types/IMessager.d.ts +22 -2
- package/package.json +1 -1
@@ -1,14 +1,33 @@
|
|
1
1
|
import DriverFactory from "./DriverFactory";
|
2
2
|
import { HttpFactory, IHttp } from "../https";
|
3
3
|
import { EncoderFactory } from "../encoders";
|
4
|
+
import { CdnFactory } from "../cdns";
|
5
|
+
import { ExplainerFactory } from "../explainers";
|
6
|
+
import { ExcelFactory } from "../excels";
|
7
|
+
import { FeatureFactory } from "../features";
|
8
|
+
import { HasherFactory } from "../hashers";
|
9
|
+
import { ProviderFactory } from "../providers";
|
10
|
+
import { SignerFactory } from "../signers";
|
11
|
+
import { SsoFactory } from "../ssos";
|
4
12
|
/**
|
5
13
|
* 默认Http请求对象
|
6
14
|
*/
|
7
|
-
declare let
|
15
|
+
declare let cdnFactory: CdnFactory;
|
8
16
|
declare let encoderFactory: EncoderFactory;
|
17
|
+
declare let excelFactory: ExcelFactory;
|
18
|
+
declare let explainerFactory: ExplainerFactory;
|
19
|
+
declare let featureFactory: FeatureFactory;
|
20
|
+
declare let hasherFactory: HasherFactory;
|
21
|
+
declare let httpFactory: HttpFactory;
|
22
|
+
declare let providerFactory: ProviderFactory;
|
23
|
+
declare let signerFactory: SignerFactory;
|
24
|
+
declare let ssoFactory: SsoFactory;
|
25
|
+
/**
|
26
|
+
* 默认http请求对象
|
27
|
+
*/
|
9
28
|
declare let http: IHttp;
|
10
29
|
/**
|
11
30
|
* 设置Http请求对象
|
12
31
|
*/
|
13
32
|
declare let setHttp: () => Promise<void>;
|
14
|
-
export {
|
33
|
+
export { cdnFactory, encoderFactory, excelFactory, explainerFactory, featureFactory, hasherFactory, httpFactory, providerFactory, signerFactory, ssoFactory, DriverFactory, http, setHttp };
|
@@ -29,7 +29,7 @@ interface ISso extends IDriver {
|
|
29
29
|
/**
|
30
30
|
* 获取授权头,不能泄露域账号等用户标识
|
31
31
|
*/
|
32
|
-
getAuth(token: string, timestamp: number, sign: string, env: string): string;
|
32
|
+
getAuth(token: string, timestamp: number, sign: string, platform: string, env: string): string;
|
33
33
|
/**
|
34
34
|
* 退出
|
35
35
|
*/
|
@@ -16,7 +16,7 @@ declare class BearerSso implements ISso {
|
|
16
16
|
token: string;
|
17
17
|
secret: string;
|
18
18
|
};
|
19
|
-
getAuth(token: string, timestamp: number, signature: string, env?: string): string;
|
19
|
+
getAuth(token: string, timestamp: number, signature: string, platform?: string, env?: string): string;
|
20
20
|
logout(): void;
|
21
21
|
}
|
22
22
|
export default BearerSso;
|
File without changes
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -45,11 +45,15 @@ declare class TimeHelper {
|
|
45
45
|
/**
|
46
46
|
* 添加天数
|
47
47
|
*/
|
48
|
-
static addDays: (value: any, days: number) =>
|
48
|
+
static addDays: (value: any, days: number) => Date;
|
49
49
|
/**
|
50
50
|
* 添加月份
|
51
51
|
*/
|
52
|
-
static addMonths: (value: any, months: number) =>
|
52
|
+
static addMonths: (value: any, months: number) => Date;
|
53
|
+
/**
|
54
|
+
* 添加小时
|
55
|
+
*/
|
56
|
+
static addHours: (value: any, hours: number) => Date;
|
53
57
|
/**
|
54
58
|
* 判断指定时间是否是周末
|
55
59
|
*/
|
@@ -57,6 +61,6 @@ declare class TimeHelper {
|
|
57
61
|
/**
|
58
62
|
* 把中国时间,转换为当地时间
|
59
63
|
*/
|
60
|
-
static localeTime: (time: any) =>
|
64
|
+
static localeTime: (time: any) => Date;
|
61
65
|
}
|
62
66
|
export default TimeHelper;
|
package/esm/main.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { IMessager } from "./
|
1
|
+
import { IMessager } from "./plugins";
|
2
2
|
import "./styles/index.scss";
|
3
3
|
export * from "./coms";
|
4
4
|
export * from "./drivers";
|
@@ -8,7 +8,7 @@ export * from "./services";
|
|
8
8
|
export * from "./stores";
|
9
9
|
export * from "./utilities";
|
10
10
|
/**
|
11
|
-
*
|
11
|
+
* 初始化前端基础框架
|
12
12
|
*/
|
13
|
-
declare let
|
14
|
-
export {
|
13
|
+
declare let createFe: (messager: IMessager) => Promise<void>;
|
14
|
+
export { createFe };
|
package/esm/plugins/index.d.ts
CHANGED
@@ -0,0 +1,34 @@
|
|
1
|
+
/**
|
2
|
+
* 消息提示接口,下游自己定义
|
3
|
+
*/
|
4
|
+
interface IMessager {
|
5
|
+
/**
|
6
|
+
* 显示全局成功消息
|
7
|
+
*/
|
8
|
+
success(message: string): void;
|
9
|
+
/**
|
10
|
+
* 显示全局警告消息
|
11
|
+
*/
|
12
|
+
warning(message: string): void;
|
13
|
+
/**
|
14
|
+
* 显示全局信息消息
|
15
|
+
*/
|
16
|
+
info(message: string): void;
|
17
|
+
/**
|
18
|
+
* 显示全局错误消息
|
19
|
+
*/
|
20
|
+
error(message: string): void;
|
21
|
+
/**
|
22
|
+
* 显示全局错误消息
|
23
|
+
*/
|
24
|
+
confirm(title: string, message: string, options?: any): Promise<any>;
|
25
|
+
/**
|
26
|
+
* 显示警告框
|
27
|
+
*/
|
28
|
+
alert(title: string, message: string, options?: any): void;
|
29
|
+
/**
|
30
|
+
* 通知
|
31
|
+
*/
|
32
|
+
notify(title: string, message: string, type: string): void;
|
33
|
+
}
|
34
|
+
export default IMessager;
|
package/esm/services/index.d.ts
CHANGED
@@ -1,9 +1,2 @@
|
|
1
1
|
import SettingService from "./SettingService";
|
2
|
-
|
3
|
-
export * from "./types";
|
4
|
-
declare let messager: IMessager;
|
5
|
-
/**
|
6
|
-
* 重新设置消息对象
|
7
|
-
*/
|
8
|
-
declare let setMessager: (msgr: IMessager) => void;
|
9
|
-
export { SettingService, messager, setMessager };
|
2
|
+
export { SettingService, };
|
@@ -3,12 +3,32 @@
|
|
3
3
|
*/
|
4
4
|
interface IMessager {
|
5
5
|
/**
|
6
|
-
*
|
6
|
+
* 显示全局成功消息
|
7
7
|
*/
|
8
8
|
success(message: string): void;
|
9
9
|
/**
|
10
|
-
*
|
10
|
+
* 显示全局警告消息
|
11
|
+
*/
|
12
|
+
warning(message: string): void;
|
13
|
+
/**
|
14
|
+
* 显示全局信息消息
|
15
|
+
*/
|
16
|
+
info(message: string): void;
|
17
|
+
/**
|
18
|
+
* 显示全局错误消息
|
11
19
|
*/
|
12
20
|
error(message: string): void;
|
21
|
+
/**
|
22
|
+
* 显示全局错误消息
|
23
|
+
*/
|
24
|
+
confirm(title: string, message: string, options?: any): void;
|
25
|
+
/**
|
26
|
+
* 显示警告框
|
27
|
+
*/
|
28
|
+
alert(title: string, message: string, options?: any): void;
|
29
|
+
/**
|
30
|
+
* 通知
|
31
|
+
*/
|
32
|
+
notify(title: string, message: string, type: string): void;
|
13
33
|
}
|
14
34
|
export default IMessager;
|