@ibiz-template/vue3-components 0.5.7-alpha.5 → 0.5.7-alpha.9
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/index-vJ69ZIJV.js +1 -0
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/{xlsx-util-74o5wGKy.js → xlsx-util-gM6xqNsx.js} +1 -1
- package/es/common/grid-setting/grid-setting.css +1 -1
- package/es/common/grid-setting/grid-setting.mjs +23 -4
- package/es/control/calendar/calendar.mjs +1 -1
- package/es/control/data-view/data-view.mjs +3 -2
- package/es/control/drtab/drtab.css +1 -1
- package/es/control/form/form-detail/form-mdctrl/form-mdctrl-md/form-mdctrl-md.css +1 -1
- package/es/control/grid/grid/grid.css +1 -1
- package/es/control/grid/grid/grid.mjs +1 -4
- package/es/control/search-bar/filter-mode-select/filter-mode-select.d.ts +5 -1
- package/es/control/search-bar/filter-mode-select/filter-mode-select.mjs +3 -1
- package/es/control/search-bar/filter-tree/filter-tree.mjs +13 -1
- package/es/control/search-bar/search-bar.mjs +1 -1
- package/es/control/tab-exp-panel/tab-exp-panel.mjs +32 -1
- package/es/editor/date-range/ibiz-date-range-picker/ibiz-date-range-picker.css +1 -1
- package/es/index.d.ts +0 -1
- package/es/index.mjs +0 -1
- package/es/panel-component/auth-userinfo/auth-userinfo.css +1 -1
- package/es/panel-component/panel-app-login-view/index.d.ts +1 -0
- package/es/panel-component/panel-app-login-view/panel-app-login-view.css +1 -1
- package/es/panel-component/panel-app-login-view/panel-app-login-view.d.ts +1 -0
- package/es/panel-component/panel-app-login-view/panel-app-login-view.mjs +18 -1
- package/es/panel-component/panel-button/index.d.ts +2 -0
- package/es/panel-component/panel-button/panel-button.d.ts +2 -0
- package/es/panel-component/panel-button/panel-button.mjs +12 -4
- package/es/panel-component/user-message/user-message.mjs +1 -0
- package/es/util/app-drawer/app-drawer-component.mjs +17 -18
- package/es/util/app-modal/app-modal-component.mjs +23 -17
- package/es/util/app-popover/app-popover-component.mjs +25 -2
- package/es/util/notification-util/notification-util.mjs +1 -0
- package/es/util/open-view-util/open-view-util.mjs +13 -3
- package/es/view-engine/edit-view.engine.d.ts +14 -0
- package/es/view-engine/edit-view.engine.mjs +90 -0
- package/es/view-engine/report-view.engine.d.ts +19 -0
- package/es/view-engine/report-view.engine.mjs +37 -10
- package/es/view-engine/tab-exp-view.engine.mjs +3 -3
- package/lib/common/grid-setting/grid-setting.cjs +23 -4
- package/lib/common/grid-setting/grid-setting.css +1 -1
- package/lib/control/calendar/calendar.cjs +1 -1
- package/lib/control/data-view/data-view.cjs +3 -2
- package/lib/control/drtab/drtab.css +1 -1
- package/lib/control/form/form-detail/form-mdctrl/form-mdctrl-md/form-mdctrl-md.css +1 -1
- package/lib/control/grid/grid/grid.cjs +1 -4
- package/lib/control/grid/grid/grid.css +1 -1
- package/lib/control/search-bar/filter-mode-select/filter-mode-select.cjs +3 -1
- package/lib/control/search-bar/filter-tree/filter-tree.cjs +13 -1
- package/lib/control/search-bar/search-bar.cjs +1 -1
- package/lib/control/search-bar/search-groups/search-groups.cjs +2 -2
- package/lib/control/tab-exp-panel/tab-exp-panel.cjs +31 -0
- package/lib/editor/date-range/ibiz-date-range-picker/ibiz-date-range-picker.css +1 -1
- package/lib/editor/html/wang-editor/wang-editor.cjs +2 -2
- package/lib/index.cjs +181 -183
- package/lib/panel-component/auth-userinfo/auth-userinfo.css +1 -1
- package/lib/panel-component/panel-app-login-view/panel-app-login-view.cjs +18 -1
- package/lib/panel-component/panel-app-login-view/panel-app-login-view.css +1 -1
- package/lib/panel-component/panel-button/panel-button.cjs +11 -3
- package/lib/panel-component/searchform-buttons/searchform-buttons.cjs +2 -2
- package/lib/panel-component/user-message/user-message.cjs +1 -0
- package/lib/util/app-drawer/app-drawer-component.cjs +16 -17
- package/lib/util/app-modal/app-modal-component.cjs +22 -16
- package/lib/util/app-popover/app-popover-component.cjs +24 -1
- package/lib/util/confirm-util/confirm-util.cjs +5 -5
- package/lib/util/loading-util/loading-util.cjs +2 -2
- package/lib/util/message-util/message-util.cjs +5 -5
- package/lib/util/modal-util/modal-util.cjs +6 -6
- package/lib/util/notice-util/notice-util.cjs +3 -3
- package/lib/util/notification-util/notification-util.cjs +3 -2
- package/lib/util/open-view-util/open-view-util.cjs +13 -3
- package/lib/view-engine/edit-view.engine.cjs +90 -0
- package/lib/view-engine/report-view.engine.cjs +36 -9
- package/lib/view-engine/tab-exp-view.engine.cjs +2 -2
- package/package.json +5 -5
- package/dist/index--KqYDzjn.js +0 -2
- package/es/devtool/devtool-action.css +0 -1
- package/es/devtool/devtool-action.d.ts +0 -26
- package/es/devtool/devtool-action.mjs +0 -219
- package/es/devtool/index.d.ts +0 -50
- package/es/devtool/index.mjs +0 -81
- package/es/devtool/interface/devtool-event.d.ts +0 -12
- package/es/devtool/interface/devtool-event.mjs +0 -1
- package/es/devtool/interface/devtool-view.d.ts +0 -15
- package/es/devtool/interface/devtool-view.mjs +0 -1
- package/es/node_modules/.pnpm/element-plus@2.4.2_vue@3.3.8/node_modules/element-plus/dist/locale/zh-cn.mjs +0 -131
- package/lib/devtool/devtool-action.cjs +0 -221
- package/lib/devtool/devtool-action.css +0 -1
- package/lib/devtool/index.cjs +0 -84
- package/lib/devtool/interface/devtool-event.cjs +0 -3
- package/lib/devtool/interface/devtool-view.cjs +0 -3
- package/lib/node_modules/.pnpm/element-plus@2.4.2_vue@3.3.8/node_modules/element-plus/dist/locale/zh-cn.cjs +0 -135
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.ibiz-devtool-action{position:absolute;right:0;bottom:0;z-index:9999;display:flex;height:100%;font-size:13px;color:#fff;background:rgba(96,98,102,.8);transition:all .5s}.ibiz-devtool-action-collapse{flex:0 0 auto;width:320px;padding:0 12px;margin-top:44px;margin-bottom:12px;overflow:auto;border-right:1px solid #999}.ibiz-devtool-action-collapse-item{display:flex;align-items:center;padding-bottom:4px}.ibiz-devtool-action-collapse-item__key{flex:0 0 auto;width:40%;overflow:hidden;text-align:right;text-overflow:ellipsis;white-space:nowrap;cursor:pointer}.ibiz-devtool-action-collapse-item__key:hover{color:#dbe6ff}.ibiz-devtool-action-collapse-item__value{flex:0 0 auto;width:60%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;cursor:pointer}.ibiz-devtool-action-collapse-item__value:hover{color:#dbe6ff}.ibiz-devtool-action-container{display:flex;flex:0 0 auto;flex-direction:column;width:400px;padding:12px}.ibiz-devtool-action-header{display:flex;flex:0 0 auto;align-items:center;justify-content:flex-end;height:20px;margin-bottom:12px}.ibiz-devtool-action-header ion-icon{margin-right:12px;font-size:20px;cursor:pointer}.ibiz-devtool-action-header ion-icon:last-child{margin-right:0}.ibiz-devtool-action-content{display:flex;flex:0 0 auto;flex-direction:column;height:calc(100% - 32px);overflow:auto}.ibiz-devtool-action-item{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.ibiz-devtool-action-item__text{display:flex;flex:1 1 0;justify-content:flex-start;height:auto;padding:4px 6px;margin-right:16px;overflow:hidden;line-height:normal;cursor:pointer}.ibiz-devtool-action-item__text>.el-tag__content{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ibiz-devtool-action-item__button{flex:0 0 auto;cursor:pointer}.ibiz-devtool-action-item__button:hover{color:#409eff}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { Ref } from 'vue';
|
|
2
|
-
import './devtool-action.scss';
|
|
3
|
-
import { DevtoolView } from './interface/devtool-view';
|
|
4
|
-
export declare const DevtoolAction: import("vue").DefineComponent<{}, {
|
|
5
|
-
ns: import("@ibiz-template/core").Namespace;
|
|
6
|
-
items: Ref<DevtoolView[]>;
|
|
7
|
-
activeItem: Ref<DevtoolView | null>;
|
|
8
|
-
height: Ref<string>;
|
|
9
|
-
isShow: Ref<boolean>;
|
|
10
|
-
activeCollapse: Ref<string[]>;
|
|
11
|
-
contextArray: import("vue").ComputedRef<{
|
|
12
|
-
key: string;
|
|
13
|
-
value: string;
|
|
14
|
-
}[]>;
|
|
15
|
-
paramsArray: import("vue").ComputedRef<{
|
|
16
|
-
key: string;
|
|
17
|
-
value: string;
|
|
18
|
-
}[]>;
|
|
19
|
-
onItemClick: (item: DevtoolView) => void;
|
|
20
|
-
copy: (value: string) => void;
|
|
21
|
-
minimize: () => void;
|
|
22
|
-
expand: () => void;
|
|
23
|
-
close: () => void;
|
|
24
|
-
onMouseEnter: (item: DevtoolView) => void;
|
|
25
|
-
onMouseLeave: (item: DevtoolView) => void;
|
|
26
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
|
|
@@ -1,219 +0,0 @@
|
|
|
1
|
-
import { isVNode, inject, ref, getCurrentInstance, computed, unref, onMounted, onUnmounted, resolveComponent, createVNode, createTextVNode, defineComponent } from 'vue';
|
|
2
|
-
import { useNamespace } from '@ibiz-template/vue3-util';
|
|
3
|
-
import './devtool-action.css';
|
|
4
|
-
import { useRouter } from 'vue-router';
|
|
5
|
-
|
|
6
|
-
"use strict";
|
|
7
|
-
function _isSlot(s) {
|
|
8
|
-
return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
|
|
9
|
-
}
|
|
10
|
-
const DevtoolAction = /* @__PURE__ */ defineComponent({
|
|
11
|
-
name: "IBizDevtoolAction",
|
|
12
|
-
setup() {
|
|
13
|
-
var _a;
|
|
14
|
-
const ns = useNamespace("devtool-action");
|
|
15
|
-
const evt = inject("devtool-evt");
|
|
16
|
-
const items = ref([]);
|
|
17
|
-
const activeItem = ref(null);
|
|
18
|
-
const isShow = ref(false);
|
|
19
|
-
const height = ref("");
|
|
20
|
-
const activeCollapse = ref(["context", "params"]);
|
|
21
|
-
const router = useRouter();
|
|
22
|
-
const instance = (_a = getCurrentInstance()) == null ? void 0 : _a.proxy;
|
|
23
|
-
router.afterEach(() => {
|
|
24
|
-
if (instance) {
|
|
25
|
-
activeItem.value = null;
|
|
26
|
-
instance.$forceUpdate();
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
const getObjEntriesArray = (obj) => {
|
|
30
|
-
if (!obj) {
|
|
31
|
-
return [];
|
|
32
|
-
}
|
|
33
|
-
return Object.entries(obj).map(([key, value]) => {
|
|
34
|
-
return {
|
|
35
|
-
key,
|
|
36
|
-
value: Object.prototype.toString.call(value) === "[object Object]" ? JSON.stringify(value) : "".concat(value)
|
|
37
|
-
};
|
|
38
|
-
});
|
|
39
|
-
};
|
|
40
|
-
const contextArray = computed(() => {
|
|
41
|
-
if (!activeItem.value) {
|
|
42
|
-
return [];
|
|
43
|
-
}
|
|
44
|
-
return getObjEntriesArray(activeItem.value.controller.context);
|
|
45
|
-
});
|
|
46
|
-
const paramsArray = computed(() => {
|
|
47
|
-
if (!activeItem.value) {
|
|
48
|
-
return [];
|
|
49
|
-
}
|
|
50
|
-
return getObjEntriesArray(activeItem.value.controller.params);
|
|
51
|
-
});
|
|
52
|
-
const onDataChange = (data) => {
|
|
53
|
-
items.value = [...data.values()];
|
|
54
|
-
};
|
|
55
|
-
const keydownHandle = (e) => {
|
|
56
|
-
if ((e.ctrlKey || e.metaKey) && e.code === "F12") {
|
|
57
|
-
isShow.value = !isShow.value;
|
|
58
|
-
}
|
|
59
|
-
};
|
|
60
|
-
const onItemClick = (item) => {
|
|
61
|
-
var _a2;
|
|
62
|
-
if (item.key === ((_a2 = activeItem.value) == null ? void 0 : _a2.key)) {
|
|
63
|
-
activeItem.value = null;
|
|
64
|
-
} else {
|
|
65
|
-
activeItem.value = item;
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
|
-
const copy = (value) => {
|
|
69
|
-
if (!value) {
|
|
70
|
-
return;
|
|
71
|
-
}
|
|
72
|
-
const result = ibiz.util.text.copy(value);
|
|
73
|
-
if (result) {
|
|
74
|
-
ibiz.message.success("\u62F7\u8D1D\u6210\u529F!");
|
|
75
|
-
} else {
|
|
76
|
-
ibiz.message.error("\u62F7\u8D1D\u5931\u8D25\uFF0C\u6D4F\u89C8\u5668copy\u64CD\u4F5C\u4E0D\u88AB\u652F\u6301\u6216\u672A\u88AB\u542F\u7528!");
|
|
77
|
-
}
|
|
78
|
-
};
|
|
79
|
-
const minimize = () => {
|
|
80
|
-
height.value = "44px";
|
|
81
|
-
};
|
|
82
|
-
const expand = () => {
|
|
83
|
-
height.value = "100%";
|
|
84
|
-
};
|
|
85
|
-
const close = () => {
|
|
86
|
-
isShow.value = false;
|
|
87
|
-
};
|
|
88
|
-
const onMouseEnter = (item) => {
|
|
89
|
-
const el = unref(item.dom);
|
|
90
|
-
if (el) {
|
|
91
|
-
el.style.outline = "3px solid #409EFF";
|
|
92
|
-
}
|
|
93
|
-
};
|
|
94
|
-
const onMouseLeave = (item) => {
|
|
95
|
-
const el = unref(item.dom);
|
|
96
|
-
if (el) {
|
|
97
|
-
el.style.outline = "";
|
|
98
|
-
}
|
|
99
|
-
};
|
|
100
|
-
onMounted(() => {
|
|
101
|
-
evt.on("change", onDataChange);
|
|
102
|
-
document.addEventListener("keydown", keydownHandle);
|
|
103
|
-
});
|
|
104
|
-
onUnmounted(() => {
|
|
105
|
-
evt.off("change", onDataChange);
|
|
106
|
-
document.removeEventListener("keydown", keydownHandle);
|
|
107
|
-
});
|
|
108
|
-
return {
|
|
109
|
-
ns,
|
|
110
|
-
items,
|
|
111
|
-
activeItem,
|
|
112
|
-
height,
|
|
113
|
-
isShow,
|
|
114
|
-
activeCollapse,
|
|
115
|
-
contextArray,
|
|
116
|
-
paramsArray,
|
|
117
|
-
onItemClick,
|
|
118
|
-
copy,
|
|
119
|
-
minimize,
|
|
120
|
-
expand,
|
|
121
|
-
close,
|
|
122
|
-
onMouseEnter,
|
|
123
|
-
onMouseLeave
|
|
124
|
-
};
|
|
125
|
-
},
|
|
126
|
-
render() {
|
|
127
|
-
let _slot, _slot2;
|
|
128
|
-
if (!this.isShow) {
|
|
129
|
-
return;
|
|
130
|
-
}
|
|
131
|
-
return createVNode("div", {
|
|
132
|
-
"class": this.ns.b(),
|
|
133
|
-
"style": {
|
|
134
|
-
height: this.height
|
|
135
|
-
}
|
|
136
|
-
}, [this.activeItem ? createVNode("div", {
|
|
137
|
-
"class": this.ns.b("collapse")
|
|
138
|
-
}, [createVNode(resolveComponent("el-collapse"), {
|
|
139
|
-
"modelValue": this.activeCollapse,
|
|
140
|
-
"onUpdate:modelValue": ($event) => this.activeCollapse = $event
|
|
141
|
-
}, {
|
|
142
|
-
default: () => [createVNode(resolveComponent("el-collapse-item"), {
|
|
143
|
-
"title": "\u5E94\u7528\u4E0A\u4E0B\u6587",
|
|
144
|
-
"name": "context"
|
|
145
|
-
}, _isSlot(_slot = this.contextArray.map((item) => createVNode("div", {
|
|
146
|
-
"class": this.ns.b("collapse-item")
|
|
147
|
-
}, [createVNode("div", {
|
|
148
|
-
"class": this.ns.be("collapse-item", "key"),
|
|
149
|
-
"title": item.key,
|
|
150
|
-
"onClick": () => this.copy(item.key)
|
|
151
|
-
}, [item.key]), createVNode("div", {
|
|
152
|
-
"class": this.ns.be("collapse-item", "value"),
|
|
153
|
-
"title": item.value,
|
|
154
|
-
"onClick": () => this.copy(item.value)
|
|
155
|
-
}, ["\uFF1A".concat(item.value)])]))) ? _slot : {
|
|
156
|
-
default: () => [_slot]
|
|
157
|
-
}), createVNode(resolveComponent("el-collapse-item"), {
|
|
158
|
-
"title": "\u89C6\u56FE\u53C2\u6570",
|
|
159
|
-
"name": "params"
|
|
160
|
-
}, _isSlot(_slot2 = this.paramsArray.map((item) => createVNode("div", {
|
|
161
|
-
"class": this.ns.b("collapse-item")
|
|
162
|
-
}, [createVNode("div", {
|
|
163
|
-
"class": this.ns.be("collapse-item", "key"),
|
|
164
|
-
"title": item.key,
|
|
165
|
-
"onClick": () => this.copy(item.key)
|
|
166
|
-
}, [item.key]), createVNode("div", {
|
|
167
|
-
"class": this.ns.be("collapse-item", "value"),
|
|
168
|
-
"title": item.value,
|
|
169
|
-
"onClick": () => this.copy(item.value)
|
|
170
|
-
}, ["\uFF1A".concat(item.value)])]))) ? _slot2 : {
|
|
171
|
-
default: () => [_slot2]
|
|
172
|
-
})]
|
|
173
|
-
})]) : null, createVNode("div", {
|
|
174
|
-
"class": this.ns.b("container")
|
|
175
|
-
}, [createVNode("div", {
|
|
176
|
-
"class": this.ns.b("header")
|
|
177
|
-
}, [createVNode("ion-icon", {
|
|
178
|
-
"name": "remove-outline",
|
|
179
|
-
"onClick": this.minimize
|
|
180
|
-
}, null), createVNode("ion-icon", {
|
|
181
|
-
"name": "expand-outline",
|
|
182
|
-
"onClick": this.expand
|
|
183
|
-
}, null), createVNode("ion-icon", {
|
|
184
|
-
"name": "close-outline",
|
|
185
|
-
"onClick": this.close
|
|
186
|
-
}, null)]), createVNode("div", {
|
|
187
|
-
"class": this.ns.b("content")
|
|
188
|
-
}, [this.items.map((item) => {
|
|
189
|
-
var _a;
|
|
190
|
-
if (!item.controller.isActive) {
|
|
191
|
-
return null;
|
|
192
|
-
}
|
|
193
|
-
const {
|
|
194
|
-
caption,
|
|
195
|
-
name
|
|
196
|
-
} = item.controller.model;
|
|
197
|
-
const text = "".concat(caption || "", "\uFF08").concat(name || "", "\uFF09");
|
|
198
|
-
const type = ((_a = this.activeItem) == null ? void 0 : _a.key) === item.key ? "success" : "";
|
|
199
|
-
return createVNode("div", {
|
|
200
|
-
"key": item.key,
|
|
201
|
-
"class": this.ns.b("item")
|
|
202
|
-
}, [createVNode(resolveComponent("el-tag"), {
|
|
203
|
-
"type": type,
|
|
204
|
-
"class": this.ns.be("item", "text"),
|
|
205
|
-
"title": text,
|
|
206
|
-
"onClick": () => this.onItemClick(item),
|
|
207
|
-
"onMouseenter": () => this.onMouseEnter(item),
|
|
208
|
-
"onMouseleave": () => this.onMouseLeave(item)
|
|
209
|
-
}, _isSlot(text) ? text : {
|
|
210
|
-
default: () => [text]
|
|
211
|
-
}), createVNode("div", {
|
|
212
|
-
"class": this.ns.be("item", "button"),
|
|
213
|
-
"onClick": () => this.copy(name)
|
|
214
|
-
}, [createTextVNode("\u62F7\u8D1D")])]);
|
|
215
|
-
})])])]);
|
|
216
|
-
}
|
|
217
|
-
});
|
|
218
|
-
|
|
219
|
-
export { DevtoolAction };
|
package/es/devtool/index.d.ts
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { Ref } from 'vue';
|
|
2
|
-
import { ViewController } from '@ibiz-template/runtime';
|
|
3
|
-
import { QXEvent } from 'qx-util';
|
|
4
|
-
import { Router } from 'vue-router';
|
|
5
|
-
import { DevtoolEvent } from './interface/devtool-event';
|
|
6
|
-
import { DevtoolView } from './interface/devtool-view';
|
|
7
|
-
export declare class Devtool {
|
|
8
|
-
/**
|
|
9
|
-
* 视图map
|
|
10
|
-
*
|
|
11
|
-
* @author zhanghengfeng
|
|
12
|
-
* @date 2023-08-28 18:08:16
|
|
13
|
-
*/
|
|
14
|
-
viewMap: Map<string, DevtoolView>;
|
|
15
|
-
/**
|
|
16
|
-
* 事件中心
|
|
17
|
-
*
|
|
18
|
-
* @author zhanghengfeng
|
|
19
|
-
* @date 2023-08-28 18:08:43
|
|
20
|
-
*/
|
|
21
|
-
evt: QXEvent<DevtoolEvent>;
|
|
22
|
-
/**
|
|
23
|
-
* 初始化devtool工具
|
|
24
|
-
*
|
|
25
|
-
* @author zhanghengfeng
|
|
26
|
-
* @date 2023-08-28 18:08:24
|
|
27
|
-
* @param {Router} router
|
|
28
|
-
*/
|
|
29
|
-
init(router: Router): void;
|
|
30
|
-
/**
|
|
31
|
-
* 注册视图
|
|
32
|
-
*
|
|
33
|
-
* @author zhanghengfeng
|
|
34
|
-
* @date 2023-08-28 18:08:25
|
|
35
|
-
* @param {string} key
|
|
36
|
-
* @param {ViewController} controller
|
|
37
|
-
* @param {(Ref<HTMLElement | null>)} dom
|
|
38
|
-
*/
|
|
39
|
-
registerView(key: string, controller: ViewController, dom: Ref<HTMLElement | null>): void;
|
|
40
|
-
/**
|
|
41
|
-
* 注销视图
|
|
42
|
-
*
|
|
43
|
-
* @author zhanghengfeng
|
|
44
|
-
* @date 2023-08-28 18:08:39
|
|
45
|
-
* @param {string} key
|
|
46
|
-
*/
|
|
47
|
-
unRegisterView(key: string): void;
|
|
48
|
-
}
|
|
49
|
-
declare const devtool: Devtool;
|
|
50
|
-
export { devtool };
|
package/es/devtool/index.mjs
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { createApp } from 'vue';
|
|
2
|
-
import { QXEvent } from 'qx-util';
|
|
3
|
-
import ElementPlus from 'element-plus';
|
|
4
|
-
import zhCn from '../node_modules/.pnpm/element-plus@2.4.2_vue@3.3.8/node_modules/element-plus/dist/locale/zh-cn.mjs';
|
|
5
|
-
import { DevtoolAction } from './devtool-action.mjs';
|
|
6
|
-
|
|
7
|
-
"use strict";
|
|
8
|
-
var __defProp = Object.defineProperty;
|
|
9
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
10
|
-
var __publicField = (obj, key, value) => {
|
|
11
|
-
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
12
|
-
return value;
|
|
13
|
-
};
|
|
14
|
-
class Devtool {
|
|
15
|
-
constructor() {
|
|
16
|
-
/**
|
|
17
|
-
* 视图map
|
|
18
|
-
*
|
|
19
|
-
* @author zhanghengfeng
|
|
20
|
-
* @date 2023-08-28 18:08:16
|
|
21
|
-
*/
|
|
22
|
-
__publicField(this, "viewMap", /* @__PURE__ */ new Map());
|
|
23
|
-
/**
|
|
24
|
-
* 事件中心
|
|
25
|
-
*
|
|
26
|
-
* @author zhanghengfeng
|
|
27
|
-
* @date 2023-08-28 18:08:43
|
|
28
|
-
*/
|
|
29
|
-
__publicField(this, "evt", new QXEvent());
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* 初始化devtool工具
|
|
33
|
-
*
|
|
34
|
-
* @author zhanghengfeng
|
|
35
|
-
* @date 2023-08-28 18:08:24
|
|
36
|
-
* @param {Router} router
|
|
37
|
-
*/
|
|
38
|
-
init(router) {
|
|
39
|
-
const devtool2 = document.createElement("div");
|
|
40
|
-
devtool2.classList.add("devtool");
|
|
41
|
-
document.body.append(devtool2);
|
|
42
|
-
const app = createApp(DevtoolAction);
|
|
43
|
-
app.use(router);
|
|
44
|
-
app.use(ElementPlus, {
|
|
45
|
-
locale: zhCn
|
|
46
|
-
});
|
|
47
|
-
app.provide("devtool-evt", this.evt);
|
|
48
|
-
app.mount(devtool2);
|
|
49
|
-
}
|
|
50
|
-
/**
|
|
51
|
-
* 注册视图
|
|
52
|
-
*
|
|
53
|
-
* @author zhanghengfeng
|
|
54
|
-
* @date 2023-08-28 18:08:25
|
|
55
|
-
* @param {string} key
|
|
56
|
-
* @param {ViewController} controller
|
|
57
|
-
* @param {(Ref<HTMLElement | null>)} dom
|
|
58
|
-
*/
|
|
59
|
-
registerView(key, controller, dom) {
|
|
60
|
-
this.viewMap.set(key, {
|
|
61
|
-
key,
|
|
62
|
-
controller,
|
|
63
|
-
dom
|
|
64
|
-
});
|
|
65
|
-
this.evt.emit("change", this.viewMap);
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* 注销视图
|
|
69
|
-
*
|
|
70
|
-
* @author zhanghengfeng
|
|
71
|
-
* @date 2023-08-28 18:08:39
|
|
72
|
-
* @param {string} key
|
|
73
|
-
*/
|
|
74
|
-
unRegisterView(key) {
|
|
75
|
-
this.viewMap.delete(key);
|
|
76
|
-
this.evt.emit("change", this.viewMap);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
const devtool = new Devtool();
|
|
80
|
-
|
|
81
|
-
export { Devtool, devtool };
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { DevtoolView } from './devtool-view';
|
|
2
|
-
/**
|
|
3
|
-
* devtool事件
|
|
4
|
-
*
|
|
5
|
-
* @author zhanghengfeng
|
|
6
|
-
* @date 2023-08-28 19:08:42
|
|
7
|
-
* @export
|
|
8
|
-
* @interface DevtoolEvent
|
|
9
|
-
*/
|
|
10
|
-
export interface DevtoolEvent {
|
|
11
|
-
change: (data: Map<string, DevtoolView>) => void;
|
|
12
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { ViewController } from '@ibiz-template/runtime';
|
|
2
|
-
import { Ref } from 'vue';
|
|
3
|
-
/**
|
|
4
|
-
* devtool视图
|
|
5
|
-
*
|
|
6
|
-
* @author zhanghengfeng
|
|
7
|
-
* @date 2023-08-28 19:08:07
|
|
8
|
-
* @export
|
|
9
|
-
* @interface DevtoolView
|
|
10
|
-
*/
|
|
11
|
-
export interface DevtoolView {
|
|
12
|
-
key: string;
|
|
13
|
-
controller: ViewController;
|
|
14
|
-
dom: Ref<HTMLElement | null>;
|
|
15
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
/*! Element Plus v2.4.2 */
|
|
2
|
-
|
|
3
|
-
var zhCn = {
|
|
4
|
-
name: "zh-cn",
|
|
5
|
-
el: {
|
|
6
|
-
colorpicker: {
|
|
7
|
-
confirm: "\u786E\u5B9A",
|
|
8
|
-
clear: "\u6E05\u7A7A"
|
|
9
|
-
},
|
|
10
|
-
datepicker: {
|
|
11
|
-
now: "\u6B64\u523B",
|
|
12
|
-
today: "\u4ECA\u5929",
|
|
13
|
-
cancel: "\u53D6\u6D88",
|
|
14
|
-
clear: "\u6E05\u7A7A",
|
|
15
|
-
confirm: "\u786E\u5B9A",
|
|
16
|
-
selectDate: "\u9009\u62E9\u65E5\u671F",
|
|
17
|
-
selectTime: "\u9009\u62E9\u65F6\u95F4",
|
|
18
|
-
startDate: "\u5F00\u59CB\u65E5\u671F",
|
|
19
|
-
startTime: "\u5F00\u59CB\u65F6\u95F4",
|
|
20
|
-
endDate: "\u7ED3\u675F\u65E5\u671F",
|
|
21
|
-
endTime: "\u7ED3\u675F\u65F6\u95F4",
|
|
22
|
-
prevYear: "\u524D\u4E00\u5E74",
|
|
23
|
-
nextYear: "\u540E\u4E00\u5E74",
|
|
24
|
-
prevMonth: "\u4E0A\u4E2A\u6708",
|
|
25
|
-
nextMonth: "\u4E0B\u4E2A\u6708",
|
|
26
|
-
year: "\u5E74",
|
|
27
|
-
month1: "1 \u6708",
|
|
28
|
-
month2: "2 \u6708",
|
|
29
|
-
month3: "3 \u6708",
|
|
30
|
-
month4: "4 \u6708",
|
|
31
|
-
month5: "5 \u6708",
|
|
32
|
-
month6: "6 \u6708",
|
|
33
|
-
month7: "7 \u6708",
|
|
34
|
-
month8: "8 \u6708",
|
|
35
|
-
month9: "9 \u6708",
|
|
36
|
-
month10: "10 \u6708",
|
|
37
|
-
month11: "11 \u6708",
|
|
38
|
-
month12: "12 \u6708",
|
|
39
|
-
weeks: {
|
|
40
|
-
sun: "\u65E5",
|
|
41
|
-
mon: "\u4E00",
|
|
42
|
-
tue: "\u4E8C",
|
|
43
|
-
wed: "\u4E09",
|
|
44
|
-
thu: "\u56DB",
|
|
45
|
-
fri: "\u4E94",
|
|
46
|
-
sat: "\u516D"
|
|
47
|
-
},
|
|
48
|
-
months: {
|
|
49
|
-
jan: "\u4E00\u6708",
|
|
50
|
-
feb: "\u4E8C\u6708",
|
|
51
|
-
mar: "\u4E09\u6708",
|
|
52
|
-
apr: "\u56DB\u6708",
|
|
53
|
-
may: "\u4E94\u6708",
|
|
54
|
-
jun: "\u516D\u6708",
|
|
55
|
-
jul: "\u4E03\u6708",
|
|
56
|
-
aug: "\u516B\u6708",
|
|
57
|
-
sep: "\u4E5D\u6708",
|
|
58
|
-
oct: "\u5341\u6708",
|
|
59
|
-
nov: "\u5341\u4E00\u6708",
|
|
60
|
-
dec: "\u5341\u4E8C\u6708"
|
|
61
|
-
}
|
|
62
|
-
},
|
|
63
|
-
select: {
|
|
64
|
-
loading: "\u52A0\u8F7D\u4E2D",
|
|
65
|
-
noMatch: "\u65E0\u5339\u914D\u6570\u636E",
|
|
66
|
-
noData: "\u65E0\u6570\u636E",
|
|
67
|
-
placeholder: "\u8BF7\u9009\u62E9"
|
|
68
|
-
},
|
|
69
|
-
cascader: {
|
|
70
|
-
noMatch: "\u65E0\u5339\u914D\u6570\u636E",
|
|
71
|
-
loading: "\u52A0\u8F7D\u4E2D",
|
|
72
|
-
placeholder: "\u8BF7\u9009\u62E9",
|
|
73
|
-
noData: "\u6682\u65E0\u6570\u636E"
|
|
74
|
-
},
|
|
75
|
-
pagination: {
|
|
76
|
-
goto: "\u524D\u5F80",
|
|
77
|
-
pagesize: "\u6761/\u9875",
|
|
78
|
-
total: "\u5171 {total} \u6761",
|
|
79
|
-
pageClassifier: "\u9875",
|
|
80
|
-
page: "\u9875",
|
|
81
|
-
prev: "\u4E0A\u4E00\u9875",
|
|
82
|
-
next: "\u4E0B\u4E00\u9875",
|
|
83
|
-
currentPage: "\u7B2C {pager} \u9875",
|
|
84
|
-
prevPages: "\u5411\u524D {pager} \u9875",
|
|
85
|
-
nextPages: "\u5411\u540E {pager} \u9875",
|
|
86
|
-
deprecationWarning: "\u4F60\u4F7F\u7528\u4E86\u4E00\u4E9B\u5DF2\u88AB\u5E9F\u5F03\u7684\u7528\u6CD5\uFF0C\u8BF7\u53C2\u8003 el-pagination \u7684\u5B98\u65B9\u6587\u6863"
|
|
87
|
-
},
|
|
88
|
-
messagebox: {
|
|
89
|
-
title: "\u63D0\u793A",
|
|
90
|
-
confirm: "\u786E\u5B9A",
|
|
91
|
-
cancel: "\u53D6\u6D88",
|
|
92
|
-
error: "\u8F93\u5165\u7684\u6570\u636E\u4E0D\u5408\u6CD5!"
|
|
93
|
-
},
|
|
94
|
-
upload: {
|
|
95
|
-
deleteTip: "\u6309 delete \u952E\u53EF\u5220\u9664",
|
|
96
|
-
delete: "\u5220\u9664",
|
|
97
|
-
preview: "\u67E5\u770B\u56FE\u7247",
|
|
98
|
-
continue: "\u7EE7\u7EED\u4E0A\u4F20"
|
|
99
|
-
},
|
|
100
|
-
table: {
|
|
101
|
-
emptyText: "\u6682\u65E0\u6570\u636E",
|
|
102
|
-
confirmFilter: "\u7B5B\u9009",
|
|
103
|
-
resetFilter: "\u91CD\u7F6E",
|
|
104
|
-
clearFilter: "\u5168\u90E8",
|
|
105
|
-
sumText: "\u5408\u8BA1"
|
|
106
|
-
},
|
|
107
|
-
tree: {
|
|
108
|
-
emptyText: "\u6682\u65E0\u6570\u636E"
|
|
109
|
-
},
|
|
110
|
-
transfer: {
|
|
111
|
-
noMatch: "\u65E0\u5339\u914D\u6570\u636E",
|
|
112
|
-
noData: "\u65E0\u6570\u636E",
|
|
113
|
-
titles: ["\u5217\u8868 1", "\u5217\u8868 2"],
|
|
114
|
-
filterPlaceholder: "\u8BF7\u8F93\u5165\u641C\u7D22\u5185\u5BB9",
|
|
115
|
-
noCheckedFormat: "\u5171 {total} \u9879",
|
|
116
|
-
hasCheckedFormat: "\u5DF2\u9009 {checked}/{total} \u9879"
|
|
117
|
-
},
|
|
118
|
-
image: {
|
|
119
|
-
error: "\u52A0\u8F7D\u5931\u8D25"
|
|
120
|
-
},
|
|
121
|
-
pageHeader: {
|
|
122
|
-
title: "\u8FD4\u56DE"
|
|
123
|
-
},
|
|
124
|
-
popconfirm: {
|
|
125
|
-
confirmButtonText: "\u786E\u5B9A",
|
|
126
|
-
cancelButtonText: "\u53D6\u6D88"
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
};
|
|
130
|
-
|
|
131
|
-
export { zhCn as default };
|