bitz-react-admin-ui 2.1.3 → 2.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/iconfont/IconColumnCancelFixed.d.ts +7 -0
- package/dist/assets/iconfont/IconColumnCancelFixed.mjs +35 -0
- package/dist/assets/iconfont/IconColumnFixedLeft.d.ts +7 -0
- package/dist/assets/iconfont/IconColumnFixedLeft.mjs +35 -0
- package/dist/assets/iconfont/IconColumnFixedRight.d.ts +7 -0
- package/dist/assets/iconfont/IconColumnFixedRight.mjs +35 -0
- package/dist/assets/iconfont/IconDragOrder.d.ts +7 -0
- package/dist/assets/iconfont/IconDragOrder.mjs +35 -0
- package/dist/assets/iconfont/index.d.ts +5 -1
- package/dist/assets/iconfont/index.mjs +105 -89
- package/dist/components/BitzFluentInput/index.d.ts +2 -5
- package/dist/components/BitzFluentInput/index.mjs +4 -58
- package/dist/components/BitzFluentSelect/index.d.ts +4 -5
- package/dist/components/BitzFluentSelect/index.mjs +4 -58
- package/dist/components/BitzFluentTreeSelect/index.mjs +6 -0
- package/dist/components/BitzTable/Dropdown/index.mjs +16 -15
- package/dist/components/BitzTable/Select/index.d.ts +4 -0
- package/dist/components/BitzTable/Select/index.mjs +11 -0
- package/dist/components/BitzTable/Select/style.d.ts +4 -0
- package/dist/components/BitzTable/Select/style.mjs +66 -0
- package/dist/components/BitzTable/Store/index.d.ts +52 -9
- package/dist/components/BitzTable/Store/index.mjs +276 -156
- package/dist/components/BitzTable/Store/utils/index.mjs +26 -25
- package/dist/components/BitzTable/Table/index.mjs +226 -229
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.mjs +82 -67
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndItem.mjs +118 -61
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.d.ts +4 -3
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.mjs +48 -47
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/index.d.ts +5 -1
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/index.mjs +84 -15
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/index.mjs +59 -50
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/style.d.ts +1 -1
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/style.mjs +47 -21
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.d.ts +11 -0
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.mjs +97 -0
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.d.ts +1 -6
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.mjs +63 -32
- package/dist/components/BitzTable/ToolBar/index.d.ts +9 -3
- package/dist/components/BitzTableSelect/SelectPopup/index.mjs +148 -123
- package/dist/components/BitzTableSelect/TextBlock/index.mjs +21 -18
- package/dist/index.d.ts +1 -0
- package/dist/index.mjs +94 -92
- package/dist/style.css +1 -1
- package/dist/utils/WithFluent.d.ts +9 -0
- package/dist/utils/WithFluent.mjs +58 -0
- package/package.json +2 -1
- package/dist/node_modules/.store/@ant-design_icons-svg@4.4.2/node_modules/@ant-design/icons-svg/es/asn/PicRightOutlined.mjs +0 -5
- package/dist/node_modules/.store/@ant-design_icons@5.3.6/node_modules/@ant-design/icons/es/icons/PicRightOutlined.mjs +0 -15
|
@@ -2,7 +2,7 @@ import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/
|
|
|
2
2
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useCacheToken.mjs";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/StyleContext.mjs";
|
|
5
|
-
import { unit as
|
|
5
|
+
import { unit as e } from "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/util/index.mjs";
|
|
6
6
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useCompatibleInsertionEffect.mjs";
|
|
7
7
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useEffectCleanupRegister.mjs";
|
|
8
8
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useHMR.mjs";
|
|
@@ -12,15 +12,15 @@ import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/
|
|
|
12
12
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/transformers/legacyLogicalProperties.mjs";
|
|
13
13
|
import { css as r } from "../../../../node_modules/.store/@emotion_css@11.11.2/node_modules/@emotion/css/dist/emotion-css.esm.mjs";
|
|
14
14
|
const n = (o) => {
|
|
15
|
-
var
|
|
15
|
+
var a, t, i;
|
|
16
16
|
return r`
|
|
17
17
|
.ant-modal-content {
|
|
18
|
-
background-color: ${(
|
|
18
|
+
background-color: ${(a = o.Modal) == null ? void 0 : a.contentBg};
|
|
19
19
|
|
|
20
20
|
.ant-modal-header {
|
|
21
21
|
font-size: 16px;
|
|
22
22
|
font-weight: 700;
|
|
23
|
-
background-color: ${(
|
|
23
|
+
background-color: ${(t = o.Modal) == null ? void 0 : t.headerBg};
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
.ant-modal-body {
|
|
@@ -31,7 +31,7 @@ const n = (o) => {
|
|
|
31
31
|
text-align: left;
|
|
32
32
|
margin: 0;
|
|
33
33
|
padding: 20px;
|
|
34
|
-
background-color: ${(
|
|
34
|
+
background-color: ${(i = o.Modal) == null ? void 0 : i.footerBg};
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
37
|
`;
|
|
@@ -47,7 +47,7 @@ const n = (o) => {
|
|
|
47
47
|
width: 100%;
|
|
48
48
|
height: 100%;
|
|
49
49
|
background-color: var(--sortCard-bgColor);
|
|
50
|
-
border-radius: ${
|
|
50
|
+
border-radius: ${e(o.borderRadius)};
|
|
51
51
|
padding: 6px;
|
|
52
52
|
padding-block-end: 10px;
|
|
53
53
|
box-sizing: border-box;
|
|
@@ -71,27 +71,28 @@ const n = (o) => {
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
.sortItem {
|
|
74
|
-
border-radius: ${
|
|
74
|
+
border-radius: ${e(o.borderRadius)};
|
|
75
75
|
|
|
76
76
|
&:hover {
|
|
77
77
|
background-color: ${o.colorBgContainer};
|
|
78
78
|
}
|
|
79
|
-
|
|
79
|
+
|
|
80
80
|
.dragIcon {
|
|
81
81
|
height: 100%;
|
|
82
82
|
padding-inline: 8px;
|
|
83
|
-
|
|
84
|
-
&,
|
|
83
|
+
|
|
84
|
+
&,
|
|
85
|
+
& span {
|
|
85
86
|
cursor: inherit;
|
|
86
87
|
}
|
|
87
88
|
}
|
|
88
|
-
|
|
89
|
+
|
|
89
90
|
.ant-checkbox-wrapper {
|
|
90
91
|
/* width: calc(100% - 66px); */
|
|
91
92
|
flex: 1;
|
|
92
93
|
padding-block: 6px;
|
|
93
94
|
padding-inline-end: 8px;
|
|
94
|
-
|
|
95
|
+
|
|
95
96
|
& > span:last-child {
|
|
96
97
|
flex: 1;
|
|
97
98
|
padding-right: 0;
|
|
@@ -136,11 +137,13 @@ const n = (o) => {
|
|
|
136
137
|
}
|
|
137
138
|
`, l = (o) => r`
|
|
138
139
|
.stylesConfigFormContent {
|
|
139
|
-
|
|
140
|
+
display: flex;
|
|
141
|
+
flex-direction: column;
|
|
142
|
+
|
|
140
143
|
.ant-form-item {
|
|
141
144
|
width: 100%;
|
|
142
145
|
|
|
143
|
-
|
|
146
|
+
.ant-form-item-label > label {
|
|
144
147
|
height: auto;
|
|
145
148
|
font-weight: 600;
|
|
146
149
|
}
|
|
@@ -164,8 +167,10 @@ const n = (o) => {
|
|
|
164
167
|
grid-template-columns: repeat(5, 2fr);
|
|
165
168
|
}
|
|
166
169
|
|
|
167
|
-
.scope
|
|
168
|
-
|
|
170
|
+
.scope {
|
|
171
|
+
flex: 1;
|
|
172
|
+
display: flex;
|
|
173
|
+
align-items: flex-end;
|
|
169
174
|
}
|
|
170
175
|
|
|
171
176
|
.ant-radio-wrapper {
|
|
@@ -175,7 +180,7 @@ const n = (o) => {
|
|
|
175
180
|
font-weight: normal !important;
|
|
176
181
|
background-color: ${o.colorBgLayout};
|
|
177
182
|
background-color: var(--radioCard-bgColor);
|
|
178
|
-
border-radius: ${
|
|
183
|
+
border-radius: ${e(o.borderRadiusLG)};
|
|
179
184
|
margin-inline-end: 0;
|
|
180
185
|
box-sizing: border-box;
|
|
181
186
|
position: relative;
|
|
@@ -215,9 +220,29 @@ const n = (o) => {
|
|
|
215
220
|
}
|
|
216
221
|
}
|
|
217
222
|
}
|
|
218
|
-
`,
|
|
219
|
-
|
|
223
|
+
`, c = (o) => r`
|
|
224
|
+
.exportConfigFormContent {
|
|
225
|
+
display: flex;
|
|
226
|
+
flex-direction: column;
|
|
227
|
+
row-gap: 10px;
|
|
228
|
+
|
|
229
|
+
.ant-form-item {
|
|
230
|
+
width: 100%;
|
|
231
|
+
|
|
232
|
+
.ant-form-item-label > label {
|
|
233
|
+
height: auto;
|
|
234
|
+
font-weight: 600;
|
|
235
|
+
}
|
|
236
|
+
}
|
|
220
237
|
|
|
238
|
+
.exportFields .ant-checkbox-group {
|
|
239
|
+
display: grid;
|
|
240
|
+
grid-template-columns: repeat(3, 1fr);
|
|
241
|
+
gap: 8px;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
`, v = (o) => r`
|
|
245
|
+
&.tableConfigModal {
|
|
221
246
|
${n(o)}
|
|
222
247
|
|
|
223
248
|
.pointerCursor {
|
|
@@ -240,7 +265,6 @@ const n = (o) => {
|
|
|
240
265
|
}
|
|
241
266
|
|
|
242
267
|
.segmentedWrapper {
|
|
243
|
-
|
|
244
268
|
}
|
|
245
269
|
|
|
246
270
|
.containerBody {
|
|
@@ -251,10 +275,12 @@ const n = (o) => {
|
|
|
251
275
|
${d(o)}
|
|
252
276
|
|
|
253
277
|
${l(o)}
|
|
278
|
+
|
|
279
|
+
${c()}
|
|
254
280
|
}
|
|
255
281
|
}
|
|
256
282
|
}
|
|
257
283
|
`;
|
|
258
284
|
export {
|
|
259
|
-
|
|
285
|
+
v as styles
|
|
260
286
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { MenuKeysType } from '..';
|
|
3
|
+
interface AnyDataTotalLabelProps {
|
|
4
|
+
onClick: (key: MenuKeysType, info: {
|
|
5
|
+
value: number;
|
|
6
|
+
type: 'page' | 'pieces';
|
|
7
|
+
}) => void;
|
|
8
|
+
onClose: () => void;
|
|
9
|
+
}
|
|
10
|
+
declare const AnyDataTotalLabel: FC<AnyDataTotalLabelProps>;
|
|
11
|
+
export default AnyDataTotalLabel;
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { j as e } from "../../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { css as s } from "../../../../node_modules/.store/@emotion_css@11.11.2/node_modules/@emotion/css/dist/emotion-css.esm.mjs";
|
|
3
|
+
import { Tooltip as g, Flex as b, Typography as l, InputNumber as S, Select as j } from "antd";
|
|
4
|
+
import { useState as a } from "react";
|
|
5
|
+
import y from "../../Select/index.mjs";
|
|
6
|
+
const { Option: p } = j, E = ({
|
|
7
|
+
onClick: u,
|
|
8
|
+
onClose: c
|
|
9
|
+
}) => {
|
|
10
|
+
const [m, o] = a(!1), [d, i] = a(!1), [r, f] = a("page"), [t, h] = a(1), x = () => {
|
|
11
|
+
if (!d) {
|
|
12
|
+
if (!t && typeof t != "number" || t <= 0) {
|
|
13
|
+
i(!0), o(!0), setTimeout(() => {
|
|
14
|
+
o(!1), i(!1);
|
|
15
|
+
}, 2e3);
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
18
|
+
i(!0), u("any", { value: t, type: r }), c();
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
return /* @__PURE__ */ e.jsx(
|
|
22
|
+
g,
|
|
23
|
+
{
|
|
24
|
+
open: m,
|
|
25
|
+
title: "数字必须大于等于1",
|
|
26
|
+
getTooltipContainer: (n) => n.parentElement.parentElement.parentElement,
|
|
27
|
+
children: /* @__PURE__ */ e.jsxs(b, { align: "center", gap: 8, onClick: (n) => n.stopPropagation(), children: [
|
|
28
|
+
/* @__PURE__ */ e.jsx(l.Text, { style: { fontSize: "var(--fontSize)" }, children: "导出" }),
|
|
29
|
+
/* @__PURE__ */ e.jsx(
|
|
30
|
+
S,
|
|
31
|
+
{
|
|
32
|
+
controls: !1,
|
|
33
|
+
min: 1,
|
|
34
|
+
value: t,
|
|
35
|
+
onChange: (n) => h(n),
|
|
36
|
+
style: { width: 100 },
|
|
37
|
+
size: "small",
|
|
38
|
+
addonAfter: /* @__PURE__ */ e.jsxs(
|
|
39
|
+
y,
|
|
40
|
+
{
|
|
41
|
+
value: r,
|
|
42
|
+
onChange: f,
|
|
43
|
+
className: s`
|
|
44
|
+
width: auto;
|
|
45
|
+
height: calc(var(--fontSize) + 12px);
|
|
46
|
+
|
|
47
|
+
.ant-select-selection-item {
|
|
48
|
+
padding-right: 0 !important;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.ant-select-selector {
|
|
52
|
+
width: auto !important;
|
|
53
|
+
padding-inline: 8px !important;
|
|
54
|
+
}
|
|
55
|
+
`,
|
|
56
|
+
popupMatchSelectWidth: !1,
|
|
57
|
+
suffixIcon: !1,
|
|
58
|
+
children: [
|
|
59
|
+
/* @__PURE__ */ e.jsx(p, { value: "page", children: "页" }),
|
|
60
|
+
/* @__PURE__ */ e.jsx(p, { value: "pieces", children: "条" })
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
),
|
|
64
|
+
className: s`
|
|
65
|
+
.ant-input-number-group-wrapper {
|
|
66
|
+
height: calc(var(--fontSize) + 12px);
|
|
67
|
+
}
|
|
68
|
+
.ant-input-number-wrapper,
|
|
69
|
+
.ant-input-number,
|
|
70
|
+
.ant-input-number-input-wrap,
|
|
71
|
+
.ant-input-number-input {
|
|
72
|
+
height: 100% !important;
|
|
73
|
+
}
|
|
74
|
+
.ant-input-number {
|
|
75
|
+
box-shadow: none;
|
|
76
|
+
}
|
|
77
|
+
.ant-input-number-group-addon {
|
|
78
|
+
width: auto;
|
|
79
|
+
}
|
|
80
|
+
`
|
|
81
|
+
}
|
|
82
|
+
),
|
|
83
|
+
/* @__PURE__ */ e.jsx(
|
|
84
|
+
l.Link,
|
|
85
|
+
{
|
|
86
|
+
style: { userSelect: "none", fontSize: "var(--fontSize)" },
|
|
87
|
+
onClick: x,
|
|
88
|
+
children: "下载"
|
|
89
|
+
}
|
|
90
|
+
)
|
|
91
|
+
] })
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
};
|
|
95
|
+
export {
|
|
96
|
+
E as default
|
|
97
|
+
};
|
|
@@ -1,16 +1,11 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { BitzDropdownToButtonProps } from '@/components/BitzConvert';
|
|
3
2
|
import { ExportEvent } from '..';
|
|
4
|
-
interface ExportIconProps
|
|
3
|
+
interface ExportIconProps {
|
|
5
4
|
order?: number;
|
|
6
5
|
icon?: ReactNode;
|
|
7
6
|
loading?: boolean;
|
|
8
7
|
/** 是否显示导出icon */
|
|
9
8
|
show?: boolean;
|
|
10
|
-
/**
|
|
11
|
-
* 导出按钮下拉菜单的点击事件,通过key值判断是导出为excel或其他格式的文件
|
|
12
|
-
* @Key1 导出查询结果为excel: excel
|
|
13
|
-
*/
|
|
14
9
|
onClick?: ExportEvent;
|
|
15
10
|
}
|
|
16
11
|
declare const _default: import("react").NamedExoticComponent<ExportIconProps>;
|
|
@@ -1,45 +1,76 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { memo as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import { j as o } from "../../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { memo as d, useState as u } from "react";
|
|
3
|
+
import f from "../style.mjs";
|
|
4
|
+
import x from "../../../BitzButton/index.mjs";
|
|
5
|
+
import y from "../../Dropdown/index.mjs";
|
|
6
|
+
import c from "./AnyDataTotalLabel.mjs";
|
|
7
|
+
import { css as b } from "../../../../node_modules/.store/@emotion_css@11.11.2/node_modules/@emotion/css/dist/emotion-css.esm.mjs";
|
|
8
|
+
import g from "../../../../node_modules/.store/@ant-design_icons@5.3.6/node_modules/@ant-design/icons/es/icons/DownloadOutlined.mjs";
|
|
9
|
+
const j = ({
|
|
10
|
+
show: a = !0,
|
|
11
|
+
order: n,
|
|
10
12
|
loading: m,
|
|
11
|
-
onClick:
|
|
12
|
-
icon:
|
|
13
|
-
menu: o,
|
|
14
|
-
tipText: i
|
|
13
|
+
onClick: e,
|
|
14
|
+
icon: l = /* @__PURE__ */ o.jsx(g, {})
|
|
15
15
|
}) => {
|
|
16
|
-
const { toolbarItemClassName:
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
],
|
|
20
|
-
onClick: ({ key: a }) => t == null ? void 0 : t(a)
|
|
21
|
-
}, [o, t]);
|
|
22
|
-
return r ? /* @__PURE__ */ e.jsx(
|
|
23
|
-
d.DropdownToButton,
|
|
16
|
+
const { toolbarItemClassName: s } = f(), [p, r] = u(!1);
|
|
17
|
+
return a ? /* @__PURE__ */ o.jsx(
|
|
18
|
+
y,
|
|
24
19
|
{
|
|
25
|
-
|
|
20
|
+
open: p,
|
|
21
|
+
onOpenChange: r,
|
|
22
|
+
menu: {
|
|
23
|
+
items: [
|
|
24
|
+
{ key: "current", label: "仅导出当前页" },
|
|
25
|
+
{ key: "all", label: "导出全部数据" },
|
|
26
|
+
{ type: "divider" },
|
|
27
|
+
{
|
|
28
|
+
key: "any",
|
|
29
|
+
label: /* @__PURE__ */ o.jsx(
|
|
30
|
+
c,
|
|
31
|
+
{
|
|
32
|
+
onClick: (t, i) => e == null ? void 0 : e(t, i),
|
|
33
|
+
onClose: () => r(!1)
|
|
34
|
+
}
|
|
35
|
+
),
|
|
36
|
+
className: "anyTotal"
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
onClick: ({ key: t }) => e == null ? void 0 : e(t)
|
|
40
|
+
},
|
|
41
|
+
overlayClassName: b`
|
|
42
|
+
.ant-dropdown-menu.ant-dropdown-menu-root {
|
|
43
|
+
display: flex;
|
|
44
|
+
flex-direction: column;
|
|
45
|
+
|
|
46
|
+
.anyTotal {
|
|
47
|
+
cursor: default !important;
|
|
48
|
+
margin: 5px 12px;
|
|
49
|
+
padding: 0;
|
|
50
|
+
|
|
51
|
+
&:hover {
|
|
52
|
+
background-color: inherit !important;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
`,
|
|
26
57
|
trigger: ["click"],
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
58
|
+
disabled: m,
|
|
59
|
+
destroyPopupOnHide: !0,
|
|
60
|
+
getPopupContainer: (t) => t.parentElement.parentElement.parentElement,
|
|
61
|
+
children: /* @__PURE__ */ o.jsx(
|
|
62
|
+
x,
|
|
31
63
|
{
|
|
32
64
|
type: "text",
|
|
33
|
-
className:
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
style: { order: s },
|
|
65
|
+
className: s,
|
|
66
|
+
icon: l,
|
|
67
|
+
style: { order: n },
|
|
37
68
|
children: "下载"
|
|
38
69
|
}
|
|
39
70
|
)
|
|
40
71
|
}
|
|
41
72
|
) : null;
|
|
42
|
-
},
|
|
73
|
+
}, T = d(j);
|
|
43
74
|
export {
|
|
44
|
-
|
|
75
|
+
T as default
|
|
45
76
|
};
|
|
@@ -2,8 +2,11 @@ import { DensitySize } from '../Store';
|
|
|
2
2
|
import { MouseEventHandler } from 'react';
|
|
3
3
|
import { ToolEnum } from '../../../components/BitzConfigProvider/context';
|
|
4
4
|
import { ColumnsConfigProps } from '..';
|
|
5
|
-
export type MenuKeysType = '
|
|
6
|
-
export type ExportEvent = (key: MenuKeysType
|
|
5
|
+
export type MenuKeysType = 'current' | 'all' | 'any';
|
|
6
|
+
export type ExportEvent = (key: MenuKeysType, info?: {
|
|
7
|
+
value: number;
|
|
8
|
+
type: 'page' | 'pieces';
|
|
9
|
+
}) => void;
|
|
7
10
|
export type ToolsConfigType = {
|
|
8
11
|
/** 表格设置按钮 */
|
|
9
12
|
config?: ConfigType;
|
|
@@ -38,7 +41,10 @@ export interface BitzTableToolBarProps {
|
|
|
38
41
|
loading?: boolean;
|
|
39
42
|
/**
|
|
40
43
|
* 导出按钮下拉菜单的点击事件,通过key值判断是导出为excel或其他格式的文件
|
|
41
|
-
* @Key1
|
|
44
|
+
* @Key1 仅导出当前页数据: current
|
|
45
|
+
* @Key2 导出所有数据: all
|
|
46
|
+
* @Key3 导出 xx页/条 数据: any
|
|
47
|
+
* @note key为any时,会返回第二个参数,info: {value: number, type: 'page' | 'pieces'}
|
|
42
48
|
*/
|
|
43
49
|
onExport?: ExportEvent;
|
|
44
50
|
/** 表格刷新 */
|