hy-dispatch-ui-v3 0.2.43 → 0.2.45
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/tailwind.css +2 -2
- package/es/components/hyDialog/dialog.vue.mjs +8 -6
- package/es/components/hyInput/index.mjs +3 -1
- package/es/components/hyInput/inputSearch.vue.mjs +122 -0
- package/es/components/hyInput/style/inputSearch.scss +39 -0
- package/es/components/hySearch/js/useAppSearch.mjs +5 -6
- package/es/components/hyTable/js/search.mjs +8 -2
- package/es/components/hyTable/js/useAppTable.mjs +2 -2
- package/es/components/hyTable/table.vue.mjs +13 -42
- package/es/components/hyTableActionButton/tableActionButton.vue.mjs +3 -1
- package/es/components/hyTableForm/tableForm.vue.mjs +3 -0
- package/es/components/index.mjs +1 -1
- package/es/index.mjs +1 -1
- package/es/version.mjs +1 -1
- package/lib/components/hyDialog/dialog.vue.js +8 -6
- package/lib/components/hyInput/index.js +3 -0
- package/lib/components/hyInput/inputSearch.vue.js +126 -0
- package/lib/components/hyInput/style/inputSearch.scss +39 -0
- package/lib/components/hySearch/js/useAppSearch.js +5 -6
- package/lib/components/hyTable/js/search.js +8 -2
- package/lib/components/hyTable/js/useAppTable.js +2 -2
- package/lib/components/hyTable/table.vue.js +36 -65
- package/lib/components/hyTableActionButton/tableActionButton.vue.js +3 -1
- package/lib/components/hyTableForm/tableForm.vue.js +3 -0
- package/lib/components/index.js +1 -0
- package/lib/index.js +1 -0
- package/lib/version.js +1 -1
- package/package.json +1 -1
package/dist/tailwind.css
CHANGED
|
@@ -19,9 +19,10 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
19
19
|
default: "default"
|
|
20
20
|
// default-默认类型 right-右侧弹窗
|
|
21
21
|
},
|
|
22
|
-
|
|
22
|
+
// body-Content-Class
|
|
23
|
+
bodyContentClass: {
|
|
23
24
|
type: String,
|
|
24
|
-
default: "
|
|
25
|
+
default: ""
|
|
25
26
|
},
|
|
26
27
|
top: String,
|
|
27
28
|
// 是否可缩小化
|
|
@@ -77,6 +78,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
77
78
|
const dialogTypeRight = computed(() => {
|
|
78
79
|
return props.dialogType === "right";
|
|
79
80
|
});
|
|
81
|
+
const bodyContentClass = computed(() => {
|
|
82
|
+
return `${props.bodyContentClass || null} ${dialogTypeRight.value ? "flex-grow h-0" : ""}`;
|
|
83
|
+
});
|
|
80
84
|
const ifDraggable = computed(() => {
|
|
81
85
|
if (props.ifShrink) {
|
|
82
86
|
return true;
|
|
@@ -197,7 +201,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
197
201
|
"onUpdate:modelValue": ($event) => visible.value = $event,
|
|
198
202
|
width: props.width,
|
|
199
203
|
top: dialogTypeRight.value ? "16px" : props.top || null,
|
|
200
|
-
class: dialogTypeRight.value ? "h-[
|
|
204
|
+
class: dialogTypeRight.value ? "h-[96vh] flex flex-col !my-4 !mr-4 !ml-auto" : null,
|
|
201
205
|
"body-class": dialogTypeRight.value ? "flex-grow h-0" : null
|
|
202
206
|
}, _ctx.$attrs), {
|
|
203
207
|
header: withCtx(() => [
|
|
@@ -241,9 +245,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
241
245
|
createElementVNode(
|
|
242
246
|
"div",
|
|
243
247
|
{
|
|
244
|
-
class: normalizeClass([
|
|
245
|
-
"flex-grow h-0": dialogTypeRight.value
|
|
246
|
-
}, "scroll-body overflow-auto px-6 py-4"])
|
|
248
|
+
class: normalizeClass([bodyContentClass.value, "scroll-body overflow-auto px-6 py-4"])
|
|
247
249
|
},
|
|
248
250
|
[
|
|
249
251
|
renderSlot(_ctx.$slots, "default")
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import _sfc_main from './input.vue.mjs';
|
|
2
|
+
import _sfc_main$1 from './inputSearch.vue.mjs';
|
|
2
3
|
import { withInstall } from '../../utils/handler.mjs';
|
|
3
4
|
|
|
4
5
|
const HyInput = withInstall(_sfc_main);
|
|
6
|
+
const HyInputSearch = withInstall(_sfc_main$1);
|
|
5
7
|
const ElInput = withInstall(_sfc_main, "ElInput");
|
|
6
8
|
|
|
7
|
-
export { ElInput, HyInput, HyInput as default };
|
|
9
|
+
export { ElInput, HyInput, HyInputSearch, HyInput as default };
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { useModel, useTemplateRef, ref, computed, openBlock, createElementBlock, normalizeClass, renderSlot, createVNode, mergeProps, withKeys, createSlots, renderList, withCtx, normalizeProps, guardReactiveProps, createElementVNode, unref, mergeModels, defineComponent } from 'vue';
|
|
2
|
+
import { ElIcon } from 'element-plus';
|
|
3
|
+
import { Search } from '@element-plus/icons-vue';
|
|
4
|
+
import _sfc_main$1 from './input.vue.mjs';
|
|
5
|
+
|
|
6
|
+
import "./style/inputSearch.scss";
|
|
7
|
+
|
|
8
|
+
const __default__ = defineComponent({
|
|
9
|
+
name: "HyInputSearch"
|
|
10
|
+
});
|
|
11
|
+
const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
12
|
+
props: /* @__PURE__ */ mergeModels({}, {
|
|
13
|
+
"modelValue": {
|
|
14
|
+
type: [String, Number],
|
|
15
|
+
default: ""
|
|
16
|
+
},
|
|
17
|
+
"modelModifiers": {}
|
|
18
|
+
}),
|
|
19
|
+
emits: /* @__PURE__ */ mergeModels(["search"], ["update:modelValue"]),
|
|
20
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
21
|
+
const emits = __emit;
|
|
22
|
+
const modelValue = useModel(__props, "modelValue");
|
|
23
|
+
const inputRef = useTemplateRef("inputRef");
|
|
24
|
+
const isSearchFocus = ref(false);
|
|
25
|
+
function onSearchInputHandler() {
|
|
26
|
+
isSearchFocus.value = true;
|
|
27
|
+
}
|
|
28
|
+
function onSearchBlurHandler() {
|
|
29
|
+
isSearchFocus.value = false;
|
|
30
|
+
}
|
|
31
|
+
function onSearchQueryHandler() {
|
|
32
|
+
emits("search", modelValue.value);
|
|
33
|
+
}
|
|
34
|
+
__expose({
|
|
35
|
+
blur() {
|
|
36
|
+
inputRef.value.blur();
|
|
37
|
+
},
|
|
38
|
+
clear() {
|
|
39
|
+
inputRef.value.clear();
|
|
40
|
+
},
|
|
41
|
+
focus() {
|
|
42
|
+
inputRef.value.focus();
|
|
43
|
+
},
|
|
44
|
+
input: computed(() => {
|
|
45
|
+
return inputRef.value.input;
|
|
46
|
+
}),
|
|
47
|
+
ref: computed(() => {
|
|
48
|
+
return inputRef.value.ref;
|
|
49
|
+
}),
|
|
50
|
+
resizeTextarea() {
|
|
51
|
+
inputRef.value.resizeTextarea();
|
|
52
|
+
},
|
|
53
|
+
select() {
|
|
54
|
+
inputRef.value.select();
|
|
55
|
+
},
|
|
56
|
+
textarea: computed(() => {
|
|
57
|
+
return inputRef.value.textarea;
|
|
58
|
+
}),
|
|
59
|
+
textareaStyle: computed(() => {
|
|
60
|
+
return inputRef.value.textareaStyle;
|
|
61
|
+
}),
|
|
62
|
+
isComposing: computed(() => {
|
|
63
|
+
return inputRef.value.isComposing;
|
|
64
|
+
}),
|
|
65
|
+
passwordVisible: computed(() => {
|
|
66
|
+
return inputRef.value.passwordVisible;
|
|
67
|
+
})
|
|
68
|
+
});
|
|
69
|
+
return (_ctx, _cache) => {
|
|
70
|
+
return openBlock(), createElementBlock(
|
|
71
|
+
"div",
|
|
72
|
+
{
|
|
73
|
+
class: normalizeClass(["hy-input-search", { focus: isSearchFocus.value }])
|
|
74
|
+
},
|
|
75
|
+
[
|
|
76
|
+
renderSlot(_ctx.$slots, "before"),
|
|
77
|
+
createVNode(_sfc_main$1, mergeProps({
|
|
78
|
+
ref_key: "inputRef",
|
|
79
|
+
ref: inputRef,
|
|
80
|
+
modelValue: modelValue.value,
|
|
81
|
+
"onUpdate:modelValue": ($event) => modelValue.value = $event,
|
|
82
|
+
clearable: "",
|
|
83
|
+
class: "hy-input-search-item"
|
|
84
|
+
}, _ctx.$attrs, {
|
|
85
|
+
onFocus: onSearchInputHandler,
|
|
86
|
+
onBlur: onSearchBlurHandler,
|
|
87
|
+
onClear: onSearchQueryHandler,
|
|
88
|
+
onKeydown: withKeys(onSearchQueryHandler, ["enter"])
|
|
89
|
+
}), createSlots({
|
|
90
|
+
_: 2
|
|
91
|
+
/* DYNAMIC */
|
|
92
|
+
}, [
|
|
93
|
+
renderList(_ctx.$slots, (_, slotName) => {
|
|
94
|
+
return {
|
|
95
|
+
name: slotName,
|
|
96
|
+
fn: withCtx((scope) => [
|
|
97
|
+
renderSlot(_ctx.$slots, slotName, normalizeProps(guardReactiveProps(scope)))
|
|
98
|
+
])
|
|
99
|
+
};
|
|
100
|
+
})
|
|
101
|
+
]), 1040, ["modelValue", "onUpdate:modelValue"]),
|
|
102
|
+
createElementVNode("div", {
|
|
103
|
+
class: "w-[32px] h-[32px] flex-shrink-0 flex items-center justify-center bg-background-3 rounded-[2px] cursor-pointer",
|
|
104
|
+
onClick: onSearchQueryHandler
|
|
105
|
+
}, [
|
|
106
|
+
createVNode(unref(ElIcon), { size: "18" }, {
|
|
107
|
+
default: withCtx(() => [
|
|
108
|
+
createVNode(unref(Search))
|
|
109
|
+
]),
|
|
110
|
+
_: 1
|
|
111
|
+
/* STABLE */
|
|
112
|
+
})
|
|
113
|
+
])
|
|
114
|
+
],
|
|
115
|
+
2
|
|
116
|
+
/* CLASS */
|
|
117
|
+
);
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
|
|
122
|
+
export { _sfc_main as default };
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
.hy-input-search {
|
|
2
|
+
width: 100%;
|
|
3
|
+
min-width: 160px;
|
|
4
|
+
display: flex;
|
|
5
|
+
align-items: center;
|
|
6
|
+
gap: 4px;
|
|
7
|
+
border: 1px solid rgba(var(--hy-border));
|
|
8
|
+
border-radius: 4px;
|
|
9
|
+
box-sizing: border-box;
|
|
10
|
+
padding: 2px 4px;
|
|
11
|
+
overflow: hidden;
|
|
12
|
+
background: rgba(var(--hy-background-2));
|
|
13
|
+
&:hover,
|
|
14
|
+
&.focus {
|
|
15
|
+
border: 1px solid rgba(var(--hy-theme));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.hy-input-search-item {
|
|
19
|
+
width: 0;
|
|
20
|
+
flex: 1;
|
|
21
|
+
& > .hy-el-input__wrapper {
|
|
22
|
+
padding-left: 8px;
|
|
23
|
+
padding-right: 4px;
|
|
24
|
+
}
|
|
25
|
+
.hy-el-input__inner::placeholder {
|
|
26
|
+
font-size: 12px;
|
|
27
|
+
}
|
|
28
|
+
.hy-el-input__wrapper {
|
|
29
|
+
box-shadow: none;
|
|
30
|
+
}
|
|
31
|
+
.hy-el-input-group__append {
|
|
32
|
+
color: rgb(var(--hy-main));
|
|
33
|
+
background-color: rgba(var(--hy-background-2));
|
|
34
|
+
box-shadow: none;
|
|
35
|
+
padding: 4px;
|
|
36
|
+
min-height: 100%;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
@@ -33,9 +33,8 @@ const genPlaceholderHandler = (config) => {
|
|
|
33
33
|
return { placeholder, startPlaceholder, endPlaceholder };
|
|
34
34
|
};
|
|
35
35
|
const genColumnWidth = (config) => {
|
|
36
|
-
let { width, type, attrs } = config || {};
|
|
37
|
-
|
|
38
|
-
if (!width) {
|
|
36
|
+
let { width, inputWidth, type, attrs } = config || {};
|
|
37
|
+
if (!width && !inputWidth) {
|
|
39
38
|
if (type === "date-picker") {
|
|
40
39
|
switch (attrs?.type) {
|
|
41
40
|
case "datetimerange":
|
|
@@ -154,10 +153,10 @@ const useAppSearch = (config = [], model) => {
|
|
|
154
153
|
const target = appSearchItemHandler(item);
|
|
155
154
|
columns.push(target);
|
|
156
155
|
}
|
|
157
|
-
const
|
|
156
|
+
const filterModel = resetAppSearchValue(columns, model);
|
|
158
157
|
return {
|
|
159
|
-
|
|
160
|
-
|
|
158
|
+
filterModel: toRef(filterModel),
|
|
159
|
+
filterColumns: toRef(columns)
|
|
161
160
|
};
|
|
162
161
|
};
|
|
163
162
|
|
|
@@ -60,9 +60,14 @@ function useAppTableSearch(hy) {
|
|
|
60
60
|
emits("reqSuccess", tableDataSource.value);
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
async function
|
|
63
|
+
async function resetFields() {
|
|
64
64
|
await nextTick();
|
|
65
|
-
appSearchRef.value
|
|
65
|
+
if (appSearchRef.value) {
|
|
66
|
+
appSearchRef.value.resetFields();
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
async function resetFn() {
|
|
70
|
+
await resetFields();
|
|
66
71
|
props.filterModel.query = null;
|
|
67
72
|
getData(1);
|
|
68
73
|
}
|
|
@@ -104,6 +109,7 @@ function useAppTableSearch(hy) {
|
|
|
104
109
|
showFilter,
|
|
105
110
|
getData,
|
|
106
111
|
setData,
|
|
112
|
+
resetFields,
|
|
107
113
|
resetFn,
|
|
108
114
|
switchShowFilter,
|
|
109
115
|
getTotalElements,
|
|
@@ -142,8 +142,8 @@ const useAppTable = (config = {}) => {
|
|
|
142
142
|
});
|
|
143
143
|
return {
|
|
144
144
|
tableColumns: toRef(tableColumns),
|
|
145
|
-
filterModel: appSearchForm.
|
|
146
|
-
filterColumns: appSearchForm.
|
|
145
|
+
filterModel: appSearchForm.filterModel,
|
|
146
|
+
filterColumns: appSearchForm.filterColumns
|
|
147
147
|
};
|
|
148
148
|
};
|
|
149
149
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent, useTemplateRef, openBlock, createElementBlock, createCommentVNode, createElementVNode, createBlock, unref, createVNode, withCtx, toDisplayString,
|
|
2
|
-
import { ElIcon,
|
|
3
|
-
import { Filter,
|
|
1
|
+
import { defineComponent, useTemplateRef, openBlock, createElementBlock, createCommentVNode, createElementVNode, createBlock, unref, createVNode, withCtx, toDisplayString, renderSlot, normalizeClass, createSlots, renderList, normalizeProps, guardReactiveProps, mergeProps, Fragment, withModifiers } from 'vue';
|
|
2
|
+
import { ElIcon, ElTable, ElTableColumn, ElDropdown, ElDropdownMenu, ElDropdownItem, ElAutoResizer, ElPagination } from 'element-plus';
|
|
3
|
+
import { Filter, MoreFilled } from '@element-plus/icons-vue';
|
|
4
4
|
import { operatorFilterHandler, operatorClickHandler, operatorDisabledHandler, operatorDisableTextdHandler, renderContentHandler, renderHeaderHandler, useAppTableWrapper } from './js/index.mjs';
|
|
5
5
|
import { useAppTableSearch } from './js/search.mjs';
|
|
6
6
|
import _sfc_main$2 from './cpns/headerItem.vue.mjs';
|
|
@@ -9,6 +9,7 @@ import _sfc_main$3 from './cpns/virtualTable.vue.mjs';
|
|
|
9
9
|
import { useLocale } from '../../hooks/useLocale.mjs';
|
|
10
10
|
import { useMixins } from '../../hooks/useMixins.mjs';
|
|
11
11
|
import { HyTooltip } from '../hyTooltip/index.mjs';
|
|
12
|
+
import { HyInputSearch } from '../hyInput/index.mjs';
|
|
12
13
|
import { HyButton } from '../hyButton/index.mjs';
|
|
13
14
|
import { HyIcon } from '../hyIcon/index.mjs';
|
|
14
15
|
import { HySearch } from '../hySearch/index.mjs';
|
|
@@ -231,6 +232,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
231
232
|
showFilter,
|
|
232
233
|
getData,
|
|
233
234
|
setData,
|
|
235
|
+
resetFields,
|
|
234
236
|
resetFn,
|
|
235
237
|
switchShowFilter,
|
|
236
238
|
getTotalElements,
|
|
@@ -256,6 +258,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
256
258
|
__expose({
|
|
257
259
|
getData,
|
|
258
260
|
setData,
|
|
261
|
+
resetFields,
|
|
259
262
|
resetFn,
|
|
260
263
|
getSelectedList,
|
|
261
264
|
getTotalElements,
|
|
@@ -278,7 +281,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
278
281
|
key: 0,
|
|
279
282
|
class: "min-h-[36px] flex flex-row-reverse items-center justify-between gap-3 mb-4"
|
|
280
283
|
}, [
|
|
281
|
-
createElementVNode("div", { class: "flex gap-3 whitespace-nowrap" }, [
|
|
284
|
+
createElementVNode("div", { class: "flex items-center gap-3 whitespace-nowrap" }, [
|
|
282
285
|
__props.showEditable ? (openBlock(), createBlock(_sfc_main$1, {
|
|
283
286
|
key: 0,
|
|
284
287
|
columns: unref(tableColumns),
|
|
@@ -318,44 +321,12 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
318
321
|
}, null, 8, ["innerHTML"])
|
|
319
322
|
]),
|
|
320
323
|
default: withCtx(() => [
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
createVNode(unref(ElInput), {
|
|
328
|
-
modelValue: __props.filterModel.query,
|
|
329
|
-
"onUpdate:modelValue": ($event) => __props.filterModel.query = $event,
|
|
330
|
-
class: "hy-table-search",
|
|
331
|
-
placeholder: unref(t)("table.searchFor", [__props.controllerText || ""]),
|
|
332
|
-
clearable: "",
|
|
333
|
-
onFocus: unref(onSearchInputHandler),
|
|
334
|
-
onBlur: unref(onSearchBlurHandler),
|
|
335
|
-
onClear: unref(onSearchQueryHandler),
|
|
336
|
-
onKeydown: withKeys(unref(onSearchQueryHandler), ["enter"])
|
|
337
|
-
}, {
|
|
338
|
-
append: withCtx(() => [
|
|
339
|
-
createElementVNode("div", {
|
|
340
|
-
class: "w-[32px] h-full flex items-center justify-center bg-background-3 rounded-[2px] cursor-pointer",
|
|
341
|
-
onClick: unref(onSearchQueryHandler)
|
|
342
|
-
}, [
|
|
343
|
-
createVNode(unref(ElIcon), { size: "18" }, {
|
|
344
|
-
default: withCtx(() => [
|
|
345
|
-
createVNode(unref(Search))
|
|
346
|
-
]),
|
|
347
|
-
_: 1
|
|
348
|
-
/* STABLE */
|
|
349
|
-
})
|
|
350
|
-
], 8, ["onClick"])
|
|
351
|
-
]),
|
|
352
|
-
_: 1
|
|
353
|
-
/* STABLE */
|
|
354
|
-
}, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "onFocus", "onBlur", "onClear", "onKeydown"])
|
|
355
|
-
],
|
|
356
|
-
2
|
|
357
|
-
/* CLASS */
|
|
358
|
-
)
|
|
324
|
+
createVNode(unref(HyInputSearch), {
|
|
325
|
+
modelValue: __props.filterModel.query,
|
|
326
|
+
"onUpdate:modelValue": ($event) => __props.filterModel.query = $event,
|
|
327
|
+
placeholder: unref(t)("table.searchFor", [__props.controllerText || ""]),
|
|
328
|
+
onSearch: unref(onSearchQueryHandler)
|
|
329
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "onSearch"])
|
|
359
330
|
]),
|
|
360
331
|
_: 1
|
|
361
332
|
/* STABLE */
|
|
@@ -75,7 +75,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
75
75
|
return props.label;
|
|
76
76
|
});
|
|
77
77
|
function buttonChange(item) {
|
|
78
|
-
|
|
78
|
+
if (item) {
|
|
79
|
+
emits("change", item.value);
|
|
80
|
+
}
|
|
79
81
|
}
|
|
80
82
|
function getDataList(dataList2 = []) {
|
|
81
83
|
const arr = [];
|
|
@@ -224,6 +224,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
224
224
|
});
|
|
225
225
|
initValidateHandler(dataSource.value);
|
|
226
226
|
setData(dataSource.value);
|
|
227
|
+
emits("validate", {
|
|
228
|
+
...statistics.value
|
|
229
|
+
});
|
|
227
230
|
},
|
|
228
231
|
deleteData(data) {
|
|
229
232
|
if (!isArray(data)) {
|
package/es/components/index.mjs
CHANGED
|
@@ -18,7 +18,7 @@ export { HyMenu } from './hyMenu/index.mjs';
|
|
|
18
18
|
export { HyTree } from './hyTree/index.mjs';
|
|
19
19
|
export { HyVideoPlayer } from './hyVideoPlayer/index.mjs';
|
|
20
20
|
export { HyAudioPlayer } from './hyAudioPlayer/index.mjs';
|
|
21
|
-
export { ElInput, HyInput } from './hyInput/index.mjs';
|
|
21
|
+
export { ElInput, HyInput, HyInputSearch } from './hyInput/index.mjs';
|
|
22
22
|
export { ElTimePicker, HyTimePicker } from './hyTimePicker/index.mjs';
|
|
23
23
|
export { HyBatchTableForm, HyTableForm } from './hyTableForm/index.mjs';
|
|
24
24
|
export { HyTableActionButton } from './hyTableActionButton/index.mjs';
|
package/es/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import installer from './make-installer.mjs';
|
|
2
2
|
export { ElDatePicker, HyDatePicker } from './components/hyDatePicker/index.mjs';
|
|
3
|
-
export { ElInput, HyInput } from './components/hyInput/index.mjs';
|
|
3
|
+
export { ElInput, HyInput, HyInputSearch } from './components/hyInput/index.mjs';
|
|
4
4
|
export { ElTimePicker, HyTimePicker } from './components/hyTimePicker/index.mjs';
|
|
5
5
|
export { ElTooltip, HyTooltip } from './components/hyTooltip/index.mjs';
|
|
6
6
|
export { HyAudioPlayer } from './components/hyAudioPlayer/index.mjs';
|
package/es/version.mjs
CHANGED
|
@@ -23,9 +23,10 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
23
23
|
default: "default"
|
|
24
24
|
// default-默认类型 right-右侧弹窗
|
|
25
25
|
},
|
|
26
|
-
|
|
26
|
+
// body-Content-Class
|
|
27
|
+
bodyContentClass: {
|
|
27
28
|
type: String,
|
|
28
|
-
default: "
|
|
29
|
+
default: ""
|
|
29
30
|
},
|
|
30
31
|
top: String,
|
|
31
32
|
// 是否可缩小化
|
|
@@ -81,6 +82,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
81
82
|
const dialogTypeRight = vue.computed(() => {
|
|
82
83
|
return props.dialogType === "right";
|
|
83
84
|
});
|
|
85
|
+
const bodyContentClass = vue.computed(() => {
|
|
86
|
+
return `${props.bodyContentClass || null} ${dialogTypeRight.value ? "flex-grow h-0" : ""}`;
|
|
87
|
+
});
|
|
84
88
|
const ifDraggable = vue.computed(() => {
|
|
85
89
|
if (props.ifShrink) {
|
|
86
90
|
return true;
|
|
@@ -201,7 +205,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
201
205
|
"onUpdate:modelValue": ($event) => visible.value = $event,
|
|
202
206
|
width: props.width,
|
|
203
207
|
top: dialogTypeRight.value ? "16px" : props.top || null,
|
|
204
|
-
class: dialogTypeRight.value ? "h-[
|
|
208
|
+
class: dialogTypeRight.value ? "h-[96vh] flex flex-col !my-4 !mr-4 !ml-auto" : null,
|
|
205
209
|
"body-class": dialogTypeRight.value ? "flex-grow h-0" : null
|
|
206
210
|
}, _ctx.$attrs), {
|
|
207
211
|
header: vue.withCtx(() => [
|
|
@@ -245,9 +249,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
245
249
|
vue.createElementVNode(
|
|
246
250
|
"div",
|
|
247
251
|
{
|
|
248
|
-
class: vue.normalizeClass([
|
|
249
|
-
"flex-grow h-0": dialogTypeRight.value
|
|
250
|
-
}, "scroll-body overflow-auto px-6 py-4"])
|
|
252
|
+
class: vue.normalizeClass([bodyContentClass.value, "scroll-body overflow-auto px-6 py-4"])
|
|
251
253
|
},
|
|
252
254
|
[
|
|
253
255
|
vue.renderSlot(_ctx.$slots, "default")
|
|
@@ -3,11 +3,14 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var input = require('./input.vue.js');
|
|
6
|
+
var inputSearch = require('./inputSearch.vue.js');
|
|
6
7
|
var handler = require('../../utils/handler.js');
|
|
7
8
|
|
|
8
9
|
const HyInput = handler.withInstall(input.default);
|
|
10
|
+
const HyInputSearch = handler.withInstall(inputSearch.default);
|
|
9
11
|
const ElInput = handler.withInstall(input.default, "ElInput");
|
|
10
12
|
|
|
11
13
|
exports.ElInput = ElInput;
|
|
12
14
|
exports.HyInput = HyInput;
|
|
15
|
+
exports.HyInputSearch = HyInputSearch;
|
|
13
16
|
exports.default = HyInput;
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
var elementPlus = require('element-plus');
|
|
7
|
+
var iconsVue = require('@element-plus/icons-vue');
|
|
8
|
+
var input = require('./input.vue.js');
|
|
9
|
+
|
|
10
|
+
import "./style/inputSearch.scss";
|
|
11
|
+
|
|
12
|
+
const __default__ = vue.defineComponent({
|
|
13
|
+
name: "HyInputSearch"
|
|
14
|
+
});
|
|
15
|
+
const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
16
|
+
props: /* @__PURE__ */ vue.mergeModels({}, {
|
|
17
|
+
"modelValue": {
|
|
18
|
+
type: [String, Number],
|
|
19
|
+
default: ""
|
|
20
|
+
},
|
|
21
|
+
"modelModifiers": {}
|
|
22
|
+
}),
|
|
23
|
+
emits: /* @__PURE__ */ vue.mergeModels(["search"], ["update:modelValue"]),
|
|
24
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
25
|
+
const emits = __emit;
|
|
26
|
+
const modelValue = vue.useModel(__props, "modelValue");
|
|
27
|
+
const inputRef = vue.useTemplateRef("inputRef");
|
|
28
|
+
const isSearchFocus = vue.ref(false);
|
|
29
|
+
function onSearchInputHandler() {
|
|
30
|
+
isSearchFocus.value = true;
|
|
31
|
+
}
|
|
32
|
+
function onSearchBlurHandler() {
|
|
33
|
+
isSearchFocus.value = false;
|
|
34
|
+
}
|
|
35
|
+
function onSearchQueryHandler() {
|
|
36
|
+
emits("search", modelValue.value);
|
|
37
|
+
}
|
|
38
|
+
__expose({
|
|
39
|
+
blur() {
|
|
40
|
+
inputRef.value.blur();
|
|
41
|
+
},
|
|
42
|
+
clear() {
|
|
43
|
+
inputRef.value.clear();
|
|
44
|
+
},
|
|
45
|
+
focus() {
|
|
46
|
+
inputRef.value.focus();
|
|
47
|
+
},
|
|
48
|
+
input: vue.computed(() => {
|
|
49
|
+
return inputRef.value.input;
|
|
50
|
+
}),
|
|
51
|
+
ref: vue.computed(() => {
|
|
52
|
+
return inputRef.value.ref;
|
|
53
|
+
}),
|
|
54
|
+
resizeTextarea() {
|
|
55
|
+
inputRef.value.resizeTextarea();
|
|
56
|
+
},
|
|
57
|
+
select() {
|
|
58
|
+
inputRef.value.select();
|
|
59
|
+
},
|
|
60
|
+
textarea: vue.computed(() => {
|
|
61
|
+
return inputRef.value.textarea;
|
|
62
|
+
}),
|
|
63
|
+
textareaStyle: vue.computed(() => {
|
|
64
|
+
return inputRef.value.textareaStyle;
|
|
65
|
+
}),
|
|
66
|
+
isComposing: vue.computed(() => {
|
|
67
|
+
return inputRef.value.isComposing;
|
|
68
|
+
}),
|
|
69
|
+
passwordVisible: vue.computed(() => {
|
|
70
|
+
return inputRef.value.passwordVisible;
|
|
71
|
+
})
|
|
72
|
+
});
|
|
73
|
+
return (_ctx, _cache) => {
|
|
74
|
+
return vue.openBlock(), vue.createElementBlock(
|
|
75
|
+
"div",
|
|
76
|
+
{
|
|
77
|
+
class: vue.normalizeClass(["hy-input-search", { focus: isSearchFocus.value }])
|
|
78
|
+
},
|
|
79
|
+
[
|
|
80
|
+
vue.renderSlot(_ctx.$slots, "before"),
|
|
81
|
+
vue.createVNode(input.default, vue.mergeProps({
|
|
82
|
+
ref_key: "inputRef",
|
|
83
|
+
ref: inputRef,
|
|
84
|
+
modelValue: modelValue.value,
|
|
85
|
+
"onUpdate:modelValue": ($event) => modelValue.value = $event,
|
|
86
|
+
clearable: "",
|
|
87
|
+
class: "hy-input-search-item"
|
|
88
|
+
}, _ctx.$attrs, {
|
|
89
|
+
onFocus: onSearchInputHandler,
|
|
90
|
+
onBlur: onSearchBlurHandler,
|
|
91
|
+
onClear: onSearchQueryHandler,
|
|
92
|
+
onKeydown: vue.withKeys(onSearchQueryHandler, ["enter"])
|
|
93
|
+
}), vue.createSlots({
|
|
94
|
+
_: 2
|
|
95
|
+
/* DYNAMIC */
|
|
96
|
+
}, [
|
|
97
|
+
vue.renderList(_ctx.$slots, (_, slotName) => {
|
|
98
|
+
return {
|
|
99
|
+
name: slotName,
|
|
100
|
+
fn: vue.withCtx((scope) => [
|
|
101
|
+
vue.renderSlot(_ctx.$slots, slotName, vue.normalizeProps(vue.guardReactiveProps(scope)))
|
|
102
|
+
])
|
|
103
|
+
};
|
|
104
|
+
})
|
|
105
|
+
]), 1040, ["modelValue", "onUpdate:modelValue"]),
|
|
106
|
+
vue.createElementVNode("div", {
|
|
107
|
+
class: "w-[32px] h-[32px] flex-shrink-0 flex items-center justify-center bg-background-3 rounded-[2px] cursor-pointer",
|
|
108
|
+
onClick: onSearchQueryHandler
|
|
109
|
+
}, [
|
|
110
|
+
vue.createVNode(vue.unref(elementPlus.ElIcon), { size: "18" }, {
|
|
111
|
+
default: vue.withCtx(() => [
|
|
112
|
+
vue.createVNode(vue.unref(iconsVue.Search))
|
|
113
|
+
]),
|
|
114
|
+
_: 1
|
|
115
|
+
/* STABLE */
|
|
116
|
+
})
|
|
117
|
+
])
|
|
118
|
+
],
|
|
119
|
+
2
|
|
120
|
+
/* CLASS */
|
|
121
|
+
);
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
});
|
|
125
|
+
|
|
126
|
+
exports.default = _sfc_main;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
.hy-input-search {
|
|
2
|
+
width: 100%;
|
|
3
|
+
min-width: 160px;
|
|
4
|
+
display: flex;
|
|
5
|
+
align-items: center;
|
|
6
|
+
gap: 4px;
|
|
7
|
+
border: 1px solid rgba(var(--hy-border));
|
|
8
|
+
border-radius: 4px;
|
|
9
|
+
box-sizing: border-box;
|
|
10
|
+
padding: 2px 4px;
|
|
11
|
+
overflow: hidden;
|
|
12
|
+
background: rgba(var(--hy-background-2));
|
|
13
|
+
&:hover,
|
|
14
|
+
&.focus {
|
|
15
|
+
border: 1px solid rgba(var(--hy-theme));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.hy-input-search-item {
|
|
19
|
+
width: 0;
|
|
20
|
+
flex: 1;
|
|
21
|
+
& > .hy-el-input__wrapper {
|
|
22
|
+
padding-left: 8px;
|
|
23
|
+
padding-right: 4px;
|
|
24
|
+
}
|
|
25
|
+
.hy-el-input__inner::placeholder {
|
|
26
|
+
font-size: 12px;
|
|
27
|
+
}
|
|
28
|
+
.hy-el-input__wrapper {
|
|
29
|
+
box-shadow: none;
|
|
30
|
+
}
|
|
31
|
+
.hy-el-input-group__append {
|
|
32
|
+
color: rgb(var(--hy-main));
|
|
33
|
+
background-color: rgba(var(--hy-background-2));
|
|
34
|
+
box-shadow: none;
|
|
35
|
+
padding: 4px;
|
|
36
|
+
min-height: 100%;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
@@ -35,9 +35,8 @@ const genPlaceholderHandler = (config) => {
|
|
|
35
35
|
return { placeholder, startPlaceholder, endPlaceholder };
|
|
36
36
|
};
|
|
37
37
|
const genColumnWidth = (config) => {
|
|
38
|
-
let { width, type, attrs } = config || {};
|
|
39
|
-
|
|
40
|
-
if (!width) {
|
|
38
|
+
let { width, inputWidth, type, attrs } = config || {};
|
|
39
|
+
if (!width && !inputWidth) {
|
|
41
40
|
if (type === "date-picker") {
|
|
42
41
|
switch (attrs?.type) {
|
|
43
42
|
case "datetimerange":
|
|
@@ -156,10 +155,10 @@ const useAppSearch = (config = [], model) => {
|
|
|
156
155
|
const target = appSearchItemHandler(item);
|
|
157
156
|
columns.push(target);
|
|
158
157
|
}
|
|
159
|
-
const
|
|
158
|
+
const filterModel = resetAppSearchValue(columns, model);
|
|
160
159
|
return {
|
|
161
|
-
|
|
162
|
-
|
|
160
|
+
filterModel: vue.toRef(filterModel),
|
|
161
|
+
filterColumns: vue.toRef(columns)
|
|
163
162
|
};
|
|
164
163
|
};
|
|
165
164
|
|
|
@@ -62,9 +62,14 @@ function useAppTableSearch(hy) {
|
|
|
62
62
|
emits("reqSuccess", tableDataSource.value);
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
|
-
async function
|
|
65
|
+
async function resetFields() {
|
|
66
66
|
await vue.nextTick();
|
|
67
|
-
appSearchRef.value
|
|
67
|
+
if (appSearchRef.value) {
|
|
68
|
+
appSearchRef.value.resetFields();
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
async function resetFn() {
|
|
72
|
+
await resetFields();
|
|
68
73
|
props.filterModel.query = null;
|
|
69
74
|
getData(1);
|
|
70
75
|
}
|
|
@@ -106,6 +111,7 @@ function useAppTableSearch(hy) {
|
|
|
106
111
|
showFilter,
|
|
107
112
|
getData,
|
|
108
113
|
setData,
|
|
114
|
+
resetFields,
|
|
109
115
|
resetFn,
|
|
110
116
|
switchShowFilter,
|
|
111
117
|
getTotalElements,
|
|
@@ -144,8 +144,8 @@ const useAppTable = (config = {}) => {
|
|
|
144
144
|
});
|
|
145
145
|
return {
|
|
146
146
|
tableColumns: vue.toRef(tableColumns),
|
|
147
|
-
filterModel: appSearchForm.
|
|
148
|
-
filterColumns: appSearchForm.
|
|
147
|
+
filterModel: appSearchForm.filterModel,
|
|
148
|
+
filterColumns: appSearchForm.filterColumns
|
|
149
149
|
};
|
|
150
150
|
};
|
|
151
151
|
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var vue = require('vue');
|
|
6
6
|
var elementPlus = require('element-plus');
|
|
7
7
|
var iconsVue = require('@element-plus/icons-vue');
|
|
8
|
-
var index$
|
|
8
|
+
var index$5 = require('./js/index.js');
|
|
9
9
|
var search = require('./js/search.js');
|
|
10
10
|
var headerItem = require('./cpns/headerItem.vue.js');
|
|
11
11
|
var columnSelect = require('./cpns/columnSelect.vue.js');
|
|
@@ -13,9 +13,10 @@ var virtualTable = require('./cpns/virtualTable.vue.js');
|
|
|
13
13
|
var useLocale = require('../../hooks/useLocale.js');
|
|
14
14
|
var useMixins = require('../../hooks/useMixins.js');
|
|
15
15
|
var index = require('../hyTooltip/index.js');
|
|
16
|
-
var index$1 = require('../
|
|
17
|
-
var index$2 = require('../
|
|
18
|
-
var index$3 = require('../
|
|
16
|
+
var index$1 = require('../hyInput/index.js');
|
|
17
|
+
var index$2 = require('../hyButton/index.js');
|
|
18
|
+
var index$3 = require('../hyIcon/index.js');
|
|
19
|
+
var index$4 = require('../hySearch/index.js');
|
|
19
20
|
var adaptive = require('../../utils/adaptive.js');
|
|
20
21
|
var is = require('../../utils/is.js');
|
|
21
22
|
|
|
@@ -235,6 +236,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
235
236
|
showFilter,
|
|
236
237
|
getData,
|
|
237
238
|
setData,
|
|
239
|
+
resetFields,
|
|
238
240
|
resetFn,
|
|
239
241
|
switchShowFilter,
|
|
240
242
|
getTotalElements,
|
|
@@ -252,7 +254,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
252
254
|
operatorDropdownRef,
|
|
253
255
|
appSearchRef
|
|
254
256
|
},
|
|
255
|
-
[index$
|
|
257
|
+
[index$5.useAppTableWrapper, search.useAppTableSearch]
|
|
256
258
|
);
|
|
257
259
|
if (props.defaultGetData) {
|
|
258
260
|
getData(1);
|
|
@@ -260,6 +262,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
260
262
|
__expose({
|
|
261
263
|
getData,
|
|
262
264
|
setData,
|
|
265
|
+
resetFields,
|
|
263
266
|
resetFn,
|
|
264
267
|
getSelectedList,
|
|
265
268
|
getTotalElements,
|
|
@@ -282,7 +285,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
282
285
|
key: 0,
|
|
283
286
|
class: "min-h-[36px] flex flex-row-reverse items-center justify-between gap-3 mb-4"
|
|
284
287
|
}, [
|
|
285
|
-
vue.createElementVNode("div", { class: "flex gap-3 whitespace-nowrap" }, [
|
|
288
|
+
vue.createElementVNode("div", { class: "flex items-center gap-3 whitespace-nowrap" }, [
|
|
286
289
|
__props.showEditable ? (vue.openBlock(), vue.createBlock(columnSelect.default, {
|
|
287
290
|
key: 0,
|
|
288
291
|
columns: vue.unref(tableColumns),
|
|
@@ -322,54 +325,22 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
322
325
|
}, null, 8, ["innerHTML"])
|
|
323
326
|
]),
|
|
324
327
|
default: vue.withCtx(() => [
|
|
325
|
-
vue.
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
vue.createVNode(vue.unref(elementPlus.ElInput), {
|
|
332
|
-
modelValue: __props.filterModel.query,
|
|
333
|
-
"onUpdate:modelValue": ($event) => __props.filterModel.query = $event,
|
|
334
|
-
class: "hy-table-search",
|
|
335
|
-
placeholder: vue.unref(t)("table.searchFor", [__props.controllerText || ""]),
|
|
336
|
-
clearable: "",
|
|
337
|
-
onFocus: vue.unref(onSearchInputHandler),
|
|
338
|
-
onBlur: vue.unref(onSearchBlurHandler),
|
|
339
|
-
onClear: vue.unref(onSearchQueryHandler),
|
|
340
|
-
onKeydown: vue.withKeys(vue.unref(onSearchQueryHandler), ["enter"])
|
|
341
|
-
}, {
|
|
342
|
-
append: vue.withCtx(() => [
|
|
343
|
-
vue.createElementVNode("div", {
|
|
344
|
-
class: "w-[32px] h-full flex items-center justify-center bg-background-3 rounded-[2px] cursor-pointer",
|
|
345
|
-
onClick: vue.unref(onSearchQueryHandler)
|
|
346
|
-
}, [
|
|
347
|
-
vue.createVNode(vue.unref(elementPlus.ElIcon), { size: "18" }, {
|
|
348
|
-
default: vue.withCtx(() => [
|
|
349
|
-
vue.createVNode(vue.unref(iconsVue.Search))
|
|
350
|
-
]),
|
|
351
|
-
_: 1
|
|
352
|
-
/* STABLE */
|
|
353
|
-
})
|
|
354
|
-
], 8, ["onClick"])
|
|
355
|
-
]),
|
|
356
|
-
_: 1
|
|
357
|
-
/* STABLE */
|
|
358
|
-
}, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "onFocus", "onBlur", "onClear", "onKeydown"])
|
|
359
|
-
],
|
|
360
|
-
2
|
|
361
|
-
/* CLASS */
|
|
362
|
-
)
|
|
328
|
+
vue.createVNode(vue.unref(index$1.HyInputSearch), {
|
|
329
|
+
modelValue: __props.filterModel.query,
|
|
330
|
+
"onUpdate:modelValue": ($event) => __props.filterModel.query = $event,
|
|
331
|
+
placeholder: vue.unref(t)("table.searchFor", [__props.controllerText || ""]),
|
|
332
|
+
onSearch: vue.unref(onSearchQueryHandler)
|
|
333
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "onSearch"])
|
|
363
334
|
]),
|
|
364
335
|
_: 1
|
|
365
336
|
/* STABLE */
|
|
366
|
-
})) : (vue.openBlock(), vue.createBlock(vue.unref(index$
|
|
337
|
+
})) : (vue.openBlock(), vue.createBlock(vue.unref(index$2.HyButton), {
|
|
367
338
|
key: 3,
|
|
368
339
|
type: "primary",
|
|
369
340
|
onClick: ($event) => vue.unref(getData)()
|
|
370
341
|
}, {
|
|
371
342
|
default: vue.withCtx(() => [
|
|
372
|
-
vue.createVNode(vue.unref(index$
|
|
343
|
+
vue.createVNode(vue.unref(index$3.HyIcon), {
|
|
373
344
|
class: "w-[12px] h-[12px]",
|
|
374
345
|
"svg-name": "ops-button-icon-refres-v2"
|
|
375
346
|
})
|
|
@@ -387,7 +358,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
387
358
|
])) : vue.createCommentVNode("v-if", true)
|
|
388
359
|
])) : vue.createCommentVNode("v-if", true),
|
|
389
360
|
vue.createCommentVNode(" \u67E5\u8BE2\u8FC7\u6EE4 "),
|
|
390
|
-
__props.filterColumns.length > 0 ? (vue.openBlock(), vue.createBlock(vue.unref(index$
|
|
361
|
+
__props.filterColumns.length > 0 ? (vue.openBlock(), vue.createBlock(vue.unref(index$4.HySearch), {
|
|
391
362
|
key: 1,
|
|
392
363
|
ref_key: "appSearchRef",
|
|
393
364
|
ref: appSearchRef,
|
|
@@ -471,11 +442,11 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
471
442
|
}, {
|
|
472
443
|
default: vue.withCtx(() => [
|
|
473
444
|
vue.renderSlot(_ctx.$slots, column.headerSlot, vue.mergeProps({ ref_for: true }, { column, $index: scope.$index }), () => [
|
|
474
|
-
!vue.unref(is.isEmpty)(vue.unref(index$
|
|
445
|
+
!vue.unref(is.isEmpty)(vue.unref(index$5.renderHeaderHandler)(column, scope)) ? (vue.openBlock(), vue.createBlock(vue.unref(index.HyTooltip), {
|
|
475
446
|
key: 0,
|
|
476
447
|
"is-always": false,
|
|
477
448
|
"over-line": 1,
|
|
478
|
-
content: vue.unref(index$
|
|
449
|
+
content: vue.unref(index$5.renderHeaderHandler)(column, scope)
|
|
479
450
|
}, null, 8, ["content"])) : vue.createCommentVNode("v-if", true)
|
|
480
451
|
])
|
|
481
452
|
]),
|
|
@@ -491,7 +462,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
491
462
|
(vue.openBlock(true), vue.createElementBlock(
|
|
492
463
|
vue.Fragment,
|
|
493
464
|
null,
|
|
494
|
-
vue.renderList(vue.unref(index$
|
|
465
|
+
vue.renderList(vue.unref(index$5.operatorFilterHandler)(
|
|
495
466
|
column,
|
|
496
467
|
scope,
|
|
497
468
|
"default"
|
|
@@ -505,11 +476,11 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
505
476
|
default: vue.withCtx(() => [
|
|
506
477
|
vue.createElementVNode("div", {
|
|
507
478
|
class: vue.normalizeClass(["w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer", citem.className]),
|
|
508
|
-
onClick: vue.withModifiers(($event) => vue.unref(index$
|
|
479
|
+
onClick: vue.withModifiers(($event) => vue.unref(index$5.operatorClickHandler)(cindex, column, scope, "default"), ["stop"]),
|
|
509
480
|
onContextmenu: vue.withModifiers(() => {
|
|
510
481
|
}, ["stop"])
|
|
511
482
|
}, [
|
|
512
|
-
vue.createVNode(vue.unref(index$
|
|
483
|
+
vue.createVNode(vue.unref(index$3.HyIcon), {
|
|
513
484
|
"svg-name": citem.svgName,
|
|
514
485
|
"class-name": "!w-4 !h-4"
|
|
515
486
|
}, null, 8, ["svg-name"]),
|
|
@@ -535,7 +506,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
535
506
|
128
|
|
536
507
|
/* KEYED_FRAGMENT */
|
|
537
508
|
)),
|
|
538
|
-
vue.unref(index$
|
|
509
|
+
vue.unref(index$5.operatorFilterHandler)(column, scope, "more")?.length ? (vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElDropdown), {
|
|
539
510
|
key: 0,
|
|
540
511
|
ref_for: true,
|
|
541
512
|
ref_key: "operatorDropdownRef",
|
|
@@ -543,7 +514,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
543
514
|
trigger: "click",
|
|
544
515
|
"popper-style": "min-width: 150px",
|
|
545
516
|
placement: "bottom",
|
|
546
|
-
onCommand: ($event) => vue.unref(index$
|
|
517
|
+
onCommand: ($event) => vue.unref(index$5.operatorClickHandler)($event, column, scope, "more")
|
|
547
518
|
}, {
|
|
548
519
|
dropdown: vue.withCtx(() => [
|
|
549
520
|
vue.createVNode(
|
|
@@ -554,7 +525,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
554
525
|
(vue.openBlock(true), vue.createElementBlock(
|
|
555
526
|
vue.Fragment,
|
|
556
527
|
null,
|
|
557
|
-
vue.renderList(vue.unref(index$
|
|
528
|
+
vue.renderList(vue.unref(index$5.operatorFilterHandler)(
|
|
558
529
|
column,
|
|
559
530
|
scope,
|
|
560
531
|
"more"
|
|
@@ -562,7 +533,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
562
533
|
return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElDropdownItem), {
|
|
563
534
|
key: cindex,
|
|
564
535
|
command: cindex,
|
|
565
|
-
disabled: vue.unref(index$
|
|
536
|
+
disabled: vue.unref(index$5.operatorDisabledHandler)(citem, scope)
|
|
566
537
|
}, {
|
|
567
538
|
default: vue.withCtx(() => [
|
|
568
539
|
vue.createElementVNode("span", null, [
|
|
@@ -573,13 +544,13 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
573
544
|
1
|
|
574
545
|
/* TEXT */
|
|
575
546
|
),
|
|
576
|
-
vue.unref(index$
|
|
547
|
+
vue.unref(index$5.operatorDisabledHandler)(citem, scope) ? (vue.openBlock(), vue.createElementBlock(
|
|
577
548
|
"span",
|
|
578
549
|
{
|
|
579
550
|
key: 0,
|
|
580
551
|
class: "text-xs leading-1"
|
|
581
552
|
},
|
|
582
|
-
"\uFF08" + vue.toDisplayString(vue.unref(index$
|
|
553
|
+
"\uFF08" + vue.toDisplayString(vue.unref(index$5.operatorDisableTextdHandler)(citem, scope)) + "\uFF09",
|
|
583
554
|
1
|
|
584
555
|
/* TEXT */
|
|
585
556
|
)) : vue.createCommentVNode("v-if", true)
|
|
@@ -645,11 +616,11 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
645
616
|
vue.Fragment,
|
|
646
617
|
{ key: 2 },
|
|
647
618
|
[
|
|
648
|
-
!vue.unref(is.isEmpty)(vue.unref(index$
|
|
619
|
+
!vue.unref(is.isEmpty)(vue.unref(index$5.renderContentHandler)(column, scope)) ? (vue.openBlock(), vue.createBlock(vue.unref(index.HyTooltip), {
|
|
649
620
|
key: 0,
|
|
650
621
|
"over-line": 2,
|
|
651
622
|
"is-always": false,
|
|
652
|
-
content: vue.unref(index$
|
|
623
|
+
content: vue.unref(index$5.renderContentHandler)(column, scope)
|
|
653
624
|
}, null, 8, ["content"])) : (vue.openBlock(), vue.createElementBlock("span", {
|
|
654
625
|
key: 1,
|
|
655
626
|
class: "text-auxiliary"
|
|
@@ -776,7 +747,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
776
747
|
"virtual-triggering": "",
|
|
777
748
|
trigger: "contextmenu",
|
|
778
749
|
placement: "bottom",
|
|
779
|
-
onCommand: ($event) => vue.unref(index$
|
|
750
|
+
onCommand: ($event) => vue.unref(index$5.operatorClickHandler)(
|
|
780
751
|
$event,
|
|
781
752
|
vue.unref(tableTriggerRef).column,
|
|
782
753
|
vue.unref(tableTriggerRef).scope
|
|
@@ -788,14 +759,14 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
788
759
|
(vue.openBlock(true), vue.createElementBlock(
|
|
789
760
|
vue.Fragment,
|
|
790
761
|
null,
|
|
791
|
-
vue.renderList(vue.unref(index$
|
|
762
|
+
vue.renderList(vue.unref(index$5.operatorFilterHandler)(
|
|
792
763
|
vue.unref(tableTriggerRef).column,
|
|
793
764
|
vue.unref(tableTriggerRef).scope
|
|
794
765
|
), (citem, cindex) => {
|
|
795
766
|
return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElDropdownItem), {
|
|
796
767
|
key: cindex,
|
|
797
768
|
command: cindex,
|
|
798
|
-
disabled: vue.unref(index$
|
|
769
|
+
disabled: vue.unref(index$5.operatorDisabledHandler)(citem, vue.unref(tableTriggerRef).scope)
|
|
799
770
|
}, {
|
|
800
771
|
default: vue.withCtx(() => [
|
|
801
772
|
vue.createElementVNode("span", null, [
|
|
@@ -806,13 +777,13 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
806
777
|
1
|
|
807
778
|
/* TEXT */
|
|
808
779
|
),
|
|
809
|
-
vue.unref(index$
|
|
780
|
+
vue.unref(index$5.operatorDisabledHandler)(citem, vue.unref(tableTriggerRef).scope) ? (vue.openBlock(), vue.createElementBlock(
|
|
810
781
|
"span",
|
|
811
782
|
{
|
|
812
783
|
key: 0,
|
|
813
784
|
class: "text-xs leading-1"
|
|
814
785
|
},
|
|
815
|
-
"\uFF08" + vue.toDisplayString(vue.unref(index$
|
|
786
|
+
"\uFF08" + vue.toDisplayString(vue.unref(index$5.operatorDisableTextdHandler)(citem, vue.unref(tableTriggerRef).scope)) + "\uFF09",
|
|
816
787
|
1
|
|
817
788
|
/* TEXT */
|
|
818
789
|
)) : vue.createCommentVNode("v-if", true)
|
|
@@ -79,7 +79,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
79
79
|
return props.label;
|
|
80
80
|
});
|
|
81
81
|
function buttonChange(item) {
|
|
82
|
-
|
|
82
|
+
if (item) {
|
|
83
|
+
emits("change", item.value);
|
|
84
|
+
}
|
|
83
85
|
}
|
|
84
86
|
function getDataList(dataList2 = []) {
|
|
85
87
|
const arr = [];
|
|
@@ -228,6 +228,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
|
|
|
228
228
|
});
|
|
229
229
|
initValidateHandler(dataSource.value);
|
|
230
230
|
setData(dataSource.value);
|
|
231
|
+
emits("validate", {
|
|
232
|
+
...statistics.value
|
|
233
|
+
});
|
|
231
234
|
},
|
|
232
235
|
deleteData(data) {
|
|
233
236
|
if (!is.isArray(data)) {
|
package/lib/components/index.js
CHANGED
|
@@ -56,6 +56,7 @@ exports.HyVideoPlayer = index$o.HyVideoPlayer;
|
|
|
56
56
|
exports.HyAudioPlayer = index$4.HyAudioPlayer;
|
|
57
57
|
exports.ElInput = index$1.ElInput;
|
|
58
58
|
exports.HyInput = index$1.HyInput;
|
|
59
|
+
exports.HyInputSearch = index$1.HyInputSearch;
|
|
59
60
|
exports.ElTimePicker = index$2.ElTimePicker;
|
|
60
61
|
exports.HyTimePicker = index$2.HyTimePicker;
|
|
61
62
|
exports.HyBatchTableForm = index$5.HyBatchTableForm;
|
package/lib/index.js
CHANGED
|
@@ -62,6 +62,7 @@ exports.ElDatePicker = index.ElDatePicker;
|
|
|
62
62
|
exports.HyDatePicker = index.HyDatePicker;
|
|
63
63
|
exports.ElInput = index$1.ElInput;
|
|
64
64
|
exports.HyInput = index$1.HyInput;
|
|
65
|
+
exports.HyInputSearch = index$1.HyInputSearch;
|
|
65
66
|
exports.ElTimePicker = index$2.ElTimePicker;
|
|
66
67
|
exports.HyTimePicker = index$2.HyTimePicker;
|
|
67
68
|
exports.ElTooltip = index$3.ElTooltip;
|
package/lib/version.js
CHANGED