@vxe-ui/core 4.4.42 → 4.5.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/dist/all.esm.js +1364 -1390
- package/es/index.d.ts +135 -0
- package/es/index.esm.js +135 -125
- package/es/index.js +147 -0
- package/es/src/base-utils.d.ts +2 -0
- package/es/src/base-utils.js +40 -37
- package/es/src/clipboard.d.ts +2 -0
- package/es/src/clipboard.js +48 -45
- package/es/src/commands.d.ts +2 -0
- package/es/src/commands.js +47 -48
- package/es/src/config.d.ts +13 -0
- package/es/src/config.js +21 -23
- package/es/src/configStore.d.ts +2 -0
- package/es/src/configStore.js +8 -5
- package/es/src/core.d.ts +3 -0
- package/es/src/core.js +11 -7
- package/es/src/dataStore.d.ts +2 -0
- package/es/src/dataStore.js +4 -1
- package/es/src/dom-utils.d.ts +2 -0
- package/es/src/dom-utils.js +65 -68
- package/es/src/event.d.ts +4 -0
- package/es/src/event.js +133 -147
- package/es/src/formats.d.ts +2 -0
- package/es/src/formats.js +47 -48
- package/es/src/hooks.d.ts +2 -0
- package/es/src/hooks.js +5 -2
- package/es/src/i18n.d.ts +6 -0
- package/es/src/i18n.js +51 -44
- package/es/src/i18nStore.d.ts +5 -0
- package/es/src/i18nStore.js +7 -4
- package/es/src/icon.d.ts +9 -0
- package/es/src/icon.js +28 -22
- package/es/src/iconStore.d.ts +2 -0
- package/es/src/iconStore.js +4 -1
- package/es/src/interceptor.d.ts +2 -0
- package/es/src/interceptor.js +52 -54
- package/es/src/log.d.ts +2 -0
- package/es/src/log.js +14 -11
- package/es/src/menus.d.ts +2 -0
- package/es/src/menus.js +47 -48
- package/es/src/permission.d.ts +3 -0
- package/es/src/permission.js +57 -55
- package/es/src/popper-utils.d.ts +2 -0
- package/es/src/popper-utils.js +159 -179
- package/es/src/renderer.d.ts +5 -0
- package/es/src/renderer.js +37 -42
- package/es/src/resize.d.ts +2 -0
- package/es/src/resize.js +60 -70
- package/es/src/scrollbar-utils.d.ts +2 -0
- package/es/src/scrollbar-utils.js +57 -54
- package/es/src/store.d.ts +13 -0
- package/es/src/store.js +43 -45
- package/es/src/theme.d.ts +3 -0
- package/es/src/theme.js +17 -13
- package/es/src/themeStore.d.ts +4 -0
- package/es/src/themeStore.js +5 -2
- package/es/src/useFns.d.ts +40 -0
- package/es/src/useFns.js +212 -231
- package/es/src/validators.d.ts +2 -0
- package/es/src/validators.js +6 -3
- package/es/src/vm.d.ts +2 -0
- package/es/src/vm.js +9 -6
- package/es/src/z-index.d.ts +2 -0
- package/es/src/z-index.js +29 -26
- package/lib/index.common.js +133 -365
- package/lib/index.js +178 -0
- package/lib/index.umd.js +588 -3343
- package/lib/index.umd.min.js +1 -1
- package/lib/src/base-utils.js +39 -13
- package/lib/src/clipboard.js +50 -23
- package/lib/src/commands.js +46 -27
- package/lib/src/config.js +43 -23
- package/lib/src/configStore.js +24 -7
- package/lib/src/core.js +29 -11
- package/lib/src/dataStore.js +22 -5
- package/lib/src/dom-utils.js +40 -20
- package/lib/src/event.js +95 -102
- package/lib/src/formats.js +46 -27
- package/lib/src/hooks.js +33 -7
- package/lib/src/i18n.js +53 -38
- package/lib/src/i18nStore.js +25 -8
- package/lib/src/icon.js +46 -22
- package/lib/src/iconStore.js +22 -5
- package/lib/src/interceptor.js +40 -18
- package/lib/src/log.js +29 -12
- package/lib/src/menus.js +46 -27
- package/lib/src/permission.js +40 -17
- package/lib/src/popper-utils.js +71 -71
- package/lib/src/renderer.js +40 -21
- package/lib/src/resize.js +48 -42
- package/lib/src/scrollbar-utils.js +23 -6
- package/lib/src/store.js +44 -25
- package/lib/src/theme.js +31 -14
- package/lib/src/themeStore.js +24 -7
- package/lib/src/useFns.js +87 -124
- package/lib/src/validators.js +34 -10
- package/lib/src/vm.js +34 -8
- package/lib/src/z-index.js +38 -12
- package/package.json +14 -3
- package/packages/index.ts +168 -168
- package/packages/src/base-utils.ts +42 -43
- package/packages/src/clipboard.ts +56 -56
- package/packages/src/commands.ts +56 -56
- package/packages/src/config.ts +30 -30
- package/packages/src/configStore.ts +8 -8
- package/packages/src/core.ts +11 -11
- package/packages/src/dataStore.ts +3 -4
- package/packages/src/dom-utils.ts +86 -87
- package/packages/src/event.ts +161 -161
- package/packages/src/formats.ts +56 -56
- package/packages/src/hooks.ts +5 -5
- package/packages/src/i18n.ts +63 -63
- package/packages/src/i18nStore.ts +11 -11
- package/packages/src/icon.ts +32 -32
- package/packages/src/iconStore.ts +3 -3
- package/packages/src/interceptor.ts +64 -64
- package/packages/src/log.ts +19 -19
- package/packages/src/menus.ts +56 -56
- package/packages/src/permission.ts +61 -61
- package/packages/src/popper-utils.ts +197 -194
- package/packages/src/renderer.ts +50 -50
- package/packages/src/resize.ts +89 -89
- package/packages/src/scrollbar-utils.ts +58 -58
- package/packages/src/store.ts +47 -47
- package/packages/src/theme.ts +20 -20
- package/packages/src/themeStore.ts +7 -7
- package/packages/src/useFns.ts +270 -275
- package/packages/src/validators.ts +7 -7
- package/packages/src/vm.ts +10 -10
- package/packages/src/z-index.ts +30 -30
- package/types/core/base-utils.d.ts +39 -40
- package/types/core/clipboard.d.ts +22 -22
- package/types/core/commands.d.ts +17 -19
- package/types/core/components.d.ts +5 -5
- package/types/core/dom-utils.d.ts +36 -37
- package/types/core/formats.d.ts +17 -19
- package/types/core/global-config.d.ts +68 -74
- package/types/core/global-data.d.ts +7 -7
- package/types/core/global-event.d.ts +48 -48
- package/types/core/global-icon.d.ts +10 -10
- package/types/core/global-lang.d.ts +28 -27
- package/types/core/global-resize.d.ts +3 -3
- package/types/core/global-theme.d.ts +1 -1
- package/types/core/hooks.d.ts +12 -14
- package/types/core/index.d.ts +336 -336
- package/types/core/interceptor.d.ts +20 -22
- package/types/core/log.d.ts +8 -8
- package/types/core/menus.d.ts +17 -19
- package/types/core/permission.d.ts +10 -10
- package/types/core/popper-utils.d.ts +44 -44
- package/types/core/renderer.d.ts +14 -14
- package/types/core/scrollbar-utils.d.ts +37 -38
- package/types/core/useFn.d.ts +121 -126
- package/types/core/validators.d.ts +17 -19
- package/types/core/z-index.d.ts +18 -18
- package/types/index.d.ts +13 -13
- package/types/tool/common.d.ts +146 -155
- package/types/tool/index.d.ts +2 -2
- package/types/tool/util.d.ts +4 -4
- package/lib/src/base-utils.min.js +0 -1
- package/lib/src/clipboard.min.js +0 -1
- package/lib/src/commands.min.js +0 -1
- package/lib/src/config.min.js +0 -1
- package/lib/src/configStore.min.js +0 -1
- package/lib/src/core.min.js +0 -1
- package/lib/src/dataStore.min.js +0 -1
- package/lib/src/dom-utils.min.js +0 -1
- package/lib/src/event.min.js +0 -1
- package/lib/src/formats.min.js +0 -1
- package/lib/src/hooks.min.js +0 -1
- package/lib/src/i18n.min.js +0 -1
- package/lib/src/i18nStore.min.js +0 -1
- package/lib/src/icon.min.js +0 -1
- package/lib/src/iconStore.min.js +0 -1
- package/lib/src/interceptor.min.js +0 -1
- package/lib/src/log.min.js +0 -1
- package/lib/src/menus.min.js +0 -1
- package/lib/src/permission.min.js +0 -1
- package/lib/src/popper-utils.min.js +0 -1
- package/lib/src/renderer.min.js +0 -1
- package/lib/src/resize.min.js +0 -1
- package/lib/src/scrollbar-utils.min.js +0 -1
- package/lib/src/store.min.js +0 -1
- package/lib/src/theme.min.js +0 -1
- package/lib/src/themeStore.min.js +0 -1
- package/lib/src/useFns.min.js +0 -1
- package/lib/src/validators.min.js +0 -1
- package/lib/src/vm.min.js +0 -1
- package/lib/src/z-index.min.js +0 -1
package/dist/all.esm.js
CHANGED
|
@@ -1,1530 +1,1504 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3
|
+
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
// packages_temp/src/core.ts
|
|
6
|
+
var coreVersion = "4.5.0";
|
|
7
|
+
var VxeCore = {
|
|
8
|
+
coreVersion,
|
|
9
|
+
uiVersion: "",
|
|
10
|
+
tableVersion: "",
|
|
11
|
+
designVersion: "",
|
|
12
|
+
ganttVersion: ""
|
|
12
13
|
};
|
|
13
14
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
// packages_temp/index.ts
|
|
16
|
+
import { createCommentVNode } from "vue";
|
|
17
|
+
|
|
18
|
+
// packages_temp/src/config.ts
|
|
19
|
+
import XEUtils from "xe-utils";
|
|
20
|
+
import DomZIndex from "dom-zindex";
|
|
21
|
+
|
|
22
|
+
// packages_temp/src/configStore.ts
|
|
23
|
+
var globalConfigStore = {
|
|
24
|
+
size: "",
|
|
25
|
+
version: 1,
|
|
26
|
+
zIndex: 999,
|
|
27
|
+
resizeInterval: 500
|
|
19
28
|
};
|
|
20
29
|
|
|
21
|
-
|
|
22
|
-
|
|
30
|
+
// packages_temp/src/themeStore.ts
|
|
31
|
+
var themeConfigStore = {
|
|
32
|
+
theme: ""
|
|
23
33
|
};
|
|
24
34
|
|
|
35
|
+
// packages_temp/src/theme.ts
|
|
25
36
|
function setTheme(name) {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
37
|
+
const theme = !name || name === "default" ? "light" : name;
|
|
38
|
+
themeConfigStore.theme = theme;
|
|
39
|
+
if (typeof document !== "undefined") {
|
|
40
|
+
const documentElement = document.documentElement;
|
|
41
|
+
if (documentElement) {
|
|
42
|
+
documentElement.setAttribute("data-vxe-ui-theme", theme);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
return VxeCore;
|
|
35
46
|
}
|
|
36
47
|
function getTheme() {
|
|
37
|
-
|
|
48
|
+
return themeConfigStore.theme;
|
|
38
49
|
}
|
|
39
50
|
|
|
40
|
-
|
|
41
|
-
* 全局参数设置
|
|
42
|
-
*/
|
|
51
|
+
// packages_temp/src/config.ts
|
|
43
52
|
function setConfig(options) {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
if (options.theme) {
|
|
49
|
-
setTheme(options.theme);
|
|
50
|
-
}
|
|
51
|
-
XEUtils.merge(globalConfigStore, options);
|
|
53
|
+
if (options) {
|
|
54
|
+
if (options.zIndex) {
|
|
55
|
+
DomZIndex.setCurrent(options.zIndex);
|
|
52
56
|
}
|
|
53
|
-
|
|
57
|
+
if (options.theme) {
|
|
58
|
+
setTheme(options.theme);
|
|
59
|
+
}
|
|
60
|
+
XEUtils.merge(globalConfigStore, options);
|
|
61
|
+
}
|
|
62
|
+
return VxeCore;
|
|
54
63
|
}
|
|
55
|
-
/**
|
|
56
|
-
* 获取全局参数
|
|
57
|
-
*/
|
|
58
64
|
function getConfig(key, defaultValue) {
|
|
59
|
-
|
|
65
|
+
return arguments.length ? XEUtils.get(globalConfigStore, key, defaultValue) : globalConfigStore;
|
|
60
66
|
}
|
|
61
67
|
|
|
62
|
-
|
|
68
|
+
// packages_temp/src/dataStore.ts
|
|
69
|
+
var globalStore = {};
|
|
70
|
+
|
|
71
|
+
// packages_temp/src/icon.ts
|
|
72
|
+
import { h } from "vue";
|
|
73
|
+
import XEUtils3 from "xe-utils";
|
|
63
74
|
|
|
64
|
-
|
|
75
|
+
// packages_temp/src/iconStore.ts
|
|
76
|
+
var iconConfigStore = {};
|
|
65
77
|
|
|
78
|
+
// packages_temp/src/vm.ts
|
|
79
|
+
import XEUtils2 from "xe-utils";
|
|
66
80
|
function getSlotVNs(vns) {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
81
|
+
if (XEUtils2.isArray(vns)) {
|
|
82
|
+
return vns;
|
|
83
|
+
}
|
|
84
|
+
return vns ? [vns] : [];
|
|
71
85
|
}
|
|
72
86
|
|
|
87
|
+
// packages_temp/src/icon.ts
|
|
73
88
|
function setIcon(options) {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
89
|
+
if (options) {
|
|
90
|
+
Object.assign(iconConfigStore, options);
|
|
91
|
+
}
|
|
92
|
+
return VxeCore;
|
|
78
93
|
}
|
|
79
94
|
function getIcon(key) {
|
|
80
|
-
|
|
95
|
+
return arguments.length ? XEUtils3.get(iconConfigStore, key) : iconConfigStore;
|
|
81
96
|
}
|
|
82
97
|
function renderGlobalIcon(name) {
|
|
83
|
-
|
|
84
|
-
|
|
98
|
+
const icon = getIcon(name);
|
|
99
|
+
return renderCustomIcon(icon, name);
|
|
85
100
|
}
|
|
86
101
|
function renderCustomIcon(icon, name) {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
102
|
+
if (XEUtils3.isFunction(icon)) {
|
|
103
|
+
return h("span", {}, getSlotVNs(icon({ name })));
|
|
104
|
+
}
|
|
105
|
+
return h("i", {
|
|
106
|
+
class: icon
|
|
107
|
+
});
|
|
93
108
|
}
|
|
94
109
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
110
|
+
// packages_temp/src/event.ts
|
|
111
|
+
import XEUtils4 from "xe-utils";
|
|
112
|
+
var GLOBAL_EVENT_KEYS = {
|
|
113
|
+
F2: "F2",
|
|
114
|
+
F10: "F10",
|
|
115
|
+
TAB: "Tab",
|
|
116
|
+
ESCAPE: "Escape",
|
|
117
|
+
ENTER: "Enter",
|
|
118
|
+
DELETE: "Delete",
|
|
119
|
+
BACKSPACE: "Backspace",
|
|
120
|
+
SPACEBAR: " ",
|
|
121
|
+
CONTEXT_MENU: "ContextMenu",
|
|
122
|
+
ARROW_UP: "ArrowUp",
|
|
123
|
+
ARROW_DOWN: "ArrowDown",
|
|
124
|
+
ARROW_LEFT: "ArrowLeft",
|
|
125
|
+
ARROW_RIGHT: "ArrowRight",
|
|
126
|
+
PAGE_UP: "PageUp",
|
|
127
|
+
PAGE_DOWN: "PageDown",
|
|
128
|
+
HOME: "Home",
|
|
129
|
+
END: "End",
|
|
130
|
+
PROCESS: "Process",
|
|
131
|
+
A: "A",
|
|
132
|
+
X: "X",
|
|
133
|
+
C: "C",
|
|
134
|
+
V: "V",
|
|
135
|
+
D: "D",
|
|
136
|
+
F: "F",
|
|
137
|
+
H: "H",
|
|
138
|
+
M: "M",
|
|
139
|
+
Y: "Y",
|
|
140
|
+
Z: "Z",
|
|
141
|
+
R: "R",
|
|
142
|
+
P: "P"
|
|
126
143
|
};
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
144
|
+
var browse = XEUtils4.browse();
|
|
145
|
+
var convertEventKeys = {
|
|
146
|
+
" ": "Spacebar",
|
|
147
|
+
Apps: GLOBAL_EVENT_KEYS.CONTEXT_MENU,
|
|
148
|
+
Del: GLOBAL_EVENT_KEYS.DELETE,
|
|
149
|
+
Up: GLOBAL_EVENT_KEYS.ARROW_UP,
|
|
150
|
+
Down: GLOBAL_EVENT_KEYS.ARROW_DOWN,
|
|
151
|
+
Left: GLOBAL_EVENT_KEYS.ARROW_LEFT,
|
|
152
|
+
Right: GLOBAL_EVENT_KEYS.ARROW_RIGHT
|
|
136
153
|
};
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
const eventStore$1 = [];
|
|
154
|
+
var wheelName = browse.firefox ? "DOMMouseScroll" : "mousewheel";
|
|
155
|
+
var eventStore = [];
|
|
140
156
|
function triggerEvent(evnt) {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
});
|
|
157
|
+
const isWheel = evnt.type === wheelName;
|
|
158
|
+
eventStore.forEach(({ type, cb }) => {
|
|
159
|
+
if (!evnt.cancelBubble) {
|
|
160
|
+
if (type === evnt.type || isWheel && type === "mousewheel") {
|
|
161
|
+
cb(evnt);
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
});
|
|
150
165
|
}
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
if (evnt.type) {
|
|
180
|
-
this.type = evnt.type;
|
|
181
|
-
}
|
|
182
|
-
if (evnt.key) {
|
|
183
|
-
this.key = evnt.key;
|
|
184
|
-
}
|
|
185
|
-
if (evnt.code) {
|
|
186
|
-
this.code = evnt.code;
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
Object.assign(this, params1);
|
|
190
|
-
XEUtils.objectEach(params2, (val, key) => {
|
|
191
|
-
if (XEUtils.isFunction(val)) {
|
|
192
|
-
let rest = null;
|
|
193
|
-
let isRun = false;
|
|
194
|
-
Object.defineProperty(this, key, {
|
|
195
|
-
get() {
|
|
196
|
-
if (!isRun) {
|
|
197
|
-
isRun = true;
|
|
198
|
-
rest = val();
|
|
199
|
-
}
|
|
200
|
-
return rest;
|
|
201
|
-
}
|
|
202
|
-
});
|
|
203
|
-
}
|
|
204
|
-
else {
|
|
205
|
-
this[key] = val;
|
|
166
|
+
var VxeComponentEvent = class {
|
|
167
|
+
constructor(evnt, params1, params2) {
|
|
168
|
+
__publicField(this, "$event");
|
|
169
|
+
__publicField(this, "type", "");
|
|
170
|
+
__publicField(this, "key", "");
|
|
171
|
+
__publicField(this, "code", "");
|
|
172
|
+
this.$event = evnt;
|
|
173
|
+
if (evnt) {
|
|
174
|
+
if (evnt.type) {
|
|
175
|
+
this.type = evnt.type;
|
|
176
|
+
}
|
|
177
|
+
if (evnt.key) {
|
|
178
|
+
this.key = evnt.key;
|
|
179
|
+
}
|
|
180
|
+
if (evnt.code) {
|
|
181
|
+
this.code = evnt.code;
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
Object.assign(this, params1);
|
|
185
|
+
XEUtils4.objectEach(params2, (val, key) => {
|
|
186
|
+
if (XEUtils4.isFunction(val)) {
|
|
187
|
+
let rest = null;
|
|
188
|
+
let isRun = false;
|
|
189
|
+
Object.defineProperty(this, key, {
|
|
190
|
+
get() {
|
|
191
|
+
if (!isRun) {
|
|
192
|
+
isRun = true;
|
|
193
|
+
rest = val();
|
|
206
194
|
}
|
|
195
|
+
return rest;
|
|
196
|
+
}
|
|
207
197
|
});
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
return new VxeComponentEvent(evnt, params1, params2);
|
|
198
|
+
} else {
|
|
199
|
+
;
|
|
200
|
+
this[key] = val;
|
|
201
|
+
}
|
|
202
|
+
});
|
|
203
|
+
}
|
|
204
|
+
stopPropagation() {
|
|
205
|
+
const evnt = this.$event;
|
|
206
|
+
if (evnt) {
|
|
207
|
+
evnt.stopPropagation();
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
preventDefault() {
|
|
211
|
+
const evnt = this.$event;
|
|
212
|
+
if (evnt) {
|
|
213
|
+
evnt.preventDefault();
|
|
214
|
+
}
|
|
215
|
+
}
|
|
227
216
|
};
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
217
|
+
var createEvent = (evnt, params1, params2) => {
|
|
218
|
+
if (evnt instanceof VxeComponentEvent) {
|
|
219
|
+
evnt = evnt.$event;
|
|
220
|
+
}
|
|
221
|
+
return new VxeComponentEvent(evnt, params1, params2);
|
|
222
|
+
};
|
|
223
|
+
var globalEvents = {
|
|
224
|
+
on(comp, type, cb) {
|
|
225
|
+
eventStore.push({ comp, type, cb });
|
|
226
|
+
},
|
|
227
|
+
off(comp, type) {
|
|
228
|
+
XEUtils4.remove(eventStore, (item) => item.comp === comp && item.type === type);
|
|
229
|
+
},
|
|
230
|
+
hasKey(evnt, targetKey) {
|
|
231
|
+
if (!targetKey) {
|
|
232
|
+
return false;
|
|
233
|
+
}
|
|
234
|
+
const { key } = evnt;
|
|
235
|
+
targetKey = targetKey.toLowerCase();
|
|
236
|
+
return key ? targetKey === key.toLowerCase() || !!(convertEventKeys[key] && convertEventKeys[key].toLowerCase() === targetKey) : false;
|
|
237
|
+
}
|
|
243
238
|
};
|
|
244
239
|
if (browse.isDoc) {
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
240
|
+
if (!browse.msie) {
|
|
241
|
+
window.addEventListener("copy", triggerEvent, false);
|
|
242
|
+
window.addEventListener("cut", triggerEvent, false);
|
|
243
|
+
window.addEventListener("paste", triggerEvent, false);
|
|
244
|
+
}
|
|
245
|
+
document.addEventListener("scroll", triggerEvent, true);
|
|
246
|
+
document.addEventListener("keydown", triggerEvent, false);
|
|
247
|
+
document.addEventListener("contextmenu", triggerEvent, false);
|
|
248
|
+
window.addEventListener("mousedown", triggerEvent, false);
|
|
249
|
+
window.addEventListener("click", triggerEvent, false);
|
|
250
|
+
window.addEventListener("blur", triggerEvent, false);
|
|
251
|
+
window.addEventListener("resize", triggerEvent, false);
|
|
252
|
+
window.addEventListener(wheelName, XEUtils4.throttle(triggerEvent, 100, { leading: true, trailing: false }), { passive: true, capture: false });
|
|
258
253
|
}
|
|
259
254
|
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
/* eslint-disable no-use-before-define */
|
|
266
|
-
const eventStore = [];
|
|
267
|
-
const defaultInterval = 500;
|
|
255
|
+
// packages_temp/src/resize.ts
|
|
256
|
+
import XEUtils5 from "xe-utils";
|
|
257
|
+
var resizeTimeout;
|
|
258
|
+
var eventStore2 = [];
|
|
259
|
+
var defaultInterval = 500;
|
|
268
260
|
function eventHandle() {
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
}
|
|
261
|
+
if (eventStore2.length) {
|
|
262
|
+
eventStore2.forEach((item) => {
|
|
263
|
+
item.tarList.forEach((observer) => {
|
|
264
|
+
const { target, width, heighe } = observer;
|
|
265
|
+
const clientWidth = target.clientWidth;
|
|
266
|
+
const clientHeight = target.clientHeight;
|
|
267
|
+
const rWidth = clientWidth && width !== clientWidth;
|
|
268
|
+
const rHeight = clientHeight && heighe !== clientHeight;
|
|
269
|
+
if (rWidth || rHeight) {
|
|
270
|
+
observer.width = clientWidth;
|
|
271
|
+
observer.heighe = clientHeight;
|
|
272
|
+
setTimeout(item.callback);
|
|
273
|
+
}
|
|
274
|
+
});
|
|
275
|
+
});
|
|
276
|
+
eventListener();
|
|
277
|
+
}
|
|
287
278
|
}
|
|
288
279
|
function eventListener() {
|
|
289
|
-
|
|
290
|
-
|
|
280
|
+
clearTimeout(resizeTimeout);
|
|
281
|
+
resizeTimeout = setTimeout(eventHandle, globalConfigStore.resizeInterval || defaultInterval);
|
|
291
282
|
}
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
283
|
+
var XEResizeObserver = class {
|
|
284
|
+
constructor(callback) {
|
|
285
|
+
__publicField(this, "tarList", []);
|
|
286
|
+
__publicField(this, "callback");
|
|
287
|
+
this.callback = callback;
|
|
288
|
+
}
|
|
289
|
+
observe(target) {
|
|
290
|
+
if (target) {
|
|
291
|
+
const { tarList } = this;
|
|
292
|
+
if (!tarList.some((observer) => observer.target === target)) {
|
|
293
|
+
tarList.push({
|
|
294
|
+
target,
|
|
295
|
+
width: target.clientWidth,
|
|
296
|
+
heighe: target.clientHeight
|
|
305
297
|
});
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
unobserve(target) {
|
|
327
|
-
XEUtils.remove(eventStore, item => item.tarList.some(observer => observer.target === target));
|
|
328
|
-
}
|
|
329
|
-
disconnect() {
|
|
330
|
-
XEUtils.remove(eventStore, item => item === this);
|
|
331
|
-
}
|
|
332
|
-
}
|
|
333
|
-
const globalResize = {
|
|
334
|
-
create(callback) {
|
|
335
|
-
if (window.ResizeObserver) {
|
|
336
|
-
return new window.ResizeObserver(callback);
|
|
337
|
-
}
|
|
338
|
-
return new XEResizeObserver(callback);
|
|
298
|
+
}
|
|
299
|
+
if (!eventStore2.length) {
|
|
300
|
+
eventListener();
|
|
301
|
+
}
|
|
302
|
+
if (!eventStore2.some((item) => item === this)) {
|
|
303
|
+
eventStore2.push(this);
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
unobserve(target) {
|
|
308
|
+
XEUtils5.remove(eventStore2, (item) => item.tarList.some((observer) => observer.target === target));
|
|
309
|
+
}
|
|
310
|
+
disconnect() {
|
|
311
|
+
XEUtils5.remove(eventStore2, (item) => item === this);
|
|
312
|
+
}
|
|
313
|
+
};
|
|
314
|
+
var globalResize = {
|
|
315
|
+
create(callback) {
|
|
316
|
+
if (window.ResizeObserver) {
|
|
317
|
+
return new window.ResizeObserver(callback);
|
|
339
318
|
}
|
|
319
|
+
return new XEResizeObserver(callback);
|
|
320
|
+
}
|
|
340
321
|
};
|
|
341
322
|
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
323
|
+
// packages_temp/src/i18n.ts
|
|
324
|
+
import XEUtils6 from "xe-utils";
|
|
325
|
+
|
|
326
|
+
// packages_temp/src/i18nStore.ts
|
|
327
|
+
import { reactive } from "vue";
|
|
328
|
+
var i18nConfigStore = reactive({
|
|
329
|
+
language: "",
|
|
330
|
+
langMaps: {}
|
|
345
331
|
});
|
|
346
332
|
|
|
347
|
-
|
|
348
|
-
|
|
333
|
+
// packages_temp/src/i18n.ts
|
|
334
|
+
var checkInstall = false;
|
|
335
|
+
var cacheMaps = {};
|
|
349
336
|
function getDefaultExport(mod) {
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
337
|
+
if (mod && mod.__esModule) {
|
|
338
|
+
return mod.default;
|
|
339
|
+
}
|
|
340
|
+
return mod;
|
|
354
341
|
}
|
|
355
342
|
function getI18n(key, args) {
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
343
|
+
const { langMaps, language } = i18nConfigStore;
|
|
344
|
+
const { i18n } = globalConfigStore;
|
|
345
|
+
if (i18n) {
|
|
346
|
+
return `${i18n(key, args) || ""}`;
|
|
347
|
+
}
|
|
348
|
+
if (!checkInstall) {
|
|
349
|
+
if (!langMaps[language]) {
|
|
350
|
+
console.error(`[vxe core] 语言包未安装。Language not installed. https://${VxeCore.uiVersion ? "vxeui.com" : "vxetable.cn"}/#/start/i18n`);
|
|
351
|
+
}
|
|
352
|
+
checkInstall = true;
|
|
353
|
+
}
|
|
354
|
+
if (!args && cacheMaps[key]) {
|
|
355
|
+
return cacheMaps[key];
|
|
356
|
+
}
|
|
357
|
+
const i18nLabel = XEUtils6.toFormatString(XEUtils6.get(langMaps[language], key, key), args);
|
|
358
|
+
if (!args) {
|
|
359
|
+
cacheMaps[key] = i18nLabel;
|
|
360
|
+
}
|
|
361
|
+
return i18nLabel;
|
|
375
362
|
}
|
|
376
363
|
function setLanguage(locale) {
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
364
|
+
const { language } = i18nConfigStore;
|
|
365
|
+
const targetlang = locale || "zh-CN";
|
|
366
|
+
if (language !== targetlang) {
|
|
367
|
+
i18nConfigStore.language = targetlang;
|
|
368
|
+
cacheMaps = {};
|
|
369
|
+
}
|
|
370
|
+
return VxeCore;
|
|
384
371
|
}
|
|
385
372
|
function setI18n(locale, data) {
|
|
386
|
-
|
|
387
|
-
|
|
373
|
+
i18nConfigStore.langMaps[locale] = Object.assign({}, getDefaultExport(data));
|
|
374
|
+
return VxeCore;
|
|
388
375
|
}
|
|
389
376
|
function hasLanguage(language) {
|
|
390
|
-
|
|
391
|
-
|
|
377
|
+
const { langMaps } = i18nConfigStore;
|
|
378
|
+
return !!langMaps[language];
|
|
392
379
|
}
|
|
393
380
|
function getLanguage() {
|
|
394
|
-
|
|
395
|
-
|
|
381
|
+
const { language } = i18nConfigStore;
|
|
382
|
+
return language;
|
|
396
383
|
}
|
|
397
384
|
|
|
385
|
+
// packages_temp/src/renderer.ts
|
|
386
|
+
import XEUtils7 from "xe-utils";
|
|
387
|
+
|
|
388
|
+
// packages_temp/src/log.ts
|
|
398
389
|
function createLog(type, name) {
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
390
|
+
return function(key, args) {
|
|
391
|
+
const msg = `[vxe ${name || ""}] ${getI18n(key, args)}`;
|
|
392
|
+
console[type](msg);
|
|
393
|
+
return msg;
|
|
394
|
+
};
|
|
404
395
|
}
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
396
|
+
var version = "4.5.0";
|
|
397
|
+
var log = {
|
|
398
|
+
create: createLog,
|
|
399
|
+
warn: createLog("warn", `v${version}`),
|
|
400
|
+
err: createLog("error", `v${version}`)
|
|
410
401
|
};
|
|
411
402
|
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
403
|
+
// packages_temp/src/renderer.ts
|
|
404
|
+
var renderMap = {};
|
|
405
|
+
var renderer = {
|
|
406
|
+
mixin(opts) {
|
|
407
|
+
XEUtils7.each(opts, (options, name) => {
|
|
408
|
+
renderer.add(name, options);
|
|
409
|
+
});
|
|
410
|
+
return renderer;
|
|
411
|
+
},
|
|
412
|
+
get(name) {
|
|
413
|
+
return renderMap[name] || null;
|
|
414
|
+
},
|
|
415
|
+
add(name, options) {
|
|
416
|
+
if (name && options) {
|
|
417
|
+
const renders = renderMap[name];
|
|
418
|
+
if (renders) {
|
|
419
|
+
XEUtils7.each(options, (val, key) => {
|
|
420
|
+
if (!XEUtils7.eqNull(renders[key]) && renders[key] !== val) {
|
|
421
|
+
log.warn("vxe.error.coverProp", [`Renderer.${name}`, key]);
|
|
422
|
+
}
|
|
423
423
|
});
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
Object.assign(renders, options);
|
|
440
|
-
}
|
|
441
|
-
else {
|
|
442
|
-
renderMap[name] = options;
|
|
443
|
-
}
|
|
444
|
-
}
|
|
445
|
-
return renderer;
|
|
446
|
-
},
|
|
447
|
-
forEach(callback) {
|
|
448
|
-
XEUtils.objectEach(renderMap, callback);
|
|
449
|
-
return renderer;
|
|
450
|
-
},
|
|
451
|
-
delete(name) {
|
|
452
|
-
delete renderMap[name];
|
|
453
|
-
return renderer;
|
|
454
|
-
}
|
|
424
|
+
Object.assign(renders, options);
|
|
425
|
+
} else {
|
|
426
|
+
renderMap[name] = options;
|
|
427
|
+
}
|
|
428
|
+
}
|
|
429
|
+
return renderer;
|
|
430
|
+
},
|
|
431
|
+
forEach(callback) {
|
|
432
|
+
XEUtils7.objectEach(renderMap, callback);
|
|
433
|
+
return renderer;
|
|
434
|
+
},
|
|
435
|
+
delete(name) {
|
|
436
|
+
delete renderMap[name];
|
|
437
|
+
return renderer;
|
|
438
|
+
}
|
|
455
439
|
};
|
|
456
440
|
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
delete this.store[name];
|
|
495
|
-
}
|
|
496
|
-
forEach(callback) {
|
|
497
|
-
XEUtils.objectEach(this.store, callback);
|
|
498
|
-
}
|
|
499
|
-
}
|
|
441
|
+
// packages_temp/src/store.ts
|
|
442
|
+
import XEUtils8 from "xe-utils";
|
|
443
|
+
var Store = class {
|
|
444
|
+
constructor() {
|
|
445
|
+
__publicField(this, "store", {});
|
|
446
|
+
}
|
|
447
|
+
mixin(options) {
|
|
448
|
+
XEUtils8.each(options, (item, key) => {
|
|
449
|
+
this.add(key, item);
|
|
450
|
+
});
|
|
451
|
+
return this;
|
|
452
|
+
}
|
|
453
|
+
has(name) {
|
|
454
|
+
return !!this.get(name);
|
|
455
|
+
}
|
|
456
|
+
get(name) {
|
|
457
|
+
return this.store[name];
|
|
458
|
+
}
|
|
459
|
+
add(name, options) {
|
|
460
|
+
const conf = this.store[name];
|
|
461
|
+
const confKeys = XEUtils8.keys(conf);
|
|
462
|
+
XEUtils8.each(options, (item, key) => {
|
|
463
|
+
if (confKeys.includes(key)) {
|
|
464
|
+
log.warn("vxe.error.coverProp", [name, key]);
|
|
465
|
+
}
|
|
466
|
+
});
|
|
467
|
+
this.store[name] = conf ? XEUtils8.merge(conf, options) : options;
|
|
468
|
+
return this;
|
|
469
|
+
}
|
|
470
|
+
delete(name) {
|
|
471
|
+
delete this.store[name];
|
|
472
|
+
}
|
|
473
|
+
forEach(callback) {
|
|
474
|
+
XEUtils8.objectEach(this.store, callback);
|
|
475
|
+
}
|
|
476
|
+
};
|
|
477
|
+
var store_default = Store;
|
|
500
478
|
|
|
501
|
-
|
|
502
|
-
|
|
479
|
+
// packages_temp/src/validators.ts
|
|
480
|
+
var validators = new store_default();
|
|
481
|
+
Object.assign(validators, { _name: "Validators" });
|
|
503
482
|
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
XEUtils.objectEach(this.store, callback);
|
|
549
|
-
}
|
|
550
|
-
}
|
|
551
|
-
const menus = new VXEMenusStore();
|
|
552
|
-
Object.assign(menus, { _name: 'Menus' });
|
|
483
|
+
// packages_temp/src/menus.ts
|
|
484
|
+
import XEUtils9 from "xe-utils";
|
|
485
|
+
var VXEMenusStore = class {
|
|
486
|
+
constructor() {
|
|
487
|
+
__publicField(this, "store", {});
|
|
488
|
+
}
|
|
489
|
+
mixin(options) {
|
|
490
|
+
XEUtils9.each(options, (item, key) => {
|
|
491
|
+
this.add(key, item);
|
|
492
|
+
});
|
|
493
|
+
return this;
|
|
494
|
+
}
|
|
495
|
+
has(name) {
|
|
496
|
+
return !!this.get(name);
|
|
497
|
+
}
|
|
498
|
+
get(name) {
|
|
499
|
+
return this.store[name];
|
|
500
|
+
}
|
|
501
|
+
add(name, render) {
|
|
502
|
+
const conf = this.store[name];
|
|
503
|
+
if (XEUtils9.isFunction(render)) {
|
|
504
|
+
log.warn("vxe.error.delProp", ["menus -> callback", "menuMethod"]);
|
|
505
|
+
render = {
|
|
506
|
+
menuMethod: render
|
|
507
|
+
};
|
|
508
|
+
}
|
|
509
|
+
const confKeys = XEUtils9.keys(conf);
|
|
510
|
+
XEUtils9.each(render, (item, key) => {
|
|
511
|
+
if (confKeys.includes(key)) {
|
|
512
|
+
log.warn("vxe.error.coverProp", [name, key]);
|
|
513
|
+
}
|
|
514
|
+
});
|
|
515
|
+
this.store[name] = conf ? XEUtils9.merge(conf, render) : render;
|
|
516
|
+
return this;
|
|
517
|
+
}
|
|
518
|
+
delete(name) {
|
|
519
|
+
delete this.store[name];
|
|
520
|
+
}
|
|
521
|
+
forEach(callback) {
|
|
522
|
+
XEUtils9.objectEach(this.store, callback);
|
|
523
|
+
}
|
|
524
|
+
};
|
|
525
|
+
var menus = new VXEMenusStore();
|
|
526
|
+
Object.assign(menus, { _name: "Menus" });
|
|
553
527
|
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
XEUtils.objectEach(this.store, callback);
|
|
599
|
-
}
|
|
600
|
-
}
|
|
601
|
-
const formats = new VXEFormatsStore();
|
|
602
|
-
Object.assign(formats, { _name: 'Formats' });
|
|
528
|
+
// packages_temp/src/formats.ts
|
|
529
|
+
import XEUtils10 from "xe-utils";
|
|
530
|
+
var VXEFormatsStore = class {
|
|
531
|
+
constructor() {
|
|
532
|
+
__publicField(this, "store", {});
|
|
533
|
+
}
|
|
534
|
+
mixin(options) {
|
|
535
|
+
XEUtils10.each(options, (item, key) => {
|
|
536
|
+
this.add(key, item);
|
|
537
|
+
});
|
|
538
|
+
return this;
|
|
539
|
+
}
|
|
540
|
+
has(name) {
|
|
541
|
+
return !!this.get(name);
|
|
542
|
+
}
|
|
543
|
+
get(name) {
|
|
544
|
+
return this.store[name];
|
|
545
|
+
}
|
|
546
|
+
add(name, render) {
|
|
547
|
+
const conf = this.store[name];
|
|
548
|
+
if (XEUtils10.isFunction(render)) {
|
|
549
|
+
log.warn("vxe.error.delProp", ["formats -> callback", "cellFormatMethod"]);
|
|
550
|
+
render = {
|
|
551
|
+
cellFormatMethod: render
|
|
552
|
+
};
|
|
553
|
+
}
|
|
554
|
+
const confKeys = XEUtils10.keys(conf);
|
|
555
|
+
XEUtils10.each(render, (item, key) => {
|
|
556
|
+
if (confKeys.includes(key)) {
|
|
557
|
+
log.warn("vxe.error.coverProp", [name, key]);
|
|
558
|
+
}
|
|
559
|
+
});
|
|
560
|
+
this.store[name] = conf ? XEUtils10.merge(conf, render) : render;
|
|
561
|
+
return this;
|
|
562
|
+
}
|
|
563
|
+
delete(name) {
|
|
564
|
+
delete this.store[name];
|
|
565
|
+
}
|
|
566
|
+
forEach(callback) {
|
|
567
|
+
XEUtils10.objectEach(this.store, callback);
|
|
568
|
+
}
|
|
569
|
+
};
|
|
570
|
+
var formats = new VXEFormatsStore();
|
|
571
|
+
Object.assign(formats, { _name: "Formats" });
|
|
603
572
|
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
XEUtils.objectEach(this.store, callback);
|
|
649
|
-
}
|
|
650
|
-
}
|
|
651
|
-
const commands = new VXECommandsStore();
|
|
652
|
-
Object.assign(commands, { _name: 'Commands' });
|
|
573
|
+
// packages_temp/src/commands.ts
|
|
574
|
+
import XEUtils11 from "xe-utils";
|
|
575
|
+
var VXECommandsStore = class {
|
|
576
|
+
constructor() {
|
|
577
|
+
__publicField(this, "store", {});
|
|
578
|
+
}
|
|
579
|
+
mixin(options) {
|
|
580
|
+
XEUtils11.each(options, (item, key) => {
|
|
581
|
+
this.add(key, item);
|
|
582
|
+
});
|
|
583
|
+
return this;
|
|
584
|
+
}
|
|
585
|
+
has(name) {
|
|
586
|
+
return !!this.get(name);
|
|
587
|
+
}
|
|
588
|
+
get(name) {
|
|
589
|
+
return this.store[name];
|
|
590
|
+
}
|
|
591
|
+
add(name, render) {
|
|
592
|
+
const conf = this.store[name];
|
|
593
|
+
if (XEUtils11.isFunction(render)) {
|
|
594
|
+
log.warn("vxe.error.delProp", ["commands -> callback", "commandMethod"]);
|
|
595
|
+
render = {
|
|
596
|
+
commandMethod: render
|
|
597
|
+
};
|
|
598
|
+
}
|
|
599
|
+
const confKeys = XEUtils11.keys(conf);
|
|
600
|
+
XEUtils11.each(render, (item, key) => {
|
|
601
|
+
if (confKeys.includes(key)) {
|
|
602
|
+
log.warn("vxe.error.coverProp", [name, key]);
|
|
603
|
+
}
|
|
604
|
+
});
|
|
605
|
+
this.store[name] = conf ? XEUtils11.merge(conf, render) : render;
|
|
606
|
+
return this;
|
|
607
|
+
}
|
|
608
|
+
delete(name) {
|
|
609
|
+
delete this.store[name];
|
|
610
|
+
}
|
|
611
|
+
forEach(callback) {
|
|
612
|
+
XEUtils11.objectEach(this.store, callback);
|
|
613
|
+
}
|
|
614
|
+
};
|
|
615
|
+
var commands = new VXECommandsStore();
|
|
616
|
+
Object.assign(commands, { _name: "Commands" });
|
|
653
617
|
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
}
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
}
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
}
|
|
706
|
-
}
|
|
707
|
-
}
|
|
618
|
+
// packages_temp/src/interceptor.ts
|
|
619
|
+
import XEUtils12 from "xe-utils";
|
|
620
|
+
var storeMap = {};
|
|
621
|
+
var interceptor = {
|
|
622
|
+
mixin(options) {
|
|
623
|
+
XEUtils12.each(options, (render, type) => {
|
|
624
|
+
interceptor.add(type, render);
|
|
625
|
+
});
|
|
626
|
+
return interceptor;
|
|
627
|
+
},
|
|
628
|
+
get(type) {
|
|
629
|
+
if (type) {
|
|
630
|
+
return storeMap[type] || [];
|
|
631
|
+
}
|
|
632
|
+
return [];
|
|
633
|
+
},
|
|
634
|
+
add(type, render) {
|
|
635
|
+
if (XEUtils12.isFunction(render)) {
|
|
636
|
+
render = {
|
|
637
|
+
tableInterceptorMethod: render
|
|
638
|
+
};
|
|
639
|
+
}
|
|
640
|
+
const callback = render.tableInterceptorMethod;
|
|
641
|
+
if (callback) {
|
|
642
|
+
let eList = storeMap[type];
|
|
643
|
+
if (!eList) {
|
|
644
|
+
eList = storeMap[type] = [];
|
|
645
|
+
}
|
|
646
|
+
if (eList.indexOf(callback) > -1) {
|
|
647
|
+
log.warn("vxe.error.coverProp", ["Interceptor", type]);
|
|
648
|
+
}
|
|
649
|
+
eList.push(callback);
|
|
650
|
+
}
|
|
651
|
+
return interceptor;
|
|
652
|
+
},
|
|
653
|
+
delete(type, render) {
|
|
654
|
+
const eList = storeMap[type];
|
|
655
|
+
if (eList) {
|
|
656
|
+
if (XEUtils12.isFunction(render)) {
|
|
657
|
+
render = {
|
|
658
|
+
tableInterceptorMethod: render
|
|
659
|
+
};
|
|
660
|
+
}
|
|
661
|
+
const callback = render ? render.tableInterceptorMethod : null;
|
|
662
|
+
if (callback) {
|
|
663
|
+
XEUtils12.remove(eList, (fn) => fn === callback);
|
|
664
|
+
} else {
|
|
665
|
+
delete storeMap[type];
|
|
666
|
+
}
|
|
667
|
+
}
|
|
668
|
+
}
|
|
708
669
|
};
|
|
709
670
|
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
671
|
+
// packages_temp/src/clipboard.ts
|
|
672
|
+
import XEUtils13 from "xe-utils";
|
|
673
|
+
var copyElem;
|
|
674
|
+
var clipStore = {
|
|
675
|
+
text: "",
|
|
676
|
+
html: ""
|
|
714
677
|
};
|
|
715
678
|
function handleText(text) {
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
679
|
+
if (!copyElem) {
|
|
680
|
+
copyElem = document.createElement("textarea");
|
|
681
|
+
copyElem.id = "$VxeCopy";
|
|
682
|
+
const styles = copyElem.style;
|
|
683
|
+
styles.width = "48px";
|
|
684
|
+
styles.height = "24px";
|
|
685
|
+
styles.position = "fixed";
|
|
686
|
+
styles.zIndex = "0";
|
|
687
|
+
styles.left = "-500px";
|
|
688
|
+
styles.top = "-500px";
|
|
689
|
+
document.body.appendChild(copyElem);
|
|
690
|
+
}
|
|
691
|
+
copyElem.value = text;
|
|
729
692
|
}
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
693
|
+
var clipboard = {
|
|
694
|
+
getStore() {
|
|
695
|
+
return clipStore;
|
|
696
|
+
},
|
|
697
|
+
setStore(data) {
|
|
698
|
+
Object.assign(clipStore, data || {});
|
|
699
|
+
},
|
|
700
|
+
/**
|
|
701
|
+
* 复制内容到剪贴板
|
|
702
|
+
*
|
|
703
|
+
* @param {String} content Text 内容
|
|
704
|
+
*/
|
|
705
|
+
copy(content) {
|
|
706
|
+
let result = false;
|
|
707
|
+
try {
|
|
708
|
+
const text = XEUtils13.toValueString(content);
|
|
709
|
+
handleText(text);
|
|
710
|
+
copyElem.select();
|
|
711
|
+
copyElem.setSelectionRange(0, copyElem.value.length);
|
|
712
|
+
result = document.execCommand("copy");
|
|
713
|
+
copyElem.blur();
|
|
714
|
+
clipStore.text = text;
|
|
715
|
+
clipStore.html = "";
|
|
716
|
+
} catch (e) {
|
|
717
|
+
}
|
|
718
|
+
return result;
|
|
719
|
+
},
|
|
720
|
+
getText() {
|
|
721
|
+
return clipStore.text || "";
|
|
722
|
+
}
|
|
760
723
|
};
|
|
761
724
|
|
|
725
|
+
// packages_temp/src/permission.ts
|
|
726
|
+
import XEUtils14 from "xe-utils";
|
|
762
727
|
function handleCheckInfo(permissionCode, permissionMethod) {
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
};
|
|
803
|
-
return info;
|
|
728
|
+
let checkVisible = true;
|
|
729
|
+
let checkDisabled = false;
|
|
730
|
+
const checkMethod = permissionMethod || globalConfigStore.permissionMethod;
|
|
731
|
+
if (permissionCode && checkMethod) {
|
|
732
|
+
checkVisible = false;
|
|
733
|
+
checkDisabled = true;
|
|
734
|
+
let vDone = false;
|
|
735
|
+
let dDone = false;
|
|
736
|
+
const codeList = String(permissionCode).split("|");
|
|
737
|
+
for (let i = 0; i < codeList.length; i++) {
|
|
738
|
+
const code = codeList[i];
|
|
739
|
+
let visible = true;
|
|
740
|
+
let disabled = false;
|
|
741
|
+
const rest = checkMethod({ code });
|
|
742
|
+
if (XEUtils14.isBoolean(rest)) {
|
|
743
|
+
visible = rest;
|
|
744
|
+
} else if (rest) {
|
|
745
|
+
visible = !!rest.visible;
|
|
746
|
+
disabled = !!rest.disabled;
|
|
747
|
+
}
|
|
748
|
+
if (!disabled && !dDone) {
|
|
749
|
+
dDone = true;
|
|
750
|
+
checkDisabled = disabled;
|
|
751
|
+
}
|
|
752
|
+
if (visible && !vDone) {
|
|
753
|
+
vDone = true;
|
|
754
|
+
checkVisible = visible;
|
|
755
|
+
}
|
|
756
|
+
if (vDone && dDone) {
|
|
757
|
+
break;
|
|
758
|
+
}
|
|
759
|
+
}
|
|
760
|
+
}
|
|
761
|
+
const info = {
|
|
762
|
+
code: permissionCode,
|
|
763
|
+
visible: checkVisible,
|
|
764
|
+
disabled: checkDisabled
|
|
765
|
+
};
|
|
766
|
+
return info;
|
|
804
767
|
}
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
768
|
+
var permission = {
|
|
769
|
+
getCheckInfo(code) {
|
|
770
|
+
return handleCheckInfo(code);
|
|
771
|
+
},
|
|
772
|
+
checkVisible(code) {
|
|
773
|
+
const permissionInfo = handleCheckInfo(code);
|
|
774
|
+
return permissionInfo.visible;
|
|
775
|
+
},
|
|
776
|
+
checkDisable(code) {
|
|
777
|
+
const permissionInfo = handleCheckInfo(code);
|
|
778
|
+
return permissionInfo.disabled;
|
|
779
|
+
}
|
|
817
780
|
};
|
|
818
781
|
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
782
|
+
// packages_temp/src/z-index.ts
|
|
783
|
+
import DomZIndex2 from "dom-zindex";
|
|
784
|
+
var zIndex = {
|
|
785
|
+
/**
|
|
786
|
+
* 获取主层级下一个 z-index
|
|
787
|
+
*/
|
|
788
|
+
next() {
|
|
789
|
+
return DomZIndex2.getNext();
|
|
790
|
+
},
|
|
791
|
+
/**
|
|
792
|
+
* 获取主层级最后一个 z-index
|
|
793
|
+
*/
|
|
794
|
+
getLast() {
|
|
795
|
+
return DomZIndex2.getCurrent();
|
|
796
|
+
},
|
|
797
|
+
/**
|
|
798
|
+
* 获取子层级的下一个 z-index
|
|
799
|
+
*/
|
|
800
|
+
nextSub() {
|
|
801
|
+
return DomZIndex2.getSubNext();
|
|
802
|
+
},
|
|
803
|
+
/**
|
|
804
|
+
* 获取子层级的最后一个 z-index
|
|
805
|
+
*/
|
|
806
|
+
getSubLast() {
|
|
807
|
+
return DomZIndex2.getSubCurrent();
|
|
808
|
+
}
|
|
844
809
|
};
|
|
845
810
|
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
}
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
811
|
+
// packages_temp/src/base-utils.ts
|
|
812
|
+
import XEUtils15 from "xe-utils";
|
|
813
|
+
var baseUtils = {
|
|
814
|
+
/**
|
|
815
|
+
* 转成字符串
|
|
816
|
+
*/
|
|
817
|
+
toString(content) {
|
|
818
|
+
if (XEUtils15.eqNull(content)) {
|
|
819
|
+
return "";
|
|
820
|
+
}
|
|
821
|
+
return "" + content;
|
|
822
|
+
},
|
|
823
|
+
/**
|
|
824
|
+
* 判断值为:'' | null | undefined 时都属于空值
|
|
825
|
+
*/
|
|
826
|
+
isEmpty(value) {
|
|
827
|
+
return value === null || value === void 0 || value === "";
|
|
828
|
+
},
|
|
829
|
+
/**
|
|
830
|
+
* 获取配置值,如果存在则返回,如果不存在则使用默认值
|
|
831
|
+
*/
|
|
832
|
+
getDefVal(value, defVal) {
|
|
833
|
+
return XEUtils15.eqNull(value) ? defVal : value;
|
|
834
|
+
},
|
|
835
|
+
/**
|
|
836
|
+
* 判断是否启用
|
|
837
|
+
*/
|
|
838
|
+
isEnabled(conf) {
|
|
839
|
+
return !!(conf && conf.enabled !== false);
|
|
840
|
+
},
|
|
841
|
+
/**
|
|
842
|
+
* 用于开关类型的配置项
|
|
843
|
+
* 局部启用规则:conf={}
|
|
844
|
+
* 局部禁用规则:conf={enabled:false}
|
|
845
|
+
* 全局默认启用规则:conf.enabled=true
|
|
846
|
+
*/
|
|
847
|
+
hasEnableConf(conf, opts) {
|
|
848
|
+
return !!(opts && (conf ? opts.enabled !== false : opts.enabled));
|
|
849
|
+
}
|
|
883
850
|
};
|
|
884
851
|
|
|
885
|
-
|
|
852
|
+
// packages_temp/src/dom-utils.ts
|
|
853
|
+
import XEUtils16 from "xe-utils";
|
|
854
|
+
var reClsMap = {};
|
|
886
855
|
function getClsRE(cls) {
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
856
|
+
if (!reClsMap[cls]) {
|
|
857
|
+
reClsMap[cls] = new RegExp(`(?:^|\\s)${cls}(?!\\S)`, "g");
|
|
858
|
+
}
|
|
859
|
+
return reClsMap[cls];
|
|
891
860
|
}
|
|
892
|
-
/**
|
|
893
|
-
* 判断元素是否包含 class
|
|
894
|
-
*/
|
|
895
861
|
function hasClass(elem, cls) {
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
}
|
|
900
|
-
return !!(elem.className && elem.className.match && elem.className.match(getClsRE(cls)));
|
|
862
|
+
if (elem) {
|
|
863
|
+
if (elem.classList) {
|
|
864
|
+
return elem.classList.contains(cls);
|
|
901
865
|
}
|
|
902
|
-
return
|
|
866
|
+
return !!(elem.className && elem.className.match && elem.className.match(getClsRE(cls)));
|
|
867
|
+
}
|
|
868
|
+
return false;
|
|
903
869
|
}
|
|
904
|
-
/**
|
|
905
|
-
* 给元素删除 class
|
|
906
|
-
*/
|
|
907
870
|
function removeClass(elem, cls) {
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
871
|
+
if (elem && hasClass(elem, cls)) {
|
|
872
|
+
elem.className = elem.className.replace(getClsRE(cls), "");
|
|
873
|
+
}
|
|
911
874
|
}
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
}
|
|
953
|
-
}
|
|
875
|
+
var domUtils = {
|
|
876
|
+
/**
|
|
877
|
+
* 判断是否像素px单位 '100px' | 100
|
|
878
|
+
*/
|
|
879
|
+
isPx(val) {
|
|
880
|
+
return val && /^\d+(\.\d+)?(px)?$/.test(val);
|
|
881
|
+
},
|
|
882
|
+
/**
|
|
883
|
+
* 判断是否百分比%单位 '100%'
|
|
884
|
+
*/
|
|
885
|
+
isScale(val) {
|
|
886
|
+
return val && /^\d+(\.\d+)?%$/.test(val);
|
|
887
|
+
},
|
|
888
|
+
/**
|
|
889
|
+
* 判断元素是否包含 class
|
|
890
|
+
*/
|
|
891
|
+
hasClass,
|
|
892
|
+
/**
|
|
893
|
+
* 给元素删除 class
|
|
894
|
+
*/
|
|
895
|
+
removeClass,
|
|
896
|
+
/**
|
|
897
|
+
* 给元素增加 class
|
|
898
|
+
*/
|
|
899
|
+
addClass(elem, cls) {
|
|
900
|
+
if (elem && !hasClass(elem, cls)) {
|
|
901
|
+
removeClass(elem, cls);
|
|
902
|
+
elem.className = elem.className + " " + cls;
|
|
903
|
+
}
|
|
904
|
+
},
|
|
905
|
+
/**
|
|
906
|
+
* 生成 className
|
|
907
|
+
*/
|
|
908
|
+
buildClass(staticClassNames, mapClassName) {
|
|
909
|
+
const parts = [];
|
|
910
|
+
if (staticClassNames) {
|
|
911
|
+
for (let i = 0; i < staticClassNames.length; i++) {
|
|
912
|
+
const val = staticClassNames[i];
|
|
913
|
+
if (val) {
|
|
914
|
+
parts.push("" + val);
|
|
954
915
|
}
|
|
955
|
-
|
|
956
|
-
if (val) {
|
|
957
|
-
parts.push(key);
|
|
958
|
-
}
|
|
959
|
-
});
|
|
960
|
-
return parts.join(' ');
|
|
916
|
+
}
|
|
961
917
|
}
|
|
918
|
+
XEUtils16.each(mapClassName, (val, key) => {
|
|
919
|
+
if (val) {
|
|
920
|
+
parts.push(key);
|
|
921
|
+
}
|
|
922
|
+
});
|
|
923
|
+
return parts.join(" ");
|
|
924
|
+
}
|
|
962
925
|
};
|
|
963
926
|
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
927
|
+
// packages_temp/src/scrollbar-utils.ts
|
|
928
|
+
var scrollbarUtils = {
|
|
929
|
+
/**
|
|
930
|
+
* 计算滚动条滑块的长度
|
|
931
|
+
*/
|
|
932
|
+
getThumbSize(viewportSize, contentSize, trackSize) {
|
|
933
|
+
if (contentSize <= viewportSize) {
|
|
934
|
+
return 0;
|
|
935
|
+
}
|
|
936
|
+
const ratio = viewportSize / contentSize;
|
|
937
|
+
const ideal = trackSize * ratio;
|
|
938
|
+
return Math.max(20, Math.min(ideal, trackSize));
|
|
939
|
+
},
|
|
940
|
+
/**
|
|
941
|
+
* 计算滚动条滑块的偏移位置
|
|
942
|
+
*/
|
|
943
|
+
getThumbOffsetSize(offsetSize, viewportSize, contentSize, trackSize, thumbSize) {
|
|
944
|
+
const maxScroll = contentSize - viewportSize;
|
|
945
|
+
if (maxScroll <= 0) {
|
|
946
|
+
return 0;
|
|
947
|
+
}
|
|
948
|
+
const maxThumbOffset = trackSize - thumbSize;
|
|
949
|
+
if (maxThumbOffset <= 0) {
|
|
950
|
+
return 0;
|
|
951
|
+
}
|
|
952
|
+
const clamped = Math.min(Math.max(offsetSize, 0), maxScroll);
|
|
953
|
+
const ratio = clamped / maxScroll;
|
|
954
|
+
return ratio * maxThumbOffset;
|
|
955
|
+
},
|
|
956
|
+
/**
|
|
957
|
+
* 根据点击轨道的位置,计算滑块的偏移位置
|
|
958
|
+
*/
|
|
959
|
+
getScrollFromClick(clickPosition, viewportSize, contentSize, trackSize, thumbSize) {
|
|
960
|
+
const maxThumbOffset = trackSize - thumbSize;
|
|
961
|
+
const maxScroll = contentSize - viewportSize;
|
|
962
|
+
if (maxScroll <= 0 || maxThumbOffset <= 0) {
|
|
963
|
+
return 0;
|
|
964
|
+
}
|
|
965
|
+
let thumbOffset = clickPosition - thumbSize / 2;
|
|
966
|
+
thumbOffset = Math.min(Math.max(thumbOffset, 0), maxThumbOffset);
|
|
967
|
+
const scrollOffset = thumbOffset / maxThumbOffset * maxScroll;
|
|
968
|
+
return scrollOffset;
|
|
969
|
+
},
|
|
970
|
+
/**
|
|
971
|
+
* 拖拽 thumb 时,根据鼠标位置计算滑块的偏移位置
|
|
972
|
+
*/
|
|
973
|
+
getScrollFromDrag(pointerPosition, dragOffset, viewportSize, contentSize, trackSize, thumbSize) {
|
|
974
|
+
const maxScroll = contentSize - viewportSize;
|
|
975
|
+
const maxThumbOffset = trackSize - thumbSize;
|
|
976
|
+
if (maxScroll <= 0 || maxThumbOffset <= 0) {
|
|
977
|
+
return 0;
|
|
978
|
+
}
|
|
979
|
+
let thumbOffset = pointerPosition - dragOffset;
|
|
980
|
+
thumbOffset = Math.min(Math.max(thumbOffset, 0), maxThumbOffset);
|
|
981
|
+
return thumbOffset / maxThumbOffset * maxScroll;
|
|
982
|
+
}
|
|
1019
983
|
};
|
|
1020
984
|
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
*/
|
|
985
|
+
// packages_temp/src/popper-utils.ts
|
|
986
|
+
import XEUtils17 from "xe-utils";
|
|
1024
987
|
function getWrapperElement(panelElem) {
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
988
|
+
if (!panelElem) {
|
|
989
|
+
return null;
|
|
990
|
+
}
|
|
991
|
+
const bodyEl = document.body;
|
|
992
|
+
const parentEl = panelElem.parentElement;
|
|
993
|
+
return (parentEl === bodyEl ? document.documentElement : parentEl) || null;
|
|
1031
994
|
}
|
|
1032
|
-
/**
|
|
1033
|
-
* 获取插入到指定容器的元素或字符串
|
|
1034
|
-
*/
|
|
1035
995
|
function getAppendSelector(appendTo) {
|
|
1036
|
-
|
|
1037
|
-
|
|
996
|
+
const selectElem = appendTo && XEUtils17.isFunction(appendTo) ? appendTo({}) : appendTo;
|
|
997
|
+
return selectElem || "body";
|
|
1038
998
|
}
|
|
1039
|
-
/**
|
|
1040
|
-
* 获取插入到指定容器的元素
|
|
1041
|
-
*/
|
|
1042
999
|
function getAppendElement(appendTo) {
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1000
|
+
const selectElem = getAppendSelector(appendTo);
|
|
1001
|
+
if (XEUtils17.isString(selectElem)) {
|
|
1002
|
+
return document.querySelector(selectElem) || document.body;
|
|
1003
|
+
}
|
|
1004
|
+
return selectElem;
|
|
1048
1005
|
}
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
else if (!placement) {
|
|
1142
|
-
// 如果下面不够放,则向上
|
|
1143
|
-
top = targetHeight;
|
|
1144
|
-
if (targetTop + targetHeight + panelHeight + marginSize > visibleHeight) {
|
|
1145
|
-
// 如果上面不够放,则向下(优先)
|
|
1146
|
-
if (targetTop - targetHeight - panelHeight > marginSize) {
|
|
1147
|
-
panelPlacement = 'top';
|
|
1148
|
-
top = '';
|
|
1149
|
-
bottom = targetHeight;
|
|
1150
|
-
}
|
|
1151
|
-
}
|
|
1152
|
-
}
|
|
1153
|
-
// 是否超出右侧
|
|
1154
|
-
if (panelRect.left + panelRect.width + marginSize > visibleWidth) {
|
|
1155
|
-
left = -(panelRect.left + panelRect.width + marginSize - visibleWidth);
|
|
1156
|
-
}
|
|
1157
|
-
}
|
|
1158
|
-
if (XEUtils.isNumber(top)) {
|
|
1159
|
-
stys.top = top + 'px';
|
|
1160
|
-
}
|
|
1161
|
-
if (XEUtils.isNumber(bottom)) {
|
|
1162
|
-
stys.bottom = bottom + 'px';
|
|
1163
|
-
}
|
|
1164
|
-
if (XEUtils.isNumber(left)) {
|
|
1165
|
-
stys.left = left + 'px';
|
|
1166
|
-
}
|
|
1167
|
-
if (isMinWidth && XEUtils.isNumber(minWidth)) {
|
|
1168
|
-
stys.minWidth = minWidth + 'px';
|
|
1169
|
-
}
|
|
1170
|
-
// 箭头
|
|
1171
|
-
if (left === targetLeft) {
|
|
1172
|
-
if (targetWidth <= panelWidth) {
|
|
1173
|
-
arrowLeft = targetWidth / 2;
|
|
1174
|
-
}
|
|
1175
|
-
}
|
|
1176
|
-
else if (left < targetLeft) {
|
|
1177
|
-
if (left + panelWidth > targetLeft + targetWidth) {
|
|
1178
|
-
arrowLeft = (targetLeft - left) + targetWidth / 2;
|
|
1179
|
-
}
|
|
1180
|
-
else {
|
|
1181
|
-
arrowLeft = (targetLeft - left) + (panelWidth - (targetLeft - left)) / 2;
|
|
1182
|
-
}
|
|
1183
|
-
}
|
|
1006
|
+
var popperUtils = {
|
|
1007
|
+
/**
|
|
1008
|
+
* 更新位置
|
|
1009
|
+
*/
|
|
1010
|
+
updatePlacement(targetElem, panelElem, options) {
|
|
1011
|
+
const { defaultTop, defaultLeft, placement, defaultPlacement, appendTo, teleportTo, marginSize, isMinWidth } = Object.assign(
|
|
1012
|
+
{
|
|
1013
|
+
appendTo: "",
|
|
1014
|
+
teleportTo: false,
|
|
1015
|
+
marginSize: 12,
|
|
1016
|
+
isMinWidth: true
|
|
1017
|
+
},
|
|
1018
|
+
options
|
|
1019
|
+
);
|
|
1020
|
+
let panelPlacement = "bottom";
|
|
1021
|
+
let top = "";
|
|
1022
|
+
let bottom = "";
|
|
1023
|
+
let left = 0;
|
|
1024
|
+
let minWidth = "";
|
|
1025
|
+
let arrowLeft = "";
|
|
1026
|
+
const stys = {};
|
|
1027
|
+
if (panelElem && targetElem) {
|
|
1028
|
+
const bodyEl = document.body;
|
|
1029
|
+
const parentWrapperEl = getWrapperElement(teleportTo ? getAppendElement(appendTo) : panelElem);
|
|
1030
|
+
if (parentWrapperEl) {
|
|
1031
|
+
const targetWidth = targetElem.offsetWidth;
|
|
1032
|
+
const targetHeight = targetElem.offsetHeight;
|
|
1033
|
+
const panelWidth = panelElem.offsetWidth;
|
|
1034
|
+
const panelHeight = panelElem.offsetHeight;
|
|
1035
|
+
const parentWrapperRect = parentWrapperEl.getBoundingClientRect();
|
|
1036
|
+
const panelRect = panelElem.getBoundingClientRect();
|
|
1037
|
+
const targetRect = targetElem.getBoundingClientRect();
|
|
1038
|
+
const visibleHeight = bodyEl.clientHeight;
|
|
1039
|
+
const visibleWidth = bodyEl.clientWidth;
|
|
1040
|
+
const parentWrapperScrollLeft = parentWrapperEl.scrollLeft;
|
|
1041
|
+
const parentWrapperScrollTop = parentWrapperEl.scrollTop;
|
|
1042
|
+
const parentWrapperOffsetLeft = parentWrapperRect.left;
|
|
1043
|
+
const parentWrapperOffsetTop = parentWrapperRect.top;
|
|
1044
|
+
const targetLeft = targetRect.left;
|
|
1045
|
+
const targetTop = targetRect.top;
|
|
1046
|
+
minWidth = targetElem.offsetWidth;
|
|
1047
|
+
if (teleportTo) {
|
|
1048
|
+
left = (defaultLeft || targetLeft - (panelWidth - targetWidth) / 2) - parentWrapperScrollLeft;
|
|
1049
|
+
top = (defaultTop || targetTop + targetHeight) - parentWrapperScrollTop;
|
|
1050
|
+
if (placement === "top") {
|
|
1051
|
+
panelPlacement = "top";
|
|
1052
|
+
top = targetTop - panelHeight;
|
|
1053
|
+
} else if (!placement) {
|
|
1054
|
+
if (defaultPlacement === "top") {
|
|
1055
|
+
panelPlacement = "top";
|
|
1056
|
+
if (!defaultTop) {
|
|
1057
|
+
top = targetTop - panelHeight;
|
|
1058
|
+
}
|
|
1059
|
+
if (top < marginSize) {
|
|
1060
|
+
panelPlacement = "bottom";
|
|
1061
|
+
top = targetTop + targetHeight;
|
|
1062
|
+
}
|
|
1063
|
+
if (top + panelHeight + marginSize > visibleHeight) {
|
|
1064
|
+
panelPlacement = "top";
|
|
1065
|
+
top = targetTop - panelHeight;
|
|
1066
|
+
}
|
|
1067
|
+
} else {
|
|
1068
|
+
if (top + panelHeight + marginSize > visibleHeight) {
|
|
1069
|
+
panelPlacement = "top";
|
|
1070
|
+
top = targetTop - panelHeight;
|
|
1071
|
+
}
|
|
1072
|
+
if (top < marginSize) {
|
|
1073
|
+
panelPlacement = "bottom";
|
|
1074
|
+
top = targetTop + targetHeight;
|
|
1075
|
+
}
|
|
1076
|
+
}
|
|
1077
|
+
}
|
|
1078
|
+
if (left + panelWidth + marginSize > visibleWidth) {
|
|
1079
|
+
left -= left + panelWidth + marginSize - visibleWidth;
|
|
1080
|
+
}
|
|
1081
|
+
if (left < marginSize) {
|
|
1082
|
+
left = marginSize;
|
|
1083
|
+
}
|
|
1084
|
+
top -= parentWrapperOffsetTop;
|
|
1085
|
+
left -= parentWrapperOffsetLeft;
|
|
1086
|
+
} else {
|
|
1087
|
+
if (placement === "top") {
|
|
1088
|
+
panelPlacement = "top";
|
|
1089
|
+
bottom = targetHeight;
|
|
1090
|
+
} else if (!placement) {
|
|
1091
|
+
top = targetHeight;
|
|
1092
|
+
if (targetTop + targetHeight + panelHeight + marginSize > visibleHeight) {
|
|
1093
|
+
if (targetTop - targetHeight - panelHeight > marginSize) {
|
|
1094
|
+
panelPlacement = "top";
|
|
1095
|
+
top = "";
|
|
1096
|
+
bottom = targetHeight;
|
|
1097
|
+
}
|
|
1184
1098
|
}
|
|
1099
|
+
}
|
|
1100
|
+
if (panelRect.left + panelRect.width + marginSize > visibleWidth) {
|
|
1101
|
+
left = -(panelRect.left + panelRect.width + marginSize - visibleWidth);
|
|
1102
|
+
}
|
|
1185
1103
|
}
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1104
|
+
if (XEUtils17.isNumber(top)) {
|
|
1105
|
+
stys.top = top + "px";
|
|
1106
|
+
}
|
|
1107
|
+
if (XEUtils17.isNumber(bottom)) {
|
|
1108
|
+
stys.bottom = bottom + "px";
|
|
1109
|
+
}
|
|
1110
|
+
if (XEUtils17.isNumber(left)) {
|
|
1111
|
+
stys.left = left + "px";
|
|
1112
|
+
}
|
|
1113
|
+
if (isMinWidth && XEUtils17.isNumber(minWidth)) {
|
|
1114
|
+
stys.minWidth = minWidth + "px";
|
|
1115
|
+
}
|
|
1116
|
+
if (left === targetLeft) {
|
|
1117
|
+
if (targetWidth <= panelWidth) {
|
|
1118
|
+
arrowLeft = targetWidth / 2;
|
|
1119
|
+
}
|
|
1120
|
+
} else if (left < targetLeft) {
|
|
1121
|
+
if (left + panelWidth > targetLeft + targetWidth) {
|
|
1122
|
+
arrowLeft = targetLeft - left + targetWidth / 2;
|
|
1123
|
+
} else {
|
|
1124
|
+
arrowLeft = targetLeft - left + (panelWidth - (targetLeft - left)) / 2;
|
|
1125
|
+
}
|
|
1126
|
+
}
|
|
1127
|
+
}
|
|
1128
|
+
}
|
|
1129
|
+
return {
|
|
1130
|
+
top: top || 0,
|
|
1131
|
+
bottom: bottom || 0,
|
|
1132
|
+
left: left || 0,
|
|
1133
|
+
arrowLeft: arrowLeft || 0,
|
|
1134
|
+
style: stys,
|
|
1135
|
+
placement: panelPlacement
|
|
1136
|
+
};
|
|
1137
|
+
},
|
|
1138
|
+
/**
|
|
1139
|
+
* 获取包裹容器的元素
|
|
1140
|
+
*/
|
|
1141
|
+
getWrapperElement,
|
|
1142
|
+
/**
|
|
1143
|
+
* 获取插入到指定容器的元素或字符串
|
|
1144
|
+
*/
|
|
1145
|
+
getAppendSelector,
|
|
1146
|
+
/**
|
|
1147
|
+
* 获取插入到指定容器的元素
|
|
1148
|
+
*/
|
|
1149
|
+
getAppendElement
|
|
1207
1150
|
};
|
|
1208
1151
|
|
|
1209
|
-
|
|
1152
|
+
// packages_temp/src/hooks.ts
|
|
1153
|
+
var hooks = new store_default();
|
|
1210
1154
|
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
* @returns
|
|
1216
|
-
*/
|
|
1155
|
+
// packages_temp/src/useFns.ts
|
|
1156
|
+
import XEUtils18 from "xe-utils";
|
|
1157
|
+
import { computed, ref, inject, provide } from "vue";
|
|
1158
|
+
var { getThumbOffsetSize, getThumbSize, getScrollFromClick, getScrollFromDrag } = scrollbarUtils;
|
|
1217
1159
|
function useSize(props) {
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1160
|
+
const xeSizeInfo = inject("xeSizeInfo", null);
|
|
1161
|
+
const computeSize = computed(() => {
|
|
1162
|
+
const { size } = props;
|
|
1163
|
+
return size || (xeSizeInfo ? xeSizeInfo.value : null);
|
|
1164
|
+
});
|
|
1165
|
+
provide("xeSizeInfo", computeSize);
|
|
1166
|
+
return { computeSize };
|
|
1225
1167
|
}
|
|
1226
|
-
/**
|
|
1227
|
-
* 权限码处理
|
|
1228
|
-
* @param props
|
|
1229
|
-
* @returns
|
|
1230
|
-
*/
|
|
1231
1168
|
function usePermission(props) {
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1169
|
+
const computePermissionInfo = computed(() => {
|
|
1170
|
+
return handleCheckInfo(props.permissionCode, props.permissionMethod);
|
|
1171
|
+
});
|
|
1172
|
+
return {
|
|
1173
|
+
computePermissionInfo
|
|
1174
|
+
};
|
|
1238
1175
|
}
|
|
1239
|
-
/**
|
|
1240
|
-
* 虚拟滚动条是否启用
|
|
1241
|
-
* @param props
|
|
1242
|
-
* @returns
|
|
1243
|
-
*/
|
|
1244
1176
|
function useVScrollbar(props) {
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1177
|
+
const xeScrollbarInfo = inject("xeScrollbarInfo", null);
|
|
1178
|
+
const computeIsVScrollbar = computed(() => {
|
|
1179
|
+
const { useScrollbar } = props;
|
|
1180
|
+
return XEUtils18.isBoolean(useScrollbar) ? useScrollbar : xeScrollbarInfo ? xeScrollbarInfo.value : null;
|
|
1181
|
+
});
|
|
1182
|
+
provide("xeScrollbarInfo", computeIsVScrollbar);
|
|
1183
|
+
return { computeIsVScrollbar };
|
|
1252
1184
|
}
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
const
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
const
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
};
|
|
1387
|
-
const
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
refThumbYElem,
|
|
1427
|
-
updateThumbSize,
|
|
1428
|
-
updateThumbOffset,
|
|
1429
|
-
clickTrackXEvent,
|
|
1430
|
-
clickTrackYEvent,
|
|
1431
|
-
pointerdownThumbXEvent,
|
|
1432
|
-
pointermoveThumbXEvent,
|
|
1433
|
-
cleatPointerThumbEvent,
|
|
1434
|
-
pointerdownThumbYEvent,
|
|
1435
|
-
pointermoveThumbYEvent
|
|
1436
|
-
};
|
|
1185
|
+
var useInitVScrollbar = ($xeVM) => {
|
|
1186
|
+
const { reactData, internalData } = $xeVM;
|
|
1187
|
+
const refTrackXElem = ref();
|
|
1188
|
+
const refTrackYElem = ref();
|
|
1189
|
+
const refThumbXElem = ref();
|
|
1190
|
+
const refThumbYElem = ref();
|
|
1191
|
+
const updateThumbSize = () => {
|
|
1192
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1193
|
+
if (!viewEl) {
|
|
1194
|
+
return;
|
|
1195
|
+
}
|
|
1196
|
+
if (!viewEl.clientHeight || !viewEl.clientHeight) {
|
|
1197
|
+
return;
|
|
1198
|
+
}
|
|
1199
|
+
const trackXEl = refTrackXElem.value;
|
|
1200
|
+
const xThumbWidth = trackXEl ? getThumbSize(viewEl.clientWidth, viewEl.scrollWidth, trackXEl.clientWidth) : 0;
|
|
1201
|
+
const thumbXElem = refThumbXElem.value;
|
|
1202
|
+
if (thumbXElem) {
|
|
1203
|
+
thumbXElem.style.width = xThumbWidth + "px";
|
|
1204
|
+
}
|
|
1205
|
+
reactData.xThumbWidth = xThumbWidth;
|
|
1206
|
+
const trackYEl = refTrackYElem.value;
|
|
1207
|
+
const yThumbHeight = trackYEl ? getThumbSize(viewEl.clientHeight, viewEl.scrollHeight, trackYEl.clientHeight) : 0;
|
|
1208
|
+
const thumbYElem = refThumbYElem.value;
|
|
1209
|
+
if (thumbYElem) {
|
|
1210
|
+
thumbYElem.style.height = yThumbHeight + "px";
|
|
1211
|
+
}
|
|
1212
|
+
reactData.yThumbHeight = yThumbHeight;
|
|
1213
|
+
};
|
|
1214
|
+
const updateThumbOffset = () => {
|
|
1215
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1216
|
+
if (!viewEl) {
|
|
1217
|
+
return;
|
|
1218
|
+
}
|
|
1219
|
+
if (!viewEl.clientHeight || !viewEl.clientHeight) {
|
|
1220
|
+
return;
|
|
1221
|
+
}
|
|
1222
|
+
const { xThumbWidth, yThumbHeight } = reactData;
|
|
1223
|
+
const trackXEl = refTrackXElem.value;
|
|
1224
|
+
const thumbXElem = refThumbXElem.value;
|
|
1225
|
+
const xThumbLeft = trackXEl && xThumbWidth ? getThumbOffsetSize(viewEl.scrollLeft, viewEl.clientWidth, viewEl.scrollWidth, trackXEl.clientWidth, xThumbWidth) : 0;
|
|
1226
|
+
internalData.xThumbLeft = xThumbLeft;
|
|
1227
|
+
if (thumbXElem && xThumbWidth) {
|
|
1228
|
+
thumbXElem.style.width = xThumbWidth + "px";
|
|
1229
|
+
thumbXElem.style.transform = `translateX(${xThumbLeft}px)`;
|
|
1230
|
+
}
|
|
1231
|
+
const trackYEl = refTrackYElem.value;
|
|
1232
|
+
const thumbYElem = refThumbYElem.value;
|
|
1233
|
+
const yThumbTop = trackYEl && yThumbHeight ? getThumbOffsetSize(viewEl.scrollTop, viewEl.clientHeight, viewEl.scrollHeight, trackYEl.clientHeight, yThumbHeight) : 0;
|
|
1234
|
+
internalData.yThumbTop = yThumbTop;
|
|
1235
|
+
if (thumbYElem && yThumbHeight) {
|
|
1236
|
+
thumbYElem.style.height = yThumbHeight + "px";
|
|
1237
|
+
thumbYElem.style.transform = `translateY(${yThumbTop}px)`;
|
|
1238
|
+
}
|
|
1239
|
+
};
|
|
1240
|
+
const clickTrackXEvent = (evnt) => {
|
|
1241
|
+
const trackEl = evnt.currentTarget;
|
|
1242
|
+
if (trackEl !== evnt.target) {
|
|
1243
|
+
return;
|
|
1244
|
+
}
|
|
1245
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1246
|
+
if (!viewEl) {
|
|
1247
|
+
return;
|
|
1248
|
+
}
|
|
1249
|
+
const { xThumbWidth } = reactData;
|
|
1250
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1251
|
+
viewEl.scrollTo({
|
|
1252
|
+
left: getScrollFromClick(evnt.clientX - trackRect.left, viewEl.clientWidth, viewEl.scrollWidth, trackEl.clientWidth, xThumbWidth),
|
|
1253
|
+
behavior: "auto"
|
|
1254
|
+
});
|
|
1255
|
+
};
|
|
1256
|
+
const clickTrackYEvent = (evnt) => {
|
|
1257
|
+
const trackEl = evnt.currentTarget;
|
|
1258
|
+
if (trackEl !== evnt.target) {
|
|
1259
|
+
return;
|
|
1260
|
+
}
|
|
1261
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1262
|
+
if (!viewEl) {
|
|
1263
|
+
return;
|
|
1264
|
+
}
|
|
1265
|
+
const { yThumbHeight } = reactData;
|
|
1266
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1267
|
+
viewEl.scrollTo({
|
|
1268
|
+
top: getScrollFromClick(evnt.clientY - trackRect.top, viewEl.clientHeight, viewEl.scrollHeight, trackEl.clientHeight, yThumbHeight),
|
|
1269
|
+
behavior: "auto"
|
|
1270
|
+
});
|
|
1271
|
+
};
|
|
1272
|
+
const pointerdownThumbXEvent = (evnt) => {
|
|
1273
|
+
const thumbEl = evnt.currentTarget;
|
|
1274
|
+
internalData.isThumbDrag = true;
|
|
1275
|
+
thumbEl.setPointerCapture(evnt.pointerId);
|
|
1276
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1277
|
+
if (!viewEl) {
|
|
1278
|
+
return;
|
|
1279
|
+
}
|
|
1280
|
+
const { xThumbWidth } = reactData;
|
|
1281
|
+
const trackEl = thumbEl.parentElement;
|
|
1282
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1283
|
+
const pointerPosition = evnt.clientX - trackRect.left;
|
|
1284
|
+
const thumbOffset = getThumbOffsetSize(viewEl.scrollLeft, viewEl.clientWidth, viewEl.scrollWidth, trackEl.clientWidth, xThumbWidth);
|
|
1285
|
+
internalData.thumbDragOffset = pointerPosition - thumbOffset;
|
|
1286
|
+
};
|
|
1287
|
+
const pointermoveThumbXEvent = (evnt) => {
|
|
1288
|
+
const thumbEl = evnt.currentTarget;
|
|
1289
|
+
if (!thumbEl.hasPointerCapture(evnt.pointerId)) {
|
|
1290
|
+
return;
|
|
1291
|
+
}
|
|
1292
|
+
const { isThumbDrag, thumbDragOffset } = internalData;
|
|
1293
|
+
if (isThumbDrag) {
|
|
1294
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1295
|
+
if (!viewEl) {
|
|
1296
|
+
return;
|
|
1297
|
+
}
|
|
1298
|
+
const { xThumbWidth } = reactData;
|
|
1299
|
+
const thumbEl2 = evnt.currentTarget;
|
|
1300
|
+
const trackEl = thumbEl2.parentElement;
|
|
1301
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1302
|
+
viewEl.scrollLeft = getScrollFromDrag(evnt.clientX - trackRect.left, thumbDragOffset, viewEl.clientWidth, viewEl.scrollWidth, trackEl.clientWidth, xThumbWidth);
|
|
1303
|
+
}
|
|
1304
|
+
};
|
|
1305
|
+
const cleatPointerThumbEvent = (evnt) => {
|
|
1306
|
+
const thumbEl = evnt.currentTarget;
|
|
1307
|
+
thumbEl.releasePointerCapture(evnt.pointerId);
|
|
1308
|
+
internalData.isThumbDrag = false;
|
|
1309
|
+
};
|
|
1310
|
+
const pointerdownThumbYEvent = (evnt) => {
|
|
1311
|
+
const thumbEl = evnt.currentTarget;
|
|
1312
|
+
internalData.isThumbDrag = true;
|
|
1313
|
+
thumbEl.setPointerCapture(evnt.pointerId);
|
|
1314
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1315
|
+
if (!viewEl) {
|
|
1316
|
+
return;
|
|
1317
|
+
}
|
|
1318
|
+
const { yThumbHeight } = reactData;
|
|
1319
|
+
const trackEl = thumbEl.parentElement;
|
|
1320
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1321
|
+
const pointerPosition = evnt.clientY - trackRect.top;
|
|
1322
|
+
const thumbOffset = getThumbOffsetSize(viewEl.scrollTop, viewEl.clientHeight, viewEl.scrollHeight, trackEl.clientHeight, yThumbHeight);
|
|
1323
|
+
internalData.thumbDragOffset = pointerPosition - thumbOffset;
|
|
1324
|
+
};
|
|
1325
|
+
const pointermoveThumbYEvent = (evnt) => {
|
|
1326
|
+
const thumbEl = evnt.currentTarget;
|
|
1327
|
+
if (!thumbEl.hasPointerCapture(evnt.pointerId)) {
|
|
1328
|
+
return;
|
|
1329
|
+
}
|
|
1330
|
+
const { isThumbDrag, thumbDragOffset } = internalData;
|
|
1331
|
+
if (isThumbDrag) {
|
|
1332
|
+
const viewEl = $xeVM.getScrollViewElem();
|
|
1333
|
+
if (!viewEl) {
|
|
1334
|
+
return;
|
|
1335
|
+
}
|
|
1336
|
+
const { yThumbHeight } = reactData;
|
|
1337
|
+
const thumbEl2 = evnt.currentTarget;
|
|
1338
|
+
const trackEl = thumbEl2.parentElement;
|
|
1339
|
+
const trackRect = trackEl.getBoundingClientRect();
|
|
1340
|
+
viewEl.scrollTop = getScrollFromDrag(evnt.clientY - trackRect.top, thumbDragOffset, viewEl.clientHeight, viewEl.scrollHeight, trackEl.clientHeight, yThumbHeight);
|
|
1341
|
+
}
|
|
1342
|
+
};
|
|
1343
|
+
return {
|
|
1344
|
+
refTrackXElem,
|
|
1345
|
+
refTrackYElem,
|
|
1346
|
+
refThumbXElem,
|
|
1347
|
+
refThumbYElem,
|
|
1348
|
+
updateThumbSize,
|
|
1349
|
+
updateThumbOffset,
|
|
1350
|
+
clickTrackXEvent,
|
|
1351
|
+
clickTrackYEvent,
|
|
1352
|
+
pointerdownThumbXEvent,
|
|
1353
|
+
pointermoveThumbXEvent,
|
|
1354
|
+
cleatPointerThumbEvent,
|
|
1355
|
+
pointerdownThumbYEvent,
|
|
1356
|
+
pointermoveThumbYEvent
|
|
1357
|
+
};
|
|
1437
1358
|
};
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1359
|
+
var useFns = {
|
|
1360
|
+
useSize,
|
|
1361
|
+
useVScrollbar,
|
|
1362
|
+
usePermission,
|
|
1363
|
+
useInitVScrollbar
|
|
1443
1364
|
};
|
|
1444
1365
|
|
|
1445
|
-
|
|
1366
|
+
// packages_temp/index.ts
|
|
1367
|
+
import XEUtils19 from "xe-utils";
|
|
1368
|
+
var installedPlugins = [];
|
|
1446
1369
|
function use(Plugin, options) {
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
}
|
|
1370
|
+
if (Plugin && Plugin.install) {
|
|
1371
|
+
if (installedPlugins.indexOf(Plugin) === -1) {
|
|
1372
|
+
Plugin.install(VxeUI, options);
|
|
1373
|
+
installedPlugins.push(Plugin);
|
|
1452
1374
|
}
|
|
1453
|
-
|
|
1375
|
+
}
|
|
1376
|
+
return VxeUI;
|
|
1454
1377
|
}
|
|
1455
|
-
|
|
1378
|
+
var components = {};
|
|
1456
1379
|
function getComponent(name) {
|
|
1457
|
-
|
|
1380
|
+
return components[name] || null;
|
|
1458
1381
|
}
|
|
1459
1382
|
function hasComponent(name) {
|
|
1460
|
-
|
|
1383
|
+
return !!components[name];
|
|
1461
1384
|
}
|
|
1462
1385
|
function component(comp) {
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1386
|
+
if (comp && comp.name) {
|
|
1387
|
+
components[comp.name] = comp;
|
|
1388
|
+
components[XEUtils19.kebabCase(comp.name)] = comp;
|
|
1389
|
+
}
|
|
1467
1390
|
}
|
|
1468
1391
|
function renderEmptyElement() {
|
|
1469
|
-
|
|
1392
|
+
return createCommentVNode();
|
|
1470
1393
|
}
|
|
1471
|
-
function checkVersion(
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1394
|
+
function checkVersion(version2, pVersion, sVersion) {
|
|
1395
|
+
if (version2) {
|
|
1396
|
+
const vRest = `${version2}`.match(/(\d+).(\d+).(\d+)/);
|
|
1397
|
+
if (vRest) {
|
|
1398
|
+
const pV = XEUtils19.toNumber(vRest[1]);
|
|
1399
|
+
if (sVersion) {
|
|
1400
|
+
const sV = XEUtils19.toNumber(vRest[2]);
|
|
1401
|
+
return pV >= pVersion && sV >= sVersion;
|
|
1402
|
+
}
|
|
1403
|
+
return pV >= pVersion;
|
|
1404
|
+
}
|
|
1405
|
+
}
|
|
1406
|
+
return false;
|
|
1484
1407
|
}
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1408
|
+
var VxeUI = Object.assign(VxeCore, {
|
|
1409
|
+
renderEmptyElement,
|
|
1410
|
+
setTheme,
|
|
1411
|
+
getTheme,
|
|
1412
|
+
setConfig,
|
|
1413
|
+
getConfig,
|
|
1414
|
+
setIcon,
|
|
1415
|
+
getIcon,
|
|
1416
|
+
renderGlobalIcon,
|
|
1417
|
+
renderCustomIcon,
|
|
1418
|
+
setLanguage,
|
|
1419
|
+
hasLanguage,
|
|
1420
|
+
getLanguage,
|
|
1421
|
+
setI18n,
|
|
1422
|
+
getI18n,
|
|
1423
|
+
globalEvents,
|
|
1424
|
+
GLOBAL_EVENT_KEYS,
|
|
1425
|
+
createEvent,
|
|
1426
|
+
globalResize,
|
|
1427
|
+
renderer,
|
|
1428
|
+
validators,
|
|
1429
|
+
menus,
|
|
1430
|
+
formats,
|
|
1431
|
+
commands,
|
|
1432
|
+
interceptor,
|
|
1433
|
+
clipboard,
|
|
1434
|
+
log,
|
|
1435
|
+
permission,
|
|
1436
|
+
zIndex,
|
|
1437
|
+
baseUtils,
|
|
1438
|
+
domUtils,
|
|
1439
|
+
scrollbarUtils,
|
|
1440
|
+
popperUtils,
|
|
1441
|
+
globalStore,
|
|
1442
|
+
hooks,
|
|
1443
|
+
component,
|
|
1444
|
+
getComponent,
|
|
1445
|
+
hasComponent,
|
|
1446
|
+
useFns,
|
|
1447
|
+
getSlotVNs,
|
|
1448
|
+
checkVersion,
|
|
1449
|
+
use
|
|
1527
1450
|
});
|
|
1528
1451
|
setTheme();
|
|
1529
|
-
|
|
1530
|
-
export {
|
|
1452
|
+
var index_default = VxeUI;
|
|
1453
|
+
export {
|
|
1454
|
+
GLOBAL_EVENT_KEYS,
|
|
1455
|
+
VxeCore,
|
|
1456
|
+
VxeUI,
|
|
1457
|
+
baseUtils,
|
|
1458
|
+
checkVersion,
|
|
1459
|
+
clipboard,
|
|
1460
|
+
commands,
|
|
1461
|
+
component,
|
|
1462
|
+
coreVersion,
|
|
1463
|
+
createEvent,
|
|
1464
|
+
index_default as default,
|
|
1465
|
+
domUtils,
|
|
1466
|
+
formats,
|
|
1467
|
+
getComponent,
|
|
1468
|
+
getConfig,
|
|
1469
|
+
getI18n,
|
|
1470
|
+
getIcon,
|
|
1471
|
+
getLanguage,
|
|
1472
|
+
getSlotVNs,
|
|
1473
|
+
getTheme,
|
|
1474
|
+
globalEvents,
|
|
1475
|
+
globalResize,
|
|
1476
|
+
globalStore,
|
|
1477
|
+
handleCheckInfo,
|
|
1478
|
+
hasComponent,
|
|
1479
|
+
hasLanguage,
|
|
1480
|
+
hooks,
|
|
1481
|
+
interceptor,
|
|
1482
|
+
log,
|
|
1483
|
+
menus,
|
|
1484
|
+
permission,
|
|
1485
|
+
popperUtils,
|
|
1486
|
+
renderCustomIcon,
|
|
1487
|
+
renderEmptyElement,
|
|
1488
|
+
renderGlobalIcon,
|
|
1489
|
+
renderer,
|
|
1490
|
+
scrollbarUtils,
|
|
1491
|
+
setConfig,
|
|
1492
|
+
setI18n,
|
|
1493
|
+
setIcon,
|
|
1494
|
+
setLanguage,
|
|
1495
|
+
setTheme,
|
|
1496
|
+
use,
|
|
1497
|
+
useFns,
|
|
1498
|
+
useInitVScrollbar,
|
|
1499
|
+
usePermission,
|
|
1500
|
+
useSize,
|
|
1501
|
+
useVScrollbar,
|
|
1502
|
+
validators,
|
|
1503
|
+
zIndex
|
|
1504
|
+
};
|