@zat-design/sisyphus-react 3.5.4-beta.2 → 3.5.4

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.
@@ -22,7 +22,7 @@ import ProForm from '../ProForm';
22
22
  import Empty from '../assets/empty.png';
23
23
  import locale, { formatMessage } from '../locale';
24
24
  var ProEditTable = function ProEditTable(_ref, ref) {
25
- var _resetProps$id, _resetProps$id$split, _themeConfig$data2, _value$;
25
+ var _resetProps$id, _resetProps$id$split, _themeConfig$data2, _value$2;
26
26
  var value = _ref.value,
27
27
  onChange = _ref.onChange,
28
28
  onDrag = _ref.onDrag,
@@ -279,11 +279,9 @@ var ProEditTable = function ProEditTable(_ref, ref) {
279
279
  // },
280
280
  // );
281
281
  useEffect(function () {
282
- var isAllHasKey = value.every(function (item) {
283
- return item.rowKey;
284
- });
282
+ var _value$;
285
283
  // 初始化默认生成row-key
286
- if ((value === null || value === void 0 ? void 0 : value.length) && !isAllHasKey) {
284
+ if ((value === null || value === void 0 ? void 0 : value.length) && !(value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.rowKey)) {
287
285
  var _originalArr$forEach;
288
286
  var nextValues = value === null || value === void 0 ? void 0 : value.map(function (item) {
289
287
  return _objectSpread(_objectSpread({}, item), {}, {
@@ -330,7 +328,7 @@ var ProEditTable = function ProEditTable(_ref, ref) {
330
328
  }) : null, _jsx(_Table, _objectSpread(_objectSpread({
331
329
  ref: tableRef,
332
330
  className: _className,
333
- dataSource: (value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.rowKey) ? value : undefined,
331
+ dataSource: (value === null || value === void 0 ? void 0 : (_value$2 = value[0]) === null || _value$2 === void 0 ? void 0 : _value$2.rowKey) ? value : undefined,
334
332
  columns: _columns,
335
333
  rowSelection: renderRowSelection(),
336
334
  rowClassName: _rowClassName,
@@ -137,7 +137,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
137
137
  var _res$data;
138
138
  var list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.list : res === null || res === void 0 ? void 0 : res.data;
139
139
  setState({
140
- options: transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list
140
+ options: list
141
141
  });
142
142
  }
143
143
  })),
@@ -301,7 +301,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
301
301
  while (1) switch (_context2.prev = _context2.next) {
302
302
  case 0:
303
303
  _context2.prev = 0;
304
- if (!(!(selectedRowKeys === null || selectedRowKeys === void 0 ? void 0 : selectedRowKeys.length) || !(selectedRows === null || selectedRows === void 0 ? void 0 : selectedRows.length))) {
304
+ if (selectedRowKeys === null || selectedRowKeys === void 0 ? void 0 : selectedRowKeys.length) {
305
305
  _context2.next = 4;
306
306
  break;
307
307
  }
@@ -434,7 +434,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
434
434
  // 初始化回显,当传入initParams时,前端用来回险
435
435
  var getInitValues = /*#__PURE__*/function () {
436
436
  var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
437
- var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _res$data2, _list, list, _data, nextSelectRowKeys;
437
+ var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _list, list, _res$data2, _data, nextSelectRowKeys;
438
438
  return _regeneratorRuntime().wrap(function _callee4$(_context4) {
439
439
  while (1) switch (_context4.prev = _context4.next) {
440
440
  case 0:
@@ -459,9 +459,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
459
459
  case 8:
460
460
  res = _context4.sent;
461
461
  if (res === null || res === void 0 ? void 0 : res.data) {
462
- list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.list : res === null || res === void 0 ? void 0 : res.data;
462
+ list = [];
463
463
  if (transformResponse) {
464
464
  list = transformResponse(res === null || res === void 0 ? void 0 : res.data);
465
+ } else {
466
+ list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.list : res === null || res === void 0 ? void 0 : res.data;
465
467
  }
466
468
  _data = isMultiple ? list : (_list = list) === null || _list === void 0 ? void 0 : _list[0];
467
469
  if (_data) {
@@ -498,7 +500,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
498
500
  var getDefaultOneValues = /*#__PURE__*/function () {
499
501
  var _ref10 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5() {
500
502
  var _useRequest$options4, _useRequest$options5;
501
- var queryBean, page, params, res, _res$data3, _list2, list, _data2, nextSelectRowKeys;
503
+ var queryBean, page, params, res, _list2, list, _res$data3, _data2, nextSelectRowKeys;
502
504
  return _regeneratorRuntime().wrap(function _callee5$(_context5) {
503
505
  while (1) switch (_context5.prev = _context5.next) {
504
506
  case 0:
@@ -516,9 +518,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
516
518
  case 6:
517
519
  res = _context5.sent;
518
520
  if (res === null || res === void 0 ? void 0 : res.data) {
519
- list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.list : res === null || res === void 0 ? void 0 : res.data;
521
+ list = [];
520
522
  if (transformResponse) {
521
523
  list = transformResponse(res === null || res === void 0 ? void 0 : res.data);
524
+ } else {
525
+ list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.list : res === null || res === void 0 ? void 0 : res.data;
522
526
  }
523
527
  _data2 = isMultiple ? list : (_list2 = list) === null || _list2 === void 0 ? void 0 : _list2[0];
524
528
  nextSelectRowKeys = isMultiple ? value : [value];
@@ -600,11 +604,9 @@ var ProModalSelect = function ProModalSelect(props, ref) {
600
604
  nextState.selectedRows = value;
601
605
  }
602
606
  } else if (value) {
603
- var _list$filter;
604
607
  var nextSelectedRowKeys = isMultiple ? value : [value];
605
608
  nextState.selectedRowKeys = nextSelectedRowKeys;
606
- var list = options !== null && options !== void 0 ? options : data;
607
- nextState.selectedRows = list === null || list === void 0 ? void 0 : (_list$filter = list.filter) === null || _list$filter === void 0 ? void 0 : _list$filter.call(list, function (item) {
609
+ nextState.selectedRows = options.filter(function (item) {
608
610
  return nextSelectedRowKeys.includes(item[valueKey]);
609
611
  });
610
612
  }
@@ -627,8 +629,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
627
629
  pageSize: 50,
628
630
  queryBean: _objectSpread(_objectSpread({}, useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options7 = useRequest.options) === null || _useRequest$options7 === void 0 ? void 0 : _useRequest$options7.defaultParams), initParams)
629
631
  } : _objectSpread(_objectSpread({}, useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options8 = useRequest.options) === null || _useRequest$options8 === void 0 ? void 0 : _useRequest$options8.defaultParams), initParams);
630
- var nextParams = transformParams ? transformParams(params) : params;
631
- run(nextParams);
632
+ run(params);
632
633
  setState({
633
634
  isInit: false
634
635
  });
@@ -692,8 +693,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
692
693
  pageSize: 50,
693
694
  queryBean: queryBean
694
695
  } : queryBean;
695
- var nextParams = transformParams ? transformParams(params) : params;
696
- run(nextParams);
696
+ run(params);
697
697
  setState({
698
698
  isInit: false
699
699
  });
@@ -707,8 +707,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
707
707
  pageSize: 50,
708
708
  queryBean: queryBean
709
709
  } : queryBean;
710
- var nextParams = transformParams ? transformParams(params) : params;
711
- run(nextParams);
710
+ run(params);
712
711
  }, 2000),
713
712
  style: {
714
713
  width: isView || disabled ? '100%' : 'calc(100% - 30px)'
@@ -11,11 +11,8 @@ export default (function (_ref) {
11
11
  delayTime = _ref.delayTime,
12
12
  props = _objectWithoutProperties(_ref, _excluded);
13
13
  var _useStep = useStep(),
14
- notify = _useStep.notify,
15
- loading = _useStep.loading,
16
- setLoading = _useStep.setLoading;
14
+ notify = _useStep.notify;
17
15
  return /*#__PURE__*/React.cloneElement(children, _objectSpread(_objectSpread({}, props), {}, {
18
- loading: loading || (props === null || props === void 0 ? void 0 : props.loading),
19
16
  onClick: throttle( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
20
17
  var values;
21
18
  return _regeneratorRuntime().wrap(function _callee$(_context) {
@@ -27,7 +24,6 @@ export default (function (_ref) {
27
24
  case 3:
28
25
  values = _context.sent;
29
26
  setTimeout(function () {
30
- setLoading(false);
31
27
  var localData = localStorage.getItem('cache-pro-step');
32
28
  if (localData !== 'false') {
33
29
  var _children$props, _children$props$onCli;
@@ -31,10 +31,6 @@ var ProStep = function ProStep(_ref) {
31
31
  _useState2 = _slicedToArray(_useState, 2),
32
32
  anchorIds = _useState2[0],
33
33
  setAnchorIds = _useState2[1];
34
- var _useState3 = useState(false),
35
- _useState4 = _slicedToArray(_useState3, 2),
36
- loading = _useState4[0],
37
- setLoading = _useState4[1];
38
34
  var _useLocalStorageState = useLocalStorageState('cache-pro-step'),
39
35
  _useLocalStorageState2 = _slicedToArray(_useLocalStorageState, 2),
40
36
  setLocalData = _useLocalStorageState2[1];
@@ -106,7 +102,7 @@ var ProStep = function ProStep(_ref) {
106
102
  case 10:
107
103
  values[id] = _context.sent;
108
104
  case 11:
109
- _context.next = 20;
105
+ _context.next = 19;
110
106
  break;
111
107
  case 13:
112
108
  _context.prev = 13;
@@ -117,11 +113,10 @@ var ProStep = function ProStep(_ref) {
117
113
  console.error(_context.t0);
118
114
  }
119
115
  setErrorCollection(_defineProperty({}, id, num));
120
- setLoading(false);
121
116
  return _context.abrupt("return", _context.t0);
122
- case 20:
117
+ case 19:
123
118
  return _context.abrupt("return", values[id]);
124
- case 21:
119
+ case 20:
125
120
  case "end":
126
121
  return _context.stop();
127
122
  }
@@ -142,12 +137,11 @@ var ProStep = function ProStep(_ref) {
142
137
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
143
138
  while (1) switch (_context2.prev = _context2.next) {
144
139
  case 0:
145
- setLoading(true);
146
- _context2.next = 3;
140
+ _context2.next = 2;
147
141
  return emitter.emit();
148
- case 3:
142
+ case 2:
149
143
  return _context2.abrupt("return", values);
150
- case 4:
144
+ case 3:
151
145
  case "end":
152
146
  return _context2.stop();
153
147
  }
@@ -238,9 +232,7 @@ var ProStep = function ProStep(_ref) {
238
232
  register: register,
239
233
  notify: notify,
240
234
  triggerTo: triggerTo,
241
- handleScroll: handleScroll,
242
- loading: loading,
243
- setLoading: setLoading
235
+ handleScroll: handleScroll
244
236
  },
245
237
  children: _jsxs("div", {
246
238
  className: "pro-step-wrapper",
@@ -78,6 +78,7 @@ export var formatColumn = function formatColumn(column, originalObj, dataSourceO
78
78
  };
79
79
  // 后缀处理
80
80
  var suffixNode = function suffixNode(value, record, index) {
81
+ console.log('记录看下', suffix);
81
82
  if (isString(suffix) || /*#__PURE__*/isValidElement(suffix)) {
82
83
  return suffix;
83
84
  }
@@ -25,7 +25,7 @@ var _empty = _interopRequireDefault(require("../assets/empty.png"));
25
25
  var _locale = _interopRequireWildcard(require("../locale"));
26
26
  var _excluded = ["value", "onChange", "onDrag", "className", "columns", "type", "mode", "stripe", "draggable", "disabled", "insertType", "emptyBtnText", "actionWidth", "actionProps", "toolbarProps", "rowSelection", "onlyOneLineMsg", "deletePoConfirmMsg", "mulDeletePoConfirmMsg", "requiredAlign", "summary", "max", "headerRender", "pagination", "originalValues", "originalDiffTip", "rowKey", "rowDisabled", "rowDraggable", "footerRender", "scroll"];
27
27
  var ProEditTable = function ProEditTable(_ref, ref) {
28
- var _resetProps$id, _resetProps$id$split, _themeConfig$data2, _value$;
28
+ var _resetProps$id, _resetProps$id$split, _themeConfig$data2, _value$2;
29
29
  var value = _ref.value,
30
30
  onChange = _ref.onChange,
31
31
  onDrag = _ref.onDrag,
@@ -282,11 +282,9 @@ var ProEditTable = function ProEditTable(_ref, ref) {
282
282
  // },
283
283
  // );
284
284
  (0, _react.useEffect)(function () {
285
- var isAllHasKey = value.every(function (item) {
286
- return item.rowKey;
287
- });
285
+ var _value$;
288
286
  // 初始化默认生成row-key
289
- if ((value === null || value === void 0 ? void 0 : value.length) && !isAllHasKey) {
287
+ if ((value === null || value === void 0 ? void 0 : value.length) && !(value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.rowKey)) {
290
288
  var _originalArr$forEach;
291
289
  var nextValues = value === null || value === void 0 ? void 0 : value.map(function (item) {
292
290
  return (0, _objectSpread2.default)((0, _objectSpread2.default)({}, item), {}, {
@@ -333,7 +331,7 @@ var ProEditTable = function ProEditTable(_ref, ref) {
333
331
  }) : null, (0, _jsxRuntime.jsx)(_antd.Table, (0, _objectSpread2.default)((0, _objectSpread2.default)({
334
332
  ref: tableRef,
335
333
  className: _className,
336
- dataSource: (value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.rowKey) ? value : undefined,
334
+ dataSource: (value === null || value === void 0 ? void 0 : (_value$2 = value[0]) === null || _value$2 === void 0 ? void 0 : _value$2.rowKey) ? value : undefined,
337
335
  columns: _columns,
338
336
  rowSelection: renderRowSelection(),
339
337
  rowClassName: _rowClassName,
@@ -134,7 +134,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
134
134
  var _res$data;
135
135
  var list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.list : res === null || res === void 0 ? void 0 : res.data;
136
136
  setState({
137
- options: transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list
137
+ options: list
138
138
  });
139
139
  }
140
140
  })),
@@ -298,7 +298,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
298
298
  while (1) switch (_context2.prev = _context2.next) {
299
299
  case 0:
300
300
  _context2.prev = 0;
301
- if (!(!(selectedRowKeys === null || selectedRowKeys === void 0 ? void 0 : selectedRowKeys.length) || !(selectedRows === null || selectedRows === void 0 ? void 0 : selectedRows.length))) {
301
+ if (selectedRowKeys === null || selectedRowKeys === void 0 ? void 0 : selectedRowKeys.length) {
302
302
  _context2.next = 4;
303
303
  break;
304
304
  }
@@ -431,7 +431,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
431
431
  // 初始化回显,当传入initParams时,前端用来回险
432
432
  var getInitValues = /*#__PURE__*/function () {
433
433
  var _ref9 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee4() {
434
- var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _res$data2, _list, list, _data, nextSelectRowKeys;
434
+ var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _list, list, _res$data2, _data, nextSelectRowKeys;
435
435
  return (0, _regeneratorRuntime2.default)().wrap(function _callee4$(_context4) {
436
436
  while (1) switch (_context4.prev = _context4.next) {
437
437
  case 0:
@@ -456,9 +456,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
456
456
  case 8:
457
457
  res = _context4.sent;
458
458
  if (res === null || res === void 0 ? void 0 : res.data) {
459
- list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.list : res === null || res === void 0 ? void 0 : res.data;
459
+ list = [];
460
460
  if (transformResponse) {
461
461
  list = transformResponse(res === null || res === void 0 ? void 0 : res.data);
462
+ } else {
463
+ list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.list : res === null || res === void 0 ? void 0 : res.data;
462
464
  }
463
465
  _data = isMultiple ? list : (_list = list) === null || _list === void 0 ? void 0 : _list[0];
464
466
  if (_data) {
@@ -495,7 +497,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
495
497
  var getDefaultOneValues = /*#__PURE__*/function () {
496
498
  var _ref10 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee5() {
497
499
  var _useRequest$options4, _useRequest$options5;
498
- var queryBean, page, params, res, _res$data3, _list2, list, _data2, nextSelectRowKeys;
500
+ var queryBean, page, params, res, _list2, list, _res$data3, _data2, nextSelectRowKeys;
499
501
  return (0, _regeneratorRuntime2.default)().wrap(function _callee5$(_context5) {
500
502
  while (1) switch (_context5.prev = _context5.next) {
501
503
  case 0:
@@ -513,9 +515,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
513
515
  case 6:
514
516
  res = _context5.sent;
515
517
  if (res === null || res === void 0 ? void 0 : res.data) {
516
- list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.list : res === null || res === void 0 ? void 0 : res.data;
518
+ list = [];
517
519
  if (transformResponse) {
518
520
  list = transformResponse(res === null || res === void 0 ? void 0 : res.data);
521
+ } else {
522
+ list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.list : res === null || res === void 0 ? void 0 : res.data;
519
523
  }
520
524
  _data2 = isMultiple ? list : (_list2 = list) === null || _list2 === void 0 ? void 0 : _list2[0];
521
525
  nextSelectRowKeys = isMultiple ? value : [value];
@@ -597,11 +601,9 @@ var ProModalSelect = function ProModalSelect(props, ref) {
597
601
  nextState.selectedRows = value;
598
602
  }
599
603
  } else if (value) {
600
- var _list$filter;
601
604
  var nextSelectedRowKeys = isMultiple ? value : [value];
602
605
  nextState.selectedRowKeys = nextSelectedRowKeys;
603
- var list = options !== null && options !== void 0 ? options : data;
604
- nextState.selectedRows = list === null || list === void 0 ? void 0 : (_list$filter = list.filter) === null || _list$filter === void 0 ? void 0 : _list$filter.call(list, function (item) {
606
+ nextState.selectedRows = options.filter(function (item) {
605
607
  return nextSelectedRowKeys.includes(item[valueKey]);
606
608
  });
607
609
  }
@@ -624,8 +626,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
624
626
  pageSize: 50,
625
627
  queryBean: (0, _objectSpread3.default)((0, _objectSpread3.default)({}, useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options7 = useRequest.options) === null || _useRequest$options7 === void 0 ? void 0 : _useRequest$options7.defaultParams), initParams)
626
628
  } : (0, _objectSpread3.default)((0, _objectSpread3.default)({}, useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options8 = useRequest.options) === null || _useRequest$options8 === void 0 ? void 0 : _useRequest$options8.defaultParams), initParams);
627
- var nextParams = transformParams ? transformParams(params) : params;
628
- run(nextParams);
629
+ run(params);
629
630
  setState({
630
631
  isInit: false
631
632
  });
@@ -689,8 +690,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
689
690
  pageSize: 50,
690
691
  queryBean: queryBean
691
692
  } : queryBean;
692
- var nextParams = transformParams ? transformParams(params) : params;
693
- run(nextParams);
693
+ run(params);
694
694
  setState({
695
695
  isInit: false
696
696
  });
@@ -704,8 +704,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
704
704
  pageSize: 50,
705
705
  queryBean: queryBean
706
706
  } : queryBean;
707
- var nextParams = transformParams ? transformParams(params) : params;
708
- run(nextParams);
707
+ run(params);
709
708
  }, 2000),
710
709
  style: {
711
710
  width: isView || disabled ? '100%' : 'calc(100% - 30px)'
@@ -18,11 +18,8 @@ var _default = exports.default = function _default(_ref) {
18
18
  delayTime = _ref.delayTime,
19
19
  props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
20
20
  var _useStep = (0, _index.useStep)(),
21
- notify = _useStep.notify,
22
- loading = _useStep.loading,
23
- setLoading = _useStep.setLoading;
21
+ notify = _useStep.notify;
24
22
  return /*#__PURE__*/_react.default.cloneElement(children, (0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), {}, {
25
- loading: loading || (props === null || props === void 0 ? void 0 : props.loading),
26
23
  onClick: (0, _lodash.throttle)( /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee() {
27
24
  var values;
28
25
  return (0, _regeneratorRuntime2.default)().wrap(function _callee$(_context) {
@@ -34,7 +31,6 @@ var _default = exports.default = function _default(_ref) {
34
31
  case 3:
35
32
  values = _context.sent;
36
33
  setTimeout(function () {
37
- setLoading(false);
38
34
  var localData = localStorage.getItem('cache-pro-step');
39
35
  if (localData !== 'false') {
40
36
  var _children$props, _children$props$onCli;
@@ -38,10 +38,6 @@ var ProStep = function ProStep(_ref) {
38
38
  _useState2 = (0, _slicedToArray2.default)(_useState, 2),
39
39
  anchorIds = _useState2[0],
40
40
  setAnchorIds = _useState2[1];
41
- var _useState3 = (0, _react.useState)(false),
42
- _useState4 = (0, _slicedToArray2.default)(_useState3, 2),
43
- loading = _useState4[0],
44
- setLoading = _useState4[1];
45
41
  var _useLocalStorageState = (0, _ahooks.useLocalStorageState)('cache-pro-step'),
46
42
  _useLocalStorageState2 = (0, _slicedToArray2.default)(_useLocalStorageState, 2),
47
43
  setLocalData = _useLocalStorageState2[1];
@@ -113,7 +109,7 @@ var ProStep = function ProStep(_ref) {
113
109
  case 10:
114
110
  values[id] = _context.sent;
115
111
  case 11:
116
- _context.next = 20;
112
+ _context.next = 19;
117
113
  break;
118
114
  case 13:
119
115
  _context.prev = 13;
@@ -124,11 +120,10 @@ var ProStep = function ProStep(_ref) {
124
120
  console.error(_context.t0);
125
121
  }
126
122
  setErrorCollection((0, _defineProperty2.default)({}, id, num));
127
- setLoading(false);
128
123
  return _context.abrupt("return", _context.t0);
129
- case 20:
124
+ case 19:
130
125
  return _context.abrupt("return", values[id]);
131
- case 21:
126
+ case 20:
132
127
  case "end":
133
128
  return _context.stop();
134
129
  }
@@ -149,12 +144,11 @@ var ProStep = function ProStep(_ref) {
149
144
  return (0, _regeneratorRuntime2.default)().wrap(function _callee2$(_context2) {
150
145
  while (1) switch (_context2.prev = _context2.next) {
151
146
  case 0:
152
- setLoading(true);
153
- _context2.next = 3;
147
+ _context2.next = 2;
154
148
  return emitter.emit();
155
- case 3:
149
+ case 2:
156
150
  return _context2.abrupt("return", values);
157
- case 4:
151
+ case 3:
158
152
  case "end":
159
153
  return _context2.stop();
160
154
  }
@@ -245,9 +239,7 @@ var ProStep = function ProStep(_ref) {
245
239
  register: register,
246
240
  notify: notify,
247
241
  triggerTo: triggerTo,
248
- handleScroll: _utils.handleScroll,
249
- loading: loading,
250
- setLoading: setLoading
242
+ handleScroll: _utils.handleScroll
251
243
  },
252
244
  children: (0, _jsxRuntime.jsxs)("div", {
253
245
  className: "pro-step-wrapper",
@@ -85,6 +85,7 @@ var formatColumn = exports.formatColumn = function formatColumn(column, original
85
85
  };
86
86
  // 后缀处理
87
87
  var suffixNode = function suffixNode(value, record, index) {
88
+ console.log('记录看下', suffix);
88
89
  if ((0, _lodash.isString)(suffix) || /*#__PURE__*/(0, _react.isValidElement)(suffix)) {
89
90
  return suffix;
90
91
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "3.5.4-beta.2",
3
+ "version": "3.5.4",
4
4
  "license": "Apache-2.0",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",