@zat-design/sisyphus-react 3.8.2 → 3.8.3-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/coverage/lcov-report/src/.umi/core/devScripts.ts.html +241 -0
- package/coverage/lcov-report/src/.umi/core/history.ts.html +148 -0
- package/coverage/lcov-report/src/.umi/core/index.html +206 -0
- package/coverage/lcov-report/src/.umi/core/plugin.ts.html +109 -0
- package/coverage/lcov-report/src/.umi/core/pluginRegister.ts.html +160 -0
- package/coverage/lcov-report/src/.umi/core/polyfill.ts.html +97 -0
- package/coverage/lcov-report/src/.umi/core/routes.ts.html +26050 -0
- package/coverage/lcov-report/src/.umi/core/umiExports.ts.html +112 -0
- package/coverage/lcov-report/src/.umi/dumi/demos/index.html +116 -0
- package/coverage/lcov-report/src/.umi/dumi/demos/index.ts.html +6340 -0
- package/coverage/lcov-report/src/.umi/dumi/index.html +116 -0
- package/coverage/lcov-report/src/.umi/dumi/layout.tsx.html +109 -0
- package/coverage/lcov-report/src/.umi/index.html +116 -0
- package/coverage/lcov-report/src/.umi/plugin-antd/index.html +116 -0
- package/coverage/lcov-report/src/.umi/plugin-antd/runtime.tsx.html +172 -0
- package/coverage/lcov-report/src/.umi/plugin-helmet/exports.ts.html +94 -0
- package/coverage/lcov-report/src/.umi/plugin-helmet/index.html +116 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/Provider.tsx.html +196 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/exports.ts.html +106 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/index.html +146 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/models/index.html +116 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/models/initialState.ts.html +88 -0
- package/coverage/lcov-report/src/.umi/plugin-initial-state/runtime.tsx.html +124 -0
- package/coverage/lcov-report/src/.umi/plugin-locale/SelectLang.tsx.html +1246 -0
- package/coverage/lcov-report/src/.umi/plugin-locale/index.html +161 -0
- package/coverage/lcov-report/src/.umi/plugin-locale/locale.tsx.html +268 -0
- package/coverage/lcov-report/src/.umi/plugin-locale/localeExports.ts.html +778 -0
- package/coverage/lcov-report/src/.umi/plugin-locale/runtime.tsx.html +115 -0
- package/coverage/lcov-report/src/.umi/plugin-model/Provider.tsx.html +202 -0
- package/coverage/lcov-report/src/.umi/plugin-model/helpers/constant.tsx.html +97 -0
- package/coverage/lcov-report/src/.umi/plugin-model/helpers/dispatcher.tsx.html +142 -0
- package/coverage/lcov-report/src/.umi/plugin-model/helpers/executor.tsx.html +334 -0
- package/coverage/lcov-report/src/.umi/plugin-model/helpers/index.html +146 -0
- package/coverage/lcov-report/src/.umi/plugin-model/index.html +146 -0
- package/coverage/lcov-report/src/.umi/plugin-model/runtime.tsx.html +121 -0
- package/coverage/lcov-report/src/.umi/plugin-model/useModel.tsx.html +298 -0
- package/coverage/lcov-report/src/.umi/plugin-request/index.html +116 -0
- package/coverage/lcov-report/src/.umi/plugin-request/request.ts.html +919 -0
- package/coverage/lcov-report/src/.umi/umi.ts.html +268 -0
- package/dist/index.esm.css +16 -8
- package/dist/less.esm.css +16 -8
- package/es/ProEditTable/components/RenderField/ListChangedWrapper.js +7 -6
- package/es/ProEditTable/components/RenderField/index.js +1 -0
- package/es/ProEnum/hooks/useEnumRequest.js +1 -1
- package/es/ProEnum/index.js +2 -2
- package/es/ProForm/components/base/InputNumber/index.js +1 -1
- package/es/ProForm/components/combination/Group/component/ComRender.d.ts +1 -0
- package/es/ProForm/components/combination/Group/component/ComRender.js +4 -2
- package/es/ProForm/components/combination/Group/index.js +6 -3
- package/es/ProForm/components/render/ChangedWrapper.js +8 -2
- package/es/ProForm/components/render/Render.js +3 -2
- package/es/ProForm/components/render/propsType.d.ts +4 -0
- package/es/ProForm/style/index.less +15 -2
- package/es/ProForm/utils/useShouldUpdate.js +21 -6
- package/es/ProTable/components/FormatColumn/index.d.ts +3 -1
- package/es/ProTable/components/FormatColumn/index.js +134 -24
- package/es/ProTable/components/RenderColumn/index.d.ts +1 -0
- package/es/ProTable/components/RenderColumn/index.js +22 -7
- package/es/ProTable/index.js +20 -5
- package/es/ProTable/style/index.less +8 -6
- package/lib/ProEditTable/components/RenderField/ListChangedWrapper.js +10 -9
- package/lib/ProEditTable/components/RenderField/index.js +1 -0
- package/lib/ProEnum/hooks/useEnumRequest.js +1 -1
- package/lib/ProEnum/index.js +2 -2
- package/lib/ProForm/components/base/InputNumber/index.js +1 -1
- package/lib/ProForm/components/combination/Group/component/ComRender.d.ts +1 -0
- package/lib/ProForm/components/combination/Group/component/ComRender.js +4 -2
- package/lib/ProForm/components/combination/Group/index.js +6 -3
- package/lib/ProForm/components/render/ChangedWrapper.js +8 -2
- package/lib/ProForm/components/render/Render.js +3 -2
- package/lib/ProForm/components/render/propsType.d.ts +4 -0
- package/lib/ProForm/style/index.less +15 -2
- package/lib/ProForm/utils/useShouldUpdate.js +19 -4
- package/lib/ProTable/components/FormatColumn/index.d.ts +3 -1
- package/lib/ProTable/components/FormatColumn/index.js +133 -23
- package/lib/ProTable/components/RenderColumn/index.d.ts +1 -0
- package/lib/ProTable/components/RenderColumn/index.js +22 -7
- package/lib/ProTable/index.js +20 -5
- package/lib/ProTable/style/index.less +8 -6
- package/package.json +4 -3
- package/.vscode/extensions.json +0 -5
package/lib/ProTable/index.js
CHANGED
|
@@ -37,7 +37,7 @@ var defaultPage = exports.defaultPage = {
|
|
|
37
37
|
pageSize: 10
|
|
38
38
|
};
|
|
39
39
|
function ProTable(props) {
|
|
40
|
-
var _locale$ProTable, _curTableConfig$pathK;
|
|
40
|
+
var _locale$ProTable, _props$scroll, _curTableConfig$pathK;
|
|
41
41
|
var _ref = (0, _index.useProConfig)('globalConfig') || {},
|
|
42
42
|
configStorage = _ref.storage; // 获取全局缓存位置配置
|
|
43
43
|
var _ref2 = (0, _index.useProConfig)('ProTable') || {},
|
|
@@ -65,6 +65,9 @@ function ProTable(props) {
|
|
|
65
65
|
restProps = (0, _objectWithoutProperties2.default)(props, _excluded);
|
|
66
66
|
var _props$scrollFollowPa = props.scrollFollowParent,
|
|
67
67
|
scrollFollowParent = _props$scrollFollowPa === void 0 ? true : _props$scrollFollowPa;
|
|
68
|
+
var _scroll = (_props$scroll = props === null || props === void 0 ? void 0 : props.scroll) !== null && _props$scroll !== void 0 ? _props$scroll : {
|
|
69
|
+
x: 'max-content'
|
|
70
|
+
};
|
|
68
71
|
var wrapToolTipProps = {
|
|
69
72
|
getPopupContainer: scrollFollowParent ? function (triggerNode) {
|
|
70
73
|
return triggerNode.parentNode;
|
|
@@ -208,18 +211,22 @@ function ProTable(props) {
|
|
|
208
211
|
}).filter(function (item) {
|
|
209
212
|
return !(item === null || item === void 0 ? void 0 : item.delete);
|
|
210
213
|
});
|
|
211
|
-
newColumns === null || newColumns === void 0 ? void 0 : newColumns.forEach(function (item) {
|
|
214
|
+
newColumns === null || newColumns === void 0 ? void 0 : newColumns.forEach(function (item, index) {
|
|
212
215
|
(0, _FormatColumn.formatColumn)({
|
|
213
216
|
column: item,
|
|
214
217
|
originalObj: originalObj,
|
|
215
218
|
dataSourceObj: dataSourceObj,
|
|
216
219
|
rowKey: 'rowKey',
|
|
217
220
|
diffToolTip: toolTip,
|
|
218
|
-
wrapToolTipProps: wrapToolTipProps
|
|
221
|
+
wrapToolTipProps: wrapToolTipProps,
|
|
222
|
+
scroll: _scroll,
|
|
223
|
+
onUpdateMinWidth: function onUpdateMinWidth(w) {
|
|
224
|
+
curColumns[index].minWidth = w;
|
|
225
|
+
}
|
|
219
226
|
});
|
|
220
227
|
});
|
|
221
228
|
return newColumns;
|
|
222
|
-
}, [curColumns, handleResize]);
|
|
229
|
+
}, [curColumns, handleResize, _scroll]);
|
|
223
230
|
var _columns = (0, _react.useMemo)(function () {
|
|
224
231
|
return columns === null || columns === void 0 ? void 0 : columns.filter(function (item, index) {
|
|
225
232
|
var show = item.show;
|
|
@@ -232,6 +239,13 @@ function ProTable(props) {
|
|
|
232
239
|
return true;
|
|
233
240
|
});
|
|
234
241
|
}, [columns]);
|
|
242
|
+
var isExistPercentWidth = !!(_columns === null || _columns === void 0 ? void 0 : _columns.find(function (item) {
|
|
243
|
+
var _item$width;
|
|
244
|
+
return (item === null || item === void 0 ? void 0 : item.width) && typeof (item === null || item === void 0 ? void 0 : item.width) === 'string' && (item === null || item === void 0 ? void 0 : (_item$width = item.width) === null || _item$width === void 0 ? void 0 : _item$width.endsWith('%'));
|
|
245
|
+
}));
|
|
246
|
+
if (isExistPercentWidth) {
|
|
247
|
+
_scroll = props === null || props === void 0 ? void 0 : props.scroll;
|
|
248
|
+
}
|
|
235
249
|
var handleColumnConfig = /*#__PURE__*/function () {
|
|
236
250
|
var _ref6 = (0, _asyncToGenerator2.default)(/*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee(checkList) {
|
|
237
251
|
var newColumns, _columnConfig$onColum, catchColumns;
|
|
@@ -422,7 +436,8 @@ function ProTable(props) {
|
|
|
422
436
|
summary: summary,
|
|
423
437
|
dataSource: _dataSource
|
|
424
438
|
},
|
|
425
|
-
dataSource: _dataSource
|
|
439
|
+
dataSource: _dataSource,
|
|
440
|
+
scroll: _scroll
|
|
426
441
|
})), (0, _jsxRuntime.jsx)("span", {
|
|
427
442
|
className: "pro-table-resizable-line",
|
|
428
443
|
style: {
|
|
@@ -257,12 +257,14 @@
|
|
|
257
257
|
}
|
|
258
258
|
}
|
|
259
259
|
|
|
260
|
-
.@{ant-prefix}-table-
|
|
261
|
-
.@{ant-prefix}-table-
|
|
262
|
-
background: #d2fff4 !important;
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
260
|
+
tbody.@{ant-prefix}-table-tbody {
|
|
261
|
+
tr.@{ant-prefix}-table-row.new-cell {
|
|
262
|
+
background: var(--zaui-contract-bg-add; #d2fff4) !important;
|
|
263
|
+
background-color: var(--zaui-contract-bg-add; #d2fff4) !important;
|
|
264
|
+
|
|
265
|
+
td.@{ant-prefix}-table-cell {
|
|
266
|
+
background: var(--zaui-contract-bg-add; #d2fff4) !important;
|
|
267
|
+
background-color: var(--zaui-contract-bg-add; #d2fff4) !important;
|
|
266
268
|
border-bottom: 1px solid var(--zaui-form-control-line, #dcdcdc);
|
|
267
269
|
}
|
|
268
270
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zat-design/sisyphus-react",
|
|
3
|
-
"version": "3.8.
|
|
3
|
+
"version": "3.8.3-beta.1",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -49,7 +49,8 @@
|
|
|
49
49
|
"Android >= 4"
|
|
50
50
|
],
|
|
51
51
|
"resolutions": {
|
|
52
|
-
"@types/react": "^17.0.53"
|
|
52
|
+
"@types/react": "^17.0.53",
|
|
53
|
+
"mockjs/commander": "9.2.0"
|
|
53
54
|
},
|
|
54
55
|
"dependencies": {
|
|
55
56
|
"@ant-design/icons": "^4.2.2",
|
|
@@ -58,7 +59,7 @@
|
|
|
58
59
|
"@dnd-kit/sortable": "^7.0.2",
|
|
59
60
|
"@dnd-kit/utilities": "^3.2.1",
|
|
60
61
|
"@pansy/react-watermark": "^3.1.13",
|
|
61
|
-
"@zat-design/utils": "1.1.
|
|
62
|
+
"@zat-design/utils": "1.1.35",
|
|
62
63
|
"ahooks": "3.7.4",
|
|
63
64
|
"antd": "4.24.8",
|
|
64
65
|
"big.js": "^6.2.1",
|