@lx-frontend/wrap-element-ui 1.0.0-beta.6 → 1.0.1-beta.1
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/package.json +2 -3
- package/src/components/AddMembers/index.vue +40 -32
- package/src/components/EditableTable/index.less +26 -34
- package/src/components/EditableTable/index.vue +35 -108
- package/src/components/EditableTable/types.ts +10 -32
- package/src/components/EditableTable/useColumnHeaderOperation.ts +28 -166
- package/src/components/EditableTable/useDefaultOperation.ts +10 -10
- package/src/components/EditableTable/useDragSort.ts +5 -4
- package/src/components/EditableTable/usePagination.ts +7 -4
- package/src/components/EditableTable/useRowBgColor.ts +3 -3
- package/src/components/EditableTable/useViewSetting.ts +1 -53
- package/dist/AddMembers/index.vue.d.ts +0 -31
- package/dist/AuditSteps/index.vue.d.ts +0 -46
- package/dist/DemoComponent/index.vue.d.ts +0 -2
- package/dist/EditableTable/index.vue.d.ts +0 -291
- package/dist/EditableTable/types.d.ts +0 -151
- package/dist/EditableTable/useCellHover.d.ts +0 -11
- package/dist/EditableTable/useColumnHeaderOperation.d.ts +0 -223
- package/dist/EditableTable/useDefaultOperation.d.ts +0 -22
- package/dist/EditableTable/useDragSort.d.ts +0 -14
- package/dist/EditableTable/usePagination.d.ts +0 -12
- package/dist/EditableTable/useRowBgColor.d.ts +0 -16
- package/dist/EditableTable/useViewSetting.d.ts +0 -114
- package/dist/Ellipsis/MultilineEllipsis.vue.d.ts +0 -91
- package/dist/Ellipsis/index.vue.d.ts +0 -89
- package/dist/LxTable/index.vue.d.ts +0 -2
- package/dist/PopoverForm/index.vue.d.ts +0 -50
- package/dist/SearchForm/index.vue.d.ts +0 -105
- package/dist/SearchSelect/index.vue.d.ts +0 -53
- package/dist/assets/index.286f4f2d.css +0 -1
- package/dist/index.d.ts +0 -12
- package/dist/index.mjs +0 -39998
- package/dist/singleMessage/index.d.ts +0 -4
|
@@ -1,291 +0,0 @@
|
|
|
1
|
-
import { ITableDataItem, IColumnConfig, IDefaultOperationType, IColorList } from './types';
|
|
2
|
-
|
|
3
|
-
interface IProps {
|
|
4
|
-
/** 表格数据 */
|
|
5
|
-
dataList: ITableDataItem[];
|
|
6
|
-
/** 列配置 */
|
|
7
|
-
columnConfig: IColumnConfig[];
|
|
8
|
-
/** 是否展示展开行 */
|
|
9
|
-
hasExpandRow?: boolean;
|
|
10
|
-
/** 是否展示序号 */
|
|
11
|
-
hasIndexColumn?: boolean;
|
|
12
|
-
/** 是否展示选择列 */
|
|
13
|
-
hasSelectionColumn?: boolean;
|
|
14
|
-
/** 是否支持行拖拽 */
|
|
15
|
-
rowDragAble?: boolean;
|
|
16
|
-
/** 表格总条数 */
|
|
17
|
-
total: number;
|
|
18
|
-
/** 自定义列操作,当前支持行编辑(edit),删除(delete),置顶(top) */
|
|
19
|
-
defaultOperations?: IDefaultOperationType[];
|
|
20
|
-
/** 行背景色列表 */
|
|
21
|
-
colorList?: IColorList;
|
|
22
|
-
/** 左侧固定列数 */
|
|
23
|
-
leftFixedCount?: number;
|
|
24
|
-
/** 性能优化参数,调整拖拽的范围 */
|
|
25
|
-
dragSemiRange?: number;
|
|
26
|
-
/** 是否显示加载 */
|
|
27
|
-
loading?: boolean;
|
|
28
|
-
/** 是否隐藏显示设置按钮 */
|
|
29
|
-
hideViewSettingBtn?: boolean;
|
|
30
|
-
/** 设置的缓存的key */
|
|
31
|
-
settingStorgeKey?: string;
|
|
32
|
-
/** 前端排序,默认关闭 */
|
|
33
|
-
localSort?: boolean;
|
|
34
|
-
/** 前端过滤,默认关闭 */
|
|
35
|
-
localFilter?: boolean;
|
|
36
|
-
/** 页码 */
|
|
37
|
-
currentPage: number;
|
|
38
|
-
}
|
|
39
|
-
declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<IProps>, {
|
|
40
|
-
dataList: () => never[];
|
|
41
|
-
columnConfig: () => never[];
|
|
42
|
-
hasExpandRow: boolean;
|
|
43
|
-
hasIndexColumn: boolean;
|
|
44
|
-
hasSelectionColumn: boolean;
|
|
45
|
-
rowDragAble: boolean;
|
|
46
|
-
total: number;
|
|
47
|
-
defaultOperations: () => never[];
|
|
48
|
-
colorList: () => never[];
|
|
49
|
-
leftFixedCount: number;
|
|
50
|
-
dragSemiRange: number;
|
|
51
|
-
loading: boolean;
|
|
52
|
-
hideViewSettingBtn: boolean;
|
|
53
|
-
settingStorgeKey: string;
|
|
54
|
-
localSort: boolean;
|
|
55
|
-
localFilter: boolean;
|
|
56
|
-
currentPage: number;
|
|
57
|
-
}>, {
|
|
58
|
-
closeAllExpandedRows: () => void;
|
|
59
|
-
openViewSetting: () => void;
|
|
60
|
-
elTableRef: any;
|
|
61
|
-
setSort: (params: {
|
|
62
|
-
order: "descending" | "ascending";
|
|
63
|
-
prop: string;
|
|
64
|
-
}) => void;
|
|
65
|
-
clearSort: () => void;
|
|
66
|
-
setSearchParams: (params: Record<string, any>) => void;
|
|
67
|
-
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
68
|
-
"selection-change": (selection: any) => void;
|
|
69
|
-
"row-bg-change": (param: {
|
|
70
|
-
colorId: number;
|
|
71
|
-
row: ITableDataItem;
|
|
72
|
-
rowIndex: number;
|
|
73
|
-
}) => void;
|
|
74
|
-
"row-drag-drop": (param: {
|
|
75
|
-
row: any;
|
|
76
|
-
fromIndex: number;
|
|
77
|
-
toIndex: number;
|
|
78
|
-
page: number;
|
|
79
|
-
size: number;
|
|
80
|
-
}) => void;
|
|
81
|
-
"row-delete": (param: {
|
|
82
|
-
row: any;
|
|
83
|
-
index: number;
|
|
84
|
-
page: number;
|
|
85
|
-
size: number;
|
|
86
|
-
}) => void;
|
|
87
|
-
"row-edit": (param: {
|
|
88
|
-
row: any;
|
|
89
|
-
index: number;
|
|
90
|
-
page: number;
|
|
91
|
-
size: number;
|
|
92
|
-
}) => void;
|
|
93
|
-
"row-pin-to-top": (param: {
|
|
94
|
-
row: any;
|
|
95
|
-
rawIndex: number;
|
|
96
|
-
page: number;
|
|
97
|
-
size: number;
|
|
98
|
-
}) => void;
|
|
99
|
-
"row-edit-save": (param: {
|
|
100
|
-
page: number;
|
|
101
|
-
size: number;
|
|
102
|
-
row: any;
|
|
103
|
-
changedData: Record<string, any>;
|
|
104
|
-
}) => void;
|
|
105
|
-
"row-edit-cancel": (param: {
|
|
106
|
-
row: any;
|
|
107
|
-
page: number;
|
|
108
|
-
size: number;
|
|
109
|
-
}) => void;
|
|
110
|
-
"page-change": (param: {
|
|
111
|
-
page: number;
|
|
112
|
-
size: number;
|
|
113
|
-
}) => void;
|
|
114
|
-
search: (param: Record<string, any>) => void;
|
|
115
|
-
"sort-change": (param: {
|
|
116
|
-
order: "descending" | "ascending" | null;
|
|
117
|
-
prop: string;
|
|
118
|
-
}) => void;
|
|
119
|
-
}, string, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<IProps>, {
|
|
120
|
-
dataList: () => never[];
|
|
121
|
-
columnConfig: () => never[];
|
|
122
|
-
hasExpandRow: boolean;
|
|
123
|
-
hasIndexColumn: boolean;
|
|
124
|
-
hasSelectionColumn: boolean;
|
|
125
|
-
rowDragAble: boolean;
|
|
126
|
-
total: number;
|
|
127
|
-
defaultOperations: () => never[];
|
|
128
|
-
colorList: () => never[];
|
|
129
|
-
leftFixedCount: number;
|
|
130
|
-
dragSemiRange: number;
|
|
131
|
-
loading: boolean;
|
|
132
|
-
hideViewSettingBtn: boolean;
|
|
133
|
-
settingStorgeKey: string;
|
|
134
|
-
localSort: boolean;
|
|
135
|
-
localFilter: boolean;
|
|
136
|
-
currentPage: number;
|
|
137
|
-
}>>>, {
|
|
138
|
-
colorList: IColorList;
|
|
139
|
-
hasExpandRow: boolean;
|
|
140
|
-
dataList: ITableDataItem[];
|
|
141
|
-
columnConfig: IColumnConfig[];
|
|
142
|
-
hasIndexColumn: boolean;
|
|
143
|
-
hasSelectionColumn: boolean;
|
|
144
|
-
rowDragAble: boolean;
|
|
145
|
-
total: number;
|
|
146
|
-
defaultOperations: IDefaultOperationType[];
|
|
147
|
-
leftFixedCount: number;
|
|
148
|
-
dragSemiRange: number;
|
|
149
|
-
loading: boolean;
|
|
150
|
-
hideViewSettingBtn: boolean;
|
|
151
|
-
settingStorgeKey: string;
|
|
152
|
-
localSort: boolean;
|
|
153
|
-
localFilter: boolean;
|
|
154
|
-
currentPage: number;
|
|
155
|
-
}>, Partial<Record<string, (_: {
|
|
156
|
-
[x: string]: any;
|
|
157
|
-
value: string | number;
|
|
158
|
-
text: string;
|
|
159
|
-
}) => any>> & Partial<Record<string, (_: {
|
|
160
|
-
[x: string]: any;
|
|
161
|
-
value: string | number;
|
|
162
|
-
text: string;
|
|
163
|
-
}) => any>> & Partial<Record<string, (_: {
|
|
164
|
-
[x: string]: any;
|
|
165
|
-
prop: string;
|
|
166
|
-
label: string;
|
|
167
|
-
editType?: import('./types').IEditType | undefined;
|
|
168
|
-
sortable?: boolean | undefined;
|
|
169
|
-
slotName?: string | undefined;
|
|
170
|
-
isAlwaysShow?: boolean | undefined;
|
|
171
|
-
defaultHide?: boolean | undefined;
|
|
172
|
-
search?: boolean | {
|
|
173
|
-
/** 行背景色列表 */
|
|
174
|
-
prop: string;
|
|
175
|
-
label: string;
|
|
176
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
177
|
-
}[] | undefined;
|
|
178
|
-
summary?: boolean | undefined;
|
|
179
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
180
|
-
filters?: {
|
|
181
|
-
type?: "checkbox" | "radio" | undefined;
|
|
182
|
-
options: {
|
|
183
|
-
[key: string]: any;
|
|
184
|
-
value: string | number;
|
|
185
|
-
text: string;
|
|
186
|
-
}[];
|
|
187
|
-
/** 是否展示展开行 */
|
|
188
|
-
default?: string | number | string[] | number[] | undefined;
|
|
189
|
-
} | {
|
|
190
|
-
[key: string]: any;
|
|
191
|
-
value: string | number;
|
|
192
|
-
text: string;
|
|
193
|
-
}[] | undefined;
|
|
194
|
-
} | {
|
|
195
|
-
[x: string]: any;
|
|
196
|
-
prop: string;
|
|
197
|
-
label: string;
|
|
198
|
-
editType?: import('./types').IEditType | undefined;
|
|
199
|
-
sortable?: boolean | undefined;
|
|
200
|
-
slotName?: string | undefined;
|
|
201
|
-
isAlwaysShow?: boolean | undefined;
|
|
202
|
-
defaultHide?: boolean | undefined;
|
|
203
|
-
search?: boolean | {
|
|
204
|
-
/** 行背景色列表 */
|
|
205
|
-
prop: string;
|
|
206
|
-
label: string;
|
|
207
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
208
|
-
}[] | undefined;
|
|
209
|
-
summary?: boolean | undefined;
|
|
210
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
211
|
-
filters?: {
|
|
212
|
-
type?: "checkbox" | "radio" | undefined;
|
|
213
|
-
options: {
|
|
214
|
-
[key: string]: any;
|
|
215
|
-
value: string | number;
|
|
216
|
-
text: string;
|
|
217
|
-
}[];
|
|
218
|
-
/** 是否展示展开行 */
|
|
219
|
-
default?: string | number | string[] | number[] | undefined;
|
|
220
|
-
} | {
|
|
221
|
-
[key: string]: any;
|
|
222
|
-
value: string | number;
|
|
223
|
-
text: string;
|
|
224
|
-
}[] | undefined;
|
|
225
|
-
inputType: string | number;
|
|
226
|
-
} | {
|
|
227
|
-
[x: string]: any;
|
|
228
|
-
prop: string;
|
|
229
|
-
label: string;
|
|
230
|
-
editType?: import('./types').IEditType | undefined;
|
|
231
|
-
sortable?: boolean | undefined;
|
|
232
|
-
slotName?: string | undefined;
|
|
233
|
-
isAlwaysShow?: boolean | undefined;
|
|
234
|
-
defaultHide?: boolean | undefined;
|
|
235
|
-
search?: boolean | {
|
|
236
|
-
/** 行背景色列表 */
|
|
237
|
-
prop: string;
|
|
238
|
-
label: string;
|
|
239
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
240
|
-
}[] | undefined;
|
|
241
|
-
summary?: boolean | undefined;
|
|
242
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
243
|
-
filters?: {
|
|
244
|
-
type?: "checkbox" | "radio" | undefined;
|
|
245
|
-
options: {
|
|
246
|
-
[key: string]: any;
|
|
247
|
-
value: string | number;
|
|
248
|
-
text: string;
|
|
249
|
-
}[];
|
|
250
|
-
/** 是否展示展开行 */
|
|
251
|
-
default?: string | number | string[] | number[] | undefined;
|
|
252
|
-
} | {
|
|
253
|
-
[key: string]: any;
|
|
254
|
-
value: string | number;
|
|
255
|
-
text: string;
|
|
256
|
-
}[] | undefined;
|
|
257
|
-
options: {
|
|
258
|
-
[key: string]: any;
|
|
259
|
-
key: string;
|
|
260
|
-
value: string | number;
|
|
261
|
-
}[];
|
|
262
|
-
}) => any>> & Partial<Record<string, (_: any) => any>> & Partial<Record<any, (_: {
|
|
263
|
-
scope: any;
|
|
264
|
-
column: IColumnConfig;
|
|
265
|
-
}) => any>> & Partial<Record<string, (_: any) => any>> & Partial<Record<any, (_: any) => any>> & Partial<Record<any, (_: any) => any>> & Partial<Record<string, (_: any) => any>> & {
|
|
266
|
-
expand?(_: any): any;
|
|
267
|
-
"custom-operation"?(_: any): any;
|
|
268
|
-
}>;
|
|
269
|
-
export default _default;
|
|
270
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
271
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
272
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
273
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
274
|
-
} : {
|
|
275
|
-
type: import('vue').PropType<T[K]>;
|
|
276
|
-
required: true;
|
|
277
|
-
};
|
|
278
|
-
};
|
|
279
|
-
type __VLS_WithDefaults<P, D> = {
|
|
280
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
281
|
-
default: D[K];
|
|
282
|
-
}> : P[K];
|
|
283
|
-
};
|
|
284
|
-
type __VLS_Prettify<T> = {
|
|
285
|
-
[K in keyof T]: T[K];
|
|
286
|
-
} & {};
|
|
287
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
288
|
-
new (): {
|
|
289
|
-
$scopedSlots: S;
|
|
290
|
-
};
|
|
291
|
-
};
|
|
@@ -1,151 +0,0 @@
|
|
|
1
|
-
export declare enum IEditType {
|
|
2
|
-
INPUT = "input",
|
|
3
|
-
SELECT = "select",
|
|
4
|
-
DATE_ONLY = "date"
|
|
5
|
-
}
|
|
6
|
-
export interface IColumnConfigRequired {
|
|
7
|
-
prop: string;
|
|
8
|
-
label: string;
|
|
9
|
-
editType?: IEditType;
|
|
10
|
-
sortable?: boolean;
|
|
11
|
-
slotName?: string;
|
|
12
|
-
isAlwaysShow?: boolean;
|
|
13
|
-
/** 默认隐藏,显示设置中,该列默认隐藏 */
|
|
14
|
-
defaultHide?: boolean;
|
|
15
|
-
/** 列是否允许搜索,true则表头弹窗会多一个搜索框,一列中有多个搜索字段时传数组进行配置 */
|
|
16
|
-
search?: boolean | ISearchOptions;
|
|
17
|
-
summary?: boolean;
|
|
18
|
-
summaryMethod?: (values: any[]) => string | number;
|
|
19
|
-
/** 过滤,传数组时默认复选框 */
|
|
20
|
-
filters?: {
|
|
21
|
-
type?: 'checkbox' | 'radio';
|
|
22
|
-
options: FiltersOption[];
|
|
23
|
-
default?: string | number | string[] | number[];
|
|
24
|
-
} | FiltersOption[];
|
|
25
|
-
[key: string]: any;
|
|
26
|
-
}
|
|
27
|
-
type FiltersOption = {
|
|
28
|
-
value: string | number;
|
|
29
|
-
text: string;
|
|
30
|
-
[key: string]: any;
|
|
31
|
-
};
|
|
32
|
-
type ISearchOptions = {
|
|
33
|
-
prop: string;
|
|
34
|
-
label: string;
|
|
35
|
-
validator?: (value: string) => boolean;
|
|
36
|
-
}[];
|
|
37
|
-
type IInputColumn = IColumnConfigRequired & {
|
|
38
|
-
inputType: string | number;
|
|
39
|
-
};
|
|
40
|
-
type ISelectColumn = IColumnConfigRequired & {
|
|
41
|
-
options: {
|
|
42
|
-
key: string;
|
|
43
|
-
value: string | number;
|
|
44
|
-
[key: string]: any;
|
|
45
|
-
}[];
|
|
46
|
-
};
|
|
47
|
-
type IDateOnlyColumn = IColumnConfigRequired;
|
|
48
|
-
type IDateTimeColumn = IColumnConfigRequired;
|
|
49
|
-
export type IColumnConfig = IInputColumn | ISelectColumn | IDateOnlyColumn | IDateTimeColumn;
|
|
50
|
-
export type IColorList = {
|
|
51
|
-
name: string;
|
|
52
|
-
textColor: string;
|
|
53
|
-
sampleColor: string;
|
|
54
|
-
bgColor: string;
|
|
55
|
-
id: number;
|
|
56
|
-
default?: boolean;
|
|
57
|
-
}[];
|
|
58
|
-
type IPointLoc = {
|
|
59
|
-
x: number;
|
|
60
|
-
y: number;
|
|
61
|
-
};
|
|
62
|
-
export type IDraggingData = {
|
|
63
|
-
isDragging?: boolean;
|
|
64
|
-
startPosition?: IPointLoc;
|
|
65
|
-
draggingRow?: HTMLElement | HTMLElement[];
|
|
66
|
-
draggingIndex?: number;
|
|
67
|
-
dropIndex?: number;
|
|
68
|
-
rowDoms?: Record<number, HTMLElement[]>;
|
|
69
|
-
rowHeight?: number;
|
|
70
|
-
rowsRange?: ([number, number] | undefined)[];
|
|
71
|
-
hiddenTds?: HTMLElement[];
|
|
72
|
-
fullScreenDiv?: HTMLElement;
|
|
73
|
-
};
|
|
74
|
-
export type IDefaultOperationType = 'edit' | 'delete' | 'top';
|
|
75
|
-
export type ITableDataItem = {
|
|
76
|
-
colorId?: number;
|
|
77
|
-
isPinned?: boolean;
|
|
78
|
-
[k: string]: any;
|
|
79
|
-
};
|
|
80
|
-
export interface IProps {
|
|
81
|
-
dataList: ITableDataItem[];
|
|
82
|
-
columnConfig: IColumnConfig[];
|
|
83
|
-
hasExpandRow?: boolean;
|
|
84
|
-
hasIndexColumn?: boolean;
|
|
85
|
-
hasSelectionColumn?: boolean;
|
|
86
|
-
rowDragAble?: boolean;
|
|
87
|
-
total: number;
|
|
88
|
-
defaultOperations?: IDefaultOperationType[];
|
|
89
|
-
colorList?: IColorList;
|
|
90
|
-
leftFixedCount?: number;
|
|
91
|
-
dragSemiRange?: number;
|
|
92
|
-
loading?: boolean;
|
|
93
|
-
settingStorgeKey?: string;
|
|
94
|
-
localSort?: boolean;
|
|
95
|
-
localFilter?: boolean;
|
|
96
|
-
currentPage: number;
|
|
97
|
-
}
|
|
98
|
-
export interface IEmits {
|
|
99
|
-
(e: 'selection-change', selection: any): void;
|
|
100
|
-
(e: 'row-bg-change', param: {
|
|
101
|
-
colorId: number;
|
|
102
|
-
row: ITableDataItem;
|
|
103
|
-
rowIndex: number;
|
|
104
|
-
}): void;
|
|
105
|
-
(e: 'row-drag-drop', param: {
|
|
106
|
-
row: any;
|
|
107
|
-
fromIndex: number;
|
|
108
|
-
toIndex: number;
|
|
109
|
-
page: number;
|
|
110
|
-
size: number;
|
|
111
|
-
}): void;
|
|
112
|
-
(e: 'row-delete', param: {
|
|
113
|
-
row: any;
|
|
114
|
-
index: number;
|
|
115
|
-
page: number;
|
|
116
|
-
size: number;
|
|
117
|
-
}): void;
|
|
118
|
-
(e: 'row-edit', param: {
|
|
119
|
-
row: any;
|
|
120
|
-
index: number;
|
|
121
|
-
page: number;
|
|
122
|
-
size: number;
|
|
123
|
-
}): void;
|
|
124
|
-
(e: 'row-pin-to-top', param: {
|
|
125
|
-
row: any;
|
|
126
|
-
rawIndex: number;
|
|
127
|
-
page: number;
|
|
128
|
-
size: number;
|
|
129
|
-
}): void;
|
|
130
|
-
(e: 'row-edit-save', param: {
|
|
131
|
-
page: number;
|
|
132
|
-
size: number;
|
|
133
|
-
row: any;
|
|
134
|
-
changedData: Record<string, any>;
|
|
135
|
-
}): void;
|
|
136
|
-
(e: 'row-edit-cancel', param: {
|
|
137
|
-
row: any;
|
|
138
|
-
page: number;
|
|
139
|
-
size: number;
|
|
140
|
-
}): void;
|
|
141
|
-
(e: 'page-change', param: {
|
|
142
|
-
page: number;
|
|
143
|
-
size: number;
|
|
144
|
-
}): void;
|
|
145
|
-
(e: 'search', param: Record<string, any>): void;
|
|
146
|
-
(e: 'sort-change', param: {
|
|
147
|
-
order: 'descending' | 'ascending' | null;
|
|
148
|
-
prop: string;
|
|
149
|
-
}): void;
|
|
150
|
-
}
|
|
151
|
-
export {};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export default function useCellHover(tableDomRef: any): {
|
|
2
|
-
hoveringCellInfo: import('vue').Ref<{
|
|
3
|
-
rowIndex: number;
|
|
4
|
-
columnProperty: string;
|
|
5
|
-
}>;
|
|
6
|
-
setCellClassName: ({ column, rowIndex }: {
|
|
7
|
-
column: any;
|
|
8
|
-
rowIndex: any;
|
|
9
|
-
}) => string;
|
|
10
|
-
debouncedHoverHandler: import('lodash').DebouncedFunc<(row: any, column: any, cell: any, event: any) => void>;
|
|
11
|
-
};
|
|
@@ -1,223 +0,0 @@
|
|
|
1
|
-
import { Ref } from 'vue';
|
|
2
|
-
import { IColumnConfig, IEmits, IProps } from './types';
|
|
3
|
-
|
|
4
|
-
interface IUseColumnHeaderOperationParams {
|
|
5
|
-
props: IProps;
|
|
6
|
-
tableDomRef: any;
|
|
7
|
-
sortFilterPopoverRef: any;
|
|
8
|
-
emit: IEmits;
|
|
9
|
-
showingColumns: Ref<string[]>;
|
|
10
|
-
}
|
|
11
|
-
export default function useColumnHeaderOperation({ props, tableDomRef, sortFilterPopoverRef, emit, showingColumns }: IUseColumnHeaderOperationParams): {
|
|
12
|
-
setSort: (params: {
|
|
13
|
-
order: 'ascending' | 'descending';
|
|
14
|
-
prop: string;
|
|
15
|
-
}) => void;
|
|
16
|
-
clearSort: () => void;
|
|
17
|
-
setSearchParams: (params: Record<string, any>) => void;
|
|
18
|
-
isColumnHeadActive: (column: IColumnConfig) => string | number | boolean | string[] | number[];
|
|
19
|
-
handleHeaderPopoverShow: (column: any) => void;
|
|
20
|
-
handleSort: (type: 'ascending' | 'descending', column: any) => void;
|
|
21
|
-
handleHeaderOperationConfirm: (column: IColumnConfig, scope: any) => Promise<void>;
|
|
22
|
-
handleHeaderOperationReset: (column: IColumnConfig, scope: any) => Promise<void>;
|
|
23
|
-
summaryList: Ref<string[]>;
|
|
24
|
-
tableSummaryMethod: (param: any) => (string | number)[];
|
|
25
|
-
filteredValue: Ref<Record<string, string | number | string[] | number[]>>;
|
|
26
|
-
showColumnHeadSortIcon: (column: IColumnConfig) => any;
|
|
27
|
-
tempSortingColumn: Ref<{
|
|
28
|
-
[x: string]: any;
|
|
29
|
-
prop: string;
|
|
30
|
-
label: string;
|
|
31
|
-
editType?: import('./types').IEditType | undefined;
|
|
32
|
-
sortable?: boolean | undefined;
|
|
33
|
-
slotName?: string | undefined;
|
|
34
|
-
isAlwaysShow?: boolean | undefined;
|
|
35
|
-
defaultHide?: boolean | undefined;
|
|
36
|
-
search?: boolean | {
|
|
37
|
-
prop: string;
|
|
38
|
-
label: string;
|
|
39
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
40
|
-
}[] | undefined;
|
|
41
|
-
summary?: boolean | undefined;
|
|
42
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
43
|
-
filters?: {
|
|
44
|
-
type?: "checkbox" | "radio" | undefined;
|
|
45
|
-
options: {
|
|
46
|
-
[x: string]: any;
|
|
47
|
-
value: string | number;
|
|
48
|
-
text: string;
|
|
49
|
-
}[];
|
|
50
|
-
default?: string | number | string[] | number[] | undefined;
|
|
51
|
-
} | {
|
|
52
|
-
[x: string]: any;
|
|
53
|
-
value: string | number;
|
|
54
|
-
text: string;
|
|
55
|
-
}[] | undefined;
|
|
56
|
-
} | {
|
|
57
|
-
[x: string]: any;
|
|
58
|
-
prop: string;
|
|
59
|
-
label: string;
|
|
60
|
-
editType?: import('./types').IEditType | undefined;
|
|
61
|
-
sortable?: boolean | undefined;
|
|
62
|
-
slotName?: string | undefined;
|
|
63
|
-
isAlwaysShow?: boolean | undefined;
|
|
64
|
-
defaultHide?: boolean | undefined;
|
|
65
|
-
search?: boolean | {
|
|
66
|
-
prop: string;
|
|
67
|
-
label: string;
|
|
68
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
69
|
-
}[] | undefined;
|
|
70
|
-
summary?: boolean | undefined;
|
|
71
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
72
|
-
filters?: {
|
|
73
|
-
type?: "checkbox" | "radio" | undefined;
|
|
74
|
-
options: {
|
|
75
|
-
[x: string]: any;
|
|
76
|
-
value: string | number;
|
|
77
|
-
text: string;
|
|
78
|
-
}[];
|
|
79
|
-
default?: string | number | string[] | number[] | undefined;
|
|
80
|
-
} | {
|
|
81
|
-
[x: string]: any;
|
|
82
|
-
value: string | number;
|
|
83
|
-
text: string;
|
|
84
|
-
}[] | undefined;
|
|
85
|
-
inputType: string | number;
|
|
86
|
-
} | {
|
|
87
|
-
[x: string]: any;
|
|
88
|
-
prop: string;
|
|
89
|
-
label: string;
|
|
90
|
-
editType?: import('./types').IEditType | undefined;
|
|
91
|
-
sortable?: boolean | undefined;
|
|
92
|
-
slotName?: string | undefined;
|
|
93
|
-
isAlwaysShow?: boolean | undefined;
|
|
94
|
-
defaultHide?: boolean | undefined;
|
|
95
|
-
search?: boolean | {
|
|
96
|
-
prop: string;
|
|
97
|
-
label: string;
|
|
98
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
99
|
-
}[] | undefined;
|
|
100
|
-
summary?: boolean | undefined;
|
|
101
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
102
|
-
filters?: {
|
|
103
|
-
type?: "checkbox" | "radio" | undefined;
|
|
104
|
-
options: {
|
|
105
|
-
[x: string]: any;
|
|
106
|
-
value: string | number;
|
|
107
|
-
text: string;
|
|
108
|
-
}[];
|
|
109
|
-
default?: string | number | string[] | number[] | undefined;
|
|
110
|
-
} | {
|
|
111
|
-
[x: string]: any;
|
|
112
|
-
value: string | number;
|
|
113
|
-
text: string;
|
|
114
|
-
}[] | undefined;
|
|
115
|
-
options: {
|
|
116
|
-
[x: string]: any;
|
|
117
|
-
key: string;
|
|
118
|
-
value: string | number;
|
|
119
|
-
}[];
|
|
120
|
-
} | null>;
|
|
121
|
-
tempSearchValue: Ref<Record<string, string>>;
|
|
122
|
-
tempFilteredValue: Ref<Record<string, string | number | string[] | number[]>>;
|
|
123
|
-
tempSummaryList: Ref<string[]>;
|
|
124
|
-
tempSortType: Ref<"descending" | "ascending" | null>;
|
|
125
|
-
sortingColumn: Ref<{
|
|
126
|
-
[x: string]: any;
|
|
127
|
-
prop: string;
|
|
128
|
-
label: string;
|
|
129
|
-
editType?: import('./types').IEditType | undefined;
|
|
130
|
-
sortable?: boolean | undefined;
|
|
131
|
-
slotName?: string | undefined;
|
|
132
|
-
isAlwaysShow?: boolean | undefined;
|
|
133
|
-
defaultHide?: boolean | undefined;
|
|
134
|
-
search?: boolean | {
|
|
135
|
-
prop: string;
|
|
136
|
-
label: string;
|
|
137
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
138
|
-
}[] | undefined;
|
|
139
|
-
summary?: boolean | undefined;
|
|
140
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
141
|
-
filters?: {
|
|
142
|
-
type?: "checkbox" | "radio" | undefined;
|
|
143
|
-
options: {
|
|
144
|
-
[x: string]: any;
|
|
145
|
-
value: string | number;
|
|
146
|
-
text: string;
|
|
147
|
-
}[];
|
|
148
|
-
default?: string | number | string[] | number[] | undefined;
|
|
149
|
-
} | {
|
|
150
|
-
[x: string]: any;
|
|
151
|
-
value: string | number;
|
|
152
|
-
text: string;
|
|
153
|
-
}[] | undefined;
|
|
154
|
-
} | {
|
|
155
|
-
[x: string]: any;
|
|
156
|
-
prop: string;
|
|
157
|
-
label: string;
|
|
158
|
-
editType?: import('./types').IEditType | undefined;
|
|
159
|
-
sortable?: boolean | undefined;
|
|
160
|
-
slotName?: string | undefined;
|
|
161
|
-
isAlwaysShow?: boolean | undefined;
|
|
162
|
-
defaultHide?: boolean | undefined;
|
|
163
|
-
search?: boolean | {
|
|
164
|
-
prop: string;
|
|
165
|
-
label: string;
|
|
166
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
167
|
-
}[] | undefined;
|
|
168
|
-
summary?: boolean | undefined;
|
|
169
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
170
|
-
filters?: {
|
|
171
|
-
type?: "checkbox" | "radio" | undefined;
|
|
172
|
-
options: {
|
|
173
|
-
[x: string]: any;
|
|
174
|
-
value: string | number;
|
|
175
|
-
text: string;
|
|
176
|
-
}[];
|
|
177
|
-
default?: string | number | string[] | number[] | undefined;
|
|
178
|
-
} | {
|
|
179
|
-
[x: string]: any;
|
|
180
|
-
value: string | number;
|
|
181
|
-
text: string;
|
|
182
|
-
}[] | undefined;
|
|
183
|
-
inputType: string | number;
|
|
184
|
-
} | {
|
|
185
|
-
[x: string]: any;
|
|
186
|
-
prop: string;
|
|
187
|
-
label: string;
|
|
188
|
-
editType?: import('./types').IEditType | undefined;
|
|
189
|
-
sortable?: boolean | undefined;
|
|
190
|
-
slotName?: string | undefined;
|
|
191
|
-
isAlwaysShow?: boolean | undefined;
|
|
192
|
-
defaultHide?: boolean | undefined;
|
|
193
|
-
search?: boolean | {
|
|
194
|
-
prop: string;
|
|
195
|
-
label: string;
|
|
196
|
-
validator?: ((value: string) => boolean) | undefined;
|
|
197
|
-
}[] | undefined;
|
|
198
|
-
summary?: boolean | undefined;
|
|
199
|
-
summaryMethod?: ((values: any[]) => string | number) | undefined;
|
|
200
|
-
filters?: {
|
|
201
|
-
type?: "checkbox" | "radio" | undefined;
|
|
202
|
-
options: {
|
|
203
|
-
[x: string]: any;
|
|
204
|
-
value: string | number;
|
|
205
|
-
text: string;
|
|
206
|
-
}[];
|
|
207
|
-
default?: string | number | string[] | number[] | undefined;
|
|
208
|
-
} | {
|
|
209
|
-
[x: string]: any;
|
|
210
|
-
value: string | number;
|
|
211
|
-
text: string;
|
|
212
|
-
}[] | undefined;
|
|
213
|
-
options: {
|
|
214
|
-
[x: string]: any;
|
|
215
|
-
key: string;
|
|
216
|
-
value: string | number;
|
|
217
|
-
}[];
|
|
218
|
-
} | null>;
|
|
219
|
-
isColumnFiltering: import('vue').ComputedRef<boolean>;
|
|
220
|
-
searchValue: Ref<Record<string, string>>;
|
|
221
|
-
inSorting: Ref<boolean>;
|
|
222
|
-
};
|
|
223
|
-
export {};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Ref } from 'vue';
|
|
2
|
-
import { IEmits, IProps } from './types';
|
|
3
|
-
|
|
4
|
-
interface IParams {
|
|
5
|
-
emit: IEmits;
|
|
6
|
-
pageSize: Ref<number>;
|
|
7
|
-
props: IProps;
|
|
8
|
-
tableDomRef: Ref<any>;
|
|
9
|
-
hasExpandRow: boolean;
|
|
10
|
-
}
|
|
11
|
-
export default function useDefaultOperation({ emit, pageSize, props, tableDomRef, hasExpandRow }: IParams): {
|
|
12
|
-
operationPopoverRef: any;
|
|
13
|
-
editingRowData: Ref<Record<string, any>>;
|
|
14
|
-
editingRowIndex: Ref<number>;
|
|
15
|
-
handleDelete: (row: any, index: any) => void;
|
|
16
|
-
closeAllExpandedRows: () => void;
|
|
17
|
-
handleEdit: (scope: any) => void;
|
|
18
|
-
handleEditSave: (row: any) => void;
|
|
19
|
-
handleEditCancel: (row: any) => void;
|
|
20
|
-
handleRowPinToTop: (scope: any) => void;
|
|
21
|
-
};
|
|
22
|
-
export {};
|