@zat-design/sisyphus-react 3.13.3 → 3.13.4-beta.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/README.md +1 -1
- package/dist/index.esm.css +11 -2
- package/dist/less.esm.css +11 -2
- package/es/ProForm/components/base/DatePicker/index.js +0 -9
- package/es/ProForm/components/base/RangePicker/index.js +0 -8
- package/es/ProTable/components/RcTable/components/DraggableTable/index.js +0 -9
- package/es/ProTable/hooks/useAntdTable.js +5 -4
- package/es/ProTable/propsType.d.ts +0 -6
- package/es/ProTable/utils/index.d.ts +0 -1
- package/es/ProTable/utils/index.js +0 -1
- package/es/ProTooltip/propsType.d.ts +1 -1
- package/es/ProTree/components/AdaptiveTooltip.js +0 -9
- package/es/ProTree/components/List.js +0 -8
- package/es/ProTree/components/SearchTitle.js +0 -8
- package/es/ProTreeModal/components/List.js +4 -0
- package/es/ProTreeModal/components/Trigger.js +2 -2
- package/es/ProTreeModal/index.js +5 -14
- package/es/ProTreeModal/style/index.less +13 -2
- package/es/ProUpload/components/ImageRender.js +0 -9
- package/es/ProUpload/index.js +0 -7
- package/lib/ProForm/components/base/DatePicker/index.js +0 -8
- package/lib/ProForm/components/base/RangePicker/index.js +1 -10
- package/lib/ProTable/components/RcTable/components/DraggableTable/index.js +0 -8
- package/lib/ProTable/hooks/useAntdTable.js +3 -4
- package/lib/ProTable/propsType.d.ts +0 -6
- package/lib/ProTable/utils/index.d.ts +0 -1
- package/lib/ProTable/utils/index.js +0 -1
- package/lib/ProTooltip/propsType.d.ts +1 -1
- package/lib/ProTree/components/AdaptiveTooltip.js +0 -9
- package/lib/ProTree/components/List.js +0 -8
- package/lib/ProTree/components/SearchTitle.js +0 -9
- package/lib/ProTreeModal/components/List.js +4 -0
- package/lib/ProTreeModal/components/Trigger.js +2 -2
- package/lib/ProTreeModal/index.js +5 -15
- package/lib/ProTreeModal/style/index.less +13 -2
- package/lib/ProUpload/components/ImageRender.js +0 -9
- package/lib/ProUpload/index.js +0 -7
- package/package.json +3 -3
package/README.md
CHANGED
package/dist/index.esm.css
CHANGED
@@ -3654,6 +3654,15 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3654
3654
|
.pro-tree-modal-placeholder {
|
3655
3655
|
color: #939499;
|
3656
3656
|
}
|
3657
|
+
.pro-tree-modal .ant-input-group-wrapper:hover .pro-tree-modal-view-svg {
|
3658
|
+
color: var(--zaui-brand);
|
3659
|
+
}
|
3660
|
+
.pro-tree-modal .pro-tree-modal-view-svg div {
|
3661
|
+
display: -webkit-box;
|
3662
|
+
display: -webkit-flex;
|
3663
|
+
display: -ms-flexbox;
|
3664
|
+
display: flex;
|
3665
|
+
}
|
3657
3666
|
.pro-tree-modal-content {
|
3658
3667
|
display: -webkit-box;
|
3659
3668
|
display: -webkit-flex;
|
@@ -3711,7 +3720,7 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3711
3720
|
.pro-tree-modal-box:first-child {
|
3712
3721
|
margin-right: var(--zaui-space-size-md, 16px);
|
3713
3722
|
}
|
3714
|
-
.pro-tree-modal-box .
|
3723
|
+
.pro-tree-modal-box .pro-tree-modal-search-svg > div {
|
3715
3724
|
display: -webkit-box;
|
3716
3725
|
display: -webkit-flex;
|
3717
3726
|
display: -ms-flexbox;
|
@@ -3849,7 +3858,7 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3849
3858
|
-ms-flex-align: center;
|
3850
3859
|
align-items: center;
|
3851
3860
|
}
|
3852
|
-
.pro-tree-modal-isView .
|
3861
|
+
.pro-tree-modal-isView .pro-tree-modal-view-svg {
|
3853
3862
|
margin-left: var(--zaui-space-size-sm, 8px);
|
3854
3863
|
}
|
3855
3864
|
.pro-tree-modal-tree-content {
|
package/dist/less.esm.css
CHANGED
@@ -3654,6 +3654,15 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3654
3654
|
.pro-tree-modal-placeholder {
|
3655
3655
|
color: #939499;
|
3656
3656
|
}
|
3657
|
+
.pro-tree-modal .ant-input-group-wrapper:hover .pro-tree-modal-view-svg {
|
3658
|
+
color: var(--zaui-brand);
|
3659
|
+
}
|
3660
|
+
.pro-tree-modal .pro-tree-modal-view-svg div {
|
3661
|
+
display: -webkit-box;
|
3662
|
+
display: -webkit-flex;
|
3663
|
+
display: -ms-flexbox;
|
3664
|
+
display: flex;
|
3665
|
+
}
|
3657
3666
|
.pro-tree-modal-content {
|
3658
3667
|
display: -webkit-box;
|
3659
3668
|
display: -webkit-flex;
|
@@ -3711,7 +3720,7 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3711
3720
|
.pro-tree-modal-box:first-child {
|
3712
3721
|
margin-right: var(--zaui-space-size-md, 16px);
|
3713
3722
|
}
|
3714
|
-
.pro-tree-modal-box .
|
3723
|
+
.pro-tree-modal-box .pro-tree-modal-search-svg > div {
|
3715
3724
|
display: -webkit-box;
|
3716
3725
|
display: -webkit-flex;
|
3717
3726
|
display: -ms-flexbox;
|
@@ -3849,7 +3858,7 @@ span.ant-input-group-compact.pro-range-limit .forever-checkbox {
|
|
3849
3858
|
-ms-flex-align: center;
|
3850
3859
|
align-items: center;
|
3851
3860
|
}
|
3852
|
-
.pro-tree-modal-isView .
|
3861
|
+
.pro-tree-modal-isView .pro-tree-modal-view-svg {
|
3853
3862
|
margin-left: var(--zaui-space-size-sm, 8px);
|
3854
3863
|
}
|
3855
3864
|
.pro-tree-modal-tree-content {
|
@@ -6,15 +6,6 @@ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
6
6
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
7
7
|
var _excluded = ["className", "format"];
|
8
8
|
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
-
/*
|
10
|
-
* @Author: ''
|
11
|
-
* @Date: 2024-01-19 18:27:41
|
12
|
-
* @LastEditors: ''
|
13
|
-
* @LastEditTime: 2024-06-03 15:33:12
|
14
|
-
* @FilePath: /za-material-warehouse/src/ProForm/components/base/DatePicker/index.tsx
|
15
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
16
|
-
*/
|
17
|
-
|
18
9
|
import { isFunction, isString, isObject, uniq } from 'lodash';
|
19
10
|
import classNames from 'classnames';
|
20
11
|
import moment from 'moment';
|
@@ -5,14 +5,6 @@ import "antd/es/date-picker/style";
|
|
5
5
|
import _DatePicker from "antd/es/date-picker";
|
6
6
|
var _excluded = ["format", "otherProps", "separator", "range"];
|
7
7
|
import { jsx as _jsx } from "react/jsx-runtime";
|
8
|
-
/*
|
9
|
-
* @Author: ''
|
10
|
-
* @Date: 2024-04-10 11:39:17
|
11
|
-
* @LastEditors: ''
|
12
|
-
* @LastEditTime: 2024-05-29 11:50:49
|
13
|
-
* @FilePath: /za-material-warehouse/src/ProForm/components/base/RangePicker/index.tsx
|
14
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
15
|
-
*/
|
16
8
|
// @ts-check
|
17
9
|
|
18
10
|
import { isFunction, isObject, isString, omit, uniq } from 'lodash';
|
@@ -4,15 +4,6 @@ import _Table from "antd/es/table";
|
|
4
4
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
5
5
|
var _excluded = ["dataSource", "tableProps", "draggableProps", "summaryProps", "emptyTextProps"];
|
6
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
7
|
-
/*
|
8
|
-
* @Author: ''
|
9
|
-
* @Date: 2024-08-09 13:48:59
|
10
|
-
* @LastEditors: ''
|
11
|
-
* @LastEditTime: 2024-08-27 15:27:44
|
12
|
-
* @FilePath: /za-material-warehouse/src/ProTable/components/RcTable/components/DraggableTable/index.tsx
|
13
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
14
|
-
*/
|
15
|
-
|
16
7
|
import { memo } from 'react';
|
17
8
|
import DndWrapper, { Row } from './components/DndWrapper';
|
18
9
|
import { RenderEmptyText, RenderSummary } from '../../../index';
|
@@ -4,6 +4,8 @@ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
4
4
|
import "antd/es/message/style";
|
5
5
|
import _message from "antd/es/message";
|
6
6
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
7
|
+
import "antd/es/form/style";
|
8
|
+
import _Form from "antd/es/form";
|
7
9
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
8
10
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
9
11
|
var _excluded = ["page", "filters", "sorter"];
|
@@ -32,7 +34,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
32
34
|
total: 0,
|
33
35
|
selectedRecords: [],
|
34
36
|
selectedRowKeys: [],
|
35
|
-
searchValues: undefined,
|
36
37
|
extraFilter: {
|
37
38
|
filters: undefined,
|
38
39
|
sorter: undefined
|
@@ -45,7 +46,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
45
46
|
total = _useSetState2$.total,
|
46
47
|
selectedRecords = _useSetState2$.selectedRecords,
|
47
48
|
selectedRowKeys = _useSetState2$.selectedRowKeys,
|
48
|
-
searchValues = _useSetState2$.searchValues,
|
49
49
|
extraFilter = _useSetState2$.extraFilter,
|
50
50
|
allSelected = _useSetState2$.allSelected,
|
51
51
|
setState = _useSetState2[1];
|
@@ -66,6 +66,9 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
66
66
|
transformParams = _useDefaultOptions.transformParams,
|
67
67
|
transformResponse = _useDefaultOptions.transformResponse,
|
68
68
|
disabled = _useDefaultOptions.disabled;
|
69
|
+
// 搜索表单里的值
|
70
|
+
var _searchValues = _Form.useWatch([], form);
|
71
|
+
var searchValues = removeEmptyKeys(_searchValues);
|
69
72
|
var _ref = useRequestOptions || {},
|
70
73
|
defaultParams = _ref.defaultParams;
|
71
74
|
var defaultParam = Array.isArray(defaultParams) ? defaultParams === null || defaultParams === void 0 ? void 0 : defaultParams[0] : defaultParams || {};
|
@@ -244,7 +247,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
244
247
|
if ((selectedRecords === null || selectedRecords === void 0 ? void 0 : selectedRecords.length) || isNonEmptyObject(_values) || !isEqual(previousSearchValues, _values)) {
|
245
248
|
previousSearchValues = _values;
|
246
249
|
setState({
|
247
|
-
searchValues: _values,
|
248
250
|
allSelected: false,
|
249
251
|
selectedRecords: [],
|
250
252
|
selectedRowKeys: []
|
@@ -256,7 +258,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
256
258
|
}, [extraFilter, page.pageSize, previousPage, getTransformParams]);
|
257
259
|
var resetParams = useCallback(function (page) {
|
258
260
|
setState({
|
259
|
-
searchValues: undefined,
|
260
261
|
allSelected: false,
|
261
262
|
selectedRecords: [],
|
262
263
|
selectedRowKeys: [],
|
@@ -735,12 +735,6 @@ export interface ProTableUseAntdTableType<I, R> {
|
|
735
735
|
* @default []
|
736
736
|
*/
|
737
737
|
selectedRowKeys: Key[];
|
738
|
-
/**
|
739
|
-
* 搜索值
|
740
|
-
* @description 当前表单的搜索条件
|
741
|
-
* @default undefined
|
742
|
-
*/
|
743
|
-
searchValues: I;
|
744
738
|
/**
|
745
739
|
* 额外过滤条件
|
746
740
|
* @description 表单之外的额外过滤条件
|
@@ -2,15 +2,6 @@ import "antd/es/tooltip/style";
|
|
2
2
|
import _Tooltip from "antd/es/tooltip";
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
4
4
|
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
5
|
-
/*
|
6
|
-
* @Author: ''
|
7
|
-
* @Date: 2024-09-20 10:26:04
|
8
|
-
* @LastEditors: ''
|
9
|
-
* @LastEditTime: 2024-09-26 14:12:44
|
10
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/AdaptiveTooltip.tsx
|
11
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
12
|
-
*/
|
13
|
-
|
14
5
|
import { useEffect, useState } from 'react';
|
15
6
|
var AdaptiveTooltip = function AdaptiveTooltip(_ref) {
|
16
7
|
var children = _ref.children;
|
@@ -4,14 +4,6 @@ import _Checkbox from "antd/es/checkbox";
|
|
4
4
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
5
5
|
var _excluded = ["checkedValues", "disabled", "treeData", "searchStr", "showCodeName", "mode", "fieldNames", "handleOnChange", "handleFilterClose", "optionRender"];
|
6
6
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
7
|
-
/*
|
8
|
-
* @Author: ''
|
9
|
-
* @Date: 2024-07-03 11:02:19
|
10
|
-
* @LastEditors: za-xuwenli xuwenli@zhongan.io
|
11
|
-
* @LastEditTime: 2025-03-20 10:44:39
|
12
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/List.tsx
|
13
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
14
|
-
*/
|
15
7
|
import { memo } from 'react';
|
16
8
|
import SearchTitle from './SearchTitle';
|
17
9
|
import CloseIcon from './CloseIcon';
|
@@ -1,12 +1,4 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
|
-
/*
|
3
|
-
* @Author: ''
|
4
|
-
* @Date: 2024-09-26 14:37:00
|
5
|
-
* @LastEditors: ''
|
6
|
-
* @LastEditTime: 2024-09-26 17:50:59
|
7
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/SearchTitle.tsx
|
8
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
9
|
-
*/
|
10
2
|
import { memo } from 'react';
|
11
3
|
import AdaptiveTooltip from './AdaptiveTooltip';
|
12
4
|
function SearchTitle(props) {
|
@@ -15,6 +15,7 @@ import SearchTitle from './SearchTitle';
|
|
15
15
|
import CloseIcon from './CloseIcon';
|
16
16
|
import SortableItem from './SortableItem';
|
17
17
|
import { CASCADER } from '..';
|
18
|
+
import { isEmpty } from '../../utils';
|
18
19
|
function List(props, ref) {
|
19
20
|
var checkedValues = props.checkedValues,
|
20
21
|
disabled = props.disabled,
|
@@ -108,6 +109,9 @@ function List(props, ref) {
|
|
108
109
|
}
|
109
110
|
};
|
110
111
|
function getLineHeight(string, width) {
|
112
|
+
if (isEmpty(string)) {
|
113
|
+
return 0;
|
114
|
+
}
|
111
115
|
// 创建临时元素
|
112
116
|
var temp = document.createElement('div');
|
113
117
|
temp.style.position = 'absolute';
|
@@ -77,7 +77,7 @@ function Trigger(props) {
|
|
77
77
|
}), _jsx("div", {
|
78
78
|
className: "pro-enum-input-addonAfter",
|
79
79
|
children: _jsx(ReactSVG, {
|
80
|
-
className: "
|
80
|
+
className: "pro-tree-modal-view-svg",
|
81
81
|
src: viewSvg,
|
82
82
|
onClick: onIconClick
|
83
83
|
})
|
@@ -139,7 +139,7 @@ function Trigger(props) {
|
|
139
139
|
onClick: handleClearAll
|
140
140
|
})
|
141
141
|
}), _jsx(ReactSVG, {
|
142
|
-
className: "
|
142
|
+
className: "pro-tree-modal-view-svg",
|
143
143
|
src: viewSvg,
|
144
144
|
onClick: onIconClick
|
145
145
|
})]
|
package/es/ProTreeModal/index.js
CHANGED
@@ -11,14 +11,6 @@ import _message from "antd/es/message";
|
|
11
11
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
12
12
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
13
13
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
14
|
-
/*
|
15
|
-
* @Author: ''
|
16
|
-
* @Date: 2024-06-04 10:01:18
|
17
|
-
* @LastEditors: za-xuwenli xuwenli@zhongan.io
|
18
|
-
* @LastEditTime: 2025-03-20 11:12:23
|
19
|
-
* @FilePath: /za-material-warehouse/src/ProTreeModal/index.tsx
|
20
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
21
|
-
*/
|
22
14
|
import React, { useEffect, useMemo, useRef } from 'react';
|
23
15
|
import { useDeepCompareEffect, useSetState, useRequest as useRequestFunc, useDebounceFn } from 'ahooks';
|
24
16
|
import { cloneDeep, isFunction } from 'lodash';
|
@@ -299,14 +291,13 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
299
291
|
})) === null || _state$flatTreeData$f === void 0 ? void 0 : _state$flatTreeData$f.map(function (item) {
|
300
292
|
return item[fieldNameValue];
|
301
293
|
}) : [];
|
294
|
+
onChange === null || onChange === void 0 ? void 0 : onChange([]);
|
302
295
|
setState({
|
303
296
|
checkedValues: _checkedValues,
|
304
297
|
beforeClearAllValues: state.checkedValues,
|
305
298
|
treeViewData: [],
|
306
299
|
checkAll: false
|
307
300
|
});
|
308
|
-
/* ******** fix:3.4.4-beta.4 点击清空全部不应该回调、所有的都是应该走统一的确定 ********* */
|
309
|
-
// onChange?.(_checkedValues);
|
310
301
|
};
|
311
302
|
/**
|
312
303
|
* Drawer close
|
@@ -543,7 +534,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
543
534
|
});
|
544
535
|
}
|
545
536
|
}, {
|
546
|
-
wait:
|
537
|
+
wait: 0
|
547
538
|
}),
|
548
539
|
onSearch = _useDebounceFn.run;
|
549
540
|
var handleSetSearchStr = function handleSetSearchStr(str) {
|
@@ -601,7 +592,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
601
592
|
appointChange: appointChange,
|
602
593
|
appointProps: appointProps
|
603
594
|
});
|
604
|
-
}, [state.checkedValues, state.checkAll, style, disabled, isView]);
|
595
|
+
}, [state.checkedValues, state.checkAll, style, disabled, isView, value]);
|
605
596
|
/**
|
606
597
|
* 全选操作
|
607
598
|
*/
|
@@ -779,7 +770,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
779
770
|
return _jsx(_Fragment, {
|
780
771
|
children: _jsxs("div", {
|
781
772
|
className: "pro-tree-modal",
|
782
|
-
children: [open === undefined
|
773
|
+
children: [open === undefined && TriggerComponent, _jsx(ProDrawerForm, {
|
783
774
|
onOk: handleFinish,
|
784
775
|
onCancel: handleClose,
|
785
776
|
okDisabled: disabled,
|
@@ -807,7 +798,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
807
798
|
return handleSetSearchStr(e.target.value);
|
808
799
|
},
|
809
800
|
prefix: _jsx(ReactSVG, {
|
810
|
-
className: "
|
801
|
+
className: "pro-tree-modal-search-svg",
|
811
802
|
src: searchSVG
|
812
803
|
})
|
813
804
|
}), _jsx("div", {
|
@@ -10,6 +10,17 @@
|
|
10
10
|
color: #939499;
|
11
11
|
}
|
12
12
|
|
13
|
+
.@{ant-prefix}-input-group-wrapper:hover {
|
14
|
+
.pro-tree-modal-view-svg {
|
15
|
+
color: var(--zaui-brand);
|
16
|
+
}
|
17
|
+
}
|
18
|
+
.pro-tree-modal-view-svg {
|
19
|
+
div {
|
20
|
+
display: flex;
|
21
|
+
}
|
22
|
+
}
|
23
|
+
|
13
24
|
&-content {
|
14
25
|
display: flex;
|
15
26
|
flex-direction: row;
|
@@ -59,7 +70,7 @@
|
|
59
70
|
margin-right: var(--zaui-space-size-md, 16px);
|
60
71
|
}
|
61
72
|
|
62
|
-
.
|
73
|
+
.pro-tree-modal-search-svg > div {
|
63
74
|
display: flex;
|
64
75
|
}
|
65
76
|
|
@@ -167,7 +178,7 @@
|
|
167
178
|
display: flex;
|
168
179
|
align-items: center;
|
169
180
|
|
170
|
-
.
|
181
|
+
.pro-tree-modal-view-svg {
|
171
182
|
margin-left: var(--zaui-space-size-sm, 8px);
|
172
183
|
}
|
173
184
|
}
|
@@ -13,15 +13,6 @@ import _Progress from "antd/es/progress";
|
|
13
13
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
14
14
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
15
15
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
16
|
-
/*
|
17
|
-
* @Author: wangshengqiang
|
18
|
-
* @Date: 2023-07-27 20:13:07
|
19
|
-
* @LastEditors: wangshengqiang
|
20
|
-
* @LastEditTime: 2023-11-29 19:33:04
|
21
|
-
* @Description: 图片类型
|
22
|
-
*
|
23
|
-
*/
|
24
|
-
|
25
16
|
import { useRef, useState } from 'react';
|
26
17
|
import { DndContext } from '@dnd-kit/core';
|
27
18
|
import { SortableContext, rectSortingStrategy } from '@dnd-kit/sortable';
|
package/es/ProUpload/index.js
CHANGED
@@ -5,13 +5,6 @@ import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutPr
|
|
5
5
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
6
6
|
var _excluded = ["value", "size", "action", "maxCount", "headerRender", "footerRender", "centerRender", "disabled", "uploadType", "buttonProps", "accept", "extraTipText", "beforeUpload", "onChange", "onDownload", "onPreview", "onRemove", "filterOriginFileObj", "method", "className", "dataParams", "name", "showExampleContent", "showUploadList", "otherProps", "transformResponse", "exampleTitle", "exampleContent", "exampleModalProps", "buttonText", "afterRender", "fieldNames", "isConfirmDelete"];
|
7
7
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
8
|
-
/*
|
9
|
-
* @Author: wangshengqiang
|
10
|
-
* @Date: 2023-02-03 14:18:59
|
11
|
-
* @LastEditTime: 2023-11-14 18:32:13
|
12
|
-
* @LastEditors: wangshengqiang
|
13
|
-
* @Description: 上传控件
|
14
|
-
*/
|
15
8
|
import React, { useEffect, useState, useImperativeHandle } from 'react';
|
16
9
|
import { isFunction, omit } from 'lodash';
|
17
10
|
import { PointerSensor, useSensor } from '@dnd-kit/core';
|
@@ -18,14 +18,6 @@ var _ProConfigProvider = require("../../../../ProConfigProvider");
|
|
18
18
|
var _ProForm = _interopRequireDefault(require("../../../../ProForm"));
|
19
19
|
var _Container = _interopRequireDefault(require("../../Container"));
|
20
20
|
var _excluded = ["className", "format"];
|
21
|
-
/*
|
22
|
-
* @Author: ''
|
23
|
-
* @Date: 2024-01-19 18:27:41
|
24
|
-
* @LastEditors: ''
|
25
|
-
* @LastEditTime: 2024-06-03 15:33:12
|
26
|
-
* @FilePath: /za-material-warehouse/src/ProForm/components/base/DatePicker/index.tsx
|
27
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
28
|
-
*/
|
29
21
|
var DatePicker = function DatePicker(props) {
|
30
22
|
var className = props.className,
|
31
23
|
_props$format = props.format,
|
@@ -16,16 +16,7 @@ var _ProConfigProvider = require("../../../../ProConfigProvider");
|
|
16
16
|
var _ProForm = _interopRequireDefault(require("../../../../ProForm"));
|
17
17
|
var _Container = _interopRequireDefault(require("../../Container"));
|
18
18
|
var _useDateRange = require("./useDateRange");
|
19
|
-
var _excluded = ["format", "otherProps", "separator", "range"];
|
20
|
-
/*
|
21
|
-
* @Author: ''
|
22
|
-
* @Date: 2024-04-10 11:39:17
|
23
|
-
* @LastEditors: ''
|
24
|
-
* @LastEditTime: 2024-05-29 11:50:49
|
25
|
-
* @FilePath: /za-material-warehouse/src/ProForm/components/base/RangePicker/index.tsx
|
26
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
27
|
-
*/
|
28
|
-
// @ts-check
|
19
|
+
var _excluded = ["format", "otherProps", "separator", "range"]; // @ts-check
|
29
20
|
var AntRangePicker = _antd.DatePicker.RangePicker;
|
30
21
|
var RangePicker = function RangePicker(props) {
|
31
22
|
var _props$format = props.format,
|
@@ -15,14 +15,6 @@ var _DndWrapper = _interopRequireWildcard(require("./components/DndWrapper"));
|
|
15
15
|
var _index = require("../../../index");
|
16
16
|
require("../../../../style/index.less");
|
17
17
|
var _excluded = ["dataSource", "tableProps", "draggableProps", "summaryProps", "emptyTextProps"];
|
18
|
-
/*
|
19
|
-
* @Author: ''
|
20
|
-
* @Date: 2024-08-09 13:48:59
|
21
|
-
* @LastEditors: ''
|
22
|
-
* @LastEditTime: 2024-08-27 15:27:44
|
23
|
-
* @FilePath: /za-material-warehouse/src/ProTable/components/RcTable/components/DraggableTable/index.tsx
|
24
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
25
|
-
*/
|
26
18
|
var DraggableTable = function DraggableTable(_ref) {
|
27
19
|
var dataSource = _ref.dataSource,
|
28
20
|
tableProps = _ref.tableProps,
|
@@ -39,7 +39,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
39
39
|
total: 0,
|
40
40
|
selectedRecords: [],
|
41
41
|
selectedRowKeys: [],
|
42
|
-
searchValues: undefined,
|
43
42
|
extraFilter: {
|
44
43
|
filters: undefined,
|
45
44
|
sorter: undefined
|
@@ -52,7 +51,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
52
51
|
total = _useSetState2$.total,
|
53
52
|
selectedRecords = _useSetState2$.selectedRecords,
|
54
53
|
selectedRowKeys = _useSetState2$.selectedRowKeys,
|
55
|
-
searchValues = _useSetState2$.searchValues,
|
56
54
|
extraFilter = _useSetState2$.extraFilter,
|
57
55
|
allSelected = _useSetState2$.allSelected,
|
58
56
|
setState = _useSetState2[1];
|
@@ -73,6 +71,9 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
73
71
|
transformParams = _useDefaultOptions.transformParams,
|
74
72
|
transformResponse = _useDefaultOptions.transformResponse,
|
75
73
|
disabled = _useDefaultOptions.disabled;
|
74
|
+
// 搜索表单里的值
|
75
|
+
var _searchValues = _antd.Form.useWatch([], form);
|
76
|
+
var searchValues = (0, _utils.removeEmptyKeys)(_searchValues);
|
76
77
|
var _ref = useRequestOptions || {},
|
77
78
|
defaultParams = _ref.defaultParams;
|
78
79
|
var defaultParam = Array.isArray(defaultParams) ? defaultParams === null || defaultParams === void 0 ? void 0 : defaultParams[0] : defaultParams || {};
|
@@ -251,7 +252,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
251
252
|
if ((selectedRecords === null || selectedRecords === void 0 ? void 0 : selectedRecords.length) || (0, _utils.isNonEmptyObject)(_values) || !(0, _lodash.isEqual)(previousSearchValues, _values)) {
|
252
253
|
previousSearchValues = _values;
|
253
254
|
setState({
|
254
|
-
searchValues: _values,
|
255
255
|
allSelected: false,
|
256
256
|
selectedRecords: [],
|
257
257
|
selectedRowKeys: []
|
@@ -263,7 +263,6 @@ function useAntdTable(service, options, useRequestOptions) {
|
|
263
263
|
}, [extraFilter, page.pageSize, previousPage, getTransformParams]);
|
264
264
|
var resetParams = (0, _react.useCallback)(function (page) {
|
265
265
|
setState({
|
266
|
-
searchValues: undefined,
|
267
266
|
allSelected: false,
|
268
267
|
selectedRecords: [],
|
269
268
|
selectedRowKeys: [],
|
@@ -735,12 +735,6 @@ export interface ProTableUseAntdTableType<I, R> {
|
|
735
735
|
* @default []
|
736
736
|
*/
|
737
737
|
selectedRowKeys: Key[];
|
738
|
-
/**
|
739
|
-
* 搜索值
|
740
|
-
* @description 当前表单的搜索条件
|
741
|
-
* @default undefined
|
742
|
-
*/
|
743
|
-
searchValues: I;
|
744
738
|
/**
|
745
739
|
* 额外过滤条件
|
746
740
|
* @description 表单之外的额外过滤条件
|
@@ -9,15 +9,6 @@ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/sli
|
|
9
9
|
var _jsxRuntime = require("react/jsx-runtime");
|
10
10
|
var _antd = require("antd");
|
11
11
|
var _react = require("react");
|
12
|
-
/*
|
13
|
-
* @Author: ''
|
14
|
-
* @Date: 2024-09-20 10:26:04
|
15
|
-
* @LastEditors: ''
|
16
|
-
* @LastEditTime: 2024-09-26 14:12:44
|
17
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/AdaptiveTooltip.tsx
|
18
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
19
|
-
*/
|
20
|
-
|
21
12
|
var AdaptiveTooltip = function AdaptiveTooltip(_ref) {
|
22
13
|
var children = _ref.children;
|
23
14
|
var _useState = (0, _react.useState)('right'),
|
@@ -13,14 +13,6 @@ var _antd = require("antd");
|
|
13
13
|
var _SearchTitle = _interopRequireDefault(require("./SearchTitle"));
|
14
14
|
var _CloseIcon = _interopRequireDefault(require("./CloseIcon"));
|
15
15
|
var _excluded = ["checkedValues", "disabled", "treeData", "searchStr", "showCodeName", "mode", "fieldNames", "handleOnChange", "handleFilterClose", "optionRender"];
|
16
|
-
/*
|
17
|
-
* @Author: ''
|
18
|
-
* @Date: 2024-07-03 11:02:19
|
19
|
-
* @LastEditors: za-xuwenli xuwenli@zhongan.io
|
20
|
-
* @LastEditTime: 2025-03-20 10:44:39
|
21
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/List.tsx
|
22
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
23
|
-
*/
|
24
16
|
function List(props) {
|
25
17
|
var checkedValues = props.checkedValues,
|
26
18
|
disabled = props.disabled,
|
@@ -8,15 +8,6 @@ exports.default = void 0;
|
|
8
8
|
var _jsxRuntime = require("react/jsx-runtime");
|
9
9
|
var _react = require("react");
|
10
10
|
var _AdaptiveTooltip = _interopRequireDefault(require("./AdaptiveTooltip"));
|
11
|
-
/*
|
12
|
-
* @Author: ''
|
13
|
-
* @Date: 2024-09-26 14:37:00
|
14
|
-
* @LastEditors: ''
|
15
|
-
* @LastEditTime: 2024-09-26 17:50:59
|
16
|
-
* @FilePath: /za-material-warehouse/src/ProTree/components/SearchTitle.tsx
|
17
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
18
|
-
*/
|
19
|
-
|
20
11
|
function SearchTitle(props) {
|
21
12
|
var label = props.label,
|
22
13
|
_props$searchStr = props.searchStr,
|
@@ -16,6 +16,7 @@ var _SearchTitle = _interopRequireDefault(require("./SearchTitle"));
|
|
16
16
|
var _CloseIcon = _interopRequireDefault(require("./CloseIcon"));
|
17
17
|
var _SortableItem = _interopRequireDefault(require("./SortableItem"));
|
18
18
|
var _ = require("..");
|
19
|
+
var _utils = require("../../utils");
|
19
20
|
/* eslint-disable brace-style */
|
20
21
|
|
21
22
|
function List(props, ref) {
|
@@ -111,6 +112,9 @@ function List(props, ref) {
|
|
111
112
|
}
|
112
113
|
};
|
113
114
|
function getLineHeight(string, width) {
|
115
|
+
if ((0, _utils.isEmpty)(string)) {
|
116
|
+
return 0;
|
117
|
+
}
|
114
118
|
// 创建临时元素
|
115
119
|
var temp = document.createElement('div');
|
116
120
|
temp.style.position = 'absolute';
|
@@ -80,7 +80,7 @@ function Trigger(props) {
|
|
80
80
|
}), (0, _jsxRuntime.jsx)("div", {
|
81
81
|
className: "pro-enum-input-addonAfter",
|
82
82
|
children: (0, _jsxRuntime.jsx)(_reactSvg.ReactSVG, {
|
83
|
-
className: "
|
83
|
+
className: "pro-tree-modal-view-svg",
|
84
84
|
src: _view.default,
|
85
85
|
onClick: onIconClick
|
86
86
|
})
|
@@ -142,7 +142,7 @@ function Trigger(props) {
|
|
142
142
|
onClick: handleClearAll
|
143
143
|
})
|
144
144
|
}), (0, _jsxRuntime.jsx)(_reactSvg.ReactSVG, {
|
145
|
-
className: "
|
145
|
+
className: "pro-tree-modal-view-svg",
|
146
146
|
src: _view.default,
|
147
147
|
onClick: onIconClick
|
148
148
|
})]
|
@@ -24,15 +24,6 @@ var _index2 = require("../ProTable/components/RcTable/components/DraggableTable/
|
|
24
24
|
var _inputSearch = _interopRequireDefault(require("../assets/input-search.svg"));
|
25
25
|
var _locale = _interopRequireWildcard(require("../locale"));
|
26
26
|
require("./style/index.less");
|
27
|
-
/*
|
28
|
-
* @Author: ''
|
29
|
-
* @Date: 2024-06-04 10:01:18
|
30
|
-
* @LastEditors: za-xuwenli xuwenli@zhongan.io
|
31
|
-
* @LastEditTime: 2025-03-20 11:12:23
|
32
|
-
* @FilePath: /za-material-warehouse/src/ProTreeModal/index.tsx
|
33
|
-
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
34
|
-
*/
|
35
|
-
|
36
27
|
var LIST = 'LIST';
|
37
28
|
var TREE = 'TREE';
|
38
29
|
var CASCADER = exports.CASCADER = 'CASCADER';
|
@@ -301,14 +292,13 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
301
292
|
})) === null || _state$flatTreeData$f === void 0 ? void 0 : _state$flatTreeData$f.map(function (item) {
|
302
293
|
return item[fieldNameValue];
|
303
294
|
}) : [];
|
295
|
+
onChange === null || onChange === void 0 ? void 0 : onChange([]);
|
304
296
|
setState({
|
305
297
|
checkedValues: _checkedValues,
|
306
298
|
beforeClearAllValues: state.checkedValues,
|
307
299
|
treeViewData: [],
|
308
300
|
checkAll: false
|
309
301
|
});
|
310
|
-
/* ******** fix:3.4.4-beta.4 点击清空全部不应该回调、所有的都是应该走统一的确定 ********* */
|
311
|
-
// onChange?.(_checkedValues);
|
312
302
|
};
|
313
303
|
/**
|
314
304
|
* Drawer close
|
@@ -545,7 +535,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
545
535
|
});
|
546
536
|
}
|
547
537
|
}, {
|
548
|
-
wait:
|
538
|
+
wait: 0
|
549
539
|
}),
|
550
540
|
onSearch = _useDebounceFn.run;
|
551
541
|
var handleSetSearchStr = function handleSetSearchStr(str) {
|
@@ -603,7 +593,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
603
593
|
appointChange: appointChange,
|
604
594
|
appointProps: appointProps
|
605
595
|
});
|
606
|
-
}, [state.checkedValues, state.checkAll, style, disabled, isView]);
|
596
|
+
}, [state.checkedValues, state.checkAll, style, disabled, isView, value]);
|
607
597
|
/**
|
608
598
|
* 全选操作
|
609
599
|
*/
|
@@ -781,7 +771,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
781
771
|
return (0, _jsxRuntime.jsx)(_jsxRuntime.Fragment, {
|
782
772
|
children: (0, _jsxRuntime.jsxs)("div", {
|
783
773
|
className: "pro-tree-modal",
|
784
|
-
children: [open === undefined
|
774
|
+
children: [open === undefined && TriggerComponent, (0, _jsxRuntime.jsx)(_index.ProDrawerForm, {
|
785
775
|
onOk: handleFinish,
|
786
776
|
onCancel: handleClose,
|
787
777
|
okDisabled: disabled,
|
@@ -809,7 +799,7 @@ var ProTreeModal = function ProTreeModal(props) {
|
|
809
799
|
return handleSetSearchStr(e.target.value);
|
810
800
|
},
|
811
801
|
prefix: (0, _jsxRuntime.jsx)(_reactSvg.ReactSVG, {
|
812
|
-
className: "
|
802
|
+
className: "pro-tree-modal-search-svg",
|
813
803
|
src: _inputSearch.default
|
814
804
|
})
|
815
805
|
}), (0, _jsxRuntime.jsx)("div", {
|
@@ -10,6 +10,17 @@
|
|
10
10
|
color: #939499;
|
11
11
|
}
|
12
12
|
|
13
|
+
.@{ant-prefix}-input-group-wrapper:hover {
|
14
|
+
.pro-tree-modal-view-svg {
|
15
|
+
color: var(--zaui-brand);
|
16
|
+
}
|
17
|
+
}
|
18
|
+
.pro-tree-modal-view-svg {
|
19
|
+
div {
|
20
|
+
display: flex;
|
21
|
+
}
|
22
|
+
}
|
23
|
+
|
13
24
|
&-content {
|
14
25
|
display: flex;
|
15
26
|
flex-direction: row;
|
@@ -59,7 +70,7 @@
|
|
59
70
|
margin-right: var(--zaui-space-size-md, 16px);
|
60
71
|
}
|
61
72
|
|
62
|
-
.
|
73
|
+
.pro-tree-modal-search-svg > div {
|
63
74
|
display: flex;
|
64
75
|
}
|
65
76
|
|
@@ -167,7 +178,7 @@
|
|
167
178
|
display: flex;
|
168
179
|
align-items: center;
|
169
180
|
|
170
|
-
.
|
181
|
+
.pro-tree-modal-view-svg {
|
171
182
|
margin-left: var(--zaui-space-size-sm, 8px);
|
172
183
|
}
|
173
184
|
}
|
@@ -24,15 +24,6 @@ var _look = _interopRequireDefault(require("../../assets/look.svg"));
|
|
24
24
|
var _delete = _interopRequireDefault(require("../../assets/delete.svg"));
|
25
25
|
var _download = _interopRequireDefault(require("../../assets/download.svg"));
|
26
26
|
var _locale = _interopRequireDefault(require("../../locale"));
|
27
|
-
/*
|
28
|
-
* @Author: wangshengqiang
|
29
|
-
* @Date: 2023-07-27 20:13:07
|
30
|
-
* @LastEditors: wangshengqiang
|
31
|
-
* @LastEditTime: 2023-11-29 19:33:04
|
32
|
-
* @Description: 图片类型
|
33
|
-
*
|
34
|
-
*/
|
35
|
-
|
36
27
|
var isImgage = function isImgage(_fileExt) {
|
37
28
|
return ['.PNG', '.JPG', '.JPEG', '.GIF', '.BMP', '.JPE'].includes(_fileExt.toLocaleUpperCase());
|
38
29
|
};
|
package/lib/ProUpload/index.js
CHANGED
@@ -22,13 +22,6 @@ var _ImageRender = _interopRequireDefault(require("./components/ImageRender"));
|
|
22
22
|
var _uitls = require("./uitls");
|
23
23
|
var _locale = _interopRequireDefault(require("../locale"));
|
24
24
|
var _excluded = ["value", "size", "action", "maxCount", "headerRender", "footerRender", "centerRender", "disabled", "uploadType", "buttonProps", "accept", "extraTipText", "beforeUpload", "onChange", "onDownload", "onPreview", "onRemove", "filterOriginFileObj", "method", "className", "dataParams", "name", "showExampleContent", "showUploadList", "otherProps", "transformResponse", "exampleTitle", "exampleContent", "exampleModalProps", "buttonText", "afterRender", "fieldNames", "isConfirmDelete"];
|
25
|
-
/*
|
26
|
-
* @Author: wangshengqiang
|
27
|
-
* @Date: 2023-02-03 14:18:59
|
28
|
-
* @LastEditTime: 2023-11-14 18:32:13
|
29
|
-
* @LastEditors: wangshengqiang
|
30
|
-
* @Description: 上传控件
|
31
|
-
*/
|
32
25
|
var defaultCustomRequest = function defaultCustomRequest(option) {
|
33
26
|
return option.onSuccess();
|
34
27
|
};
|
package/package.json
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
{
|
2
2
|
"name": "@zat-design/sisyphus-react",
|
3
|
-
"version": "3.13.
|
3
|
+
"version": "3.13.4-beta.1",
|
4
4
|
"license": "MIT",
|
5
5
|
"main": "lib/index.js",
|
6
6
|
"module": "es/index.js",
|
7
7
|
"typings": "lib/index.d.ts",
|
8
|
-
"homepage": "https://procomponents.zhongan.
|
8
|
+
"homepage": "https://procomponents.zhongan.tech",
|
9
9
|
"scripts": {
|
10
10
|
"analyze": "ANALYZE=1 dumi build",
|
11
11
|
"build": "npm run build-lib && npm run build-es && npm run build-dist",
|
@@ -63,7 +63,7 @@
|
|
63
63
|
"@pansy/react-watermark": "^3.1.13",
|
64
64
|
"@zat-design/utils": "1.1.37",
|
65
65
|
"ahooks": "3.8.4",
|
66
|
-
"antd": "4.24.
|
66
|
+
"antd": "4.24.16",
|
67
67
|
"big.js": "^6.2.1",
|
68
68
|
"classnames": "^2.3.1",
|
69
69
|
"lodash": "^4.17.21",
|