bitz-react-admin-ui 1.7.7 → 1.7.9
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/components/BitzConfigProvider/context.d.ts +1 -0
- package/dist/components/BitzConfigProvider/index.d.ts +10 -0
- package/dist/components/BitzConfirmModal/index.d.ts +5 -0
- package/dist/components/BitzConvert/DropdownToButton/index.d.ts +6 -6
- package/dist/components/BitzTable/Store/index.d.ts +25 -13
- package/dist/components/BitzTable/Store/index.mjs +168 -117
- package/dist/components/BitzTable/Table/index.d.ts +6 -1
- package/dist/components/BitzTable/Table/index.mjs +190 -185
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnSettingModal.d.ts +5 -3
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnSettingModal.mjs +93 -89
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.d.ts +2 -1
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.mjs +21 -17
- package/dist/components/BitzTable/ToolBar/DensityIcon/index.mjs +27 -21
- package/dist/components/BitzTable/ToolBar/index.d.ts +2 -1
- package/dist/components/BitzTable/index.d.ts +2 -2
- package/dist/style.css +1 -1
- package/package.json +5 -1
|
@@ -1,187 +1,193 @@
|
|
|
1
1
|
import { j as t } from "../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
-
import { useContext as
|
|
3
|
-
import { isMobile as
|
|
4
|
-
import { Table as
|
|
5
|
-
import
|
|
2
|
+
import { useContext as We, useState as P, useMemo as g, useEffect as le, useRef as A, useCallback as te } from "react";
|
|
3
|
+
import { isMobile as F } from "../../../node_modules/.store/react-device-detect@2.2.3/node_modules/react-device-detect/dist/lib.mjs";
|
|
4
|
+
import { Table as R, Skeleton as He } from "antd";
|
|
5
|
+
import ne from "../../../node_modules/.store/classnames@2.5.1/node_modules/classnames/index.mjs";
|
|
6
6
|
import Ee from "../../BitzDrawer/index.mjs";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
7
|
+
import $e from "../../BitzPagination/index.mjs";
|
|
8
|
+
import Pe from "../../BitzNoData/index.mjs";
|
|
9
9
|
import "../../BitzList/index.less.mjs";
|
|
10
|
-
import
|
|
10
|
+
import Ae from "../../BitzList/List.mjs";
|
|
11
11
|
import "../../BitzPullRefresh/style/index.less.mjs";
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import { columnSort as re, genColumnKey as
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
12
|
+
import Fe from "../../BitzPullRefresh/PullRefresh.mjs";
|
|
13
|
+
import Re, { TableContext as Oe } from "../Store/index.mjs";
|
|
14
|
+
import Ve from "../TableSkeleton/index.mjs";
|
|
15
|
+
import { columnSort as re, genColumnKey as se } from "../Store/utils/index.mjs";
|
|
16
|
+
import O from "../../../node_modules/.store/ahooks@3.7.10/node_modules/ahooks/es/useSize/index.mjs";
|
|
17
|
+
import Ke from "../ActionCol/style.mjs";
|
|
18
|
+
import _e from "../../BitzTheme/index.mjs";
|
|
19
19
|
import "./index.less.mjs";
|
|
20
|
-
import
|
|
21
|
-
function
|
|
22
|
-
showPagination:
|
|
20
|
+
import De from "../../../node_modules/.store/lodash-es@4.17.21/node_modules/lodash-es/at.mjs";
|
|
21
|
+
function qe({
|
|
22
|
+
showPagination: z = !0,
|
|
23
23
|
fillEvenRow: V = !0,
|
|
24
24
|
evenRowBgColor: Ge = "#f9f9f9",
|
|
25
|
-
height:
|
|
26
|
-
dataSource:
|
|
27
|
-
total:
|
|
28
|
-
columns:
|
|
29
|
-
loading:
|
|
30
|
-
skeletonNum:
|
|
25
|
+
height: B,
|
|
26
|
+
dataSource: c = [],
|
|
27
|
+
total: L = 0,
|
|
28
|
+
columns: C,
|
|
29
|
+
loading: v = !1,
|
|
30
|
+
skeletonNum: ae = 2,
|
|
31
31
|
skeletonRender: K,
|
|
32
|
-
skeletonRowNum:
|
|
33
|
-
skeletonRowsWidth:
|
|
34
|
-
mobileLoadEmit:
|
|
32
|
+
skeletonRowNum: ie = 4,
|
|
33
|
+
skeletonRowsWidth: ce = ["35%", "100%", "100%", "60%"],
|
|
34
|
+
mobileLoadEmit: de,
|
|
35
35
|
mobileRefreshEmit: _,
|
|
36
|
-
operationFilter:
|
|
37
|
-
enableControlPage:
|
|
38
|
-
pagination:
|
|
36
|
+
operationFilter: M,
|
|
37
|
+
enableControlPage: he,
|
|
38
|
+
pagination: be,
|
|
39
39
|
paginationEmit: fe = () => {
|
|
40
40
|
},
|
|
41
41
|
mobilePageHeight: Ue = 500,
|
|
42
|
-
mobileCancelText:
|
|
42
|
+
mobileCancelText: xe = "取消",
|
|
43
43
|
noDataTitle: ue,
|
|
44
44
|
noDataImg: ge,
|
|
45
45
|
color: Xe,
|
|
46
|
-
size:
|
|
47
|
-
showTableTool:
|
|
48
|
-
tableAction:
|
|
46
|
+
size: D,
|
|
47
|
+
showTableTool: q = !0,
|
|
48
|
+
tableAction: me,
|
|
49
49
|
tableToolbar: Ce,
|
|
50
|
-
selectionBar:
|
|
50
|
+
selectionBar: pe,
|
|
51
51
|
scroll: d,
|
|
52
52
|
resetPage: ye,
|
|
53
53
|
...h
|
|
54
54
|
}) {
|
|
55
|
-
var
|
|
56
|
-
const { token:
|
|
57
|
-
var
|
|
58
|
-
const
|
|
59
|
-
(
|
|
55
|
+
var oe;
|
|
56
|
+
const { token: r } = _e.useToken(), { gap: Te } = Ke(), b = We(Oe), [p, G] = P(!1), [Be, W] = P(!1), we = g(() => !!(c != null && c.length) && (c == null ? void 0 : c.length) >= L, [c, L]), [je, ze] = P([]), ve = (o, e) => {
|
|
57
|
+
var l;
|
|
58
|
+
const n = (l = M == null ? void 0 : M(o, e)) == null ? void 0 : l.filter(
|
|
59
|
+
(s) => s.type !== "divider"
|
|
60
60
|
);
|
|
61
|
-
|
|
62
|
-
},
|
|
63
|
-
|
|
61
|
+
n != null && n.length && (ze(n), W(!0));
|
|
62
|
+
}, U = () => {
|
|
63
|
+
W(!1);
|
|
64
64
|
}, Ne = (o) => {
|
|
65
65
|
var e;
|
|
66
|
-
|
|
66
|
+
W(!1), (e = o.onClick) == null || e.call(o);
|
|
67
67
|
};
|
|
68
|
-
|
|
69
|
-
var e,
|
|
70
|
-
(e = o.target) != null && e.classList.contains("bitzTableBlock") && (
|
|
68
|
+
le(() => (document == null || document.addEventListener("fullscreenchange", (o) => {
|
|
69
|
+
var e, n, l;
|
|
70
|
+
(e = o.target) != null && e.classList.contains("bitzTableBlock") && (G(!!document.fullscreenElement), (l = (n = document.fullscreenElement) == null ? void 0 : n.classList) != null && l.contains("bitzTableBlock") || G(!1));
|
|
71
71
|
}), document == null ? void 0 : document.removeEventListener("fullscreenchange", () => {
|
|
72
72
|
})), []);
|
|
73
|
-
const
|
|
74
|
-
var
|
|
75
|
-
const o = (
|
|
73
|
+
const y = A(null), H = O(y), N = A(null), E = O(N), X = A(null), T = O(X), ke = () => {
|
|
74
|
+
var n;
|
|
75
|
+
const o = (n = N.current) == null ? void 0 : n.querySelectorAll(
|
|
76
76
|
".ant-table-body tr:not(.ant-table-measure-row)"
|
|
77
77
|
), e = [];
|
|
78
|
-
if (o == null || o.forEach((
|
|
79
|
-
var
|
|
78
|
+
if (o == null || o.forEach((l) => {
|
|
79
|
+
var s;
|
|
80
80
|
e.push(
|
|
81
|
-
((
|
|
81
|
+
((s = l.querySelector(".operationCol .actionGroup")) == null ? void 0 : s.clientWidth) || 0
|
|
82
82
|
);
|
|
83
83
|
}), e.length)
|
|
84
|
-
return Math.ceil(Math.max(...e)) +
|
|
85
|
-
},
|
|
86
|
-
var
|
|
87
|
-
const o = (
|
|
84
|
+
return Math.ceil(Math.max(...e)) + Te * 2;
|
|
85
|
+
}, I = () => {
|
|
86
|
+
var s;
|
|
87
|
+
const o = (s = N.current) == null ? void 0 : s.querySelector(
|
|
88
88
|
".ant-table-body"
|
|
89
|
-
), e = o == null ? void 0 : o.clientWidth,
|
|
90
|
-
return { tbodyWidth: e, scrollBarWidth:
|
|
91
|
-
}, { y:
|
|
92
|
-
if (typeof
|
|
89
|
+
), e = o == null ? void 0 : o.clientWidth, n = ((o == null ? void 0 : o.offsetWidth) || 0) - e, l = n > 0;
|
|
90
|
+
return { tbodyWidth: e, scrollBarWidth: n, hasScrollBar: l };
|
|
91
|
+
}, { y: $, hasScrollBar: J } = g(() => {
|
|
92
|
+
if (typeof B > "u")
|
|
93
93
|
return {};
|
|
94
|
-
const { hasScrollBar: o } =
|
|
95
|
-
let e = 40,
|
|
96
|
-
if (
|
|
97
|
-
const
|
|
98
|
-
e = parseInt(
|
|
94
|
+
const { hasScrollBar: o } = I();
|
|
95
|
+
let e = 40, n = 40, l = 10;
|
|
96
|
+
if (y.current) {
|
|
97
|
+
const u = window.getComputedStyle(y.current);
|
|
98
|
+
e = parseInt(u.getPropertyValue("--cell-block")), n = parseInt(u.getPropertyValue("--toolbar-height")), l = parseInt(u.getPropertyValue("--container-gap")) || 0;
|
|
99
99
|
}
|
|
100
|
-
const
|
|
101
|
-
return { y: (
|
|
100
|
+
const s = (T == null ? void 0 : T.height) || 0, a = s ? l : 0;
|
|
101
|
+
return { y: (p ? window.innerHeight : B) - s - a - n - e, hasScrollBar: o };
|
|
102
102
|
}, [
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
]),
|
|
103
|
+
p,
|
|
104
|
+
B,
|
|
105
|
+
T == null ? void 0 : T.height,
|
|
106
|
+
H == null ? void 0 : H.height,
|
|
107
|
+
E == null ? void 0 : E.height
|
|
108
|
+
]), k = g(() => d != null && d.x ? { x: d.x, y: d.y || $ } : d != null && d.y ? { x: 1e3, y: d.y } : { x: 1e3, y: $ }, [d, $]), Q = te(
|
|
109
109
|
(o) => {
|
|
110
|
-
const e = o.length,
|
|
111
|
-
let s = 0;
|
|
112
|
-
if (C.current) {
|
|
113
|
-
const u = window.getComputedStyle(C.current);
|
|
114
|
-
s = parseInt(u.getPropertyValue("--toolCell-width"));
|
|
115
|
-
}
|
|
110
|
+
const e = o.length, n = o.filter((f) => f.width), s = n.map((f) => f.width).reduce((f, S) => f + S, 0);
|
|
116
111
|
let a = 0;
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
112
|
+
if (y.current) {
|
|
113
|
+
const f = window.getComputedStyle(y.current);
|
|
114
|
+
a = parseInt(f.getPropertyValue("--toolCell-width"));
|
|
115
|
+
}
|
|
116
|
+
let i = 0;
|
|
117
|
+
h.rowSelection && (i += a), h.expandable && (i += a);
|
|
118
|
+
const { tbodyWidth: m } = I(), x = parseInt(`${k.x}`) || 0, u = Math.max(x, m), j = (parseInt(`${u}`) || 0) - s - i;
|
|
119
|
+
return j >= 0 ? j / (e - n.length) : void 0;
|
|
120
120
|
},
|
|
121
|
-
[h.expandable, h.rowSelection,
|
|
122
|
-
),
|
|
123
|
-
const o = (
|
|
124
|
-
const
|
|
125
|
-
(
|
|
126
|
-
|
|
127
|
-
),
|
|
128
|
-
return
|
|
129
|
-
...
|
|
130
|
-
children: o(
|
|
131
|
-
} :
|
|
132
|
-
}).filter(Boolean), e = o(
|
|
133
|
-
if (
|
|
134
|
-
return e.sort(re(
|
|
135
|
-
const
|
|
136
|
-
...
|
|
137
|
-
...
|
|
138
|
-
width:
|
|
121
|
+
[h.expandable, h.rowSelection, k]
|
|
122
|
+
), w = g(() => {
|
|
123
|
+
const o = (a) => a.map((i) => {
|
|
124
|
+
const m = se(
|
|
125
|
+
(i == null ? void 0 : i.key) || (i == null ? void 0 : i.dataIndex),
|
|
126
|
+
i.index
|
|
127
|
+
), x = b.columnsMap[m];
|
|
128
|
+
return x && x.show === !1 ? !1 : i.children ? {
|
|
129
|
+
...i,
|
|
130
|
+
children: o(i.children)
|
|
131
|
+
} : i;
|
|
132
|
+
}).filter(Boolean), e = o(C);
|
|
133
|
+
if (F)
|
|
134
|
+
return e.sort(re(b.columnsMap));
|
|
135
|
+
const n = e.sort(re(b.columnsMap)), l = Q(n), s = n.map((a) => ({
|
|
136
|
+
...a,
|
|
137
|
+
...a.width ? {
|
|
138
|
+
width: a.useMaxWidth ? ke() ?? a.width : a.width
|
|
139
139
|
} : {
|
|
140
140
|
// 给未设置width的列设置平均数
|
|
141
|
-
width:
|
|
141
|
+
width: l
|
|
142
142
|
}
|
|
143
143
|
}));
|
|
144
|
-
return [
|
|
145
|
-
}, [
|
|
146
|
-
|
|
147
|
-
if (
|
|
148
|
-
const o =
|
|
144
|
+
return [R.SELECTION_COLUMN, R.EXPAND_COLUMN, ...s];
|
|
145
|
+
}, [C, b.columnsMap, Q, b.sortKeyColumns]);
|
|
146
|
+
le(() => {
|
|
147
|
+
if (C && C.length > 0) {
|
|
148
|
+
const o = C.map(
|
|
149
149
|
(e) => (
|
|
150
150
|
// @ts-ignore
|
|
151
|
-
|
|
151
|
+
se((e == null ? void 0 : e.key) ?? (e == null ? void 0 : e.dataIndex), e == null ? void 0 : e.dataIndex)
|
|
152
152
|
)
|
|
153
153
|
);
|
|
154
|
-
|
|
154
|
+
b.setSortKeyColumns(o);
|
|
155
155
|
}
|
|
156
|
-
}, [
|
|
157
|
-
const
|
|
156
|
+
}, [C]);
|
|
157
|
+
const Y = g(() => `${D ?? (b == null ? void 0 : b.tableSize) ?? "lg"}BitzTable`, [D, b.tableSize]), Se = g(() => ne(
|
|
158
158
|
"bitzTableContainer",
|
|
159
159
|
/* "hideBorder", */
|
|
160
|
-
{ hasScrollBar:
|
|
161
|
-
|
|
162
|
-
), [
|
|
163
|
-
"--container-bgColor":
|
|
164
|
-
}), [
|
|
165
|
-
var o, e,
|
|
160
|
+
{ hasScrollBar: J },
|
|
161
|
+
Y
|
|
162
|
+
), [Y, J, p]), Le = g(() => ({
|
|
163
|
+
"--container-bgColor": r.colorBgContainer
|
|
164
|
+
}), [r.Table]), Me = g(() => {
|
|
165
|
+
var o, e, n, l, s, a, i, m, x, u, j, f, S;
|
|
166
166
|
return {
|
|
167
|
-
height:
|
|
168
|
-
"--toolbar-bgColor": (o =
|
|
169
|
-
"--thead-bgColor": (e =
|
|
170
|
-
"--thead-hoverBgColor": (
|
|
171
|
-
"--evenRow-BgColor": (
|
|
172
|
-
"--radioCheckbox-borderColor": (
|
|
173
|
-
"--expandIcon-borderColor": (
|
|
174
|
-
"--rowHover-bgColor": (
|
|
167
|
+
height: p ? "100%" : B,
|
|
168
|
+
"--toolbar-bgColor": (o = r.Table) == null ? void 0 : o.toolbarBgColor,
|
|
169
|
+
"--thead-bgColor": (e = r.Table) == null ? void 0 : e.headerBg,
|
|
170
|
+
"--thead-hoverBgColor": (n = r.Table) == null ? void 0 : n.headerSortHoverBg,
|
|
171
|
+
"--evenRow-BgColor": (l = r.Table) == null ? void 0 : l.evenRowBgColor,
|
|
172
|
+
"--radioCheckbox-borderColor": (s = r.Table) == null ? void 0 : s.radioCheckboxBorderColor,
|
|
173
|
+
"--expandIcon-borderColor": (a = r.Table) == null ? void 0 : a.expandIconBorderColor,
|
|
174
|
+
"--rowHover-bgColor": (i = r.Table) == null ? void 0 : i.rowHoverBg,
|
|
175
|
+
"--tbodyRow-borderColor": (m = r.Table) == null ? void 0 : m.borderColor,
|
|
176
|
+
"--xlTable-fontSize": `${(x = r.Table) == null ? void 0 : x.xlFontSize}px`,
|
|
177
|
+
"--lgTable-fontSize": `${(u = r.Table) == null ? void 0 : u.lgFontSize}px`,
|
|
178
|
+
"--mdTable-fontSize": `${(j = r.Table) == null ? void 0 : j.mdFontSize}px`,
|
|
179
|
+
"--smTable-fontSize": `${(f = r.Table) == null ? void 0 : f.smFontSize}px`,
|
|
180
|
+
"--xsTable-fontSize": `${(S = r.Table) == null ? void 0 : S.xsFontSize}px`
|
|
175
181
|
// '--tableBody-bootomBorderColor': token.Table?.borderColor || '#f0f0f0',
|
|
176
182
|
};
|
|
177
|
-
}, [
|
|
183
|
+
}, [p, B, r.Table]), Z = te(
|
|
178
184
|
(o, e) => V ? e % 2 === 0 ? "oddRow" : "evenRow" : "",
|
|
179
185
|
[V]
|
|
180
|
-
),
|
|
181
|
-
|
|
186
|
+
), ee = /* @__PURE__ */ t.jsx(
|
|
187
|
+
Ae,
|
|
182
188
|
{
|
|
183
189
|
finished: we,
|
|
184
|
-
onLoad:
|
|
190
|
+
onLoad: de,
|
|
185
191
|
loadingText: "加载中...",
|
|
186
192
|
finishedText: "没有更多了",
|
|
187
193
|
errorText: "加载失败",
|
|
@@ -189,57 +195,57 @@ function Fe({
|
|
|
189
195
|
"div",
|
|
190
196
|
{
|
|
191
197
|
className: "mobileList",
|
|
192
|
-
style: { backgroundColor: (
|
|
198
|
+
style: { backgroundColor: (oe = r.Table) == null ? void 0 : oe.mobileListBgColor },
|
|
193
199
|
children: [
|
|
194
|
-
|
|
195
|
-
var
|
|
200
|
+
c == null ? void 0 : c.map((o, e) => {
|
|
201
|
+
var n;
|
|
196
202
|
return /* @__PURE__ */ t.jsx(
|
|
197
203
|
"div",
|
|
198
204
|
{
|
|
199
205
|
className: "listItem",
|
|
200
|
-
style: { backgroundColor: (
|
|
206
|
+
style: { backgroundColor: (n = r.Table) == null ? void 0 : n.listItemBgColor },
|
|
201
207
|
onClick: () => ve(o, e),
|
|
202
|
-
children:
|
|
203
|
-
var
|
|
204
|
-
return !(
|
|
208
|
+
children: w == null ? void 0 : w.map((l, s) => {
|
|
209
|
+
var a;
|
|
210
|
+
return !(l != null && l.mobileHide) && /* @__PURE__ */ t.jsxs(
|
|
205
211
|
"div",
|
|
206
212
|
{
|
|
207
213
|
className: "row",
|
|
208
|
-
style: { color:
|
|
214
|
+
style: { color: r.colorText },
|
|
209
215
|
children: [
|
|
210
|
-
!
|
|
211
|
-
`${
|
|
216
|
+
!l.mobileHideLabel && /* @__PURE__ */ t.jsxs("div", { className: "label", children: [
|
|
217
|
+
`${l.title}`,
|
|
212
218
|
":"
|
|
213
219
|
] }),
|
|
214
|
-
/* @__PURE__ */ t.jsx("div", { className: "value", children: ((
|
|
215
|
-
|
|
216
|
-
|
|
220
|
+
/* @__PURE__ */ t.jsx("div", { className: "value", children: ((a = l == null ? void 0 : l.render) == null ? void 0 : a.call(
|
|
221
|
+
l,
|
|
222
|
+
De(o, (l == null ? void 0 : l.dataIndex) || ""),
|
|
217
223
|
o,
|
|
218
224
|
e
|
|
219
|
-
)) || (o == null ? void 0 : o[
|
|
225
|
+
)) || (o == null ? void 0 : o[l.dataIndex]) })
|
|
220
226
|
]
|
|
221
227
|
},
|
|
222
|
-
|
|
228
|
+
s
|
|
223
229
|
);
|
|
224
230
|
})
|
|
225
231
|
},
|
|
226
232
|
e
|
|
227
233
|
);
|
|
228
234
|
}),
|
|
229
|
-
|
|
230
|
-
var
|
|
235
|
+
v && Array.from({ length: ae }).map((o, e) => {
|
|
236
|
+
var n;
|
|
231
237
|
return /* @__PURE__ */ t.jsx(
|
|
232
238
|
"div",
|
|
233
239
|
{
|
|
234
240
|
className: "listItem",
|
|
235
|
-
style: { backgroundColor: (
|
|
241
|
+
style: { backgroundColor: (n = r.Table) == null ? void 0 : n.listItemBgColor },
|
|
236
242
|
children: /* @__PURE__ */ t.jsx("div", { className: "row", children: K ? K() : /* @__PURE__ */ t.jsx(
|
|
237
|
-
|
|
243
|
+
He,
|
|
238
244
|
{
|
|
239
245
|
title: !1,
|
|
240
246
|
paragraph: {
|
|
241
|
-
rows:
|
|
242
|
-
width:
|
|
247
|
+
rows: ie,
|
|
248
|
+
width: ce
|
|
243
249
|
},
|
|
244
250
|
active: !0
|
|
245
251
|
}
|
|
@@ -256,58 +262,60 @@ function Fe({
|
|
|
256
262
|
return /* @__PURE__ */ t.jsxs(
|
|
257
263
|
"div",
|
|
258
264
|
{
|
|
259
|
-
className:
|
|
265
|
+
className: ne("bitzTableBlock", { fullscreen: p }),
|
|
260
266
|
style: Le,
|
|
261
267
|
children: [
|
|
262
|
-
!
|
|
263
|
-
/* @__PURE__ */ t.jsxs("div", { className: "bitzTableContainerBody", ref:
|
|
264
|
-
|
|
265
|
-
|
|
268
|
+
!F && /* @__PURE__ */ t.jsxs("div", { ref: y, className: Se, style: Me, children: [
|
|
269
|
+
/* @__PURE__ */ t.jsxs("div", { className: "bitzTableContainerBody", ref: N, children: [
|
|
270
|
+
q && /* @__PURE__ */ t.jsxs("div", { className: "bitzTableToolbarBlock", children: [
|
|
271
|
+
me || /* @__PURE__ */ t.jsx("div", {}),
|
|
266
272
|
Ce,
|
|
267
|
-
(h == null ? void 0 : h.rowSelection) && /* @__PURE__ */ t.jsx(t.Fragment, { children:
|
|
273
|
+
(h == null ? void 0 : h.rowSelection) && /* @__PURE__ */ t.jsx(t.Fragment, { children: pe })
|
|
268
274
|
] }),
|
|
269
275
|
/* @__PURE__ */ t.jsx(
|
|
270
|
-
|
|
276
|
+
R,
|
|
271
277
|
{
|
|
272
|
-
columns:
|
|
273
|
-
dataSource:
|
|
278
|
+
columns: w,
|
|
279
|
+
dataSource: c,
|
|
274
280
|
loading: !1,
|
|
275
281
|
pagination: !1,
|
|
276
|
-
scroll:
|
|
282
|
+
scroll: k,
|
|
277
283
|
...h,
|
|
278
|
-
rowClassName:
|
|
284
|
+
rowClassName: Z,
|
|
285
|
+
className: "bitzTable"
|
|
279
286
|
}
|
|
280
287
|
),
|
|
281
288
|
/* @__PURE__ */ t.jsx(
|
|
282
|
-
|
|
289
|
+
Ve,
|
|
283
290
|
{
|
|
284
|
-
columns:
|
|
285
|
-
dataLength:
|
|
286
|
-
scroll:
|
|
291
|
+
columns: w,
|
|
292
|
+
dataLength: c.length,
|
|
293
|
+
scroll: k,
|
|
287
294
|
rowSelection: h.rowSelection,
|
|
288
295
|
expandable: h.expandable,
|
|
289
|
-
showTableTool:
|
|
290
|
-
rowClassName:
|
|
291
|
-
loading:
|
|
296
|
+
showTableTool: q,
|
|
297
|
+
rowClassName: Z,
|
|
298
|
+
loading: v,
|
|
299
|
+
className: "bitzTableSkeleton"
|
|
292
300
|
}
|
|
293
301
|
)
|
|
294
302
|
] }),
|
|
295
|
-
|
|
296
|
-
|
|
303
|
+
z && /* @__PURE__ */ t.jsx(
|
|
304
|
+
$e,
|
|
297
305
|
{
|
|
298
|
-
elRefInstance:
|
|
299
|
-
enableControl:
|
|
300
|
-
pagination:
|
|
301
|
-
total:
|
|
302
|
-
dataSource:
|
|
306
|
+
elRefInstance: X,
|
|
307
|
+
enableControl: he,
|
|
308
|
+
pagination: be,
|
|
309
|
+
total: L,
|
|
310
|
+
dataSource: c,
|
|
303
311
|
resetPage: ye,
|
|
304
312
|
paginationEmit: fe
|
|
305
313
|
}
|
|
306
314
|
)
|
|
307
315
|
] }),
|
|
308
|
-
|
|
309
|
-
(
|
|
310
|
-
!
|
|
316
|
+
F && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
317
|
+
(v || (c == null ? void 0 : c.length) > 0) && /* @__PURE__ */ t.jsx(t.Fragment, { children: _ ? /* @__PURE__ */ t.jsx(Fe, { onRefresh: _, children: ee }) : ee }),
|
|
318
|
+
!v && /* @__PURE__ */ t.jsx(Pe, { data: c, title: ue, img: ge }),
|
|
311
319
|
/* @__PURE__ */ t.jsx(
|
|
312
320
|
Ee,
|
|
313
321
|
{
|
|
@@ -316,7 +324,7 @@ function Fe({
|
|
|
316
324
|
placement: "bottom",
|
|
317
325
|
height: "auto",
|
|
318
326
|
closable: !1,
|
|
319
|
-
onClose:
|
|
327
|
+
onClose: U,
|
|
320
328
|
children: /* @__PURE__ */ t.jsxs("div", { className: "drawerBox", children: [
|
|
321
329
|
/* @__PURE__ */ t.jsx("div", { className: "boxBody", children: je.map((o, e) => /* @__PURE__ */ t.jsx(
|
|
322
330
|
"div",
|
|
@@ -324,14 +332,14 @@ function Fe({
|
|
|
324
332
|
className: "operaList",
|
|
325
333
|
onClick: () => Ne(o),
|
|
326
334
|
...o.danger && {
|
|
327
|
-
style: { color:
|
|
335
|
+
style: { color: r.colorError }
|
|
328
336
|
},
|
|
329
337
|
children: o.label
|
|
330
338
|
},
|
|
331
339
|
e
|
|
332
340
|
)) }),
|
|
333
341
|
/* @__PURE__ */ t.jsx("div", { className: "boxLine" }),
|
|
334
|
-
/* @__PURE__ */ t.jsx("div", { className: "boxFooter", onClick:
|
|
342
|
+
/* @__PURE__ */ t.jsx("div", { className: "boxFooter", onClick: U, children: xe })
|
|
335
343
|
] })
|
|
336
344
|
}
|
|
337
345
|
)
|
|
@@ -340,10 +348,7 @@ function Fe({
|
|
|
340
348
|
}
|
|
341
349
|
);
|
|
342
350
|
}
|
|
343
|
-
const
|
|
344
|
-
// @ts-ignore
|
|
345
|
-
/* @__PURE__ */ t.jsx(Ve, { initValue: j, children: /* @__PURE__ */ t.jsx(Fe, { ...j }) })
|
|
346
|
-
);
|
|
351
|
+
const go = (z) => /* @__PURE__ */ t.jsx(Re, { initValue: z, children: /* @__PURE__ */ t.jsx(qe, { ...z }) });
|
|
347
352
|
export {
|
|
348
|
-
|
|
353
|
+
go as default
|
|
349
354
|
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { BitzTableToolBarProps } from '..';
|
|
2
3
|
import './index.less';
|
|
3
|
-
export interface
|
|
4
|
+
export interface ColConfigModalProps {
|
|
5
|
+
onChange?: BitzTableToolBarProps['onColumnChange'];
|
|
4
6
|
}
|
|
5
|
-
declare const
|
|
6
|
-
export default
|
|
7
|
+
declare const ColConfigModal: React.FC<ColConfigModalProps & import("@ebay/nice-modal-react").NiceModalHocProps>;
|
|
8
|
+
export default ColConfigModal;
|