halo-fe 1.0.5 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/main.js +3453 -2365
- package/dist/style.css +1 -1
- package/dist/{vendor-crypto-js-B6Qe-gIg.js → vendor-crypto-js-DWn5nTKL.js} +3 -1
- package/dist/vendor-xlsx-js-style-DMPNZPOx.js +11862 -0
- package/esm/coms/Code.vue.d.ts +1 -1
- package/esm/coms/Fill.vue.d.ts +15 -0
- package/esm/coms/RichText.vue.d.ts +24 -0
- package/esm/coms/Scroller.vue.d.ts +28 -0
- package/esm/coms/index.d.ts +5 -1
- package/esm/coms/types/RichTextOptions.d.ts +14 -0
- package/esm/coms/types/RichTextProps.d.ts +12 -0
- package/esm/coms/types/ScrollerProps.d.ts +15 -0
- package/esm/coms/types/index.d.ts +4 -1
- package/esm/drivers/IDisposable.d.ts +4 -0
- package/esm/drivers/bridges/index.d.ts +1 -0
- package/esm/drivers/cdns/index.d.ts +2 -2
- package/esm/drivers/driver-helper.d.ts +46 -0
- package/esm/drivers/encoders/Encoder.d.ts +6 -1
- package/esm/drivers/encoders/EncoderFactory.d.ts +0 -1
- package/esm/drivers/encoders/IEncoder.d.ts +7 -3
- package/esm/drivers/encoders/implement/Base64Encoder.d.ts +1 -1
- package/esm/drivers/encoders/index.d.ts +2 -2
- package/esm/drivers/excels/index.d.ts +2 -3
- package/esm/drivers/explainers/index.d.ts +1 -2
- package/esm/drivers/factories/Factories.d.ts +55 -0
- package/esm/drivers/factories/Factory.d.ts +9 -0
- package/esm/drivers/factories/IFactory.d.ts +4 -0
- package/esm/drivers/factories/implement/CdnFactory.d.ts +13 -0
- package/esm/drivers/factories/implement/EncoderFactory.d.ts +17 -0
- package/esm/drivers/factories/implement/ExcelFactory.d.ts +13 -0
- package/esm/drivers/factories/implement/ExplainerFactory.d.ts +6 -0
- package/esm/drivers/factories/implement/FeatureFactory.d.ts +13 -0
- package/esm/drivers/factories/implement/HasherFactory.d.ts +11 -0
- package/esm/drivers/factories/implement/HttpFactory.d.ts +18 -0
- package/esm/drivers/factories/implement/ProviderFactory.d.ts +18 -0
- package/esm/drivers/factories/implement/SignerFactory.d.ts +13 -0
- package/esm/drivers/factories/implement/SsoFactory.d.ts +17 -0
- package/esm/drivers/factories/implement/TaskFactory.d.ts +9 -0
- package/esm/drivers/factories/implement/VideoFactory.d.ts +3 -0
- package/esm/drivers/factories/implement/VoiceFactory.d.ts +6 -0
- package/esm/drivers/factories/implement/index.d.ts +11 -0
- package/esm/drivers/factories/index.d.ts +14 -26
- package/esm/drivers/features/index.d.ts +2 -3
- package/esm/drivers/hashers/HasherFactory.d.ts +0 -1
- package/esm/drivers/hashers/index.d.ts +2 -3
- package/esm/drivers/https/Http.d.ts +5 -5
- package/esm/drivers/https/HttpFactory.d.ts +0 -2
- package/esm/drivers/https/IHttp.d.ts +4 -4
- package/esm/drivers/https/entities/HttpResponse.d.ts +13 -1
- package/esm/drivers/https/implements/DefaultHttp.d.ts +1 -0
- package/esm/drivers/https/implements/HaloHttp.d.ts +28 -4
- package/esm/drivers/https/index.d.ts +2 -3
- package/esm/drivers/index.d.ts +7 -1
- package/esm/drivers/providers/implements/CookieProvider.d.ts +3 -0
- package/esm/drivers/providers/implements/StorageHelper.d.ts +34 -0
- package/esm/drivers/providers/index.d.ts +2 -3
- package/esm/drivers/requesters/IRequester.d.ts +25 -0
- package/esm/drivers/requesters/Requester.d.ts +13 -0
- package/esm/drivers/requesters/RequesterFactory.d.ts +21 -0
- package/esm/drivers/requesters/entities/HttpRequest.d.ts +34 -0
- package/esm/drivers/requesters/entities/HttpResponse.d.ts +19 -0
- package/esm/drivers/requesters/implements/DefaultRequester.d.ts +12 -0
- package/esm/drivers/requesters/implements/LocalRequester.d.ts +43 -0
- package/esm/drivers/requesters/implements/MkRequester.d.ts +40 -0
- package/esm/drivers/requesters/index.d.ts +5 -0
- package/esm/drivers/signers/implements/DefaultSigner.d.ts +0 -2
- package/esm/drivers/signers/index.d.ts +2 -3
- package/esm/drivers/ssos/index.d.ts +2 -3
- package/esm/drivers/tasks/ITask.d.ts +12 -0
- package/esm/drivers/tasks/Task.d.ts +10 -0
- package/esm/drivers/tasks/implement/MemoryTask.d.ts +11 -0
- package/esm/drivers/tasks/index.d.ts +2 -0
- package/esm/drivers/videos/VideoFactory.d.ts +3 -0
- package/esm/drivers/videos/index.d.ts +1 -0
- package/esm/drivers/voices/IVoice.d.ts +2 -1
- package/esm/drivers/voices/Voice.d.ts +8 -0
- package/esm/drivers/voices/VoiceFactory.d.ts +6 -1
- package/esm/drivers/voices/implement/DefaultVoice.d.ts +4 -2
- package/esm/drivers/voices/implement/TencentVoice.d.ts +4 -2
- package/esm/drivers/voices/index.d.ts +1 -0
- package/esm/helpers/ArrayHelper.d.ts +98 -0
- package/esm/helpers/BrowserHelper.d.ts +10 -0
- package/esm/helpers/ComponentHelper.d.ts +18 -0
- package/esm/helpers/DictionaryHelper.d.ts +18 -0
- package/esm/helpers/DomHelper.d.ts +95 -0
- package/esm/helpers/EventHelper.d.ts +30 -0
- package/esm/helpers/FileHelper.d.ts +22 -0
- package/esm/helpers/HtmlHelper.d.ts +14 -0
- package/esm/helpers/ImageHelper.d.ts +10 -0
- package/esm/helpers/JsonHelper.d.ts +35 -0
- package/esm/helpers/MathHelper.d.ts +54 -0
- package/esm/helpers/MicroHelper.d.ts +10 -0
- package/esm/helpers/MountHelper.d.ts +14 -0
- package/esm/helpers/ObjectHelper.d.ts +38 -0
- package/esm/helpers/ScriptHelper.d.ts +31 -0
- package/esm/helpers/ScrollHelper.d.ts +14 -0
- package/esm/helpers/SignHelper.d.ts +14 -0
- package/esm/helpers/StringHelper.d.ts +94 -0
- package/esm/helpers/TaskHelper.d.ts +26 -0
- package/esm/helpers/TimeHelper.d.ts +66 -0
- package/esm/helpers/TreeHelper.d.ts +54 -0
- package/esm/helpers/TypeHelper.d.ts +26 -0
- package/esm/helpers/UrlHelper.d.ts +88 -0
- package/esm/helpers/index.d.ts +25 -26
- package/esm/helpers/json-helper.d.ts +4 -12
- package/esm/helpers/object-helper.d.ts +0 -4
- package/esm/helpers/time-helper.d.ts +3 -7
- package/esm/helpers/types/TreeNodeProp.d.ts +6 -0
- package/esm/helpers/types/index.d.ts +2 -0
- package/esm/helpers/url-helper.d.ts +2 -2
- package/esm/main.d.ts +5 -4
- package/esm/plugins/index.d.ts +2 -2
- package/esm/plugins/types/IMessager.d.ts +1 -1
- package/esm/{services/types/IMessager.d.ts → plugins/types/IMessenger.d.ts} +4 -4
- package/esm/plugins/types/index.d.ts +8 -5
- package/esm/repos/SettingRepo.d.ts +11 -0
- package/esm/repos/index.d.ts +3 -0
- package/esm/services/index.d.ts +14 -1
- package/esm/servs/IServ.d.ts +6 -0
- package/esm/servs/Serv.d.ts +4 -0
- package/esm/servs/ServFactory.d.ts +11 -0
- package/esm/servs/implement/ConfigServ.d.ts +66 -0
- package/esm/servs/implement/DriverServ.d.ts +36 -0
- package/esm/servs/implement/EnvServ.d.ts +14 -0
- package/esm/servs/implement/LogServ.d.ts +19 -0
- package/esm/servs/implement/SettingServ.d.ts +42 -0
- package/esm/servs/implement/SocketServ.d.ts +38 -0
- package/esm/servs/implement/UserServ.d.ts +47 -0
- package/esm/servs/index.d.ts +15 -0
- package/esm/stores/config.d.ts +6 -10
- package/esm/stores/driver.d.ts +6 -2
- package/esm/stores/index.d.ts +2 -3
- package/esm/stores/setting.d.ts +4 -0
- package/esm/stores/user.d.ts +7 -3
- package/esm/svcs/ISvc.d.ts +6 -0
- package/esm/svcs/Svc.d.ts +4 -0
- package/esm/svcs/SvcFactory.d.ts +11 -0
- package/esm/svcs/implement/ConfigSvc.d.ts +75 -0
- package/esm/svcs/implement/DriverSvc.d.ts +36 -0
- package/esm/svcs/implement/EnvSvc.d.ts +14 -0
- package/esm/svcs/implement/LogSvc.d.ts +19 -0
- package/esm/svcs/implement/SettingSvc.d.ts +42 -0
- package/esm/svcs/implement/SocketSvc.d.ts +38 -0
- package/esm/svcs/implement/UserSvc.d.ts +47 -0
- package/esm/svcs/index.d.ts +34 -0
- package/esm/svcs/proxies/driverSvc.d.ts +18 -0
- package/esm/svcs/proxies/index.d.ts +2 -0
- package/esm/thirds/index.d.ts +8 -0
- package/esm/types/CreateOptions.d.ts +18 -0
- package/esm/types/index.d.ts +2 -0
- package/esm/utilities/EventUtility.d.ts +39 -8
- package/esm/utilities/index.d.ts +1 -0
- package/esm/utilities/types/DragEvent.d.ts +11 -0
- package/esm/utilities/types/DragOptions.d.ts +28 -0
- package/esm/utilities/types/Position.d.ts +15 -0
- package/esm/utilities/types/Range.d.ts +10 -0
- package/esm/utilities/types/Rect.d.ts +6 -0
- package/esm/utilities/types/index.d.ts +5 -0
- package/package.json +9 -8
- package/dist/vendor-@vue-l0sNRNKZ.js +0 -1
- package/dist/vendor-pinia-DVLspbiC.js +0 -310
- package/dist/vendor-vue-demi-CIhrFbpB.js +0 -17
- package/esm/services/types/IMessage.d.ts +0 -14
- package/esm/services/types/index.d.ts +0 -2
@@ -0,0 +1,66 @@
|
|
1
|
+
/**
|
2
|
+
* 时间帮助类
|
3
|
+
*/
|
4
|
+
declare class TimeHelper {
|
5
|
+
/**
|
6
|
+
* 获取相对于1970年1月1日的时间戳(ms),不同时区结果相同
|
7
|
+
*/
|
8
|
+
static getTimestamp: (value?: any) => number;
|
9
|
+
/**
|
10
|
+
* 根据字符串获取可对比的时间
|
11
|
+
*/
|
12
|
+
static getTime: (value?: any) => Date;
|
13
|
+
/**
|
14
|
+
* 格式化时间
|
15
|
+
*/
|
16
|
+
static format: (value: string, format: string) => string;
|
17
|
+
/**
|
18
|
+
* 获取当前日期时间的字符串
|
19
|
+
*/
|
20
|
+
static getDateTimeString: () => string;
|
21
|
+
/**
|
22
|
+
* 获取当前时间的字符串
|
23
|
+
*/
|
24
|
+
static getDateString: () => string;
|
25
|
+
/**
|
26
|
+
* 获取当前时间的字符串
|
27
|
+
*/
|
28
|
+
static getTimeString: () => string;
|
29
|
+
/**
|
30
|
+
* 对时间值进行时间格式化
|
31
|
+
*/
|
32
|
+
static formatSecondTime: (value: any) => string;
|
33
|
+
/**
|
34
|
+
* 对时间值进行时间格式化
|
35
|
+
*/
|
36
|
+
static formatMillisecondTime: (value: string) => string;
|
37
|
+
/**
|
38
|
+
* 格式化成24小时时间格式
|
39
|
+
*/
|
40
|
+
static formatTime: (value: any) => string;
|
41
|
+
/**
|
42
|
+
* 对时间值进行日期格式化
|
43
|
+
*/
|
44
|
+
static formatDate: (value: any) => string;
|
45
|
+
/**
|
46
|
+
* 添加天数
|
47
|
+
*/
|
48
|
+
static addDays: (value: any, days: number) => Date;
|
49
|
+
/**
|
50
|
+
* 添加月份
|
51
|
+
*/
|
52
|
+
static addMonths: (value: any, months: number) => Date;
|
53
|
+
/**
|
54
|
+
* 添加小时
|
55
|
+
*/
|
56
|
+
static addHours: (value: any, hours: number) => Date;
|
57
|
+
/**
|
58
|
+
* 判断指定时间是否是周末
|
59
|
+
*/
|
60
|
+
static isWeekend: (value: any) => boolean;
|
61
|
+
/**
|
62
|
+
* 把中国时间,转换为当地时间
|
63
|
+
*/
|
64
|
+
static localeTime: (time: any) => Date;
|
65
|
+
}
|
66
|
+
export default TimeHelper;
|
@@ -0,0 +1,54 @@
|
|
1
|
+
/**
|
2
|
+
* 树帮助类
|
3
|
+
*/
|
4
|
+
declare class TreeHelper {
|
5
|
+
/**
|
6
|
+
* 从树结构数据中,递归获取指定主键的对象
|
7
|
+
*/
|
8
|
+
static getById: (id: any, idProp: string, tree: any[], childProp: string) => any;
|
9
|
+
/**
|
10
|
+
* 树节点
|
11
|
+
*/
|
12
|
+
static getByIds: (ids: any[], idProp: string, tree: any[], childProp: string) => any[];
|
13
|
+
/**
|
14
|
+
* 找出指定层级集合中,指定对象的下一个对象
|
15
|
+
*/
|
16
|
+
static getNextById: (id: any, idProp: string, tree: any[], childProp: string) => any;
|
17
|
+
/**
|
18
|
+
* 获取兄弟节点
|
19
|
+
*/
|
20
|
+
static getSiblingsById: (id: any, idProp: string, tree: any[], childProp: string) => any;
|
21
|
+
/**
|
22
|
+
* 获取父节点
|
23
|
+
*/
|
24
|
+
static getParentById: (id: any, idProp: string, tree: any[], childProp: string) => any;
|
25
|
+
/**
|
26
|
+
* 从树结构数据中,递归获取指定主键的父元素集合
|
27
|
+
*/
|
28
|
+
static getParentsById: (id: any, idProp: string, tree: any[], childProp: string, hasSelf?: boolean) => any[];
|
29
|
+
/**
|
30
|
+
* 获取当前节点的所有孩子节点的集合
|
31
|
+
*/
|
32
|
+
static getChildrenById: (id: any, idProp: string, tree: any[], childProp: string, hasSelf?: boolean) => any[];
|
33
|
+
/**
|
34
|
+
* 获取当前节点的所有孩子节点的集合
|
35
|
+
*/
|
36
|
+
static getChildren: (element: any, childProp: string, hasSelf?: boolean) => any[];
|
37
|
+
/**
|
38
|
+
* 搜索指定文本的树结构
|
39
|
+
*/
|
40
|
+
static searchTree: (keywords: string, tree: any[], childProp: string, searchProps: any) => any[];
|
41
|
+
/**
|
42
|
+
* 删除指定子元素
|
43
|
+
*/
|
44
|
+
static removeById: (id: any, idProp: string, tree: any[], childProp: string) => void;
|
45
|
+
/**
|
46
|
+
* 获取树结构扁平化后的节点信息
|
47
|
+
*/
|
48
|
+
static getFlat: (tree: any[], childProp: string) => any[];
|
49
|
+
/**
|
50
|
+
* 对树结点的数据进行重新映射,映射得到新的Tree数组
|
51
|
+
*/
|
52
|
+
static map: (tree: any[], prevChildProp: string, childProp: string, fun: Function) => any[];
|
53
|
+
}
|
54
|
+
export default TreeHelper;
|
@@ -0,0 +1,26 @@
|
|
1
|
+
/**
|
2
|
+
* 类型帮助类
|
3
|
+
*/
|
4
|
+
declare class TypeHelper {
|
5
|
+
/**
|
6
|
+
* 判断输入类型是否是字符串类型 null -> false
|
7
|
+
*/
|
8
|
+
static isString: (input: any) => boolean;
|
9
|
+
/**
|
10
|
+
* 判断输入类型是否是Object类型
|
11
|
+
*/
|
12
|
+
static isObject: (input: any) => boolean;
|
13
|
+
/**
|
14
|
+
* 判断输入类型是否是Array类型
|
15
|
+
*/
|
16
|
+
static isArray: (input: any) => boolean;
|
17
|
+
/**
|
18
|
+
* 判断输入类型是否是Number类型,null -> false
|
19
|
+
*/
|
20
|
+
static isNumber: (input: any) => boolean;
|
21
|
+
/**
|
22
|
+
* 判断输入类型是否是isBoolean类型
|
23
|
+
*/
|
24
|
+
static isBoolean: (input: any) => boolean;
|
25
|
+
}
|
26
|
+
export default TypeHelper;
|
@@ -0,0 +1,88 @@
|
|
1
|
+
/**
|
2
|
+
* Url帮助类
|
3
|
+
*/
|
4
|
+
declare class UrlHelper {
|
5
|
+
/**
|
6
|
+
* 获取指定地址路由对象
|
7
|
+
*/
|
8
|
+
static getToRoute(url: string, withReturnUrl?: boolean): any;
|
9
|
+
/**
|
10
|
+
* 获取要跳转的Url地址信息,自动涵盖后退地址
|
11
|
+
*/
|
12
|
+
static getToUrl(url: string, withReturnUrl?: boolean): string;
|
13
|
+
/**
|
14
|
+
* 获取菜单参数
|
15
|
+
*/
|
16
|
+
static getM(url: string): any;
|
17
|
+
/**
|
18
|
+
* 获取后退地址路由
|
19
|
+
*/
|
20
|
+
static getBackRoute(): any;
|
21
|
+
/**
|
22
|
+
* 获取要后退的地址URL
|
23
|
+
*/
|
24
|
+
static getBackUrl(): string;
|
25
|
+
/**
|
26
|
+
* 获取指定地址的路由对象,自动合并qs,并解码
|
27
|
+
*/
|
28
|
+
static getRoute(url: string, queryObj?: object): any;
|
29
|
+
/**
|
30
|
+
* 处理实体,得到url query参数形式
|
31
|
+
* 如:app=Tool&compare[language]=json&compare[sql]=App%3D%27Tool%27+and+[Table]+like+%27Ctl_%25%27+order+by+[Table],+Name
|
32
|
+
*/
|
33
|
+
static getQuery(value: any): string;
|
34
|
+
/**
|
35
|
+
* 处理键值对的值
|
36
|
+
*/
|
37
|
+
private static handleQueryValue;
|
38
|
+
/**
|
39
|
+
* 自动根据后面路径,决定是否要合并Url
|
40
|
+
*/
|
41
|
+
static concatUrl: (url: string, path: string) => string;
|
42
|
+
/**
|
43
|
+
* 合并路径和查询对象(自动编码,并支持覆盖现有参数),得到完整URL地址,并会省略默认值
|
44
|
+
* ? 对url参数不编码,只对 queryObj 参数编码,防止用户的参数被改成编码形式
|
45
|
+
* ? 目前,对Url参数对象和目标对象都编码,因为源对象属性是经过解码的
|
46
|
+
*/
|
47
|
+
static getUrl: (url: string, params?: any) => string;
|
48
|
+
/**
|
49
|
+
* 获取超链接配置对象
|
50
|
+
*/
|
51
|
+
static getAnchor: (url: string, params?: any) => {
|
52
|
+
href: any;
|
53
|
+
target: any;
|
54
|
+
};
|
55
|
+
/**
|
56
|
+
* 从Url中提取路径
|
57
|
+
*/
|
58
|
+
static getPath(url: string): string;
|
59
|
+
/**
|
60
|
+
* 获取path中最后一个片段信息
|
61
|
+
*/
|
62
|
+
static getLastSegment(url: string): string;
|
63
|
+
/**
|
64
|
+
* 获取地址中的查询参数
|
65
|
+
*/
|
66
|
+
static getQueryParam(url: string, key: string): string;
|
67
|
+
/**
|
68
|
+
* 从Url中提取查询对象
|
69
|
+
*/
|
70
|
+
static deserialize(url: string): object;
|
71
|
+
/**
|
72
|
+
* 把查询字符串转换成对象(自动解码成源数据)
|
73
|
+
*/
|
74
|
+
static deserializeQs(qs: string, decode?: boolean): any;
|
75
|
+
/**
|
76
|
+
* 把对象转换成查询字符串,自动编码
|
77
|
+
*/
|
78
|
+
static serialize(obj: object, encoding?: boolean): string;
|
79
|
+
/**
|
80
|
+
* URL编码
|
81
|
+
*/
|
82
|
+
static encode(value: string): string;
|
83
|
+
/**
|
84
|
+
* 是否是http或https开头的地址
|
85
|
+
*/
|
86
|
+
static httpOrHttps(url: string): boolean;
|
87
|
+
}
|
88
|
+
export default UrlHelper;
|
package/esm/helpers/index.d.ts
CHANGED
@@ -1,26 +1,25 @@
|
|
1
|
-
import ComponentHelper from './
|
2
|
-
import ArrayHelper from "./
|
3
|
-
import
|
4
|
-
import
|
5
|
-
import
|
6
|
-
import
|
7
|
-
import
|
8
|
-
import
|
9
|
-
import
|
10
|
-
import
|
11
|
-
import
|
12
|
-
import
|
13
|
-
import
|
14
|
-
import
|
15
|
-
import
|
16
|
-
import
|
17
|
-
import
|
18
|
-
import
|
19
|
-
import
|
20
|
-
import
|
21
|
-
import
|
22
|
-
import
|
23
|
-
import
|
24
|
-
import
|
25
|
-
|
26
|
-
export { ComponentHelper, ArrayHelper, CookieHelper, DomHelper, DictionaryHelper, EventHelper, FileHelper, HtmlHelper, ImageHelper, MathHelper, MountHelper, ObjectHelper, MicroHelper, StringHelper, ScriptHelper, TaskHelper, TypeHelper, TimeHelper, TreeHelper, StorageHelper, ScrollHelper, JsonHelper, I18nHelper, UrlHelper, SignHelper };
|
1
|
+
import ComponentHelper from './ComponentHelper';
|
2
|
+
import ArrayHelper from "./ArrayHelper";
|
3
|
+
import DomHelper from "./DomHelper";
|
4
|
+
import DictionaryHelper from "./DictionaryHelper";
|
5
|
+
import EventHelper from "./EventHelper";
|
6
|
+
import FileHelper from "./FileHelper";
|
7
|
+
import HtmlHelper from "./HtmlHelper";
|
8
|
+
import ImageHelper from "./ImageHelper";
|
9
|
+
import MathHelper from "./MathHelper";
|
10
|
+
import MicroHelper from "./MicroHelper";
|
11
|
+
import MountHelper from "./MountHelper";
|
12
|
+
import ObjectHelper from "./ObjectHelper";
|
13
|
+
import StringHelper from "./StringHelper";
|
14
|
+
import ScriptHelper from "./ScriptHelper";
|
15
|
+
import TaskHelper from "./TaskHelper";
|
16
|
+
import TypeHelper from "./TypeHelper";
|
17
|
+
import TimeHelper from "./TimeHelper";
|
18
|
+
import TreeHelper from "./TreeHelper";
|
19
|
+
import StorageHelper from "../drivers/providers/implements/StorageHelper";
|
20
|
+
import ScrollHelper from "./ScrollHelper";
|
21
|
+
import JsonHelper from "./JsonHelper";
|
22
|
+
import BrowserHelper from "./BrowserHelper";
|
23
|
+
import UrlHelper from "./UrlHelper";
|
24
|
+
import SignHelper from "./SignHelper";
|
25
|
+
export { ComponentHelper, ArrayHelper, DomHelper, DictionaryHelper, EventHelper, FileHelper, HtmlHelper, ImageHelper, MathHelper, MountHelper, ObjectHelper, MicroHelper, StringHelper, ScriptHelper, TaskHelper, TypeHelper, TimeHelper, TreeHelper, StorageHelper, ScrollHelper, JsonHelper, BrowserHelper, UrlHelper, SignHelper };
|
@@ -8,21 +8,17 @@ declare type Prop = {
|
|
8
8
|
*/
|
9
9
|
declare class JsonHelper {
|
10
10
|
/**
|
11
|
-
*
|
11
|
+
* 从树集合构建出Json对象
|
12
12
|
*/
|
13
|
-
static
|
13
|
+
static buildObject(tree: any[], childProp: string, fun: (node: any) => Prop): string;
|
14
14
|
/**
|
15
|
-
*
|
15
|
+
* 把字符串格式化为Json字符串
|
16
16
|
*/
|
17
|
-
static
|
17
|
+
static stringify(value: string): string;
|
18
18
|
/**
|
19
19
|
* 把字符串格式化为Json字符串
|
20
20
|
*/
|
21
21
|
static stringifyString(value: string): string;
|
22
|
-
/**
|
23
|
-
* 反序列化成json对象
|
24
|
-
*/
|
25
|
-
static parse(value: string): any;
|
26
22
|
/**
|
27
23
|
* 根据props中的.自动分割得到属性值
|
28
24
|
*/
|
@@ -31,9 +27,5 @@ declare class JsonHelper {
|
|
31
27
|
* 把json字符串合并到目标对象上
|
32
28
|
*/
|
33
29
|
static mergeTo(target: any, from: string): void;
|
34
|
-
/**
|
35
|
-
* 从树集合构建出Json对象
|
36
|
-
*/
|
37
|
-
static buildObject(tree: any[], childProp: string, fun: (node: any) => Prop): string;
|
38
30
|
}
|
39
31
|
export default JsonHelper;
|
@@ -45,15 +45,11 @@ declare class TimeHelper {
|
|
45
45
|
/**
|
46
46
|
* 添加天数
|
47
47
|
*/
|
48
|
-
static addDays: (value: any, days: number) =>
|
48
|
+
static addDays: (value: any, days: number) => string;
|
49
49
|
/**
|
50
50
|
* 添加月份
|
51
51
|
*/
|
52
|
-
static addMonths: (value: any, months: number) =>
|
53
|
-
/**
|
54
|
-
* 添加小时
|
55
|
-
*/
|
56
|
-
static addHours: (value: any, hours: number) => Date;
|
52
|
+
static addMonths: (value: any, months: number) => string;
|
57
53
|
/**
|
58
54
|
* 判断指定时间是否是周末
|
59
55
|
*/
|
@@ -61,6 +57,6 @@ declare class TimeHelper {
|
|
61
57
|
/**
|
62
58
|
* 把中国时间,转换为当地时间
|
63
59
|
*/
|
64
|
-
static localeTime: (time: any) =>
|
60
|
+
static localeTime: (time: any) => string;
|
65
61
|
}
|
66
62
|
export default TimeHelper;
|
@@ -83,11 +83,11 @@ declare class UrlHelper {
|
|
83
83
|
/**
|
84
84
|
* 把指定对象转换成base64字符串
|
85
85
|
*/
|
86
|
-
static base64(obj: object):
|
86
|
+
static base64(obj: object): string;
|
87
87
|
/**
|
88
88
|
* 把指定base64字符串解析为原对象
|
89
89
|
*/
|
90
|
-
static base64Decode(val: string):
|
90
|
+
static base64Decode(val: string): any;
|
91
91
|
/**
|
92
92
|
* 是否是http或https开头的地址
|
93
93
|
*/
|
package/esm/main.d.ts
CHANGED
@@ -1,14 +1,15 @@
|
|
1
|
-
import {
|
1
|
+
import { IMessenger } from "./plugins";
|
2
2
|
import "./styles/index.scss";
|
3
3
|
export * from "./coms";
|
4
4
|
export * from "./drivers";
|
5
5
|
export * from "./helpers";
|
6
6
|
export * from "./plugins";
|
7
|
-
export * from "./
|
8
|
-
export * from "./
|
7
|
+
export * from "./repos";
|
8
|
+
export * from "./svcs";
|
9
|
+
export * from "./types";
|
9
10
|
export * from "./utilities";
|
10
11
|
/**
|
11
12
|
* 初始化前端基础框架
|
12
13
|
*/
|
13
|
-
declare let createFe: (
|
14
|
+
declare let createFe: (messenger: IMessenger) => Promise<void>;
|
14
15
|
export { createFe };
|
package/esm/plugins/index.d.ts
CHANGED
@@ -4,6 +4,6 @@ import moment from "moment";
|
|
4
4
|
/**
|
5
5
|
* 异步加载echarts
|
6
6
|
*/
|
7
|
-
|
7
|
+
declare let loadEcharts: () => Promise<unknown>;
|
8
8
|
export * from "./types";
|
9
|
-
export { loader, Monaco, moment };
|
9
|
+
export { loader, Monaco, moment, loadEcharts };
|
@@ -1,7 +1,7 @@
|
|
1
1
|
/**
|
2
2
|
* 消息提示接口,下游自己定义
|
3
3
|
*/
|
4
|
-
interface
|
4
|
+
interface IMessenger {
|
5
5
|
/**
|
6
6
|
* 显示全局成功消息
|
7
7
|
*/
|
@@ -9,7 +9,7 @@ interface IMessager {
|
|
9
9
|
/**
|
10
10
|
* 显示全局警告消息
|
11
11
|
*/
|
12
|
-
warning(message: string): void;
|
12
|
+
warning(message: string | number): void;
|
13
13
|
/**
|
14
14
|
* 显示全局信息消息
|
15
15
|
*/
|
@@ -21,7 +21,7 @@ interface IMessager {
|
|
21
21
|
/**
|
22
22
|
* 显示全局错误消息
|
23
23
|
*/
|
24
|
-
confirm(title: string, message: string, options?: any):
|
24
|
+
confirm(title: string, message: string, options?: any): Promise<any>;
|
25
25
|
/**
|
26
26
|
* 显示警告框
|
27
27
|
*/
|
@@ -31,4 +31,4 @@ interface IMessager {
|
|
31
31
|
*/
|
32
32
|
notify(title: string, message: string, type: string): void;
|
33
33
|
}
|
34
|
-
export default
|
34
|
+
export default IMessenger;
|
@@ -1,7 +1,10 @@
|
|
1
|
-
import type
|
2
|
-
declare let messager: IMessager;
|
1
|
+
import type IMessenger from "./IMessenger";
|
3
2
|
/**
|
4
|
-
*
|
3
|
+
* 初始化消息对象,保证后续更新能够被同步更新
|
5
4
|
*/
|
6
|
-
declare let
|
7
|
-
|
5
|
+
declare let messenger: IMessenger;
|
6
|
+
/**
|
7
|
+
* 设置消息对象
|
8
|
+
*/
|
9
|
+
declare let initMessenger: (msgr: IMessenger) => void;
|
10
|
+
export { IMessenger, messenger, initMessenger };
|
package/esm/services/index.d.ts
CHANGED
@@ -1,2 +1,15 @@
|
|
1
1
|
import SettingService from "./SettingService";
|
2
|
-
|
2
|
+
/**
|
3
|
+
* 消息提示接口,下游自己定义
|
4
|
+
*/
|
5
|
+
interface IMessageService {
|
6
|
+
/**
|
7
|
+
* 成功消息提示
|
8
|
+
*/
|
9
|
+
success(message: string): void;
|
10
|
+
/**
|
11
|
+
* 错误消息提示
|
12
|
+
*/
|
13
|
+
error(message: string): void;
|
14
|
+
}
|
15
|
+
export { IMessageService, SettingService };
|
@@ -0,0 +1,66 @@
|
|
1
|
+
/**
|
2
|
+
* 不一定跟用户相关,此时如果使用配置仓储,使用的是配置文件的配置,非接口配置
|
3
|
+
*/
|
4
|
+
declare class ConfigServ {
|
5
|
+
/**
|
6
|
+
* 默认背景
|
7
|
+
*/
|
8
|
+
background: string;
|
9
|
+
/**
|
10
|
+
* 当前主题
|
11
|
+
*/
|
12
|
+
theme: string;
|
13
|
+
/**
|
14
|
+
* 当前布局方式
|
15
|
+
*/
|
16
|
+
layout: string;
|
17
|
+
/**
|
18
|
+
* 当前语言
|
19
|
+
*/
|
20
|
+
language: string;
|
21
|
+
/**
|
22
|
+
* 字体
|
23
|
+
*/
|
24
|
+
font: string;
|
25
|
+
/**
|
26
|
+
* 文件布局方式
|
27
|
+
*/
|
28
|
+
fileLayout: string;
|
29
|
+
editor: {
|
30
|
+
schemas: any[];
|
31
|
+
completions: {};
|
32
|
+
};
|
33
|
+
/**
|
34
|
+
* 初始化配置值(不一定跟登录用户相关,这也是单独分离的好处)
|
35
|
+
*/
|
36
|
+
init(configs: any[]): void;
|
37
|
+
/**
|
38
|
+
* 尝试添加架构
|
39
|
+
*/
|
40
|
+
tryAddSchema(uri: string, fileMatch: string, schema: object): void;
|
41
|
+
/**
|
42
|
+
* 获取本地配置
|
43
|
+
*/
|
44
|
+
getLocalConfig(type: string): Promise<any>;
|
45
|
+
/**
|
46
|
+
* 设置背景
|
47
|
+
*/
|
48
|
+
setBackground(background: string): void;
|
49
|
+
/**
|
50
|
+
* 加载用户配置
|
51
|
+
*/
|
52
|
+
loadConfig(type: string, cached?: boolean): Promise<any>;
|
53
|
+
/**
|
54
|
+
* 全量保存用户配置
|
55
|
+
*/
|
56
|
+
saveConfig(type: string, data: any, cached?: boolean): Promise<boolean>;
|
57
|
+
/**
|
58
|
+
* 部分保存用户配置
|
59
|
+
*/
|
60
|
+
patchConfig(type: string, pairs: any): Promise<boolean>;
|
61
|
+
/**
|
62
|
+
* 获取当前语言
|
63
|
+
*/
|
64
|
+
getLanguage(): string;
|
65
|
+
}
|
66
|
+
export default ConfigServ;
|
@@ -0,0 +1,36 @@
|
|
1
|
+
/**
|
2
|
+
* 使用驱动仓储
|
3
|
+
*/
|
4
|
+
declare class DriverServ {
|
5
|
+
/**
|
6
|
+
* 加载完毕状态记录
|
7
|
+
*/
|
8
|
+
loaded: {
|
9
|
+
apps: boolean;
|
10
|
+
envs: boolean;
|
11
|
+
};
|
12
|
+
/**
|
13
|
+
* 是否加载中状态,用于并发场景 防止重复拉取接口
|
14
|
+
*/
|
15
|
+
loading: {
|
16
|
+
apps: boolean;
|
17
|
+
envs: boolean;
|
18
|
+
};
|
19
|
+
/**
|
20
|
+
* 应用集合,存储到Store中,防止每一个Driver实例重复加载
|
21
|
+
*/
|
22
|
+
apps: any[];
|
23
|
+
/**
|
24
|
+
* 环境集合,存储到Store中,防止每一个Driver实例重复加载
|
25
|
+
*/
|
26
|
+
envs: any[];
|
27
|
+
/**
|
28
|
+
* 加载应用选项
|
29
|
+
*/
|
30
|
+
loadApps(reload?: boolean): Promise<void>;
|
31
|
+
/**
|
32
|
+
* 加载环境选项
|
33
|
+
*/
|
34
|
+
loadEnvs(reload?: boolean): Promise<void>;
|
35
|
+
}
|
36
|
+
export default DriverServ;
|