bitz-react-admin-ui 2.7.1 → 2.7.3

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,4 +1,4 @@
1
- var s = { exports: {} };
1
+ var p = { exports: {} };
2
2
  export {
3
- s as __module
3
+ p as __module
4
4
  };
@@ -1,4 +1,4 @@
1
- var p = { exports: {} };
1
+ var s = { exports: {} };
2
2
  export {
3
- p as __module
3
+ s as __module
4
4
  };
@@ -1,7 +1,7 @@
1
- import { j as Pe } from "../../../node_modules/.store/react@18.3.1/node_modules/react/jsx-runtime.mjs";
1
+ import { j as je } from "../../../node_modules/.store/react@18.3.1/node_modules/react/jsx-runtime.mjs";
2
2
  import { Table as ue } from "antd";
3
3
  import N from "../../../hooks/useMergedState.mjs";
4
- import { createContext as ke, useRef as Re, useState as h, useContext as Le, useMemo as y, useEffect as S, useCallback as B } from "react";
4
+ import { createContext as ke, useRef as Re, useState as h, useContext as Le, useMemo as S, useEffect as g, useCallback as B } from "react";
5
5
  import { flattenColumns as Ue, genColumnKey as E } from "./utils/index.mjs";
6
6
  import { getUuid as Ae } from "../../../utils/uuid.mjs";
7
7
  import { BitzConfigContext as De } from "../../BitzConfigProvider/context.mjs";
@@ -23,7 +23,7 @@ const Ge = {
23
23
  ], de = 5;
24
24
  function _e(e) {
25
25
  var k, R, L, U, A, D, G, Z, _, F, W, X, q, Q, Y, $, p, ee, te, ne, ie, ae, oe, le, ce, fe, re;
26
- const K = Re(Ae()), [ye, Se] = h(!1), [ge, Ce] = h(!1), [me, we] = h(0), f = Le(De).Table, I = e.defaultSize ?? (f == null ? void 0 : f.defaultSize) ?? "lg", he = e.defaultZebra ?? (f == null ? void 0 : f.zebra) ?? !0, xe = e.defaultBordered ?? (f == null ? void 0 : f.bordered) ?? "row-column", Te = e.defaultPageSize ?? (f == null ? void 0 : f.pageSize) ?? 10, Ke = e.defaultOrderBy ?? (f == null ? void 0 : f.orderBy) ?? "desc", z = y(() => {
26
+ const K = Re(Ae()), [ye, Se] = h(!1), [ge, Ce] = h(!1), [me, we] = h(0), f = Le(De).Table, I = e.defaultSize ?? (f == null ? void 0 : f.defaultSize) ?? "lg", he = e.defaultZebra ?? (f == null ? void 0 : f.zebra) ?? !0, xe = e.defaultBordered ?? (f == null ? void 0 : f.bordered) ?? "row-column", Te = e.defaultPageSize ?? (f == null ? void 0 : f.pageSize) ?? 10, Ke = e.defaultOrderBy ?? (f == null ? void 0 : f.orderBy) ?? "desc", z = S(() => {
27
27
  var t;
28
28
  return u(
29
29
  {
@@ -47,131 +47,131 @@ function _e(e) {
47
47
  e.defaultOrderBy,
48
48
  f == null ? void 0 : f.orderBy,
49
49
  (k = e.stylesConfigState) == null ? void 0 : k.defaultValue
50
- ]), [g, J] = N(
50
+ ]), [C, J] = N(
51
51
  () => {
52
- var n, a, c;
53
- const { persistenceType: t, persistenceKey: i, onlineGet: l } = e.stylesConfigState || {};
54
- if (i && t && typeof window < "u" && t !== "online") {
52
+ var i, n, l;
53
+ const { persistenceType: t, persistenceKey: a, onlineGet: c } = e.stylesConfigState || {};
54
+ if (a && t && typeof window < "u" && t !== "online") {
55
55
  const o = window[t];
56
56
  try {
57
- const r = o == null ? void 0 : o.getItem(i);
57
+ const r = o == null ? void 0 : o.getItem(a);
58
58
  if (r)
59
- return (n = e == null ? void 0 : e.stylesConfigState) != null && n.defaultValue ? u(
59
+ return (i = e == null ? void 0 : e.stylesConfigState) != null && i.defaultValue ? u(
60
60
  JSON.parse(r),
61
- (a = e == null ? void 0 : e.stylesConfigState) == null ? void 0 : a.defaultValue
61
+ (n = e == null ? void 0 : e.stylesConfigState) == null ? void 0 : n.defaultValue
62
62
  ) : JSON.parse(r);
63
63
  } catch (r) {
64
64
  console.warn(r);
65
65
  }
66
66
  }
67
- return e.stylesConfig || ((c = e.stylesConfigState) == null ? void 0 : c.value) || z;
67
+ return e.stylesConfig || ((l = e.stylesConfigState) == null ? void 0 : l.value) || z;
68
68
  },
69
69
  {
70
70
  value: ((R = e.stylesConfigState) == null ? void 0 : R.value) || e.stylesConfig,
71
71
  onChange: ((L = e.stylesConfigState) == null ? void 0 : L.onChange) || e.onStylesConfigChange
72
72
  }
73
73
  );
74
- S(() => {
75
- var l, n;
76
- if (!((l = e.stylesConfigState) != null && l.persistenceKey) || !((n = e.stylesConfigState) != null && n.persistenceType) || typeof window > "u")
74
+ g(() => {
75
+ var c, i;
76
+ if (!((c = e.stylesConfigState) != null && c.persistenceKey) || !((i = e.stylesConfigState) != null && i.persistenceType) || typeof window > "u")
77
77
  return;
78
78
  const {
79
79
  persistenceType: t,
80
- persistenceKey: i
80
+ persistenceKey: a
81
81
  // onlineChange
82
82
  } = e.stylesConfigState;
83
83
  if (t !== "online") {
84
- const a = window[t];
84
+ const n = window[t];
85
85
  try {
86
- a == null || a.setItem(i, JSON.stringify(g));
87
- } catch (c) {
88
- console.warn(c), M();
86
+ n == null || n.setItem(a, JSON.stringify(C));
87
+ } catch (l) {
88
+ console.warn(l), M();
89
89
  }
90
90
  }
91
91
  }, [
92
92
  (U = e.stylesConfigState) == null ? void 0 : U.persistenceKey,
93
- g,
93
+ C,
94
94
  (A = e.stylesConfigState) == null ? void 0 : A.persistenceType
95
- ]), S(() => {
96
- var t, i, l;
97
- if ((t = e.stylesConfigState) != null && t.persistenceKey && ((i = e.stylesConfigState) == null ? void 0 : i.persistenceType) === "online") {
98
- const { onlineGet: n, persistenceKey: a } = e.stylesConfigState;
95
+ ]), g(() => {
96
+ var t, a, c;
97
+ if ((t = e.stylesConfigState) != null && t.persistenceKey && ((a = e.stylesConfigState) == null ? void 0 : a.persistenceType) === "online") {
98
+ const { onlineGet: i, persistenceKey: n } = e.stylesConfigState;
99
99
  try {
100
- (l = n == null ? void 0 : n(a)) == null || l.then((c) => {
100
+ (c = i == null ? void 0 : i(n)) == null || c.then((l) => {
101
101
  var r;
102
- const o = u(c ?? {}, (r = e == null ? void 0 : e.stylesConfigState) == null ? void 0 : r.value);
102
+ const o = u(l ?? {}, (r = e == null ? void 0 : e.stylesConfigState) == null ? void 0 : r.value);
103
103
  J(
104
104
  Object.keys(o).length ? o : z
105
105
  );
106
106
  });
107
- } catch (c) {
108
- console.warn(c);
107
+ } catch (l) {
108
+ console.warn(l);
109
109
  }
110
110
  }
111
111
  }, []);
112
- const s = y(() => (e.columns ?? []).filter(
112
+ const s = S(() => (e.columns ?? []).filter(
113
113
  (t) => !Ze.includes(t) && t.title
114
- ), [e.columns]), x = y(() => {
115
- var n;
114
+ ), [e.columns]), x = S(() => {
115
+ var i;
116
116
  const t = {
117
117
  fields: [],
118
118
  config: {
119
119
  key: "current",
120
120
  info: void 0
121
121
  }
122
- }, i = s.find((a) => {
123
- var c;
124
- return (c = a == null ? void 0 : a.children) == null ? void 0 : c.length;
125
- }), l = s.filter((a) => !a.isOperationCol);
126
- if (i)
127
- t.fields = Ue(l);
122
+ }, a = s.find((n) => {
123
+ var l;
124
+ return (l = n == null ? void 0 : n.children) == null ? void 0 : l.length;
125
+ }), c = s.filter((n) => !n.isOperationCol);
126
+ if (a)
127
+ t.fields = Ue(c);
128
128
  else {
129
- const a = [];
130
- l.forEach((c, o) => {
131
- const r = E(c, o);
132
- r && !c.exportHidden && a.push({
129
+ const n = [];
130
+ c.forEach((l, o) => {
131
+ const r = E(l, o);
132
+ r && !l.exportHidden && n.push({
133
133
  field: r,
134
- title: c.title,
134
+ title: l.title,
135
135
  show: !0
136
136
  });
137
- }), t.fields = a;
137
+ }), t.fields = n;
138
138
  }
139
- return (n = e == null ? void 0 : e.exportConfigState) != null && n.defaultValue ? u(t, e.exportConfigState.defaultValue) : t;
139
+ return (i = e == null ? void 0 : e.exportConfigState) != null && i.defaultValue ? u(t, e.exportConfigState.defaultValue) : t;
140
140
  }, [s]), [b, T] = N(
141
141
  () => {
142
- var n, a, c;
143
- const { persistenceType: t, persistenceKey: i, onlineGet: l } = e.exportConfigState || {};
144
- if (i && t && typeof window < "u" && t !== "online") {
142
+ var i, n, l;
143
+ const { persistenceType: t, persistenceKey: a, onlineGet: c } = e.exportConfigState || {};
144
+ if (a && t && typeof window < "u" && t !== "online") {
145
145
  const o = window[t];
146
146
  try {
147
- const r = o == null ? void 0 : o.getItem(i);
147
+ const r = o == null ? void 0 : o.getItem(a);
148
148
  if (r)
149
- return (n = e == null ? void 0 : e.exportConfigState) != null && n.defaultValue ? u(
149
+ return (i = e == null ? void 0 : e.exportConfigState) != null && i.defaultValue ? u(
150
150
  JSON.parse(r),
151
- (a = e == null ? void 0 : e.exportConfigState) == null ? void 0 : a.defaultValue
151
+ (n = e == null ? void 0 : e.exportConfigState) == null ? void 0 : n.defaultValue
152
152
  ) : JSON.parse(r);
153
153
  } catch (r) {
154
154
  console.warn(r);
155
155
  }
156
156
  }
157
- return e.exportConfig || ((c = e.exportConfigState) == null ? void 0 : c.value) || x;
157
+ return e.exportConfig || ((l = e.exportConfigState) == null ? void 0 : l.value) || x;
158
158
  },
159
159
  {
160
160
  value: ((D = e.exportConfigState) == null ? void 0 : D.value) || e.exportConfig,
161
161
  onChange: ((G = e.exportConfigState) == null ? void 0 : G.onChange) || e.onExportConfigChange
162
162
  }
163
163
  );
164
- S(() => {
165
- var n, a;
166
- const { persistenceType: t, persistenceKey: i, onlineGet: l } = e.exportConfigState || {};
167
- if (i && t && typeof window < "u" && t !== "online") {
168
- const c = window[t];
164
+ g(() => {
165
+ var i, n;
166
+ const { persistenceType: t, persistenceKey: a, onlineGet: c } = e.exportConfigState || {};
167
+ if (a && t && typeof window < "u" && t !== "online") {
168
+ const l = window[t];
169
169
  try {
170
- const o = c == null ? void 0 : c.getItem(i);
171
- o ? (n = e == null ? void 0 : e.exportConfigState) != null && n.defaultValue ? T(
170
+ const o = l == null ? void 0 : l.getItem(a);
171
+ o ? (i = e == null ? void 0 : e.exportConfigState) != null && i.defaultValue ? T(
172
172
  u(
173
173
  JSON.parse(o),
174
- (a = e == null ? void 0 : e.exportConfigState) == null ? void 0 : a.defaultValue
174
+ (n = e == null ? void 0 : e.exportConfigState) == null ? void 0 : n.defaultValue
175
175
  )
176
176
  ) : T(JSON.parse(o)) : T(x);
177
177
  } catch (o) {
@@ -182,95 +182,95 @@ function _e(e) {
182
182
  (Z = e.exportConfigState) == null ? void 0 : Z.persistenceKey,
183
183
  (_ = e.exportConfigState) == null ? void 0 : _.persistenceType,
184
184
  x
185
- ]), S(() => {
186
- var l, n;
187
- if (!((l = e.exportConfigState) != null && l.persistenceKey) || !((n = e.exportConfigState) != null && n.persistenceType) || typeof window > "u")
185
+ ]), g(() => {
186
+ var c, i;
187
+ if (!((c = e.exportConfigState) != null && c.persistenceKey) || !((i = e.exportConfigState) != null && i.persistenceType) || typeof window > "u")
188
188
  return;
189
189
  const {
190
190
  persistenceType: t,
191
- persistenceKey: i
191
+ persistenceKey: a
192
192
  // onlineChange
193
193
  } = e.exportConfigState;
194
194
  if (t !== "online") {
195
- const a = window[t];
195
+ const n = window[t];
196
196
  try {
197
- a == null || a.setItem(i, JSON.stringify(b));
198
- } catch (c) {
199
- console.warn(c), j();
197
+ n == null || n.setItem(a, JSON.stringify(b));
198
+ } catch (l) {
199
+ console.warn(l), P();
200
200
  }
201
201
  }
202
202
  }, [
203
203
  (F = e.exportConfigState) == null ? void 0 : F.persistenceKey,
204
204
  b,
205
205
  (W = e.exportConfigState) == null ? void 0 : W.persistenceType
206
- ]), S(() => {
207
- var t, i, l;
208
- if ((t = e.exportConfigState) != null && t.persistenceKey && ((i = e.exportConfigState) == null ? void 0 : i.persistenceType) === "online") {
209
- const { onlineGet: n, persistenceKey: a } = e.exportConfigState;
206
+ ]), g(() => {
207
+ var t, a, c;
208
+ if ((t = e.exportConfigState) != null && t.persistenceKey && ((a = e.exportConfigState) == null ? void 0 : a.persistenceType) === "online") {
209
+ const { onlineGet: i, persistenceKey: n } = e.exportConfigState;
210
210
  try {
211
- (l = n == null ? void 0 : n(a)) == null || l.then((c) => {
211
+ (c = i == null ? void 0 : i(n)) == null || c.then((l) => {
212
212
  var r;
213
- const o = u(c ?? {}, (r = e == null ? void 0 : e.exportConfigState) == null ? void 0 : r.value);
213
+ const o = u(l ?? {}, (r = e == null ? void 0 : e.exportConfigState) == null ? void 0 : r.value);
214
214
  T(
215
215
  Object.keys(o).length ? o : x
216
216
  );
217
217
  });
218
- } catch (c) {
219
- console.warn(c);
218
+ } catch (l) {
219
+ console.warn(l);
220
220
  }
221
221
  }
222
222
  }, []);
223
- const C = y(() => {
224
- var c;
225
- if ((c = e == null ? void 0 : e.columnsState) != null && c.defaultValue)
223
+ const d = S(() => {
224
+ var l;
225
+ if ((l = e == null ? void 0 : e.columnsState) != null && l.defaultValue)
226
226
  return e.columnsState.defaultValue;
227
- const t = s.filter((o) => o.fixed === "left").map((o, r) => ({ ...o, order: r })), i = s.filter((o) => o.fixed === "right").map((o, r) => ({ ...o, order: r })), l = s.filter((o) => !["left", "right"].includes(o.fixed)).map((o, r) => ({ ...o, order: r })), n = [...t, ...l, ...i], a = {};
228
- return n.forEach((o, r) => {
229
- const { order: m, width: We, fixed: Me, disabled: je } = o, se = E(o, r);
230
- se && (a[se] = {
227
+ const t = s.filter((o) => o.fixed === "left").map((o, r) => ({ ...o, order: r })), a = s.filter((o) => o.fixed === "right").map((o, r) => ({ ...o, order: r })), c = s.filter((o) => !["left", "right"].includes(o.fixed)).map((o, r) => ({ ...o, order: r })), i = [...t, ...c, ...a], n = {};
228
+ return i.forEach((o, r) => {
229
+ const { order: w, width: We, fixed: Me, disabled: Pe } = o, se = E(o, r);
230
+ se && (n[se] = {
231
231
  show: !0,
232
- order: m,
232
+ order: w,
233
233
  fixed: Me,
234
- disabled: je
234
+ disabled: Pe
235
235
  });
236
- }), a;
237
- }, [s]), [Oe, Ve] = h(!1), [d, w] = N(
236
+ }), n;
237
+ }, [s]), [Oe, Ve] = h(!1), [y, m] = N(
238
238
  () => {
239
- var n, a, c, o;
240
- const { persistenceType: t, persistenceKey: i, onlineGet: l } = e.columnsState || {};
241
- if (i && t && typeof window < "u" && t !== "online") {
239
+ var i, n, l, o;
240
+ const { persistenceType: t, persistenceKey: a, onlineGet: c } = e.columnsState || {};
241
+ if (a && t && typeof window < "u" && t !== "online") {
242
242
  const r = window[t];
243
243
  try {
244
- const m = r == null ? void 0 : r.getItem(i);
245
- if (m)
246
- return (n = e == null ? void 0 : e.columnsState) != null && n.defaultValue ? u(
247
- JSON.parse(m),
248
- (a = e == null ? void 0 : e.columnsState) == null ? void 0 : a.defaultValue
249
- ) : JSON.parse(m);
250
- } catch (m) {
251
- console.warn(m);
244
+ const w = r == null ? void 0 : r.getItem(a);
245
+ if (w)
246
+ return (i = e == null ? void 0 : e.columnsState) != null && i.defaultValue ? u(
247
+ JSON.parse(w),
248
+ (n = e == null ? void 0 : e.columnsState) == null ? void 0 : n.defaultValue
249
+ ) : JSON.parse(w);
250
+ } catch (w) {
251
+ console.warn(w);
252
252
  }
253
253
  }
254
- return e.columnsStateMap || ((c = e.columnsState) == null ? void 0 : c.value) || ((o = e.columnsState) == null ? void 0 : o.defaultValue) || {};
254
+ return e.columnsStateMap || ((l = e.columnsState) == null ? void 0 : l.value) || ((o = e.columnsState) == null ? void 0 : o.defaultValue) || {};
255
255
  },
256
256
  {
257
257
  value: ((X = e.columnsState) == null ? void 0 : X.value) || e.columnsStateMap,
258
258
  onChange: ((q = e.columnsState) == null ? void 0 : q.onChange) || e.onColumnsStateChange
259
259
  }
260
260
  );
261
- S(() => {
262
- var n, a;
263
- const { persistenceType: t, persistenceKey: i, onlineGet: l } = e.columnsState || {};
264
- if (i && t && typeof window < "u" && t !== "online") {
265
- const c = window[t];
261
+ g(() => {
262
+ var i, n;
263
+ const { persistenceType: t, persistenceKey: a, onlineGet: c } = e.columnsState || {};
264
+ if (a && t && typeof window < "u" && t !== "online") {
265
+ const l = window[t];
266
266
  try {
267
- const o = c == null ? void 0 : c.getItem(i);
268
- o ? (n = e == null ? void 0 : e.columnsState) != null && n.defaultValue ? w(
267
+ const o = l == null ? void 0 : l.getItem(a);
268
+ o ? (i = e == null ? void 0 : e.columnsState) != null && i.defaultValue ? m(
269
269
  u(
270
270
  JSON.parse(o),
271
- (a = e == null ? void 0 : e.columnsState) == null ? void 0 : a.defaultValue
271
+ (n = e == null ? void 0 : e.columnsState) == null ? void 0 : n.defaultValue
272
272
  )
273
- ) : w(JSON.parse(o)) : w(C);
273
+ ) : m(JSON.parse(o)) : m(d);
274
274
  } catch (o) {
275
275
  console.warn(o);
276
276
  }
@@ -278,83 +278,84 @@ function _e(e) {
278
278
  }, [
279
279
  (Q = e.columnsState) == null ? void 0 : Q.persistenceKey,
280
280
  (Y = e.columnsState) == null ? void 0 : Y.persistenceType,
281
- C
281
+ d
282
282
  ]);
283
283
  const H = B(() => {
284
- const { persistenceType: t, persistenceKey: i } = e.columnsState || {};
285
- if (!i || !t || typeof window > "u")
284
+ const { persistenceType: t, persistenceKey: a } = e.columnsState || {};
285
+ if (!a || !t || typeof window > "u")
286
286
  return;
287
- const l = window[t];
287
+ const c = window[t];
288
288
  try {
289
- l == null || l.removeItem(i);
290
- } catch (n) {
291
- console.warn(n);
289
+ c == null || c.removeItem(a);
290
+ } catch (i) {
291
+ console.warn(i);
292
292
  }
293
293
  }, [e.columnsState]), M = B(() => {
294
- const { persistenceType: t, persistenceKey: i } = e.stylesConfigState || {};
295
- if (!i || !t || typeof window > "u")
294
+ const { persistenceType: t, persistenceKey: a } = e.stylesConfigState || {};
295
+ if (!a || !t || typeof window > "u")
296
296
  return;
297
- const l = window[t];
297
+ const c = window[t];
298
298
  try {
299
- l == null || l.removeItem(i);
300
- } catch (n) {
301
- console.warn(n);
299
+ c == null || c.removeItem(a);
300
+ } catch (i) {
301
+ console.warn(i);
302
302
  }
303
- }, [e.stylesConfigState]), j = B(() => {
304
- const { persistenceType: t, persistenceKey: i } = e.exportConfigState || {};
305
- if (!i || !t || typeof window > "u")
303
+ }, [e.stylesConfigState]), P = B(() => {
304
+ const { persistenceType: t, persistenceKey: a } = e.exportConfigState || {};
305
+ if (!a || !t || typeof window > "u")
306
306
  return;
307
- const l = window[t];
307
+ const c = window[t];
308
308
  try {
309
- l == null || l.removeItem(i);
310
- } catch (n) {
311
- console.warn(n);
309
+ c == null || c.removeItem(a);
310
+ } catch (i) {
311
+ console.warn(i);
312
312
  }
313
313
  }, [e.exportConfigState]);
314
- S(() => {
315
- var l, n;
316
- if (!((l = e.columnsState) != null && l.persistenceKey) || !((n = e.columnsState) != null && n.persistenceType) || typeof window > "u")
314
+ g(() => {
315
+ var c, i;
316
+ if (!((c = e.columnsState) != null && c.persistenceKey) || !((i = e.columnsState) != null && i.persistenceType) || typeof window > "u")
317
317
  return;
318
318
  const {
319
319
  persistenceType: t,
320
- persistenceKey: i
320
+ persistenceKey: a
321
321
  // onlineChange
322
322
  } = e.columnsState;
323
323
  if (t !== "online") {
324
- const a = window[t];
324
+ const n = window[t];
325
325
  try {
326
- a == null || a.setItem(i, JSON.stringify(d));
327
- } catch (c) {
328
- console.warn(c), H();
326
+ n == null || n.setItem(a, JSON.stringify(y));
327
+ } catch (l) {
328
+ console.warn(l), H();
329
329
  }
330
330
  }
331
331
  }, [
332
332
  ($ = e.columnsState) == null ? void 0 : $.persistenceKey,
333
- d,
333
+ y,
334
334
  (p = e.columnsState) == null ? void 0 : p.persistenceType
335
- ]), S(() => {
336
- var t, i, l;
337
- if ((t = e.columnsState) != null && t.persistenceKey && ((i = e.columnsState) == null ? void 0 : i.persistenceType) === "online") {
338
- const { onlineGet: n, persistenceKey: a } = e.columnsState;
335
+ ]), g(() => {
336
+ var t, a, c;
337
+ if ((t = e.columnsState) != null && t.persistenceKey && ((a = e.columnsState) == null ? void 0 : a.persistenceType) === "online") {
338
+ const { onlineGet: i, persistenceKey: n } = e.columnsState;
339
339
  try {
340
- (l = n == null ? void 0 : n(a)) == null || l.then((c) => {
340
+ (c = i == null ? void 0 : i(n)) == null || c.then((l) => {
341
341
  var r;
342
- const o = u(c ?? {}, (r = e == null ? void 0 : e.columnsState) == null ? void 0 : r.value);
343
- w(o), Ve(!0);
342
+ const o = u(l ?? {}, (r = e == null ? void 0 : e.columnsState) == null ? void 0 : r.value);
343
+ m(o), Ve(!0);
344
344
  });
345
- } catch (c) {
346
- console.warn(c);
345
+ } catch (l) {
346
+ console.warn(l);
347
347
  }
348
348
  }
349
- }, []), S(() => {
350
- var i, l;
351
- const t = s.findIndex((n) => n == null ? void 0 : n.isOperationCol);
349
+ }, []), g(() => {
350
+ var c, i;
351
+ const t = s.findIndex((n) => n == null ? void 0 : n.isOperationCol), a = Object.keys(y ?? {}).length === 0;
352
352
  if (t >= 0) {
353
- const n = s[t], a = E(n, t);
354
- !(((i = d == null ? void 0 : d[a]) == null ? void 0 : i.fixed) === ((l = C == null ? void 0 : C[a]) == null ? void 0 : l.fixed)) && Object.keys(d ?? {}).length === 0 && w(C);
355
- }
356
- }, [C, d]);
357
- const ze = y(() => (e == null ? void 0 : e.rowHoverable) ?? (f == null ? void 0 : f.rowHoverable) ?? !0, [e == null ? void 0 : e.rowHoverable, f == null ? void 0 : f.rowHoverable]), be = y(() => e.zebra ?? g.zebra, [e.zebra, g.zebra]), O = y(() => e.bordered ?? g.bordered, [e.bordered, g.bordered]), ve = y(() => ["column", "row-column"].includes(O), [O]), Ne = y(() => {
353
+ const n = s[t], l = E(n, t);
354
+ !(((c = y == null ? void 0 : y[l]) == null ? void 0 : c.fixed) === ((i = d == null ? void 0 : d[l]) == null ? void 0 : i.fixed)) && a && m(d);
355
+ } else
356
+ a && m(d);
357
+ }, [d, y]);
358
+ const ze = S(() => (e == null ? void 0 : e.rowHoverable) ?? (f == null ? void 0 : f.rowHoverable) ?? !0, [e == null ? void 0 : e.rowHoverable, f == null ? void 0 : f.rowHoverable]), be = S(() => e.zebra ?? C.zebra, [e.zebra, C.zebra]), O = S(() => e.bordered ?? C.bordered, [e.bordered, C.bordered]), ve = S(() => ["column", "row-column"].includes(O), [O]), Ne = S(() => {
358
359
  let t = !1;
359
360
  return ["hide", "column"].includes(O) && (t = !0), t;
360
361
  }, [O]), [Be, v] = h(!1), [Ee, V] = h(de), Ie = () => {
@@ -362,13 +363,13 @@ function _e(e) {
362
363
  }, Je = () => {
363
364
  v(!1), V(0);
364
365
  }, He = () => {
365
- var t, i, l;
366
- (l = (t = e.columnsState) == null ? void 0 : t.onlineChange) == null || l.call(
366
+ var t, a, c;
367
+ (c = (t = e.columnsState) == null ? void 0 : t.onlineChange) == null || c.call(
367
368
  t,
368
- (i = e.columnsState) == null ? void 0 : i.persistenceKey,
369
- d
369
+ (a = e.columnsState) == null ? void 0 : a.persistenceKey,
370
+ y
370
371
  ), v(!1), V(0);
371
- }, P = {
372
+ }, j = {
372
373
  loading: e.loading ?? !1,
373
374
  dataSource: e.dataSource,
374
375
  pagination: e.pagination,
@@ -392,14 +393,14 @@ function _e(e) {
392
393
  persistenceKey: (te = e.columnsState) == null ? void 0 : te.persistenceKey,
393
394
  onlineChange: (ne = e.columnsState) == null ? void 0 : ne.onlineChange,
394
395
  finish: Oe,
395
- columnsMap: d,
396
- setColumnsMap: w,
397
- defaultColumnKeyMap: C,
396
+ columnsMap: y,
397
+ setColumnsMap: m,
398
+ defaultColumnKeyMap: d,
398
399
  clearPersistenceStorage: H,
399
- stylesConfig: g,
400
+ stylesConfig: C,
400
401
  setTableStylesConfig: J,
401
402
  defaultTableSize: I,
402
- tableSize: g.size,
403
+ tableSize: C.size,
403
404
  stylesStorageType: (ie = e.stylesConfigState) == null ? void 0 : ie.persistenceType,
404
405
  stylesStorageKey: (ae = e.stylesConfigState) == null ? void 0 : ae.persistenceKey,
405
406
  onlineStylesConfigChange: (oe = e.stylesConfigState) == null ? void 0 : oe.onlineChange,
@@ -411,20 +412,20 @@ function _e(e) {
411
412
  exportStorageType: (le = e.exportConfigState) == null ? void 0 : le.persistenceType,
412
413
  exportStorageKey: (ce = e.exportConfigState) == null ? void 0 : ce.persistenceKey,
413
414
  onlineExportConfigChange: (fe = e.exportConfigState) == null ? void 0 : fe.onlineChange,
414
- clearExportConfigCache: j,
415
+ clearExportConfigCache: P,
415
416
  exportConfigHardCodedValue: (re = e.exportConfigState) == null ? void 0 : re.hardCodedValue,
416
417
  zebra: be,
417
418
  rowHoverable: ze,
418
419
  showColumnBorder: ve,
419
420
  hideRowBorder: Ne
420
421
  };
421
- return Object.defineProperty(P, "uuid", {
422
+ return Object.defineProperty(j, "uuid", {
422
423
  get: () => K.current
423
- }), P;
424
+ }), j;
424
425
  }
425
426
  const Fe = ke({}), nt = (e) => {
426
427
  const K = _e(e.initValue);
427
- return /* @__PURE__ */ Pe.jsx(Fe.Provider, { value: K, children: e.children });
428
+ return /* @__PURE__ */ je.jsx(Fe.Provider, { value: K, children: e.children });
428
429
  };
429
430
  export {
430
431
  Fe as BitzTableContext,
@@ -7,6 +7,7 @@ export interface BitzSubTableProps<RecordType = any> extends Omit<TableProps<Rec
7
7
  scroll?: {
8
8
  x?: number;
9
9
  y?: number;
10
+ auto?: boolean;
10
11
  };
11
12
  /** PC端 & 移动端:后端返回的数组数据 */
12
13
  dataSource?: RecordType[];