bitz-react-admin-ui 2.7.5 → 2.7.6
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/dayjs.min.mjs +5 -2
- package/dist/_virtual/dayjs.min2.mjs +4 -0
- package/dist/assets/iconfont/IconChenggong.mjs +25 -4
- package/dist/assets/iconfont/IconClose.mjs +24 -3
- package/dist/assets/iconfont/IconColumnCancelFixed.mjs +23 -2
- package/dist/assets/iconfont/IconColumnFixedLeft.mjs +27 -6
- package/dist/assets/iconfont/IconColumnFixedRight.mjs +27 -6
- package/dist/assets/iconfont/IconCuowu.mjs +23 -2
- package/dist/assets/iconfont/IconDragOrder.mjs +25 -4
- package/dist/assets/iconfont/IconDuigoux.mjs +25 -4
- package/dist/assets/iconfont/IconFabu.mjs +35 -5
- package/dist/assets/iconfont/IconFanhui.mjs +25 -4
- package/dist/assets/iconfont/IconGaojisousuo.mjs +26 -5
- package/dist/assets/iconfont/IconHangfengexian.mjs +41 -3
- package/dist/assets/iconfont/IconHangliefengexian.mjs +42 -4
- package/dist/assets/iconfont/IconIcFluentHomeRegular.mjs +26 -5
- package/dist/assets/iconfont/IconIcon21.mjs +25 -4
- package/dist/assets/iconfont/IconJincoude.mjs +25 -4
- package/dist/assets/iconfont/IconJinggao.mjs +25 -4
- package/dist/assets/iconfont/IconKuansongde.mjs +26 -5
- package/dist/assets/iconfont/IconLiefengexian.mjs +41 -3
- package/dist/assets/iconfont/IconMore.mjs +41 -4
- package/dist/assets/iconfont/IconShanchu.mjs +27 -6
- package/dist/assets/iconfont/IconShanchu1.mjs +35 -5
- package/dist/assets/iconfont/IconSousuo.mjs +27 -6
- package/dist/assets/iconfont/IconTejincou.mjs +25 -4
- package/dist/assets/iconfont/IconTekuansong.mjs +26 -5
- package/dist/assets/iconfont/IconTishi1.mjs +27 -6
- package/dist/assets/iconfont/IconTuodong.mjs +28 -7
- package/dist/assets/iconfont/IconWubanmawentianchong.mjs +35 -3
- package/dist/assets/iconfont/IconWufengexian.mjs +26 -4
- package/dist/assets/iconfont/IconXinxitishi.mjs +27 -6
- package/dist/assets/iconfont/IconYoubanmawentianchong.mjs +34 -3
- package/dist/assets/iconfont/IconZhongdengde.mjs +24 -3
- package/dist/assets/iconfont/IconZhongzhi.mjs +24 -3
- package/dist/assets/iconfont/index.mjs +33 -33
- package/dist/components/BitzAddTag/index.mjs +41 -8
- package/dist/components/BitzAddressBook/index.mjs +122 -35
- package/dist/components/BitzAppPage/index.mjs +18 -4
- package/dist/components/BitzAppRefresh/index.mjs +27 -15
- package/dist/components/BitzBetterScroll/index.mjs +5 -5
- package/dist/components/BitzButton/index.mjs +23 -9
- package/dist/components/BitzCalendar/index.mjs +53 -20
- package/dist/components/BitzCascader/BitzCascaderMobile.mjs +68 -30
- package/dist/components/BitzCascader/index.mjs +6 -2
- package/dist/components/BitzCollapse/index.mjs +4 -4
- package/dist/components/BitzConfigProvider/context.mjs +3 -1
- package/dist/components/BitzConfigProvider/index.mjs +12 -8
- package/dist/components/BitzConfirmModal/index.mjs +24 -1
- package/dist/components/BitzDayJs/index.mjs +1 -1
- package/dist/components/BitzDescriptions/index.mjs +11 -1
- package/dist/components/BitzDrawer/index.mjs +17 -2
- package/dist/components/BitzEmpty/index.mjs +6 -2
- package/dist/components/BitzException/index.mjs +6 -1
- package/dist/components/BitzFloatLayout/index.mjs +10 -1
- package/dist/components/BitzFluentDatePicker/index.mjs +1 -1
- package/dist/components/BitzFluentRangePicker/index.mjs +1 -1
- package/dist/components/BitzFluentRangeTimePicker/index.mjs +1 -1
- package/dist/components/BitzFluentTimePicker/index.mjs +6 -6
- package/dist/components/BitzFuiCalendar/BitzFuiCalendarStore.mjs +13 -16
- package/dist/components/BitzFuiCalendar/CalendarAgendum.mjs +27 -21
- package/dist/components/BitzFuiCalendar/CalendarAgendumItem.mjs +22 -4
- package/dist/components/BitzFuiCalendar/CalendarBody.mjs +28 -5
- package/dist/components/BitzFuiCalendar/CalendarHead.mjs +6 -3
- package/dist/components/BitzFuiCalendar/CalendarHeadItem.mjs +13 -4
- package/dist/components/BitzFuiCalendar/CalendarToolbar.mjs +48 -16
- package/dist/components/BitzFuiCalendar/ColumnData.mjs +26 -10
- package/dist/components/BitzFuiCalendar/FuiCalendarItem.mjs +44 -8
- package/dist/components/BitzFuiCalendar/index.mjs +7 -1
- package/dist/components/BitzFullScreen/index.mjs +9 -6
- package/dist/components/BitzHighlight/Child.mjs +23 -9
- package/dist/components/BitzHighlight/Highlight.mjs +26 -5
- package/dist/components/BitzHighlight/chunks.mjs +20 -17
- package/dist/components/BitzHighlight/style.mjs +4 -1
- package/dist/components/BitzImage/index.mjs +1 -1
- package/dist/components/BitzImage/previewImage.mjs +12 -5
- package/dist/components/BitzLanguageTabs/index.mjs +14 -3
- package/dist/components/BitzLazyLoad/index.mjs +7 -1
- package/dist/components/BitzList/List.mjs +17 -3
- package/dist/components/BitzList/LoadMore.mjs +29 -20
- package/dist/components/BitzLoadMore/index.mjs +34 -14
- package/dist/components/BitzMeetingTime/BitzMeetingTimeItem.mjs +25 -12
- package/dist/components/BitzMeetingTime/index.mjs +11 -7
- package/dist/components/BitzMobileLoading/index.mjs +1 -1
- package/dist/components/BitzModal/index.mjs +24 -11
- package/dist/components/BitzNoData/index.mjs +4 -1
- package/dist/components/BitzNoMore/index.mjs +1 -1
- package/dist/components/BitzOrganizationSelection/index.mjs +43 -14
- package/dist/components/BitzPageContainer/index.mjs +107 -46
- package/dist/components/BitzPageHeader/index.mjs +89 -21
- package/dist/components/BitzPagination/index.mjs +71 -22
- package/dist/components/BitzPopover/index.mjs +4 -4
- package/dist/components/BitzPullRefresh/PullRefresh.mjs +47 -18
- package/dist/components/BitzQRCode/index.mjs +6 -1
- package/dist/components/BitzQueryFilter/QueryFilterContent.mjs +35 -17
- package/dist/components/BitzQueryFilter/QueryFilterDrawer.mjs +20 -13
- package/dist/components/BitzQueryFilter/QueryFilterMobile.mjs +4 -1
- package/dist/components/BitzQueryFilter/index.mjs +69 -20
- package/dist/components/BitzRefresh/index.mjs +5 -1
- package/dist/components/BitzRemark/index.mjs +4 -4
- package/dist/components/BitzScheduleCenter/index.mjs +24 -30
- package/dist/components/BitzSearch/index.mjs +1 -1
- package/dist/components/BitzSelect/component/BitzSelectMobile.mjs +123 -48
- package/dist/components/BitzSelect/index.mjs +1 -1
- package/dist/components/BitzSkeleton/index.mjs +31 -1
- package/dist/components/BitzSwitch/index.mjs +7 -2
- package/dist/components/BitzTabbar/BitzTabbar.mjs +25 -8
- package/dist/components/BitzTabbar/BitzTabbarItem.mjs +4 -1
- package/dist/components/BitzTable/ActionBar/ActionBar.mjs +80 -12
- package/dist/components/BitzTable/ActionBar/Button.mjs +20 -15
- package/dist/components/BitzTable/ActionBar/style.mjs +12 -9
- package/dist/components/BitzTable/ActionCol/index.mjs +183 -58
- package/dist/components/BitzTable/ActionCol/style.mjs +15 -12
- package/dist/components/BitzTable/Dropdown/index.mjs +8 -1
- package/dist/components/BitzTable/Dropdown/style.mjs +9 -6
- package/dist/components/BitzTable/SelectionBar/Button.mjs +19 -6
- package/dist/components/BitzTable/SelectionBar/SelectionBar.mjs +11 -4
- package/dist/components/BitzTable/SelectionBar/style.mjs +18 -8
- package/dist/components/BitzTable/Store/index.mjs +103 -62
- package/dist/components/BitzTable/Store/utils/index.mjs +5 -5
- package/dist/components/BitzTable/SubTable/index.mjs +122 -73
- package/dist/components/BitzTable/Table/ResizableTitle copy.mjs +43 -21
- package/dist/components/BitzTable/Table/SortTableContext.mjs +39 -17
- package/dist/components/BitzTable/Table/SortableRow.mjs +44 -20
- package/dist/components/BitzTable/Table/index.mjs +444 -211
- package/dist/components/BitzTable/Table/style.mjs +10 -1
- package/dist/components/BitzTable/Table/utils.mjs +11 -4
- package/dist/components/BitzTable/TextOverflow/index.mjs +12 -3
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnConfigModal.mjs +105 -31
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndItem.mjs +104 -23
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/DndList.mjs +68 -29
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ColumnsSort/index.mjs +325 -159
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndItem.mjs +50 -16
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/DndList.mjs +42 -16
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/ExportConfig/index.mjs +135 -38
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/RadioCard.mjs +9 -2
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/ScopeSwitch.mjs +18 -5
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/StylesConfig/index.mjs +121 -49
- package/dist/components/BitzTable/ToolBar/ColConfigIcon/index.mjs +62 -18
- package/dist/components/BitzTable/ToolBar/ExportIcon/ExportModal.mjs +59 -16
- package/dist/components/BitzTable/ToolBar/ExportIcon/index.mjs +42 -14
- package/dist/components/BitzTable/ToolBar/FullscreenIcon/index.mjs +17 -4
- package/dist/components/BitzTable/ToolBar/Modal/index.mjs +46 -14
- package/dist/components/BitzTable/ToolBar/RefreshIcon/index.mjs +20 -9
- package/dist/components/BitzTable/ToolBar/Wrapper/index.mjs +49 -2
- package/dist/components/BitzTable/ToolBar/style.mjs +6 -1
- package/dist/components/BitzTable/index.d.ts +1 -0
- package/dist/components/BitzTableOperations/index.mjs +13 -3
- package/dist/components/BitzTableSelect/Picker/index.mjs +43 -10
- package/dist/components/BitzTableSelect/Select/index.mjs +90 -21
- package/dist/components/BitzTableSelect/SelectPopup/getData.mjs +23 -13
- package/dist/components/BitzTableSelect/SelectPopup/index.mjs +219 -69
- package/dist/components/BitzTableSelect/SingleSelect/index.mjs +87 -22
- package/dist/components/BitzTableSelect/TableCell/index.mjs +52 -11
- package/dist/components/BitzTableSelect/TextBlock/index.mjs +30 -12
- package/dist/components/BitzTableSelect/index.mjs +65 -14
- package/dist/components/BitzTableSelect/utils.mjs +3 -3
- package/dist/components/BitzTag/index.mjs +1 -1
- package/dist/components/BitzText/index.mjs +41 -14
- package/dist/components/BitzText/utils.mjs +3 -3
- package/dist/components/BitzTheme/index.mjs +6 -6
- package/dist/components/BitzTimeline/index.mjs +11 -1
- package/dist/components/BitzTimer/Form.mjs +32 -11
- package/dist/components/BitzTimer/Timer.mjs +76 -38
- package/dist/components/BitzTimer/index.mjs +66 -43
- package/dist/components/BitzToast/Toast/index.mjs +28 -10
- package/dist/components/BitzToast/index.mjs +1 -1
- package/dist/components/BitzTooltip/index.mjs +59 -20
- package/dist/components/BitzTooltip/style.mjs +9 -6
- package/dist/components/BitzTooltip/utils.mjs +2 -2
- package/dist/components/BitzTree/index.mjs +4 -1
- package/dist/components/BitzUeEditor/index.mjs +5 -5
- package/dist/components/BitzUpload/index.mjs +81 -43
- package/dist/components/BitzWebAppDrawer/index.mjs +35 -4
- package/dist/components/BitzWebAppModal/index.mjs +6 -3
- package/dist/hooks/use-event-listener.mjs +11 -2
- package/dist/hooks/use-lock-fn.mjs +13 -10
- package/dist/hooks/use-scroll-parent.mjs +16 -14
- package/dist/hooks/useEvent.mjs +7 -4
- package/dist/hooks/useMergedState.mjs +11 -11
- package/dist/node_modules/dayjs/dayjs.min.mjs +292 -292
- package/dist/node_modules/dayjs/locale/zh-cn.mjs +13 -13
- package/dist/style.css +1 -1
- package/dist/utils/WithFluent.mjs +9 -3
- package/dist/utils/create.mjs +7 -1
- package/dist/utils/time.mjs +1 -1
- package/package.json +1 -1
|
@@ -1,29 +1,72 @@
|
|
|
1
1
|
import { j as e } from "../../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
-
import { Card as
|
|
3
|
-
import { useState as y, useContext as k, useRef as
|
|
2
|
+
import { Card as C, Flex as l, message as j } from "antd";
|
|
3
|
+
import { useState as y, useContext as k, useRef as b, useMemo as B } from "react";
|
|
4
4
|
import { BitzTableContext as E } from "../../Store/index.mjs";
|
|
5
5
|
import c from "../../../BitzButton/index.mjs";
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
const G = ({
|
|
11
|
-
|
|
6
|
+
import O from "../../../BitzTheme/index.mjs";
|
|
7
|
+
import R from "../Modal/index.mjs";
|
|
8
|
+
import T from "../ColConfigIcon/ExportConfig/index.mjs";
|
|
9
|
+
import z from "../../../../node_modules/@ant-design/icons/es/icons/CheckCircleOutlined.mjs";
|
|
10
|
+
const G = ({
|
|
11
|
+
open: f,
|
|
12
|
+
title: m,
|
|
13
|
+
onExport: n,
|
|
14
|
+
close: t,
|
|
15
|
+
getContainer: d
|
|
16
|
+
}) => {
|
|
17
|
+
const { token: s } = O.useToken(), [p, r] = y(!1), { defaultTableExportConfig: u } = k(E), o = b(null), x = async () => {
|
|
12
18
|
var i, a;
|
|
13
|
-
if (
|
|
19
|
+
if (p)
|
|
14
20
|
return;
|
|
15
|
-
if (
|
|
16
|
-
j.error("导出设置至少需要一个字段"),
|
|
21
|
+
if (r(!0), !((i = o.current) == null ? void 0 : i.hasOne())) {
|
|
22
|
+
j.error("导出设置至少需要一个字段"), r(!1);
|
|
17
23
|
return;
|
|
18
24
|
}
|
|
19
|
-
const
|
|
20
|
-
n && (
|
|
25
|
+
const g = ((a = o.current) == null ? void 0 : a.getExportConfig()) ?? u;
|
|
26
|
+
n && (r(!1), n(g), t());
|
|
21
27
|
};
|
|
22
|
-
|
|
28
|
+
B(() => s.mode === "dark", [s.mode]);
|
|
23
29
|
const h = () => {
|
|
24
|
-
|
|
30
|
+
r(!1);
|
|
25
31
|
};
|
|
26
|
-
return
|
|
32
|
+
return /* @__PURE__ */ e.jsx(
|
|
33
|
+
R,
|
|
34
|
+
{
|
|
35
|
+
open: f,
|
|
36
|
+
title: m,
|
|
37
|
+
close: t,
|
|
38
|
+
closeAfter: h,
|
|
39
|
+
getContainer: d,
|
|
40
|
+
footer: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
41
|
+
/* @__PURE__ */ e.jsx(
|
|
42
|
+
c,
|
|
43
|
+
{
|
|
44
|
+
type: "primary",
|
|
45
|
+
icon: /* @__PURE__ */ e.jsx(z, {}),
|
|
46
|
+
onClick: x,
|
|
47
|
+
children: "导出"
|
|
48
|
+
}
|
|
49
|
+
),
|
|
50
|
+
/* @__PURE__ */ e.jsx(c, { onClick: t, children: "取消" })
|
|
51
|
+
] }),
|
|
52
|
+
children: /* @__PURE__ */ e.jsx(
|
|
53
|
+
C,
|
|
54
|
+
{
|
|
55
|
+
className: "container",
|
|
56
|
+
bordered: !1,
|
|
57
|
+
styles: { body: { paddingBlock: 24 } },
|
|
58
|
+
children: /* @__PURE__ */ e.jsx(l, { vertical: !0, align: "center", gap: 24, style: { height: "100%" }, children: /* @__PURE__ */ e.jsx(l, { className: "containerBody", children: /* @__PURE__ */ e.jsx(
|
|
59
|
+
T,
|
|
60
|
+
{
|
|
61
|
+
refInstance: o,
|
|
62
|
+
display: !0,
|
|
63
|
+
showSelectRadio: !0
|
|
64
|
+
}
|
|
65
|
+
) }) })
|
|
66
|
+
}
|
|
67
|
+
)
|
|
68
|
+
}
|
|
69
|
+
);
|
|
27
70
|
};
|
|
28
71
|
export {
|
|
29
72
|
G as default
|
|
@@ -1,19 +1,47 @@
|
|
|
1
1
|
import { j as t } from "../../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
-
import { memo as j, useState as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { BitzTableContext as
|
|
6
|
-
import { exportConfigTitle as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
2
|
+
import { memo as j, useState as y, useContext as l, useMemo as E } from "react";
|
|
3
|
+
import b from "../style.mjs";
|
|
4
|
+
import h from "../../../BitzButton/index.mjs";
|
|
5
|
+
import { BitzTableContext as i } from "../../Store/index.mjs";
|
|
6
|
+
import { exportConfigTitle as B } from "../ColConfigIcon/ColumnConfigModal.mjs";
|
|
7
|
+
import C from "./ExportModal.mjs";
|
|
8
|
+
import I from "../../../../node_modules/@ant-design/icons/es/icons/DownloadOutlined.mjs";
|
|
9
|
+
const z = ({
|
|
10
|
+
show: p = !0,
|
|
11
|
+
order: a,
|
|
12
|
+
onClick: o,
|
|
13
|
+
icon: f = /* @__PURE__ */ t.jsx(I, {})
|
|
14
|
+
}) => {
|
|
15
|
+
const { toolbarItemClassName: x } = b(), [u, s] = y(!1);
|
|
16
|
+
l(i).exportConfig;
|
|
17
|
+
const { loading: c, fullscreen: n, dataSource: e } = l(i), d = E(() => n ? !1 : void 0, [n]), g = async (r) => {
|
|
13
18
|
var m;
|
|
14
|
-
|
|
19
|
+
o == null || o(r.config.key, r.fields, (m = r.config) == null ? void 0 : m.info);
|
|
15
20
|
};
|
|
16
|
-
return p ? t.jsxs(t.Fragment, { children: [
|
|
21
|
+
return p ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
22
|
+
/* @__PURE__ */ t.jsx(
|
|
23
|
+
C,
|
|
24
|
+
{
|
|
25
|
+
open: u,
|
|
26
|
+
title: B,
|
|
27
|
+
getContainer: d,
|
|
28
|
+
onExport: g,
|
|
29
|
+
close: () => s(!1)
|
|
30
|
+
}
|
|
31
|
+
),
|
|
32
|
+
/* @__PURE__ */ t.jsx(
|
|
33
|
+
h,
|
|
34
|
+
{
|
|
35
|
+
type: "text",
|
|
36
|
+
className: x,
|
|
37
|
+
icon: f,
|
|
38
|
+
style: { order: a },
|
|
39
|
+
disabled: c || !(e != null && e.length),
|
|
40
|
+
onClick: () => s(!0),
|
|
41
|
+
children: "导出"
|
|
42
|
+
}
|
|
43
|
+
)
|
|
44
|
+
] }) : (
|
|
17
45
|
// <Dropdown
|
|
18
46
|
// open={open}
|
|
19
47
|
// onOpenChange={setOpen}
|
|
@@ -40,7 +68,7 @@ const I = ({ show: p = !0, order: a, onClick: e, icon: f = t.jsx(F, {}) }) => {
|
|
|
40
68
|
// </Dropdown>
|
|
41
69
|
null
|
|
42
70
|
);
|
|
43
|
-
}, G = j(
|
|
71
|
+
}, G = j(z);
|
|
44
72
|
export {
|
|
45
73
|
G as default
|
|
46
74
|
};
|
|
@@ -8,13 +8,16 @@ import { findParentFirstNodeByClass as z } from "../../../../utils/findNode.mjs"
|
|
|
8
8
|
import { BitzTableContext as j } from "../../Store/index.mjs";
|
|
9
9
|
import C from "../../../../node_modules/@ant-design/icons/es/icons/FullscreenExitOutlined.mjs";
|
|
10
10
|
import T from "../../../../node_modules/@ant-design/icons/es/icons/FullscreenOutlined.mjs";
|
|
11
|
-
const g = ({
|
|
11
|
+
const g = ({
|
|
12
|
+
order: m,
|
|
13
|
+
show: u = !0
|
|
14
|
+
}) => {
|
|
12
15
|
const { toolbarItemClassName: a } = B(), { fullscreen: t, setFullscreen: r } = p(j), s = x(() => t ? {
|
|
13
16
|
title: "退出全屏",
|
|
14
|
-
icon: o.jsx(C, {})
|
|
17
|
+
icon: /* @__PURE__ */ o.jsx(C, {})
|
|
15
18
|
} : {
|
|
16
19
|
title: "全屏",
|
|
17
|
-
icon: o.jsx(T, {})
|
|
20
|
+
icon: /* @__PURE__ */ o.jsx(T, {})
|
|
18
21
|
}, [t]), f = (n) => {
|
|
19
22
|
l.isEnabled || F.error("您的浏览器不支持全屏");
|
|
20
23
|
const e = z(n.target, "bitzTableBlock");
|
|
@@ -24,7 +27,17 @@ const g = ({ order: m, show: u = !0 }) => {
|
|
|
24
27
|
var e, i, c;
|
|
25
28
|
(e = n.target) != null && e.classList.contains("bitzTableBlock") && (r(!!document.fullscreenElement), (c = (i = document.fullscreenElement) == null ? void 0 : i.classList) != null && c.contains("bitzTableBlock") || r(!1));
|
|
26
29
|
}), document == null ? void 0 : document.removeEventListener("fullscreenchange", () => {
|
|
27
|
-
})), []), u ? o.jsx(
|
|
30
|
+
})), []), u ? /* @__PURE__ */ o.jsx(
|
|
31
|
+
E,
|
|
32
|
+
{
|
|
33
|
+
type: "text",
|
|
34
|
+
className: a,
|
|
35
|
+
onClick: f,
|
|
36
|
+
icon: s.icon,
|
|
37
|
+
style: { order: m },
|
|
38
|
+
children: s.title
|
|
39
|
+
}
|
|
40
|
+
) : null;
|
|
28
41
|
}, G = d(g);
|
|
29
42
|
export {
|
|
30
43
|
G as default
|
|
@@ -1,23 +1,55 @@
|
|
|
1
|
-
import { j as
|
|
1
|
+
import { j as t } from "../../../../node_modules/react/jsx-runtime.mjs";
|
|
2
2
|
import { Modal as C, Typography as c } from "antd";
|
|
3
3
|
import { useMemo as p } from "react";
|
|
4
4
|
import g from "../../../BitzTheme/index.mjs";
|
|
5
5
|
import u from "../../../../node_modules/classnames/index.mjs";
|
|
6
|
-
import { styles as y, modalTitleHeight as
|
|
7
|
-
function H({
|
|
8
|
-
|
|
6
|
+
import { styles as y, modalTitleHeight as x } from "./style.mjs";
|
|
7
|
+
function H({
|
|
8
|
+
open: e,
|
|
9
|
+
title: s,
|
|
10
|
+
close: a,
|
|
11
|
+
closeAfter: l,
|
|
12
|
+
getContainer: i,
|
|
13
|
+
footer: m,
|
|
14
|
+
extra: h,
|
|
15
|
+
styles: n,
|
|
16
|
+
children: d
|
|
17
|
+
}) {
|
|
18
|
+
const { token: o } = g.useToken(), r = p(() => o.mode === "dark", [o.mode]), f = () => {
|
|
9
19
|
l();
|
|
10
20
|
};
|
|
11
|
-
return
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
+
return /* @__PURE__ */ t.jsx(
|
|
22
|
+
C,
|
|
23
|
+
{
|
|
24
|
+
className: u(y(o), "tableConfigModal"),
|
|
25
|
+
title: /* @__PURE__ */ t.jsx(
|
|
26
|
+
c.Title,
|
|
27
|
+
{
|
|
28
|
+
style: {
|
|
29
|
+
fontSize: 16,
|
|
30
|
+
lineHeight: `${x}px`,
|
|
31
|
+
margin: 0
|
|
32
|
+
},
|
|
33
|
+
children: s
|
|
34
|
+
}
|
|
35
|
+
),
|
|
36
|
+
getContainer: i,
|
|
37
|
+
open: e,
|
|
38
|
+
onCancel: a,
|
|
39
|
+
afterClose: f,
|
|
40
|
+
style: {
|
|
41
|
+
"--sortCard-bgColor": r ? "#444" : "#f2f2f2",
|
|
42
|
+
"--sortCard-titleColor": r ? "#ccc" : "#777",
|
|
43
|
+
"--radioCard-bgColor": r ? "#444" : "#F2F2F2",
|
|
44
|
+
"--radioCard-bgHoverColor": r ? "#333" : o.colorBgContainer
|
|
45
|
+
},
|
|
46
|
+
styles: n,
|
|
47
|
+
width: 700,
|
|
48
|
+
footer: m,
|
|
49
|
+
destroyOnClose: !0,
|
|
50
|
+
children: d
|
|
51
|
+
}
|
|
52
|
+
);
|
|
21
53
|
}
|
|
22
54
|
export {
|
|
23
55
|
H as default
|
|
@@ -1,14 +1,25 @@
|
|
|
1
1
|
import { j as o } from "../../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
-
import { memo as
|
|
3
|
-
import { Tooltip as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { BitzTableContext as
|
|
2
|
+
import { memo as a, useContext as c } from "react";
|
|
3
|
+
import { Tooltip as p } from "antd";
|
|
4
|
+
import f from "../style.mjs";
|
|
5
|
+
import d from "../../../BitzButton/index.mjs";
|
|
6
|
+
import { BitzTableContext as u } from "../../Store/index.mjs";
|
|
7
7
|
import x from "../../../../node_modules/@ant-design/icons/es/icons/ReloadOutlined.mjs";
|
|
8
8
|
const h = (t) => {
|
|
9
|
-
const { onClick: e, order: r, show: s = !0, icon: n = o.jsx(x, {}) } = t, { loading:
|
|
10
|
-
return s ? o.jsx(
|
|
11
|
-
|
|
9
|
+
const { onClick: e, order: r, show: s = !0, icon: n = /* @__PURE__ */ o.jsx(x, {}) } = t, { loading: l, selected: m } = c(u), { toolbarItemClassName: i } = f();
|
|
10
|
+
return s ? /* @__PURE__ */ o.jsx(p, { title: "刷新", open: !1, children: /* @__PURE__ */ o.jsx(
|
|
11
|
+
d,
|
|
12
|
+
{
|
|
13
|
+
type: "text",
|
|
14
|
+
className: i,
|
|
15
|
+
disabled: l || m,
|
|
16
|
+
onClick: e,
|
|
17
|
+
icon: n,
|
|
18
|
+
style: { order: r },
|
|
19
|
+
children: "刷新"
|
|
20
|
+
}
|
|
21
|
+
) }) : null;
|
|
22
|
+
}, z = a(h);
|
|
12
23
|
export {
|
|
13
|
-
|
|
24
|
+
z as default
|
|
14
25
|
};
|
|
@@ -8,7 +8,15 @@ import I from "../ExportIcon/index.mjs";
|
|
|
8
8
|
import { BitzConfigContext as R } from "../../../BitzConfigProvider/context.mjs";
|
|
9
9
|
import { BitzToolBarContext as b } from "./context.mjs";
|
|
10
10
|
import { BitzTableContext as k } from "../../Store/index.mjs";
|
|
11
|
-
const F = ["export", "refresh", "fullscreen", "config"], J = ({
|
|
11
|
+
const F = ["export", "refresh", "fullscreen", "config"], J = ({
|
|
12
|
+
size: W,
|
|
13
|
+
tools: l,
|
|
14
|
+
toolsConfig: m,
|
|
15
|
+
exclude: t,
|
|
16
|
+
onExport: p,
|
|
17
|
+
onRefresh: d,
|
|
18
|
+
onColumnChange: a
|
|
19
|
+
}) => {
|
|
12
20
|
const { Table: e } = c(R), { selected: u, setToolbarWidth: x } = c(k), i = h(() => {
|
|
13
21
|
const s = l || (e == null ? void 0 : e.toolbar) || F;
|
|
14
22
|
return t != null && t.length ? s.filter((n) => !t.includes(n)) : s;
|
|
@@ -25,7 +33,46 @@ const F = ["export", "refresh", "fullscreen", "config"], J = ({ size: W, tools:
|
|
|
25
33
|
}, [i]), f = g(null);
|
|
26
34
|
return C(() => {
|
|
27
35
|
f.current && x(f.current.clientWidth);
|
|
28
|
-
}, [f.current]), r.jsx(b.Provider, { value: m ?? {}, children:
|
|
36
|
+
}, [f.current]), /* @__PURE__ */ r.jsx(b.Provider, { value: m ?? {}, children: /* @__PURE__ */ r.jsx(
|
|
37
|
+
j,
|
|
38
|
+
{
|
|
39
|
+
ref: f,
|
|
40
|
+
style: { height: "100%", ...u && { zIndex: 10 } },
|
|
41
|
+
children: /* @__PURE__ */ r.jsxs(z.Compact, { children: [
|
|
42
|
+
/* @__PURE__ */ r.jsx(
|
|
43
|
+
I,
|
|
44
|
+
{
|
|
45
|
+
order: o.export.order,
|
|
46
|
+
show: o.export.show,
|
|
47
|
+
onClick: p
|
|
48
|
+
}
|
|
49
|
+
),
|
|
50
|
+
/* @__PURE__ */ r.jsx(
|
|
51
|
+
B,
|
|
52
|
+
{
|
|
53
|
+
order: o.refresh.order,
|
|
54
|
+
show: o.refresh.show,
|
|
55
|
+
onClick: d
|
|
56
|
+
}
|
|
57
|
+
),
|
|
58
|
+
/* @__PURE__ */ r.jsx(
|
|
59
|
+
E,
|
|
60
|
+
{
|
|
61
|
+
order: o.fullscreen.order,
|
|
62
|
+
show: o.fullscreen.show
|
|
63
|
+
}
|
|
64
|
+
),
|
|
65
|
+
/* @__PURE__ */ r.jsx(
|
|
66
|
+
T,
|
|
67
|
+
{
|
|
68
|
+
order: o.config.order,
|
|
69
|
+
show: o.config.show,
|
|
70
|
+
onChange: a
|
|
71
|
+
}
|
|
72
|
+
)
|
|
73
|
+
] })
|
|
74
|
+
}
|
|
75
|
+
) });
|
|
29
76
|
};
|
|
30
77
|
export {
|
|
31
78
|
J as default
|
|
@@ -55,6 +55,7 @@ interface BitzTableActionColProps<T> extends Pick<BitzTableActionProps<T>, 'load
|
|
|
55
55
|
defaultWidth?: number;
|
|
56
56
|
actionGroup?: ActionGroupFunType<T>;
|
|
57
57
|
customActions?: CustomActionsFunType<T>;
|
|
58
|
+
width?: number;
|
|
58
59
|
}
|
|
59
60
|
/** 列的排序和显隐控制 */
|
|
60
61
|
interface ColumnsConfigProps {
|
|
@@ -1,9 +1,19 @@
|
|
|
1
1
|
import { j as t } from "../../node_modules/react/jsx-runtime.mjs";
|
|
2
2
|
import { Space as p, Button as n } from "antd";
|
|
3
3
|
const m = ({ record: a = {}, operations: r = [], tableOperationEmit: s = () => {
|
|
4
|
-
}, ...l }) => t.jsx("div", { className: "bitzTableOperationsBlock", ...l, children: t.jsx(p, { children: r.map((e, i) =>
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
}, ...l }) => /* @__PURE__ */ t.jsx("div", { className: "bitzTableOperationsBlock", ...l, children: /* @__PURE__ */ t.jsx(p, { children: r.map((e, i) => /* @__PURE__ */ t.jsx(
|
|
5
|
+
n,
|
|
6
|
+
{
|
|
7
|
+
className: `${(e == null ? void 0 : e.className) || ""}`,
|
|
8
|
+
type: e.type == "edit" ? "primary" : "default",
|
|
9
|
+
danger: e.type == "delete",
|
|
10
|
+
onClick: () => {
|
|
11
|
+
s(e.type, a);
|
|
12
|
+
},
|
|
13
|
+
children: e.label
|
|
14
|
+
},
|
|
15
|
+
i
|
|
16
|
+
)) }) });
|
|
7
17
|
export {
|
|
8
18
|
m as default
|
|
9
19
|
};
|
|
@@ -3,21 +3,54 @@ import { useState as r, useEffect as j } from "react";
|
|
|
3
3
|
import { Select as b, Drawer as w, Input as S } from "antd";
|
|
4
4
|
import k from "../../BitzButton/index.mjs";
|
|
5
5
|
import "./index.less.mjs";
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
const h = ({
|
|
7
|
+
value: s,
|
|
8
|
+
placeholder: a = "请选择",
|
|
9
|
+
fieldNames: p = {
|
|
10
|
+
label: "name",
|
|
11
|
+
value: "key"
|
|
12
|
+
},
|
|
13
|
+
onChange: t,
|
|
14
|
+
...y
|
|
15
|
+
}) => {
|
|
16
|
+
const [c, m] = r([]), [f, l] = r([]), [n, o] = r(!1), u = () => {
|
|
11
17
|
l([]), t == null || t([], []);
|
|
12
|
-
}, d = (x,
|
|
13
|
-
l(
|
|
18
|
+
}, d = (x, i) => {
|
|
19
|
+
l(i), t == null || t(x, i);
|
|
14
20
|
};
|
|
15
21
|
return j(() => {
|
|
16
22
|
if (s && !Array.isArray(s))
|
|
17
|
-
throw new Error(
|
|
23
|
+
throw new Error(
|
|
24
|
+
`form表单在使用setFieldValue给TableSelect组件赋值时请确认值为数组类型, \`value\`: ${s}`
|
|
25
|
+
);
|
|
18
26
|
m(s ?? []);
|
|
19
|
-
}, [s]),
|
|
27
|
+
}, [s]), /* @__PURE__ */ e.jsxs("div", { children: [
|
|
28
|
+
/* @__PURE__ */ e.jsx(
|
|
29
|
+
b,
|
|
30
|
+
{
|
|
31
|
+
style: { width: "200px" },
|
|
32
|
+
allowClear: !0,
|
|
33
|
+
mode: "tags",
|
|
34
|
+
maxTagCount: "responsive",
|
|
35
|
+
value: c,
|
|
36
|
+
options: f,
|
|
37
|
+
fieldNames: p,
|
|
38
|
+
showSearch: !1,
|
|
39
|
+
open: !1,
|
|
40
|
+
placeholder: a,
|
|
41
|
+
popupClassName: "tableSelectPopupBlock",
|
|
42
|
+
dropdownRender: () => /* @__PURE__ */ e.jsx(e.Fragment, {}),
|
|
43
|
+
onClick: () => o(!0),
|
|
44
|
+
onClear: u,
|
|
45
|
+
onChange: d
|
|
46
|
+
}
|
|
47
|
+
),
|
|
48
|
+
/* @__PURE__ */ e.jsxs(w, { open: n, placement: "bottom", height: "100%", children: [
|
|
49
|
+
/* @__PURE__ */ e.jsx(S, {}),
|
|
50
|
+
/* @__PURE__ */ e.jsx(k, { onClick: () => o(!1), children: "关闭" })
|
|
51
|
+
] })
|
|
52
|
+
] });
|
|
20
53
|
};
|
|
21
54
|
export {
|
|
22
|
-
|
|
55
|
+
h as default
|
|
23
56
|
};
|
|
@@ -1,25 +1,94 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import { useState as
|
|
3
|
-
import { Select as
|
|
4
|
-
import
|
|
5
|
-
function
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { j as x } from "../../../node_modules/react/jsx-runtime.mjs";
|
|
2
|
+
import { useState as o, useEffect as b } from "react";
|
|
3
|
+
import { Select as M } from "antd";
|
|
4
|
+
import Q from "../SelectPopup/index.mjs";
|
|
5
|
+
function Z({
|
|
6
|
+
value: l,
|
|
7
|
+
options: r,
|
|
8
|
+
columns: j,
|
|
9
|
+
tableData: w,
|
|
10
|
+
total: T,
|
|
11
|
+
loading: a,
|
|
12
|
+
loadingFailed: k,
|
|
13
|
+
loadAgain: y,
|
|
14
|
+
page: E,
|
|
15
|
+
onPageChange: A,
|
|
16
|
+
searchInput: B,
|
|
17
|
+
showToolTagSelect: D,
|
|
18
|
+
toolTags: V,
|
|
19
|
+
onToolTagChange: d,
|
|
20
|
+
lrLayout: v,
|
|
21
|
+
parentRender: F,
|
|
22
|
+
mode: N = "multiple",
|
|
23
|
+
placeholder: O = "请选择",
|
|
24
|
+
fieldNames: p,
|
|
25
|
+
onChange: e,
|
|
26
|
+
onPopupVisibleChange: f,
|
|
27
|
+
...$
|
|
28
|
+
}) {
|
|
29
|
+
const [S, q] = o([]), [u, c] = o([]), [i, m] = o(!1), [z, G] = o(!1), H = () => {
|
|
30
|
+
c([]), e == null || e([], []);
|
|
31
|
+
}, I = (t, s, L) => {
|
|
32
|
+
L === "confirm" && (c([...s]), e == null || e([...t], [...s]), m(!1));
|
|
33
|
+
}, J = (t, s) => {
|
|
34
|
+
c(s), e == null || e(t, s);
|
|
35
|
+
}, K = (t) => {
|
|
36
|
+
!i && t && m(!0), !z && !t && i && m(!1), f == null || f(t);
|
|
14
37
|
};
|
|
15
|
-
return
|
|
16
|
-
if (
|
|
17
|
-
throw new Error(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
}, [
|
|
38
|
+
return b(() => {
|
|
39
|
+
if (l && !Array.isArray(l))
|
|
40
|
+
throw new Error(
|
|
41
|
+
`form表单在使用setFieldValue给TableSelect组件赋值时请确认值为数组类型, \`value\`: ${l}`
|
|
42
|
+
);
|
|
43
|
+
q(l ?? []);
|
|
44
|
+
}, [l]), b(() => {
|
|
45
|
+
r != null && r.length && c(r);
|
|
46
|
+
}, [r]), /* @__PURE__ */ x.jsx(
|
|
47
|
+
M,
|
|
48
|
+
{
|
|
49
|
+
allowClear: !0,
|
|
50
|
+
className: "tableSelectBlock",
|
|
51
|
+
mode: "multiple",
|
|
52
|
+
maxTagCount: "responsive",
|
|
53
|
+
value: S,
|
|
54
|
+
options: u,
|
|
55
|
+
fieldNames: p,
|
|
56
|
+
showSearch: !1,
|
|
57
|
+
open: i,
|
|
58
|
+
placeholder: O,
|
|
59
|
+
popupClassName: "tableSelectPopupBlock",
|
|
60
|
+
dropdownRender: () => /* @__PURE__ */ x.jsx(
|
|
61
|
+
Q,
|
|
62
|
+
{
|
|
63
|
+
columns: j,
|
|
64
|
+
tableData: w,
|
|
65
|
+
total: T,
|
|
66
|
+
page: E,
|
|
67
|
+
onPageChange: A,
|
|
68
|
+
searchInput: B,
|
|
69
|
+
loading: a,
|
|
70
|
+
loadingFailed: k,
|
|
71
|
+
loadAgain: y,
|
|
72
|
+
keys: S,
|
|
73
|
+
rows: u,
|
|
74
|
+
fieldNames: p,
|
|
75
|
+
onChange: I,
|
|
76
|
+
onDropdownVisibleChange: G,
|
|
77
|
+
showToolTagSelect: D,
|
|
78
|
+
toolTags: V,
|
|
79
|
+
onToolTagChange: d,
|
|
80
|
+
lrLayout: v,
|
|
81
|
+
parentRender: F,
|
|
82
|
+
mode: N
|
|
83
|
+
}
|
|
84
|
+
),
|
|
85
|
+
onClear: H,
|
|
86
|
+
onDropdownVisibleChange: K,
|
|
87
|
+
onChange: J,
|
|
88
|
+
...$
|
|
89
|
+
}
|
|
90
|
+
);
|
|
22
91
|
}
|
|
23
92
|
export {
|
|
24
|
-
|
|
93
|
+
Z as default
|
|
25
94
|
};
|