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