halo-fe 1.0.27 → 1.0.29
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/main.js +733 -553
- package/esm/coms/controls/@types/CodeProps.d.ts +1 -1
- package/esm/coms/controls/Code.vue.d.ts +1 -1
- package/esm/coms/pagers/index.d.ts +1 -1
- package/esm/drivers/builders/BuilderFactory.d.ts +1 -0
- package/esm/drivers/cdns/Cdn.d.ts +6 -6
- package/esm/drivers/cdns/CdnFactory.d.ts +1 -0
- package/esm/drivers/encoders/Encoder.d.ts +1 -1
- package/esm/drivers/encoders/EncoderFactory.d.ts +1 -0
- package/esm/drivers/excels/ExcelFactory.d.ts +1 -0
- package/esm/drivers/explainers/ExplainerFactory.d.ts +1 -0
- package/esm/drivers/features/Feature.d.ts +9 -0
- package/esm/drivers/features/FeatureFactory.d.ts +1 -0
- package/esm/drivers/features/implements/ExpressionFeature.d.ts +2 -3
- package/esm/drivers/features/implements/I18NFeature.d.ts +2 -3
- package/esm/drivers/features/implements/SortFeature.d.ts +2 -3
- package/esm/drivers/hashers/HasherFactory.d.ts +1 -0
- package/esm/drivers/https/HttpFactory.d.ts +1 -0
- package/esm/drivers/https/IHttp.d.ts +1 -1
- package/esm/drivers/i18ns/I18nFactory.d.ts +1 -0
- package/esm/drivers/messengers/MessengerFactory.d.ts +1 -0
- package/esm/drivers/providers/ProviderFactory.d.ts +1 -0
- package/esm/drivers/providers/implements/CookieProvider.d.ts +2 -1
- package/esm/drivers/providers/implements/IndexedDbProvider.d.ts +2 -2
- package/esm/drivers/providers/implements/StorageProvider.d.ts +2 -1
- package/esm/drivers/signers/SignerFactory.d.ts +1 -0
- package/esm/drivers/sockets/Socket.d.ts +15 -1
- package/esm/drivers/sockets/SocketFactory.d.ts +1 -0
- package/esm/drivers/ssos/SsoFactory.d.ts +1 -0
- package/esm/drivers/tasks/TaskFactory.d.ts +1 -0
- package/esm/drivers/templates/TemplateFactory.d.ts +1 -0
- package/esm/drivers/util/UtilFactory.d.ts +2 -2
- package/esm/drivers/util/implements/JsonUtil.d.ts +9 -1
- package/esm/drivers/util/implements/ObjectUtil.d.ts +20 -0
- package/esm/drivers/util/index.d.ts +1 -2
- package/esm/drivers/utilities/UtilityFactory.d.ts +1 -0
- package/esm/drivers/videos/VideoFactory.d.ts +1 -0
- package/esm/drivers/voices/VoiceFactory.d.ts +1 -0
- package/esm/factory/Factory.d.ts +11 -3
- package/esm/factory/IFactory.d.ts +13 -4
- package/package.json +1 -1
@@ -1,2 +1,2 @@
|
|
1
|
-
import HaPager from "Index.vue";
|
1
|
+
import HaPager from "./Index.vue";
|
2
2
|
export { HaPager };
|
@@ -10,14 +10,14 @@ declare abstract class Cdn implements ICdn {
|
|
10
10
|
*/
|
11
11
|
task: ITask;
|
12
12
|
openAsync(conn: string): Promise<void>;
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
13
|
+
getCrypto(): Promise<any>;
|
14
|
+
getECharts(): Promise<any>;
|
15
|
+
getElementPlus(): Promise<any>;
|
16
|
+
getFortAwesome(): Promise<any>;
|
17
17
|
getMonaco(baseUrl?: string): Promise<any>;
|
18
18
|
getQuill(): Promise<any>;
|
19
|
-
|
20
|
-
|
19
|
+
getWeiXin(): Promise<any>;
|
20
|
+
getXlsx(): Promise<any>;
|
21
21
|
/**
|
22
22
|
* 使用并发限制顺序加载资源,并防止monaco-editor的define函数冲突
|
23
23
|
*/
|
@@ -0,0 +1,9 @@
|
|
1
|
+
import IFeature from "./IFeature";
|
2
|
+
declare abstract class Feature implements IFeature {
|
3
|
+
type: string;
|
4
|
+
openAsync(conn?: string): Promise<void>;
|
5
|
+
abstract add(table: any, field: any, data: object, row: object): void;
|
6
|
+
abstract copy(table: any, field: any, data: object): void;
|
7
|
+
abstract insert(table: any, field: any, data: object, selectedRow: object, row: object): void;
|
8
|
+
}
|
9
|
+
export default Feature;
|
@@ -1,10 +1,9 @@
|
|
1
|
-
import
|
1
|
+
import Feature from "../Feature";
|
2
2
|
/**
|
3
3
|
* 表达式特征
|
4
4
|
*/
|
5
|
-
declare class ExpressionFeature
|
5
|
+
declare class ExpressionFeature extends Feature {
|
6
6
|
type: string;
|
7
|
-
openAsync(param: string): void;
|
8
7
|
add(table: any, field: any, data: {}, row: {}): void;
|
9
8
|
insert(table: any, field: any, data: object, selectedRow: object, row: object): void;
|
10
9
|
copy(table: any, field: any, data: object): void;
|
@@ -1,10 +1,9 @@
|
|
1
|
-
import
|
1
|
+
import Feature from "../Feature";
|
2
2
|
/**
|
3
3
|
* 多语言特征
|
4
4
|
*/
|
5
|
-
declare class I18NFeature
|
5
|
+
declare class I18NFeature extends Feature {
|
6
6
|
type: string;
|
7
|
-
openAsync(param: string): void;
|
8
7
|
add(table: any, field: any, data: {}, row: {}): void;
|
9
8
|
insert(table: any, field: any, data: object, selectedRow: object, row: object): void;
|
10
9
|
copy(table: any, field: any, data: object): void;
|
@@ -1,10 +1,9 @@
|
|
1
|
-
import
|
1
|
+
import Feature from "../Feature";
|
2
2
|
/**
|
3
3
|
* 排序特征
|
4
4
|
*/
|
5
|
-
declare class SortFeature
|
5
|
+
declare class SortFeature extends Feature {
|
6
6
|
type: string;
|
7
|
-
openAsync(param: string): void;
|
8
7
|
add(table: any, field: any, data: object, row: object): void;
|
9
8
|
insert(table: any, field: any, data: object, selectedRow: object, row: object): void;
|
10
9
|
copy(table: any, field: any, data: object): void;
|
@@ -4,7 +4,8 @@ import Provider from "../Provider";
|
|
4
4
|
*/
|
5
5
|
declare class CookieProvider extends Provider {
|
6
6
|
type: string;
|
7
|
-
openAsync(conn: string): Promise<
|
7
|
+
openAsync(conn: string): Promise<void>;
|
8
|
+
getKeysAsync(table: string): Promise<any[]>;
|
8
9
|
createAsync(kind: string): Promise<any>;
|
9
10
|
deleteAsync(kind: string, key: any): Promise<any>;
|
10
11
|
getAsync(kind: string, key: any): Promise<any>;
|
@@ -19,7 +19,7 @@ declare class IndexedDbProvider extends Provider {
|
|
19
19
|
/**
|
20
20
|
* 进行数据库初始化 或 从现有数据库中得到最新版本号(数据库首次初始化和open是版本号升级时,会触发升级事件)
|
21
21
|
*/
|
22
|
-
openAsync(conn: string): Promise<
|
22
|
+
openAsync(conn: string): Promise<void>;
|
23
23
|
/**
|
24
24
|
* 保证创建存储Store
|
25
25
|
*/
|
@@ -31,7 +31,7 @@ declare class IndexedDbProvider extends Provider {
|
|
31
31
|
/**
|
32
32
|
* 开启事务
|
33
33
|
*/
|
34
|
-
openTransAsync(table: string, mode:
|
34
|
+
openTransAsync(table: string, mode: IDBTransactionMode, db: IDBDatabase): Promise<IDBTransaction>;
|
35
35
|
getEntity<T>(table: string, id: any): Promise<T>;
|
36
36
|
/**
|
37
37
|
* 查询数据
|
@@ -4,8 +4,9 @@ import Provider from "../Provider";
|
|
4
4
|
*/
|
5
5
|
declare class StorageProvider extends Provider {
|
6
6
|
type: string;
|
7
|
-
openAsync(conn: string): Promise<
|
7
|
+
openAsync(conn: string): Promise<void>;
|
8
8
|
createAsync(kind: string): Promise<any>;
|
9
|
+
getKeysAsync(table: string): Promise<any[]>;
|
9
10
|
getAsync(kind: string, key: any): Promise<any>;
|
10
11
|
getEntity<T>(kind: string, key: string): Promise<T>;
|
11
12
|
insertAsync(kind: string, key: any, entity: any): Promise<any>;
|
@@ -3,15 +3,29 @@ import { SubscribedWindow } from "./@types";
|
|
3
3
|
/**
|
4
4
|
* Socket基类
|
5
5
|
*/
|
6
|
-
declare class Socket implements ISocket {
|
6
|
+
declare abstract class Socket implements ISocket {
|
7
|
+
/**
|
8
|
+
* 类型
|
9
|
+
*/
|
10
|
+
type: string;
|
11
|
+
/**
|
12
|
+
* 是否已连接(空表示不需连接)
|
13
|
+
*/
|
14
|
+
connected: boolean;
|
15
|
+
/**
|
16
|
+
* Socket消息处理程序
|
17
|
+
*/
|
18
|
+
handler: (event: MessageEvent) => void;
|
7
19
|
/**
|
8
20
|
* 已订阅的消息类型列表
|
9
21
|
*/
|
10
22
|
subscribed: SubscribedWindow;
|
11
23
|
openAsync(conn?: string): Promise<void>;
|
24
|
+
abstract connect(): Promise<void>;
|
12
25
|
subscribe(win: string, kind: string, type: string | string[]): Promise<any>;
|
13
26
|
resubscribe(): Promise<void>;
|
14
27
|
unsubscribe(win: string): Promise<any>;
|
15
28
|
abstract send(data: any): void;
|
29
|
+
dispose(): void;
|
16
30
|
}
|
17
31
|
export default Socket;
|
@@ -1,10 +1,11 @@
|
|
1
1
|
import Factory from "../../factory/Factory";
|
2
2
|
import IUtil from "./IUtil";
|
3
|
-
import { ArrayUtil, BrowserUtil, ComponentUtil, DictionaryUtil, DomUtil, EventUtil, FileUtil, HtmlUtil, ImageUtil, JsonUtil, MathUtil, MicroUtil, MountUtil, ObjectUtil, ScrollUtil, SignUtil, StringUtil, TaskUtil, TimeUtil, TreeUtil,
|
3
|
+
import { ArrayUtil, BrowserUtil, ComponentUtil, DictionaryUtil, DomUtil, EventUtil, FileUtil, HtmlUtil, ImageUtil, JsonUtil, MathUtil, MicroUtil, MountUtil, ObjectUtil, ScrollUtil, SignUtil, StringUtil, TaskUtil, TimeUtil, TreeUtil, UrlUtil } from "./";
|
4
4
|
/**
|
5
5
|
* 帮助类工厂
|
6
6
|
*/
|
7
7
|
declare class UtilFactory extends Factory<IUtil> {
|
8
|
+
type: string;
|
8
9
|
open(): void;
|
9
10
|
get array(): ArrayUtil;
|
10
11
|
get browser(): BrowserUtil;
|
@@ -23,7 +24,6 @@ declare class UtilFactory extends Factory<IUtil> {
|
|
23
24
|
get scroll(): ScrollUtil;
|
24
25
|
get string(): StringUtil;
|
25
26
|
get task(): TaskUtil;
|
26
|
-
get type(): TypeUtil;
|
27
27
|
get time(): TimeUtil;
|
28
28
|
get tree(): TreeUtil;
|
29
29
|
get url(): UrlUtil;
|
@@ -19,9 +19,17 @@ declare class JsonUtil extends Util {
|
|
19
19
|
*/
|
20
20
|
autoDeserialize(value: string): any;
|
21
21
|
/**
|
22
|
-
*
|
22
|
+
* 反序列化为json对象,异常返回null
|
23
23
|
*/
|
24
24
|
deserialize(value: string): any;
|
25
|
+
/**
|
26
|
+
* 尝试反序列化成json对象
|
27
|
+
* 异常时,结果返回异常消息对象
|
28
|
+
*/
|
29
|
+
tryDeserialize(value: string, result: any | {
|
30
|
+
message: string;
|
31
|
+
stack: string;
|
32
|
+
}): boolean;
|
25
33
|
/**
|
26
34
|
* 判断指定值,是否包含key
|
27
35
|
*/
|
@@ -4,6 +4,26 @@ import Util from "../Util";
|
|
4
4
|
*/
|
5
5
|
declare class ObjectUtil extends Util {
|
6
6
|
type: string;
|
7
|
+
/**
|
8
|
+
* 判断输入类型是否是字符串类型 null -> false
|
9
|
+
*/
|
10
|
+
isString: (input: any) => boolean;
|
11
|
+
/**
|
12
|
+
* 判断输入类型是否是Object类型
|
13
|
+
*/
|
14
|
+
isObject: (input: any) => boolean;
|
15
|
+
/**
|
16
|
+
* 判断输入类型是否是Array类型
|
17
|
+
*/
|
18
|
+
isArray: (input: any) => boolean;
|
19
|
+
/**
|
20
|
+
* 判断输入类型是否是Number类型,null -> false
|
21
|
+
*/
|
22
|
+
isNumber: (input: any) => boolean;
|
23
|
+
/**
|
24
|
+
* 判断输入类型是否是isBoolean类型
|
25
|
+
*/
|
26
|
+
isBoolean: (input: any) => boolean;
|
7
27
|
/**
|
8
28
|
* 净化对象,只清除默认值属性
|
9
29
|
*/
|
@@ -13,7 +13,6 @@ import MountUtil from "./implements/MountUtil";
|
|
13
13
|
import ObjectUtil from "./implements/ObjectUtil";
|
14
14
|
import StringUtil from "./implements/StringUtil";
|
15
15
|
import TaskUtil from "./implements/TaskUtil";
|
16
|
-
import TypeUtil from "./implements/TypeUtil";
|
17
16
|
import TimeUtil from "./implements/TimeUtil";
|
18
17
|
import TreeUtil from "./implements/TreeUtil";
|
19
18
|
import ScrollUtil from "./implements/ScrollUtil";
|
@@ -21,4 +20,4 @@ import JsonUtil from "./implements/JsonUtil";
|
|
21
20
|
import BrowserUtil from "./implements/BrowserUtil";
|
22
21
|
import UrlUtil from "./implements/UrlUtil";
|
23
22
|
import SignUtil from "./implements/SignUtil";
|
24
|
-
export { UtilFactory, ArrayUtil, ComponentUtil, DomUtil, DictionaryUtil, EventUtil, FileUtil, HtmlUtil, ImageUtil, MathUtil, MountUtil, ObjectUtil, MicroUtil, StringUtil, TaskUtil,
|
23
|
+
export { UtilFactory, ArrayUtil, ComponentUtil, DomUtil, DictionaryUtil, EventUtil, FileUtil, HtmlUtil, ImageUtil, MathUtil, MountUtil, ObjectUtil, MicroUtil, StringUtil, TaskUtil, TimeUtil, TreeUtil, ScrollUtil, JsonUtil, BrowserUtil, UrlUtil, SignUtil };
|
package/esm/factory/Factory.d.ts
CHANGED
@@ -6,16 +6,24 @@ import { Ref } from "../plugins";
|
|
6
6
|
*/
|
7
7
|
declare abstract class Factory<T extends IDriver> implements IFactory<T> {
|
8
8
|
/**
|
9
|
-
*
|
9
|
+
* 工厂类型,可用于异常提示
|
10
10
|
*/
|
11
|
-
|
11
|
+
type: string;
|
12
|
+
/**
|
13
|
+
* 当前驱动子类型名称和子类型的映射关系,用于快速实例化
|
14
|
+
*/
|
15
|
+
types: {
|
16
|
+
[name: string]: any;
|
17
|
+
};
|
12
18
|
/**
|
13
19
|
* 实例缓存集合
|
14
20
|
* 或者使用:Record<string, string>
|
15
21
|
*/
|
16
22
|
private created;
|
17
23
|
open(): void;
|
18
|
-
register(
|
24
|
+
register(types: {
|
25
|
+
[name: string]: any;
|
26
|
+
}): void;
|
19
27
|
/**
|
20
28
|
* 根据主键创建并开启驱动,并返回加载后的驱动信息
|
21
29
|
*/
|
@@ -4,21 +4,30 @@ import { Ref } from "../plugins";
|
|
4
4
|
*/
|
5
5
|
interface IFactory<T> {
|
6
6
|
/**
|
7
|
-
*
|
7
|
+
* 工厂类型,可用于异常提示
|
8
8
|
*/
|
9
|
-
|
9
|
+
type: string;
|
10
|
+
/**
|
11
|
+
* 当前驱动所有类型,可根据key快速实例化
|
12
|
+
*/
|
13
|
+
get types(): {
|
14
|
+
[name: string]: any;
|
15
|
+
};
|
10
16
|
/**
|
11
17
|
* 开启工厂
|
12
18
|
*/
|
13
19
|
open(): void;
|
14
20
|
/**
|
15
|
-
*
|
21
|
+
* 使用key和类型 集合,注册多个新类型,必须有key,因为前端编译后,会丢失类名
|
16
22
|
*/
|
17
|
-
register(
|
23
|
+
register(types: {
|
24
|
+
[name: string]: any;
|
25
|
+
}): void;
|
18
26
|
/**
|
19
27
|
* 根据主键创建驱动,并返回加载后的驱动信息
|
20
28
|
*/
|
21
29
|
createByIdAsync(id: number, driverRef?: Ref<any>): Promise<T>;
|
30
|
+
createWithCache<S extends T>(type: string, name?: string, open?: (entity: T) => void): S;
|
22
31
|
/**
|
23
32
|
* 从缓存中获取指定类型的驱动,不存在则创建,用于Helper类等简单类型
|
24
33
|
* 可以定义名称,实现同一类型,按照不同场景各自进行缓存
|