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