bitz-react-admin-ui 2.8.5 → 2.9.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/dist/_virtual/index.mjs +2 -2
- package/dist/_virtual/index2.mjs +2 -2
- package/dist/_virtual/lodash.mjs +4 -0
- package/dist/components/BitzTable/Store/utils/index.d.ts +3 -1
- package/dist/components/BitzTable/Store/utils/index.mjs +26 -38
- package/dist/components/BitzTable/Table/index.mjs +433 -430
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.mjs +144 -142
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/index.mjs +55 -49
- package/dist/components/BitzTable/ToolBar/index.d.ts +3 -0
- package/dist/node_modules/classnames/index.mjs +1 -1
- package/dist/node_modules/lodash/lodash.mjs +3680 -0
- package/dist/node_modules/lodash-es/_SetCache.mjs +13 -0
- package/dist/node_modules/lodash-es/_arrayIncludes.mjs +8 -0
- package/dist/node_modules/lodash-es/_arrayIncludesWith.mjs +9 -0
- package/dist/node_modules/lodash-es/_arraySome.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseFindIndex.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseForOwn.mjs +8 -0
- package/dist/node_modules/lodash-es/_baseHasIn.mjs +6 -0
- package/dist/node_modules/lodash-es/_baseIndexOf.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseIsEqual.mjs +8 -0
- package/dist/node_modules/lodash-es/_baseIsEqualDeep.mjs +32 -0
- package/dist/node_modules/lodash-es/_baseIsMatch.mjs +31 -0
- package/dist/node_modules/lodash-es/_baseIsNaN.mjs +6 -0
- package/dist/node_modules/lodash-es/_baseIteratee.mjs +11 -0
- package/dist/node_modules/lodash-es/_baseMatches.mjs +12 -0
- package/dist/node_modules/lodash-es/_baseMatchesProperty.mjs +17 -0
- package/dist/node_modules/lodash-es/_baseProperty.mjs +8 -0
- package/dist/node_modules/lodash-es/_basePropertyDeep.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseUniq.mjs +34 -0
- package/dist/node_modules/lodash-es/_cacheHas.mjs +6 -0
- package/dist/node_modules/lodash-es/_createSet.mjs +10 -0
- package/dist/node_modules/lodash-es/_equalArrays.mjs +40 -0
- package/dist/node_modules/lodash-es/_equalByTag.mjs +45 -0
- package/dist/node_modules/lodash-es/_equalObjects.mjs +36 -0
- package/dist/node_modules/lodash-es/_getMatchData.mjs +12 -0
- package/dist/node_modules/lodash-es/_hasPath.mjs +19 -0
- package/dist/node_modules/lodash-es/_isStrictComparable.mjs +7 -0
- package/dist/node_modules/lodash-es/_mapToArray.mjs +9 -0
- package/dist/node_modules/lodash-es/_matchesStrictComparable.mjs +8 -0
- package/dist/node_modules/lodash-es/_setCacheAdd.mjs +7 -0
- package/dist/node_modules/lodash-es/_setCacheHas.mjs +6 -0
- package/dist/node_modules/lodash-es/_setToArray.mjs +9 -0
- package/dist/node_modules/lodash-es/_strictIndexOf.mjs +9 -0
- package/dist/node_modules/lodash-es/hasIn.mjs +8 -0
- package/dist/node_modules/lodash-es/isNil.mjs +6 -0
- package/dist/node_modules/lodash-es/mapValues.mjs +12 -0
- package/dist/node_modules/lodash-es/noop.mjs +5 -0
- package/dist/node_modules/lodash-es/property.mjs +10 -0
- package/dist/node_modules/lodash-es/uniq.mjs +7 -0
- package/dist/node_modules/prop-types/index.mjs +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,282 +1,285 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { useRef as
|
|
3
|
-
import { isMobile as
|
|
4
|
-
import { Typography as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
1
|
+
import { j as n } from "../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { useRef as I, useContext as Ae, useState as G, useEffect as we, useMemo as a, useLayoutEffect as Fe, useCallback as de } from "react";
|
|
3
|
+
import { isMobile as z } from "../../../node_modules/react-device-detect/dist/lib.mjs";
|
|
4
|
+
import { Typography as ge, Skeleton as Ut, Alert as Xt, Table as Zt, Spin as vt } from "antd";
|
|
5
|
+
import he from "../../../node_modules/classnames/index.mjs";
|
|
6
|
+
import Et from "../../BitzDrawer/index.mjs";
|
|
7
|
+
import At from "../../BitzPagination/index.mjs";
|
|
8
|
+
import Ft from "../../BitzNoData/index.mjs";
|
|
9
9
|
import "../../BitzList/index.less.mjs";
|
|
10
|
-
import
|
|
10
|
+
import es from "../../BitzList/List.mjs";
|
|
11
11
|
import "../../BitzPullRefresh/style/index.less.mjs";
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import { loopFilter as
|
|
15
|
-
import
|
|
16
|
-
import { tablePaddingInline as
|
|
17
|
-
import
|
|
18
|
-
import
|
|
12
|
+
import ts from "../../BitzPullRefresh/PullRefresh.mjs";
|
|
13
|
+
import ss, { BitzTableContext as rs, toolCols as ns } from "../Store/index.mjs";
|
|
14
|
+
import { loopFilter as os, columnSort as ls, genColumnKey as Te } from "../Store/utils/index.mjs";
|
|
15
|
+
import is from "../../BitzTheme/index.mjs";
|
|
16
|
+
import { tablePaddingInline as cs } from "../../BitzConfigProvider/context.mjs";
|
|
17
|
+
import et from "../../BitzHighlight/index.mjs";
|
|
18
|
+
import as from "../../../node_modules/antd/es/table/ExpandIcon.mjs";
|
|
19
19
|
import "../../../node_modules/antd/es/config-provider/index.mjs";
|
|
20
|
-
import
|
|
21
|
-
import { getColumnsWithTool as
|
|
22
|
-
import { getCssVar as
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import
|
|
20
|
+
import us from "../../../node_modules/antd/locale/en_US.mjs";
|
|
21
|
+
import { getColumnsWithTool as ds, loopBuildSkeleton as hs, resetScroll as tt } from "./utils.mjs";
|
|
22
|
+
import { getCssVar as fs } from "./style.mjs";
|
|
23
|
+
import ms from "./SortableRow.mjs";
|
|
24
|
+
import bs from "./SortTableContext.mjs";
|
|
25
|
+
import ys from "./ResizableTitle copy.mjs";
|
|
26
|
+
import Cs from "../TextOverflow/index.mjs";
|
|
27
27
|
import "./index.less.mjs";
|
|
28
|
-
import { querySelectorAll as
|
|
29
|
-
import { TdCell as
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
28
|
+
import { querySelectorAll as xs, querySelector as ws } from "../../../utils/select-query.mjs";
|
|
29
|
+
import { TdCell as gs } from "./TdCell.mjs";
|
|
30
|
+
import Ts from "../../../node_modules/lodash-es/isNil.mjs";
|
|
31
|
+
import { ConfigContext as js } from "../../../node_modules/antd/es/config-provider/context.mjs";
|
|
32
|
+
import ks from "../../../node_modules/lodash-es/at.mjs";
|
|
33
|
+
function zs({
|
|
34
|
+
showPagination: Z = !0,
|
|
35
|
+
height: q,
|
|
36
|
+
minHeight: te,
|
|
37
|
+
dataSource: T,
|
|
38
|
+
total: K = 0,
|
|
39
|
+
columns: fe,
|
|
39
40
|
loading: u,
|
|
40
|
-
loadingType:
|
|
41
|
-
dataProps:
|
|
42
|
-
skeletonNum:
|
|
41
|
+
loadingType: st,
|
|
42
|
+
dataProps: rt = {},
|
|
43
|
+
skeletonNum: se = {
|
|
43
44
|
pc: 10,
|
|
44
45
|
mobile: 10
|
|
45
46
|
},
|
|
46
|
-
skeletonRender:
|
|
47
|
-
skeletonRowNum:
|
|
48
|
-
skeletonRowsWidth:
|
|
47
|
+
skeletonRender: me,
|
|
48
|
+
skeletonRowNum: nt = 4,
|
|
49
|
+
skeletonRowsWidth: ot = ["35%", "100%", "100%", "60%"],
|
|
49
50
|
// mobileLoadEmit,
|
|
50
|
-
mobileRefreshEmit:
|
|
51
|
-
operationFilter:
|
|
52
|
-
enableControlPage:
|
|
53
|
-
pagination:
|
|
54
|
-
paginationEmit:
|
|
51
|
+
mobileRefreshEmit: je,
|
|
52
|
+
operationFilter: f,
|
|
53
|
+
enableControlPage: lt,
|
|
54
|
+
pagination: B,
|
|
55
|
+
paginationEmit: Y = () => {
|
|
55
56
|
},
|
|
56
|
-
onChange:
|
|
57
|
-
enabledRowDragSort:
|
|
58
|
-
onRowDragEnd:
|
|
59
|
-
resizableColumns:
|
|
57
|
+
onChange: be,
|
|
58
|
+
enabledRowDragSort: J,
|
|
59
|
+
onRowDragEnd: ye,
|
|
60
|
+
resizableColumns: re,
|
|
60
61
|
// mobilePageHeight = 500,
|
|
61
|
-
mobileCancelText:
|
|
62
|
-
noDataTitle:
|
|
63
|
-
noDataImg:
|
|
62
|
+
mobileCancelText: it = "取消",
|
|
63
|
+
noDataTitle: ct,
|
|
64
|
+
noDataImg: at,
|
|
64
65
|
// color,
|
|
65
|
-
size:
|
|
66
|
-
showTableTool:
|
|
67
|
-
tableAction:
|
|
68
|
-
tableToolbar:
|
|
69
|
-
selectionBar:
|
|
70
|
-
scroll:
|
|
71
|
-
components:
|
|
72
|
-
expandable:
|
|
73
|
-
rowSelection:
|
|
74
|
-
selectionAlert:
|
|
75
|
-
resetPage:
|
|
76
|
-
inview:
|
|
77
|
-
...
|
|
66
|
+
size: ke,
|
|
67
|
+
showTableTool: ut = !0,
|
|
68
|
+
tableAction: dt,
|
|
69
|
+
tableToolbar: ht,
|
|
70
|
+
selectionBar: ft,
|
|
71
|
+
scroll: m,
|
|
72
|
+
components: O,
|
|
73
|
+
expandable: H,
|
|
74
|
+
rowSelection: D,
|
|
75
|
+
selectionAlert: y,
|
|
76
|
+
resetPage: mt,
|
|
77
|
+
inview: ze = !0,
|
|
78
|
+
...c
|
|
78
79
|
}) {
|
|
79
|
-
var
|
|
80
|
-
const { token:
|
|
81
|
-
|
|
82
|
-
let e = [...
|
|
83
|
-
(
|
|
84
|
-
}, [
|
|
85
|
-
const
|
|
86
|
-
var o, l,
|
|
87
|
-
let s,
|
|
88
|
-
if (typeof
|
|
89
|
-
s = (o =
|
|
90
|
-
(
|
|
80
|
+
var Ye, Je;
|
|
81
|
+
const { token: P } = is.useToken(), Ne = I([]), { Table: b } = P, We = b.tableSpaceBetweenPage ?? 10, bt = b.cellPaddingInline ?? cs, ne = b.minHeight ?? 500, { showColumnBorder: oe, hideRowBorder: Be, rowHoverable: yt, ...i } = Ae(rs), [Ct, le] = G(!1), [N, xt] = G([]);
|
|
82
|
+
we(() => {
|
|
83
|
+
let e = [...T ?? []];
|
|
84
|
+
(B == null ? void 0 : B.page) !== 1 && (e = [...N, ...e]), xt(e);
|
|
85
|
+
}, [z ? T : 0]);
|
|
86
|
+
const Se = a(() => !!(N != null && N.length) && (N == null ? void 0 : N.length) >= K, [N, K]), [ie, wt] = G([]), [gt, Me] = G(!1), Tt = async (e, t) => {
|
|
87
|
+
var o, l, x;
|
|
88
|
+
let s, r = !1;
|
|
89
|
+
if (typeof f == "function")
|
|
90
|
+
s = (o = f == null ? void 0 : f(e, t)) == null ? void 0 : o.filter(
|
|
91
|
+
(h) => h.type !== "divider"
|
|
91
92
|
);
|
|
92
|
-
else if (s = (l =
|
|
93
|
-
|
|
93
|
+
else if (s = (l = f == null ? void 0 : f.custom) == null ? void 0 : l.call(f, e, t), f != null && f.request) {
|
|
94
|
+
Me(!0), le(!0), r = !0;
|
|
94
95
|
try {
|
|
95
|
-
const
|
|
96
|
-
(
|
|
97
|
-
var
|
|
96
|
+
const h = await (f == null ? void 0 : f.request(e, t));
|
|
97
|
+
(x = f.fieldsName) != null && x.label ? s = h == null ? void 0 : h.map((C) => {
|
|
98
|
+
var W;
|
|
98
99
|
return {
|
|
99
100
|
...C,
|
|
100
|
-
label: C == null ? void 0 : C[((
|
|
101
|
+
label: C == null ? void 0 : C[((W = f.fieldsName) == null ? void 0 : W.label) ?? "label"]
|
|
101
102
|
};
|
|
102
|
-
}) : s =
|
|
103
|
+
}) : s = h ?? [];
|
|
103
104
|
} finally {
|
|
104
|
-
|
|
105
|
+
Me(!1);
|
|
105
106
|
}
|
|
106
107
|
}
|
|
107
|
-
s != null && s.length && (
|
|
108
|
-
},
|
|
109
|
-
|
|
110
|
-
},
|
|
111
|
-
var s,
|
|
112
|
-
|
|
113
|
-
},
|
|
114
|
-
|
|
115
|
-
},
|
|
116
|
-
|
|
117
|
-
},
|
|
108
|
+
s != null && s.length && (wt(s), r || le(!0));
|
|
109
|
+
}, He = () => {
|
|
110
|
+
le(!1);
|
|
111
|
+
}, jt = (e, t) => {
|
|
112
|
+
var s, r;
|
|
113
|
+
le(!1), (s = e.onClick) == null || s.call(e), !(e != null && e.onClick) && typeof f != "function" && (f != null && f.onClick) && f.onClick((r = ie == null ? void 0 : ie[t]) == null ? void 0 : r.key);
|
|
114
|
+
}, Q = I(null), Pe = I(null), d = I(null), p = I(null), v = I(null), kt = (...e) => {
|
|
115
|
+
tt(Q), be == null || be(...e);
|
|
116
|
+
}, zt = (...e) => {
|
|
117
|
+
tt(Q), Y == null || Y(...e);
|
|
118
|
+
}, U = a(() => !(m != null && m.auto) && re, [m == null ? void 0 : m.auto, re]), Nt = () => {
|
|
118
119
|
var s;
|
|
119
|
-
const e =
|
|
120
|
+
const e = xs(
|
|
120
121
|
"& > .bitzTableContainerBody > .ant-table-wrapper.bitzTable > .ant-spin-nested-loading > .ant-spin-container > .ant-table > .ant-table-container > .ant-table-body > table > .ant-table-tbody > tr:not(.ant-table-measure-row, .ant-table-expanded-row)",
|
|
121
|
-
(s =
|
|
122
|
+
(s = d.current) == null ? void 0 : s.querySelectorAll
|
|
122
123
|
), t = [];
|
|
123
|
-
if (e == null || e.forEach((
|
|
124
|
+
if (e == null || e.forEach((r) => {
|
|
124
125
|
var o;
|
|
125
126
|
t.push(
|
|
126
|
-
((o =
|
|
127
|
+
((o = ws("& > .operationCol .actionGroup", r.querySelector)) == null ? void 0 : o.clientWidth) || 0
|
|
127
128
|
);
|
|
128
129
|
}), t.length)
|
|
129
130
|
return Math.ceil(Math.max(...t));
|
|
130
|
-
},
|
|
131
|
-
var o, l,
|
|
132
|
-
let e = (o =
|
|
131
|
+
}, Wt = () => {
|
|
132
|
+
var o, l, x, h;
|
|
133
|
+
let e = (o = d.current) == null ? void 0 : o.querySelector(
|
|
133
134
|
".ant-table-content"
|
|
134
135
|
);
|
|
135
|
-
e || (e = (l =
|
|
136
|
+
e || (e = (l = d.current) == null ? void 0 : l.querySelector(
|
|
136
137
|
".ant-table-body"
|
|
137
138
|
));
|
|
138
|
-
let t = 0, s = !1,
|
|
139
|
-
return e && (t = e.clientWidth - (
|
|
139
|
+
let t = 0, s = !1, r = 0;
|
|
140
|
+
return e && (t = e.clientWidth - (oe ? 1 : 0), s = e.offsetWidth - e.clientWidth > 0, r = (h = (x = d.current) == null ? void 0 : x.querySelector(
|
|
140
141
|
".ant-table-cell-scrollbar"
|
|
141
|
-
)) == null ? void 0 :
|
|
142
|
-
},
|
|
143
|
-
const e = (
|
|
144
|
-
return Array.from({ length: t }).map((
|
|
142
|
+
)) == null ? void 0 : h.offsetWidth), { hasScrollBar: s, scrollbarSize: r, tbodyWidth: t };
|
|
143
|
+
}, Le = a(() => {
|
|
144
|
+
const e = (T ?? []).length, t = e > (se.pc ?? 10) ? e >= 15 ? 15 : e : se.pc ?? 10;
|
|
145
|
+
return Array.from({ length: t }).map((r, o) => ({
|
|
145
146
|
key: `${Date.now()}${o}`
|
|
146
147
|
}));
|
|
147
|
-
}, [
|
|
148
|
-
var
|
|
149
|
-
if (typeof
|
|
148
|
+
}, [T]), ce = a(() => st === "normal" ? u ? Ne.current : (Ne.current = T, T) : u ? Le : T ?? [], [u, T, Le]), { hasScrollBar: L, scrollbarSize: S, tbodyWidth: E } = a(() => Wt(), [ce, i.fullscreen]), Ce = a(() => {
|
|
149
|
+
var R, _, k, ee, Qe, ue, Ue, Xe, Ze, ve;
|
|
150
|
+
if (typeof q > "u" || Ts((R = d == null ? void 0 : d.current) == null ? void 0 : R.clientHeight))
|
|
150
151
|
return;
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
152
|
+
const e = (_ = d == null ? void 0 : d.current) == null ? void 0 : _.clientHeight, t = ((Qe = (ee = (k = d == null ? void 0 : d.current) == null ? void 0 : k.querySelector) == null ? void 0 : ee.call(k, ".ant-table-header")) == null ? void 0 : Qe.clientHeight) ?? 50, s = ((Xe = (Ue = (ue = d == null ? void 0 : d.current) == null ? void 0 : ue.querySelector) == null ? void 0 : Ue.call(ue, ".bitzTablePagination")) == null ? void 0 : Xe.clientHeight) ?? 30;
|
|
153
|
+
let r = 40, o = 40;
|
|
154
|
+
if (d.current) {
|
|
155
|
+
const Ee = window.getComputedStyle(d.current);
|
|
156
|
+
r = parseInt(Ee.getPropertyValue("--cell-height")), o = parseInt(Ee.getPropertyValue("--toolbar-height"));
|
|
155
157
|
}
|
|
156
|
-
const
|
|
157
|
-
if (!
|
|
158
|
-
return
|
|
159
|
-
const
|
|
160
|
-
return (
|
|
158
|
+
const l = ((Ze = v == null ? void 0 : v.current) == null ? void 0 : Ze.clientHeight) || 0, x = l ? We : 0, h = (x || 10) + o + s + (t ?? 50), C = (ve = Q == null ? void 0 : Q.current) == null ? void 0 : ve.clientHeight;
|
|
159
|
+
if (!i.fullscreen && e < C + h)
|
|
160
|
+
return e - h;
|
|
161
|
+
const W = te ?? ne, $ = q >= W ? q : W;
|
|
162
|
+
return (i.fullscreen ? window.innerHeight : $) - l - x - o - r;
|
|
161
163
|
}, [
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
164
|
+
(Ye = d == null ? void 0 : d.current) == null ? void 0 : Ye.clientHeight,
|
|
165
|
+
i.fullscreen,
|
|
166
|
+
q,
|
|
165
167
|
te,
|
|
168
|
+
ne,
|
|
166
169
|
// paginationRect?.height,
|
|
167
|
-
|
|
170
|
+
ce,
|
|
168
171
|
// containerBodyRect?.height,
|
|
169
|
-
|
|
170
|
-
]),
|
|
172
|
+
i.tableSize
|
|
173
|
+
]), Bt = () => {
|
|
171
174
|
let e = 0;
|
|
172
|
-
if (
|
|
173
|
-
const s = window.getComputedStyle(
|
|
175
|
+
if (d.current) {
|
|
176
|
+
const s = window.getComputedStyle(d.current), r = parseInt(
|
|
174
177
|
s.getPropertyValue("--toolCell-paddingInline")
|
|
175
178
|
);
|
|
176
|
-
e = parseInt(s.getPropertyValue("--fontSize")) + 4 + 2 *
|
|
179
|
+
e = parseInt(s.getPropertyValue("--fontSize")) + 4 + 2 * r;
|
|
177
180
|
}
|
|
178
181
|
let t = 0;
|
|
179
|
-
return
|
|
180
|
-
}, [
|
|
181
|
-
|
|
182
|
-
var
|
|
183
|
-
const e =
|
|
182
|
+
return D && (t += e), H && (t += e), J && (t += e), t;
|
|
183
|
+
}, [j, St] = G([]), [A, Mt] = G(0);
|
|
184
|
+
Fe(() => {
|
|
185
|
+
var h;
|
|
186
|
+
const e = fe ?? [], t = (h = e.find((C) => C.isOperationCol)) == null ? void 0 : h.width, s = e.filter((C) => !ns.includes(C)), o = os(s, i.columnsMap).sort(ls(i.columnsMap)), l = o.findIndex((C) => C.isOperationCol);
|
|
184
187
|
l >= 0 && (o[l].width = t);
|
|
185
|
-
let
|
|
186
|
-
|
|
187
|
-
}, [
|
|
188
|
-
const [
|
|
189
|
-
|
|
190
|
-
if (
|
|
191
|
-
const e =
|
|
192
|
-
let
|
|
188
|
+
let x = 0;
|
|
189
|
+
z || (x = Bt()), St(o), Mt(x);
|
|
190
|
+
}, [i.columnsMap, fe]);
|
|
191
|
+
const [g, Ht] = G([]);
|
|
192
|
+
we(() => {
|
|
193
|
+
if (U) {
|
|
194
|
+
const e = j.map((t, s) => {
|
|
195
|
+
let r = t.width;
|
|
193
196
|
if (t != null && t.isOperationCol && (t != null && t.useMaxWidth)) {
|
|
194
|
-
const l =
|
|
195
|
-
l && (
|
|
197
|
+
const l = Nt();
|
|
198
|
+
l && (r = l + bt * 2);
|
|
196
199
|
}
|
|
197
200
|
return {
|
|
198
|
-
key:
|
|
199
|
-
width:
|
|
201
|
+
key: Te(t, s),
|
|
202
|
+
width: r ?? 0
|
|
200
203
|
};
|
|
201
204
|
});
|
|
202
|
-
|
|
205
|
+
Ht(e);
|
|
203
206
|
}
|
|
204
|
-
}, [
|
|
205
|
-
const
|
|
207
|
+
}, [j, U]);
|
|
208
|
+
const $e = I(!1), qe = I(!1), ae = a(() => {
|
|
206
209
|
let e;
|
|
207
|
-
if (typeof
|
|
210
|
+
if (typeof Ce == "number" && (e = Ce - 1), typeof (m == null ? void 0 : m.y) == "number" && (e = m.y - 2), m != null && m.auto)
|
|
208
211
|
return {
|
|
209
212
|
x: void 0,
|
|
210
213
|
y: e
|
|
211
214
|
};
|
|
212
|
-
let t =
|
|
213
|
-
return
|
|
215
|
+
let t = m == null ? void 0 : m.x;
|
|
216
|
+
return re && g.length && (t = g.reduce((o, l) => o + l.width, 0) + A, E && t < E - (L ? S : 0) && ($e.current = !0, t = E)), m != null && m.y ? { x: t, y: m.y } : { x: t, y: e };
|
|
214
217
|
}, [
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
218
|
+
m,
|
|
219
|
+
Ce,
|
|
220
|
+
re,
|
|
221
|
+
g,
|
|
222
|
+
A,
|
|
223
|
+
oe,
|
|
224
|
+
L,
|
|
225
|
+
S
|
|
223
226
|
]);
|
|
224
|
-
|
|
225
|
-
if (
|
|
226
|
-
const t =
|
|
227
|
-
if (t <
|
|
228
|
-
const o = /* @__PURE__ */ new Map(), l =
|
|
229
|
-
(
|
|
227
|
+
we(() => {
|
|
228
|
+
if (U && g.length) {
|
|
229
|
+
const t = g.reduce((o, l) => o + l.width, 0) + A, r = E - (L ? S : 0);
|
|
230
|
+
if (t < r || $e.current && t > r && !qe.current) {
|
|
231
|
+
const o = /* @__PURE__ */ new Map(), l = j.findIndex(
|
|
232
|
+
(w) => w == null ? void 0 : w.isOperationCol
|
|
230
233
|
);
|
|
231
|
-
let
|
|
232
|
-
l >= 0 && (
|
|
233
|
-
|
|
234
|
+
let x = "";
|
|
235
|
+
l >= 0 && (x = Te(
|
|
236
|
+
j[l],
|
|
234
237
|
l
|
|
235
|
-
)),
|
|
236
|
-
let
|
|
237
|
-
if (l >= 0 && C--,
|
|
238
|
-
const
|
|
239
|
-
o.forEach((
|
|
240
|
-
o.set(
|
|
241
|
-
}),
|
|
238
|
+
)), g.forEach((w) => o.set(w.key, w.width));
|
|
239
|
+
let h = r - t, C = j.length;
|
|
240
|
+
if (l >= 0 && C--, h >= C) {
|
|
241
|
+
const w = Math.floor(h / C);
|
|
242
|
+
o.forEach((F, R) => {
|
|
243
|
+
o.set(R, F + (x === R ? 0 : w));
|
|
244
|
+
}), h = h - w * C;
|
|
242
245
|
}
|
|
243
|
-
let
|
|
244
|
-
l === 0 &&
|
|
245
|
-
const
|
|
246
|
-
o.set(
|
|
247
|
-
const
|
|
248
|
-
for (const
|
|
249
|
-
|
|
250
|
-
|
|
246
|
+
let W = 0;
|
|
247
|
+
l === 0 && j.length > 1 && W++;
|
|
248
|
+
const $ = Te(j[W]);
|
|
249
|
+
o.set($, o.get($) + h);
|
|
250
|
+
const M = { ...i.columnsMap };
|
|
251
|
+
for (const w in M)
|
|
252
|
+
M[w].show && (M[w].width = o.get(w));
|
|
253
|
+
i.setColumnsMap(M);
|
|
251
254
|
}
|
|
252
255
|
}
|
|
253
256
|
}, [
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
257
|
+
U,
|
|
258
|
+
g,
|
|
259
|
+
A,
|
|
260
|
+
oe,
|
|
261
|
+
L,
|
|
262
|
+
S
|
|
260
263
|
]);
|
|
261
|
-
const
|
|
264
|
+
const Pt = a(() => {
|
|
262
265
|
var e;
|
|
263
|
-
if (
|
|
266
|
+
if (i.fullscreen) {
|
|
264
267
|
const t = document.body.clientHeight, s = (e = document.fullscreenElement) != null && e.classList.contains(
|
|
265
268
|
"bz-fullscreen"
|
|
266
269
|
) ? 50 : 0;
|
|
267
270
|
return { y: t - 80 - s };
|
|
268
271
|
}
|
|
269
272
|
return {};
|
|
270
|
-
}, [
|
|
271
|
-
if (
|
|
272
|
-
return
|
|
273
|
-
const e =
|
|
273
|
+
}, [i.fullscreen]), V = a(() => {
|
|
274
|
+
if (z)
|
|
275
|
+
return j;
|
|
276
|
+
const e = j.length - 1, t = j.map((s, r) => {
|
|
274
277
|
var o;
|
|
275
278
|
return {
|
|
276
279
|
...s,
|
|
277
280
|
...typeof s.title == "string" && {
|
|
278
|
-
title: /* @__PURE__ */
|
|
279
|
-
|
|
281
|
+
title: /* @__PURE__ */ n.jsx(
|
|
282
|
+
ge.Paragraph,
|
|
280
283
|
{
|
|
281
284
|
className: "bitzTableTitle",
|
|
282
285
|
ellipsis: { rows: 2 },
|
|
@@ -284,68 +287,68 @@ function bs({
|
|
|
284
287
|
}
|
|
285
288
|
)
|
|
286
289
|
},
|
|
287
|
-
...e ===
|
|
288
|
-
className:
|
|
290
|
+
...e === r && {
|
|
291
|
+
className: he(s.className, "lastColumn")
|
|
289
292
|
},
|
|
290
|
-
width:
|
|
291
|
-
...
|
|
293
|
+
width: g.length ? (o = g[r]) == null ? void 0 : o.width : (s == null ? void 0 : s.width) || void 0,
|
|
294
|
+
...ae.x !== void 0 ? {
|
|
292
295
|
onHeaderCell: (l) => {
|
|
293
|
-
var
|
|
296
|
+
var x;
|
|
294
297
|
return {
|
|
295
|
-
...(
|
|
298
|
+
...(x = s.onHeaderCell) == null ? void 0 : x.call(s),
|
|
296
299
|
width: l.width,
|
|
297
|
-
stretchref:
|
|
298
|
-
datagridref:
|
|
299
|
-
onResize:
|
|
300
|
+
stretchref: Pe,
|
|
301
|
+
datagridref: p,
|
|
302
|
+
onResize: Lt(r)
|
|
300
303
|
};
|
|
301
304
|
}
|
|
302
305
|
} : {},
|
|
303
306
|
...!(s != null && s.render) && s.copyable ? {
|
|
304
|
-
render: (l) => ["number", "bigint"].includes(typeof l) ? l : /* @__PURE__ */
|
|
307
|
+
render: (l) => ["number", "bigint"].includes(typeof l) ? l : /* @__PURE__ */ n.jsx(Cs, { value: l })
|
|
305
308
|
} : {}
|
|
306
309
|
};
|
|
307
310
|
});
|
|
308
|
-
return
|
|
309
|
-
|
|
311
|
+
return ds(
|
|
312
|
+
fe,
|
|
310
313
|
t,
|
|
311
|
-
|
|
312
|
-
!!
|
|
313
|
-
!!
|
|
314
|
+
J,
|
|
315
|
+
!!D,
|
|
316
|
+
!!H
|
|
314
317
|
);
|
|
315
|
-
}, [
|
|
316
|
-
const l = (s.width >
|
|
318
|
+
}, [j, g]), Lt = (e) => (t, { size: s, minWidth: r }) => {
|
|
319
|
+
const l = (s.width > r ? s.width : r) - g[e].width;
|
|
317
320
|
if (l === 0)
|
|
318
321
|
return;
|
|
319
|
-
const
|
|
320
|
-
let
|
|
321
|
-
if (l < 0 &&
|
|
322
|
-
|
|
323
|
-
const
|
|
324
|
-
(e ===
|
|
325
|
-
let
|
|
326
|
-
|
|
322
|
+
const h = g.reduce((_, k) => _ + k.width, 0) + l + A, W = E - (L ? S : 0);
|
|
323
|
+
let $ = "", M = -1, w = 0;
|
|
324
|
+
if (l < 0 && h < W) {
|
|
325
|
+
M = e + 1;
|
|
326
|
+
const _ = j.length - 1, k = j[_];
|
|
327
|
+
(e === _ - 1 && (k != null && k.isOperationCol) || e === _ && !(k != null && k.isOperationCol)) && (M = e - 1);
|
|
328
|
+
let ee = 0;
|
|
329
|
+
ae.x > W && (ee = ae.x - W), $ = `${g[M].key}`, w = g[M].width - l - ee;
|
|
327
330
|
}
|
|
328
|
-
const
|
|
329
|
-
...
|
|
330
|
-
[
|
|
331
|
-
...
|
|
332
|
-
width:
|
|
331
|
+
const F = `${g[e].key}`, R = {
|
|
332
|
+
...i.columnsMap,
|
|
333
|
+
[F]: {
|
|
334
|
+
...i.columnsMap[F],
|
|
335
|
+
width: g[e].width + l
|
|
333
336
|
},
|
|
334
|
-
|
|
335
|
-
[
|
|
336
|
-
...
|
|
337
|
-
width:
|
|
337
|
+
...$ && M >= 0 && {
|
|
338
|
+
[$]: {
|
|
339
|
+
...i.columnsMap[$],
|
|
340
|
+
width: w
|
|
338
341
|
}
|
|
339
342
|
}
|
|
340
343
|
};
|
|
341
|
-
|
|
342
|
-
},
|
|
343
|
-
if (
|
|
344
|
+
i.setColumnsMap(R), qe.current = !0, i.persistenceType === "online" && i.persistenceKey && i.startAutoSaveCountdown();
|
|
345
|
+
}, Ke = a(() => hs(V), [V]), X = a(() => u ? Ke : V, [u, V, Ke]), { table: xe, locale: $t = us } = Ae(js), qt = { ...$t.Table }, Kt = ((Je = xe == null ? void 0 : xe.expandable) == null ? void 0 : Je.expandIcon) || (H == null ? void 0 : H.expandIcon) || as(qt), Oe = a(() => {
|
|
346
|
+
if (H)
|
|
344
347
|
return {
|
|
345
|
-
...
|
|
346
|
-
expandedRowRender: () => /* @__PURE__ */
|
|
348
|
+
...H,
|
|
349
|
+
expandedRowRender: () => /* @__PURE__ */ n.jsx(n.Fragment, {}),
|
|
347
350
|
expandIcon: (e) => {
|
|
348
|
-
const t =
|
|
351
|
+
const t = Kt(e);
|
|
349
352
|
return {
|
|
350
353
|
...t,
|
|
351
354
|
props: {
|
|
@@ -353,143 +356,143 @@ function bs({
|
|
|
353
356
|
disabled: !0,
|
|
354
357
|
style: {
|
|
355
358
|
...t.props.style,
|
|
356
|
-
backgroundColor:
|
|
359
|
+
backgroundColor: P.colorBgContainerDisabled
|
|
357
360
|
}
|
|
358
361
|
}
|
|
359
362
|
};
|
|
360
363
|
}
|
|
361
364
|
};
|
|
362
|
-
}, [
|
|
363
|
-
if (
|
|
365
|
+
}, [H]), Ot = a(() => u ? Oe : H, [u, H, Oe]), pe = a(() => {
|
|
366
|
+
if (D)
|
|
364
367
|
return {
|
|
365
|
-
...
|
|
368
|
+
...D,
|
|
366
369
|
selectedRowKeys: [],
|
|
367
370
|
getCheckboxProps: () => ({ disabled: !0 })
|
|
368
371
|
};
|
|
369
|
-
}, [
|
|
372
|
+
}, [D]), pt = a(() => u ? pe : D, [u, D, pe]), Ve = a(() => u ? "key" : c.rowKey, [u, c.rowKey]), _e = a(() => `${ke ?? i.stylesConfig.size}BitzTable`, [ke, i.stylesConfig.size]), Vt = de(
|
|
370
373
|
(e, t) => {
|
|
371
|
-
var
|
|
372
|
-
if (!
|
|
374
|
+
var r;
|
|
375
|
+
if (!c.onRow || u)
|
|
373
376
|
return {};
|
|
374
|
-
const s = (
|
|
377
|
+
const s = (r = c.onRow) == null ? void 0 : r.call(c, e, t);
|
|
375
378
|
return s.onClick && (s.className = "rowPointerCursor"), s;
|
|
376
379
|
},
|
|
377
|
-
[
|
|
378
|
-
),
|
|
380
|
+
[c.onRow, u]
|
|
381
|
+
), _t = a(() => he(
|
|
379
382
|
"bitzTableContainer",
|
|
380
|
-
{ hideBorder:
|
|
381
|
-
{ hasScrollBar:
|
|
382
|
-
{ stickyTable: !!(
|
|
383
|
-
|
|
384
|
-
|
|
383
|
+
{ hideBorder: Be },
|
|
384
|
+
{ hasScrollBar: L },
|
|
385
|
+
{ stickyTable: !!(c != null && c.sticky) },
|
|
386
|
+
_e,
|
|
387
|
+
c.className
|
|
385
388
|
), [
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
]),
|
|
393
|
-
"--container-bgColor":
|
|
394
|
-
}), [
|
|
395
|
-
const e =
|
|
389
|
+
c.className,
|
|
390
|
+
_e,
|
|
391
|
+
L,
|
|
392
|
+
i.fullscreen,
|
|
393
|
+
Be,
|
|
394
|
+
c.sticky
|
|
395
|
+
]), It = a(() => ({
|
|
396
|
+
"--container-bgColor": P.colorBgContainer
|
|
397
|
+
}), [P.colorBgContainer]), Dt = a(() => {
|
|
398
|
+
const e = te ?? ne;
|
|
396
399
|
let t;
|
|
397
|
-
|
|
398
|
-
const s =
|
|
399
|
-
let
|
|
400
|
-
return (
|
|
400
|
+
q && (t = q >= e ? q : e);
|
|
401
|
+
const s = i.fullscreen ? "100%" : t;
|
|
402
|
+
let r;
|
|
403
|
+
return (S ?? 0) > 0 && (r = S), fs({
|
|
401
404
|
height: s ?? "auto",
|
|
402
|
-
token:
|
|
403
|
-
evenRowBgColor:
|
|
404
|
-
table:
|
|
405
|
-
gap:
|
|
406
|
-
borderColor: (
|
|
407
|
-
scrollbarWidth:
|
|
408
|
-
other:
|
|
405
|
+
token: P,
|
|
406
|
+
evenRowBgColor: i.zebra ? b == null ? void 0 : b.evenRowBgColor : P.colorBgContainer,
|
|
407
|
+
table: b,
|
|
408
|
+
gap: We,
|
|
409
|
+
borderColor: (b == null ? void 0 : b.borderColor) || P.colorBorderSecondary,
|
|
410
|
+
scrollbarWidth: r,
|
|
411
|
+
other: c.style
|
|
409
412
|
});
|
|
410
413
|
}, [
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
A,
|
|
414
|
+
c.style,
|
|
415
|
+
i.fullscreen,
|
|
416
|
+
q,
|
|
415
417
|
te,
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
418
|
+
ne,
|
|
419
|
+
b,
|
|
420
|
+
i == null ? void 0 : i.zebra,
|
|
421
|
+
S
|
|
422
|
+
]), Rt = de(
|
|
420
423
|
(e, t, s) => {
|
|
421
|
-
const
|
|
422
|
-
if (
|
|
423
|
-
const o =
|
|
424
|
-
return
|
|
424
|
+
const r = t % 2 === 0 ? "oddRow" : "evenRow";
|
|
425
|
+
if (c.rowClassName) {
|
|
426
|
+
const o = c.rowClassName(e, t, s);
|
|
427
|
+
return he(r, o);
|
|
425
428
|
}
|
|
426
|
-
return
|
|
429
|
+
return r;
|
|
427
430
|
},
|
|
428
|
-
[
|
|
429
|
-
),
|
|
430
|
-
|
|
431
|
+
[c.rowClassName]
|
|
432
|
+
), Ie = a(() => /* @__PURE__ */ n.jsx(
|
|
433
|
+
es,
|
|
431
434
|
{
|
|
432
|
-
finished:
|
|
435
|
+
finished: Se,
|
|
433
436
|
onLoad: async () => (
|
|
434
437
|
// @ts-ignore
|
|
435
|
-
!u && (
|
|
438
|
+
!u && (Y == null ? void 0 : Y((B == null ? void 0 : B.page) + 1, B == null ? void 0 : B.size))
|
|
436
439
|
),
|
|
437
440
|
loadingText: "加载中...",
|
|
438
441
|
finishedText: "没有更多了",
|
|
439
442
|
errorText: "加载失败",
|
|
440
|
-
children: /* @__PURE__ */
|
|
443
|
+
children: /* @__PURE__ */ n.jsxs(
|
|
441
444
|
"div",
|
|
442
445
|
{
|
|
443
446
|
className: "mobileList",
|
|
444
|
-
style: { backgroundColor:
|
|
447
|
+
style: { backgroundColor: b == null ? void 0 : b.mobileListBgColor },
|
|
445
448
|
children: [
|
|
446
|
-
|
|
449
|
+
N == null ? void 0 : N.map((e, t) => /* @__PURE__ */ n.jsx(
|
|
447
450
|
"div",
|
|
448
451
|
{
|
|
449
452
|
className: "listItem",
|
|
450
|
-
style: { backgroundColor:
|
|
451
|
-
onClick: () =>
|
|
452
|
-
children:
|
|
453
|
+
style: { backgroundColor: b == null ? void 0 : b.listItemBgColor },
|
|
454
|
+
onClick: () => Tt(e, t),
|
|
455
|
+
children: V == null ? void 0 : V.map((s, r) => {
|
|
453
456
|
var o;
|
|
454
|
-
return !(s != null && s.mobileHide) && /* @__PURE__ */
|
|
457
|
+
return !(s != null && s.mobileHide) && /* @__PURE__ */ n.jsxs(
|
|
455
458
|
"div",
|
|
456
459
|
{
|
|
457
460
|
className: "row",
|
|
458
|
-
style: { color:
|
|
461
|
+
style: { color: P.colorText },
|
|
459
462
|
children: [
|
|
460
|
-
!s.mobileHideLabel && /* @__PURE__ */
|
|
463
|
+
!s.mobileHideLabel && /* @__PURE__ */ n.jsxs("div", { className: "label", children: [
|
|
461
464
|
`${s.title}`,
|
|
462
465
|
":"
|
|
463
466
|
] }),
|
|
464
|
-
/* @__PURE__ */
|
|
467
|
+
/* @__PURE__ */ n.jsx("div", { className: "value", children: ((o = s == null ? void 0 : s.render) == null ? void 0 : o.call(
|
|
465
468
|
s,
|
|
466
|
-
|
|
469
|
+
ks(e, (s == null ? void 0 : s.dataIndex) || ""),
|
|
467
470
|
e,
|
|
468
471
|
t
|
|
469
472
|
)) || (e == null ? void 0 : e[s.dataIndex]) })
|
|
470
473
|
]
|
|
471
474
|
},
|
|
472
|
-
|
|
475
|
+
r
|
|
473
476
|
);
|
|
474
477
|
})
|
|
475
478
|
},
|
|
476
479
|
t
|
|
477
480
|
)),
|
|
478
|
-
Array.from({ length:
|
|
481
|
+
Array.from({ length: se.mobile ?? 2 }).map((e, t) => /* @__PURE__ */ n.jsx(
|
|
479
482
|
"div",
|
|
480
483
|
{
|
|
481
484
|
className: "listItem",
|
|
482
485
|
style: {
|
|
483
486
|
display: u ? "block" : "none",
|
|
484
|
-
backgroundColor:
|
|
487
|
+
backgroundColor: b == null ? void 0 : b.listItemBgColor
|
|
485
488
|
},
|
|
486
|
-
children: /* @__PURE__ */
|
|
487
|
-
|
|
489
|
+
children: /* @__PURE__ */ n.jsx("div", { className: "row", children: me ? me() : /* @__PURE__ */ n.jsx(
|
|
490
|
+
Ut,
|
|
488
491
|
{
|
|
489
492
|
title: !1,
|
|
490
493
|
paragraph: {
|
|
491
|
-
rows:
|
|
492
|
-
width:
|
|
494
|
+
rows: nt,
|
|
495
|
+
width: ot
|
|
493
496
|
},
|
|
494
497
|
active: !0
|
|
495
498
|
}
|
|
@@ -502,207 +505,207 @@ function bs({
|
|
|
502
505
|
)
|
|
503
506
|
}
|
|
504
507
|
), [
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
508
|
+
z ? Se : 0,
|
|
509
|
+
z ? u : 0,
|
|
510
|
+
z ? B : 0,
|
|
511
|
+
z ? b : 0,
|
|
512
|
+
z ? N : 0,
|
|
513
|
+
z ? V : 0,
|
|
514
|
+
z ? se : 0,
|
|
515
|
+
z ? me : 0
|
|
513
516
|
]);
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
}, [
|
|
517
|
-
const
|
|
518
|
-
/* @__PURE__ */
|
|
519
|
-
|
|
517
|
+
Fe(() => {
|
|
518
|
+
i.setSelected(!!(y != null && y.num));
|
|
519
|
+
}, [y]);
|
|
520
|
+
const De = a(() => /* @__PURE__ */ n.jsxs("div", { className: "alert", children: [
|
|
521
|
+
/* @__PURE__ */ n.jsx(
|
|
522
|
+
et,
|
|
520
523
|
{
|
|
521
524
|
highlightTag: "strong",
|
|
522
|
-
keywords: `${
|
|
523
|
-
sourceString: `共 ${
|
|
525
|
+
keywords: `${K}`,
|
|
526
|
+
sourceString: `共 ${K} 条`,
|
|
524
527
|
tagClass: "totalText"
|
|
525
528
|
}
|
|
526
529
|
),
|
|
527
|
-
!!
|
|
528
|
-
/* @__PURE__ */
|
|
529
|
-
/* @__PURE__ */
|
|
530
|
-
|
|
530
|
+
!!y && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
531
|
+
/* @__PURE__ */ n.jsx(ge.Text, { className: "splitBorder", children: "/" }),
|
|
532
|
+
/* @__PURE__ */ n.jsx(
|
|
533
|
+
et,
|
|
531
534
|
{
|
|
532
535
|
highlightTag: "strong",
|
|
533
|
-
keywords: `${(
|
|
534
|
-
sourceString: `已选中 ${(
|
|
536
|
+
keywords: `${(y == null ? void 0 : y.num) ?? 0}`,
|
|
537
|
+
sourceString: `已选中 ${(y == null ? void 0 : y.num) ?? 0} 条`
|
|
535
538
|
}
|
|
536
539
|
),
|
|
537
|
-
!!(
|
|
538
|
-
|
|
540
|
+
!!(y != null && y.num) && /* @__PURE__ */ n.jsx(
|
|
541
|
+
ge.Link,
|
|
539
542
|
{
|
|
540
543
|
className: "cleanSelected",
|
|
541
|
-
onClick:
|
|
544
|
+
onClick: y == null ? void 0 : y.onClear,
|
|
542
545
|
children: "取消选中"
|
|
543
546
|
}
|
|
544
547
|
)
|
|
545
548
|
] })
|
|
546
|
-
] }), [
|
|
547
|
-
u ||
|
|
548
|
-
},
|
|
549
|
-
row: (e) =>
|
|
550
|
-
} : {}, [
|
|
549
|
+
] }), [K, y]), Gt = (e) => {
|
|
550
|
+
u || ye == null || ye(e);
|
|
551
|
+
}, Re = de(() => J ? {
|
|
552
|
+
row: (e) => ms({ ...e, loading: u == null ? void 0 : u.toString() })
|
|
553
|
+
} : {}, [J, J ? u : !1]), Ge = de(
|
|
551
554
|
(e) => {
|
|
552
|
-
var
|
|
553
|
-
if (
|
|
554
|
-
return
|
|
555
|
+
var r, o;
|
|
556
|
+
if (U)
|
|
557
|
+
return ys({ ...e, hasScrollBar: L, scrollbarSize: S });
|
|
555
558
|
const t = { ...e };
|
|
556
|
-
return ((
|
|
559
|
+
return ((r = t.className) == null ? void 0 : r.includes(
|
|
557
560
|
"ant-table-cell-fix-right"
|
|
558
|
-
)) && !
|
|
561
|
+
)) && !L && ((o = t.style) != null && o.right) && (t.style = { ...t.style ?? {} }, t.style.right = Number(t.style.right ?? 0) - (S || 0)), /* @__PURE__ */ n.jsx("th", { ...t });
|
|
559
562
|
},
|
|
560
|
-
[
|
|
561
|
-
),
|
|
562
|
-
...
|
|
563
|
+
[L, S, U]
|
|
564
|
+
), Yt = a(() => c != null && c.virtual ? {} : ze ? { cell: gs } : {}, [ze, c == null ? void 0 : c.virtual]), Jt = a(() => ({
|
|
565
|
+
...O,
|
|
563
566
|
header: {
|
|
564
|
-
...
|
|
565
|
-
cell:
|
|
567
|
+
...O == null ? void 0 : O.header,
|
|
568
|
+
cell: Ge
|
|
566
569
|
},
|
|
567
570
|
body: {
|
|
568
|
-
...
|
|
569
|
-
...
|
|
570
|
-
...
|
|
571
|
+
...Yt,
|
|
572
|
+
...O == null ? void 0 : O.body,
|
|
573
|
+
...Re()
|
|
571
574
|
}
|
|
572
|
-
}), [
|
|
575
|
+
}), [O, Ge, Re]), Qt = a(() => {
|
|
573
576
|
var e;
|
|
574
|
-
if ((
|
|
575
|
-
const t =
|
|
576
|
-
(
|
|
577
|
+
if ((X == null ? void 0 : X.length) > 5 && (p != null && p.current)) {
|
|
578
|
+
const t = X.reduce(
|
|
579
|
+
(r, o) => (o.fixed && (r += o.width), r),
|
|
577
580
|
0
|
|
578
|
-
), s = (e =
|
|
581
|
+
), s = (e = p == null ? void 0 : p.current) == null ? void 0 : e.clientWidth;
|
|
579
582
|
return t > s - 300;
|
|
580
583
|
}
|
|
581
584
|
return !1;
|
|
582
|
-
}, [
|
|
583
|
-
return /* @__PURE__ */
|
|
585
|
+
}, [X]);
|
|
586
|
+
return /* @__PURE__ */ n.jsxs(
|
|
584
587
|
"div",
|
|
585
588
|
{
|
|
586
|
-
className:
|
|
587
|
-
fullscreen:
|
|
589
|
+
className: he("bitzTableBlock", {
|
|
590
|
+
fullscreen: i.fullscreen
|
|
588
591
|
}),
|
|
589
|
-
style:
|
|
590
|
-
...
|
|
592
|
+
style: It,
|
|
593
|
+
...rt,
|
|
591
594
|
children: [
|
|
592
|
-
!
|
|
593
|
-
/* @__PURE__ */
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
595
|
+
!z && /* @__PURE__ */ n.jsxs("div", { ref: d, className: _t, style: Dt, children: [
|
|
596
|
+
/* @__PURE__ */ n.jsxs("div", { className: "bitzTableContainerBody", ref: p, children: [
|
|
597
|
+
ut && /* @__PURE__ */ n.jsxs("div", { className: "bitzTableToolbarBlock", children: [
|
|
598
|
+
dt || /* @__PURE__ */ n.jsx("div", {}),
|
|
599
|
+
ht,
|
|
600
|
+
ft
|
|
598
601
|
] }),
|
|
599
|
-
/* @__PURE__ */
|
|
602
|
+
/* @__PURE__ */ n.jsx(
|
|
600
603
|
"div",
|
|
601
604
|
{
|
|
602
605
|
className: "stretchLine",
|
|
603
|
-
ref:
|
|
606
|
+
ref: Pe,
|
|
604
607
|
style: {
|
|
605
|
-
background:
|
|
608
|
+
background: P.colorPrimary,
|
|
606
609
|
bottom: 0
|
|
607
610
|
}
|
|
608
611
|
}
|
|
609
612
|
),
|
|
610
|
-
/* @__PURE__ */
|
|
611
|
-
|
|
613
|
+
/* @__PURE__ */ n.jsxs(
|
|
614
|
+
bs,
|
|
612
615
|
{
|
|
613
|
-
enabledRowDragSort:
|
|
614
|
-
dataSource:
|
|
615
|
-
mergeRowKey:
|
|
616
|
-
onDragEnd:
|
|
616
|
+
enabledRowDragSort: J,
|
|
617
|
+
dataSource: ce,
|
|
618
|
+
mergeRowKey: Ve,
|
|
619
|
+
onDragEnd: Gt,
|
|
617
620
|
children: [
|
|
618
|
-
|
|
619
|
-
|
|
621
|
+
Qt && /* @__PURE__ */ n.jsx(
|
|
622
|
+
Xt,
|
|
620
623
|
{
|
|
621
624
|
closable: !0,
|
|
622
625
|
type: "error",
|
|
623
626
|
message: "表格固定列的宽度超过表格宽度,影响表格显示效果;请重新拖拽列宽度或点击表格设置调整固定列配置。"
|
|
624
627
|
}
|
|
625
628
|
),
|
|
626
|
-
/* @__PURE__ */
|
|
627
|
-
|
|
629
|
+
/* @__PURE__ */ n.jsx(
|
|
630
|
+
Zt,
|
|
628
631
|
{
|
|
629
|
-
...
|
|
630
|
-
bordered:
|
|
631
|
-
columns:
|
|
632
|
-
dataSource:
|
|
632
|
+
...c,
|
|
633
|
+
bordered: oe,
|
|
634
|
+
columns: X,
|
|
635
|
+
dataSource: ce,
|
|
633
636
|
loading: !1,
|
|
634
637
|
pagination: !1,
|
|
635
|
-
scroll: { ...
|
|
636
|
-
expandable:
|
|
637
|
-
rowSelection:
|
|
638
|
-
onRow:
|
|
639
|
-
rowHoverable:
|
|
640
|
-
rowClassName:
|
|
638
|
+
scroll: { ...ae, ...Pt },
|
|
639
|
+
expandable: Ot,
|
|
640
|
+
rowSelection: pt,
|
|
641
|
+
onRow: Vt,
|
|
642
|
+
rowHoverable: yt,
|
|
643
|
+
rowClassName: Rt,
|
|
641
644
|
className: "bitzTable",
|
|
642
|
-
components:
|
|
643
|
-
rowKey:
|
|
644
|
-
onChange:
|
|
645
|
-
ref:
|
|
645
|
+
components: Jt,
|
|
646
|
+
rowKey: Ve,
|
|
647
|
+
onChange: kt,
|
|
648
|
+
ref: Q
|
|
646
649
|
}
|
|
647
650
|
)
|
|
648
651
|
]
|
|
649
652
|
}
|
|
650
653
|
)
|
|
651
654
|
] }),
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
/* @__PURE__ */
|
|
655
|
-
|
|
655
|
+
Z && !!K && /* @__PURE__ */ n.jsxs("div", { className: "bitzTablePagination", ref: v, children: [
|
|
656
|
+
De,
|
|
657
|
+
/* @__PURE__ */ n.jsx(
|
|
658
|
+
At,
|
|
656
659
|
{
|
|
657
660
|
size: "small",
|
|
658
|
-
enableControl:
|
|
659
|
-
pagination:
|
|
660
|
-
total:
|
|
661
|
-
dataSource:
|
|
662
|
-
resetPage:
|
|
661
|
+
enableControl: lt,
|
|
662
|
+
pagination: B,
|
|
663
|
+
total: K,
|
|
664
|
+
dataSource: T,
|
|
665
|
+
resetPage: mt,
|
|
663
666
|
hideTotalText: !0,
|
|
664
|
-
paginationEmit:
|
|
667
|
+
paginationEmit: zt
|
|
665
668
|
}
|
|
666
669
|
)
|
|
667
670
|
] }),
|
|
668
|
-
!
|
|
671
|
+
!Z && !!y && !!K && /* @__PURE__ */ n.jsx("div", { className: "bitzTablePagination", ref: v, children: De })
|
|
669
672
|
] }),
|
|
670
|
-
|
|
671
|
-
(u || !!(
|
|
673
|
+
z && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
674
|
+
(u || !!(T != null && T.length)) && /* @__PURE__ */ n.jsx(n.Fragment, { children: je ? (
|
|
672
675
|
// @ts-ignore
|
|
673
|
-
/* @__PURE__ */
|
|
674
|
-
|
|
676
|
+
/* @__PURE__ */ n.jsx(
|
|
677
|
+
ts,
|
|
675
678
|
{
|
|
676
|
-
onRefresh: async () => !u &&
|
|
677
|
-
children:
|
|
679
|
+
onRefresh: async () => !u && je(),
|
|
680
|
+
children: Ie
|
|
678
681
|
}
|
|
679
682
|
)
|
|
680
|
-
) :
|
|
681
|
-
!u && /* @__PURE__ */
|
|
682
|
-
/* @__PURE__ */
|
|
683
|
-
|
|
683
|
+
) : Ie }),
|
|
684
|
+
!u && /* @__PURE__ */ n.jsx(Ft, { data: T, title: ct, img: at }),
|
|
685
|
+
/* @__PURE__ */ n.jsx(
|
|
686
|
+
Et,
|
|
684
687
|
{
|
|
685
688
|
className: "tableMobileDrawer",
|
|
686
|
-
open:
|
|
689
|
+
open: Ct,
|
|
687
690
|
placement: "bottom",
|
|
688
691
|
height: "auto",
|
|
689
692
|
closable: !1,
|
|
690
|
-
onClose:
|
|
691
|
-
children: /* @__PURE__ */
|
|
692
|
-
/* @__PURE__ */
|
|
693
|
+
onClose: He,
|
|
694
|
+
children: /* @__PURE__ */ n.jsxs("div", { className: "drawerBox", children: [
|
|
695
|
+
/* @__PURE__ */ n.jsx("div", { className: "boxBody", children: gt ? /* @__PURE__ */ n.jsx("div", { className: "operaList", children: /* @__PURE__ */ n.jsx(vt, {}) }) : ie.map((e, t) => /* @__PURE__ */ n.jsx(
|
|
693
696
|
"div",
|
|
694
697
|
{
|
|
695
698
|
className: "operaList",
|
|
696
|
-
onClick: () =>
|
|
699
|
+
onClick: () => jt(e, t),
|
|
697
700
|
...e.danger && {
|
|
698
|
-
style: { color:
|
|
701
|
+
style: { color: P.colorError }
|
|
699
702
|
},
|
|
700
703
|
children: e.label
|
|
701
704
|
},
|
|
702
705
|
t
|
|
703
706
|
)) }),
|
|
704
|
-
/* @__PURE__ */
|
|
705
|
-
/* @__PURE__ */
|
|
707
|
+
/* @__PURE__ */ n.jsx("div", { className: "boxLine" }),
|
|
708
|
+
/* @__PURE__ */ n.jsx("div", { className: "boxFooter", onClick: He, children: it })
|
|
706
709
|
] })
|
|
707
710
|
}
|
|
708
711
|
)
|
|
@@ -711,7 +714,7 @@ function bs({
|
|
|
711
714
|
}
|
|
712
715
|
);
|
|
713
716
|
}
|
|
714
|
-
const
|
|
717
|
+
const rr = (Z) => /* @__PURE__ */ n.jsx(ss, { initValue: Z, children: /* @__PURE__ */ n.jsx(zs, { ...Z }) });
|
|
715
718
|
export {
|
|
716
|
-
|
|
719
|
+
rr as default
|
|
717
720
|
};
|