ele-admin-plus 1.0.0 → 1.0.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-avatar-group/index.js +2 -2
- package/es/ele-config-provider/receiver.js +1 -1
- package/es/ele-dot/index.d.ts +3 -3
- package/es/ele-dot/props.d.ts +1 -1
- package/es/ele-dot/props.js +1 -1
- package/es/ele-file-list/components/file-grid.js +1 -1
- package/es/ele-file-list/icons.d.ts +10 -2
- package/es/ele-file-list/icons.js +40 -132
- package/es/ele-map-picker/components/map-view.d.ts +1 -1
- package/es/ele-modal/util.js +1 -1
- package/es/ele-page/style/index.scss +2 -1
- package/es/ele-pro-layout/components/pro-tabs.js +2 -1
- package/es/ele-pro-layout/index.d.ts +370 -0
- package/es/ele-pro-layout/index.js +7 -7
- package/es/ele-pro-layout/props.d.ts +1 -4
- package/es/ele-pro-layout/props.js +2 -5
- package/es/ele-pro-layout/types/index.d.ts +1 -1
- package/es/ele-pro-table/components/table-view.d.ts +4 -13
- package/es/ele-pro-table/index.d.ts +5 -14
- package/es/ele-pro-table/index.js +3 -3
- package/es/ele-pro-table/props.d.ts +92 -9
- package/es/ele-pro-table/props.js +3 -1
- package/es/ele-pro-table/style/index.scss +2 -2
- package/es/ele-segmented/index.js +6 -3
- package/es/ele-toolbar/index.d.ts +0 -3
- package/es/ele-toolbar/props.d.ts +0 -1
- package/es/ele-toolbar/props.js +1 -3
- package/es/ele-watermark/index.d.ts +7 -1
- package/es/ele-watermark/index.js +67 -29
- package/es/ele-watermark/props.d.ts +2 -1
- package/es/ele-watermark/props.js +3 -1
- package/es/ele-watermark/types/index.d.ts +13 -0
- package/es/ele-watermark/util.d.ts +8 -1
- package/es/ele-watermark/util.js +31 -1
- package/es/style/themes/dark-css-var.scss +19 -19
- package/es/style/themes/dark.scss +1 -1
- package/es/style/themes/default.scss +1 -1
- package/es/utils/core.d.ts +1 -1
- package/es/utils/menu-util.js +1 -1
- package/lib/ele-avatar-group/index.js +2 -2
- package/lib/ele-config-provider/receiver.js +1 -1
- package/lib/ele-dot/index.d.ts +3 -3
- package/lib/ele-dot/props.d.ts +1 -1
- package/lib/ele-dot/props.js +1 -1
- package/lib/ele-file-list/components/file-grid.js +1 -1
- package/lib/ele-file-list/icons.d.ts +10 -2
- package/lib/ele-file-list/icons.js +40 -132
- package/lib/ele-map-picker/components/map-view.d.ts +1 -1
- package/lib/ele-modal/util.js +1 -1
- package/lib/ele-page/style/index.scss +2 -1
- package/lib/ele-pro-layout/components/pro-tabs.js +2 -1
- package/lib/ele-pro-layout/index.d.ts +370 -0
- package/lib/ele-pro-layout/index.js +6 -6
- package/lib/ele-pro-layout/props.d.ts +1 -4
- package/lib/ele-pro-layout/props.js +2 -5
- package/lib/ele-pro-layout/types/index.d.ts +1 -1
- package/lib/ele-pro-table/components/table-view.d.ts +4 -13
- package/lib/ele-pro-table/index.d.ts +5 -14
- package/lib/ele-pro-table/index.js +3 -3
- package/lib/ele-pro-table/props.d.ts +92 -9
- package/lib/ele-pro-table/props.js +3 -1
- package/lib/ele-pro-table/style/index.scss +2 -2
- package/lib/ele-segmented/index.js +5 -2
- package/lib/ele-toolbar/index.d.ts +0 -3
- package/lib/ele-toolbar/props.d.ts +0 -1
- package/lib/ele-toolbar/props.js +1 -3
- package/lib/ele-watermark/index.d.ts +7 -1
- package/lib/ele-watermark/index.js +65 -27
- package/lib/ele-watermark/props.d.ts +2 -1
- package/lib/ele-watermark/props.js +3 -1
- package/lib/ele-watermark/types/index.d.ts +13 -0
- package/lib/ele-watermark/util.d.ts +8 -1
- package/lib/ele-watermark/util.js +30 -0
- package/lib/style/themes/dark-css-var.scss +19 -19
- package/lib/style/themes/dark.scss +1 -1
- package/lib/style/themes/default.scss +1 -1
- package/lib/utils/core.d.ts +1 -1
- package/lib/utils/menu-util.js +1 -1
- package/package.json +3 -1
|
@@ -28,15 +28,15 @@ const _sfc_main = vue.defineComponent({
|
|
|
28
28
|
const { authenticated } = receiver.useLicense();
|
|
29
29
|
const { currentRoute } = vueRouter.useRouter();
|
|
30
30
|
const contentRef = vue.ref(null);
|
|
31
|
-
const levelData = vue.
|
|
32
|
-
const tabData = vue.
|
|
31
|
+
const levelData = vue.shallowRef([]);
|
|
32
|
+
const tabData = vue.shallowRef([]);
|
|
33
33
|
const tabActive = vue.ref(util.getHomePath(props2.homePath));
|
|
34
|
-
const menuData = vue.
|
|
35
|
-
const headerData = vue.
|
|
34
|
+
const menuData = vue.shallowRef([]);
|
|
35
|
+
const headerData = vue.shallowRef([]);
|
|
36
36
|
const headerActive = vue.ref();
|
|
37
|
-
const sidebarData = vue.
|
|
37
|
+
const sidebarData = vue.shallowRef([]);
|
|
38
38
|
const sidebarActive = vue.ref();
|
|
39
|
-
const sideboxData = vue.
|
|
39
|
+
const sideboxData = vue.shallowRef([]);
|
|
40
40
|
const sideboxActive = vue.ref();
|
|
41
41
|
const hideSidebar = vue.ref(false);
|
|
42
42
|
const hideSidebox = vue.ref(false);
|
|
@@ -69,10 +69,7 @@ export declare const proLayoutProps: {
|
|
|
69
69
|
type: BooleanConstructor;
|
|
70
70
|
default: boolean;
|
|
71
71
|
};
|
|
72
|
-
fixedSidebar:
|
|
73
|
-
type: BooleanConstructor;
|
|
74
|
-
default: boolean;
|
|
75
|
-
};
|
|
72
|
+
fixedSidebar: BooleanConstructor;
|
|
76
73
|
fixedBody: BooleanConstructor;
|
|
77
74
|
fluid: {
|
|
78
75
|
type: BooleanConstructor;
|
|
@@ -87,10 +87,7 @@ const proLayoutProps = {
|
|
|
87
87
|
default: false
|
|
88
88
|
},
|
|
89
89
|
// 是否固定侧栏
|
|
90
|
-
fixedSidebar:
|
|
91
|
-
type: Boolean,
|
|
92
|
-
default: true
|
|
93
|
-
},
|
|
90
|
+
fixedSidebar: Boolean,
|
|
94
91
|
// 是否固定内容区
|
|
95
92
|
fixedBody: Boolean,
|
|
96
93
|
// 内容区是否撑满
|
|
@@ -131,7 +128,7 @@ const proLayoutProps = {
|
|
|
131
128
|
sidebarOpeneds: Array,
|
|
132
129
|
// 是否支持页签右键菜单
|
|
133
130
|
tabContextMenu: Boolean,
|
|
134
|
-
//
|
|
131
|
+
// 是否支持页签拖动排序
|
|
135
132
|
tabSortable: Boolean,
|
|
136
133
|
// 固定主体时切换路由自动滚到顶部
|
|
137
134
|
autoScrollTop: {
|
|
@@ -79,10 +79,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
79
79
|
};
|
|
80
80
|
lazy: BooleanConstructor;
|
|
81
81
|
load: import("vue").PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
82
|
-
style: {
|
|
83
|
-
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
84
|
-
default: () => {};
|
|
85
|
-
};
|
|
86
82
|
className: {
|
|
87
83
|
type: StringConstructor;
|
|
88
84
|
default: string;
|
|
@@ -209,10 +205,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
209
205
|
};
|
|
210
206
|
lazy: BooleanConstructor;
|
|
211
207
|
load: import("vue").PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
212
|
-
style: {
|
|
213
|
-
type: import("vue").PropType<import("vue").CSSProperties>;
|
|
214
|
-
default: () => {};
|
|
215
|
-
};
|
|
216
208
|
className: {
|
|
217
209
|
type: StringConstructor;
|
|
218
210
|
default: string;
|
|
@@ -246,13 +238,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
246
238
|
onHeaderDragend?: ((_width: number, _old: number, _column: import("../types").Column, _e: MouseEvent) => any) | undefined;
|
|
247
239
|
onExpandChange?: ((_row: import("../types").DataItem, _expanded: boolean) => any) | undefined;
|
|
248
240
|
}, {
|
|
249
|
-
className: string;
|
|
250
|
-
style: import("vue").CSSProperties;
|
|
251
|
-
stripe: boolean;
|
|
252
|
-
border: boolean;
|
|
253
|
-
loading: boolean;
|
|
254
241
|
data: any[];
|
|
255
242
|
fit: boolean;
|
|
243
|
+
stripe: boolean;
|
|
244
|
+
border: boolean;
|
|
256
245
|
showHeader: boolean;
|
|
257
246
|
showSummary: boolean;
|
|
258
247
|
highlightCurrentRow: boolean;
|
|
@@ -264,8 +253,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
264
253
|
children?: string | undefined;
|
|
265
254
|
} | undefined;
|
|
266
255
|
lazy: boolean;
|
|
256
|
+
className: string;
|
|
267
257
|
tableLayout: "fixed" | "auto";
|
|
268
258
|
scrollbarAlwaysOn: boolean;
|
|
269
259
|
flexible: boolean;
|
|
260
|
+
loading: boolean;
|
|
270
261
|
}, {}>;
|
|
271
262
|
export default _default;
|
|
@@ -139,10 +139,6 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
139
139
|
};
|
|
140
140
|
lazy: BooleanConstructor;
|
|
141
141
|
load: import("vue").PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
142
|
-
style: {
|
|
143
|
-
type: import("vue").PropType<CSSProperties>;
|
|
144
|
-
default: () => {};
|
|
145
|
-
};
|
|
146
142
|
className: {
|
|
147
143
|
type: StringConstructor;
|
|
148
144
|
default: string;
|
|
@@ -187,16 +183,16 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
187
183
|
hideInTable?: boolean | undefined;
|
|
188
184
|
hideInSetting?: boolean | undefined;
|
|
189
185
|
children?: any[] | undefined;
|
|
190
|
-
type?: string | undefined;
|
|
191
186
|
width?: string | number | undefined;
|
|
187
|
+
type?: string | undefined;
|
|
192
188
|
minWidth?: string | number | undefined;
|
|
193
189
|
sortable?: string | boolean | undefined;
|
|
194
190
|
resizable?: boolean | undefined;
|
|
195
191
|
reserveSelection?: boolean | undefined;
|
|
196
192
|
filterMultiple?: boolean | undefined;
|
|
197
193
|
sortOrders?: ("ascending" | "descending" | null)[] | undefined;
|
|
198
|
-
label?: string | undefined;
|
|
199
194
|
className?: string | undefined;
|
|
195
|
+
label?: string | undefined;
|
|
200
196
|
labelClassName?: string | undefined;
|
|
201
197
|
property?: string | undefined;
|
|
202
198
|
prop?: string | undefined;
|
|
@@ -346,7 +342,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
346
342
|
tableIndex: import("vue").ComputedRef<number>;
|
|
347
343
|
paginationProps: import("vue").ComputedRef<Partial<PaginationProps> | null>;
|
|
348
344
|
tableProps: import("vue").ComputedRef<Partial<TableViewProps>>;
|
|
349
|
-
|
|
345
|
+
proTableStyle: import("vue").ComputedRef<CSSProperties>;
|
|
350
346
|
tableTools: import("vue").ComputedRef<TableTool[]>;
|
|
351
347
|
tableLoad: (row: DataItem, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: DataItem[]) => void) => void;
|
|
352
348
|
onRefresh: () => void;
|
|
@@ -543,10 +539,6 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
543
539
|
};
|
|
544
540
|
lazy: BooleanConstructor;
|
|
545
541
|
load: import("vue").PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
546
|
-
style: {
|
|
547
|
-
type: import("vue").PropType<CSSProperties>;
|
|
548
|
-
default: () => {};
|
|
549
|
-
};
|
|
550
542
|
className: {
|
|
551
543
|
type: StringConstructor;
|
|
552
544
|
default: string;
|
|
@@ -587,10 +579,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
587
579
|
onMaximizedChange?: ((_maximized: boolean) => any) | undefined;
|
|
588
580
|
onRefresh?: (() => any) | undefined;
|
|
589
581
|
}, {
|
|
590
|
-
className: string;
|
|
591
|
-
style: CSSProperties;
|
|
592
582
|
data: any[];
|
|
593
|
-
loading: boolean;
|
|
594
583
|
fit: boolean;
|
|
595
584
|
stripe: boolean;
|
|
596
585
|
border: boolean;
|
|
@@ -605,9 +594,11 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
605
594
|
children?: string | undefined;
|
|
606
595
|
} | undefined;
|
|
607
596
|
lazy: boolean;
|
|
597
|
+
className: string;
|
|
608
598
|
tableLayout: "fixed" | "auto";
|
|
609
599
|
scrollbarAlwaysOn: boolean;
|
|
610
600
|
flexible: boolean;
|
|
601
|
+
loading: boolean;
|
|
611
602
|
loadOnCreated: boolean;
|
|
612
603
|
loadOnChanged: boolean;
|
|
613
604
|
toolbar: boolean | import("./types").TableToolbar;
|
|
@@ -71,7 +71,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
71
71
|
};
|
|
72
72
|
return Object.assign(core.pick(props$1, props.tablePropKeys), opt);
|
|
73
73
|
});
|
|
74
|
-
const
|
|
74
|
+
const proTableStyle = vue.computed(() => {
|
|
75
75
|
if (!tableMaximized.value) {
|
|
76
76
|
return {};
|
|
77
77
|
}
|
|
@@ -475,7 +475,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
475
475
|
tableIndex,
|
|
476
476
|
paginationProps,
|
|
477
477
|
tableProps,
|
|
478
|
-
|
|
478
|
+
proTableStyle,
|
|
479
479
|
tableTools,
|
|
480
480
|
tableLoad,
|
|
481
481
|
onRefresh,
|
|
@@ -521,7 +521,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
521
521
|
{ "is-header-ellipsis": _ctx.headerEllipsis },
|
|
522
522
|
{ "is-maximized": _ctx.tableMaximized }
|
|
523
523
|
]),
|
|
524
|
-
style: vue.normalizeStyle(_ctx.
|
|
524
|
+
style: vue.normalizeStyle(_ctx.proTableStyle)
|
|
525
525
|
}, [
|
|
526
526
|
_ctx.toolbar ? (vue.openBlock(), vue.createBlock(_component_EleToolbar, vue.normalizeProps(vue.mergeProps({ key: 0 }, _ctx.toolbar === true ? {} : _ctx.toolbar)), {
|
|
527
527
|
tools: vue.withCtx(() => [
|
|
@@ -1,6 +1,96 @@
|
|
|
1
1
|
import type { PropType, CSSProperties, ExtractPropTypes } from 'vue';
|
|
2
|
-
import tableProps from 'element-plus/es/components/table/src/table/defaults';
|
|
3
2
|
import type { Column, Columns, DataItem, Where, Datasource, RequestOption, ResponseOption, ParseData, Sorter, Filter, DoneParams, TablePagination, TableToolbar, TableTool, TableSize, RowClickChecked, TableLocale } from './types';
|
|
3
|
+
declare const tableProps: Omit<{
|
|
4
|
+
data: {
|
|
5
|
+
type: PropType<any[]>;
|
|
6
|
+
default: () => never[];
|
|
7
|
+
};
|
|
8
|
+
size: {
|
|
9
|
+
readonly type: PropType<import("element-plus/es/utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
10
|
+
readonly required: false;
|
|
11
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
12
|
+
__epPropKey: true;
|
|
13
|
+
};
|
|
14
|
+
width: (StringConstructor | NumberConstructor)[];
|
|
15
|
+
height: (StringConstructor | NumberConstructor)[];
|
|
16
|
+
maxHeight: (StringConstructor | NumberConstructor)[];
|
|
17
|
+
fit: {
|
|
18
|
+
type: BooleanConstructor;
|
|
19
|
+
default: boolean;
|
|
20
|
+
};
|
|
21
|
+
stripe: BooleanConstructor;
|
|
22
|
+
border: BooleanConstructor;
|
|
23
|
+
rowKey: PropType<string | ((row: any) => string) | undefined>;
|
|
24
|
+
showHeader: {
|
|
25
|
+
type: BooleanConstructor;
|
|
26
|
+
default: boolean;
|
|
27
|
+
};
|
|
28
|
+
showSummary: BooleanConstructor;
|
|
29
|
+
sumText: StringConstructor;
|
|
30
|
+
summaryMethod: PropType<import("element-plus/es/components/table/src/table/defaults").SummaryMethod<any> | undefined>;
|
|
31
|
+
rowClassName: PropType<import("element-plus/es/components/table/src/table/defaults").ColumnCls<any> | undefined>;
|
|
32
|
+
rowStyle: PropType<import("element-plus/es/components/table/src/table/defaults").ColumnStyle<any> | undefined>;
|
|
33
|
+
cellClassName: PropType<import("element-plus/es/components/table/src/table/defaults").CellCls<any> | undefined>;
|
|
34
|
+
cellStyle: PropType<import("element-plus/es/components/table/src/table/defaults").CellStyle<any> | undefined>;
|
|
35
|
+
headerRowClassName: PropType<import("element-plus/es/components/table/src/table/defaults").ColumnCls<any> | undefined>;
|
|
36
|
+
headerRowStyle: PropType<import("element-plus/es/components/table/src/table/defaults").ColumnStyle<any> | undefined>;
|
|
37
|
+
headerCellClassName: PropType<import("element-plus/es/components/table/src/table/defaults").CellCls<any> | undefined>;
|
|
38
|
+
headerCellStyle: PropType<import("element-plus/es/components/table/src/table/defaults").CellStyle<any> | undefined>;
|
|
39
|
+
highlightCurrentRow: BooleanConstructor;
|
|
40
|
+
currentRowKey: (StringConstructor | NumberConstructor)[];
|
|
41
|
+
emptyText: StringConstructor;
|
|
42
|
+
expandRowKeys: PropType<any[] | undefined>;
|
|
43
|
+
defaultExpandAll: BooleanConstructor;
|
|
44
|
+
defaultSort: PropType<import("element-plus/es/components/table/src/table/defaults").Sort | undefined>;
|
|
45
|
+
tooltipEffect: StringConstructor;
|
|
46
|
+
tooltipOptions: PropType<Partial<Pick<import("element-plus").ElTooltipProps, "showArrow" | "effect" | "enterable" | "popperClass" | "offset" | "placement" | "popperOptions" | "showAfter" | "hideAfter">> | undefined>;
|
|
47
|
+
spanMethod: PropType<((data: {
|
|
48
|
+
row: any;
|
|
49
|
+
rowIndex: number;
|
|
50
|
+
column: import("element-plus/es/components/table/src/table-column/defaults").TableColumnCtx<any>;
|
|
51
|
+
columnIndex: number;
|
|
52
|
+
}) => number[] | {
|
|
53
|
+
rowspan: number;
|
|
54
|
+
colspan: number;
|
|
55
|
+
} | undefined) | undefined>;
|
|
56
|
+
selectOnIndeterminate: {
|
|
57
|
+
type: BooleanConstructor;
|
|
58
|
+
default: boolean;
|
|
59
|
+
};
|
|
60
|
+
indent: {
|
|
61
|
+
type: NumberConstructor;
|
|
62
|
+
default: number;
|
|
63
|
+
};
|
|
64
|
+
treeProps: {
|
|
65
|
+
type: PropType<{
|
|
66
|
+
hasChildren?: string | undefined;
|
|
67
|
+
children?: string | undefined;
|
|
68
|
+
} | undefined>;
|
|
69
|
+
default: () => {
|
|
70
|
+
hasChildren: string;
|
|
71
|
+
children: string;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
lazy: BooleanConstructor;
|
|
75
|
+
load: PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
76
|
+
style: {
|
|
77
|
+
type: PropType<CSSProperties>;
|
|
78
|
+
default: () => {};
|
|
79
|
+
};
|
|
80
|
+
className: {
|
|
81
|
+
type: StringConstructor;
|
|
82
|
+
default: string;
|
|
83
|
+
};
|
|
84
|
+
tableLayout: {
|
|
85
|
+
type: PropType<"fixed" | "auto">;
|
|
86
|
+
default: string;
|
|
87
|
+
};
|
|
88
|
+
scrollbarAlwaysOn: {
|
|
89
|
+
type: BooleanConstructor;
|
|
90
|
+
default: boolean;
|
|
91
|
+
};
|
|
92
|
+
flexible: BooleanConstructor;
|
|
93
|
+
}, "style">;
|
|
4
94
|
/**
|
|
5
95
|
* 表格组件属性
|
|
6
96
|
*/
|
|
@@ -83,10 +173,6 @@ export declare const tableViewProps: {
|
|
|
83
173
|
};
|
|
84
174
|
lazy: BooleanConstructor;
|
|
85
175
|
load: PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
86
|
-
style: {
|
|
87
|
-
type: PropType<CSSProperties>;
|
|
88
|
-
default: () => {};
|
|
89
|
-
};
|
|
90
176
|
className: {
|
|
91
177
|
type: StringConstructor;
|
|
92
178
|
default: string;
|
|
@@ -239,10 +325,6 @@ export declare const proTableProps: {
|
|
|
239
325
|
};
|
|
240
326
|
lazy: BooleanConstructor;
|
|
241
327
|
load: PropType<((row: any, treeNode: import("element-plus/es/components/table/src/table/defaults").TreeNode, resolve: (data: any[]) => void) => void) | undefined>;
|
|
242
|
-
style: {
|
|
243
|
-
type: PropType<CSSProperties>;
|
|
244
|
-
default: () => {};
|
|
245
|
-
};
|
|
246
328
|
className: {
|
|
247
329
|
type: StringConstructor;
|
|
248
330
|
default: string;
|
|
@@ -321,3 +403,4 @@ export type TablePropKeys = Array<keyof typeof tableProps>;
|
|
|
321
403
|
* 表格组件属性名
|
|
322
404
|
*/
|
|
323
405
|
export declare const tablePropKeys: TablePropKeys;
|
|
406
|
+
export {};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
3
|
+
const elTableProps = require("element-plus/es/components/table/src/table/defaults");
|
|
4
|
+
const core = require("../utils/core");
|
|
5
|
+
const tableProps = core.omit(elTableProps, ["style"]);
|
|
4
6
|
const tableViewProps = {
|
|
5
7
|
...tableProps,
|
|
6
8
|
// 列配置
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
& > .el-table__inner-wrapper > .el-table__header-wrapper {
|
|
120
120
|
position: sticky;
|
|
121
121
|
top: eleVar('table', 'sticky-top');
|
|
122
|
-
z-index:
|
|
122
|
+
z-index: 3;
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
125
|
|
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
|
|
134
134
|
/* 全屏 */
|
|
135
135
|
.ele-pro-table.is-maximized {
|
|
136
|
-
position: fixed;
|
|
136
|
+
position: fixed !important;
|
|
137
137
|
top: 0;
|
|
138
138
|
left: 0;
|
|
139
139
|
width: 100vw;
|
|
@@ -27,7 +27,10 @@ const _export_sfc = (sfc, props2) => {
|
|
|
27
27
|
}
|
|
28
28
|
return target;
|
|
29
29
|
};
|
|
30
|
-
const _hoisted_1 = {
|
|
30
|
+
const _hoisted_1 = {
|
|
31
|
+
key: 1,
|
|
32
|
+
class: "ele-segmented-item-label"
|
|
33
|
+
};
|
|
31
34
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
32
35
|
const _component_ElIcon = vue.resolveComponent("ElIcon");
|
|
33
36
|
const _component_ElTabPane = vue.resolveComponent("ElTabPane");
|
|
@@ -62,7 +65,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
62
65
|
]),
|
|
63
66
|
_: 2
|
|
64
67
|
}, 1040)) : vue.createCommentVNode("", true),
|
|
65
|
-
vue.
|
|
68
|
+
item.label ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1, vue.toDisplayString(item.label), 1)) : vue.createCommentVNode("", true)
|
|
66
69
|
])
|
|
67
70
|
]),
|
|
68
71
|
_: 2
|
|
@@ -8,7 +8,6 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
8
8
|
titleStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
9
9
|
bodyStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
10
10
|
toolsStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
11
|
-
form: BooleanConstructor;
|
|
12
11
|
}, unknown, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
12
|
title: StringConstructor;
|
|
14
13
|
subtitle: StringConstructor;
|
|
@@ -19,9 +18,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
19
18
|
titleStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
20
19
|
bodyStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
21
20
|
toolsStyle: import("vue").PropType<import("vue").CSSProperties>;
|
|
22
|
-
form: BooleanConstructor;
|
|
23
21
|
}>>, {
|
|
24
22
|
theme: import("./types").ToolbarTheme;
|
|
25
|
-
form: boolean;
|
|
26
23
|
}, {}>;
|
|
27
24
|
export default _sfc_main;
|
package/lib/ele-toolbar/props.js
CHANGED
|
@@ -9,8 +9,13 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
9
9
|
font: import("vue").PropType<import("./types").WatermarkFont>;
|
|
10
10
|
gap: import("vue").PropType<import("./types").WatermarkGap>;
|
|
11
11
|
offset: import("vue").PropType<import("./types").WatermarkOffset>;
|
|
12
|
+
customStyle: import("vue").PropType<CSSProperties>;
|
|
12
13
|
}, {
|
|
13
|
-
|
|
14
|
+
rootKey: import("vue").Ref<number>;
|
|
15
|
+
rootRef: import("vue").Ref<HTMLDivElement | null>;
|
|
16
|
+
imgKey: import("vue").Ref<number>;
|
|
17
|
+
imgRef: import("vue").Ref<HTMLDivElement | null>;
|
|
18
|
+
imgStyle: import("vue").Ref<CSSProperties | undefined>;
|
|
14
19
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
20
|
width: NumberConstructor;
|
|
16
21
|
height: NumberConstructor;
|
|
@@ -21,5 +26,6 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
21
26
|
font: import("vue").PropType<import("./types").WatermarkFont>;
|
|
22
27
|
gap: import("vue").PropType<import("./types").WatermarkGap>;
|
|
23
28
|
offset: import("vue").PropType<import("./types").WatermarkOffset>;
|
|
29
|
+
customStyle: import("vue").PropType<CSSProperties>;
|
|
24
30
|
}>>, {}, {}>;
|
|
25
31
|
export default _sfc_main;
|
|
@@ -10,29 +10,61 @@ const _sfc_main = vue.defineComponent({
|
|
|
10
10
|
props: props.watermarkProps,
|
|
11
11
|
setup(props2) {
|
|
12
12
|
const { authenticated } = receiver.useLicense();
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
const { observe, disconnect } = util.useMutation({
|
|
14
|
+
getRoot: () => rootRef.value,
|
|
15
|
+
getEl: () => imgRef.value,
|
|
16
|
+
onDeleted: () => {
|
|
17
|
+
disconnect();
|
|
18
|
+
rootKey.value = rootKey.value + 1;
|
|
19
|
+
vue.nextTick(() => {
|
|
20
|
+
observe();
|
|
21
|
+
});
|
|
22
|
+
},
|
|
23
|
+
onDalsified: () => {
|
|
24
|
+
disconnect();
|
|
25
|
+
imgKey.value = imgKey.value + 1;
|
|
26
|
+
vue.nextTick(() => {
|
|
27
|
+
observe();
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
const rootKey = vue.ref(1);
|
|
32
|
+
const rootRef = vue.ref(null);
|
|
33
|
+
const imgKey = vue.ref(1);
|
|
34
|
+
const imgRef = vue.ref(null);
|
|
35
|
+
const imgStyle = vue.ref();
|
|
36
|
+
const updateStyle = (base64, size) => {
|
|
16
37
|
const style = {
|
|
17
|
-
position: "absolute",
|
|
18
|
-
top: 0,
|
|
19
|
-
left: 0,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
38
|
+
position: "absolute !important",
|
|
39
|
+
top: "0 !important",
|
|
40
|
+
left: "0 !important",
|
|
41
|
+
right: "auto !important",
|
|
42
|
+
bottom: "auto !important",
|
|
43
|
+
width: "100% !important",
|
|
44
|
+
height: "100% !important",
|
|
45
|
+
pointerEvents: "none !important",
|
|
46
|
+
backgroundRepeat: "repeat !important",
|
|
47
|
+
opacity: "1 !important",
|
|
48
|
+
transform: "none !important",
|
|
49
|
+
filter: "none !important",
|
|
50
|
+
display: "block !important",
|
|
51
|
+
...props2.customStyle
|
|
24
52
|
};
|
|
25
|
-
if (!authenticated || !base64
|
|
26
|
-
style.display = "none";
|
|
53
|
+
if (!authenticated || !base64) {
|
|
54
|
+
style.display = "none !important";
|
|
27
55
|
} else {
|
|
28
|
-
style.backgroundImage = `url('${base64
|
|
29
|
-
if (
|
|
30
|
-
style.backgroundSize =
|
|
56
|
+
style.backgroundImage = `url('${base64}') !important`;
|
|
57
|
+
if (size) {
|
|
58
|
+
style.backgroundSize = `${size} !important`;
|
|
31
59
|
}
|
|
32
|
-
style.zIndex = props2.zIndex ??
|
|
60
|
+
style.zIndex = `${props2.zIndex ?? 2147483647} !important`;
|
|
33
61
|
}
|
|
34
|
-
|
|
35
|
-
|
|
62
|
+
disconnect();
|
|
63
|
+
imgStyle.value = style;
|
|
64
|
+
vue.nextTick(() => {
|
|
65
|
+
observe();
|
|
66
|
+
});
|
|
67
|
+
};
|
|
36
68
|
const getDefaultWidth = (ctx) => {
|
|
37
69
|
if (props2.image || !ctx.measureText) {
|
|
38
70
|
return 120;
|
|
@@ -120,8 +152,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
120
152
|
drawWidth,
|
|
121
153
|
drawHeight
|
|
122
154
|
);
|
|
123
|
-
|
|
124
|
-
imgSize.value = `${(gapX + markWidth) * SIZE}px`;
|
|
155
|
+
updateStyle(canvas.toDataURL(), `${(gapX + markWidth) * SIZE}px`);
|
|
125
156
|
};
|
|
126
157
|
img.crossOrigin = "anonymous";
|
|
127
158
|
img.referrerPolicy = "no-referrer";
|
|
@@ -131,13 +162,15 @@ const _sfc_main = vue.defineComponent({
|
|
|
131
162
|
ctx.restore();
|
|
132
163
|
util.rotateWatermark(ctx, alternateRotateX, alternateRotateY, rotate);
|
|
133
164
|
fillTexts(ctx, alternateDrawX, alternateDrawY, drawWidth, drawHeight);
|
|
134
|
-
|
|
135
|
-
imgSize.value = `${(gapX + markWidth) * SIZE}px`;
|
|
165
|
+
updateStyle(canvas.toDataURL(), `${(gapX + markWidth) * SIZE}px`);
|
|
136
166
|
}
|
|
137
167
|
};
|
|
138
168
|
vue.onMounted(() => {
|
|
139
169
|
render();
|
|
140
170
|
});
|
|
171
|
+
vue.onBeforeMount(() => {
|
|
172
|
+
disconnect();
|
|
173
|
+
});
|
|
141
174
|
vue.watch(
|
|
142
175
|
() => props2,
|
|
143
176
|
() => {
|
|
@@ -145,7 +178,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
145
178
|
},
|
|
146
179
|
{ deep: true }
|
|
147
180
|
);
|
|
148
|
-
return { imgStyle };
|
|
181
|
+
return { rootKey, rootRef, imgKey, imgRef, imgStyle };
|
|
149
182
|
}
|
|
150
183
|
});
|
|
151
184
|
const _export_sfc = (sfc, props2) => {
|
|
@@ -155,13 +188,18 @@ const _export_sfc = (sfc, props2) => {
|
|
|
155
188
|
}
|
|
156
189
|
return target;
|
|
157
190
|
};
|
|
158
|
-
const _hoisted_1 = { style: { position: "relative" } };
|
|
159
191
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
160
|
-
return vue.openBlock(), vue.createElementBlock("div",
|
|
192
|
+
return vue.openBlock(), vue.createElementBlock("div", {
|
|
193
|
+
ref: "rootRef",
|
|
194
|
+
key: _ctx.rootKey,
|
|
195
|
+
style: { position: "relative" }
|
|
196
|
+
}, [
|
|
161
197
|
vue.renderSlot(_ctx.$slots, "default"),
|
|
162
|
-
vue.
|
|
198
|
+
(vue.openBlock(), vue.createElementBlock("div", {
|
|
199
|
+
ref: "imgRef",
|
|
200
|
+
key: _ctx.imgKey,
|
|
163
201
|
style: vue.normalizeStyle(_ctx.imgStyle)
|
|
164
|
-
}, null, 4)
|
|
202
|
+
}, null, 4))
|
|
165
203
|
]);
|
|
166
204
|
}
|
|
167
205
|
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { PropType, ExtractPropTypes } from 'vue';
|
|
1
|
+
import type { PropType, ExtractPropTypes, CSSProperties } from 'vue';
|
|
2
2
|
import type { WatermarkGap, WatermarkOffset, WatermarkFont } from './types';
|
|
3
3
|
export declare const watermarkProps: {
|
|
4
4
|
width: NumberConstructor;
|
|
@@ -10,5 +10,6 @@ export declare const watermarkProps: {
|
|
|
10
10
|
font: PropType<WatermarkFont>;
|
|
11
11
|
gap: PropType<WatermarkGap>;
|
|
12
12
|
offset: PropType<WatermarkOffset>;
|
|
13
|
+
customStyle: PropType<CSSProperties>;
|
|
13
14
|
};
|
|
14
15
|
export type WatermarkProps = ExtractPropTypes<typeof watermarkProps>;
|
|
@@ -21,3 +21,16 @@ export interface WatermarkFont {
|
|
|
21
21
|
/** 字体类型 */
|
|
22
22
|
fontStyle?: 'none' | 'normal' | 'italic' | 'oblique';
|
|
23
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* 水印篡改观测参数
|
|
26
|
+
*/
|
|
27
|
+
export interface MutationOption {
|
|
28
|
+
/** 获取根节点 */
|
|
29
|
+
getRoot: () => HTMLElement | null;
|
|
30
|
+
/** 获取水印节点 */
|
|
31
|
+
getEl: () => HTMLElement | null;
|
|
32
|
+
/** 水印被删除回调 */
|
|
33
|
+
onDeleted: () => void;
|
|
34
|
+
/** 水印样式被篡改回调 */
|
|
35
|
+
onDalsified: () => void;
|
|
36
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { WatermarkGap, WatermarkFont } from './types';
|
|
1
|
+
import type { WatermarkGap, WatermarkFont, MutationOption } from './types';
|
|
2
2
|
/**
|
|
3
3
|
* 获取文字样式
|
|
4
4
|
*/
|
|
@@ -15,3 +15,10 @@ export declare function getPixelRatio(): number;
|
|
|
15
15
|
* 旋转水印
|
|
16
16
|
*/
|
|
17
17
|
export declare function rotateWatermark(ctx: CanvasRenderingContext2D, rotateX: number, rotateY: number, rotate: number): void;
|
|
18
|
+
/**
|
|
19
|
+
* 水印篡改观测
|
|
20
|
+
*/
|
|
21
|
+
export declare function useMutation(option: MutationOption): {
|
|
22
|
+
observe: () => void;
|
|
23
|
+
disconnect: () => void;
|
|
24
|
+
};
|