fan-standard-comp 4.0.6 → 4.0.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 (57) hide show
  1. package/dist/fan-standard-comp.min.css +1 -1
  2. package/dist/fan-standard-comp.min.js +1 -1
  3. package/es/ButtonGroup/index.d.ts +2 -0
  4. package/es/ButtonGroup/index.js +31 -18
  5. package/es/ButtonGroup/styles/index.js +9 -1
  6. package/es/DragContent/index.js +1 -1
  7. package/es/DragContent/index.less +2 -3
  8. package/es/StandardContent/ContentHeader.d.ts +9 -0
  9. package/es/StandardContent/ContentHeader.js +79 -0
  10. package/es/StandardContent/SubfieldContent.d.ts +2 -0
  11. package/es/StandardContent/SubfieldContent.js +47 -20
  12. package/es/StandardContent/WrapperContent.d.ts +2 -0
  13. package/es/StandardContent/WrapperContent.js +52 -17
  14. package/es/StandardContent/styles/Header.d.ts +6 -0
  15. package/es/StandardContent/styles/Header.js +33 -0
  16. package/es/StandardContent/styles/Subfield.js +22 -4
  17. package/es/StandardContent/styles/Wrapper.js +7 -3
  18. package/es/StandardContent/styles/index.less +11 -11
  19. package/es/StandardForm/style/index.less +1 -1
  20. package/es/StandardModal/style/index.js +5 -3
  21. package/es/StandardModal/style/index.less +5 -5
  22. package/es/StandardTable/index.js +9 -9
  23. package/es/StandardTable/style/index.js +1 -1
  24. package/es/components/IconNode/index.d.ts +1 -0
  25. package/es/components/IconNode/index.js +6 -3
  26. package/es/theme/index.js +4 -4
  27. package/es/utils/index.d.ts +1 -0
  28. package/es/utils/index.js +3 -1
  29. package/es/utils/regExp.js +111 -0
  30. package/lib/ButtonGroup/index.d.ts +2 -0
  31. package/lib/ButtonGroup/index.js +31 -18
  32. package/lib/ButtonGroup/styles/index.js +9 -1
  33. package/lib/DragContent/index.js +1 -1
  34. package/lib/DragContent/index.less +2 -3
  35. package/lib/StandardContent/ContentHeader.d.ts +9 -0
  36. package/lib/StandardContent/ContentHeader.js +89 -0
  37. package/lib/StandardContent/SubfieldContent.d.ts +2 -0
  38. package/lib/StandardContent/SubfieldContent.js +49 -20
  39. package/lib/StandardContent/WrapperContent.d.ts +2 -0
  40. package/lib/StandardContent/WrapperContent.js +54 -17
  41. package/lib/StandardContent/styles/Header.d.ts +6 -0
  42. package/lib/StandardContent/styles/Header.js +39 -0
  43. package/lib/StandardContent/styles/Subfield.js +22 -4
  44. package/lib/StandardContent/styles/Wrapper.js +7 -3
  45. package/lib/StandardContent/styles/index.less +11 -11
  46. package/lib/StandardForm/style/index.less +1 -1
  47. package/lib/StandardModal/style/index.js +5 -3
  48. package/lib/StandardModal/style/index.less +5 -5
  49. package/lib/StandardTable/index.js +9 -9
  50. package/lib/StandardTable/style/index.js +1 -1
  51. package/lib/components/IconNode/index.d.ts +1 -0
  52. package/lib/components/IconNode/index.js +6 -3
  53. package/lib/theme/index.js +4 -4
  54. package/lib/utils/index.d.ts +1 -0
  55. package/lib/utils/index.js +11 -0
  56. package/lib/utils/regExp.js +116 -0
  57. package/package.json +1 -1
@@ -19,10 +19,10 @@
19
19
  //background: @background-color-base;
20
20
  height: 100%;
21
21
  overflow: auto;
22
- box-sizing: border-box;
22
+ //box-sizing: border-box;
23
23
 
24
24
  & * {
25
- box-sizing: border-box;
25
+ //box-sizing: border-box;
26
26
  }
27
27
 
28
28
  & .light-block {
@@ -34,21 +34,21 @@
34
34
 
35
35
  .spec-grid-content {
36
36
  position: relative;
37
- display: flex;
37
+ // display: flex;
38
38
  //height: calc(100vh - @layout-header-height);
39
- height: 100%;
39
+ //height: 100%;
40
40
  background: transparent; // @background-color-base;
41
- box-sizing: border-box;
42
-
43
- & * {
44
- box-sizing: border-box;
45
- }
41
+ //box-sizing: border-box;
42
+ //
43
+ //& * {
44
+ // box-sizing: border-box;
45
+ //}
46
46
  .spec-grid-left {
47
47
  //height: calc(100vh - @layout-header-height);
48
- height: 100%;
48
+ //height: 100%;
49
49
  //padding: @padding-md @padding-sm;
50
50
  //background: @layout-body-background;
51
- overflow-y: auto;
51
+ //overflow-y: auto;
52
52
  //.scroll-bar();
53
53
  .ant-tree-list,
54
54
  .ant-tree {
@@ -32,7 +32,7 @@
32
32
 
33
33
  > label {
34
34
  //min-height: @input-height-base;
35
- height: auto;
35
+ //height: auto;
36
36
 
37
37
  &.ant-form-item-required {
38
38
  padding-left: 8px;
@@ -14,14 +14,14 @@ var StandardPanelStyleFunc = function StandardPanelStyleFunc(prefix) {
14
14
  };
15
15
  return createStyleHook(prefix, function (token) {
16
16
  var prefixCls = ".".concat(prefix);
17
- return [_defineProperty(_defineProperty(_defineProperty({}, prefixCls, {
17
+ return [_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, prefixCls, {
18
18
  '.ant-modal-body ': _objectSpread(_objectSpread({}, scrollBar(token)), {}, {
19
19
  padding: "".concat(token.paddingXS, "px 0")
20
20
  }),
21
21
  '&.ant-modal .ant-modal-footer .ant-btn + .ant-btn': {
22
22
  marginInlineStart: token.marginXS
23
23
  },
24
- '.modalForm': {
24
+ '.spec-standard-form': {
25
25
  '&.ant-form-horizontal .ant-form-item-label': {
26
26
  '> label': {
27
27
  minHeight: token.controlHeight + 'px'
@@ -40,7 +40,9 @@ var StandardPanelStyleFunc = function StandardPanelStyleFunc(prefix) {
40
40
  '&:before': {
41
41
  borderLeft: " 4px solid ".concat(token.colorPrimary)
42
42
  }
43
- }), '.modalPanelTitle, .modal-grid-title', {
43
+ }), '.modalPanelTitle', {}), '.modalPanelTitle, .modal-grid-title', {
44
+ height: token.controlHeight + 'px',
45
+ lineHeight: token.controlHeight + 'px',
44
46
  margin: "0 0 ".concat(token.margin, "px 0"),
45
47
  paddingBottom: token.paddingXS,
46
48
  borderBottom: "1px solid ".concat(token.colorBorder)
@@ -20,7 +20,7 @@
20
20
  white-space: inherit;
21
21
  > label {
22
22
  //min-height: @input-height-base;
23
- height: auto;
23
+ //height: auto;
24
24
  &.ant-form-item-required::before {
25
25
  margin-right: 2px;
26
26
  }
@@ -30,13 +30,13 @@
30
30
  }
31
31
 
32
32
  .modalPanelTitle {
33
- height: 32px;
33
+ //height: 32px;
34
34
  //margin: 0 0 @padding-md 0;
35
35
  //padding-bottom: @padding-xs;
36
36
  //color: @text-color;
37
37
  //font-size: @font-size-base + 1;
38
38
  font-weight: bold;
39
- line-height: 32px;
39
+ //line-height: 32px;
40
40
  //border-bottom: 1px solid @border-color-base;
41
41
  }
42
42
  .ant-form-item.form-item-view-only {
@@ -50,14 +50,14 @@
50
50
  }
51
51
  .modalGridTitle,
52
52
  .modal-grid-title{
53
- height: 32px;
53
+ //height: 32px;
54
54
  //margin: 0 0 @padding-md 0;
55
55
  //padding-bottom: @padding-xs;
56
56
  //padding-left: @padding-xs;
57
57
  //color: @text-color;
58
58
  //font-size: @font-size-base + 1;
59
59
  //font-weight: bold;
60
- line-height: 32px;
60
+ //line-height: 32px;
61
61
  position: relative;
62
62
  &.modalPanelTitle {
63
63
  border-bottom: 0;
@@ -102,9 +102,9 @@ var StandardTable = function StandardTable(props) {
102
102
  if (typeof buttonGroup === 'function') recombinationGroup = buttonGroup(text, record, rowIndex); // 方法返回数组结构
103
103
  // 判断是否是数组且长度大于0时 ?{如下结构渲染} : {按buttonGroup返回的node渲染}
104
104
  if (Array.isArray(buttonGroup) || typeof buttonGroup === 'function') {
105
- var _colItem4, _colItem5;
105
+ var _colItem4, _colItem5, _colItem6;
106
106
  if (recombinationGroup.length === 0) return '-';
107
- return /*#__PURE__*/React.createElement(ButtonGroup, {
107
+ return /*#__PURE__*/React.createElement(ButtonGroup, _extends({
108
108
  type: "text",
109
109
  min: colItem.min || 2 // 配置按钮展示最少数量,其他的将会被折叠
110
110
  ,
@@ -115,11 +115,12 @@ var StandardTable = function StandardTable(props) {
115
115
  text: text,
116
116
  record: record,
117
117
  rowIndex: rowIndex
118
- },
119
- dropdownConfig: colItem.buttonGroupConfig || {},
118
+ }
119
+ // dropdownConfig={colItem.buttonGroupConfig || {}}
120
+ ,
120
121
  moreText: (_colItem4 = colItem) === null || _colItem4 === void 0 ? void 0 : _colItem4.moreText,
121
122
  moreIcon: (_colItem5 = colItem) === null || _colItem5 === void 0 ? void 0 : _colItem5.moreIcon
122
- });
123
+ }, ((_colItem6 = colItem) === null || _colItem6 === void 0 ? void 0 : _colItem6.buttonGroupConfig) || {}));
123
124
  } else {
124
125
  return buttonGroup;
125
126
  }
@@ -148,13 +149,12 @@ var StandardTable = function StandardTable(props) {
148
149
  batchButtonGroup = exProps.batchButtonGroup;
149
150
  // 只有配置rowSelection才显示对应的批量按钮组
150
151
  var list = _.unionBy(rowSelection && (rowSelection === null || rowSelection === void 0 ? void 0 : rowSelection.type) !== 'radio' && (batchButtonGroup || []), buttonGroup || []);
151
- return /*#__PURE__*/React.createElement(ButtonGroup, {
152
+ return /*#__PURE__*/React.createElement(ButtonGroup, _extends({
152
153
  options: list,
153
154
  min: min,
154
155
  codes: codes,
155
- permissionCodes: permissionCodes,
156
- dropdownConfig: buttonGroupConfig
157
- });
156
+ permissionCodes: permissionCodes
157
+ }, buttonGroupConfig));
158
158
  };
159
159
  return wrapSSR( /*#__PURE__*/React.createElement(Card, {
160
160
  className: classNames(componentName, 'standard-table', className, hashId),
@@ -78,7 +78,7 @@ var StandardTableStyleFunc = function StandardTableStyleFunc(prefix) {
78
78
  'table': {
79
79
  fontSize: token.fontSize,
80
80
  '> .ant-table-thead > tr > th': {
81
- fontSize: token.fontSizeLG
81
+ fontSize: token.fontSize
82
82
  },
83
83
  '.ant-table-thead > tr > th': {
84
84
  padding: "12px ".concat(token.paddingMD, "px"),
@@ -11,6 +11,7 @@ import React from "react";
11
11
  */
12
12
  interface IconNodeProps {
13
13
  icon?: string | string[] | React.ReactNode;
14
+ style?: any;
14
15
  }
15
16
  declare const IconNode: (props: IconNodeProps) => React.JSX.Element | null;
16
17
  export default IconNode;
@@ -13,21 +13,24 @@ import React from "react";
13
13
  */
14
14
 
15
15
  var IconNode = function IconNode(props) {
16
- var icon = props.icon;
16
+ var icon = props.icon,
17
+ style = props.style;
17
18
  if (!icon) return null;
18
19
  if (typeof icon === 'string') {
19
20
  var iconArr = icon.split(',');
20
21
  return /*#__PURE__*/React.createElement(SpecIcon, {
21
22
  prefix: iconArr.length > 1 ? iconArr[0] : 'speci',
22
23
  noPrefix: !iconArr[0] || iconArr[0] === 'noPrefix',
23
- name: iconArr.length > 1 ? iconArr[1] : icon
24
+ name: iconArr.length > 1 ? iconArr[1] : icon,
25
+ style: style
24
26
  });
25
27
  }
26
28
  if (Array.isArray(icon) && icon.length > 1) {
27
29
  // @ts-ignore
28
30
  return /*#__PURE__*/React.createElement(SpecIcon, {
29
31
  prefix: icon[0],
30
- name: icon[1]
32
+ name: icon[1],
33
+ style: style
31
34
  }); // 预留 Array ['speci','plus']
32
35
  }
33
36
  return /*#__PURE__*/React.createElement(React.Fragment, null, icon);
package/es/theme/index.js CHANGED
@@ -7,8 +7,8 @@ export var scrollBar = function scrollBar(token) {
7
7
  return _defineProperty(_defineProperty(_defineProperty({}, '&::-webkit-scrollbar-track-piece', {
8
8
  background: new TinyColor('#c1c1c1').setAlpha(0.02).toRgbString() // new TinyColor(token.colorPrimary).setAlpha(0.1)
9
9
  }), '&::-webkit-scrollbar', {
10
- width: '6px',
11
- height: '6px'
10
+ width: '8px',
11
+ height: '8px'
12
12
  }), '&::-webkit-scrollbar-thumb', {
13
13
  background: new TinyColor('#c1c1c1').setAlpha(0.5).toRgbString(),
14
14
  // new TinyColor(token.colorPrimary).setAlpha(0.5),
@@ -19,8 +19,8 @@ export var scrollBarPrimary = function scrollBarPrimary(token) {
19
19
  return _defineProperty(_defineProperty(_defineProperty({}, '&::-webkit-scrollbar-track-piece', {
20
20
  background: new TinyColor(token.colorPrimary).setAlpha(0.1).toRgbString() // new TinyColor(token.colorPrimary).setAlpha(0.1)
21
21
  }), '&::-webkit-scrollbar', {
22
- width: '6px',
23
- height: '6px'
22
+ width: '8px',
23
+ height: '8px'
24
24
  }), '&::-webkit-scrollbar-thumb', {
25
25
  background: new TinyColor(token.colorPrimary).setAlpha(0.5).toRgbString(),
26
26
  // new TinyColor(token.colorPrimary).setAlpha(0.5),
@@ -3,3 +3,4 @@ export * from './ValueFormat';
3
3
  export * from './dictSelectUtil';
4
4
  export * from './transferFile';
5
5
  export * from './urlUtils';
6
+ export * from './regExp';
package/es/utils/index.js CHANGED
@@ -2,4 +2,6 @@ export * from "./getParentNodes";
2
2
  export * from "./ValueFormat";
3
3
  export * from "./dictSelectUtil";
4
4
  export * from "./transferFile";
5
- export * from "./urlUtils";
5
+ export * from "./urlUtils";
6
+ // @ts-ignore
7
+ export * from "./regExp";
@@ -0,0 +1,111 @@
1
+ /* eslint-disable */
2
+ // 校验身份证格式
3
+ var isIdCard = function isIdCard(value) {
4
+ // 身份证号码为15位或者18位,15位时全为数字,18位前17位为数字,最后一位是校验位,可能为数字或字符X
5
+ var idCardReg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
6
+ return idCardReg.test(value);
7
+ };
8
+ var isEmail = function isEmail(value) {
9
+ /* eslint no-useless-escape:0 */
10
+ var emailReg = /^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/;
11
+ return emailReg.test(value);
12
+ };
13
+
14
+ // 手机或者固定电话
15
+ var isPhone = function isPhone(value) {
16
+ /* eslint no-useless-escape:0 */
17
+ value = value.split('-').join('').split(' ').join('');
18
+ var is400 = /^400\d{7}$/;
19
+ var phoneReg = /^((0\d{2,3}-?\d{7,8})|(1[3456789]\d{9}))$/;
20
+ return is400.test(value) || phoneReg.test(value);
21
+ };
22
+
23
+ // 传真号码
24
+ var isSendNumber = function isSendNumber(value) {
25
+ var reg = /^(\d{3,4}-)?\d{7,8}$/;
26
+ return reg.test(value);
27
+ };
28
+
29
+ // 登录账号(用于用户管理模块)
30
+ var isAccount = function isAccount(value) {
31
+ // 长度1-20个字符,只能以英文或@开头。英文、数字不限制,字符仅使用_ . @ - 这几个
32
+ var reg = /^[a-zA-Z0-9_@.-]{1}([a-zA-Z0-9]|[_@.-]){0,19}$/;
33
+
34
+ // 可以包含数字、字母、下划线,并且要同时含有数字和字母,且长度要在8-16位之间。
35
+ // const reg = /^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z_]{8,16}$**/
36
+ return reg.test(value);
37
+ };
38
+
39
+ // 判断是否为英文字符(用于用户管理模块)
40
+ var isUserAccount = function isUserAccount(value) {
41
+ var reg = /([a-zA-Z0-9]|[_@.-])+$/;
42
+ return reg.test(value);
43
+ };
44
+ var isCardNo = function isCardNo(num) {
45
+ num = num.toUpperCase();
46
+ // 身份证号码为15位或者18位,15位时全为数字,18位前17位为数字,最后一位是校验位,可能为数字或字符X。
47
+ if (!/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(num)) {
48
+ return false;
49
+ }
50
+ return true;
51
+ // 校验位按照ISO 7064:1983.MOD 11-2的规定生成,X可以认为是数字10。
52
+ // 下面分别分析出生日期和校验位
53
+ var len, re;
54
+ var arrSplit;
55
+ len = num.length;
56
+ if (len == 15) {
57
+ re = new RegExp(/^(\d{6})(\d{2})(\d{2})(\d{2})(\d{3})$/);
58
+ arrSplit = num.match(re);
59
+
60
+ // 检查生日日期是否正确 
61
+ var dtmBirth = new Date('19' + arrSplit[2] + '/' + arrSplit[3] + '/' + arrSplit[4]);
62
+ var bCorrectDay;
63
+ bCorrectDay = dtmBirth.getYear() == Number(arrSplit[2]) && dtmBirth.getMonth() + 1 == Number(arrSplit[3]) && dtmBirth.getDate() == Number(arrSplit[4]);
64
+ if (!bCorrectDay) {
65
+ return false;
66
+ } else {
67
+ // 将15位身份证转成18位 
68
+ // 校验位按照ISO 7064:1983.MOD 11-2的规定生成,X可以认为是数字10。 
69
+ var arrInt = new Array(7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2);
70
+ var arrCh = new Array('1', '0', 'X', '9', '8', '7', '6', '5', '4', '3', '2');
71
+ var nTemp = 0,
72
+ i;
73
+ num = num.substr(0, 6) + '19' + num.substr(6, num.length - 6);
74
+ for (i = 0; i < 17; i++) {
75
+ nTemp += num.substr(i, 1) * arrInt[i];
76
+ }
77
+ num += arrCh[nTemp % 11];
78
+ return true;
79
+ }
80
+ }
81
+ if (len == 18) {
82
+ re = new RegExp(/^(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X)$/);
83
+ arrSplit = num.match(re);
84
+
85
+ //检查生日日期是否正确 
86
+ var dtmBirth = new Date(arrSplit[2] + '/' + arrSplit[3] + '/' + arrSplit[4]);
87
+ var bCorrectDay;
88
+ bCorrectDay = dtmBirth.getFullYear() == Number(arrSplit[2]) && dtmBirth.getMonth() + 1 == Number(arrSplit[3]) && dtmBirth.getDate() == Number(arrSplit[4]);
89
+ if (!bCorrectDay) {
90
+ return false;
91
+ } else {
92
+ //检验18位身份证的校验码是否正确。 
93
+ //校验位按照ISO 7064:1983.MOD 11-2的规定生成,X可以认为是数字10。 
94
+ var valnum;
95
+ var arrInt = new Array(7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2);
96
+ var arrCh = new Array('1', '0', 'X', '9', '8', '7', '6', '5', '4', '3', '2');
97
+ var nTemp = 0,
98
+ i;
99
+ for (i = 0; i < 17; i++) {
100
+ nTemp += num.substr(i, 1) * arrInt[i];
101
+ }
102
+ valnum = arrCh[nTemp % 11];
103
+ if (valnum != num.substr(17, 1)) {
104
+ return false;
105
+ }
106
+ return true;
107
+ }
108
+ }
109
+ return false;
110
+ };
111
+ export { isCardNo, isIdCard, isEmail, isPhone, isSendNumber, isAccount, isUserAccount };
@@ -35,6 +35,8 @@ interface ButtonGroupProps {
35
35
  dropdownConfig?: Object;
36
36
  moreText?: string;
37
37
  moreIcon?: React.ReactNode | string | number;
38
+ size?: any;
39
+ showTextIcon?: boolean;
38
40
  }
39
41
  declare const ButtonGroup: (props: ButtonGroupProps) => any;
40
42
  export default ButtonGroup;
@@ -14,7 +14,7 @@ var _filterPermission = require("../utils/filterPermission");
14
14
  var _styles = _interopRequireDefault(require("./styles"));
15
15
  var _classnames = _interopRequireDefault(require("classnames"));
16
16
  var _ConfigContext = require("../ConfigContext");
17
- var _excluded = ["code", "fn", "exName", "name", "children", "icon"],
17
+ var _excluded = ["code", "fn", "exName", "name", "children", "icon", "confirmText", "confirmConfig", "render"],
18
18
  _excluded2 = ["exName", "name", "type", "icon", "ghost", "danger", "disabled", "loading", "fn", "code", "rowParams", "isHide"],
19
19
  _excluded3 = ["code", "fn", "exName", "name", "children", "icon", "confirmText", "confirmConfig"];
20
20
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -59,7 +59,11 @@ var ButtonGroup = function ButtonGroup(props) {
59
59
  dropdownConfig = _providerConfig$props4 === void 0 ? {} : _providerConfig$props4,
60
60
  _providerConfig$props5 = _providerConfig$props.moreText,
61
61
  moreText = _providerConfig$props5 === void 0 ? '更多' : _providerConfig$props5,
62
- moreIcon = _providerConfig$props.moreIcon;
62
+ _providerConfig$props6 = _providerConfig$props.size,
63
+ size = _providerConfig$props6 === void 0 ? 'default' : _providerConfig$props6,
64
+ moreIcon = _providerConfig$props.moreIcon,
65
+ _providerConfig$props7 = _providerConfig$props.showTextIcon,
66
+ showTextIcon = _providerConfig$props7 === void 0 ? false : _providerConfig$props7;
63
67
  var _props$options = props.options,
64
68
  options = _props$options === void 0 ? [] : _props$options,
65
69
  _props$min = props.min,
@@ -95,6 +99,9 @@ var ButtonGroup = function ButtonGroup(props) {
95
99
  name = vItem.name,
96
100
  children = vItem.children,
97
101
  icon = vItem.icon,
102
+ confirmText = vItem.confirmText,
103
+ confirmConfig = vItem.confirmConfig,
104
+ render = vItem.render,
98
105
  others = _objectWithoutProperties(vItem, _excluded);
99
106
  return _objectSpread(_objectSpread({}, others), {}, {
100
107
  key: code ? code + i : i,
@@ -164,7 +171,9 @@ var ButtonGroup = function ButtonGroup(props) {
164
171
  },
165
172
  placement: "bottomRight"
166
173
  }, (item === null || item === void 0 ? void 0 : item.dropdownConfig) || dropdownConfig || {}), /*#__PURE__*/_react.default.createElement(_antd.Button, {
167
- type: "primary"
174
+ type: "primary",
175
+ size: size
176
+ // icon={item?.icon ? <IconNode icon={item?.icon}/> : null}
168
177
  }, item.exName || item.name, " ", /*#__PURE__*/_react.default.createElement(_SpecIcon.default, {
169
178
  name: "down"
170
179
  })));
@@ -176,7 +185,8 @@ var ButtonGroup = function ButtonGroup(props) {
176
185
  loading: loading,
177
186
  onClick: fn ? function () {
178
187
  return fn(item);
179
- } : null
188
+ } : null,
189
+ size: size
180
190
  }, others, {
181
191
  icon: icon ? /*#__PURE__*/_react.default.createElement(_components.IconNode, {
182
192
  icon: icon
@@ -269,10 +279,12 @@ var ButtonGroup = function ButtonGroup(props) {
269
279
  }));
270
280
  };
271
281
  // 自定义渲染显示的文本
272
- var renderCustomLabel = function renderCustomLabel(gItem) {
282
+ var renderCustomLabel = function renderCustomLabel(gItem, hideIcon) {
273
283
  return gItem.render ? gItem.render.apply(gItem, _toConsumableArray(Object.keys(rowParams).map(function (pItem) {
274
284
  return rowParams[pItem];
275
- }))) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, gItem.icon ? ' ' : '', gItem.exName || gItem.name);
285
+ }))) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, !hideIcon && gItem.icon && showTextIcon ? /*#__PURE__*/_react.default.createElement(_components.IconNode, {
286
+ icon: gItem.icon
287
+ }) : '', " ", gItem.exName || gItem.name);
276
288
  };
277
289
  // 递归转换原来的数组结构
278
290
  var deepTransTextMenus = function deepTransTextMenus(groupArray) {
@@ -293,7 +305,13 @@ var ButtonGroup = function ButtonGroup(props) {
293
305
  danger: others.danger,
294
306
  disabled: (0, _filterPermission.btnIsDisabled)(others.disabled, rowParams),
295
307
  key: code ? code + i : i,
296
- // icon: <IconNode icon={icon}/>, // 不显示图标
308
+ icon: icon && showTextIcon ? /*#__PURE__*/_react.default.createElement(_components.IconNode, {
309
+ icon: icon,
310
+ style: {
311
+ marginRight: '4px'
312
+ }
313
+ }) : null,
314
+ // 不显示图标
297
315
  label: /*#__PURE__*/_react.default.createElement("a", {
298
316
  onClick: function onClick() {
299
317
  // 配置二次确认
@@ -306,7 +324,7 @@ var ButtonGroup = function ButtonGroup(props) {
306
324
  })));
307
325
  }
308
326
  }
309
- }, renderCustomLabel(vItem)),
327
+ }, renderCustomLabel(vItem, true)),
310
328
  title: vItem.exName || vItem.name,
311
329
  children: children && children.length > 0 ? deepTransTextMenus(children) : undefined
312
330
  };
@@ -323,9 +341,7 @@ var ButtonGroup = function ButtonGroup(props) {
323
341
  placement: "bottomRight"
324
342
  }, (item === null || item === void 0 ? void 0 : item.dropdownConfig) || dropdownConfig || {}), /*#__PURE__*/_react.default.createElement("a", {
325
343
  className: 'spec-button-group-text'
326
- }, item.render ? item.render.apply(item, _toConsumableArray(Object.keys(rowParams).map(function (pItem) {
327
- return rowParams[pItem];
328
- }))) : item.exName || item.name, " ", /*#__PURE__*/_react.default.createElement(_SpecIcon.default, {
344
+ }, renderCustomLabel(item, true), " ", /*#__PURE__*/_react.default.createElement(_SpecIcon.default, {
329
345
  name: "down"
330
346
  })));
331
347
  }
@@ -364,9 +380,7 @@ var ButtonGroup = function ButtonGroup(props) {
364
380
  // @ts-ignore
365
381
  ,
366
382
  disabled: (0, _filterPermission.btnIsDisabled)(item.disabled, rowParams)
367
- }, item.render ? item.render.apply(item, _toConsumableArray(Object.keys(rowParams).map(function (pItem) {
368
- return rowParams[pItem];
369
- }))) : item.exName || item.name)) : /*#__PURE__*/_react.default.createElement("a", {
383
+ }, renderCustomLabel(item))) : /*#__PURE__*/_react.default.createElement("a", {
370
384
  className: 'spec-button-group-text',
371
385
  title: item.exName || item.name,
372
386
  key: item.index
@@ -378,9 +392,7 @@ var ButtonGroup = function ButtonGroup(props) {
378
392
  return rowParams[pItem];
379
393
  })));
380
394
  } : undefined
381
- }, item.render ? item.render.apply(item, _toConsumableArray(Object.keys(rowParams).map(function (pItem) {
382
- return rowParams[pItem];
383
- }))) : item.exName || item.name));
395
+ }, renderCustomLabel(item)));
384
396
  };
385
397
  var RenderCustomNode = function RenderCustomNode(item) {
386
398
  var render = item.render,
@@ -440,7 +452,8 @@ var ButtonGroup = function ButtonGroup(props) {
440
452
  },
441
453
  placement: "bottomRight"
442
454
  }, dropdownConfig), /*#__PURE__*/_react.default.createElement(_antd.Button, {
443
- type: "primary"
455
+ type: "primary",
456
+ size: size
444
457
  }, moreText || '更多', moreIcon || /*#__PURE__*/_react.default.createElement(_icons.DownOutlined, null))) : /*#__PURE__*/_react.default.createElement(_antd.Popconfirm, _extends({
445
458
  placement: "topRight",
446
459
  open: popVisibleIndex === rowParams.rowIndex,
@@ -55,13 +55,21 @@ var SpecButtonGroupStyleFunc = function SpecButtonGroupStyleFunc(prefix) {
55
55
  return [_defineProperty({}, prefixCls, _objectSpread({
56
56
  display: 'inline-block',
57
57
  verticalAlign: 'middle',
58
+ alignItems: 'center',
58
59
  '> *': {
59
60
  marginLeft: token.marginSM,
60
61
  '&:first-child': {
61
62
  marginLeft: 0
62
63
  }
63
64
  }
64
- }, SpecButtonGroupTextStyle(prefixCls, SpecButtonGroupToken)))];
65
+ }, SpecButtonGroupTextStyle(prefixCls, SpecButtonGroupToken))), {
66
+ '.ant-dropdown-menu-item': {
67
+ background: '#f00',
68
+ '.spec-icon + .ant-dropdown-menu-title-content': {
69
+ marginLeft: token.marginSM
70
+ }
71
+ }
72
+ }];
65
73
  }, prepareComponentToken // 当前组件扩展的变量
66
74
  );
67
75
  };
@@ -153,7 +153,7 @@ var DragContent = function DragContent(props) {
153
153
  };
154
154
  return wrapSSR( /*#__PURE__*/_react.default.createElement("div", {
155
155
  ref: divRef,
156
- className: (0, _classnames.default)(componentName, hashId, className),
156
+ className: (0, _classnames.default)(className, componentName, hashId),
157
157
  style: style
158
158
  }, children, direction && direction.map(function (item, idx) {
159
159
  return /*#__PURE__*/_react.default.createElement(_DragBar.default, {
@@ -8,16 +8,15 @@
8
8
 
9
9
  .spec-grid-dragbar-left-horizontal{
10
10
  height: 100%;
11
- width: 5px;
11
+ width: 10px;
12
12
  position: absolute;
13
13
  left: 0;
14
14
  top: 0;
15
15
  cursor: col-resize;
16
-
17
16
  }
18
17
  .spec-grid-dragbar-right-horizontal{
19
18
  height: 100%;
20
- width: 5px;
19
+ width: 10px;
21
20
  position: absolute;
22
21
  right: 0;
23
22
  top: 0;
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ export interface ContentHeaderProps {
3
+ title?: string | React.ReactNode;
4
+ breadcrumb?: object;
5
+ componentName?: string;
6
+ [key: string]: any;
7
+ }
8
+ declare const ContentHeader: React.ForwardRefExoticComponent<Omit<ContentHeaderProps, "ref"> & React.RefAttributes<unknown>>;
9
+ export default ContentHeader;