@zat-design/sisyphus-react 3.4.2-beta.6 → 3.4.2-beta.7

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.
Files changed (26) hide show
  1. package/dist/index.esm.css +63 -29
  2. package/es/ProEditTable/components/RenderField/index.js +2 -2
  3. package/es/ProEditTable/utils/index.js +35 -21
  4. package/es/ProLayout/components/Layout/Menu/OpenMenu/style/index.less +0 -1
  5. package/es/ProLayout/components/Layout/Menu/style/index.less +2 -2
  6. package/es/ProLayout/components/ProCollapse/PropTypes.d.ts +0 -5
  7. package/es/ProLayout/components/ProCollapse/index.js +0 -3
  8. package/es/ProLayout/components/ProCollapse/style/index.less +1 -24
  9. package/es/ProLayout/components/ProFooter/index.js +1 -1
  10. package/es/ProLayout/components/ProFooter/style/index.less +1 -1
  11. package/es/ProLayout/components/ProHeader/style/index.less +2 -1
  12. package/es/ProLayout/style/index.less +75 -3
  13. package/es/style/theme/antd.less +0 -1
  14. package/lib/ProEditTable/components/RenderField/index.js +1 -1
  15. package/lib/ProEditTable/utils/index.js +35 -21
  16. package/lib/ProLayout/components/Layout/Menu/OpenMenu/style/index.less +0 -1
  17. package/lib/ProLayout/components/Layout/Menu/style/index.less +2 -2
  18. package/lib/ProLayout/components/ProCollapse/PropTypes.d.ts +0 -5
  19. package/lib/ProLayout/components/ProCollapse/index.js +0 -3
  20. package/lib/ProLayout/components/ProCollapse/style/index.less +1 -24
  21. package/lib/ProLayout/components/ProFooter/index.js +1 -1
  22. package/lib/ProLayout/components/ProFooter/style/index.less +1 -1
  23. package/lib/ProLayout/components/ProHeader/style/index.less +2 -1
  24. package/lib/ProLayout/style/index.less +75 -3
  25. package/lib/style/theme/antd.less +0 -1
  26. package/package.json +1 -1
@@ -398,9 +398,6 @@
398
398
  .pro-layout-open-menu .ant-menu-submenu:hover > .ant-menu-submenu-title > .ant-menu-submenu-expand-icon {
399
399
  color: #fff;
400
400
  }
401
- .pro-layout-open-menu .ant-menu-item-selected {
402
- background: #000 !important;
403
- }
404
401
  .pro-layout-open-menu .ant-menu-item-selected .ant-menu-title-content h2 {
405
402
  font-weight: bold !important;
406
403
  }
@@ -539,8 +536,8 @@
539
536
  display: inline-block;
540
537
  white-space: nowrap;
541
538
  opacity: 0;
542
- -webkit-transition: opacity 0.5s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.5s;
543
- transition: opacity 0.5s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.5s;
539
+ -webkit-transition: opacity 0.3s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.3s;
540
+ transition: opacity 0.3s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.3s;
544
541
  }
545
542
  .pro-layout-row.pro-layout-menu-collapsed .pro-layout-content {
546
543
  margin-left: 220px !important;
@@ -620,8 +617,8 @@
620
617
  width: 48px;
621
618
  height: 48px;
622
619
  background: #292f3b;
623
- -webkit-transition: all 0.25s ease;
624
- transition: all 0.25s ease;
620
+ -webkit-transition: all 0.3s ease;
621
+ transition: all 0.3s ease;
625
622
  }
626
623
  .pro-layout-row .pro-layout-menu .pro-layout-menu-collapsed:hover {
627
624
  background-color: rgba(185, 185, 189, 0.1);
@@ -673,22 +670,6 @@
673
670
  width: 12px;
674
671
  margin-right: 0;
675
672
  }
676
- .pro-collapse.pro-collapse-card {
677
- border-radius: var(--zaui-border-radius, 8px);
678
- }
679
- .pro-collapse.pro-collapse-card.pro-collapse-no-title .pro-collapse-content {
680
- border-radius: var(--zaui-border-radius, 8px) !important;
681
- }
682
- .pro-collapse.pro-collapse-card .ant-collapse-header {
683
- border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
684
- }
685
- .pro-collapse.pro-collapse-card .pro-collapse-content {
686
- border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
687
- padding-bottom: var(--zaui-space-size-sm, 8px) !important;
688
- }
689
- .pro-collapse.pro-collapse-card .pro-collapse-panel .ant-collapse-header {
690
- border-radius: var(--zaui-border-radius, 8px) !important;
691
- }
692
673
  .pro-collapse.pro-collapse-no-title .ant-collapse-header {
693
674
  display: none !important;
694
675
  }
@@ -709,7 +690,7 @@
709
690
  font-size: var(--zaui-font-size-lg, 16px);
710
691
  }
711
692
  .pro-collapse .ant-collapse-expand-icon {
712
- color: #c5c7cd;
693
+ color: #999;
713
694
  }
714
695
  .pro-collapse.ant-collapse-borderless .ant-collapse-item > .ant-collapse-content > .ant-collapse-content-box {
715
696
  padding: 0;
@@ -819,7 +800,7 @@
819
800
  position: fixed;
820
801
  right: 0;
821
802
  bottom: 0;
822
- z-index: 101;
803
+ z-index: 98;
823
804
  width: 100%;
824
805
  padding: calc(var(--zaui-space-size-md, 16px) * var(--zaui-size, 1)) var(--zaui-space-size-lg, 32px);
825
806
  background: var(--zaui-base-bg, #ffffff);
@@ -846,6 +827,8 @@
846
827
  .pro-header {
847
828
  padding: 16px 0 0 0 !important;
848
829
  background-color: var(--zaui-base-bg, #ffffff);
830
+ -webkit-box-shadow: 2px 3px 8px 0px rgba(0, 55, 93, 0.1);
831
+ box-shadow: 2px 3px 8px 0px rgba(0, 55, 93, 0.1);
849
832
  }
850
833
  .pro-header.pro-header-no-back.pro-header-has-describe .pro-header-top {
851
834
  padding-left: var(--zaui-space-size-md, 16px);
@@ -1051,7 +1034,7 @@
1051
1034
  display: -webkit-flex;
1052
1035
  display: -ms-flexbox;
1053
1036
  display: flex;
1054
- background: #f7f9fc;
1037
+ background: #fafafa;
1055
1038
  border-top: 1px solid #f2f2f2;
1056
1039
  }
1057
1040
  .pro-header .pro-header-nav.pro-header-nav-open .pro-header-fold .pro-header-fold-bg {
@@ -1201,6 +1184,52 @@
1201
1184
  .pro-layout .pro-layout-menu-open .pro-layout-open-menu-lv1 h2 {
1202
1185
  font-weight: bold;
1203
1186
  }
1187
+ .pro-layout.pro-layout-light .pro-collapse {
1188
+ border-radius: var(--zaui-border-radius, 8px);
1189
+ }
1190
+ .pro-layout.pro-layout-light .pro-collapse.ant-collapse-borderless {
1191
+ background: #fff;
1192
+ }
1193
+ .pro-layout.pro-layout-light .pro-collapse.pro-collapse-no-title .pro-collapse-content {
1194
+ border-radius: var(--zaui-border-radius, 8px) !important;
1195
+ padding: var(--zaui-space-size-md, 16px);
1196
+ }
1197
+ .pro-layout.pro-layout-light .pro-collapse.pro-collapse-no-title .pro-header-no-describe {
1198
+ padding: 0 !important;
1199
+ }
1200
+ .pro-layout.pro-layout-light .pro-collapse .ant-collapse-item-active.pro-collapse-panel .ant-collapse-header {
1201
+ border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
1202
+ }
1203
+ .pro-layout.pro-layout-light .pro-collapse .pro-collapse-content {
1204
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
1205
+ padding: var(--zaui-space-size-md, 16px);
1206
+ }
1207
+ .pro-layout.pro-layout-light .pro-collapse .pro-collapse-content .pro-form {
1208
+ margin-bottom: 0;
1209
+ }
1210
+ .pro-layout.pro-layout-light .pro-collapse.pro-collapse-level2 .pro-collapse-panel .ant-collapse-header {
1211
+ background: #fff;
1212
+ }
1213
+ .pro-layout.pro-layout-light .pro-collapse .pro-collapse-panel .ant-collapse-header {
1214
+ border-radius: var(--zaui-border-radius, 8px) !important;
1215
+ background: #E4F2FE;
1216
+ }
1217
+ .pro-layout.pro-layout-light .pro-header {
1218
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
1219
+ }
1220
+ .pro-layout.pro-layout-light .pro-header.pro-header-no-describe {
1221
+ padding: var(--zaui-space-size-md, 16px) !important;
1222
+ }
1223
+ .pro-layout.pro-layout-light .pro-header.pro-header-no-describe .pro-header-top {
1224
+ padding-bottom: 0;
1225
+ }
1226
+ .pro-layout.pro-layout-light .pro-header.pro-header-has-describe .pro-header-nav-open {
1227
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
1228
+ }
1229
+ .pro-layout.pro-layout-light .pro-layout-content {
1230
+ padding: 0 var(--zaui-space-size-md, 16px);
1231
+ background: #f3f5f8;
1232
+ }
1204
1233
  .pro-layout.pro-layout-light .pro-layout-menu-open,
1205
1234
  .pro-layout.pro-layout-light .pro-layout-menu {
1206
1235
  -webkit-box-shadow: 2px 0px 5px 0px rgba(0, 55, 93, 0.1);
@@ -1301,6 +1330,10 @@
1301
1330
  }
1302
1331
  .pro-layout.pro-layout-light .pro-layout-open-menu .ant-menu-title-content div h2 {
1303
1332
  color: var(--zaui-text, #343434);
1333
+ padding-right: 26px;
1334
+ }
1335
+ .pro-layout.pro-layout-light .ant-menu-item-only-child .ant-menu-title-content div h2 {
1336
+ padding-right: 0;
1304
1337
  }
1305
1338
  .pro-layout.pro-layout-light .pro-layout-open-menu .ant-menu-item:hover,
1306
1339
  .pro-layout.pro-layout-light .pro-layout-open-menu .ant-menu-submenu-title:hover {
@@ -1312,7 +1345,8 @@
1312
1345
  position: absolute;
1313
1346
  left: var(--zaui-space-size-sm, 8px);
1314
1347
  width: calc(100% - 16px);
1315
- height: 38px;
1348
+ min-height: 38px;
1349
+ height: 80%;
1316
1350
  background-color: var(--zaui-brand, #006aff);
1317
1351
  border-radius: var(--zaui-border-radius, 8px);
1318
1352
  opacity: 0.08;
@@ -1340,8 +1374,8 @@
1340
1374
  margin-top: 48px;
1341
1375
  margin-left: 48px;
1342
1376
  padding: 0 var(--zaui-space-size-lg, 32px);
1343
- -webkit-transition: all 0.3s ease-in-out;
1344
- transition: all 0.3s ease-in-out;
1377
+ -webkit-transition: all 0.24s ease;
1378
+ transition: all 0.24s ease;
1345
1379
  }
1346
1380
  .pro-layout .pro-layout-content.pro-layout-has-notice {
1347
1381
  min-height: calc(100vh - 80px);
@@ -17,7 +17,7 @@ import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-run
17
17
  /* eslint-disable prefer-const */
18
18
  import React, { useCallback, useEffect } from 'react';
19
19
  import classNames from 'classnames';
20
- import { cloneDeep, isEqual, debounce, omit, isFunction } from 'lodash';
20
+ import { cloneDeep, isEqual, debounce, omit, isFunction, get } from 'lodash';
21
21
  import valueTypeMap from '../../../ProForm/utils/valueType';
22
22
  import transformMap from '../../utils/transform';
23
23
  import { getNamePath, difference } from '../../utils/tools';
@@ -85,7 +85,7 @@ var RenderField = function RenderField(_ref) {
85
85
  type = ((_type = type) === null || _type === void 0 ? void 0 : (_type$replace = _type.replace) === null || _type$replace === void 0 ? void 0 : _type$replace.call(_type, type[0], type[0].toUpperCase())) || 'Input';
86
86
  // 单行正在编辑时,临时生成一套formItem用来存储中间值,点击取消时候重置回上一次状态
87
87
  var namePath = getNamePath(name, virtualKey);
88
- var rowData = form.getFieldValue([].concat(_toConsumableArray(namePath), [index])) || record || {};
88
+ var rowData = get(form.getFieldsValue(), [].concat(_toConsumableArray(namePath), [index])) || record || {};
89
89
  var currentValue = dataIndex ? rowData === null || rowData === void 0 ? void 0 : rowData[dataIndex] : null;
90
90
  // 第三个参数
91
91
  var options = {
@@ -85,40 +85,54 @@ var getActionColumn = function getActionColumn(config) {
85
85
  index = tools.calc(firstIndex, '+', index);
86
86
  rowName = [].concat(_toConsumableArray(virtualRowName), [index]);
87
87
  if (!(type === 'save')) {
88
- _context.next = 5;
88
+ _context.next = 12;
89
89
  break;
90
90
  }
91
- _context.next = 5;
91
+ _context.prev = 3;
92
+ _context.next = 6;
92
93
  return customValidate(validateKeys, form, rowName);
93
- case 5:
94
+ case 6:
95
+ _context.next = 12;
96
+ break;
97
+ case 8:
98
+ _context.prev = 8;
99
+ _context.t0 = _context["catch"](3);
100
+ setTimeout(function () {
101
+ var errorDom = document.querySelector('.ant-form-item-has-error');
102
+ if (errorDom) {
103
+ errorDom.scrollIntoViewIfNeeded(true);
104
+ }
105
+ }, 0);
106
+ return _context.abrupt("return", Promise.reject(_context.t0));
107
+ case 12:
94
108
  // 编辑状态使用自定义form值,非编辑状态直接使用行数据
95
109
  _record = (_form$getFieldValue = form.getFieldValue(rowName)) !== null && _form$getFieldValue !== void 0 ? _form$getFieldValue : record; // 新增事件可以设置初始默认值,当做函数的出参导出
96
110
  onEvent = onClick || onHandle;
97
- _context.next = 9;
111
+ _context.next = 16;
98
112
  return onEvent === null || onEvent === void 0 ? void 0 : onEvent(_record, index, {
99
113
  form: form,
100
114
  namePath: virtualRowName
101
115
  });
102
- case 9:
103
- _context.t1 = _yield$onEvent = _context.sent;
104
- _context.t0 = _context.t1 !== null;
105
- if (!_context.t0) {
106
- _context.next = 13;
116
+ case 16:
117
+ _context.t2 = _yield$onEvent = _context.sent;
118
+ _context.t1 = _context.t2 !== null;
119
+ if (!_context.t1) {
120
+ _context.next = 20;
107
121
  break;
108
122
  }
109
- _context.t0 = _yield$onEvent !== void 0;
110
- case 13:
111
- if (!_context.t0) {
112
- _context.next = 17;
123
+ _context.t1 = _yield$onEvent !== void 0;
124
+ case 20:
125
+ if (!_context.t1) {
126
+ _context.next = 24;
113
127
  break;
114
128
  }
115
- _context.t2 = _yield$onEvent;
116
- _context.next = 18;
129
+ _context.t3 = _yield$onEvent;
130
+ _context.next = 25;
117
131
  break;
118
- case 17:
119
- _context.t2 = true;
120
- case 18:
121
- result = _context.t2;
132
+ case 24:
133
+ _context.t3 = true;
134
+ case 25:
135
+ result = _context.t3;
122
136
  if (result && type !== 'custom') {
123
137
  actions[type](_objectSpread(_objectSpread({}, config), {}, {
124
138
  rowName: [].concat(_toConsumableArray(name), [index]),
@@ -128,11 +142,11 @@ var getActionColumn = function getActionColumn(config) {
128
142
  validateKeys: validateKeys
129
143
  }));
130
144
  }
131
- case 20:
145
+ case 27:
132
146
  case "end":
133
147
  return _context.stop();
134
148
  }
135
- }, _callee);
149
+ }, _callee, null, [[3, 8]]);
136
150
  }));
137
151
  return function (_x, _x2) {
138
152
  return _ref.apply(this, arguments);
@@ -162,7 +162,6 @@
162
162
  }
163
163
 
164
164
  .@{ant-prefix}-menu-item-selected{
165
- background: #000 !important;
166
165
  .@{ant-prefix}-menu-title-content{
167
166
  h2{
168
167
  font-weight: bold !important;
@@ -44,7 +44,7 @@
44
44
  display: inline-block;
45
45
  white-space: nowrap;
46
46
  opacity: 0;
47
- transition: opacity 0.5s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.5s;
47
+ transition: opacity 0.3s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.3s;
48
48
  }
49
49
  }
50
50
  }
@@ -129,7 +129,7 @@
129
129
  width: 48px;
130
130
  height: 48px;
131
131
  background: #292f3b;
132
- transition: all 0.25s ease;
132
+ transition: all 0.3s ease;
133
133
  }
134
134
 
135
135
  .pro-layout-menu .pro-layout-menu-collapsed:hover {
@@ -15,11 +15,6 @@ export interface TitleListProps {
15
15
  }
16
16
  export interface ProCollapseProps {
17
17
  /**
18
- * @description 折叠头部模式
19
- * @default default
20
- */
21
- mode?: 'default' | 'card';
22
- /**
23
18
  * @description 折叠头部标题
24
19
  * @default -
25
20
  */
@@ -26,13 +26,10 @@ var ProCollapse = function ProCollapse(props) {
26
26
  _props$folding = props.folding,
27
27
  folding = _props$folding === void 0 ? false : _props$folding,
28
28
  collapseProps = props.collapseProps,
29
- _props$mode = props.mode,
30
- mode = _props$mode === void 0 ? 'default' : _props$mode,
31
29
  collapsePanelProps = props.collapsePanelProps,
32
30
  className = props.className;
33
31
  var cls = classNames(_defineProperty({
34
32
  'pro-collapse': true,
35
- 'pro-collapse-card': mode === 'card',
36
33
  'pro-collapse-level2': level === '2',
37
34
  'pro-collapse-list': titleList === null || titleList === void 0 ? void 0 : titleList.length,
38
35
  'pro-collapse-no-title': !title
@@ -2,29 +2,6 @@
2
2
  @import (reference) '~antd/es/style/themes/index.less';
3
3
 
4
4
  .pro-collapse {
5
-
6
- &.pro-collapse-card {
7
- border-radius: var(--zaui-border-radius, 8px);
8
- &.pro-collapse-no-title{
9
- .pro-collapse-content{
10
- border-radius: var(--zaui-border-radius, 8px) !important;
11
- }
12
- }
13
- .@{ant-prefix}-collapse-header{
14
- border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
15
- }
16
- .pro-collapse-content{
17
- border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
18
- padding-bottom: var(--zaui-space-size-sm, 8px) !important;
19
- }
20
- .pro-collapse-panel{
21
- .@{ant-prefix}-collapse-header{
22
- border-radius: var(--zaui-border-radius, 8px) !important;
23
- }
24
-
25
- }
26
- }
27
-
28
5
 
29
6
  &.pro-collapse-no-title {
30
7
  .@{ant-prefix}-collapse-header {
@@ -51,7 +28,7 @@
51
28
  }
52
29
 
53
30
  .@{ant-prefix}-collapse-expand-icon {
54
- color: #c5c7cd;
31
+ color: #999;
55
32
  }
56
33
 
57
34
  &.@{ant-prefix}-collapse-borderless
@@ -12,7 +12,7 @@ var ProFooter = function ProFooter(props) {
12
12
  className = props.className,
13
13
  children = props.children,
14
14
  _props$zIndex = props.zIndex,
15
- zIndex = _props$zIndex === void 0 ? 101 : _props$zIndex,
15
+ zIndex = _props$zIndex === void 0 ? 99 : _props$zIndex,
16
16
  _props$sideDom = props.sideDom,
17
17
  sideDom = _props$sideDom === void 0 ? '.pro-layout-sider-nav' : _props$sideDom,
18
18
  _props$contentDom = props.contentDom,
@@ -5,7 +5,7 @@
5
5
  position: fixed;
6
6
  right: 0;
7
7
  bottom: 0;
8
- z-index: 101;
8
+ z-index: 98;
9
9
  width: 100%;
10
10
  padding: calc(var(--zaui-space-size-md; 16px) * var(--zaui-size; 1))
11
11
  var(--zaui-space-size-lg, 32px);
@@ -5,6 +5,7 @@
5
5
  .pro-header {
6
6
  padding: 16px 0 0 0 !important;
7
7
  background-color: var(--zaui-base-bg, #ffffff);
8
+ box-shadow: 2px 3px 8px 0px rgba(0, 55, 93, 0.1);
8
9
 
9
10
  &.pro-header-no-back.pro-header-has-describe {
10
11
  .pro-header-top {
@@ -216,7 +217,7 @@
216
217
  .pro-header-nav {
217
218
  position: relative;
218
219
  display: flex;
219
- background: #f7f9fc;
220
+ background: #fafafa;
220
221
  border-top: 1px solid #f2f2f2;
221
222
 
222
223
  &.pro-header-nav-open {
@@ -21,7 +21,72 @@
21
21
 
22
22
  // light模式
23
23
  &.pro-layout-light {
24
- .pro-layout-menu-collapsed {
24
+
25
+ // pro-collapse折叠调整
26
+ .pro-collapse {
27
+ border-radius: var(--zaui-border-radius, 8px);
28
+ &.@{ant-prefix}-collapse-borderless{
29
+ background: #fff;
30
+ }
31
+ &.pro-collapse-no-title{
32
+ .pro-collapse-content{
33
+ border-radius: var(--zaui-border-radius, 8px) !important;
34
+ padding: var(--zaui-space-size-md, 16px);
35
+ }
36
+ .pro-header-no-describe{
37
+ padding: 0 !important;
38
+ }
39
+ }
40
+ .@{ant-prefix}-collapse-item-active{
41
+ &.pro-collapse-panel{
42
+ .@{ant-prefix}-collapse-header{
43
+ border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
44
+ }
45
+ }
46
+ }
47
+
48
+ .pro-collapse-content{
49
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
50
+ padding: var(--zaui-space-size-md, 16px);
51
+ .pro-form{
52
+ margin-bottom: 0;
53
+ }
54
+ }
55
+ &.pro-collapse-level2{
56
+ .pro-collapse-panel .@{ant-prefix}-collapse-header{
57
+ background: #fff;
58
+ }
59
+ }
60
+
61
+ .pro-collapse-panel{
62
+ .@{ant-prefix}-collapse-header{
63
+ border-radius: var(--zaui-border-radius, 8px) !important;
64
+ background: #E4F2FE;
65
+ }
66
+
67
+ }
68
+ }
69
+
70
+ // pro-header调整
71
+ .pro-header{
72
+ &.pro-header-no-describe{
73
+ padding: var(--zaui-space-size-md, 16px) !important;
74
+ .pro-header-top{
75
+ padding-bottom: 0;
76
+ }
77
+ }
78
+ &.pro-header-has-describe{
79
+ .pro-header-nav-open{
80
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
81
+ }
82
+ }
83
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
84
+ }
85
+
86
+
87
+ .pro-layout-content {
88
+ padding: 0 var(--zaui-space-size-md, 16px);
89
+ background: #f3f5f8;
25
90
  }
26
91
 
27
92
  .pro-layout-menu-open,
@@ -145,6 +210,12 @@
145
210
 
146
211
  .pro-layout-open-menu .@{ant-prefix}-menu-title-content div h2 {
147
212
  color: var(--zaui-text, #343434);
213
+ padding-right: 26px;
214
+ }
215
+ .@{ant-prefix}-menu-item-only-child{
216
+ .@{ant-prefix}-menu-title-content div h2{
217
+ padding-right: 0;
218
+ }
148
219
  }
149
220
 
150
221
  .pro-layout-open-menu .@{ant-prefix}-menu-item:hover,
@@ -156,7 +227,8 @@
156
227
  position: absolute;
157
228
  left: var(--zaui-space-size-sm, 8px);
158
229
  width: calc(100% - 16px);
159
- height: 38px;
230
+ min-height: 38px;
231
+ height: 80%;
160
232
  background-color: var(--zaui-brand, #006aff);
161
233
  border-radius: var(--zaui-border-radius, 8px);
162
234
  opacity: 0.08;
@@ -192,7 +264,7 @@
192
264
  margin-top: 48px;
193
265
  margin-left: 48px;
194
266
  padding: 0 var(--zaui-space-size-lg, 32px);
195
- transition: all 0.3s ease-in-out;
267
+ transition: all 0.24s ease;
196
268
 
197
269
  &.pro-layout-has-notice {
198
270
  min-height: calc(100vh - 80px);
@@ -673,7 +673,6 @@
673
673
  width: calc(100% - 18px);
674
674
  margin-bottom: 0;
675
675
  text-align: right;
676
- // background: #fff;
677
676
  }
678
677
  }
679
678
  }
@@ -88,7 +88,7 @@ var RenderField = function RenderField(_ref) {
88
88
  type = ((_type = type) === null || _type === void 0 ? void 0 : (_type$replace = _type.replace) === null || _type$replace === void 0 ? void 0 : _type$replace.call(_type, type[0], type[0].toUpperCase())) || 'Input';
89
89
  // 单行正在编辑时,临时生成一套formItem用来存储中间值,点击取消时候重置回上一次状态
90
90
  var namePath = (0, _tools.getNamePath)(name, virtualKey);
91
- var rowData = form.getFieldValue([].concat((0, _toConsumableArray2.default)(namePath), [index])) || record || {};
91
+ var rowData = (0, _lodash.get)(form.getFieldsValue(), [].concat((0, _toConsumableArray2.default)(namePath), [index])) || record || {};
92
92
  var currentValue = dataIndex ? rowData === null || rowData === void 0 ? void 0 : rowData[dataIndex] : null;
93
93
  // 第三个参数
94
94
  var options = {
@@ -89,40 +89,54 @@ var getActionColumn = function getActionColumn(config) {
89
89
  index = _utils.tools.calc(firstIndex, '+', index);
90
90
  rowName = [].concat((0, _toConsumableArray2.default)(virtualRowName), [index]);
91
91
  if (!(type === 'save')) {
92
- _context.next = 5;
92
+ _context.next = 12;
93
93
  break;
94
94
  }
95
- _context.next = 5;
95
+ _context.prev = 3;
96
+ _context.next = 6;
96
97
  return (0, _tools.customValidate)(validateKeys, form, rowName);
97
- case 5:
98
+ case 6:
99
+ _context.next = 12;
100
+ break;
101
+ case 8:
102
+ _context.prev = 8;
103
+ _context.t0 = _context["catch"](3);
104
+ setTimeout(function () {
105
+ var errorDom = document.querySelector('.ant-form-item-has-error');
106
+ if (errorDom) {
107
+ errorDom.scrollIntoViewIfNeeded(true);
108
+ }
109
+ }, 0);
110
+ return _context.abrupt("return", Promise.reject(_context.t0));
111
+ case 12:
98
112
  // 编辑状态使用自定义form值,非编辑状态直接使用行数据
99
113
  _record = (_form$getFieldValue = form.getFieldValue(rowName)) !== null && _form$getFieldValue !== void 0 ? _form$getFieldValue : record; // 新增事件可以设置初始默认值,当做函数的出参导出
100
114
  onEvent = onClick || onHandle;
101
- _context.next = 9;
115
+ _context.next = 16;
102
116
  return onEvent === null || onEvent === void 0 ? void 0 : onEvent(_record, index, {
103
117
  form: form,
104
118
  namePath: virtualRowName
105
119
  });
106
- case 9:
107
- _context.t1 = _yield$onEvent = _context.sent;
108
- _context.t0 = _context.t1 !== null;
109
- if (!_context.t0) {
110
- _context.next = 13;
120
+ case 16:
121
+ _context.t2 = _yield$onEvent = _context.sent;
122
+ _context.t1 = _context.t2 !== null;
123
+ if (!_context.t1) {
124
+ _context.next = 20;
111
125
  break;
112
126
  }
113
- _context.t0 = _yield$onEvent !== void 0;
114
- case 13:
115
- if (!_context.t0) {
116
- _context.next = 17;
127
+ _context.t1 = _yield$onEvent !== void 0;
128
+ case 20:
129
+ if (!_context.t1) {
130
+ _context.next = 24;
117
131
  break;
118
132
  }
119
- _context.t2 = _yield$onEvent;
120
- _context.next = 18;
133
+ _context.t3 = _yield$onEvent;
134
+ _context.next = 25;
121
135
  break;
122
- case 17:
123
- _context.t2 = true;
124
- case 18:
125
- result = _context.t2;
136
+ case 24:
137
+ _context.t3 = true;
138
+ case 25:
139
+ result = _context.t3;
126
140
  if (result && type !== 'custom') {
127
141
  _config.actions[type]((0, _objectSpread2.default)((0, _objectSpread2.default)({}, config), {}, {
128
142
  rowName: [].concat((0, _toConsumableArray2.default)(name), [index]),
@@ -132,11 +146,11 @@ var getActionColumn = function getActionColumn(config) {
132
146
  validateKeys: validateKeys
133
147
  }));
134
148
  }
135
- case 20:
149
+ case 27:
136
150
  case "end":
137
151
  return _context.stop();
138
152
  }
139
- }, _callee);
153
+ }, _callee, null, [[3, 8]]);
140
154
  }));
141
155
  return function (_x, _x2) {
142
156
  return _ref.apply(this, arguments);
@@ -162,7 +162,6 @@
162
162
  }
163
163
 
164
164
  .@{ant-prefix}-menu-item-selected{
165
- background: #000 !important;
166
165
  .@{ant-prefix}-menu-title-content{
167
166
  h2{
168
167
  font-weight: bold !important;
@@ -44,7 +44,7 @@
44
44
  display: inline-block;
45
45
  white-space: nowrap;
46
46
  opacity: 0;
47
- transition: opacity 0.5s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.5s;
47
+ transition: opacity 0.3s cubic-bezier(0.645, 0.045, 0.355, 1), color 0.3s;
48
48
  }
49
49
  }
50
50
  }
@@ -129,7 +129,7 @@
129
129
  width: 48px;
130
130
  height: 48px;
131
131
  background: #292f3b;
132
- transition: all 0.25s ease;
132
+ transition: all 0.3s ease;
133
133
  }
134
134
 
135
135
  .pro-layout-menu .pro-layout-menu-collapsed:hover {
@@ -15,11 +15,6 @@ export interface TitleListProps {
15
15
  }
16
16
  export interface ProCollapseProps {
17
17
  /**
18
- * @description 折叠头部模式
19
- * @default default
20
- */
21
- mode?: 'default' | 'card';
22
- /**
23
18
  * @description 折叠头部标题
24
19
  * @default -
25
20
  */
@@ -30,13 +30,10 @@ var ProCollapse = function ProCollapse(props) {
30
30
  _props$folding = props.folding,
31
31
  folding = _props$folding === void 0 ? false : _props$folding,
32
32
  collapseProps = props.collapseProps,
33
- _props$mode = props.mode,
34
- mode = _props$mode === void 0 ? 'default' : _props$mode,
35
33
  collapsePanelProps = props.collapsePanelProps,
36
34
  className = props.className;
37
35
  var cls = (0, _classnames.default)((0, _defineProperty2.default)({
38
36
  'pro-collapse': true,
39
- 'pro-collapse-card': mode === 'card',
40
37
  'pro-collapse-level2': level === '2',
41
38
  'pro-collapse-list': titleList === null || titleList === void 0 ? void 0 : titleList.length,
42
39
  'pro-collapse-no-title': !title
@@ -2,29 +2,6 @@
2
2
  @import (reference) '~antd/es/style/themes/index.less';
3
3
 
4
4
  .pro-collapse {
5
-
6
- &.pro-collapse-card {
7
- border-radius: var(--zaui-border-radius, 8px);
8
- &.pro-collapse-no-title{
9
- .pro-collapse-content{
10
- border-radius: var(--zaui-border-radius, 8px) !important;
11
- }
12
- }
13
- .@{ant-prefix}-collapse-header{
14
- border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
15
- }
16
- .pro-collapse-content{
17
- border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
18
- padding-bottom: var(--zaui-space-size-sm, 8px) !important;
19
- }
20
- .pro-collapse-panel{
21
- .@{ant-prefix}-collapse-header{
22
- border-radius: var(--zaui-border-radius, 8px) !important;
23
- }
24
-
25
- }
26
- }
27
-
28
5
 
29
6
  &.pro-collapse-no-title {
30
7
  .@{ant-prefix}-collapse-header {
@@ -51,7 +28,7 @@
51
28
  }
52
29
 
53
30
  .@{ant-prefix}-collapse-expand-icon {
54
- color: #c5c7cd;
31
+ color: #999;
55
32
  }
56
33
 
57
34
  &.@{ant-prefix}-collapse-borderless
@@ -18,7 +18,7 @@ var ProFooter = function ProFooter(props) {
18
18
  className = props.className,
19
19
  children = props.children,
20
20
  _props$zIndex = props.zIndex,
21
- zIndex = _props$zIndex === void 0 ? 101 : _props$zIndex,
21
+ zIndex = _props$zIndex === void 0 ? 99 : _props$zIndex,
22
22
  _props$sideDom = props.sideDom,
23
23
  sideDom = _props$sideDom === void 0 ? '.pro-layout-sider-nav' : _props$sideDom,
24
24
  _props$contentDom = props.contentDom,
@@ -5,7 +5,7 @@
5
5
  position: fixed;
6
6
  right: 0;
7
7
  bottom: 0;
8
- z-index: 101;
8
+ z-index: 98;
9
9
  width: 100%;
10
10
  padding: calc(var(--zaui-space-size-md; 16px) * var(--zaui-size; 1))
11
11
  var(--zaui-space-size-lg, 32px);
@@ -5,6 +5,7 @@
5
5
  .pro-header {
6
6
  padding: 16px 0 0 0 !important;
7
7
  background-color: var(--zaui-base-bg, #ffffff);
8
+ box-shadow: 2px 3px 8px 0px rgba(0, 55, 93, 0.1);
8
9
 
9
10
  &.pro-header-no-back.pro-header-has-describe {
10
11
  .pro-header-top {
@@ -216,7 +217,7 @@
216
217
  .pro-header-nav {
217
218
  position: relative;
218
219
  display: flex;
219
- background: #f7f9fc;
220
+ background: #fafafa;
220
221
  border-top: 1px solid #f2f2f2;
221
222
 
222
223
  &.pro-header-nav-open {
@@ -21,7 +21,72 @@
21
21
 
22
22
  // light模式
23
23
  &.pro-layout-light {
24
- .pro-layout-menu-collapsed {
24
+
25
+ // pro-collapse折叠调整
26
+ .pro-collapse {
27
+ border-radius: var(--zaui-border-radius, 8px);
28
+ &.@{ant-prefix}-collapse-borderless{
29
+ background: #fff;
30
+ }
31
+ &.pro-collapse-no-title{
32
+ .pro-collapse-content{
33
+ border-radius: var(--zaui-border-radius, 8px) !important;
34
+ padding: var(--zaui-space-size-md, 16px);
35
+ }
36
+ .pro-header-no-describe{
37
+ padding: 0 !important;
38
+ }
39
+ }
40
+ .@{ant-prefix}-collapse-item-active{
41
+ &.pro-collapse-panel{
42
+ .@{ant-prefix}-collapse-header{
43
+ border-radius: var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px) 0 0 !important;
44
+ }
45
+ }
46
+ }
47
+
48
+ .pro-collapse-content{
49
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
50
+ padding: var(--zaui-space-size-md, 16px);
51
+ .pro-form{
52
+ margin-bottom: 0;
53
+ }
54
+ }
55
+ &.pro-collapse-level2{
56
+ .pro-collapse-panel .@{ant-prefix}-collapse-header{
57
+ background: #fff;
58
+ }
59
+ }
60
+
61
+ .pro-collapse-panel{
62
+ .@{ant-prefix}-collapse-header{
63
+ border-radius: var(--zaui-border-radius, 8px) !important;
64
+ background: #E4F2FE;
65
+ }
66
+
67
+ }
68
+ }
69
+
70
+ // pro-header调整
71
+ .pro-header{
72
+ &.pro-header-no-describe{
73
+ padding: var(--zaui-space-size-md, 16px) !important;
74
+ .pro-header-top{
75
+ padding-bottom: 0;
76
+ }
77
+ }
78
+ &.pro-header-has-describe{
79
+ .pro-header-nav-open{
80
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
81
+ }
82
+ }
83
+ border-radius: 0 0 var(--zaui-border-radius, 8px) var(--zaui-border-radius, 8px);
84
+ }
85
+
86
+
87
+ .pro-layout-content {
88
+ padding: 0 var(--zaui-space-size-md, 16px);
89
+ background: #f3f5f8;
25
90
  }
26
91
 
27
92
  .pro-layout-menu-open,
@@ -145,6 +210,12 @@
145
210
 
146
211
  .pro-layout-open-menu .@{ant-prefix}-menu-title-content div h2 {
147
212
  color: var(--zaui-text, #343434);
213
+ padding-right: 26px;
214
+ }
215
+ .@{ant-prefix}-menu-item-only-child{
216
+ .@{ant-prefix}-menu-title-content div h2{
217
+ padding-right: 0;
218
+ }
148
219
  }
149
220
 
150
221
  .pro-layout-open-menu .@{ant-prefix}-menu-item:hover,
@@ -156,7 +227,8 @@
156
227
  position: absolute;
157
228
  left: var(--zaui-space-size-sm, 8px);
158
229
  width: calc(100% - 16px);
159
- height: 38px;
230
+ min-height: 38px;
231
+ height: 80%;
160
232
  background-color: var(--zaui-brand, #006aff);
161
233
  border-radius: var(--zaui-border-radius, 8px);
162
234
  opacity: 0.08;
@@ -192,7 +264,7 @@
192
264
  margin-top: 48px;
193
265
  margin-left: 48px;
194
266
  padding: 0 var(--zaui-space-size-lg, 32px);
195
- transition: all 0.3s ease-in-out;
267
+ transition: all 0.24s ease;
196
268
 
197
269
  &.pro-layout-has-notice {
198
270
  min-height: calc(100vh - 80px);
@@ -673,7 +673,6 @@
673
673
  width: calc(100% - 18px);
674
674
  margin-bottom: 0;
675
675
  text-align: right;
676
- // background: #fff;
677
676
  }
678
677
  }
679
678
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "3.4.2-beta.6",
3
+ "version": "3.4.2-beta.7",
4
4
  "license": "Apache-2.0",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",