xframelib 0.4.1 → 0.4.6
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/README.md +5 -0
- package/dist/api/Token.d.ts +20 -0
- package/dist/api/User.d.ts +45 -0
- package/dist/api/index.d.ts +2 -0
- package/dist/controls/collapsepanel/VCollapsiblePanel.vue.d.ts +26 -0
- package/dist/controls/collapsepanel/VCollapsiblePanelGroup.vue.d.ts +30 -0
- package/dist/controls/collapsepanel/color.util.d.ts +1 -0
- package/dist/controls/collapsepanel/composables/store.d.ts +7 -0
- package/dist/controls/collapsepanel/constant.d.ts +1 -0
- package/dist/controls/collapsepanel/index.d.ts +3 -0
- package/dist/controls/layoutcontainer/LayoutManager.d.ts +107 -0
- package/dist/controls/layoutcontainer/index.d.ts +3 -0
- package/dist/controls/layoutcontainer/layout.vue.d.ts +37 -0
- package/dist/controls/splitpanes/index.d.ts +3 -0
- package/dist/controls/vuewindow/SinglePointerEvent.d.ts +23 -0
- package/dist/controls/vuewindow/dom.d.ts +16 -0
- package/dist/controls/vuewindow/draggable_helper.d.ts +20 -0
- package/dist/controls/vuewindow/index.d.ts +6 -0
- package/dist/controls/vuewindow/resizable_helper.d.ts +16 -0
- package/dist/controls/vuewindow/style.d.ts +110 -0
- package/dist/controls/vuewindow/window/Button.vue.d.ts +26 -0
- package/dist/controls/vuewindow/window/index.vue.d.ts +160 -0
- package/dist/controls/vuewindow/window/utils.d.ts +17 -0
- package/dist/controls/vuewindow/z_element.d.ts +11 -0
- package/dist/core/Global.d.ts +26 -0
- package/dist/core/IModel.d.ts +34 -0
- package/dist/core/MsgHelper.d.ts +12 -0
- package/dist/core/SysEvents.d.ts +23 -0
- package/dist/core/index.d.ts +3 -0
- package/dist/hprose/HproseClient.d.ts +20 -0
- package/dist/hprose/ProxyClient.d.ts +22 -0
- package/dist/hprose/index.d.ts +11 -0
- package/dist/index.cjs +3 -8
- package/dist/index.css +69 -0
- package/dist/index.d.ts +10 -1116
- package/dist/index.js +3 -8
- package/dist/mitt/index.d.ts +25 -0
- package/dist/model/Config.d.ts +94 -0
- package/dist/model/Constants.d.ts +15 -0
- package/dist/model/Layout.d.ts +75 -0
- package/dist/model/Token.d.ts +66 -0
- package/dist/model/index.d.ts +4 -0
- package/dist/public/mitm.html +166 -0
- package/dist/public/sw.js +128 -0
- package/dist/utils/AxiosHelper.d.ts +58 -0
- package/dist/utils/BigFileDownload.d.ts +117 -0
- package/dist/utils/Color.d.ts +74 -0
- package/dist/utils/FileDownload.d.ts +36 -0
- package/dist/utils/FileUpload.d.ts +90 -0
- package/dist/utils/H5Tool.d.ts +98 -0
- package/dist/utils/IsTool.d.ts +101 -0
- package/dist/utils/JQuery.d.ts +35 -0
- package/dist/utils/LockHelper.d.ts +17 -0
- package/dist/utils/Storage.d.ts +57 -0
- package/dist/utils/StringUtils.d.ts +15 -0
- package/dist/utils/Time.d.ts +1 -0
- package/dist/utils/TokenHelper.d.ts +18 -0
- package/dist/utils/URLTool.d.ts +18 -0
- package/dist/utils/index.d.ts +16 -0
- package/dist/utils/uuid.d.ts +3 -0
- package/package.json +15 -15
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { PropType } from 'vue';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
windowStyle: {
|
|
4
|
+
type: ObjectConstructor;
|
|
5
|
+
required: true;
|
|
6
|
+
};
|
|
7
|
+
isOpen: {
|
|
8
|
+
type: PropType<boolean>;
|
|
9
|
+
required: false;
|
|
10
|
+
default: boolean;
|
|
11
|
+
};
|
|
12
|
+
title: {
|
|
13
|
+
type: PropType<string>;
|
|
14
|
+
required: true;
|
|
15
|
+
default: string;
|
|
16
|
+
};
|
|
17
|
+
closeButton: {
|
|
18
|
+
type: PropType<boolean>;
|
|
19
|
+
required: false;
|
|
20
|
+
default: boolean;
|
|
21
|
+
};
|
|
22
|
+
resizable: {
|
|
23
|
+
type: PropType<boolean>;
|
|
24
|
+
required: false;
|
|
25
|
+
default: boolean;
|
|
26
|
+
};
|
|
27
|
+
isScrollable: {
|
|
28
|
+
type: PropType<boolean>;
|
|
29
|
+
required: false;
|
|
30
|
+
default: boolean;
|
|
31
|
+
};
|
|
32
|
+
padding: {
|
|
33
|
+
type: PropType<number>;
|
|
34
|
+
required: false;
|
|
35
|
+
default: number;
|
|
36
|
+
};
|
|
37
|
+
activateWhenOpen: {
|
|
38
|
+
type: PropType<boolean>;
|
|
39
|
+
required: false;
|
|
40
|
+
default: boolean;
|
|
41
|
+
};
|
|
42
|
+
positionHint: {
|
|
43
|
+
type: PropType<string>;
|
|
44
|
+
required: false;
|
|
45
|
+
default: string;
|
|
46
|
+
};
|
|
47
|
+
zGroup: {
|
|
48
|
+
type: PropType<number>;
|
|
49
|
+
required: false;
|
|
50
|
+
default: number;
|
|
51
|
+
};
|
|
52
|
+
overflow: {
|
|
53
|
+
type: PropType<string>;
|
|
54
|
+
required: false;
|
|
55
|
+
default: string;
|
|
56
|
+
};
|
|
57
|
+
minWidth: {
|
|
58
|
+
type: PropType<number>;
|
|
59
|
+
required: false;
|
|
60
|
+
default: number;
|
|
61
|
+
};
|
|
62
|
+
minHeight: {
|
|
63
|
+
type: PropType<number>;
|
|
64
|
+
required: false;
|
|
65
|
+
default: number;
|
|
66
|
+
};
|
|
67
|
+
maxWidth: {
|
|
68
|
+
type: PropType<number>;
|
|
69
|
+
required: false;
|
|
70
|
+
default: number;
|
|
71
|
+
};
|
|
72
|
+
maxHeight: {
|
|
73
|
+
type: PropType<number>;
|
|
74
|
+
required: false;
|
|
75
|
+
default: number;
|
|
76
|
+
};
|
|
77
|
+
height: {
|
|
78
|
+
type: PropType<number>;
|
|
79
|
+
required: false;
|
|
80
|
+
};
|
|
81
|
+
width: {
|
|
82
|
+
type: PropType<number>;
|
|
83
|
+
required: false;
|
|
84
|
+
};
|
|
85
|
+
top: {
|
|
86
|
+
type: PropType<number>;
|
|
87
|
+
required: false;
|
|
88
|
+
};
|
|
89
|
+
left: {
|
|
90
|
+
type: PropType<number>;
|
|
91
|
+
required: false;
|
|
92
|
+
};
|
|
93
|
+
}, {
|
|
94
|
+
isOpen: import("vue").Ref<boolean>;
|
|
95
|
+
windowEl: any;
|
|
96
|
+
titlebar: any;
|
|
97
|
+
content: any;
|
|
98
|
+
activate: () => void;
|
|
99
|
+
styleWindow: any;
|
|
100
|
+
styleTitlebar: import("vue").ComputedRef<any>;
|
|
101
|
+
styleContent: import("vue").ComputedRef<any>;
|
|
102
|
+
closeButtonClick: () => void;
|
|
103
|
+
} | undefined, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
|
|
104
|
+
windowStyle?: unknown;
|
|
105
|
+
isOpen?: unknown;
|
|
106
|
+
title?: unknown;
|
|
107
|
+
closeButton?: unknown;
|
|
108
|
+
resizable?: unknown;
|
|
109
|
+
isScrollable?: unknown;
|
|
110
|
+
padding?: unknown;
|
|
111
|
+
activateWhenOpen?: unknown;
|
|
112
|
+
positionHint?: unknown;
|
|
113
|
+
zGroup?: unknown;
|
|
114
|
+
overflow?: unknown;
|
|
115
|
+
minWidth?: unknown;
|
|
116
|
+
minHeight?: unknown;
|
|
117
|
+
maxWidth?: unknown;
|
|
118
|
+
maxHeight?: unknown;
|
|
119
|
+
height?: unknown;
|
|
120
|
+
width?: unknown;
|
|
121
|
+
top?: unknown;
|
|
122
|
+
left?: unknown;
|
|
123
|
+
} & {
|
|
124
|
+
windowStyle: Record<string, any>;
|
|
125
|
+
isOpen: boolean;
|
|
126
|
+
title: string;
|
|
127
|
+
closeButton: boolean;
|
|
128
|
+
resizable: boolean;
|
|
129
|
+
isScrollable: boolean;
|
|
130
|
+
padding: number;
|
|
131
|
+
activateWhenOpen: boolean;
|
|
132
|
+
positionHint: string;
|
|
133
|
+
zGroup: number;
|
|
134
|
+
overflow: string;
|
|
135
|
+
minWidth: number;
|
|
136
|
+
minHeight: number;
|
|
137
|
+
maxWidth: number;
|
|
138
|
+
maxHeight: number;
|
|
139
|
+
} & {
|
|
140
|
+
height?: number | undefined;
|
|
141
|
+
width?: number | undefined;
|
|
142
|
+
top?: number | undefined;
|
|
143
|
+
left?: number | undefined;
|
|
144
|
+
}>, {
|
|
145
|
+
isOpen: boolean;
|
|
146
|
+
title: string;
|
|
147
|
+
closeButton: boolean;
|
|
148
|
+
resizable: boolean;
|
|
149
|
+
isScrollable: boolean;
|
|
150
|
+
padding: number;
|
|
151
|
+
activateWhenOpen: boolean;
|
|
152
|
+
positionHint: string;
|
|
153
|
+
zGroup: number;
|
|
154
|
+
overflow: string;
|
|
155
|
+
minWidth: number;
|
|
156
|
+
minHeight: number;
|
|
157
|
+
maxWidth: number;
|
|
158
|
+
maxHeight: number;
|
|
159
|
+
}>;
|
|
160
|
+
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare const windows: Set<unknown>;
|
|
2
|
+
export declare function contentSize(el: HTMLElement): {
|
|
3
|
+
width: number;
|
|
4
|
+
height: number;
|
|
5
|
+
};
|
|
6
|
+
export declare class WindowResizeEvent {
|
|
7
|
+
readonly width: number;
|
|
8
|
+
readonly height: number;
|
|
9
|
+
constructor(width: number, height: number);
|
|
10
|
+
}
|
|
11
|
+
export declare function leftTop(proxy: any): {
|
|
12
|
+
left: number;
|
|
13
|
+
top: number;
|
|
14
|
+
} | null;
|
|
15
|
+
export declare function distance2(x1: number, y1: number, x2: number, y2: number): number;
|
|
16
|
+
export declare function fixPosition(): void;
|
|
17
|
+
export declare const instances: any[];
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export default class ZElement {
|
|
2
|
+
private _group;
|
|
3
|
+
onChange: (zIndex: number) => void;
|
|
4
|
+
zIndex?: number;
|
|
5
|
+
constructor(_group: number, onChange: (zIndex: number) => void);
|
|
6
|
+
set group(_group: number);
|
|
7
|
+
get group(): number;
|
|
8
|
+
unregister(): void;
|
|
9
|
+
raise(): void;
|
|
10
|
+
private a;
|
|
11
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import ProxyClient from '../hprose/ProxyClient';
|
|
2
|
+
import { InnerObject, XOptions } from './IModel';
|
|
3
|
+
export declare const Global: InnerObject;
|
|
4
|
+
/**
|
|
5
|
+
* 通过配置文件初始化系统
|
|
6
|
+
* @param options 配置参数对象
|
|
7
|
+
*/
|
|
8
|
+
export declare function initXFrame(options: XOptions): void;
|
|
9
|
+
/**
|
|
10
|
+
* 框架初始化
|
|
11
|
+
* @param messageUI 消息UI
|
|
12
|
+
* @param defaultHproseURL 默认HproseURL
|
|
13
|
+
*/
|
|
14
|
+
export declare const init: (messageUI: any, axiosObj: any, defaultHproseURL?: string | undefined) => void;
|
|
15
|
+
/**
|
|
16
|
+
* 获取HproseProxy对象
|
|
17
|
+
* @param hproseURL Hprose服务链接地址
|
|
18
|
+
* @returns Hprose代理对象
|
|
19
|
+
*/
|
|
20
|
+
export declare function getProxyClient(hproseURL?: string): ProxyClient | undefined;
|
|
21
|
+
/**
|
|
22
|
+
* 初始化Global.DefaultProxyClient对象
|
|
23
|
+
* @param defaulthproseURL 默认的Hprose服务对象URL
|
|
24
|
+
* @returns ProxyClient对象
|
|
25
|
+
*/
|
|
26
|
+
export declare function initDefaultProxyClient(defaulthproseURL?: string): ProxyClient | undefined;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import MsgHelper from './MsgHelper';
|
|
2
|
+
import { Emitter } from '../mitt';
|
|
3
|
+
import ProxyClient from '../hprose/ProxyClient';
|
|
4
|
+
import { ISystemConfig } from '../model/Config';
|
|
5
|
+
import { ISystemUser } from '../model/Token';
|
|
6
|
+
import { LayoutManager } from '../controls/layoutcontainer';
|
|
7
|
+
export interface InnerObject {
|
|
8
|
+
/**
|
|
9
|
+
* 当前登录用户对象
|
|
10
|
+
*/
|
|
11
|
+
User?: ISystemUser;
|
|
12
|
+
/**
|
|
13
|
+
* axios对象
|
|
14
|
+
*/
|
|
15
|
+
Axios: any;
|
|
16
|
+
Config: ISystemConfig;
|
|
17
|
+
EventBus: Emitter;
|
|
18
|
+
DefaultProxyClient: ProxyClient | null | undefined;
|
|
19
|
+
Message?: MsgHelper;
|
|
20
|
+
/**
|
|
21
|
+
* 布局管理对象
|
|
22
|
+
*/
|
|
23
|
+
LayoutManager?: LayoutManager;
|
|
24
|
+
[props: string]: any;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* 初始化配置信息
|
|
28
|
+
*/
|
|
29
|
+
export interface XOptions {
|
|
30
|
+
config?: any;
|
|
31
|
+
message?: any;
|
|
32
|
+
axios?: any;
|
|
33
|
+
defaultHproseURL?: string;
|
|
34
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Emitter } from '../mitt';
|
|
2
|
+
declare class MsgHelper {
|
|
3
|
+
private message;
|
|
4
|
+
private eventBus;
|
|
5
|
+
constructor(messageui: any, eventbus?: Emitter | undefined);
|
|
6
|
+
/**共用消息 */
|
|
7
|
+
msg(msgInfo: string, seconds?: number, typename?: string): void;
|
|
8
|
+
info(msgInfo: string, seconds?: number): void;
|
|
9
|
+
warn(msgInfo: string, seconds?: number): void;
|
|
10
|
+
err(msgInfo: string, seconds?: number): void;
|
|
11
|
+
}
|
|
12
|
+
export default MsgHelper;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const SysEvents: {
|
|
2
|
+
HproseServiceErrorEvent: string;
|
|
3
|
+
WebAPIErrorEvent: string;
|
|
4
|
+
AlertInfoEvent: string;
|
|
5
|
+
/**
|
|
6
|
+
* 一般通用警告或错误
|
|
7
|
+
*/
|
|
8
|
+
CommonWarnEvent: string;
|
|
9
|
+
/**
|
|
10
|
+
* 插件加载后事件
|
|
11
|
+
*/
|
|
12
|
+
WidgetLoadedEvent: string;
|
|
13
|
+
WidgetUnLoadedEvent: string;
|
|
14
|
+
/**
|
|
15
|
+
* 组件的可见性改变
|
|
16
|
+
*/
|
|
17
|
+
WidgetVisibleChanged: string;
|
|
18
|
+
/**
|
|
19
|
+
* Axios请求失败异常
|
|
20
|
+
*/
|
|
21
|
+
AxiosRequestErrorEvent: string;
|
|
22
|
+
};
|
|
23
|
+
export default SysEvents;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Client, ClientContext } from '@hprose/rpc-core';
|
|
2
|
+
declare class HproseClient {
|
|
3
|
+
private hproseURL?;
|
|
4
|
+
client?: Client;
|
|
5
|
+
private hproseProxy;
|
|
6
|
+
private static httpTransport?;
|
|
7
|
+
constructor(url?: string);
|
|
8
|
+
private init;
|
|
9
|
+
/**
|
|
10
|
+
* 获取HproseProxy
|
|
11
|
+
*/
|
|
12
|
+
getProxy(): Promise<any>;
|
|
13
|
+
invoke(methodName: string, args?: any[], context?: ClientContext): Promise<any>;
|
|
14
|
+
/**
|
|
15
|
+
* 解码和编码
|
|
16
|
+
*/
|
|
17
|
+
encode(name: string, args: any[], context: ClientContext): Uint8Array | undefined;
|
|
18
|
+
decode(response: Uint8Array, context: ClientContext): any;
|
|
19
|
+
}
|
|
20
|
+
export default HproseClient;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ClientContext } from '@hprose/rpc-core';
|
|
2
|
+
export default class ProxyClient {
|
|
3
|
+
private hproseClient;
|
|
4
|
+
private hpProxyObj;
|
|
5
|
+
private readonly defaultContext;
|
|
6
|
+
constructor(hproseUrl: string);
|
|
7
|
+
getClientContext(): ClientContext | null;
|
|
8
|
+
getHproseProxy(): Promise<any>;
|
|
9
|
+
hproseInvoke(methodName: string, args?: any[] | undefined): Promise<any>;
|
|
10
|
+
hproseInvokeContext(methodName: string, context: ClientContext | undefined, ...args: any): Promise<any>;
|
|
11
|
+
/**
|
|
12
|
+
* 编码参数方式请求
|
|
13
|
+
* @param request
|
|
14
|
+
*/
|
|
15
|
+
hproseInvokeEncode(requestParamsEncode: string): Promise<any>;
|
|
16
|
+
/**
|
|
17
|
+
* 对请求参数编码
|
|
18
|
+
* @param name 方法名
|
|
19
|
+
* @param args 请求参数
|
|
20
|
+
*/
|
|
21
|
+
encodeRequest(name: string, ...args: any): string;
|
|
22
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import ProxyClient from './ProxyClient';
|
|
2
|
+
import HproseClient from './HproseClient';
|
|
3
|
+
export interface GIHprose {
|
|
4
|
+
getDefaultClient(): ProxyClient;
|
|
5
|
+
registerHprose(hpClientName: string, hproseUrl: string): HproseClient | undefined;
|
|
6
|
+
getHprose(hpClientName: string): HproseClient | undefined;
|
|
7
|
+
getProxyHprose(hpClientName: string): ProxyClient | undefined;
|
|
8
|
+
unregisterHprose(hpClientName: string): void;
|
|
9
|
+
}
|
|
10
|
+
declare const GlobalHprose: GIHprose;
|
|
11
|
+
export { GlobalHprose, ProxyClient, HproseClient };
|