bitz-react-admin-ui 2.1.9 → 2.2.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/components/BitzPagination/index.d.ts +4 -0
- package/dist/components/BitzPagination/index.mjs +22 -21
- package/dist/components/BitzTable/ActionBar/ActionBar.mjs +26 -22
- package/dist/components/BitzTable/ActionCol/index.d.ts +1 -1
- package/dist/components/BitzTable/ActionCol/index.mjs +61 -61
- package/dist/components/BitzTable/SelectionBar/Button.d.ts +2 -3
- package/dist/components/BitzTable/SelectionBar/Button.mjs +19 -25
- package/dist/components/BitzTable/SelectionBar/SelectionBar.mjs +19 -38
- package/dist/components/BitzTable/Store/index.d.ts +43 -22
- package/dist/components/BitzTable/Store/index.mjs +128 -125
- package/dist/components/BitzTable/Store/utils/index.d.ts +4 -5
- package/dist/components/BitzTable/Store/utils/index.mjs +31 -31
- package/dist/components/BitzTable/SubTable/index.mjs +90 -106
- package/dist/components/BitzTable/Table/SortTableContext.d.ts +12 -0
- package/dist/components/BitzTable/Table/SortTableContext.mjs +25 -0
- package/dist/components/BitzTable/Table/SortableRow.d.ts +7 -0
- package/dist/components/BitzTable/Table/SortableRow.mjs +54 -0
- package/dist/components/BitzTable/Table/index.d.ts +14 -1
- package/dist/components/BitzTable/Table/index.mjs +319 -273
- package/dist/components/BitzTable/Table/style.d.ts +2 -1
- package/dist/components/BitzTable/Table/style.mjs +17 -15
- package/dist/components/BitzTable/Table/utils.mjs +17 -16
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.d.ts +1 -0
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.mjs +84 -97
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndItem.d.ts +5 -4
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndItem.mjs +66 -60
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndList.mjs +78 -72
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.d.ts +1 -3
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.mjs +190 -189
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndItem.d.ts +8 -0
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndItem.mjs +94 -0
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndList.d.ts +10 -0
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndList.mjs +58 -0
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/index.d.ts +13 -7
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/index.mjs +119 -80
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/index.d.ts +2 -2
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.mjs +26 -29
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/style.d.ts +3 -1
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/style.mjs +53 -77
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.d.ts +2 -2
- package/dist/components/BitzTable/ToolBar/ExportIcon/ExportModal.d.ts +12 -0
- package/dist/components/BitzTable/ToolBar/ExportIcon/ExportModal.mjs +61 -0
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.mjs +50 -59
- package/dist/components/BitzTable/ToolBar/FullscreenIcon/index.mjs +22 -23
- package/dist/components/BitzTable/ToolBar/Modal/index.d.ts +18 -0
- package/dist/components/BitzTable/ToolBar/Modal/index.mjs +50 -0
- package/dist/components/BitzTable/ToolBar/Modal/style.d.ts +2 -0
- package/dist/components/BitzTable/ToolBar/Modal/style.mjs +58 -0
- package/dist/components/BitzTable/ToolBar/RefreshIcon/index.mjs +21 -21
- package/dist/components/BitzTable/ToolBar/Wrapper/index.mjs +20 -22
- package/dist/components/BitzTable/ToolBar/index.d.ts +12 -11
- package/dist/components/BitzTable/ToolBar/style.mjs +41 -46
- package/dist/components/BitzTable/index.d.ts +4 -2
- package/dist/node_modules/.store/@ant-design_icons-svg@4.4.2/node_modules/@ant-design/icons-svg/es/asn/MenuOutlined.mjs +5 -0
- package/dist/node_modules/.store/@ant-design_icons@5.3.6/node_modules/@ant-design/icons/es/icons/MenuOutlined.mjs +15 -0
- package/dist/node_modules/.store/@dnd-kit_core@6.1.0/node_modules/@dnd-kit/core/dist/core.esm.mjs +1098 -753
- package/dist/style.css +1 -1
- package/dist/utils/findNode.d.ts +2 -2
- package/package.json +1 -1
- package/dist/components/BitzTable/Select/index.mjs +0 -11
- package/dist/components/BitzTable/Select/style.mjs +0 -66
- package/dist/components/BitzTable/ToolBar/ExportIcon/AnyDataTotalLabel.mjs +0 -78
- package/dist/components/BitzTable/ToolBar/ExportIcon/styles.mjs +0 -47
|
@@ -1,10 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
getExportConfig: () => any[];
|
|
1
|
+
import { ExportConfigProps, ExportResultConfigType } from '@/components/BitzTable/Store';
|
|
2
|
+
import { Ref } from 'react';
|
|
3
|
+
type BooleanConvertType<T extends boolean> = T extends false ? 'config' : 'export';
|
|
4
|
+
export interface ExportConfigImperativeProps<T extends ExportResultConfigType> {
|
|
5
|
+
getExportConfig: () => ExportConfigProps<T>;
|
|
7
6
|
hasOne: () => boolean;
|
|
8
7
|
}
|
|
9
|
-
|
|
8
|
+
interface ExportConfigComponentProps<T extends boolean> {
|
|
9
|
+
display: boolean;
|
|
10
|
+
parentHeight?: any;
|
|
11
|
+
showSelectRadio: T;
|
|
12
|
+
refInstance: Ref<ExportConfigImperativeProps<BooleanConvertType<T>>>;
|
|
13
|
+
}
|
|
14
|
+
declare function ExportConfig<T extends boolean>({ display, showSelectRadio, parentHeight, refInstance }: ExportConfigComponentProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
declare const _default: import("react").MemoExoticComponent<typeof ExportConfig>;
|
|
10
16
|
export default _default;
|
|
@@ -1,86 +1,125 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { BitzTableContext as
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
1
|
+
import { j as n } from "../../../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { BitzTableContext as A } from "../../../Store/index.mjs";
|
|
3
|
+
import D from "../../../../BitzTheme/index.mjs";
|
|
4
|
+
import { findParentFirstNodeByClass as L } from "../../../../../utils/findNode.mjs";
|
|
5
|
+
import M from "../../../../../node_modules/.store/ahooks@3.7.11/node_modules/ahooks/es/useSize/index.mjs";
|
|
6
|
+
import { Form as C, Flex as y, Checkbox as O, Radio as c, InputNumber as P, Select as G } from "antd";
|
|
7
|
+
import { memo as $, useRef as q, useMemo as h, useContext as F, useState as f, useEffect as H, useImperativeHandle as J } from "react";
|
|
8
|
+
import Q from "./DndList.mjs";
|
|
9
|
+
function R({
|
|
10
|
+
display: r,
|
|
11
|
+
showSelectRadio: d = !1,
|
|
12
|
+
parentHeight: g,
|
|
13
|
+
refInstance: I
|
|
14
|
+
}) {
|
|
15
|
+
D.useToken();
|
|
16
|
+
const v = q(null), t = M(v), N = h(() => ({
|
|
17
|
+
// display: display ? 'flex' : 'none'
|
|
18
|
+
width: r ? "100%" : 0,
|
|
19
|
+
height: "100%",
|
|
20
|
+
pointerEvents: r ? "auto" : "none",
|
|
21
|
+
opacity: r ? 1 : 0,
|
|
22
|
+
overflow: "hidden",
|
|
23
|
+
...r ? {} : {
|
|
24
|
+
position: "absolute",
|
|
25
|
+
left: 0,
|
|
26
|
+
right: 0
|
|
27
|
+
}
|
|
28
|
+
}), [r]), T = h(() => typeof g == "number" && (t != null && t.height) ? g - (t == null ? void 0 : t.height) - 20 : "auto", [g, t == null ? void 0 : t.height]), l = F(A).exportConfig, x = F(A).selected, [i, w] = f([]), [a, u] = f([]), [m, b] = f("current"), [k, E] = f("page"), [j, S] = f(1);
|
|
29
|
+
H(() => {
|
|
30
|
+
var e, s;
|
|
31
|
+
u(l.fields), w(l.fields.map((p) => p.field)), b(d && x ? "selectedRows" : l.config.key), E(((e = l.config.info) == null ? void 0 : e.type) ?? "page"), S(((s = l.config.info) == null ? void 0 : s.value) ?? 1);
|
|
32
|
+
}, [l, d, x]);
|
|
33
|
+
const o = h(() => a.filter((e) => e.show).map((e) => e.field), [a]), B = h(() => i.length === o.length, [i, o]), V = h(() => o.length > 0 && o.length < i.length, [o, i]), z = ({ target: e }) => {
|
|
34
|
+
u(a.map((s) => ({ ...s, show: e.checked })));
|
|
35
|
+
}, K = (e, s) => {
|
|
36
|
+
u(e), w(s);
|
|
37
|
+
};
|
|
38
|
+
return J(I, () => ({
|
|
39
|
+
getExportConfig: () => {
|
|
40
|
+
const e = {
|
|
41
|
+
fields: [],
|
|
42
|
+
config: {
|
|
43
|
+
key: m,
|
|
44
|
+
info: void 0
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
return a.forEach((s) => {
|
|
48
|
+
let p = !1;
|
|
49
|
+
o.includes(s.field) && (p = !0), e.fields.push({ ...s, show: p });
|
|
50
|
+
}), m === "any" && (e.config.info = {
|
|
51
|
+
type: k,
|
|
52
|
+
value: (j || 0) < 1 ? 1 : j || 1
|
|
53
|
+
}), e;
|
|
54
|
+
},
|
|
55
|
+
hasOne: () => o.length > 0
|
|
56
|
+
})), /* @__PURE__ */ n.jsxs(
|
|
57
|
+
C,
|
|
58
|
+
{
|
|
59
|
+
style: N,
|
|
60
|
+
labelCol: { span: 3 },
|
|
61
|
+
labelAlign: "left",
|
|
62
|
+
colon: !1,
|
|
63
|
+
className: "exportConfigFormContent",
|
|
64
|
+
children: [
|
|
65
|
+
/* @__PURE__ */ n.jsx(C.Item, { label: "导出字段", className: "exportFields", children: /* @__PURE__ */ n.jsxs(y, { vertical: !0, style: { gap: 8, maxHeight: T }, children: [
|
|
66
|
+
/* @__PURE__ */ n.jsx(
|
|
67
|
+
O,
|
|
68
|
+
{
|
|
69
|
+
checked: B,
|
|
70
|
+
indeterminate: V,
|
|
71
|
+
onChange: z,
|
|
72
|
+
style: { alignSelf: "flex-start" },
|
|
73
|
+
children: "全选"
|
|
74
|
+
}
|
|
75
|
+
),
|
|
76
|
+
/* @__PURE__ */ n.jsx(
|
|
77
|
+
Q,
|
|
78
|
+
{
|
|
79
|
+
dataList: a,
|
|
80
|
+
keys: i,
|
|
81
|
+
onChange: u,
|
|
82
|
+
onMoveEnd: K
|
|
83
|
+
}
|
|
84
|
+
)
|
|
85
|
+
] }) }),
|
|
86
|
+
/* @__PURE__ */ n.jsx(C.Item, { label: "导出设置", className: "exportTotal", children: /* @__PURE__ */ n.jsx(c.Group, { ref: v, value: m, onChange: ({ target: e }) => b(e.value), children: /* @__PURE__ */ n.jsxs(y, { vertical: !0, gap: 8, align: "flex-start", children: [
|
|
87
|
+
d && x && /* @__PURE__ */ n.jsx(c, { value: "selectedRows", children: /* @__PURE__ */ n.jsx("span", { style: { whiteSpace: "nowrap" }, children: "导出选中数据" }) }),
|
|
88
|
+
/* @__PURE__ */ n.jsx(c, { value: "current", children: /* @__PURE__ */ n.jsx("span", { style: { whiteSpace: "nowrap" }, children: "仅导出当前页" }) }),
|
|
89
|
+
/* @__PURE__ */ n.jsx(c, { value: "any", children: /* @__PURE__ */ n.jsxs(y, { align: "center", gap: 8, children: [
|
|
90
|
+
/* @__PURE__ */ n.jsx("span", { style: { whiteSpace: "nowrap" }, children: "导出" }),
|
|
91
|
+
/* @__PURE__ */ n.jsx(
|
|
92
|
+
P,
|
|
40
93
|
{
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
94
|
+
controls: !1,
|
|
95
|
+
min: 1,
|
|
96
|
+
value: j,
|
|
97
|
+
onChange: (e) => S(e),
|
|
98
|
+
style: { width: 120 },
|
|
99
|
+
addonAfter: /* @__PURE__ */ n.jsx(
|
|
100
|
+
G,
|
|
101
|
+
{
|
|
102
|
+
value: k,
|
|
103
|
+
onChange: E,
|
|
104
|
+
options: [
|
|
105
|
+
{ label: "页", value: "page" },
|
|
106
|
+
{ label: "条", value: "pieces" }
|
|
107
|
+
],
|
|
108
|
+
onClick: (e) => e.preventDefault(),
|
|
109
|
+
getPopupContainer: (e) => L(e, "containerBody")
|
|
110
|
+
}
|
|
111
|
+
)
|
|
45
112
|
}
|
|
46
113
|
),
|
|
47
|
-
/* @__PURE__ */
|
|
114
|
+
/* @__PURE__ */ n.jsx("span", { style: { whiteSpace: "nowrap" }, children: "数据" })
|
|
48
115
|
] }) }),
|
|
49
|
-
/* @__PURE__ */
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
controls: !1,
|
|
57
|
-
min: 1,
|
|
58
|
-
value: k,
|
|
59
|
-
onChange: (e) => y(e),
|
|
60
|
-
style: { width: 120 },
|
|
61
|
-
addonAfter: /* @__PURE__ */ t.jsx(
|
|
62
|
-
I,
|
|
63
|
-
{
|
|
64
|
-
value: v,
|
|
65
|
-
onChange: w,
|
|
66
|
-
options: [
|
|
67
|
-
{ label: "页", value: "page" },
|
|
68
|
-
{ label: "条", value: "pieces" }
|
|
69
|
-
],
|
|
70
|
-
onClick: (e) => e.preventDefault()
|
|
71
|
-
}
|
|
72
|
-
)
|
|
73
|
-
}
|
|
74
|
-
),
|
|
75
|
-
/* @__PURE__ */ t.jsx("span", { children: "数据" })
|
|
76
|
-
] }) }),
|
|
77
|
-
/* @__PURE__ */ t.jsx(o, { value: "all", children: "导出全部数据" })
|
|
78
|
-
] }) }) })
|
|
79
|
-
]
|
|
80
|
-
}
|
|
81
|
-
);
|
|
82
|
-
}
|
|
83
|
-
), M = B(G);
|
|
116
|
+
/* @__PURE__ */ n.jsx(c, { value: "all", children: /* @__PURE__ */ n.jsx("span", { style: { whiteSpace: "nowrap" }, children: "导出全部数据" }) })
|
|
117
|
+
] }) }) })
|
|
118
|
+
]
|
|
119
|
+
}
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
const te = $(R);
|
|
84
123
|
export {
|
|
85
|
-
|
|
124
|
+
te as default
|
|
86
125
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { FormInstance } from 'antd';
|
|
3
|
-
interface
|
|
3
|
+
interface StylesConfigComponentProps {
|
|
4
4
|
display: boolean;
|
|
5
5
|
}
|
|
6
6
|
export interface StylesConfigImperativeProps {
|
|
7
7
|
getFormInstance: () => FormInstance<any>;
|
|
8
8
|
}
|
|
9
|
-
declare const _default: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<
|
|
9
|
+
declare const _default: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<StylesConfigComponentProps & import("react").RefAttributes<StylesConfigImperativeProps>>>;
|
|
10
10
|
export default _default;
|
|
@@ -1,43 +1,40 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import {
|
|
3
|
-
import { Tooltip as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import y from "
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
})), []), f ? /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
15
|
-
/* @__PURE__ */ e.jsx(
|
|
16
|
-
b,
|
|
1
|
+
import { j as t } from "../../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { useContext as x, useState as C, useMemo as d } from "react";
|
|
3
|
+
import { Tooltip as g } from "antd";
|
|
4
|
+
import j from "./ColumnConfigModal.mjs";
|
|
5
|
+
import h from "../style.mjs";
|
|
6
|
+
import p from "../../../BitzButton/index.mjs";
|
|
7
|
+
import { BitzTableContext as y } from "../../Store/index.mjs";
|
|
8
|
+
import B from "../../../../node_modules/.store/@ant-design_icons@5.3.6/node_modules/@ant-design/icons/es/icons/SettingOutlined.mjs";
|
|
9
|
+
const o = "表格设置", v = (e) => {
|
|
10
|
+
const { order: l, show: i = !0, icon: m = /* @__PURE__ */ t.jsx(B, {}) } = e, { fullscreen: n } = x(y), { toolbarItemClassName: a } = h(), [c, s] = C(!1), f = d(() => n ? !1 : void 0, [n]);
|
|
11
|
+
return i ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
12
|
+
/* @__PURE__ */ t.jsx(
|
|
13
|
+
j,
|
|
17
14
|
{
|
|
18
|
-
open:
|
|
15
|
+
open: c,
|
|
19
16
|
title: o,
|
|
20
|
-
onChange: async (...
|
|
21
|
-
var
|
|
22
|
-
return (
|
|
17
|
+
onChange: async (...u) => {
|
|
18
|
+
var r;
|
|
19
|
+
return (r = e.onChange) == null ? void 0 : r.call(e, ...u);
|
|
23
20
|
},
|
|
24
|
-
getContainer:
|
|
25
|
-
close: () =>
|
|
21
|
+
getContainer: f,
|
|
22
|
+
close: () => s(!1)
|
|
26
23
|
}
|
|
27
24
|
),
|
|
28
|
-
/* @__PURE__ */
|
|
29
|
-
|
|
25
|
+
/* @__PURE__ */ t.jsx(g, { title: o, open: !1, children: /* @__PURE__ */ t.jsx(
|
|
26
|
+
p,
|
|
30
27
|
{
|
|
31
28
|
type: "text",
|
|
32
|
-
className:
|
|
33
|
-
onClick: () =>
|
|
34
|
-
icon:
|
|
35
|
-
style: { order:
|
|
29
|
+
className: a,
|
|
30
|
+
onClick: () => s(!0),
|
|
31
|
+
icon: m,
|
|
32
|
+
style: { order: l },
|
|
36
33
|
children: o
|
|
37
34
|
}
|
|
38
35
|
) })
|
|
39
36
|
] }) : null;
|
|
40
37
|
};
|
|
41
38
|
export {
|
|
42
|
-
|
|
39
|
+
v as default
|
|
43
40
|
};
|
|
@@ -1,2 +1,4 @@
|
|
|
1
1
|
import { BitzGlobalToken } from '@/components/BitzTheme';
|
|
2
|
-
export declare const
|
|
2
|
+
export declare const columnsSortStyles: (token: BitzGlobalToken) => string;
|
|
3
|
+
export declare const appearanceConfigStyles: (token: BitzGlobalToken) => string;
|
|
4
|
+
export declare const exportConfigStyles: (token: BitzGlobalToken) => string;
|
|
@@ -2,7 +2,7 @@ import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/
|
|
|
2
2
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useCacheToken.mjs";
|
|
3
3
|
import "react";
|
|
4
4
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/StyleContext.mjs";
|
|
5
|
-
import { unit as
|
|
5
|
+
import { unit as r } from "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/util/index.mjs";
|
|
6
6
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useCompatibleInsertionEffect.mjs";
|
|
7
7
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useEffectCleanupRegister.mjs";
|
|
8
8
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/hooks/useHMR.mjs";
|
|
@@ -10,32 +10,8 @@ import "../../../../node_modules/.store/rc-util@5.39.1/node_modules/rc-util/es/w
|
|
|
10
10
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/theme/createTheme.mjs";
|
|
11
11
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/theme/ThemeCache.mjs";
|
|
12
12
|
import "../../../../node_modules/.store/@ant-design_cssinjs@1.19.1/node_modules/@ant-design/cssinjs/es/transformers/legacyLogicalProperties.mjs";
|
|
13
|
-
import { css as
|
|
14
|
-
const
|
|
15
|
-
var a, i, t;
|
|
16
|
-
return r`
|
|
17
|
-
.ant-modal-content {
|
|
18
|
-
background-color: ${(a = o.Modal) == null ? void 0 : a.contentBg};
|
|
19
|
-
|
|
20
|
-
.ant-modal-header {
|
|
21
|
-
font-size: 16px;
|
|
22
|
-
font-weight: 700;
|
|
23
|
-
background-color: ${(i = o.Modal) == null ? void 0 : i.headerBg};
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.ant-modal-body {
|
|
27
|
-
overflow: hidden auto;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.ant-modal-footer {
|
|
31
|
-
text-align: left;
|
|
32
|
-
margin: 0;
|
|
33
|
-
padding: 20px;
|
|
34
|
-
background-color: ${(t = o.Modal) == null ? void 0 : t.footerBg};
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
`;
|
|
38
|
-
}, l = (o) => r`
|
|
13
|
+
import { css as i } from "../../../../node_modules/.store/@emotion_css@11.11.2/node_modules/@emotion/css/dist/emotion-css.esm.mjs";
|
|
14
|
+
const m = (o) => i`
|
|
39
15
|
.sortContent {
|
|
40
16
|
width: 100%;
|
|
41
17
|
height: 100%;
|
|
@@ -47,8 +23,8 @@ const n = (o) => {
|
|
|
47
23
|
width: 100%;
|
|
48
24
|
height: 100%;
|
|
49
25
|
background-color: var(--sortCard-bgColor);
|
|
50
|
-
border-radius: ${
|
|
51
|
-
padding: 6px;
|
|
26
|
+
border-radius: ${r(o.borderRadius)};
|
|
27
|
+
padding-inline: 6px;
|
|
52
28
|
padding-block-end: 10px;
|
|
53
29
|
box-sizing: border-box;
|
|
54
30
|
|
|
@@ -56,22 +32,36 @@ const n = (o) => {
|
|
|
56
32
|
color: var(--sortCard-titleColor);
|
|
57
33
|
margin: 0;
|
|
58
34
|
padding-inline: 8px;
|
|
59
|
-
padding-block-start:
|
|
35
|
+
padding-block-start: 10px;
|
|
36
|
+
background-color: var(--sortCard-bgColor);
|
|
37
|
+
position: sticky;
|
|
38
|
+
top: 0;
|
|
39
|
+
z-index: 10;
|
|
60
40
|
}
|
|
61
41
|
|
|
62
42
|
.sortList {
|
|
63
43
|
flex: 1;
|
|
64
44
|
width: 100%;
|
|
65
|
-
/* height: calc(100% - 30px); */
|
|
66
45
|
/* overflow: hidden auto; */
|
|
67
46
|
cursor: grab;
|
|
68
47
|
|
|
69
|
-
&:has(.
|
|
48
|
+
&:has(.sortItemDragging) {
|
|
70
49
|
cursor: grabbing;
|
|
71
50
|
}
|
|
72
51
|
|
|
73
52
|
.sortItem {
|
|
74
|
-
|
|
53
|
+
display: grid;
|
|
54
|
+
align-items: center;
|
|
55
|
+
/* 16px是.dragIcon的padding-inline乘以2 */
|
|
56
|
+
--dragIcon-width: calc(16px + ${r(o.fontSize + 4)});
|
|
57
|
+
/* 16px是.operation的padding-inline-end加上margin-left */
|
|
58
|
+
--operation-width: calc(${r(o.fontSize + 4)} * 2 + 16px);
|
|
59
|
+
grid-template-columns: var(--dragIcon-width) calc(100% - var(--dragIcon-width));
|
|
60
|
+
border-radius: ${r(o.borderRadius)};
|
|
61
|
+
|
|
62
|
+
&.showSortItemOperat {
|
|
63
|
+
grid-template-columns: var(--dragIcon-width) calc(100% - var(--dragIcon-width) - var(--operation-width)) var(--operation-width);
|
|
64
|
+
}
|
|
75
65
|
|
|
76
66
|
&:hover {
|
|
77
67
|
background-color: ${o.colorBgContainer};
|
|
@@ -135,7 +125,7 @@ const n = (o) => {
|
|
|
135
125
|
}
|
|
136
126
|
}
|
|
137
127
|
}
|
|
138
|
-
`,
|
|
128
|
+
`, u = (o) => i`
|
|
139
129
|
.stylesConfigFormContent {
|
|
140
130
|
display: flex;
|
|
141
131
|
flex-direction: column;
|
|
@@ -171,6 +161,7 @@ const n = (o) => {
|
|
|
171
161
|
flex: 1;
|
|
172
162
|
display: flex;
|
|
173
163
|
align-items: flex-end;
|
|
164
|
+
margin-block: 60px 0;
|
|
174
165
|
}
|
|
175
166
|
|
|
176
167
|
.ant-radio-wrapper {
|
|
@@ -180,7 +171,7 @@ const n = (o) => {
|
|
|
180
171
|
font-weight: normal !important;
|
|
181
172
|
background-color: ${o.colorBgLayout};
|
|
182
173
|
background-color: var(--radioCard-bgColor);
|
|
183
|
-
border-radius: ${
|
|
174
|
+
border-radius: ${r(o.borderRadiusLG)};
|
|
184
175
|
margin-inline-end: 0;
|
|
185
176
|
box-sizing: border-box;
|
|
186
177
|
position: relative;
|
|
@@ -220,7 +211,7 @@ const n = (o) => {
|
|
|
220
211
|
}
|
|
221
212
|
}
|
|
222
213
|
}
|
|
223
|
-
`,
|
|
214
|
+
`, w = (o) => i`
|
|
224
215
|
.exportConfigFormContent {
|
|
225
216
|
display: flex;
|
|
226
217
|
flex-direction: column;
|
|
@@ -235,60 +226,45 @@ const n = (o) => {
|
|
|
235
226
|
}
|
|
236
227
|
}
|
|
237
228
|
|
|
238
|
-
.
|
|
229
|
+
.sortList {
|
|
230
|
+
flex: 1;
|
|
231
|
+
overflow: hidden auto;
|
|
239
232
|
display: grid;
|
|
240
|
-
grid-template-columns: repeat(3,
|
|
233
|
+
grid-template-columns: repeat(3, 161px);
|
|
241
234
|
gap: 8px;
|
|
235
|
+
margin-left: -2px;
|
|
242
236
|
|
|
243
|
-
.
|
|
244
|
-
|
|
245
|
-
-webkit-line-clamp: 1;
|
|
246
|
-
-webkit-box-orient: vertical;
|
|
247
|
-
overflow: hidden;
|
|
248
|
-
text-overflow: ellipsis;
|
|
249
|
-
}
|
|
250
|
-
}
|
|
251
|
-
}
|
|
252
|
-
`, v = (o) => r`
|
|
253
|
-
&.tableConfigModal {
|
|
254
|
-
${n(o)}
|
|
255
|
-
|
|
256
|
-
.pointerCursor {
|
|
257
|
-
cursor: pointer;
|
|
258
|
-
}
|
|
237
|
+
&:has(.sortItemDragging) {
|
|
238
|
+
cursor: grabbing;
|
|
259
239
|
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
.ant-card-body {
|
|
264
|
-
display: flex;
|
|
265
|
-
flex-direction: column;
|
|
266
|
-
align-items: center;
|
|
267
|
-
gap: 24px;
|
|
268
|
-
|
|
269
|
-
&::before,
|
|
270
|
-
&::after {
|
|
271
|
-
content: none;
|
|
240
|
+
.dragIcon {
|
|
241
|
+
cursor: inherit;
|
|
272
242
|
}
|
|
273
243
|
}
|
|
274
244
|
|
|
275
|
-
.
|
|
245
|
+
.ant-checkbox-wrapper {
|
|
246
|
+
width: calc(100% - 8px - ${r(o.fontSize)});
|
|
276
247
|
}
|
|
277
248
|
|
|
278
|
-
.
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
${
|
|
284
|
-
|
|
285
|
-
|
|
249
|
+
.ant-checkbox-wrapper > span:last-child {
|
|
250
|
+
padding-right: 0;
|
|
251
|
+
/* display: -webkit-box;
|
|
252
|
+
-webkit-line-clamp: 1;
|
|
253
|
+
-webkit-box-orient: vertical; */
|
|
254
|
+
width: calc(100% - 8px - ${r(o.fontSize)});
|
|
255
|
+
white-space: nowrap;
|
|
256
|
+
overflow: hidden;
|
|
257
|
+
text-overflow: ellipsis;
|
|
258
|
+
}
|
|
286
259
|
|
|
287
|
-
|
|
260
|
+
.dragIcon {
|
|
261
|
+
cursor: grab;
|
|
288
262
|
}
|
|
289
263
|
}
|
|
290
264
|
}
|
|
291
265
|
`;
|
|
292
266
|
export {
|
|
293
|
-
|
|
267
|
+
u as appearanceConfigStyles,
|
|
268
|
+
m as columnsSortStyles,
|
|
269
|
+
w as exportConfigStyles
|
|
294
270
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { ExportResultExprotKeyType } from '../../Store';
|
|
3
3
|
interface AnyDataTotalLabelProps {
|
|
4
|
-
onClick: (key:
|
|
4
|
+
onClick: (key: ExportResultExprotKeyType, info: {
|
|
5
5
|
value: number;
|
|
6
6
|
type: 'page' | 'pieces';
|
|
7
7
|
}) => void;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ModalProps } from 'antd';
|
|
2
|
+
import { FC } from 'react';
|
|
3
|
+
import { ExportConfigProps } from '../../Store';
|
|
4
|
+
export interface ExportModalProps {
|
|
5
|
+
open: boolean;
|
|
6
|
+
close: () => void;
|
|
7
|
+
title: string;
|
|
8
|
+
onExport?: (val: ExportConfigProps<'export'>) => Promise<void>;
|
|
9
|
+
getContainer: ModalProps['getContainer'];
|
|
10
|
+
}
|
|
11
|
+
declare const ExportModal: FC<ExportModalProps>;
|
|
12
|
+
export default ExportModal;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { j as e } from "../../../../node_modules/.store/react@18.2.0/node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { message as y } from "antd";
|
|
3
|
+
import { useState as m, useContext as E, useRef as b, useMemo as B } from "react";
|
|
4
|
+
import { BitzTableContext as O } from "../../Store/index.mjs";
|
|
5
|
+
import c from "../../../BitzButton/index.mjs";
|
|
6
|
+
import R from "../../../BitzTheme/index.mjs";
|
|
7
|
+
import T from "../Modal/index.mjs";
|
|
8
|
+
import z from "../ColConfigIcon/ExportConfig/index.mjs";
|
|
9
|
+
import M from "../../../../node_modules/.store/@ant-design_icons@5.3.6/node_modules/@ant-design/icons/es/icons/CheckCircleOutlined.mjs";
|
|
10
|
+
const q = ({
|
|
11
|
+
open: u,
|
|
12
|
+
title: p,
|
|
13
|
+
onExport: s,
|
|
14
|
+
close: o,
|
|
15
|
+
getContainer: d
|
|
16
|
+
}) => {
|
|
17
|
+
const { token: i } = R.useToken(), [x, r] = m(!1), [g, t] = m(!1), { defaultTableExportConfig: h } = E(O), n = b(null), C = async () => {
|
|
18
|
+
var f, l;
|
|
19
|
+
if (g)
|
|
20
|
+
return;
|
|
21
|
+
if (t(!0), !((f = n.current) == null ? void 0 : f.hasOne())) {
|
|
22
|
+
y.error("导出设置至少需要一个字段"), t(!1);
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
const k = ((l = n.current) == null ? void 0 : l.getExportConfig()) ?? h;
|
|
26
|
+
s && (t(!1), r(!0), s(k).finally(() => {
|
|
27
|
+
r(!1), o();
|
|
28
|
+
}));
|
|
29
|
+
};
|
|
30
|
+
B(() => i.mode === "dark", [i.mode]);
|
|
31
|
+
const j = () => {
|
|
32
|
+
r(!1), t(!1);
|
|
33
|
+
};
|
|
34
|
+
return /* @__PURE__ */ e.jsx(
|
|
35
|
+
T,
|
|
36
|
+
{
|
|
37
|
+
open: u,
|
|
38
|
+
title: p,
|
|
39
|
+
close: o,
|
|
40
|
+
closeAfter: j,
|
|
41
|
+
getContainer: d,
|
|
42
|
+
footer: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
43
|
+
/* @__PURE__ */ e.jsx(
|
|
44
|
+
c,
|
|
45
|
+
{
|
|
46
|
+
type: "primary",
|
|
47
|
+
icon: /* @__PURE__ */ e.jsx(M, {}),
|
|
48
|
+
onClick: C,
|
|
49
|
+
loading: x,
|
|
50
|
+
children: "导出"
|
|
51
|
+
}
|
|
52
|
+
),
|
|
53
|
+
/* @__PURE__ */ e.jsx(c, { onClick: o, children: "取消" })
|
|
54
|
+
] }),
|
|
55
|
+
children: (a) => /* @__PURE__ */ e.jsx(z, { parentHeight: a, refInstance: n, display: !0, showSelectRadio: !0 })
|
|
56
|
+
}
|
|
57
|
+
);
|
|
58
|
+
};
|
|
59
|
+
export {
|
|
60
|
+
q as default
|
|
61
|
+
};
|