ele-admin-plus 1.2.1-beta.1 → 1.2.1-beta.2
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/es/ele-admin-layout/index.d.ts +19 -10
- package/es/ele-admin-layout/props.d.ts +4 -1
- package/es/ele-admin-layout/props.js +4 -1
- package/es/ele-admin-layout/style/index.scss +7 -2
- package/es/ele-admin-layout/style/sidebar.scss +2 -0
- package/es/ele-alert/index.d.ts +1 -1
- package/es/ele-alert/index.js +3 -3
- package/es/ele-app/components/message-body.d.ts +1 -1
- package/es/ele-app/components/message-body.js +2 -2
- package/es/ele-app/plus.d.ts +3 -0
- package/es/ele-avatar-group/index.d.ts +4 -4
- package/es/ele-avatar-group/index.js +15 -15
- package/es/ele-basic-select/index.d.ts +5 -5
- package/es/ele-basic-select/index.js +16 -16
- package/es/ele-check-card/index.d.ts +1 -1
- package/es/ele-check-card/index.js +4 -4
- package/es/ele-copyable/index.d.ts +2 -2
- package/es/ele-copyable/index.js +6 -6
- package/es/ele-cropper/components/cropper-tools.d.ts +3 -3
- package/es/ele-cropper/components/cropper-tools.js +10 -10
- package/es/ele-cropper/index.d.ts +13 -13
- package/es/ele-cropper/index.js +39 -39
- package/es/ele-cropper-modal/index.d.ts +1 -1
- package/es/ele-cropper-modal/index.js +3 -3
- package/es/ele-data-table/util.js +1 -1
- package/es/ele-drawer/index.d.ts +8 -8
- package/es/ele-drawer/index.js +18 -18
- package/es/ele-dropdown/index.d.ts +3 -3
- package/es/ele-dropdown/index.js +9 -9
- package/es/ele-ellipsis/index.d.ts +1 -1
- package/es/ele-ellipsis/index.js +3 -3
- package/es/ele-file-list/components/file-grid-item.d.ts +5 -5
- package/es/ele-file-list/components/file-grid-item.js +15 -15
- package/es/ele-file-list/components/file-grid.d.ts +6 -6
- package/es/ele-file-list/components/file-grid.js +15 -15
- package/es/ele-file-list/components/file-table-item.d.ts +5 -5
- package/es/ele-file-list/components/file-table-item.js +15 -15
- package/es/ele-file-list/components/file-table.d.ts +7 -7
- package/es/ele-file-list/components/file-table.js +19 -19
- package/es/ele-file-list/index.d.ts +6 -6
- package/es/ele-file-list/index.js +22 -22
- package/es/ele-file-list-tool/index.d.ts +1 -1
- package/es/ele-file-list-tool/index.js +2 -2
- package/es/ele-icon-select/components/icon-grid.d.ts +2 -2
- package/es/ele-icon-select/components/icon-grid.js +6 -6
- package/es/ele-icon-select/index.d.ts +7 -7
- package/es/ele-icon-select/index.js +23 -23
- package/es/ele-menus/index.js +15 -15
- package/es/ele-menus/style/index.scss +1 -0
- package/es/ele-menus/util.d.ts +7 -0
- package/es/ele-menus/util.js +49 -26
- package/es/ele-modal/index.d.ts +6 -6
- package/es/ele-modal/index.js +18 -18
- package/es/ele-pagination/index.d.ts +2 -2
- package/es/ele-pagination/index.js +6 -6
- package/es/ele-popconfirm/index.d.ts +7 -17
- package/es/ele-popconfirm/index.js +15 -15
- package/es/ele-popconfirm/props.d.ts +2 -7
- package/es/ele-popover/index.d.ts +7 -17
- package/es/ele-popover/index.js +15 -15
- package/es/ele-popover/props.d.ts +1 -6
- package/es/ele-popover/props.js +1 -0
- package/es/ele-printer/index.d.ts +1 -1
- package/es/ele-printer/index.js +19 -22
- package/es/ele-printer/style/index.scss +2 -2
- package/es/ele-printer/types.d.ts +0 -2
- package/es/ele-printer/util.d.ts +9 -30
- package/es/ele-printer/util.js +118 -109
- package/es/ele-pro-layout/index.d.ts +19 -19
- package/es/ele-pro-layout/index.js +2 -2
- package/es/ele-pro-layout/props.d.ts +1 -1
- package/es/ele-pro-layout/props.js +1 -1
- package/es/ele-pro-table/components/table-tools.d.ts +3 -3
- package/es/ele-pro-table/components/table-tools.js +6 -13
- package/es/ele-pro-table/components/tool-column-list.d.ts +9 -9
- package/es/ele-pro-table/components/tool-column-list.js +33 -33
- package/es/ele-pro-table/components/tool-column.d.ts +24 -38
- package/es/ele-pro-table/components/tool-column.js +80 -102
- package/es/ele-pro-table/components/tool-export.d.ts +4 -4
- package/es/ele-pro-table/components/tool-export.js +28 -40
- package/es/ele-pro-table/components/tool-print.d.ts +10 -7
- package/es/ele-pro-table/components/tool-print.js +36 -46
- package/es/ele-pro-table/index.d.ts +16 -13
- package/es/ele-pro-table/index.js +41 -64
- package/es/ele-pro-table/props.d.ts +2 -2
- package/es/ele-pro-table/props.js +1 -1
- package/es/ele-pro-table/style/index.scss +1 -0
- package/es/ele-pro-table/util.d.ts +38 -30
- package/es/ele-pro-table/util.js +111 -80
- package/es/ele-segmented/index.d.ts +1 -1
- package/es/ele-segmented/index.js +3 -3
- package/es/ele-split-panel/index.d.ts +1 -1
- package/es/ele-split-panel/index.js +3 -3
- package/es/ele-tab-wrap/components/tab-dropdown.d.ts +1 -1
- package/es/ele-tab-wrap/components/tab-dropdown.js +3 -3
- package/es/ele-table-select/index.d.ts +19 -19
- package/es/ele-table-select/index.js +42 -37
- package/es/ele-tool/index.d.ts +6 -3
- package/es/ele-tool/index.js +35 -32
- package/es/ele-tool/style/index.js +0 -1
- package/es/ele-tool/style/index.scss +0 -13
- package/es/ele-toolbar/index.d.ts +3247 -1
- package/es/ele-toolbar/index.js +44 -5
- package/es/ele-toolbar/props.d.ts +6 -2
- package/es/ele-toolbar/props.js +2 -0
- package/es/ele-toolbar/style/index.js +1 -0
- package/es/ele-toolbar/types.d.ts +15 -0
- package/es/ele-tooltip/index.d.ts +9 -9
- package/es/ele-tooltip/index.js +25 -25
- package/es/ele-tour/index.d.ts +3 -3
- package/es/ele-tour/index.js +10 -10
- package/es/ele-tree-select/index.d.ts +9 -9
- package/es/ele-tree-select/index.js +28 -28
- package/es/ele-upload-list/components/list-item.d.ts +3 -3
- package/es/ele-upload-list/components/list-item.js +7 -7
- package/es/ele-upload-list/index.d.ts +4 -4
- package/es/ele-upload-list/index.js +13 -13
- package/es/ele-virtual-table/components/body-cell.d.ts +8 -8
- package/es/ele-virtual-table/components/body-cell.js +24 -24
- package/es/ele-virtual-table/components/body-row.d.ts +7 -7
- package/es/ele-virtual-table/components/body-row.js +21 -21
- package/es/ele-virtual-table/components/cell-checkbox.d.ts +1 -1
- package/es/ele-virtual-table/components/cell-checkbox.js +3 -3
- package/es/ele-virtual-table/components/cell-filter.d.ts +5 -5
- package/es/ele-virtual-table/components/cell-filter.js +18 -18
- package/es/ele-virtual-table/components/footer-row.d.ts +1 -1
- package/es/ele-virtual-table/components/footer-row.js +3 -3
- package/es/ele-virtual-table/components/header-cell.d.ts +5 -5
- package/es/ele-virtual-table/components/header-cell.js +15 -15
- package/es/ele-virtual-table/components/header-row.d.ts +5 -5
- package/es/ele-virtual-table/components/header-row.js +15 -15
- package/es/ele-virtual-table/index.d.ts +23 -21
- package/es/ele-virtual-table/index.js +50 -48
- package/es/ele-virtual-table/util.js +3 -3
- package/es/ele-watermark/index.js +1 -0
- package/es/style/themes/default.scss +8 -8
- package/es/style/themes/rounded.scss +1 -7
- package/es/utils/core.d.ts +7 -1
- package/lib/ele-admin-layout/index.d.ts +19 -10
- package/lib/ele-admin-layout/props.cjs +4 -1
- package/lib/ele-admin-layout/props.d.ts +4 -1
- package/lib/ele-admin-layout/style/index.scss +7 -2
- package/lib/ele-admin-layout/style/sidebar.scss +2 -0
- package/lib/ele-alert/index.cjs +3 -3
- package/lib/ele-alert/index.d.ts +1 -1
- package/lib/ele-app/components/message-body.cjs +2 -2
- package/lib/ele-app/components/message-body.d.ts +1 -1
- package/lib/ele-app/plus.d.ts +3 -0
- package/lib/ele-avatar-group/index.cjs +15 -15
- package/lib/ele-avatar-group/index.d.ts +4 -4
- package/lib/ele-basic-select/index.cjs +16 -16
- package/lib/ele-basic-select/index.d.ts +5 -5
- package/lib/ele-check-card/index.cjs +4 -4
- package/lib/ele-check-card/index.d.ts +1 -1
- package/lib/ele-copyable/index.cjs +6 -6
- package/lib/ele-copyable/index.d.ts +2 -2
- package/lib/ele-cropper/components/cropper-tools.cjs +10 -10
- package/lib/ele-cropper/components/cropper-tools.d.ts +3 -3
- package/lib/ele-cropper/index.cjs +39 -39
- package/lib/ele-cropper/index.d.ts +13 -13
- package/lib/ele-cropper-modal/index.cjs +3 -3
- package/lib/ele-cropper-modal/index.d.ts +1 -1
- package/lib/ele-data-table/util.cjs +1 -1
- package/lib/ele-drawer/index.cjs +18 -18
- package/lib/ele-drawer/index.d.ts +8 -8
- package/lib/ele-dropdown/index.cjs +9 -9
- package/lib/ele-dropdown/index.d.ts +3 -3
- package/lib/ele-ellipsis/index.cjs +3 -3
- package/lib/ele-ellipsis/index.d.ts +1 -1
- package/lib/ele-file-list/components/file-grid-item.cjs +15 -15
- package/lib/ele-file-list/components/file-grid-item.d.ts +5 -5
- package/lib/ele-file-list/components/file-grid.cjs +15 -15
- package/lib/ele-file-list/components/file-grid.d.ts +6 -6
- package/lib/ele-file-list/components/file-table-item.cjs +15 -15
- package/lib/ele-file-list/components/file-table-item.d.ts +5 -5
- package/lib/ele-file-list/components/file-table.cjs +19 -19
- package/lib/ele-file-list/components/file-table.d.ts +7 -7
- package/lib/ele-file-list/index.cjs +22 -22
- package/lib/ele-file-list/index.d.ts +6 -6
- package/lib/ele-file-list-tool/index.cjs +2 -2
- package/lib/ele-file-list-tool/index.d.ts +1 -1
- package/lib/ele-icon-select/components/icon-grid.cjs +6 -6
- package/lib/ele-icon-select/components/icon-grid.d.ts +2 -2
- package/lib/ele-icon-select/index.cjs +23 -23
- package/lib/ele-icon-select/index.d.ts +7 -7
- package/lib/ele-menus/index.cjs +15 -15
- package/lib/ele-menus/style/index.scss +1 -0
- package/lib/ele-menus/util.cjs +49 -26
- package/lib/ele-menus/util.d.ts +7 -0
- package/lib/ele-modal/index.cjs +18 -18
- package/lib/ele-modal/index.d.ts +6 -6
- package/lib/ele-pagination/index.cjs +6 -6
- package/lib/ele-pagination/index.d.ts +2 -2
- package/lib/ele-popconfirm/index.cjs +15 -15
- package/lib/ele-popconfirm/index.d.ts +7 -17
- package/lib/ele-popconfirm/props.d.ts +2 -7
- package/lib/ele-popover/index.cjs +15 -15
- package/lib/ele-popover/index.d.ts +7 -17
- package/lib/ele-popover/props.cjs +1 -0
- package/lib/ele-popover/props.d.ts +1 -6
- package/lib/ele-printer/index.cjs +17 -20
- package/lib/ele-printer/index.d.ts +1 -1
- package/lib/ele-printer/style/index.scss +2 -2
- package/lib/ele-printer/types.d.ts +0 -2
- package/lib/ele-printer/util.cjs +118 -109
- package/lib/ele-printer/util.d.ts +9 -30
- package/lib/ele-pro-layout/index.cjs +2 -2
- package/lib/ele-pro-layout/index.d.ts +19 -19
- package/lib/ele-pro-layout/props.cjs +1 -1
- package/lib/ele-pro-layout/props.d.ts +1 -1
- package/lib/ele-pro-table/components/table-tools.cjs +6 -13
- package/lib/ele-pro-table/components/table-tools.d.ts +3 -3
- package/lib/ele-pro-table/components/tool-column-list.cjs +33 -33
- package/lib/ele-pro-table/components/tool-column-list.d.ts +9 -9
- package/lib/ele-pro-table/components/tool-column.cjs +79 -101
- package/lib/ele-pro-table/components/tool-column.d.ts +24 -38
- package/lib/ele-pro-table/components/tool-export.cjs +28 -40
- package/lib/ele-pro-table/components/tool-export.d.ts +4 -4
- package/lib/ele-pro-table/components/tool-print.cjs +36 -46
- package/lib/ele-pro-table/components/tool-print.d.ts +10 -7
- package/lib/ele-pro-table/index.cjs +41 -64
- package/lib/ele-pro-table/index.d.ts +16 -13
- package/lib/ele-pro-table/props.cjs +1 -1
- package/lib/ele-pro-table/props.d.ts +2 -2
- package/lib/ele-pro-table/style/index.scss +1 -0
- package/lib/ele-pro-table/util.cjs +111 -80
- package/lib/ele-pro-table/util.d.ts +38 -30
- package/lib/ele-segmented/index.cjs +3 -3
- package/lib/ele-segmented/index.d.ts +1 -1
- package/lib/ele-split-panel/index.cjs +3 -3
- package/lib/ele-split-panel/index.d.ts +1 -1
- package/lib/ele-tab-wrap/components/tab-dropdown.cjs +3 -3
- package/lib/ele-tab-wrap/components/tab-dropdown.d.ts +1 -1
- package/lib/ele-table-select/index.cjs +42 -37
- package/lib/ele-table-select/index.d.ts +19 -19
- package/lib/ele-tool/index.cjs +34 -31
- package/lib/ele-tool/index.d.ts +6 -3
- package/lib/ele-tool/style/index.cjs +0 -1
- package/lib/ele-tool/style/index.scss +0 -13
- package/lib/ele-toolbar/index.cjs +42 -3
- package/lib/ele-toolbar/index.d.ts +3247 -1
- package/lib/ele-toolbar/props.cjs +2 -0
- package/lib/ele-toolbar/props.d.ts +6 -2
- package/lib/ele-toolbar/style/index.cjs +1 -0
- package/lib/ele-toolbar/types.d.ts +15 -0
- package/lib/ele-tooltip/index.cjs +25 -25
- package/lib/ele-tooltip/index.d.ts +9 -9
- package/lib/ele-tour/index.cjs +10 -10
- package/lib/ele-tour/index.d.ts +3 -3
- package/lib/ele-tree-select/index.cjs +28 -28
- package/lib/ele-tree-select/index.d.ts +9 -9
- package/lib/ele-upload-list/components/list-item.cjs +7 -7
- package/lib/ele-upload-list/components/list-item.d.ts +3 -3
- package/lib/ele-upload-list/index.cjs +13 -13
- package/lib/ele-upload-list/index.d.ts +4 -4
- package/lib/ele-virtual-table/components/body-cell.cjs +24 -24
- package/lib/ele-virtual-table/components/body-cell.d.ts +8 -8
- package/lib/ele-virtual-table/components/body-row.cjs +21 -21
- package/lib/ele-virtual-table/components/body-row.d.ts +7 -7
- package/lib/ele-virtual-table/components/cell-checkbox.cjs +3 -3
- package/lib/ele-virtual-table/components/cell-checkbox.d.ts +1 -1
- package/lib/ele-virtual-table/components/cell-filter.cjs +18 -18
- package/lib/ele-virtual-table/components/cell-filter.d.ts +5 -5
- package/lib/ele-virtual-table/components/footer-row.cjs +3 -3
- package/lib/ele-virtual-table/components/footer-row.d.ts +1 -1
- package/lib/ele-virtual-table/components/header-cell.cjs +15 -15
- package/lib/ele-virtual-table/components/header-cell.d.ts +5 -5
- package/lib/ele-virtual-table/components/header-row.cjs +15 -15
- package/lib/ele-virtual-table/components/header-row.d.ts +5 -5
- package/lib/ele-virtual-table/index.cjs +50 -48
- package/lib/ele-virtual-table/index.d.ts +23 -21
- package/lib/ele-virtual-table/util.cjs +3 -3
- package/lib/ele-watermark/index.cjs +1 -0
- package/lib/style/themes/default.scss +8 -8
- package/lib/style/themes/rounded.scss +1 -7
- package/lib/utils/core.d.ts +7 -1
- package/package.json +1 -1
|
@@ -69,23 +69,23 @@ const _sfc_main = defineComponent({
|
|
|
69
69
|
}
|
|
70
70
|
return (_c = props.icons.find((d) => d.type === "file")) == null ? void 0 : _c.icon;
|
|
71
71
|
});
|
|
72
|
-
const
|
|
72
|
+
const handleClick = () => {
|
|
73
73
|
emit("click", props.item);
|
|
74
74
|
};
|
|
75
|
-
const
|
|
75
|
+
const handleCheckChange = () => {
|
|
76
76
|
emit("checkChange", props.item);
|
|
77
77
|
};
|
|
78
|
-
const
|
|
78
|
+
const handleContextmenu = (e) => {
|
|
79
79
|
e.preventDefault();
|
|
80
80
|
e.stopPropagation();
|
|
81
81
|
if (dropdownRef.value) {
|
|
82
82
|
dropdownRef.value.handleOpen();
|
|
83
83
|
}
|
|
84
84
|
};
|
|
85
|
-
const
|
|
85
|
+
const handleItemContextMenu = (command) => {
|
|
86
86
|
emit("contextMenu", { key: command, item: props.item });
|
|
87
87
|
};
|
|
88
|
-
const
|
|
88
|
+
const handleContextVisibleChange = (visible) => {
|
|
89
89
|
dropdownVisible.value = visible;
|
|
90
90
|
if (visible) {
|
|
91
91
|
emit("contextOpen", dropdownRef.value);
|
|
@@ -97,11 +97,11 @@ const _sfc_main = defineComponent({
|
|
|
97
97
|
selectable,
|
|
98
98
|
selected,
|
|
99
99
|
icon,
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
100
|
+
handleClick,
|
|
101
|
+
handleCheckChange,
|
|
102
|
+
handleContextmenu,
|
|
103
|
+
handleItemContextMenu,
|
|
104
|
+
handleContextVisibleChange
|
|
105
105
|
};
|
|
106
106
|
}
|
|
107
107
|
});
|
|
@@ -132,11 +132,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
132
132
|
{ "is-checked": _ctx.selected },
|
|
133
133
|
{ "is-active": _ctx.dropdownVisible }
|
|
134
134
|
]),
|
|
135
|
-
onClick: _cache[3] || (_cache[3] = withModifiers((...args) => _ctx.
|
|
135
|
+
onClick: _cache[3] || (_cache[3] = withModifiers((...args) => _ctx.handleClick && _ctx.handleClick(...args), ["stop"]))
|
|
136
136
|
}, [
|
|
137
137
|
createElementVNode("div", {
|
|
138
138
|
class: "ele-file-list-item-body",
|
|
139
|
-
onContextmenu: _cache[1] || (_cache[1] = (...args) => _ctx.
|
|
139
|
+
onContextmenu: _cache[1] || (_cache[1] = (...args) => _ctx.handleContextmenu && _ctx.handleContextmenu(...args))
|
|
140
140
|
}, [
|
|
141
141
|
_ctx.selectable ? (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
142
142
|
createElementVNode("i", {
|
|
@@ -145,7 +145,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
145
145
|
{ "is-radio": _ctx.selectionType === "radio" },
|
|
146
146
|
{ "is-checked": _ctx.selected }
|
|
147
147
|
]),
|
|
148
|
-
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.
|
|
148
|
+
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.handleCheckChange && _ctx.handleCheckChange(...args), ["stop"]))
|
|
149
149
|
}, null, 2)
|
|
150
150
|
])) : createCommentVNode("", true),
|
|
151
151
|
createElementVNode("div", _hoisted_2, [
|
|
@@ -195,8 +195,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
195
195
|
trigger: "click",
|
|
196
196
|
class: "ele-file-list-item-dropdown",
|
|
197
197
|
items: _ctx.contextMenus,
|
|
198
|
-
onCommand: _ctx.
|
|
199
|
-
onVisibleChange: _ctx.
|
|
198
|
+
onCommand: _ctx.handleItemContextMenu,
|
|
199
|
+
onVisibleChange: _ctx.handleContextVisibleChange
|
|
200
200
|
}), createSlots({
|
|
201
201
|
default: withCtx(() => [
|
|
202
202
|
createElementVNode("div", {
|
|
@@ -40,12 +40,12 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
40
40
|
itemRefs: Ref<TableItemInstance[]>;
|
|
41
41
|
tableCols: import('vue').ComputedRef<ColumnItem[]>;
|
|
42
42
|
getContextMenus: (item: FileItem) => import('../../ele-dropdown/types').DropdownItem[] | undefined;
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
43
|
+
handleCheckAllChange: () => void;
|
|
44
|
+
handleItemClick: (item: FileItem) => void;
|
|
45
|
+
handleItemCheckChange: (item: FileItem) => void;
|
|
46
|
+
handleSortChange: (sort: string, col?: ColumnItem) => void;
|
|
47
|
+
handleItemContextMenu: (option: ItemContextMenuOption) => void;
|
|
48
|
+
handleItemContextOpen: (ref: EleDropdownInstance) => void;
|
|
49
49
|
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
50
50
|
checkAllChange: () => true;
|
|
51
51
|
itemClick: (_item: FileItem) => true;
|
|
@@ -89,8 +89,8 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
89
89
|
onItemClick?: ((_item: FileItem) => any) | undefined;
|
|
90
90
|
onSortChange?: ((_sort: string) => any) | undefined;
|
|
91
91
|
onCheckAllChange?: (() => any) | undefined;
|
|
92
|
-
onItemContextMenu?: ((_option: ItemContextMenuOption) => any) | undefined;
|
|
93
92
|
onItemCheckChange?: ((_item: FileItem) => any) | undefined;
|
|
93
|
+
onItemContextMenu?: ((_option: ItemContextMenuOption) => any) | undefined;
|
|
94
94
|
}, {
|
|
95
95
|
sortable: boolean;
|
|
96
96
|
isIndeterminate: boolean;
|
|
@@ -80,16 +80,16 @@ const _sfc_main = defineComponent({
|
|
|
80
80
|
}
|
|
81
81
|
return props.contextMenus;
|
|
82
82
|
};
|
|
83
|
-
const
|
|
83
|
+
const handleCheckAllChange = () => {
|
|
84
84
|
emit("checkAllChange");
|
|
85
85
|
};
|
|
86
|
-
const
|
|
86
|
+
const handleItemClick = (item) => {
|
|
87
87
|
emit("itemClick", item);
|
|
88
88
|
};
|
|
89
|
-
const
|
|
89
|
+
const handleItemCheckChange = (item) => {
|
|
90
90
|
emit("itemCheckChange", item);
|
|
91
91
|
};
|
|
92
|
-
const
|
|
92
|
+
const handleSortChange = (sort, col) => {
|
|
93
93
|
if (!col) {
|
|
94
94
|
if (props.sortable) {
|
|
95
95
|
emit("sortChange", sort);
|
|
@@ -98,10 +98,10 @@ const _sfc_main = defineComponent({
|
|
|
98
98
|
emit("sortChange", sort);
|
|
99
99
|
}
|
|
100
100
|
};
|
|
101
|
-
const
|
|
101
|
+
const handleItemContextMenu = (option) => {
|
|
102
102
|
emit("itemContextMenu", option);
|
|
103
103
|
};
|
|
104
|
-
const
|
|
104
|
+
const handleItemContextOpen = (ref2) => {
|
|
105
105
|
if (itemRefs.value) {
|
|
106
106
|
itemRefs.value.forEach((r) => {
|
|
107
107
|
if ((r == null ? void 0 : r.dropdownRef) && r.dropdownRef !== ref2) {
|
|
@@ -114,12 +114,12 @@ const _sfc_main = defineComponent({
|
|
|
114
114
|
itemRefs,
|
|
115
115
|
tableCols,
|
|
116
116
|
getContextMenus,
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
117
|
+
handleCheckAllChange,
|
|
118
|
+
handleItemClick,
|
|
119
|
+
handleItemCheckChange,
|
|
120
|
+
handleSortChange,
|
|
121
|
+
handleItemContextMenu,
|
|
122
|
+
handleItemContextOpen
|
|
123
123
|
};
|
|
124
124
|
}
|
|
125
125
|
});
|
|
@@ -156,12 +156,12 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
156
156
|
{ "is-checked": _ctx.isCheckAll },
|
|
157
157
|
{ "is-indeterminate": _ctx.isIndeterminate }
|
|
158
158
|
]),
|
|
159
|
-
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.
|
|
159
|
+
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.handleCheckAllChange && _ctx.handleCheckAllChange(...args), ["stop"]))
|
|
160
160
|
}, null, 2)) : createCommentVNode("", true)
|
|
161
161
|
])) : createCommentVNode("", true),
|
|
162
162
|
createElementVNode("div", {
|
|
163
163
|
class: "ele-file-list-item-name",
|
|
164
|
-
onClick: _cache[1] || (_cache[1] = ($event) => _ctx.
|
|
164
|
+
onClick: _cache[1] || (_cache[1] = ($event) => _ctx.handleSortChange("name"))
|
|
165
165
|
}, [
|
|
166
166
|
createElementVNode("span", null, toDisplayString(_ctx.nameText), 1),
|
|
167
167
|
_ctx.sortable ? (openBlock(), createBlock(_component_FileSort, {
|
|
@@ -176,7 +176,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
176
176
|
key: col.prop,
|
|
177
177
|
style: normalizeStyle(col.headerStyle || col.style),
|
|
178
178
|
class: "ele-file-list-item-cell",
|
|
179
|
-
onClick: ($event) => _ctx.
|
|
179
|
+
onClick: ($event) => _ctx.handleSortChange(col.prop, col)
|
|
180
180
|
}, [
|
|
181
181
|
createElementVNode("span", null, [
|
|
182
182
|
col.headerSlot && !["icon", "title", "tool", "contextMenu"].includes(
|
|
@@ -213,10 +213,10 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
213
213
|
columns: _ctx.tableCols,
|
|
214
214
|
contextMenus: _ctx.getContextMenus(item),
|
|
215
215
|
contextMenuProps: _ctx.contextMenuProps,
|
|
216
|
-
onClick: _ctx.
|
|
217
|
-
onCheckChange: _ctx.
|
|
218
|
-
onContextMenu: _ctx.
|
|
219
|
-
onContextOpen: _ctx.
|
|
216
|
+
onClick: _ctx.handleItemClick,
|
|
217
|
+
onCheckChange: _ctx.handleItemCheckChange,
|
|
218
|
+
onContextMenu: _ctx.handleItemContextMenu,
|
|
219
|
+
onContextOpen: _ctx.handleItemContextOpen
|
|
220
220
|
}, createSlots({ _: 2 }, [
|
|
221
221
|
renderList(Object.keys(_ctx.$slots), (name) => {
|
|
222
222
|
return {
|
|
@@ -34,12 +34,12 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
34
34
|
selectorStyle: Ref<Partial<import('vue').CSSProperties>>;
|
|
35
35
|
isCheckAll: import('vue').ComputedRef<boolean>;
|
|
36
36
|
isIndeterminate: import('vue').ComputedRef<boolean>;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
37
|
+
handleCheckAllChange: () => void;
|
|
38
|
+
handleItemCheckChange: (item: FileItem) => void;
|
|
39
|
+
handleItemClick: (item: FileItem) => void;
|
|
40
|
+
handleSortChange: (name: string) => void;
|
|
41
|
+
handleItemContextMenu: (option: ItemContextMenuOption) => void;
|
|
42
|
+
handleMousedown: (event: MouseEvent) => void;
|
|
43
43
|
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
44
44
|
itemClick: (_item: FileItem) => boolean;
|
|
45
45
|
sortChange: (_sorter: SortValue) => boolean;
|
|
@@ -36,7 +36,7 @@ const _sfc_main = defineComponent({
|
|
|
36
36
|
const updateCurrent = (current) => {
|
|
37
37
|
emit("update:current", current);
|
|
38
38
|
};
|
|
39
|
-
const
|
|
39
|
+
const handleCheckAllChange = () => {
|
|
40
40
|
if (props.selectionType !== "checkbox") {
|
|
41
41
|
return;
|
|
42
42
|
}
|
|
@@ -62,7 +62,7 @@ const _sfc_main = defineComponent({
|
|
|
62
62
|
);
|
|
63
63
|
updateSelections(temp);
|
|
64
64
|
};
|
|
65
|
-
const
|
|
65
|
+
const handleItemCheckChange = (item) => {
|
|
66
66
|
if (props.selectionType === "radio") {
|
|
67
67
|
updateCurrent(
|
|
68
68
|
props.current && props.current.key === item.key ? null : item
|
|
@@ -82,10 +82,10 @@ const _sfc_main = defineComponent({
|
|
|
82
82
|
}
|
|
83
83
|
updateSelections(props.selections.filter((t) => t.key !== item.key));
|
|
84
84
|
};
|
|
85
|
-
const
|
|
85
|
+
const handleItemClick = (item) => {
|
|
86
86
|
emit("itemClick", item);
|
|
87
87
|
};
|
|
88
|
-
const
|
|
88
|
+
const handleSortChange = (name) => {
|
|
89
89
|
const sorter = { sort: name };
|
|
90
90
|
if (props.order && name === props.sort) {
|
|
91
91
|
sorter.order = props.order === "asc" ? "desc" : null;
|
|
@@ -94,10 +94,10 @@ const _sfc_main = defineComponent({
|
|
|
94
94
|
}
|
|
95
95
|
emit("sortChange", sorter);
|
|
96
96
|
};
|
|
97
|
-
const
|
|
97
|
+
const handleItemContextMenu = (option) => {
|
|
98
98
|
emit("itemContextMenu", option);
|
|
99
99
|
};
|
|
100
|
-
const
|
|
100
|
+
const handleMousedown = (event) => {
|
|
101
101
|
if (!props.boxChoose || props.selectionType !== "checkbox") {
|
|
102
102
|
return;
|
|
103
103
|
}
|
|
@@ -185,12 +185,12 @@ const _sfc_main = defineComponent({
|
|
|
185
185
|
selectorStyle,
|
|
186
186
|
isCheckAll,
|
|
187
187
|
isIndeterminate,
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
188
|
+
handleCheckAllChange,
|
|
189
|
+
handleItemCheckChange,
|
|
190
|
+
handleItemClick,
|
|
191
|
+
handleSortChange,
|
|
192
|
+
handleItemContextMenu,
|
|
193
|
+
handleMousedown
|
|
194
194
|
};
|
|
195
195
|
}
|
|
196
196
|
});
|
|
@@ -206,7 +206,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
206
206
|
const _component_FileTable = resolveComponent("FileTable");
|
|
207
207
|
return openBlock(), createElementBlock("div", {
|
|
208
208
|
class: "ele-file-list-group",
|
|
209
|
-
onMousedown: _cache[0] || (_cache[0] = (...args) => _ctx.
|
|
209
|
+
onMousedown: _cache[0] || (_cache[0] = (...args) => _ctx.handleMousedown && _ctx.handleMousedown(...args))
|
|
210
210
|
}, [
|
|
211
211
|
_ctx.grid ? (openBlock(), createBlock(_component_FileGrid, {
|
|
212
212
|
key: 0,
|
|
@@ -221,10 +221,10 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
221
221
|
selectedText: _ctx.lang.selectTips,
|
|
222
222
|
contextMenus: _ctx.contextMenus,
|
|
223
223
|
contextMenuProps: _ctx.contextMenuProps,
|
|
224
|
-
onCheckAllChange: _ctx.
|
|
225
|
-
onItemClick: _ctx.
|
|
226
|
-
onItemCheckChange: _ctx.
|
|
227
|
-
onItemContextMenu: _ctx.
|
|
224
|
+
onCheckAllChange: _ctx.handleCheckAllChange,
|
|
225
|
+
onItemClick: _ctx.handleItemClick,
|
|
226
|
+
onItemCheckChange: _ctx.handleItemCheckChange,
|
|
227
|
+
onItemContextMenu: _ctx.handleItemContextMenu
|
|
228
228
|
}, createSlots({ _: 2 }, [
|
|
229
229
|
renderList(Object.keys(_ctx.$slots), (name) => {
|
|
230
230
|
return {
|
|
@@ -252,11 +252,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
252
252
|
columns: _ctx.columns,
|
|
253
253
|
contextMenus: _ctx.contextMenus,
|
|
254
254
|
contextMenuProps: _ctx.contextMenuProps,
|
|
255
|
-
onCheckAllChange: _ctx.
|
|
256
|
-
onItemClick: _ctx.
|
|
257
|
-
onItemCheckChange: _ctx.
|
|
258
|
-
onItemContextMenu: _ctx.
|
|
259
|
-
onSortChange: _ctx.
|
|
255
|
+
onCheckAllChange: _ctx.handleCheckAllChange,
|
|
256
|
+
onItemClick: _ctx.handleItemClick,
|
|
257
|
+
onItemCheckChange: _ctx.handleItemCheckChange,
|
|
258
|
+
onItemContextMenu: _ctx.handleItemContextMenu,
|
|
259
|
+
onSortChange: _ctx.handleSortChange
|
|
260
260
|
}, createSlots({ _: 2 }, [
|
|
261
261
|
renderList(Object.keys(_ctx.$slots), (name) => {
|
|
262
262
|
return {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
declare const _default: import('vue').DefineComponent<{}, {
|
|
2
|
-
|
|
2
|
+
handleClick: (e: MouseEvent) => void;
|
|
3
3
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
4
4
|
click: (_e: MouseEvent) => true;
|
|
5
5
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{}>> & {
|
|
@@ -6,7 +6,7 @@ const _sfc_main = defineComponent({
|
|
|
6
6
|
},
|
|
7
7
|
setup(_props, { emit }) {
|
|
8
8
|
return {
|
|
9
|
-
|
|
9
|
+
handleClick: (e) => emit("click", e)
|
|
10
10
|
};
|
|
11
11
|
}
|
|
12
12
|
});
|
|
@@ -20,7 +20,7 @@ const _export_sfc = (sfc, props) => {
|
|
|
20
20
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
21
21
|
return openBlock(), createElementBlock("div", {
|
|
22
22
|
class: "ele-file-list-item-tool",
|
|
23
|
-
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.
|
|
23
|
+
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.handleClick && _ctx.handleClick(...args), ["stop"]))
|
|
24
24
|
}, [
|
|
25
25
|
renderSlot(_ctx.$slots, "default")
|
|
26
26
|
]);
|
|
@@ -27,8 +27,8 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
27
27
|
virtualRef: import('vue').Ref<any>;
|
|
28
28
|
updateTooltipVisible: (visible: boolean) => void;
|
|
29
29
|
hideTooltip: () => void;
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
handleItemHover: (icon: string, e: MouseEvent) => void;
|
|
31
|
+
handleItemClick: (icon: string) => void;
|
|
32
32
|
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
33
33
|
select: (_icon: string) => true;
|
|
34
34
|
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
@@ -38,14 +38,14 @@ const _sfc_main = defineComponent({
|
|
|
38
38
|
const hideTooltip = () => {
|
|
39
39
|
updateTooltipVisible(false);
|
|
40
40
|
};
|
|
41
|
-
const
|
|
41
|
+
const handleItemHover = (icon, e) => {
|
|
42
42
|
if (props.tooltip && props.popperVisible && icon) {
|
|
43
43
|
virtualRef.value = e.currentTarget;
|
|
44
44
|
tooltipContent.value = icon;
|
|
45
45
|
tooltipVisible.value = true;
|
|
46
46
|
}
|
|
47
47
|
};
|
|
48
|
-
const
|
|
48
|
+
const handleItemClick = (icon) => {
|
|
49
49
|
emit("select", icon);
|
|
50
50
|
};
|
|
51
51
|
watch(
|
|
@@ -62,8 +62,8 @@ const _sfc_main = defineComponent({
|
|
|
62
62
|
virtualRef,
|
|
63
63
|
updateTooltipVisible,
|
|
64
64
|
hideTooltip,
|
|
65
|
-
|
|
66
|
-
|
|
65
|
+
handleItemHover,
|
|
66
|
+
handleItemClick
|
|
67
67
|
};
|
|
68
68
|
}
|
|
69
69
|
});
|
|
@@ -95,8 +95,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
95
95
|
class: normalizeClass(["ele-icon-select-item", { "is-active": _ctx.icon && d === _ctx.icon }]),
|
|
96
96
|
title: _ctx.tooltip ? void 0 : d,
|
|
97
97
|
style: normalizeStyle(_ctx.itemStyle),
|
|
98
|
-
onClick: ($event) => _ctx.
|
|
99
|
-
onMouseover: (e) => _ctx.
|
|
98
|
+
onClick: ($event) => _ctx.handleItemClick(d),
|
|
99
|
+
onMouseover: (e) => _ctx.handleItemHover(d, e)
|
|
100
100
|
}, [
|
|
101
101
|
renderSlot(_ctx.$slots, "icon", { icon: d })
|
|
102
102
|
], 46, _hoisted_1);
|
|
@@ -79,13 +79,13 @@ declare const _default: import('vue').DefineComponent<{
|
|
|
79
79
|
iconPopperStyle: import('vue').ComputedRef<Partial<import('vue').CSSProperties> | undefined>;
|
|
80
80
|
updatePopover: () => void;
|
|
81
81
|
updateVisible: (visible: boolean) => void;
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
82
|
+
handleSelectClear: () => void;
|
|
83
|
+
handleSelectFocus: (e: FocusEvent) => void;
|
|
84
|
+
handleSelectBlur: (e: FocusEvent) => void;
|
|
85
|
+
handleSelectFilter: (value: string) => void;
|
|
86
|
+
handleTabClick: (index: number) => void;
|
|
87
|
+
handleMenuClick: (index: number) => void;
|
|
88
|
+
handleIconSelect: (icon: string) => void;
|
|
89
89
|
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
90
90
|
'update:modelValue': (_value?: string | null | undefined) => boolean;
|
|
91
91
|
change: (_value?: string | null | undefined) => boolean;
|
|
@@ -91,7 +91,7 @@ const _sfc_main = defineComponent({
|
|
|
91
91
|
};
|
|
92
92
|
const updateVisible = (visible) => {
|
|
93
93
|
if (visible) {
|
|
94
|
-
|
|
94
|
+
handleSelectFilter("");
|
|
95
95
|
}
|
|
96
96
|
if (selectVisible.value !== visible) {
|
|
97
97
|
selectVisible.value = visible;
|
|
@@ -104,18 +104,18 @@ const _sfc_main = defineComponent({
|
|
|
104
104
|
emit("change", modelValue);
|
|
105
105
|
}
|
|
106
106
|
};
|
|
107
|
-
const
|
|
107
|
+
const handleSelectClear = () => {
|
|
108
108
|
updateModelValue(null);
|
|
109
109
|
updateVisible(false);
|
|
110
110
|
emit("clear");
|
|
111
111
|
};
|
|
112
|
-
const
|
|
112
|
+
const handleSelectFocus = (e) => {
|
|
113
113
|
emit("focus", e);
|
|
114
114
|
};
|
|
115
|
-
const
|
|
115
|
+
const handleSelectBlur = (e) => {
|
|
116
116
|
emit("blur", e);
|
|
117
117
|
};
|
|
118
|
-
const
|
|
118
|
+
const handleSelectFilter = (value) => {
|
|
119
119
|
var _a;
|
|
120
120
|
if (keywords.value !== value) {
|
|
121
121
|
keywords.value = value;
|
|
@@ -147,15 +147,15 @@ const _sfc_main = defineComponent({
|
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
149
|
};
|
|
150
|
-
const
|
|
150
|
+
const handleTabClick = (index2) => {
|
|
151
151
|
tabActive.value = index2;
|
|
152
152
|
initData();
|
|
153
153
|
};
|
|
154
|
-
const
|
|
154
|
+
const handleMenuClick = (index2) => {
|
|
155
155
|
menuActive.value = index2;
|
|
156
156
|
initData();
|
|
157
157
|
};
|
|
158
|
-
const
|
|
158
|
+
const handleIconSelect = (icon) => {
|
|
159
159
|
updateModelValue(icon);
|
|
160
160
|
updateVisible(false);
|
|
161
161
|
};
|
|
@@ -184,13 +184,13 @@ const _sfc_main = defineComponent({
|
|
|
184
184
|
iconPopperStyle,
|
|
185
185
|
updatePopover,
|
|
186
186
|
updateVisible,
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
187
|
+
handleSelectClear,
|
|
188
|
+
handleSelectFocus,
|
|
189
|
+
handleSelectBlur,
|
|
190
|
+
handleSelectFilter,
|
|
191
|
+
handleTabClick,
|
|
192
|
+
handleMenuClick,
|
|
193
|
+
handleIconSelect
|
|
194
194
|
};
|
|
195
195
|
}
|
|
196
196
|
});
|
|
@@ -231,10 +231,10 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
231
231
|
selectedLabel: _ctx.modelValue,
|
|
232
232
|
visible: _ctx.selectVisible,
|
|
233
233
|
"onUpdate:visible": _ctx.updateVisible,
|
|
234
|
-
onFilterChange: _ctx.
|
|
235
|
-
onClear: _ctx.
|
|
236
|
-
onFocus: _ctx.
|
|
237
|
-
onBlur: _ctx.
|
|
234
|
+
onFilterChange: _ctx.handleSelectFilter,
|
|
235
|
+
onClear: _ctx.handleSelectClear,
|
|
236
|
+
onFocus: _ctx.handleSelectFocus,
|
|
237
|
+
onBlur: _ctx.handleSelectBlur
|
|
238
238
|
}, createSlots({
|
|
239
239
|
default: withCtx(() => [
|
|
240
240
|
createElementVNode("div", {
|
|
@@ -256,7 +256,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
256
256
|
return openBlock(), createElementBlock("div", {
|
|
257
257
|
key: i + "-" + t,
|
|
258
258
|
class: normalizeClass(["ele-icon-select-tab", { "is-active": i === _ctx.tabActive }]),
|
|
259
|
-
onClick: ($event) => _ctx.
|
|
259
|
+
onClick: ($event) => _ctx.handleTabClick(i)
|
|
260
260
|
}, toDisplayString(t), 11, _hoisted_1);
|
|
261
261
|
}), 128))
|
|
262
262
|
], 4)) : createCommentVNode("", true),
|
|
@@ -271,7 +271,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
271
271
|
modelValue: _ctx.keywords,
|
|
272
272
|
prefixIcon: _ctx.SearchOutlined,
|
|
273
273
|
placeholder: _ctx.filterPlaceholder,
|
|
274
|
-
"onUpdate:modelValue": _ctx.
|
|
274
|
+
"onUpdate:modelValue": _ctx.handleSelectFilter
|
|
275
275
|
}, null, 8, ["modelValue", "prefixIcon", "placeholder", "onUpdate:modelValue"])
|
|
276
276
|
], 4)) : createCommentVNode("", true),
|
|
277
277
|
renderSlot(_ctx.$slots, "tabRightExtra")
|
|
@@ -286,7 +286,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
286
286
|
return openBlock(), createElementBlock("div", {
|
|
287
287
|
key: i + "-" + m,
|
|
288
288
|
class: normalizeClass(["ele-icon-select-menu", { "is-active": i === _ctx.menuActive }]),
|
|
289
|
-
onClick: ($event) => _ctx.
|
|
289
|
+
onClick: ($event) => _ctx.handleMenuClick(i)
|
|
290
290
|
}, toDisplayString(m), 11, _hoisted_3);
|
|
291
291
|
}), 128))
|
|
292
292
|
], 4)) : createCommentVNode("", true),
|
|
@@ -300,7 +300,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
300
300
|
gridStyle: _ctx.gridStyle,
|
|
301
301
|
itemStyle: _ctx.itemStyle,
|
|
302
302
|
style: normalizeStyle(_ctx.bodyStyle),
|
|
303
|
-
onSelect: _ctx.
|
|
303
|
+
onSelect: _ctx.handleIconSelect
|
|
304
304
|
}, createSlots({ _: 2 }, [
|
|
305
305
|
_ctx.$slots.icon ? {
|
|
306
306
|
name: "icon",
|
package/es/ele-menus/index.js
CHANGED
|
@@ -108,22 +108,22 @@ const index = defineComponent({
|
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
110
|
};
|
|
111
|
-
const
|
|
111
|
+
const handleItemClick = (item, e) => {
|
|
112
112
|
emit("itemClick", item, e);
|
|
113
113
|
};
|
|
114
|
-
const
|
|
114
|
+
const handleItemMouseenter = (item, e) => {
|
|
115
115
|
triggerTooltip(e);
|
|
116
116
|
emit("itemMouseenter", item, e);
|
|
117
117
|
};
|
|
118
|
-
const
|
|
118
|
+
const handleItemMouseleave = (item, e) => {
|
|
119
119
|
hideTooltip();
|
|
120
120
|
emit("itemMouseleave", item, e);
|
|
121
121
|
};
|
|
122
|
-
const
|
|
122
|
+
const handleParentMouseenter = (item, e) => {
|
|
123
123
|
triggerTooltip(e);
|
|
124
124
|
emit("parentMouseenter", item, e);
|
|
125
125
|
};
|
|
126
|
-
const
|
|
126
|
+
const handleParentMouseleave = (item, e) => {
|
|
127
127
|
hideTooltip();
|
|
128
128
|
emit("parentMouseleave", item, e);
|
|
129
129
|
};
|
|
@@ -174,12 +174,12 @@ const index = defineComponent({
|
|
|
174
174
|
props.popupColorful,
|
|
175
175
|
props.firstPopperClass,
|
|
176
176
|
true,
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
177
|
+
handleItemClick,
|
|
178
|
+
handleItemMouseenter,
|
|
179
|
+
handleItemMouseleave,
|
|
180
180
|
isWebkit,
|
|
181
|
-
|
|
182
|
-
|
|
181
|
+
handleParentMouseenter,
|
|
182
|
+
handleParentMouseleave
|
|
183
183
|
);
|
|
184
184
|
if (moreItems) {
|
|
185
185
|
const ellipsisProps = props.ellipsisProps || {};
|
|
@@ -218,12 +218,12 @@ const index = defineComponent({
|
|
|
218
218
|
props.popupColorful,
|
|
219
219
|
props.firstPopperClass,
|
|
220
220
|
false,
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
221
|
+
handleItemClick,
|
|
222
|
+
handleItemMouseenter,
|
|
223
|
+
handleItemMouseleave,
|
|
224
224
|
isWebkit,
|
|
225
|
-
|
|
226
|
-
|
|
225
|
+
handleParentMouseenter,
|
|
226
|
+
handleParentMouseleave
|
|
227
227
|
);
|
|
228
228
|
},
|
|
229
229
|
title: () => {
|
package/es/ele-menus/util.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { VNode, Slot } from 'vue';
|
|
2
|
+
import { ClassValue, ClassValues } from '../ele-app/types';
|
|
2
3
|
import { MenuItem, MenuTheme, PopupMenuTheme, PopupColorful, MenuResult, MenuEllipsisOption, MenuItemEvent } from './types';
|
|
3
4
|
|
|
4
5
|
/** 子菜单项链接类名 */
|
|
@@ -11,6 +12,12 @@ export declare const triggerClass = "ele-menu-trigger";
|
|
|
11
12
|
export declare const overflowClass = "ele-menu-overflow";
|
|
12
13
|
/** 菜单省略项的类名 */
|
|
13
14
|
export declare const ellipsisClass = "ele-sub-menu-ellipsis";
|
|
15
|
+
/**
|
|
16
|
+
* 合并类名
|
|
17
|
+
* @param class1 类名
|
|
18
|
+
* @param class2 用户自定义类名
|
|
19
|
+
*/
|
|
20
|
+
export declare function mergeClass(class1?: ClassValue, class2?: ClassValue): ClassValues;
|
|
14
21
|
/**
|
|
15
22
|
* 生成菜单链接节点
|
|
16
23
|
* @param path 链接地址
|