bitz-react-admin-ui 1.6.5 → 1.6.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/bitz-ui.mjs +126 -120
- package/dist/components/BitzFluentInput/index.mjs +20 -17
- package/dist/components/BitzFluentSelect/index.mjs +20 -18
- package/dist/components/BitzList/List.mjs +28 -0
- package/dist/components/BitzList/LoadMore.mjs +69 -0
- package/dist/components/BitzList/index.less.mjs +4 -0
- package/dist/components/BitzList/index.mjs +6 -0
- package/dist/components/BitzPullRefresh/PullRefresh.mjs +113 -0
- package/dist/components/BitzPullRefresh/index.mjs +6 -0
- package/dist/components/BitzPullRefresh/style/index.less.mjs +4 -0
- package/dist/components/BitzSelect/component/BitzSelectMobile.mjs +133 -94
- package/dist/components/BitzTable/ActionBar/ActionBar.mjs +64 -0
- package/dist/components/BitzTable/ActionBar/Button.mjs +10 -0
- package/dist/components/BitzTable/ActionBar/index.mjs +6 -60
- package/dist/components/BitzTable/ActionBar/style.mjs +36 -32
- package/dist/components/BitzTable/ActionCol/index.mjs +29 -28
- package/dist/components/BitzTable/Table/index.mjs +302 -253
- package/dist/components/BitzTable/TableSkeleton/index.mjs +46 -42
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnSettingModal.mjs +179 -173
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/DndItem.mjs +28 -26
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.mjs +10 -9
- package/dist/components/BitzTable/ToolBar/DensityIcon/index.mjs +1 -1
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.mjs +28 -25
- package/dist/components/BitzTable/ToolBar/RefreshIcon/index.mjs +3 -2
- package/dist/components/BitzTable/ToolBar/Wrapper/index.mjs +23 -14
- package/dist/components/BitzTable/ToolBar/style.mjs +29 -20
- package/dist/hooks/use-event-listener.mjs +40 -0
- package/dist/hooks/use-lock-fn.mjs +21 -0
- package/dist/hooks/use-scroll-parent.mjs +34 -0
- package/dist/hooks/use-touch.mjs +33 -0
- package/dist/node_modules/.store/@dnd-kit_core@6.1.0/node_modules/@dnd-kit/core/dist/core.esm.mjs +751 -1050
- package/dist/node_modules/.store/ahooks@3.7.10/node_modules/ahooks/es/useSetState/index.mjs +16 -0
- package/dist/node_modules/.store/ahooks@3.7.10/node_modules/ahooks/es/useThrottleFn/index.mjs +28 -0
- package/dist/node_modules/.store/ahooks@3.7.10/node_modules/ahooks/es/useUpdateEffect/index.mjs +6 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_Symbol.mjs +5 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_baseGetTag.mjs +11 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_baseTrim.mjs +9 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_freeGlobal.mjs +5 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_getRawTag.mjs +16 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_objectToString.mjs +8 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_root.mjs +5 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/_trimmedEndIndex.mjs +10 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/debounce.mjs +55 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/isObject.mjs +8 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/isObjectLike.mjs +7 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/isSymbol.mjs +10 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/now.mjs +7 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/throttle.mjs +19 -0
- package/dist/node_modules/.store/lodash@4.17.21/node_modules/lodash/toNumber.mjs +23 -0
- package/dist/node_modules/.store/tslib@2.6.2/node_modules/tslib/tslib.es6.mjs +48 -37
- package/dist/node_modules/_clsx@2.1.0@clsx/dist/clsx.mjs +23 -0
- package/dist/style.css +1 -1
- package/dist/type/bitz-ui.d.ts +2 -0
- package/dist/type/components/BitzList/List.d.ts +4 -0
- package/dist/type/components/BitzList/LoadMore.d.ts +4 -0
- package/dist/type/components/BitzList/PropsType.d.ts +35 -0
- package/dist/type/components/BitzList/index.d.ts +5 -0
- package/dist/type/components/BitzPagination/index.d.ts +8 -2
- package/dist/type/components/BitzPullRefresh/PropsType.d.ts +43 -0
- package/dist/type/components/BitzPullRefresh/PullRefresh.d.ts +4 -0
- package/dist/type/components/BitzPullRefresh/index.d.ts +5 -0
- package/dist/type/components/BitzSelect/component/BitzSelectMobile.d.ts +1 -0
- package/dist/type/components/BitzTable/ActionBar/ActionBar.d.ts +37 -0
- package/dist/type/components/BitzTable/ActionBar/Button.d.ts +6 -0
- package/dist/type/components/BitzTable/ActionBar/index.d.ts +6 -33
- package/dist/type/components/BitzTable/ActionBar/style.d.ts +2 -2
- package/dist/type/components/BitzTable/Store/index.d.ts +2 -3
- package/dist/type/components/BitzTable/Table/index.d.ts +2 -2
- package/dist/type/components/BitzTable/TableSkeleton/index.d.ts +1 -1
- package/dist/type/components/BitzTable/ToolBar/ExportIcon/index.d.ts +2 -1
- package/dist/type/components/BitzTable/ToolBar/style.d.ts +1 -2
- package/dist/type/components/BitzTable/index.d.ts +6 -7
- package/dist/type/hooks/use-event-listener.d.ts +11 -0
- package/dist/type/hooks/use-lock-fn.d.ts +2 -0
- package/dist/type/hooks/use-scroll-parent.d.ts +9 -0
- package/dist/type/hooks/use-touch.d.ts +18 -0
- package/dist/type/pages/Login2/useRowSelection.d.ts +6 -4
- package/dist/type/pages/Test/index.d.ts +3 -0
- package/dist/type/utils/get-default-props.d.ts +2 -0
- package/dist/type/utils/scroll.d.ts +6 -0
- package/dist/utils/get-default-props.mjs +12 -0
- package/dist/utils/scroll.mjs +15 -0
- package/package.json +2 -1
|
@@ -1,152 +1,191 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { useState as
|
|
3
|
-
import { BitzPickDrawer as
|
|
4
|
-
import { Tag as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import { useImmer as
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
const { Search:
|
|
12
|
-
|
|
1
|
+
import { j as a } from "../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { useState as w, useRef as P, useEffect as D } from "react";
|
|
3
|
+
import { BitzPickDrawer as U } from "../../BitzDrawer/index.mjs";
|
|
4
|
+
import { Tag as z, Input as W, Space as q } from "antd";
|
|
5
|
+
import $ from "../../../node_modules/.store/@better-scroll_core@2.5.1/node_modules/@better-scroll/core/dist/core.esm.mjs";
|
|
6
|
+
import A from "../../../node_modules/.store/@better-scroll_wheel@2.5.1/node_modules/@better-scroll/wheel/dist/wheel.esm.mjs";
|
|
7
|
+
import n from "./index.module.less.mjs";
|
|
8
|
+
import { useImmer as T } from "../../../node_modules/.store/use-immer@0.9.0/node_modules/use-immer/dist/use-immer.module.mjs";
|
|
9
|
+
import y from "../../../node_modules/.store/@ant-design_icons@5.3.1/node_modules/@ant-design/icons/es/icons/DownOutlined.mjs";
|
|
10
|
+
$.use(A);
|
|
11
|
+
const { Search: G } = W, te = ({ ...e }) => {
|
|
12
|
+
var C, g, k;
|
|
13
|
+
const u = e.mode === "multiple" || e.mode === "tags";
|
|
14
|
+
let b = [];
|
|
15
|
+
if (e != null && e.options && ((C = e == null ? void 0 : e.options) != null && C.length) && (e != null && e.fieldNames)) {
|
|
16
|
+
const l = (g = e == null ? void 0 : e.fieldNames) == null ? void 0 : g.label, t = (k = e == null ? void 0 : e.fieldNames) == null ? void 0 : k.value;
|
|
17
|
+
(e == null ? void 0 : e.options).map((s) => {
|
|
18
|
+
const c = {};
|
|
19
|
+
c.label = s[l], c.value = s[t], b.push(c);
|
|
20
|
+
});
|
|
21
|
+
} else
|
|
22
|
+
b = (e == null ? void 0 : e.options) || [];
|
|
23
|
+
const i = b, B = (l, t) => ((t == null ? void 0 : t.label) ?? "").toLowerCase().includes(l.toLowerCase()), m = e.value ?? e.defaultValue, S = e.filterOption || B, [N, E] = w(() => {
|
|
24
|
+
const l = i == null ? void 0 : i.findIndex((t) => t.value === m);
|
|
25
|
+
return l === -1 ? 0 : l;
|
|
26
|
+
}), [d, h] = T(() => {
|
|
13
27
|
var l;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
}, y = () => {
|
|
22
|
-
const e = n.onChange;
|
|
23
|
-
if (o)
|
|
24
|
-
x(d.map((l) => l.value)), e == null || e(d.map((l) => l.value));
|
|
28
|
+
return u ? m : ((l = i == null ? void 0 : i.find((t) => t.value === m)) == null ? void 0 : l.value) || "";
|
|
29
|
+
}), I = P(null), [j, x] = w(!1), [L, O] = w(""), [f, v] = T([]), V = () => {
|
|
30
|
+
x(!1);
|
|
31
|
+
}, M = () => {
|
|
32
|
+
const l = e.onChange;
|
|
33
|
+
if (u)
|
|
34
|
+
h(f.map((t) => t.value)), l == null || l(f.map((t) => t.value));
|
|
25
35
|
else {
|
|
26
|
-
const
|
|
27
|
-
|
|
36
|
+
const t = i[N || 0];
|
|
37
|
+
h(t.label), l == null || l(t.value, t);
|
|
28
38
|
}
|
|
29
|
-
|
|
39
|
+
x(!1);
|
|
30
40
|
};
|
|
31
|
-
|
|
32
|
-
if (
|
|
33
|
-
if (
|
|
34
|
-
let
|
|
41
|
+
D(() => {
|
|
42
|
+
if (I.current)
|
|
43
|
+
if (j) {
|
|
44
|
+
let l = new $("." + n.wheel, {
|
|
35
45
|
click: !0,
|
|
36
46
|
probeType: 3,
|
|
37
47
|
preventDefaultException: {
|
|
38
48
|
className: /wheel-item/
|
|
39
49
|
},
|
|
40
50
|
wheel: {
|
|
41
|
-
selectedIndex:
|
|
42
|
-
wheelWrapperClass:
|
|
43
|
-
wheelItemClass:
|
|
44
|
-
wheelDisabledItemClass:
|
|
51
|
+
selectedIndex: N,
|
|
52
|
+
wheelWrapperClass: n["wheel-scroll"],
|
|
53
|
+
wheelItemClass: n["wheel-item"],
|
|
54
|
+
wheelDisabledItemClass: n["wheel-disabled-item"]
|
|
45
55
|
},
|
|
46
56
|
useTransition: !1
|
|
47
57
|
});
|
|
48
|
-
if (
|
|
49
|
-
|
|
50
|
-
}),
|
|
51
|
-
const
|
|
52
|
-
|
|
58
|
+
if (l.on("scrollEnd", () => {
|
|
59
|
+
E(l.getSelectedIndex());
|
|
60
|
+
}), u) {
|
|
61
|
+
const t = i.filter((r) => d == null ? void 0 : d.find((s) => s === r.value));
|
|
62
|
+
v(t);
|
|
53
63
|
}
|
|
54
64
|
} else
|
|
55
|
-
|
|
56
|
-
|
|
65
|
+
v((l) => {
|
|
66
|
+
l.splice(0);
|
|
57
67
|
});
|
|
58
|
-
}, [
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
68
|
+
}, [j]), D(() => {
|
|
69
|
+
h(m);
|
|
70
|
+
}, [m]);
|
|
71
|
+
function R() {
|
|
72
|
+
return u ? /* @__PURE__ */ a.jsxs("div", { className: n.textarea, onClick: () => x(!0), children: [
|
|
73
|
+
/* @__PURE__ */ a.jsx("div", { children: d == null ? void 0 : d.map((l, t) => {
|
|
62
74
|
var r;
|
|
63
|
-
return /* @__PURE__ */
|
|
64
|
-
|
|
75
|
+
return /* @__PURE__ */ a.jsx(
|
|
76
|
+
z,
|
|
65
77
|
{
|
|
66
78
|
bordered: !1,
|
|
67
79
|
closable: !0,
|
|
68
|
-
onClose: (
|
|
69
|
-
|
|
70
|
-
const
|
|
71
|
-
|
|
72
|
-
|
|
80
|
+
onClose: (s) => {
|
|
81
|
+
s.preventDefault();
|
|
82
|
+
const c = d.findIndex((o) => o === l);
|
|
83
|
+
h((o) => {
|
|
84
|
+
o.splice(c, 1);
|
|
73
85
|
});
|
|
74
86
|
},
|
|
75
|
-
children: (r =
|
|
87
|
+
children: (r = i.find((s) => l === s.value)) == null ? void 0 : r.label
|
|
76
88
|
},
|
|
77
|
-
|
|
89
|
+
t
|
|
78
90
|
);
|
|
79
91
|
}) }),
|
|
80
|
-
/* @__PURE__ */
|
|
81
|
-
] }) : /* @__PURE__ */
|
|
92
|
+
/* @__PURE__ */ a.jsx(y, { style: { color: "#d9d9d9" } })
|
|
93
|
+
] }) : /* @__PURE__ */ a.jsx(
|
|
94
|
+
W,
|
|
95
|
+
{
|
|
96
|
+
placeholder: e.placeholder,
|
|
97
|
+
onClick: () => x(!0),
|
|
98
|
+
value: d,
|
|
99
|
+
suffix: /* @__PURE__ */ a.jsx(y, { style: { color: "#d9d9d9" } })
|
|
100
|
+
}
|
|
101
|
+
);
|
|
82
102
|
}
|
|
83
|
-
function
|
|
84
|
-
return
|
|
85
|
-
|
|
103
|
+
function F() {
|
|
104
|
+
return e.showSearch ? /* @__PURE__ */ a.jsx("div", { className: n["search-input"], children: /* @__PURE__ */ a.jsx(
|
|
105
|
+
G,
|
|
86
106
|
{
|
|
87
|
-
onKeyUp: (
|
|
88
|
-
if (
|
|
89
|
-
|
|
107
|
+
onKeyUp: (l) => {
|
|
108
|
+
if (e.onSearch) {
|
|
109
|
+
e.onSearch(l.currentTarget.value);
|
|
90
110
|
return;
|
|
91
111
|
}
|
|
92
|
-
|
|
112
|
+
O(l.currentTarget.value);
|
|
93
113
|
}
|
|
94
114
|
}
|
|
95
115
|
) }) : null;
|
|
96
116
|
}
|
|
97
|
-
function
|
|
98
|
-
return
|
|
99
|
-
/* @__PURE__ */
|
|
100
|
-
/* @__PURE__ */
|
|
101
|
-
|
|
117
|
+
function H() {
|
|
118
|
+
return u ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
119
|
+
/* @__PURE__ */ a.jsx("div", { className: n["select-label"], children: "已选择:" }),
|
|
120
|
+
/* @__PURE__ */ a.jsx(q, { size: [0, "small"], wrap: !0, className: n["tag-list"], children: f.map((l, t) => /* @__PURE__ */ a.jsx(
|
|
121
|
+
z,
|
|
102
122
|
{
|
|
103
123
|
bordered: !1,
|
|
104
124
|
closable: !0,
|
|
105
125
|
onClose: (r) => {
|
|
106
126
|
r.preventDefault();
|
|
107
|
-
const
|
|
108
|
-
|
|
109
|
-
|
|
127
|
+
const s = f.findIndex((c) => l.value === c.value);
|
|
128
|
+
v((c) => {
|
|
129
|
+
c.splice(s, 1);
|
|
110
130
|
});
|
|
111
131
|
},
|
|
112
|
-
children:
|
|
132
|
+
children: l.label
|
|
113
133
|
},
|
|
114
|
-
|
|
134
|
+
t
|
|
115
135
|
)) })
|
|
116
136
|
] }) : null;
|
|
117
137
|
}
|
|
118
|
-
function
|
|
119
|
-
return (
|
|
138
|
+
function K() {
|
|
139
|
+
return (S ? i.filter((t) => S(L, t)) : i).map((t, r) => /* @__PURE__ */ a.jsx(
|
|
120
140
|
"li",
|
|
121
141
|
{
|
|
122
|
-
className:
|
|
142
|
+
className: n["wheel-item"],
|
|
123
143
|
onClick: () => {
|
|
124
|
-
|
|
125
|
-
if (
|
|
126
|
-
const
|
|
127
|
-
|
|
144
|
+
u && v((s) => {
|
|
145
|
+
if (f.find((c) => c.value === t.value)) {
|
|
146
|
+
const c = f.findIndex((o) => t.value === o.value);
|
|
147
|
+
s.splice(c, 1);
|
|
128
148
|
} else
|
|
129
|
-
|
|
149
|
+
s.push(t);
|
|
130
150
|
});
|
|
131
151
|
},
|
|
132
|
-
children:
|
|
152
|
+
children: t.label
|
|
133
153
|
},
|
|
134
154
|
r
|
|
135
155
|
));
|
|
136
156
|
}
|
|
137
|
-
return /* @__PURE__ */
|
|
138
|
-
|
|
139
|
-
/* @__PURE__ */
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
157
|
+
return /* @__PURE__ */ a.jsxs("div", { className: `bitzSelectMobileBlock ${e.className}`, children: [
|
|
158
|
+
R(),
|
|
159
|
+
/* @__PURE__ */ a.jsx(
|
|
160
|
+
U,
|
|
161
|
+
{
|
|
162
|
+
open: j,
|
|
163
|
+
handleCancel: V,
|
|
164
|
+
handleOk: M,
|
|
165
|
+
height: e.drawerHeight || 273,
|
|
166
|
+
children: /* @__PURE__ */ a.jsxs("div", { ref: I, className: n.bitzSelectWrapper, children: [
|
|
167
|
+
F(),
|
|
168
|
+
H(),
|
|
169
|
+
/* @__PURE__ */ a.jsxs("div", { className: n["picker-content"], children: [
|
|
170
|
+
/* @__PURE__ */ a.jsx(
|
|
171
|
+
"div",
|
|
172
|
+
{
|
|
173
|
+
className: `${n["mask-top"]} ${n["border-bottom-1px"]}`
|
|
174
|
+
}
|
|
175
|
+
),
|
|
176
|
+
/* @__PURE__ */ a.jsx(
|
|
177
|
+
"div",
|
|
178
|
+
{
|
|
179
|
+
className: `${n["mask-bottom"]} ${n["border-top-1px"]}`
|
|
180
|
+
}
|
|
181
|
+
),
|
|
182
|
+
/* @__PURE__ */ a.jsx("div", { className: n["wheel-wrapper"], children: /* @__PURE__ */ a.jsx("div", { className: n.wheel, children: /* @__PURE__ */ a.jsx("ul", { className: n["wheel-scroll"], children: K() }) }) })
|
|
183
|
+
] })
|
|
184
|
+
] })
|
|
185
|
+
}
|
|
186
|
+
)
|
|
148
187
|
] });
|
|
149
188
|
};
|
|
150
189
|
export {
|
|
151
|
-
|
|
190
|
+
te as default
|
|
152
191
|
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { j as s } from "../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { useMemo as b } from "react";
|
|
3
|
+
import { Space as u, Dropdown as c } from "antd";
|
|
4
|
+
import h from "../../BitzButton/index.mjs";
|
|
5
|
+
import g from "./style.mjs";
|
|
6
|
+
import w from "../../../node_modules/.store/@ant-design_icons@5.3.1/node_modules/@ant-design/icons/es/icons/PlusCircleFilled.mjs";
|
|
7
|
+
import B from "../../../node_modules/.store/@ant-design_icons@5.3.1/node_modules/@ant-design/icons/es/icons/CaretDownOutlined.mjs";
|
|
8
|
+
const F = ({
|
|
9
|
+
size: d,
|
|
10
|
+
add: i,
|
|
11
|
+
excel: t,
|
|
12
|
+
children: f
|
|
13
|
+
}) => {
|
|
14
|
+
const { blockCls: j, addBtnClassName: k, btnClassName: C } = g(d), y = b(() => {
|
|
15
|
+
var r, o, n, m, a, l, p, e;
|
|
16
|
+
return [
|
|
17
|
+
{
|
|
18
|
+
key: ((o = (r = t.menu) == null ? void 0 : r[0]) == null ? void 0 : o.key) || "download",
|
|
19
|
+
label: ((m = (n = t.menu) == null ? void 0 : n[0]) == null ? void 0 : m.label) || "Excel模板下载"
|
|
20
|
+
// icon: excel.menu?.[0]?.icon || (
|
|
21
|
+
// <CloudDownloadOutlined style={{ fontSize: 14 }} />
|
|
22
|
+
// ),
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
key: ((l = (a = t.menu) == null ? void 0 : a[1]) == null ? void 0 : l.key) || "import",
|
|
26
|
+
label: ((e = (p = t.menu) == null ? void 0 : p[1]) == null ? void 0 : e.label) || "Excel数据导入"
|
|
27
|
+
// icon: excel.menu?.[1]?.icon || (
|
|
28
|
+
// <CloudUploadOutlined style={{ fontSize: 14 }} />
|
|
29
|
+
// ),
|
|
30
|
+
},
|
|
31
|
+
...(t == null ? void 0 : t.otherMenu) ?? []
|
|
32
|
+
];
|
|
33
|
+
}, [t]);
|
|
34
|
+
return /* @__PURE__ */ s.jsxs(u.Compact, { className: j, style: { height: "100%" }, children: [
|
|
35
|
+
i.show !== !1 && /* @__PURE__ */ s.jsx(
|
|
36
|
+
h,
|
|
37
|
+
{
|
|
38
|
+
type: "primary",
|
|
39
|
+
icon: /* @__PURE__ */ s.jsx(w, {}),
|
|
40
|
+
onClick: i.onClick,
|
|
41
|
+
className: k,
|
|
42
|
+
children: i.text
|
|
43
|
+
}
|
|
44
|
+
),
|
|
45
|
+
f,
|
|
46
|
+
t.show !== !1 && /* @__PURE__ */ s.jsx(
|
|
47
|
+
c,
|
|
48
|
+
{
|
|
49
|
+
menu: { items: y, onClick: ({ key: r }) => {
|
|
50
|
+
var o;
|
|
51
|
+
return (o = t.onClick) == null ? void 0 : o.call(t, r);
|
|
52
|
+
} },
|
|
53
|
+
trigger: (t == null ? void 0 : t.trigger) || ["click"],
|
|
54
|
+
children: /* @__PURE__ */ s.jsx(h, { className: C, type: "text", children: /* @__PURE__ */ s.jsxs(u, { size: 6, children: [
|
|
55
|
+
/* @__PURE__ */ s.jsx("span", { children: t.text ?? "Excel文档导入" }),
|
|
56
|
+
/* @__PURE__ */ s.jsx(B, {})
|
|
57
|
+
] }) })
|
|
58
|
+
}
|
|
59
|
+
)
|
|
60
|
+
] });
|
|
61
|
+
};
|
|
62
|
+
export {
|
|
63
|
+
F as default
|
|
64
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { j as s } from "../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import e from "../../BitzButton/index.mjs";
|
|
3
|
+
import r from "./style.mjs";
|
|
4
|
+
const i = ({ ...t }) => {
|
|
5
|
+
const { btnClassName: o } = r();
|
|
6
|
+
return /* @__PURE__ */ s.jsx(e, { className: o, type: "text", ...t });
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
i as default
|
|
10
|
+
};
|
|
@@ -1,62 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import w from "../../../node_modules/.store/@ant-design_icons@5.3.1/node_modules/@ant-design/icons/es/icons/PlusCircleFilled.mjs";
|
|
7
|
-
import B from "../../../node_modules/.store/@ant-design_icons@5.3.1/node_modules/@ant-design/icons/es/icons/CaretDownOutlined.mjs";
|
|
8
|
-
const A = ({
|
|
9
|
-
size: h,
|
|
10
|
-
add: n,
|
|
11
|
-
excel: t
|
|
12
|
-
}) => {
|
|
13
|
-
const { blockCls: f, addBtnClassName: j, dropdownBtnClassName: k } = c(h), C = y(() => {
|
|
14
|
-
var s, r, i, m, a, l, p, e;
|
|
15
|
-
return [
|
|
16
|
-
{
|
|
17
|
-
key: ((r = (s = t.menu) == null ? void 0 : s[0]) == null ? void 0 : r.key) || "download",
|
|
18
|
-
label: ((m = (i = t.menu) == null ? void 0 : i[0]) == null ? void 0 : m.label) || "Excel模板下载"
|
|
19
|
-
// icon: excel.menu?.[0]?.icon || (
|
|
20
|
-
// <CloudDownloadOutlined style={{ fontSize: 14 }} />
|
|
21
|
-
// ),
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
key: ((l = (a = t.menu) == null ? void 0 : a[1]) == null ? void 0 : l.key) || "import",
|
|
25
|
-
label: ((e = (p = t.menu) == null ? void 0 : p[1]) == null ? void 0 : e.label) || "Excel数据导入"
|
|
26
|
-
// icon: excel.menu?.[1]?.icon || (
|
|
27
|
-
// <CloudUploadOutlined style={{ fontSize: 14 }} />
|
|
28
|
-
// ),
|
|
29
|
-
},
|
|
30
|
-
...(t == null ? void 0 : t.otherMenu) ?? []
|
|
31
|
-
];
|
|
32
|
-
}, [t]);
|
|
33
|
-
return /* @__PURE__ */ o.jsxs(u.Compact, { className: f, style: { height: "100%" }, children: [
|
|
34
|
-
n.show !== !1 && /* @__PURE__ */ o.jsx(
|
|
35
|
-
d,
|
|
36
|
-
{
|
|
37
|
-
type: "primary",
|
|
38
|
-
icon: /* @__PURE__ */ o.jsx(w, {}),
|
|
39
|
-
onClick: n.onClick,
|
|
40
|
-
className: j,
|
|
41
|
-
children: n.text
|
|
42
|
-
}
|
|
43
|
-
),
|
|
44
|
-
t.show !== !1 && /* @__PURE__ */ o.jsx(
|
|
45
|
-
b,
|
|
46
|
-
{
|
|
47
|
-
menu: { items: C, onClick: ({ key: s }) => {
|
|
48
|
-
var r;
|
|
49
|
-
return (r = t.onClick) == null ? void 0 : r.call(t, s);
|
|
50
|
-
} },
|
|
51
|
-
trigger: (t == null ? void 0 : t.trigger) || ["click"],
|
|
52
|
-
children: /* @__PURE__ */ o.jsx(d, { className: k, type: "text", children: /* @__PURE__ */ o.jsxs(u, { size: 8, children: [
|
|
53
|
-
/* @__PURE__ */ o.jsx("span", { children: t.text ?? "Excel文档导入" }),
|
|
54
|
-
/* @__PURE__ */ o.jsx(B, {})
|
|
55
|
-
] }) })
|
|
56
|
-
}
|
|
57
|
-
)
|
|
58
|
-
] });
|
|
59
|
-
};
|
|
1
|
+
import o from "./ActionBar.mjs";
|
|
2
|
+
import i from "./Button.mjs";
|
|
3
|
+
const t = o;
|
|
4
|
+
process.env.NODE_ENV !== "production" && (t.displayName = "BitzTableActionBar");
|
|
5
|
+
t.Button = i;
|
|
60
6
|
export {
|
|
61
|
-
|
|
7
|
+
t as default
|
|
62
8
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { useContext as
|
|
2
|
-
import { theme as
|
|
1
|
+
import { useContext as b, useMemo as z } from "react";
|
|
2
|
+
import { theme as B } from "antd";
|
|
3
3
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/extractStyle.mjs";
|
|
4
4
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/hooks/useCacheToken.mjs";
|
|
5
5
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/StyleContext.mjs";
|
|
@@ -9,57 +9,61 @@ import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@an
|
|
|
9
9
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/hooks/useCompatibleInsertionEffect.mjs";
|
|
10
10
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/hooks/useEffectCleanupRegister.mjs";
|
|
11
11
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/hooks/useHMR.mjs";
|
|
12
|
-
import
|
|
12
|
+
import T from "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/hooks/useStyleRegister.mjs";
|
|
13
13
|
import "../../../node_modules/.store/@ant-design_cssinjs@1.18.4/node_modules/@ant-design/cssinjs/es/transformers/legacyLogicalProperties.mjs";
|
|
14
|
-
import { TableContext as
|
|
15
|
-
import
|
|
16
|
-
const
|
|
17
|
-
const { theme:
|
|
14
|
+
import { TableContext as x } from "../Store/index.mjs";
|
|
15
|
+
import $ from "../../../node_modules/.store/classnames@2.5.1/node_modules/classnames/index.mjs";
|
|
16
|
+
const F = (m) => {
|
|
17
|
+
const { theme: d, hashId: n, token: a } = B.useToken(), { tableSize: s } = b(x), h = z(() => m ?? s ?? "lg", [m, s]), e = "bitzTableActionBarBlock", r = "actionBtn", c = "ActionBtn", l = "dropdownBtn", S = (o, i, t) => [
|
|
18
18
|
{
|
|
19
|
-
[`.${
|
|
19
|
+
[`.${o} .${i}`]: {
|
|
20
20
|
height: "100%",
|
|
21
21
|
borderRadius: 0,
|
|
22
|
-
paddingBlock: 0
|
|
22
|
+
paddingBlock: 0,
|
|
23
|
+
lineHeight: "normal",
|
|
24
|
+
".ant-btn-icon .anticon": {
|
|
25
|
+
verticalAlign: "-0.14em"
|
|
26
|
+
}
|
|
23
27
|
}
|
|
24
28
|
},
|
|
25
|
-
{ [`.${
|
|
26
|
-
{ [`.${
|
|
27
|
-
{ [`.${
|
|
28
|
-
{ [`.${
|
|
29
|
-
{ [`.${
|
|
30
|
-
],
|
|
29
|
+
{ [`.${o} .xl${t}`]: { fontSize: 14 } },
|
|
30
|
+
{ [`.${o} .lg${t}`]: { fontSize: 12 } },
|
|
31
|
+
{ [`.${o} .md${t}`]: { fontSize: 12 } },
|
|
32
|
+
{ [`.${o} .sm${t}`]: { fontSize: 12 } },
|
|
33
|
+
{ [`.${o} .xs${t}`]: { fontSize: 12 } }
|
|
34
|
+
], g = (o, i, t) => [
|
|
31
35
|
{
|
|
32
|
-
[`.${
|
|
36
|
+
[`.${o} .${i}`]: {
|
|
33
37
|
"&:hover": {
|
|
34
|
-
color: `${
|
|
35
|
-
background: "inherit !important"
|
|
38
|
+
color: `${t.colorText} !important`
|
|
36
39
|
},
|
|
37
40
|
"&:focus": {
|
|
38
|
-
color: `${
|
|
41
|
+
color: `${t.colorText} !important`
|
|
42
|
+
},
|
|
43
|
+
"&:disabled:hover": {
|
|
44
|
+
color: `${t.colorTextDisabled} !important`
|
|
45
|
+
},
|
|
46
|
+
"&:disabled:focus": {
|
|
47
|
+
color: `${t.colorTextDisabled} !important`
|
|
39
48
|
}
|
|
40
49
|
}
|
|
41
50
|
}
|
|
42
51
|
];
|
|
43
|
-
|
|
52
|
+
T(
|
|
44
53
|
{
|
|
45
|
-
theme:
|
|
54
|
+
theme: d,
|
|
46
55
|
token: a,
|
|
47
|
-
hashId:
|
|
56
|
+
hashId: n,
|
|
48
57
|
path: [e]
|
|
49
58
|
},
|
|
50
59
|
() => [
|
|
51
|
-
S(e,
|
|
52
|
-
|
|
60
|
+
S(e, r, c),
|
|
61
|
+
g(e, l, a)
|
|
53
62
|
]
|
|
54
63
|
);
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
c,
|
|
58
|
-
$,
|
|
59
|
-
r
|
|
60
|
-
);
|
|
61
|
-
return { blockCls: e, addBtnClassName: B, dropdownBtnClassName: g };
|
|
64
|
+
const p = `${h}${c}`, u = $(r, p, n), f = $(r, l, p, n);
|
|
65
|
+
return { blockCls: e, addBtnClassName: u, btnClassName: f };
|
|
62
66
|
};
|
|
63
67
|
export {
|
|
64
|
-
|
|
68
|
+
F as default
|
|
65
69
|
};
|