bitz-react-admin-ui 2.9.0 → 2.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/index.mjs +2 -2
- package/dist/_virtual/index2.mjs +2 -2
- package/dist/_virtual/lodash.mjs +4 -0
- package/dist/components/BitzTable/Store/utils/index.d.ts +3 -1
- package/dist/components/BitzTable/Store/utils/index.mjs +26 -38
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.mjs +144 -142
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/index.mjs +55 -49
- package/dist/components/BitzTable/ToolBar/index.d.ts +3 -0
- package/dist/node_modules/classnames/index.mjs +1 -1
- package/dist/node_modules/lodash/lodash.mjs +3680 -0
- package/dist/node_modules/lodash-es/_SetCache.mjs +13 -0
- package/dist/node_modules/lodash-es/_arrayIncludes.mjs +8 -0
- package/dist/node_modules/lodash-es/_arrayIncludesWith.mjs +9 -0
- package/dist/node_modules/lodash-es/_arraySome.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseFindIndex.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseForOwn.mjs +8 -0
- package/dist/node_modules/lodash-es/_baseHasIn.mjs +6 -0
- package/dist/node_modules/lodash-es/_baseIndexOf.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseIsEqual.mjs +8 -0
- package/dist/node_modules/lodash-es/_baseIsEqualDeep.mjs +32 -0
- package/dist/node_modules/lodash-es/_baseIsMatch.mjs +31 -0
- package/dist/node_modules/lodash-es/_baseIsNaN.mjs +6 -0
- package/dist/node_modules/lodash-es/_baseIteratee.mjs +11 -0
- package/dist/node_modules/lodash-es/_baseMatches.mjs +12 -0
- package/dist/node_modules/lodash-es/_baseMatchesProperty.mjs +17 -0
- package/dist/node_modules/lodash-es/_baseProperty.mjs +8 -0
- package/dist/node_modules/lodash-es/_basePropertyDeep.mjs +9 -0
- package/dist/node_modules/lodash-es/_baseUniq.mjs +34 -0
- package/dist/node_modules/lodash-es/_cacheHas.mjs +6 -0
- package/dist/node_modules/lodash-es/_createSet.mjs +10 -0
- package/dist/node_modules/lodash-es/_equalArrays.mjs +40 -0
- package/dist/node_modules/lodash-es/_equalByTag.mjs +45 -0
- package/dist/node_modules/lodash-es/_equalObjects.mjs +36 -0
- package/dist/node_modules/lodash-es/_getMatchData.mjs +12 -0
- package/dist/node_modules/lodash-es/_hasPath.mjs +19 -0
- package/dist/node_modules/lodash-es/_isStrictComparable.mjs +7 -0
- package/dist/node_modules/lodash-es/_mapToArray.mjs +9 -0
- package/dist/node_modules/lodash-es/_matchesStrictComparable.mjs +8 -0
- package/dist/node_modules/lodash-es/_setCacheAdd.mjs +7 -0
- package/dist/node_modules/lodash-es/_setCacheHas.mjs +6 -0
- package/dist/node_modules/lodash-es/_setToArray.mjs +9 -0
- package/dist/node_modules/lodash-es/_strictIndexOf.mjs +9 -0
- package/dist/node_modules/lodash-es/hasIn.mjs +8 -0
- package/dist/node_modules/lodash-es/mapValues.mjs +12 -0
- package/dist/node_modules/lodash-es/noop.mjs +5 -0
- package/dist/node_modules/lodash-es/property.mjs +10 -0
- package/dist/node_modules/lodash-es/uniq.mjs +7 -0
- package/dist/node_modules/prop-types/index.mjs +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/_virtual/index.mjs
CHANGED
package/dist/_virtual/index2.mjs
CHANGED
|
@@ -10,5 +10,7 @@ export declare const loopFilter: (columns: any[], columnsMap: any) => any[];
|
|
|
10
10
|
export declare const genColumnKey: (column: any, defaultKey?: any) => any;
|
|
11
11
|
export declare const flattenColumns: (columns: any) => any[];
|
|
12
12
|
export declare const columnSort: (columnsMap: Record<string, ColumnsConfigProps>) => (a: any, b: any) => number;
|
|
13
|
-
export declare function updateNestedObject(obj: any, prop: any, val: any): {
|
|
13
|
+
export declare function updateNestedObject(obj: any, prop: any, val: any): {
|
|
14
|
+
[x: string]: any;
|
|
15
|
+
};
|
|
14
16
|
export declare const removePropertiesWithoutMutation: (obj: any, without: any) => {};
|
|
@@ -1,62 +1,50 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { l as y } from "../../../../node_modules/lodash/lodash.mjs";
|
|
2
|
+
const I = (e, r) => ((t, i) => t.map((d) => {
|
|
3
|
+
const f = h(d, d.index), o = i[f];
|
|
4
|
+
return o && o.show === !1 ? !1 : {
|
|
4
5
|
...d,
|
|
5
|
-
...
|
|
6
|
+
...o
|
|
6
7
|
// ...item?.isOperationCol && {
|
|
7
8
|
// width: finish ? config?.width ?? item?.width : item?.width
|
|
8
9
|
// },
|
|
9
10
|
};
|
|
10
|
-
}))(e, r).filter(Boolean),
|
|
11
|
+
}))(e, r).filter(Boolean), h = (e, r) => "key" in e && e.key !== void 0 && e.key !== null ? e.key : e.dataIndex ? Array.isArray(e.dataIndex) ? e.dataIndex.join("-") : e.dataIndex : `${r}`, k = (e) => {
|
|
11
12
|
const r = [];
|
|
12
|
-
function
|
|
13
|
-
t.children ? t.children.forEach(
|
|
13
|
+
function n(t) {
|
|
14
|
+
t.children ? t.children.forEach(n) : t.dataIndex && !t.exportHidden && r.push({
|
|
14
15
|
field: t.dataIndex,
|
|
15
16
|
title: t.title,
|
|
16
17
|
show: !0
|
|
17
18
|
});
|
|
18
19
|
}
|
|
19
|
-
return e.forEach(
|
|
20
|
-
},
|
|
21
|
-
var
|
|
22
|
-
const { fixed: t, index:
|
|
20
|
+
return e.forEach(n), r;
|
|
21
|
+
}, g = (e) => (r, n) => {
|
|
22
|
+
var s, l, x, u;
|
|
23
|
+
const { fixed: t, index: i } = r, { fixed: d, index: f } = n;
|
|
23
24
|
if (t === "left" && d !== "left" || d === "right" && t !== "right")
|
|
24
25
|
return -2;
|
|
25
26
|
if (d === "left" && t !== "left" || t === "right" && d !== "right")
|
|
26
27
|
return 2;
|
|
27
|
-
const
|
|
28
|
-
return (
|
|
28
|
+
const o = r.key || `${i}`, a = n.key || `${f}`;
|
|
29
|
+
return (s = e[o]) != null && s.order || (l = e[a]) != null && l.order ? (((x = e[o]) == null ? void 0 : x.order) || 0) - (((u = e[a]) == null ? void 0 : u.order) || 0) : (r.index || 0) - (n.index || 0);
|
|
29
30
|
};
|
|
30
|
-
function
|
|
31
|
-
|
|
32
|
-
let n = "";
|
|
33
|
-
const d = (o, s, a) => {
|
|
34
|
-
for (const f in o)
|
|
35
|
-
if (o.hasOwnProperty(f) && (typeof o[f] == "object" && o[f] !== null && (n = f, t[f] = { ...o[f] }, d(o[f], s, a)), f === s)) {
|
|
36
|
-
const l = t[n];
|
|
37
|
-
t[n] = {
|
|
38
|
-
...l,
|
|
39
|
-
[s]: a
|
|
40
|
-
// [prop]: current.disabled || current.fixed ? true : val,
|
|
41
|
-
}, n = "";
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
return d(e, r, i), t;
|
|
31
|
+
function K(e, r, n) {
|
|
32
|
+
return y.mapValues(e, (t) => ({ ...t, [r]: n }));
|
|
45
33
|
}
|
|
46
|
-
const
|
|
47
|
-
let
|
|
34
|
+
const p = (e, r) => {
|
|
35
|
+
let n = {};
|
|
48
36
|
for (let t in e)
|
|
49
37
|
if (e.hasOwnProperty(t)) {
|
|
50
|
-
let
|
|
51
|
-
typeof
|
|
38
|
+
let i = e[t];
|
|
39
|
+
typeof i == "object" && i !== null && (i = p(i, r)), r.includes(t) || (n[t] = i);
|
|
52
40
|
}
|
|
53
|
-
return
|
|
41
|
+
return n;
|
|
54
42
|
};
|
|
55
43
|
export {
|
|
56
|
-
|
|
44
|
+
g as columnSort,
|
|
57
45
|
k as flattenColumns,
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
46
|
+
h as genColumnKey,
|
|
47
|
+
I as loopFilter,
|
|
48
|
+
p as removePropertiesWithoutMutation,
|
|
49
|
+
K as updateNestedObject
|
|
62
50
|
};
|
|
@@ -1,32 +1,34 @@
|
|
|
1
1
|
import { j as r } from "../../../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
-
import { css as
|
|
3
|
-
import { theme as
|
|
4
|
-
import { forwardRef as
|
|
5
|
-
import { useImmer as
|
|
2
|
+
import { css as Le } from "../../../../../node_modules/@emotion/css/dist/emotion-css.esm.mjs";
|
|
3
|
+
import { theme as ve, Flex as F, Alert as be, Typography as q, Space as Ke, Checkbox as Re, Button as se } from "antd";
|
|
4
|
+
import { forwardRef as Ne, useRef as oe, useState as f, useEffect as T, useMemo as v, useContext as Ee, useImperativeHandle as Te, memo as Ie } from "react";
|
|
5
|
+
import { useImmer as ze } from "../../../../../node_modules/use-immer/dist/use-immer.module.mjs";
|
|
6
6
|
import "../../../index.mjs";
|
|
7
|
-
import { columnSort as
|
|
8
|
-
import
|
|
9
|
-
import { BitzTableContext as
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
7
|
+
import { columnSort as Ae, genColumnKey as He, updateNestedObject as b, removePropertiesWithoutMutation as Fe } from "../../../Store/utils/index.mjs";
|
|
8
|
+
import V from "./DndList.mjs";
|
|
9
|
+
import { BitzTableContext as We } from "../../../Store/index.mjs";
|
|
10
|
+
import ne from "../../../../../node_modules/lodash-es/mapValues.mjs";
|
|
11
|
+
import $e from "../../../../../node_modules/lodash-es/uniq.mjs";
|
|
12
|
+
import Be from "../../../../../node_modules/lodash-es/omit.mjs";
|
|
13
|
+
import re from "../../../../../node_modules/lodash-es/merge.mjs";
|
|
14
|
+
import ce from "../../../../../node_modules/@ant-design/icons/es/icons/RedoOutlined.mjs";
|
|
15
|
+
const De = Ne(
|
|
16
|
+
({ display: y, height: W, postHeight: ie }, le) => {
|
|
17
|
+
const { token: ae } = ve.useToken(), $ = oe(null), G = oe(null), [B, he] = f("auto"), J = Le`
|
|
16
18
|
&:hover {
|
|
17
|
-
color: ${
|
|
19
|
+
color: ${ae.colorPrimary} !important;
|
|
18
20
|
}
|
|
19
21
|
`;
|
|
20
22
|
T(() => {
|
|
21
|
-
|
|
22
|
-
}, [
|
|
23
|
+
$.current && ie();
|
|
24
|
+
}, [$.current]), T(() => {
|
|
23
25
|
var e;
|
|
24
|
-
if (typeof
|
|
25
|
-
const s = (e =
|
|
26
|
-
|
|
26
|
+
if (typeof W == "number") {
|
|
27
|
+
const s = (e = G.current) == null ? void 0 : e.clientHeight;
|
|
28
|
+
he(W - s - 16 - 8);
|
|
27
29
|
}
|
|
28
|
-
}, [
|
|
29
|
-
const
|
|
30
|
+
}, [W]);
|
|
31
|
+
const de = v(() => ({
|
|
30
32
|
// display: display ? 'flex' : 'none'
|
|
31
33
|
width: y ? "100%" : 0,
|
|
32
34
|
pointerEvents: y ? "auto" : "none",
|
|
@@ -37,162 +39,162 @@ const We = Ke(
|
|
|
37
39
|
left: 0,
|
|
38
40
|
right: 0
|
|
39
41
|
}
|
|
40
|
-
}), [y]), { defaultColumnKeyMap:
|
|
42
|
+
}), [y]), { defaultColumnKeyMap: Q, baseColumns: U, columnsMap: fe } = Ee(We), [l, D] = ze({});
|
|
41
43
|
T(() => {
|
|
42
|
-
const e =
|
|
44
|
+
const e = ne(Q, (s, t) => re({}, s, fe[t]));
|
|
43
45
|
D(e);
|
|
44
46
|
}, []);
|
|
45
|
-
const
|
|
46
|
-
var
|
|
47
|
-
const { key:
|
|
48
|
-
|
|
47
|
+
const X = v(() => ((s, t) => s.map((n) => {
|
|
48
|
+
var te;
|
|
49
|
+
const { key: o, dataIndex: c, children: i, ...g } = n, C = He(
|
|
50
|
+
n,
|
|
49
51
|
[t == null ? void 0 : t.columnKey, g.index].join("-")
|
|
50
52
|
), m = l[C || "null"] || {
|
|
51
53
|
show: !0
|
|
52
54
|
};
|
|
53
55
|
return {
|
|
54
56
|
key: C,
|
|
55
|
-
...
|
|
57
|
+
...Be(g, ["className"]),
|
|
56
58
|
selectable: !1,
|
|
57
59
|
disabled: m.disabled === !0,
|
|
58
|
-
disableCheckbox: typeof m.disabled == "boolean" ? m == null ? void 0 : m.disabled : (
|
|
60
|
+
disableCheckbox: typeof m.disabled == "boolean" ? m == null ? void 0 : m.disabled : (te = m == null ? void 0 : m.disabled) == null ? void 0 : te.checkbox,
|
|
59
61
|
isLeaf: t ? !0 : void 0,
|
|
60
62
|
...m
|
|
61
63
|
};
|
|
62
|
-
}))(
|
|
64
|
+
}))(U ?? []).sort(Ae(l)), [l, U]);
|
|
63
65
|
T(() => {
|
|
64
|
-
var
|
|
66
|
+
var n, o;
|
|
65
67
|
const e = {}, s = {}, t = {};
|
|
66
68
|
for (const c in l)
|
|
67
|
-
((
|
|
69
|
+
((n = l[c]) == null ? void 0 : n.fixed) === "left" ? e[c] = l[c] : ((o = l[c]) == null ? void 0 : o.fixed) === "right" ? s[c] = l[c] : t[c] = l[c];
|
|
68
70
|
u(e), p(s), x(t);
|
|
69
71
|
}, [l]);
|
|
70
|
-
const [
|
|
72
|
+
const [w, I] = f([]), [j, K] = f([]), [a, u] = f({}), [M, z] = f([]), [k, R] = f([]), [h, p] = f({}), [N, A] = f([]), [S, E] = f([]), [d, x] = f({});
|
|
71
73
|
T(() => {
|
|
72
|
-
const e = [], s = [], t = [],
|
|
73
|
-
|
|
74
|
-
i.fixed === "left" ? (e.push(i), s.push(i.key)) : i.fixed === "right" ? (t.push(i),
|
|
75
|
-
}), I(e), K(s), z(t), R(
|
|
76
|
-
}, [
|
|
77
|
-
const
|
|
74
|
+
const e = [], s = [], t = [], n = [], o = [], c = [];
|
|
75
|
+
X.forEach((i) => {
|
|
76
|
+
i.fixed === "left" ? (e.push(i), s.push(i.key)) : i.fixed === "right" ? (t.push(i), n.push(i.key)) : (o.push(i), c.push(i.key));
|
|
77
|
+
}), I(e), K(s), z(t), R(n), A(o), E(c);
|
|
78
|
+
}, [X]);
|
|
79
|
+
const Y = [...w, ...M], me = Y.length < 8, ue = (e) => {
|
|
78
80
|
u(e);
|
|
79
|
-
},
|
|
81
|
+
}, pe = (e, s) => {
|
|
80
82
|
u(e), K(s);
|
|
81
|
-
},
|
|
83
|
+
}, xe = (e) => {
|
|
82
84
|
p(e);
|
|
83
|
-
},
|
|
85
|
+
}, ge = (e, s) => {
|
|
84
86
|
p(e), R(s);
|
|
85
|
-
},
|
|
87
|
+
}, Ce = (e) => {
|
|
86
88
|
x(e);
|
|
87
|
-
},
|
|
89
|
+
}, ye = (e, s) => {
|
|
88
90
|
x(e), E(s);
|
|
89
|
-
},
|
|
90
|
-
const
|
|
91
|
+
}, Z = (e, s, t, n) => {
|
|
92
|
+
const o = { ...s[e] };
|
|
91
93
|
delete s[e], x({
|
|
92
94
|
...d,
|
|
93
|
-
[e]: { ...
|
|
95
|
+
[e]: { ...o, fixed: void 0, order: N.length }
|
|
94
96
|
});
|
|
95
97
|
const c = t.findIndex((C) => C.key === e), i = t.splice(c, 1)[0];
|
|
96
98
|
A([...N, { ...i, fixed: void 0 }]);
|
|
97
|
-
const g =
|
|
98
|
-
return E([...S, ...g]), { map: s, list: t, keys:
|
|
99
|
-
},
|
|
100
|
-
const
|
|
99
|
+
const g = n.splice(c, 1);
|
|
100
|
+
return E([...S, ...g]), { map: s, list: t, keys: n };
|
|
101
|
+
}, _ = (e, s, t, n) => {
|
|
102
|
+
const o = { ...s[e] };
|
|
101
103
|
delete s[e], u({
|
|
102
104
|
...a,
|
|
103
|
-
[e]: { ...
|
|
105
|
+
[e]: { ...o, fixed: "left", order: w.length, show: !0 }
|
|
104
106
|
});
|
|
105
107
|
const c = t.findIndex((C) => C.key === e), i = t.splice(c, 1)[0];
|
|
106
|
-
I([...
|
|
107
|
-
const g =
|
|
108
|
-
return K([...
|
|
109
|
-
},
|
|
110
|
-
const
|
|
108
|
+
I([...w, { ...i, fixed: "left" }]);
|
|
109
|
+
const g = n.splice(c, 1);
|
|
110
|
+
return K([...j, ...g]), { map: s, list: t, keys: n };
|
|
111
|
+
}, ee = (e, s, t, n) => {
|
|
112
|
+
const o = { ...s[e] };
|
|
111
113
|
delete s[e], p({
|
|
112
114
|
...h,
|
|
113
115
|
[e]: {
|
|
114
|
-
...
|
|
116
|
+
...o,
|
|
115
117
|
fixed: "right",
|
|
116
|
-
order:
|
|
118
|
+
order: M.length,
|
|
117
119
|
show: !0
|
|
118
120
|
}
|
|
119
121
|
});
|
|
120
122
|
const c = t.findIndex((C) => C.key === e), i = t.splice(c, 1)[0];
|
|
121
|
-
z([...
|
|
122
|
-
const g =
|
|
123
|
-
return R([...
|
|
124
|
-
},
|
|
123
|
+
z([...M, { ...i, fixed: "right" }]);
|
|
124
|
+
const g = n.splice(c, 1);
|
|
125
|
+
return R([...k, ...g]), { map: s, list: t, keys: n };
|
|
126
|
+
}, O = (e, s) => {
|
|
125
127
|
if (s === "left") {
|
|
126
|
-
const { map: t, list:
|
|
128
|
+
const { map: t, list: n, keys: o } = Z(
|
|
127
129
|
e,
|
|
128
130
|
a,
|
|
129
|
-
|
|
130
|
-
|
|
131
|
+
w,
|
|
132
|
+
j
|
|
131
133
|
);
|
|
132
|
-
u({ ...t }), I([...
|
|
134
|
+
u({ ...t }), I([...n]), K([...o]);
|
|
133
135
|
} else if (s === "center") {
|
|
134
|
-
const { map: t, list:
|
|
136
|
+
const { map: t, list: n, keys: o } = _(
|
|
135
137
|
e,
|
|
136
138
|
d,
|
|
137
139
|
N,
|
|
138
140
|
S
|
|
139
141
|
);
|
|
140
|
-
x({ ...t }), A([...
|
|
142
|
+
x({ ...t }), A([...n]), E([...o]);
|
|
141
143
|
} else {
|
|
142
|
-
const { map: t, list:
|
|
144
|
+
const { map: t, list: n, keys: o } = _(
|
|
143
145
|
e,
|
|
144
146
|
h,
|
|
145
|
-
|
|
146
|
-
|
|
147
|
+
M,
|
|
148
|
+
k
|
|
147
149
|
);
|
|
148
|
-
p({ ...t }), z([...
|
|
150
|
+
p({ ...t }), z([...n]), R([...o]);
|
|
149
151
|
}
|
|
150
|
-
},
|
|
152
|
+
}, P = (e, s) => {
|
|
151
153
|
if (s === "left") {
|
|
152
|
-
const { map: t, list:
|
|
154
|
+
const { map: t, list: n, keys: o } = ee(
|
|
153
155
|
e,
|
|
154
156
|
a,
|
|
155
|
-
|
|
156
|
-
|
|
157
|
+
w,
|
|
158
|
+
j
|
|
157
159
|
);
|
|
158
|
-
u({ ...t }), I([...
|
|
160
|
+
u({ ...t }), I([...n]), K([...o]);
|
|
159
161
|
} else if (s === "center") {
|
|
160
|
-
const { map: t, list:
|
|
162
|
+
const { map: t, list: n, keys: o } = ee(
|
|
161
163
|
e,
|
|
162
164
|
d,
|
|
163
165
|
N,
|
|
164
166
|
S
|
|
165
167
|
);
|
|
166
|
-
x({ ...t }), A([...
|
|
168
|
+
x({ ...t }), A([...n]), E([...o]);
|
|
167
169
|
} else {
|
|
168
|
-
const { map: t, list:
|
|
170
|
+
const { map: t, list: n, keys: o } = Z(
|
|
169
171
|
e,
|
|
170
172
|
h,
|
|
171
|
-
|
|
172
|
-
|
|
173
|
+
M,
|
|
174
|
+
k
|
|
173
175
|
);
|
|
174
|
-
p({ ...t }), z([...
|
|
176
|
+
p({ ...t }), z([...n]), R([...o]);
|
|
175
177
|
}
|
|
176
|
-
},
|
|
177
|
-
e.checked ? (u(
|
|
178
|
-
}, H =
|
|
179
|
-
var s, t,
|
|
178
|
+
}, we = ({ target: e }) => {
|
|
179
|
+
e.checked ? (u(b(a, "show", !0)), x(b(d, "show", !0)), p(b(h, "show", !0))) : (u(b(a, "show", !1)), x(b(d, "show", !1)), p(b(h, "show", !1)));
|
|
180
|
+
}, H = v(() => [...j, ...S, ...k], [j, S, k]), L = v(() => {
|
|
181
|
+
var s, t, n;
|
|
180
182
|
const e = [];
|
|
181
|
-
for (const
|
|
182
|
-
(s = a[
|
|
183
|
-
for (const
|
|
184
|
-
(t = d[
|
|
185
|
-
for (const
|
|
186
|
-
(
|
|
187
|
-
return e;
|
|
188
|
-
}, [a, d, h]),
|
|
189
|
-
const e =
|
|
190
|
-
D(
|
|
191
|
-
},
|
|
192
|
-
const e =
|
|
183
|
+
for (const o in a)
|
|
184
|
+
(s = a[o]) != null && s.show && e.push(o);
|
|
185
|
+
for (const o in d)
|
|
186
|
+
(t = d[o]) != null && t.show && e.push(o);
|
|
187
|
+
for (const o in h)
|
|
188
|
+
(n = h[o]) != null && n.show && e.push(o);
|
|
189
|
+
return $e(e);
|
|
190
|
+
}, [a, d, h]), je = v(() => H.length === L.length, [H, L]), Me = v(() => L.length > 0 && L.length < H.length, [L, H]), ke = () => {
|
|
191
|
+
const e = re({ ...l }, Q), s = ne(e, (t) => ({ ...t, show: !0, fixed: void 0 }));
|
|
192
|
+
D(s);
|
|
193
|
+
}, Se = () => {
|
|
194
|
+
const e = Fe(l, ["width"]);
|
|
193
195
|
D(e);
|
|
194
196
|
};
|
|
195
|
-
return
|
|
197
|
+
return Te(le, () => ({
|
|
196
198
|
getLeftSortColumns: () => a,
|
|
197
199
|
getCenterSortColumns: () => d,
|
|
198
200
|
getRightSortColumns: () => h,
|
|
@@ -202,12 +204,12 @@ const We = Ke(
|
|
|
202
204
|
{
|
|
203
205
|
vertical: !0,
|
|
204
206
|
gap: 8,
|
|
205
|
-
style:
|
|
206
|
-
ref:
|
|
207
|
+
style: de,
|
|
208
|
+
ref: $,
|
|
207
209
|
className: "columnsSortWrapper",
|
|
208
210
|
children: [
|
|
209
|
-
!
|
|
210
|
-
|
|
211
|
+
!me && /* @__PURE__ */ r.jsx(
|
|
212
|
+
be,
|
|
211
213
|
{
|
|
212
214
|
showIcon: !0,
|
|
213
215
|
type: "warning",
|
|
@@ -215,7 +217,7 @@ const We = Ke(
|
|
|
215
217
|
description: /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
|
|
216
218
|
/* @__PURE__ */ r.jsxs("div", { children: [
|
|
217
219
|
"当前总固定",
|
|
218
|
-
/* @__PURE__ */ r.jsx("em", { style: { fontSize: 18, color: "red" }, children:
|
|
220
|
+
/* @__PURE__ */ r.jsx("em", { style: { fontSize: 18, color: "red" }, children: Y.length }),
|
|
219
221
|
"列"
|
|
220
222
|
] }),
|
|
221
223
|
/* @__PURE__ */ r.jsxs("div", { children: [
|
|
@@ -238,16 +240,16 @@ const We = Ke(
|
|
|
238
240
|
children: [
|
|
239
241
|
/* @__PURE__ */ r.jsx(q.Title, { level: 5, className: "title", children: "固定在左侧" }),
|
|
240
242
|
/* @__PURE__ */ r.jsx(
|
|
241
|
-
|
|
243
|
+
V,
|
|
242
244
|
{
|
|
243
245
|
placement: "left",
|
|
244
|
-
dataList:
|
|
245
|
-
keys:
|
|
246
|
+
dataList: w,
|
|
247
|
+
keys: j,
|
|
246
248
|
columnsMap: a,
|
|
247
|
-
onLeftClick:
|
|
248
|
-
onRightClick:
|
|
249
|
-
onChange:
|
|
250
|
-
onMoveEnd:
|
|
249
|
+
onLeftClick: O,
|
|
250
|
+
onRightClick: P,
|
|
251
|
+
onChange: ue,
|
|
252
|
+
onMoveEnd: pe
|
|
251
253
|
}
|
|
252
254
|
)
|
|
253
255
|
]
|
|
@@ -263,16 +265,16 @@ const We = Ke(
|
|
|
263
265
|
children: [
|
|
264
266
|
/* @__PURE__ */ r.jsx(q.Title, { level: 5, className: "title", children: "不固定" }),
|
|
265
267
|
/* @__PURE__ */ r.jsx(
|
|
266
|
-
|
|
268
|
+
V,
|
|
267
269
|
{
|
|
268
270
|
placement: "center",
|
|
269
271
|
dataList: N,
|
|
270
272
|
keys: S,
|
|
271
273
|
columnsMap: d,
|
|
272
|
-
onLeftClick:
|
|
273
|
-
onRightClick:
|
|
274
|
-
onChange:
|
|
275
|
-
onMoveEnd:
|
|
274
|
+
onLeftClick: O,
|
|
275
|
+
onRightClick: P,
|
|
276
|
+
onChange: Ce,
|
|
277
|
+
onMoveEnd: ye
|
|
276
278
|
}
|
|
277
279
|
)
|
|
278
280
|
]
|
|
@@ -288,16 +290,16 @@ const We = Ke(
|
|
|
288
290
|
children: [
|
|
289
291
|
/* @__PURE__ */ r.jsx(q.Title, { level: 5, className: "title", children: "固定在右侧" }),
|
|
290
292
|
/* @__PURE__ */ r.jsx(
|
|
291
|
-
|
|
293
|
+
V,
|
|
292
294
|
{
|
|
293
295
|
placement: "right",
|
|
294
|
-
dataList:
|
|
295
|
-
keys:
|
|
296
|
+
dataList: M,
|
|
297
|
+
keys: k,
|
|
296
298
|
columnsMap: h,
|
|
297
|
-
onLeftClick:
|
|
298
|
-
onRightClick:
|
|
299
|
-
onChange:
|
|
300
|
-
onMoveEnd:
|
|
299
|
+
onLeftClick: O,
|
|
300
|
+
onRightClick: P,
|
|
301
|
+
onChange: xe,
|
|
302
|
+
onMoveEnd: ge
|
|
301
303
|
}
|
|
302
304
|
)
|
|
303
305
|
]
|
|
@@ -305,42 +307,42 @@ const We = Ke(
|
|
|
305
307
|
)
|
|
306
308
|
] }),
|
|
307
309
|
/* @__PURE__ */ r.jsxs(
|
|
308
|
-
|
|
310
|
+
Ke,
|
|
309
311
|
{
|
|
310
312
|
size: 16,
|
|
311
313
|
align: "end",
|
|
312
|
-
ref:
|
|
314
|
+
ref: G,
|
|
313
315
|
className: "checkAllAndReset",
|
|
314
316
|
style: { paddingBottom: 8 },
|
|
315
317
|
children: [
|
|
316
318
|
/* @__PURE__ */ r.jsx(
|
|
317
|
-
|
|
319
|
+
Re,
|
|
318
320
|
{
|
|
319
|
-
indeterminate:
|
|
320
|
-
checked:
|
|
321
|
-
onChange:
|
|
322
|
-
children: /* @__PURE__ */ r.jsx("span", { style: { whiteSpace: "nowrap" }, children: "
|
|
321
|
+
indeterminate: Me,
|
|
322
|
+
checked: je,
|
|
323
|
+
onChange: we,
|
|
324
|
+
children: /* @__PURE__ */ r.jsx("span", { style: { whiteSpace: "nowrap" }, children: "全部显示" })
|
|
323
325
|
}
|
|
324
326
|
),
|
|
325
327
|
/* @__PURE__ */ r.jsx(
|
|
326
|
-
|
|
328
|
+
se,
|
|
327
329
|
{
|
|
328
330
|
type: "link",
|
|
329
|
-
icon: /* @__PURE__ */ r.jsx(
|
|
331
|
+
icon: /* @__PURE__ */ r.jsx(ce, {}),
|
|
330
332
|
size: "small",
|
|
331
|
-
onClick:
|
|
332
|
-
className:
|
|
333
|
+
onClick: ke,
|
|
334
|
+
className: J,
|
|
333
335
|
children: /* @__PURE__ */ r.jsx("span", { style: { whiteSpace: "nowrap" }, children: "重置排序和显隐" })
|
|
334
336
|
}
|
|
335
337
|
),
|
|
336
338
|
/* @__PURE__ */ r.jsx(
|
|
337
|
-
|
|
339
|
+
se,
|
|
338
340
|
{
|
|
339
341
|
type: "link",
|
|
340
|
-
icon: /* @__PURE__ */ r.jsx(
|
|
342
|
+
icon: /* @__PURE__ */ r.jsx(ce, {}),
|
|
341
343
|
size: "small",
|
|
342
|
-
onClick:
|
|
343
|
-
className:
|
|
344
|
+
onClick: Se,
|
|
345
|
+
className: J,
|
|
344
346
|
children: /* @__PURE__ */ r.jsx("span", { style: { whiteSpace: "nowrap" }, children: "重置列宽" })
|
|
345
347
|
}
|
|
346
348
|
)
|
|
@@ -351,7 +353,7 @@ const We = Ke(
|
|
|
351
353
|
}
|
|
352
354
|
);
|
|
353
355
|
}
|
|
354
|
-
),
|
|
356
|
+
), ot = Ie(De);
|
|
355
357
|
export {
|
|
356
|
-
|
|
358
|
+
ot as default
|
|
357
359
|
};
|