bitz-react-admin-ui 2.1.5 → 2.1.7
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/dayjs.min.mjs +2 -5
- package/dist/_virtual/index.mjs +2 -2
- package/dist/_virtual/index2.mjs +2 -2
- package/dist/components/BitzCalendar/index.mjs +1 -1
- package/dist/components/BitzDayJs/index.mjs +1 -1
- package/dist/components/BitzFuiCalendar/BitzFuiCalendarStore.mjs +1 -1
- package/dist/components/BitzFuiCalendar/CalendarAgendum.mjs +1 -1
- package/dist/components/BitzFuiCalendar/CalendarAgendumItem.mjs +1 -1
- package/dist/components/BitzFuiCalendar/CalendarHeadItem.mjs +1 -1
- package/dist/components/BitzFuiCalendar/CalendarToolbar.mjs +1 -1
- package/dist/components/BitzFuiCalendar/ColumnData.mjs +1 -1
- package/dist/components/BitzMeetingTime/BitzMeetingTimeItem.mjs +1 -1
- package/dist/components/BitzMeetingTime/index.mjs +1 -1
- package/dist/components/BitzTable/Dropdown/index.mjs +16 -15
- package/dist/components/BitzTable/Store/index.d.ts +11 -2
- package/dist/components/BitzTable/Store/index.mjs +121 -114
- package/dist/components/BitzTable/Store/utils/index.mjs +24 -24
- package/dist/components/BitzTable/Table/index.d.ts +3 -1
- package/dist/components/BitzTable/Table/index.mjs +226 -229
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.d.ts +4 -2
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.mjs +116 -106
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.mjs +24 -25
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.d.ts +10 -4
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.mjs +58 -50
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.d.ts +0 -4
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.mjs +45 -28
- package/dist/components/BitzTable/ToolBar/index.d.ts +6 -3
- package/dist/components/BitzTable/index.d.ts +2 -2
- package/dist/node_modules/.store/classnames@2.5.1/node_modules/classnames/index.mjs +1 -1
- package/dist/node_modules/.store/dayjs@1.11.10/node_modules/dayjs/dayjs.min.mjs +292 -292
- package/dist/node_modules/.store/dayjs@1.11.10/node_modules/dayjs/locale/zh-cn.mjs +13 -13
- package/dist/node_modules/.store/prop-types@15.8.1/node_modules/prop-types/index.mjs +1 -1
- package/dist/style.css +1 -1
- package/dist/utils/time.mjs +1 -1
- package/package.json +1 -1
- package/dist/_virtual/dayjs.min2.mjs +0 -4
|
@@ -1,96 +1,93 @@
|
|
|
1
1
|
import { j as o } 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
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
2
|
+
import { useContext as ge, useState as H, useRef as T, useEffect as X, useMemo as c, useCallback as we } from "react";
|
|
3
|
+
import { isMobile as J } from "../../../node_modules/.store/react-device-detect@2.2.3/node_modules/react-device-detect/dist/lib.mjs";
|
|
4
|
+
import { Table as Z, Skeleton as lt } from "antd";
|
|
5
|
+
import Q from "../../../node_modules/.store/classnames@2.5.1/node_modules/classnames/index.mjs";
|
|
6
|
+
import ct from "../../BitzDrawer/index.mjs";
|
|
7
|
+
import it from "../../BitzPagination/index.mjs";
|
|
8
|
+
import at from "../../BitzNoData/index.mjs";
|
|
9
9
|
import "../../BitzList/index.less.mjs";
|
|
10
|
-
import
|
|
10
|
+
import dt from "../../BitzList/List.mjs";
|
|
11
11
|
import "../../BitzPullRefresh/style/index.less.mjs";
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import { loopFilter as
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import vt from "../../../node_modules/.store/antd@5.16.2/node_modules/antd/es/table/ExpandIcon.mjs";
|
|
12
|
+
import ht from "../../BitzPullRefresh/PullRefresh.mjs";
|
|
13
|
+
import ut, { BitzTableContext as ft } from "../Store/index.mjs";
|
|
14
|
+
import { loopFilter as mt, columnSort as bt, genColumnKey as Ct } from "../Store/utils/index.mjs";
|
|
15
|
+
import Y from "../../../node_modules/.store/ahooks@3.7.11/node_modules/ahooks/es/useSize/index.mjs";
|
|
16
|
+
import yt from "../ActionCol/style.mjs";
|
|
17
|
+
import xt from "../../BitzTheme/index.mjs";
|
|
18
|
+
import gt from "../../../node_modules/.store/antd@5.16.2/node_modules/antd/es/table/ExpandIcon.mjs";
|
|
20
19
|
import "../../../node_modules/.store/antd@5.16.2/node_modules/antd/es/config-provider/index.mjs";
|
|
21
|
-
import
|
|
22
|
-
import { getColumnsWithTool as
|
|
23
|
-
import { getCssVar as
|
|
20
|
+
import wt from "../../../node_modules/.store/antd@5.16.2/node_modules/antd/locale/en_US.mjs";
|
|
21
|
+
import { getColumnsWithTool as Bt, loopBuildSkeleton as zt } from "./utils.mjs";
|
|
22
|
+
import { getCssVar as jt } from "./style.mjs";
|
|
24
23
|
import "./index.less.mjs";
|
|
25
|
-
import { ConfigContext as
|
|
26
|
-
import
|
|
27
|
-
const
|
|
28
|
-
function
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
showPagination: ke = !0,
|
|
32
|
-
height: L,
|
|
24
|
+
import { ConfigContext as vt } from "../../../node_modules/.store/antd@5.16.2/node_modules/antd/es/config-provider/context.mjs";
|
|
25
|
+
import Nt from "../../../node_modules/.store/lodash-es@4.17.21/node_modules/lodash-es/at.mjs";
|
|
26
|
+
const Be = [Z.SELECTION_COLUMN, Z.EXPAND_COLUMN];
|
|
27
|
+
function kt({
|
|
28
|
+
showPagination: W = !0,
|
|
29
|
+
height: S,
|
|
33
30
|
dataSource: d = [],
|
|
34
|
-
total:
|
|
31
|
+
total: A = 0,
|
|
35
32
|
columns: N,
|
|
36
|
-
loading:
|
|
37
|
-
skeletonNum:
|
|
33
|
+
loading: i = !1,
|
|
34
|
+
skeletonNum: E = {
|
|
38
35
|
pc: 10,
|
|
39
36
|
mobile: 10
|
|
40
37
|
},
|
|
41
|
-
skeletonRender:
|
|
42
|
-
skeletonRowNum:
|
|
43
|
-
skeletonRowsWidth:
|
|
38
|
+
skeletonRender: ee,
|
|
39
|
+
skeletonRowNum: ze = 4,
|
|
40
|
+
skeletonRowsWidth: je = ["35%", "100%", "100%", "60%"],
|
|
44
41
|
// mobileLoadEmit,
|
|
45
|
-
mobileRefreshEmit:
|
|
46
|
-
operationFilter:
|
|
47
|
-
enableControlPage:
|
|
48
|
-
pagination:
|
|
42
|
+
mobileRefreshEmit: te,
|
|
43
|
+
operationFilter: K,
|
|
44
|
+
enableControlPage: ve,
|
|
45
|
+
pagination: b,
|
|
49
46
|
paginationEmit: R = () => {
|
|
50
47
|
},
|
|
51
|
-
mobilePageHeight:
|
|
52
|
-
mobileCancelText:
|
|
53
|
-
noDataTitle:
|
|
54
|
-
noDataImg:
|
|
55
|
-
color:
|
|
56
|
-
size:
|
|
57
|
-
showTableTool:
|
|
58
|
-
tableAction:
|
|
59
|
-
tableToolbar:
|
|
60
|
-
selectionBar:
|
|
61
|
-
scroll:
|
|
62
|
-
components:
|
|
63
|
-
expandable:
|
|
48
|
+
mobilePageHeight: pt = 500,
|
|
49
|
+
mobileCancelText: Ne = "取消",
|
|
50
|
+
noDataTitle: ke,
|
|
51
|
+
noDataImg: pe,
|
|
52
|
+
color: Tt,
|
|
53
|
+
size: re,
|
|
54
|
+
showTableTool: Te = !0,
|
|
55
|
+
tableAction: Se,
|
|
56
|
+
tableToolbar: Le,
|
|
57
|
+
selectionBar: Me,
|
|
58
|
+
scroll: h,
|
|
59
|
+
components: L,
|
|
60
|
+
expandable: C,
|
|
64
61
|
rowSelection: z,
|
|
65
|
-
resetPage:
|
|
66
|
-
...
|
|
62
|
+
resetPage: We,
|
|
63
|
+
...a
|
|
67
64
|
}) {
|
|
68
|
-
var
|
|
69
|
-
const { token:
|
|
70
|
-
|
|
65
|
+
var ye;
|
|
66
|
+
const { token: g } = xt.useToken(), { Table: l } = g, { tableSpaceBetweenPage: oe = 10 } = l, { gap: Re } = yt(), { showColumnBorder: Pe, hideRowBorder: ne, rowHoverable: De, ...f } = ge(ft), [k, se] = H(!1), $ = T(void 0), V = T(0), O = T(0), [He, I] = H(!1), [m, Ae] = H([]);
|
|
67
|
+
X(() => {
|
|
71
68
|
let e = [...d];
|
|
72
|
-
(
|
|
69
|
+
(b == null ? void 0 : b.page) !== 1 && (e = [...m, ...e]), Ae(e);
|
|
73
70
|
}, [d]);
|
|
74
|
-
const
|
|
71
|
+
const Ee = c(() => !!(m != null && m.length) && (m == null ? void 0 : m.length) >= A, [m, A]), [Ke, $e] = H([]), Ve = (e, t) => {
|
|
75
72
|
var n;
|
|
76
|
-
const r = (n =
|
|
73
|
+
const r = (n = K == null ? void 0 : K(e, t)) == null ? void 0 : n.filter(
|
|
77
74
|
(s) => s.type !== "divider"
|
|
78
75
|
);
|
|
79
|
-
r != null && r.length && (
|
|
80
|
-
},
|
|
76
|
+
r != null && r.length && ($e(r), I(!0));
|
|
77
|
+
}, le = () => {
|
|
81
78
|
I(!1);
|
|
82
|
-
},
|
|
79
|
+
}, Oe = (e) => {
|
|
83
80
|
var t;
|
|
84
81
|
I(!1), (t = e.onClick) == null || t.call(e);
|
|
85
82
|
};
|
|
86
|
-
|
|
83
|
+
X(() => (document == null || document.addEventListener("fullscreenchange", (e) => {
|
|
87
84
|
var t, r, n;
|
|
88
|
-
(t = e.target) != null && t.classList.contains("bitzTableBlock") && (
|
|
85
|
+
(t = e.target) != null && t.classList.contains("bitzTableBlock") && (se(!!document.fullscreenElement), (n = (r = document.fullscreenElement) == null ? void 0 : r.classList) != null && n.contains("bitzTableBlock") || se(!1));
|
|
89
86
|
}), document == null ? void 0 : document.removeEventListener("fullscreenchange", () => {
|
|
90
87
|
})), []);
|
|
91
|
-
const
|
|
88
|
+
const w = T(null), _ = Y(w), ce = T(null), q = Y(ce), ie = T(null), p = Y(ie), Ie = () => {
|
|
92
89
|
var r;
|
|
93
|
-
const e = (r =
|
|
90
|
+
const e = (r = w.current) == null ? void 0 : r.querySelectorAll(
|
|
94
91
|
"& > .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)"
|
|
95
92
|
), t = [];
|
|
96
93
|
if (e == null || e.forEach((n) => {
|
|
@@ -99,96 +96,96 @@ function Lt({
|
|
|
99
96
|
((s = n.querySelector("& > .operationCol .actionGroup")) == null ? void 0 : s.clientWidth) || 0
|
|
100
97
|
);
|
|
101
98
|
}), t.length)
|
|
102
|
-
return Math.ceil(Math.max(...t)) +
|
|
103
|
-
},
|
|
104
|
-
var
|
|
105
|
-
const e = (
|
|
99
|
+
return Math.ceil(Math.max(...t)) + Re * 2;
|
|
100
|
+
}, ae = () => {
|
|
101
|
+
var u, y, v;
|
|
102
|
+
const e = (u = w.current) == null ? void 0 : u.querySelector(
|
|
106
103
|
".ant-table-body"
|
|
107
|
-
), t = e == null ? void 0 : e.clientWidth, n = ((e == null ? void 0 : e.offsetWidth) || 0) - t > 0, s = (
|
|
104
|
+
), t = e == null ? void 0 : e.clientWidth, n = ((e == null ? void 0 : e.offsetWidth) || 0) - t > 0, s = (v = (y = w.current) == null ? void 0 : y.querySelector(
|
|
108
105
|
".ant-table-cell-scrollbar"
|
|
109
|
-
)) == null ? void 0 :
|
|
106
|
+
)) == null ? void 0 : v.offsetWidth;
|
|
110
107
|
return { tbodyWidth: t, scrollbarSize: s, hasScrollBar: n };
|
|
111
|
-
}, { y: F, hasScrollBar:
|
|
112
|
-
const { hasScrollBar: e, scrollbarSize: t } =
|
|
113
|
-
if (typeof
|
|
108
|
+
}, { y: F, hasScrollBar: P, scrollbarSize: M } = c(() => {
|
|
109
|
+
const { hasScrollBar: e, scrollbarSize: t } = ae();
|
|
110
|
+
if (typeof S > "u")
|
|
114
111
|
return {
|
|
115
112
|
hasScrollBar: e,
|
|
116
113
|
scrollbarSize: t
|
|
117
114
|
};
|
|
118
115
|
let r = 40, n = 40;
|
|
119
|
-
if (
|
|
120
|
-
const D = window.getComputedStyle(
|
|
116
|
+
if (w.current) {
|
|
117
|
+
const D = window.getComputedStyle(w.current);
|
|
121
118
|
r = parseInt(D.getPropertyValue("--cell-height")), n = parseInt(D.getPropertyValue("--toolbar-height"));
|
|
122
119
|
}
|
|
123
|
-
const s = (p == null ? void 0 : p.height) || 0,
|
|
124
|
-
return { y: (k ? window.innerHeight :
|
|
120
|
+
const s = (p == null ? void 0 : p.height) || 0, u = s ? oe : 0;
|
|
121
|
+
return { y: (k ? window.innerHeight : S) - s - u - n - r, hasScrollBar: e, scrollbarSize: t };
|
|
125
122
|
}, [
|
|
126
123
|
k,
|
|
127
|
-
|
|
124
|
+
S,
|
|
128
125
|
p == null ? void 0 : p.height,
|
|
129
126
|
_ == null ? void 0 : _.height,
|
|
130
127
|
q == null ? void 0 : q.height
|
|
131
|
-
]),
|
|
132
|
-
let e = (
|
|
133
|
-
return V.current && (e -= V.current), O.current && (e -= O.current * ($.current || 0)),
|
|
134
|
-
}, [
|
|
135
|
-
const t = e.length, r = e.filter((B) => B.width), s = r.map((B) => B.width).reduce((B,
|
|
136
|
-
let
|
|
137
|
-
if (
|
|
138
|
-
const B = window.getComputedStyle(
|
|
128
|
+
]), de = c(() => {
|
|
129
|
+
let e = (h == null ? void 0 : h.x) ?? 1e3;
|
|
130
|
+
return V.current && (e -= V.current), O.current && (e -= O.current * ($.current || 0)), h != null && h.x ? { x: e, y: h.y || F } : h != null && h.y ? { x: e, y: h.y } : { x: e, y: F };
|
|
131
|
+
}, [h, F, $.current]), _e = (e) => {
|
|
132
|
+
const t = e.length, r = e.filter((B) => B.width), s = r.map((B) => B.width).reduce((B, U) => B + U, 0);
|
|
133
|
+
let u = 0;
|
|
134
|
+
if (w.current) {
|
|
135
|
+
const B = window.getComputedStyle(w.current), U = parseInt(
|
|
139
136
|
B.getPropertyValue("--toolCell-paddingInline")
|
|
140
137
|
);
|
|
141
|
-
|
|
138
|
+
u = parseInt(B.getPropertyValue("--fontSize")) + 4 + 2 * U;
|
|
142
139
|
}
|
|
143
|
-
let
|
|
144
|
-
z && (
|
|
145
|
-
const { tbodyWidth:
|
|
146
|
-
return
|
|
147
|
-
},
|
|
148
|
-
const e = N ?? [], t = e.filter((
|
|
140
|
+
let y = 0;
|
|
141
|
+
z && (y += u), C && (y += u);
|
|
142
|
+
const { tbodyWidth: v } = ae(), x = parseInt(`${de.x}`) || 0, D = Math.max(x, v), xe = (parseInt(`${D}`) || 0) - s - y;
|
|
143
|
+
return xe >= 0 ? xe / (t - r.length) : void 0;
|
|
144
|
+
}, j = c(() => {
|
|
145
|
+
const e = N ?? [], t = e.filter((x) => !Be.includes(x)), { filterColumns: r, width: n, autoWidthColLength: s } = mt(
|
|
149
146
|
t,
|
|
150
|
-
|
|
147
|
+
f.columnsMap
|
|
151
148
|
);
|
|
152
149
|
V.current = Math.ceil(n), O.current = s;
|
|
153
|
-
const
|
|
154
|
-
if (
|
|
155
|
-
return
|
|
156
|
-
const
|
|
157
|
-
$.current = Math.ceil(
|
|
158
|
-
const
|
|
159
|
-
...
|
|
160
|
-
...
|
|
161
|
-
width:
|
|
150
|
+
const u = r.sort(bt(f.columnsMap));
|
|
151
|
+
if (J)
|
|
152
|
+
return u;
|
|
153
|
+
const y = _e(u);
|
|
154
|
+
$.current = Math.ceil(y ?? 0);
|
|
155
|
+
const v = u.map((x) => ({
|
|
156
|
+
...x,
|
|
157
|
+
...x.width ? {
|
|
158
|
+
width: x.useMaxWidth ? Ie() ?? x.width : x.width
|
|
162
159
|
} : {
|
|
163
160
|
// 给未设置width的列设置平均数
|
|
164
|
-
width:
|
|
161
|
+
width: y
|
|
165
162
|
}
|
|
166
163
|
}));
|
|
167
|
-
return
|
|
168
|
-
}, [N,
|
|
169
|
-
|
|
164
|
+
return Bt(e, v, z, C);
|
|
165
|
+
}, [N, f.columnsMap, f.sortKeyColumns]);
|
|
166
|
+
X(() => {
|
|
170
167
|
if (N && N.length > 0) {
|
|
171
168
|
const e = N.map(
|
|
172
169
|
(t) => (
|
|
173
170
|
// @ts-ignore
|
|
174
|
-
|
|
171
|
+
Ct((t == null ? void 0 : t.key) ?? (t == null ? void 0 : t.dataIndex), t == null ? void 0 : t.dataIndex)
|
|
175
172
|
)
|
|
176
173
|
);
|
|
177
|
-
|
|
174
|
+
f.setSortKeyColumns(e);
|
|
178
175
|
}
|
|
179
176
|
}, [N]);
|
|
180
|
-
const
|
|
181
|
-
const e = d == null ? void 0 : d.length, t = e > (
|
|
177
|
+
const he = c(() => zt(j, Be), [j]), qe = c(() => i ? he : j, [i, j, he]), ue = c(() => {
|
|
178
|
+
const e = d == null ? void 0 : d.length, t = e > (E.pc ?? 10) ? e >= 20 ? 20 : e : E.pc ?? 10;
|
|
182
179
|
return Array.from({ length: t }).map((n, s) => ({
|
|
183
180
|
key: `${Date.now()}${s}`
|
|
184
181
|
}));
|
|
185
|
-
}, [d]),
|
|
186
|
-
if (
|
|
182
|
+
}, [d]), Fe = c(() => i ? ue : d, [i, d, ue]), { table: G, locale: Ge = wt } = ge(vt), Ue = { ...Ge.Table }, Xe = ((ye = G == null ? void 0 : G.expandable) == null ? void 0 : ye.expandIcon) || (C == null ? void 0 : C.expandIcon) || gt(Ue), fe = c(() => {
|
|
183
|
+
if (C)
|
|
187
184
|
return {
|
|
188
|
-
...
|
|
185
|
+
...C,
|
|
189
186
|
expandedRowRender: () => /* @__PURE__ */ o.jsx(o.Fragment, {}),
|
|
190
187
|
expandIcon: (e) => {
|
|
191
|
-
const t =
|
|
188
|
+
const t = Xe(e);
|
|
192
189
|
return {
|
|
193
190
|
...t,
|
|
194
191
|
props: {
|
|
@@ -196,77 +193,72 @@ function Lt({
|
|
|
196
193
|
disabled: !0,
|
|
197
194
|
style: {
|
|
198
195
|
...t.props.style,
|
|
199
|
-
backgroundColor:
|
|
196
|
+
backgroundColor: g.colorBgContainerDisabled
|
|
200
197
|
}
|
|
201
198
|
}
|
|
202
199
|
};
|
|
203
200
|
}
|
|
204
201
|
};
|
|
205
|
-
}, [
|
|
202
|
+
}, [C]), Je = c(() => i ? fe : C, [i, C, fe]), me = c(() => {
|
|
206
203
|
if (z)
|
|
207
204
|
return {
|
|
208
205
|
...z,
|
|
209
206
|
selectedRowKeys: [],
|
|
210
207
|
getCheckboxProps: () => ({ disabled: !0 })
|
|
211
208
|
};
|
|
212
|
-
}, [z]),
|
|
209
|
+
}, [z]), Qe = c(() => i ? me : z, [i, z, me]), Ye = c(() => i ? void 0 : a.rowKey, [i, a.rowKey]), be = c(() => `${re ?? f.stylesConfig.size}BitzTable`, [re, f.stylesConfig.size]), Ze = we(
|
|
213
210
|
(e, t) => {
|
|
214
211
|
var n;
|
|
215
|
-
if (!
|
|
212
|
+
if (!a.onRow)
|
|
216
213
|
return {};
|
|
217
|
-
const r = (n =
|
|
214
|
+
const r = (n = a.onRow) == null ? void 0 : n.call(a, e, t);
|
|
218
215
|
return r.onClick && (r.className = "rowPointerCursor"), r;
|
|
219
216
|
},
|
|
220
|
-
[
|
|
221
|
-
),
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
"--container-bgColor": x.colorBgContainer
|
|
232
|
-
}), [x.colorBgContainer]), lt = l(() => {
|
|
233
|
-
const e = re ?? w.zebra, t = k ? "100%" : L;
|
|
234
|
-
let r;
|
|
235
|
-
return (G ?? 0) > 0 && (r = G), pt({
|
|
236
|
-
height: t,
|
|
237
|
-
evenRowBgColor: e ? c == null ? void 0 : c.evenRowBgColor : x.colorBgContainer,
|
|
238
|
-
colorBgContainer: x.colorBgContainer,
|
|
239
|
-
table: c,
|
|
240
|
-
gap: le,
|
|
241
|
-
borderColor: (c == null ? void 0 : c.borderColor) || x.colorBorderSecondary,
|
|
242
|
-
scrollbarWidth: r,
|
|
243
|
-
other: i.style
|
|
244
|
-
});
|
|
245
|
-
}, [
|
|
246
|
-
i.style,
|
|
217
|
+
[a.onRow]
|
|
218
|
+
), et = c(() => Q(
|
|
219
|
+
"bitzTableContainer",
|
|
220
|
+
{ hideBorder: ne },
|
|
221
|
+
{ hasScrollBar: P },
|
|
222
|
+
be,
|
|
223
|
+
a.className
|
|
224
|
+
), [
|
|
225
|
+
a.className,
|
|
226
|
+
be,
|
|
227
|
+
P,
|
|
247
228
|
k,
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
229
|
+
ne
|
|
230
|
+
]), tt = c(() => ({
|
|
231
|
+
"--container-bgColor": g.colorBgContainer
|
|
232
|
+
}), [g.colorBgContainer]), rt = c(() => {
|
|
233
|
+
const e = k ? "100%" : S;
|
|
234
|
+
let t;
|
|
235
|
+
return (M ?? 0) > 0 && (t = M), jt({
|
|
236
|
+
height: e,
|
|
237
|
+
evenRowBgColor: f.zebra ? l == null ? void 0 : l.evenRowBgColor : g.colorBgContainer,
|
|
238
|
+
colorBgContainer: g.colorBgContainer,
|
|
239
|
+
table: l,
|
|
240
|
+
gap: oe,
|
|
241
|
+
borderColor: (l == null ? void 0 : l.borderColor) || g.colorBorderSecondary,
|
|
242
|
+
scrollbarWidth: t,
|
|
243
|
+
other: a.style
|
|
244
|
+
});
|
|
245
|
+
}, [a.style, k, S, l, f == null ? void 0 : f.zebra, M]), ot = we(
|
|
254
246
|
(e, t, r) => {
|
|
255
247
|
const n = t % 2 === 0 ? "oddRow" : "evenRow";
|
|
256
|
-
if (
|
|
257
|
-
const s =
|
|
258
|
-
return
|
|
248
|
+
if (a.rowClassName) {
|
|
249
|
+
const s = a.rowClassName(e, t, r);
|
|
250
|
+
return Q(n, s);
|
|
259
251
|
}
|
|
260
252
|
return n;
|
|
261
253
|
},
|
|
262
|
-
[
|
|
263
|
-
),
|
|
264
|
-
|
|
254
|
+
[a.rowClassName]
|
|
255
|
+
), Ce = /* @__PURE__ */ o.jsx(
|
|
256
|
+
dt,
|
|
265
257
|
{
|
|
266
|
-
finished:
|
|
258
|
+
finished: Ee,
|
|
267
259
|
onLoad: async () => (
|
|
268
260
|
// @ts-ignore
|
|
269
|
-
!
|
|
261
|
+
!i && (R == null ? void 0 : R((b == null ? void 0 : b.page) + 1, b == null ? void 0 : b.size))
|
|
270
262
|
),
|
|
271
263
|
loadingText: "加载中...",
|
|
272
264
|
finishedText: "没有更多了",
|
|
@@ -275,21 +267,21 @@ function Lt({
|
|
|
275
267
|
"div",
|
|
276
268
|
{
|
|
277
269
|
className: "mobileList",
|
|
278
|
-
style: { backgroundColor:
|
|
270
|
+
style: { backgroundColor: l == null ? void 0 : l.mobileListBgColor },
|
|
279
271
|
children: [
|
|
280
|
-
|
|
272
|
+
m == null ? void 0 : m.map((e, t) => /* @__PURE__ */ o.jsx(
|
|
281
273
|
"div",
|
|
282
274
|
{
|
|
283
275
|
className: "listItem",
|
|
284
|
-
style: { backgroundColor:
|
|
285
|
-
onClick: () =>
|
|
286
|
-
children:
|
|
276
|
+
style: { backgroundColor: l == null ? void 0 : l.listItemBgColor },
|
|
277
|
+
onClick: () => Ve(e, t),
|
|
278
|
+
children: j == null ? void 0 : j.map((r, n) => {
|
|
287
279
|
var s;
|
|
288
280
|
return !(r != null && r.mobileHide) && /* @__PURE__ */ o.jsxs(
|
|
289
281
|
"div",
|
|
290
282
|
{
|
|
291
283
|
className: "row",
|
|
292
|
-
style: { color:
|
|
284
|
+
style: { color: g.colorText },
|
|
293
285
|
children: [
|
|
294
286
|
!r.mobileHideLabel && /* @__PURE__ */ o.jsxs("div", { className: "label", children: [
|
|
295
287
|
`${r.title}`,
|
|
@@ -297,7 +289,7 @@ function Lt({
|
|
|
297
289
|
] }),
|
|
298
290
|
/* @__PURE__ */ o.jsx("div", { className: "value", children: ((s = r == null ? void 0 : r.render) == null ? void 0 : s.call(
|
|
299
291
|
r,
|
|
300
|
-
|
|
292
|
+
Nt(e, (r == null ? void 0 : r.dataIndex) || ""),
|
|
301
293
|
e,
|
|
302
294
|
t
|
|
303
295
|
)) || (e == null ? void 0 : e[r.dataIndex]) })
|
|
@@ -309,21 +301,21 @@ function Lt({
|
|
|
309
301
|
},
|
|
310
302
|
t
|
|
311
303
|
)),
|
|
312
|
-
Array.from({ length:
|
|
304
|
+
Array.from({ length: E.mobile ?? 2 }).map((e, t) => /* @__PURE__ */ o.jsx(
|
|
313
305
|
"div",
|
|
314
306
|
{
|
|
315
307
|
className: "listItem",
|
|
316
308
|
style: {
|
|
317
|
-
display:
|
|
318
|
-
backgroundColor:
|
|
309
|
+
display: i ? "block" : "none",
|
|
310
|
+
backgroundColor: l == null ? void 0 : l.listItemBgColor
|
|
319
311
|
},
|
|
320
|
-
children: /* @__PURE__ */ o.jsx("div", { className: "row", children:
|
|
321
|
-
|
|
312
|
+
children: /* @__PURE__ */ o.jsx("div", { className: "row", children: ee ? ee() : /* @__PURE__ */ o.jsx(
|
|
313
|
+
lt,
|
|
322
314
|
{
|
|
323
315
|
title: !1,
|
|
324
316
|
paragraph: {
|
|
325
|
-
rows:
|
|
326
|
-
width:
|
|
317
|
+
rows: ze,
|
|
318
|
+
width: je
|
|
327
319
|
},
|
|
328
320
|
active: !0
|
|
329
321
|
}
|
|
@@ -335,99 +327,104 @@ function Lt({
|
|
|
335
327
|
}
|
|
336
328
|
)
|
|
337
329
|
}
|
|
338
|
-
),
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
330
|
+
), nt = (e) => {
|
|
331
|
+
var r;
|
|
332
|
+
const t = { ...e };
|
|
333
|
+
return t.className.includes("ant-table-cell-fix-right") && !P && ((r = t.style) != null && r.right) && (t.style = {
|
|
334
|
+
...t.style,
|
|
335
|
+
right: t.style.right - (M || 0)
|
|
336
|
+
}), /* @__PURE__ */ o.jsx("th", { ...t });
|
|
337
|
+
}, st = c(() => ({
|
|
338
|
+
...L,
|
|
339
|
+
header: {
|
|
340
|
+
...L == null ? void 0 : L.header,
|
|
341
|
+
cell: nt
|
|
342
|
+
}
|
|
343
|
+
}), [L, P, M]);
|
|
348
344
|
return /* @__PURE__ */ o.jsxs(
|
|
349
345
|
"div",
|
|
350
346
|
{
|
|
351
|
-
className:
|
|
352
|
-
style:
|
|
347
|
+
className: Q("bitzTableBlock", { fullscreen: k }),
|
|
348
|
+
style: tt,
|
|
353
349
|
children: [
|
|
354
|
-
!
|
|
355
|
-
/* @__PURE__ */ o.jsxs("div", { className: "bitzTableContainerBody", ref:
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
350
|
+
!J && /* @__PURE__ */ o.jsxs("div", { ref: w, className: et, style: rt, children: [
|
|
351
|
+
/* @__PURE__ */ o.jsxs("div", { className: "bitzTableContainerBody", ref: ce, children: [
|
|
352
|
+
Te && /* @__PURE__ */ o.jsxs("div", { className: "bitzTableToolbarBlock", children: [
|
|
353
|
+
Se || /* @__PURE__ */ o.jsx("div", {}),
|
|
354
|
+
Le,
|
|
355
|
+
Me
|
|
360
356
|
] }),
|
|
361
357
|
/* @__PURE__ */ o.jsx(
|
|
362
|
-
|
|
358
|
+
Z,
|
|
363
359
|
{
|
|
364
|
-
...
|
|
365
|
-
bordered:
|
|
366
|
-
columns:
|
|
367
|
-
dataSource:
|
|
360
|
+
...a,
|
|
361
|
+
bordered: Pe,
|
|
362
|
+
columns: qe,
|
|
363
|
+
dataSource: Fe,
|
|
368
364
|
loading: !1,
|
|
369
365
|
pagination: !1,
|
|
370
|
-
scroll:
|
|
371
|
-
expandable:
|
|
372
|
-
rowSelection:
|
|
373
|
-
onRow:
|
|
374
|
-
|
|
366
|
+
scroll: de,
|
|
367
|
+
expandable: Je,
|
|
368
|
+
rowSelection: Qe,
|
|
369
|
+
onRow: Ze,
|
|
370
|
+
rowHoverable: De,
|
|
371
|
+
rowClassName: ot,
|
|
375
372
|
className: "bitzTable",
|
|
376
|
-
components:
|
|
377
|
-
rowKey:
|
|
373
|
+
components: st,
|
|
374
|
+
rowKey: Ye
|
|
378
375
|
}
|
|
379
376
|
)
|
|
380
377
|
] }),
|
|
381
|
-
|
|
382
|
-
|
|
378
|
+
W && /* @__PURE__ */ o.jsx(
|
|
379
|
+
it,
|
|
383
380
|
{
|
|
384
381
|
size: "small",
|
|
385
|
-
elRefInstance:
|
|
386
|
-
enableControl:
|
|
387
|
-
pagination:
|
|
388
|
-
total:
|
|
382
|
+
elRefInstance: ie,
|
|
383
|
+
enableControl: ve,
|
|
384
|
+
pagination: b,
|
|
385
|
+
total: A,
|
|
389
386
|
dataSource: d,
|
|
390
|
-
resetPage:
|
|
387
|
+
resetPage: We,
|
|
391
388
|
paginationEmit: R
|
|
392
389
|
}
|
|
393
390
|
)
|
|
394
391
|
] }),
|
|
395
|
-
|
|
396
|
-
(
|
|
392
|
+
J && /* @__PURE__ */ o.jsxs(o.Fragment, { children: [
|
|
393
|
+
(i || (d == null ? void 0 : d.length) > 0) && /* @__PURE__ */ o.jsx(o.Fragment, { children: te ? (
|
|
397
394
|
// @ts-ignore
|
|
398
395
|
/* @__PURE__ */ o.jsx(
|
|
399
|
-
|
|
396
|
+
ht,
|
|
400
397
|
{
|
|
401
|
-
onRefresh: async () => !
|
|
402
|
-
children:
|
|
398
|
+
onRefresh: async () => !i && te(),
|
|
399
|
+
children: Ce
|
|
403
400
|
}
|
|
404
401
|
)
|
|
405
|
-
) :
|
|
406
|
-
!
|
|
402
|
+
) : Ce }),
|
|
403
|
+
!i && /* @__PURE__ */ o.jsx(at, { data: d, title: ke, img: pe }),
|
|
407
404
|
/* @__PURE__ */ o.jsx(
|
|
408
|
-
|
|
405
|
+
ct,
|
|
409
406
|
{
|
|
410
407
|
className: "tableMobileDrawer",
|
|
411
|
-
open:
|
|
408
|
+
open: He,
|
|
412
409
|
placement: "bottom",
|
|
413
410
|
height: "auto",
|
|
414
411
|
closable: !1,
|
|
415
|
-
onClose:
|
|
412
|
+
onClose: le,
|
|
416
413
|
children: /* @__PURE__ */ o.jsxs("div", { className: "drawerBox", children: [
|
|
417
|
-
/* @__PURE__ */ o.jsx("div", { className: "boxBody", children:
|
|
414
|
+
/* @__PURE__ */ o.jsx("div", { className: "boxBody", children: Ke.map((e, t) => /* @__PURE__ */ o.jsx(
|
|
418
415
|
"div",
|
|
419
416
|
{
|
|
420
417
|
className: "operaList",
|
|
421
|
-
onClick: () =>
|
|
418
|
+
onClick: () => Oe(e),
|
|
422
419
|
...e.danger && {
|
|
423
|
-
style: { color:
|
|
420
|
+
style: { color: g.colorError }
|
|
424
421
|
},
|
|
425
422
|
children: e.label
|
|
426
423
|
},
|
|
427
424
|
t
|
|
428
425
|
)) }),
|
|
429
426
|
/* @__PURE__ */ o.jsx("div", { className: "boxLine" }),
|
|
430
|
-
/* @__PURE__ */ o.jsx("div", { className: "boxFooter", onClick:
|
|
427
|
+
/* @__PURE__ */ o.jsx("div", { className: "boxFooter", onClick: le, children: Ne })
|
|
431
428
|
] })
|
|
432
429
|
}
|
|
433
430
|
)
|
|
@@ -436,7 +433,7 @@ function Lt({
|
|
|
436
433
|
}
|
|
437
434
|
);
|
|
438
435
|
}
|
|
439
|
-
const
|
|
436
|
+
const tr = (W) => /* @__PURE__ */ o.jsx(ut, { initValue: W, children: /* @__PURE__ */ o.jsx(kt, { ...W }) });
|
|
440
437
|
export {
|
|
441
|
-
|
|
438
|
+
tr as default
|
|
442
439
|
};
|