@zohodesk/components 1.0.0-temp-193 → 1.0.0-temp-194

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 (79) hide show
  1. package/.cli/propValidation_report.html +1 -1
  2. package/es/AppContainer/AppContainer.js +10 -9
  3. package/es/Avatar/Avatar.js +4 -5
  4. package/es/AvatarTeam/AvatarTeam.js +7 -7
  5. package/es/Button/Button.js +5 -6
  6. package/es/CheckBox/CheckBox.js +8 -8
  7. package/es/DateTime/DateTime.js +2 -8
  8. package/es/DateTime/DateWidget.js +3 -14
  9. package/es/DateTime/Time.js +13 -30
  10. package/es/DateTime/props/defaultProps.js +2 -4
  11. package/es/DateTime/props/propTypes.js +3 -6
  12. package/es/DropBox/DropBox.js +10 -11
  13. package/es/DropDown/DropDown.js +2 -1
  14. package/es/ListItem/ListContainer.js +6 -5
  15. package/es/ListItem/ListItem.js +4 -5
  16. package/es/ListItem/ListItemWithAvatar.js +4 -5
  17. package/es/ListItem/ListItemWithCheckBox.js +4 -5
  18. package/es/ListItem/ListItemWithIcon.js +4 -5
  19. package/es/ListItem/ListItemWithRadio.js +4 -5
  20. package/es/Modal/Modal.js +4 -5
  21. package/es/MultiSelect/AdvancedMultiSelect.js +8 -9
  22. package/es/MultiSelect/MultiSelectWithAvatar.js +4 -5
  23. package/es/MultiSelect/SelectedOptions.js +6 -8
  24. package/es/MultiSelect/Suggestions.js +6 -8
  25. package/es/Popup/Popup.js +3 -4
  26. package/es/Radio/Radio.js +8 -8
  27. package/es/ResponsiveDropBox/ResponsiveDropBox.js +2 -4
  28. package/es/Select/Select.js +4 -5
  29. package/es/Switch/Switch.js +8 -8
  30. package/es/Tab/Tab.js +4 -5
  31. package/es/Tab/TabContentWrapper.js +4 -5
  32. package/es/Tab/TabWrapper.js +5 -6
  33. package/es/Tab/Tabs.js +16 -16
  34. package/es/Tab/props/propTypes.js +1 -0
  35. package/es/TextBox/TextBox.js +5 -5
  36. package/es/TextBoxIcon/TextBoxIcon.js +2 -4
  37. package/es/Textarea/Textarea.js +4 -6
  38. package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +4 -5
  39. package/es/deprecated/PortalLayer/PortalLayer.js +8 -6
  40. package/es/v1/AppContainer/AppContainer.js +10 -9
  41. package/es/v1/Avatar/Avatar.js +4 -5
  42. package/es/v1/AvatarTeam/AvatarTeam.js +7 -7
  43. package/es/v1/Button/Button.js +5 -6
  44. package/es/v1/CheckBox/CheckBox.js +8 -8
  45. package/es/v1/DropBox/DropBox.js +10 -11
  46. package/es/v1/DropDown/DropDown.js +2 -1
  47. package/es/v1/ListItem/ListContainer.js +6 -5
  48. package/es/v1/ListItem/ListItem.js +4 -5
  49. package/es/v1/ListItem/ListItemWithAvatar.js +4 -5
  50. package/es/v1/ListItem/ListItemWithCheckBox.js +4 -5
  51. package/es/v1/ListItem/ListItemWithIcon.js +4 -5
  52. package/es/v1/ListItem/ListItemWithRadio.js +4 -5
  53. package/es/v1/Modal/Modal.js +4 -5
  54. package/es/v1/MultiSelect/AdvancedMultiSelect.js +8 -9
  55. package/es/v1/MultiSelect/MultiSelectWithAvatar.js +4 -5
  56. package/es/v1/MultiSelect/SelectedOptions.js +6 -8
  57. package/es/v1/MultiSelect/Suggestions.js +6 -8
  58. package/es/v1/Popup/Popup.js +3 -4
  59. package/es/v1/Radio/Radio.js +8 -8
  60. package/es/v1/ResponsiveDropBox/ResponsiveDropBox.js +2 -4
  61. package/es/v1/Select/Select.js +4 -5
  62. package/es/v1/Switch/Switch.js +8 -8
  63. package/es/v1/Tab/Tab.js +4 -5
  64. package/es/v1/Tab/TabContentWrapper.js +4 -5
  65. package/es/v1/Tab/TabWrapper.js +2 -4
  66. package/es/v1/Tab/Tabs.js +16 -16
  67. package/es/v1/TextBox/TextBox.js +5 -5
  68. package/es/v1/TextBoxIcon/TextBoxIcon.js +2 -4
  69. package/es/v1/Textarea/Textarea.js +4 -6
  70. package/es/v1/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +4 -5
  71. package/lib/DateTime/DateTime.js +2 -13
  72. package/lib/DateTime/DateWidget.js +3 -19
  73. package/lib/DateTime/Time.js +13 -35
  74. package/lib/DateTime/props/defaultProps.js +2 -4
  75. package/lib/DateTime/props/propTypes.js +3 -6
  76. package/lib/Tab/TabWrapper.js +3 -2
  77. package/lib/Tab/props/propTypes.js +1 -0
  78. package/package.json +1 -1
  79. package/result.json +1 -1
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { defaultProps } from './props/defaultProps';
5
3
  import { propTypes } from './props/propTypes';
@@ -108,23 +106,26 @@ export default class AppContainer extends React.Component {
108
106
  TooltipProps = {},
109
107
  ExtraProps = {}
110
108
  } = customProps;
111
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Container, _extends({
109
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Container, {
112
110
  className: `${style.container} ${className}`,
113
111
  dataId: dataId,
114
112
  dataSelectorId: dataSelectorId,
115
113
  tagName: tagName,
116
- eleRef: this.getContainerRef
117
- }, ContainerProps, ExtraProps), /*#__PURE__*/React.createElement(Box, {
114
+ eleRef: this.getContainerRef,
115
+ ...ContainerProps,
116
+ ...ExtraProps
117
+ }, /*#__PURE__*/React.createElement(Box, {
118
118
  flexible: true
119
- }, children)), needTooltip ? /*#__PURE__*/React.createElement("div", _extends({}, ExtraProps, {
119
+ }, children)), needTooltip ? /*#__PURE__*/React.createElement("div", { ...ExtraProps,
120
120
  className: `${style.container} ${style.tooltip} ${tooltipParentClass}`,
121
121
  "data-id": `${dataId}_tooltip`,
122
122
  "data-test-id": `${dataId}_tooltip`,
123
123
  "data-selector-id": `${dataSelectorId}_tooltip`
124
- }), /*#__PURE__*/React.createElement(Tooltip, _extends({
124
+ }, /*#__PURE__*/React.createElement(Tooltip, {
125
125
  ref: this.setTooltipRef,
126
- customClass: tooltipClass
127
- }, TooltipProps))) : null);
126
+ customClass: tooltipClass,
127
+ ...TooltipProps
128
+ })) : null);
128
129
  }
129
130
 
130
131
  }
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { defaultProps } from './props/defaultProps';
5
3
  import { propTypes } from './props/propTypes';
@@ -156,15 +154,16 @@ export default class Avatar extends React.Component {
156
154
  let showDefaultBorder = src && !isInvalidImageList && needDefaultBorder;
157
155
  let borderStyle = (showDefaultBorder || !src || !showAvatar || showInitial) && needBorder ? `${style.border} ${borderOnActive ? style.borderOnActive : border ? style.borderOnHover : ''} ` : '';
158
156
  borderStyle = showAlternateAvatar ? '' : borderStyle;
159
- return /*#__PURE__*/React.createElement("div", _extends({
157
+ return /*#__PURE__*/React.createElement("div", {
160
158
  className: `${style.avatar} ${style[size]} ${AvatarSize(size)} ${style[shapeStyle]} ${style[palette]} ${textStyle} ${borderStyle} ${customClass ? customClass : ''}`,
161
159
  "data-title": needTitle ? title ? title : name : null,
162
160
  "data-id": dataId,
163
161
  "data-test-id": dataId,
164
162
  onClick: onClick,
165
163
  "data-selector-id": dataSelectorId,
166
- tabIndex: onClick ? 0 : null
167
- }, AvatarProps), showInitial && !showAlternateAvatar && /*#__PURE__*/React.createElement("span", {
164
+ tabIndex: onClick ? 0 : null,
165
+ ...AvatarProps
166
+ }, showInitial && !showAlternateAvatar && /*#__PURE__*/React.createElement("span", {
168
167
  className: `${style.initial}`,
169
168
  "data-id": `${dataId}_AvatarInitial`,
170
169
  "data-test-id": `${dataId}_AvatarInitial`,
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { defaultProps } from './props/defaultProps';
5
3
  import { propTypes } from './props/propTypes';
@@ -47,12 +45,13 @@ export default class AvatarTeam extends React.Component {
47
45
  customAvatarTeam = ''
48
46
  } = customClass;
49
47
  let border = borderOnHover || onClick;
50
- return /*#__PURE__*/React.createElement("span", _extends({
48
+ return /*#__PURE__*/React.createElement("span", {
51
49
  className: `${style.container} ${borderOnActive ? style.borderOnActive : border ? style.borderOnHover : ''} `,
52
50
  "data-id": dataId,
53
51
  "data-test-id": dataId,
54
- "data-selector-id": dataSelectorId
55
- }, AvatarTeamProps), /*#__PURE__*/React.createElement(Avatar, _extends({
52
+ "data-selector-id": dataSelectorId,
53
+ ...AvatarTeamProps
54
+ }, /*#__PURE__*/React.createElement(Avatar, {
56
55
  name: name,
57
56
  onClick: onClick,
58
57
  palette: palette,
@@ -66,8 +65,9 @@ export default class AvatarTeam extends React.Component {
66
65
  borderOnHover: border,
67
66
  needInnerBorder: needInnerBorder,
68
67
  needBorder: needBorder,
69
- needDefaultBorder: needDefaultBorder
70
- }, AvatarProps)), /*#__PURE__*/React.createElement("span", {
68
+ needDefaultBorder: needDefaultBorder,
69
+ ...AvatarProps
70
+ }), /*#__PURE__*/React.createElement("span", {
71
71
  className: `${style.team} ${isFilled ? `${style[`${palette}Filled`]}` : style.nofill}
72
72
  ${style[`${size}team`]} ${customAvatarTeam}`
73
73
  }));
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { defaultProps } from './props/defaultProps';
5
3
  import { propTypes } from './props/propTypes';
@@ -41,7 +39,7 @@ export default function Button(props) {
41
39
  style: finalStyle
42
40
  });
43
41
  let statusLower = status.toLowerCase();
44
- return /*#__PURE__*/React.createElement("button", _extends({
42
+ return /*#__PURE__*/React.createElement("button", {
45
43
  className: buttonClass,
46
44
  "data-id": disabled ? `${dataId}_disabled` : dataId,
47
45
  "data-test-id": disabled ? `${dataId}_disabled` : dataId,
@@ -50,10 +48,11 @@ export default function Button(props) {
50
48
  "data-title": title,
51
49
  type: "button",
52
50
  ref: getRef,
53
- "data-selector-id": dataSelectorId
54
- }, customProps, a11y, {
51
+ "data-selector-id": dataSelectorId,
52
+ ...customProps,
53
+ ...a11y,
55
54
  id: id
56
- }), children ? children : text, statusLower !== 'none' && needAppearance && /*#__PURE__*/React.createElement("div", {
55
+ }, children ? children : text, statusLower !== 'none' && needAppearance && /*#__PURE__*/React.createElement("div", {
57
56
  className: finalStyle.overlay
58
57
  }, /*#__PURE__*/React.createElement("div", {
59
58
  className: loaderParentClass
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { propTypes } from './props/propTypes';
5
3
  import { defaultProps } from './props/defaultProps';
@@ -75,7 +73,7 @@ export default class CheckBox extends React.Component {
75
73
  role = 'checkbox',
76
74
  ariaChecked = checked
77
75
  } = a11y;
78
- return /*#__PURE__*/React.createElement(Container, _extends({
76
+ return /*#__PURE__*/React.createElement(Container, {
79
77
  dataId: dataId,
80
78
  isCover: false,
81
79
  isInline: text ? false : true,
@@ -92,8 +90,9 @@ export default class CheckBox extends React.Component {
92
90
  "aria-label": ariaLabel,
93
91
  "aria-labelledby": ariaLabelledby,
94
92
  "aria-hidden": ariaHidden,
95
- "data-selector-id": dataSelectorId || id
96
- }, CheckBoxProps), /*#__PURE__*/React.createElement(Box, {
93
+ "data-selector-id": dataSelectorId || id,
94
+ ...CheckBoxProps
95
+ }, /*#__PURE__*/React.createElement(Box, {
97
96
  className: `${style.boxContainer} ${style[size]} ${customCBoxSize} ${isFilled ? style.filled : ''}`
98
97
  }, /*#__PURE__*/React.createElement("input", {
99
98
  type: "hidden",
@@ -145,7 +144,7 @@ export default class CheckBox extends React.Component {
145
144
  }) : null))), text && /*#__PURE__*/React.createElement(Box, {
146
145
  flexible: true,
147
146
  className: style.text
148
- }, /*#__PURE__*/React.createElement(Label, _extends({
147
+ }, /*#__PURE__*/React.createElement(Label, {
149
148
  text: text,
150
149
  palette: disabled ? 'disable' : labelPalette,
151
150
  id: id,
@@ -156,8 +155,9 @@ export default class CheckBox extends React.Component {
156
155
  customClass: `${active && !disabled ? `${style[`active${palette}Label`]}` : ''}
157
156
  ${checked && active ? `${style[`checked${palette}Label`]}` : ''}
158
157
  ${accessMode} ${customLabel}`,
159
- title: toolTip ? toolTip : text
160
- }, LabelProps))));
158
+ title: toolTip ? toolTip : text,
159
+ ...LabelProps
160
+ })));
161
161
  }
162
162
 
163
163
  }
@@ -649,12 +649,8 @@ export default class DateTime extends React.PureComponent {
649
649
  positionsOffset,
650
650
  targetOffset,
651
651
  isRestrictScroll,
652
- dropBoxPortalId,
653
- customProps = {}
652
+ dropBoxPortalId
654
653
  } = this.props;
655
- const {
656
- TimeProps = {}
657
- } = customProps;
658
654
  const {
659
655
  timeText = 'Time',
660
656
  submitText = 'Set',
@@ -710,9 +706,7 @@ export default class DateTime extends React.PureComponent {
710
706
  ampmSuggestions: this.ampmSuggestions,
711
707
  onAmPmSelect: this.amPmSelect,
712
708
  amPm: amPm,
713
- is24Hour: is24Hour,
714
- customProps: { ...TimeProps
715
- }
709
+ is24Hour: is24Hour
716
710
  }) : null, needAction ? /*#__PURE__*/React.createElement(DateTimePopupFooter, {
717
711
  submitText: submitText,
718
712
  onSubmit: this.handleSelect,
@@ -988,13 +988,8 @@ class DateWidgetComponent extends React.Component {
988
988
  dropBoxPortalId,
989
989
  a11y,
990
990
  boxSize,
991
- onError,
992
- customProps = {}
991
+ onError
993
992
  } = this.props;
994
- const {
995
- DateTimeProps = {},
996
- TextBoxProps = {}
997
- } = customProps;
998
993
  const {
999
994
  selected: value = '',
1000
995
  isError,
@@ -1046,11 +1041,7 @@ class DateWidgetComponent extends React.Component {
1046
1041
  iconOnHover: iconOnHover,
1047
1042
  isFocus: isPopupReady,
1048
1043
  autoComplete: false,
1049
- a11y: a11y,
1050
- customProps: {
1051
- TextBoxProps: { ...TextBoxProps
1052
- }
1053
- }
1044
+ a11y: a11y
1054
1045
  }, /*#__PURE__*/React.createElement(Container, {
1055
1046
  align: "both",
1056
1047
  onClick: isDisabled || isReadOnly ? null : this.handleDateIconClick
@@ -1087,9 +1078,7 @@ class DateWidgetComponent extends React.Component {
1087
1078
  isRestrictScroll: isRestrictScroll,
1088
1079
  dropBoxPortalId: dropBoxPortalId,
1089
1080
  boxSize: boxSize,
1090
- onError: onError,
1091
- customProps: { ...DateTimeProps
1092
- }
1081
+ onError: onError
1093
1082
  }));
1094
1083
  }
1095
1084
 
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /* eslint-disable react/forbid-component-props */
4
2
 
5
3
  /** ** Libraries *** */
@@ -30,14 +28,8 @@ export default class Time extends PureComponent {
30
28
  ampmSuggestions,
31
29
  onAmPmSelect,
32
30
  amPm,
33
- is24Hour,
34
- customProps = {}
31
+ is24Hour
35
32
  } = this.props;
36
- const {
37
- HourCompProps = {},
38
- MinuteCompProps = {},
39
- AmPmCompProps = {}
40
- } = customProps;
41
33
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("span", {
42
34
  className: style.text
43
35
  }, timeText), /*#__PURE__*/React.createElement(Container, {
@@ -54,9 +46,7 @@ export default class Time extends PureComponent {
54
46
  onHourSelect: onHourSelect,
55
47
  hours: hours,
56
48
  needResponsive: needResponsive,
57
- hourEmptyText: hourEmptyText,
58
- customProps: { ...HourCompProps
59
- }
49
+ hourEmptyText: hourEmptyText
60
50
  })), /*#__PURE__*/React.createElement(Box, {
61
51
  flexible: true,
62
52
  className: style.dropDownContainer
@@ -65,9 +55,7 @@ export default class Time extends PureComponent {
65
55
  onMinutesSelect: onMinutesSelect,
66
56
  mins: mins,
67
57
  minuteEmptyText: minuteEmptyText,
68
- needResponsive: needResponsive,
69
- customProps: { ...MinuteCompProps
70
- }
58
+ needResponsive: needResponsive
71
59
  })), !is24Hour ? /*#__PURE__*/React.createElement(Box, {
72
60
  flexible: true,
73
61
  className: style.dropDownContainer
@@ -75,9 +63,7 @@ export default class Time extends PureComponent {
75
63
  ampmSuggestions: ampmSuggestions,
76
64
  onAmPmSelect: onAmPmSelect,
77
65
  amPm: amPm,
78
- needResponsive: needResponsive,
79
- customProps: { ...AmPmCompProps
80
- }
66
+ needResponsive: needResponsive
81
67
  })) : null));
82
68
  }
83
69
 
@@ -92,10 +78,9 @@ class Hour extends React.PureComponent {
92
78
  onHourSelect,
93
79
  hours,
94
80
  needResponsive,
95
- hourEmptyText,
96
- customProps
81
+ hourEmptyText
97
82
  } = this.props;
98
- return /*#__PURE__*/React.createElement(Select, _extends({
83
+ return /*#__PURE__*/React.createElement(Select, {
99
84
  options: hourSuggestions,
100
85
  onChange: onHourSelect,
101
86
  selectedValue: hours,
@@ -114,7 +99,7 @@ class Hour extends React.PureComponent {
114
99
  needListBorder: true,
115
100
  needTick: false,
116
101
  listItemSize: "small"
117
- }, customProps));
102
+ });
118
103
  }
119
104
 
120
105
  }
@@ -126,10 +111,9 @@ class Minute extends React.PureComponent {
126
111
  onMinutesSelect,
127
112
  mins,
128
113
  minuteEmptyText,
129
- needResponsive,
130
- customProps
114
+ needResponsive
131
115
  } = this.props;
132
- return /*#__PURE__*/React.createElement(Select, _extends({
116
+ return /*#__PURE__*/React.createElement(Select, {
133
117
  options: minSuggestions,
134
118
  onChange: onMinutesSelect,
135
119
  selectedValue: mins,
@@ -148,7 +132,7 @@ class Minute extends React.PureComponent {
148
132
  needListBorder: true,
149
133
  needTick: false,
150
134
  listItemSize: "small"
151
- }, customProps));
135
+ });
152
136
  }
153
137
 
154
138
  }
@@ -159,10 +143,9 @@ class AmPm extends React.PureComponent {
159
143
  ampmSuggestions,
160
144
  onAmPmSelect,
161
145
  amPm,
162
- needResponsive,
163
- customProps
146
+ needResponsive
164
147
  } = this.props;
165
- return /*#__PURE__*/React.createElement(Select, _extends({
148
+ return /*#__PURE__*/React.createElement(Select, {
166
149
  options: ampmSuggestions,
167
150
  onChange: onAmPmSelect,
168
151
  selectedValue: amPm,
@@ -177,7 +160,7 @@ class AmPm extends React.PureComponent {
177
160
  needListBorder: true,
178
161
  needTick: false,
179
162
  listItemSize: "small"
180
- }, customProps));
163
+ });
181
164
  }
182
165
 
183
166
  }
@@ -20,8 +20,7 @@ export const DateTime_defaultProps = {
20
20
  i18nKeys: {},
21
21
  is24Hour: false,
22
22
  isDefaultPosition: false,
23
- customDateFormat: null,
24
- customProps: {}
23
+ customDateFormat: null
25
24
  };
26
25
  export const DateWidget_defaultProps = {
27
26
  borderColor: 'default',
@@ -54,6 +53,5 @@ export const DateTimePopupFooter_defaultProps = {
54
53
  dataId: 'DateTimePopupFooter'
55
54
  };
56
55
  export const Time_defaultProps = {
57
- dataId: 'Time',
58
- customProps: {}
56
+ dataId: 'Time'
59
57
  };
@@ -72,8 +72,7 @@ export const DateTime_propTypes = {
72
72
  positionsOffset: PropTypes.array,
73
73
  targetOffset: PropTypes.string,
74
74
  isRestrictScroll: PropTypes.bool,
75
- dropBoxPortalId: PropTypes.string,
76
- customProps: PropTypes.object
75
+ dropBoxPortalId: PropTypes.string
77
76
  };
78
77
  export const DateWidget_propTypes = {
79
78
  borderColor: PropTypes.oneOf(['transparent', 'default']),
@@ -140,8 +139,7 @@ export const DateWidget_propTypes = {
140
139
  targetOffset: PropTypes.array,
141
140
  isRestrictScroll: PropTypes.bool,
142
141
  dropBoxPortalId: PropTypes.string,
143
- a11y: PropTypes.object,
144
- customProps: PropTypes.object
142
+ a11y: PropTypes.object
145
143
  };
146
144
  export const YearView_propTypes = {
147
145
  onSelectMonth: PropTypes.func,
@@ -185,6 +183,5 @@ export const Time_propTypes = {
185
183
  ampmSuggestions: PropTypes.array,
186
184
  onAmPmSelect: PropTypes.func,
187
185
  amPm: PropTypes.string,
188
- is24Hour: PropTypes.bool,
189
- customProps: PropTypes.object
186
+ is24Hour: PropTypes.bool
190
187
  };
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React, { useRef, useContext } from 'react';
4
2
  import FocusScope from '@zohodesk/a11y/es/FocusScope/FocusScope';
5
3
  import Modal from '../Modal/Modal'; // import { getLibraryConfig } from '../Provider/Config';
@@ -42,27 +40,28 @@ export default function DropBox(props) {
42
40
  const {
43
41
  zIndexStyle
44
42
  } = cssJSLogic(props);
45
- const dropBoxEle = needFocusScope ? /*#__PURE__*/React.createElement(FocusScope, _extends({
43
+ const dropBoxEle = needFocusScope ? /*#__PURE__*/React.createElement(FocusScope, {
46
44
  onClose: onClose,
47
45
  elementRef: dropBoxRef,
48
46
  needAutoFocus: needAutoFocus,
49
47
  needRestoreFocus: needRestoreFocus,
50
48
  needListNavigation: needListNavigation,
51
49
  needFocusLoop: needFocusLoop,
52
- needEnterAction: needEnterAction
53
- }, focusScopeProps), /*#__PURE__*/React.createElement(DropBoxElement, _extends({
50
+ needEnterAction: needEnterAction,
51
+ ...focusScopeProps
52
+ }, /*#__PURE__*/React.createElement(DropBoxElement, {
54
53
  isModel: isModel,
55
- direction: direction
56
- }, props, {
54
+ direction: direction,
55
+ ...props,
57
56
  zIndexStyle: zIndexStyle,
58
57
  subContainerRef: dropBoxRef
59
- }))) : /*#__PURE__*/React.createElement(DropBoxElement, _extends({
58
+ })) : /*#__PURE__*/React.createElement(DropBoxElement, {
60
59
  isModel: isModel,
61
60
  subContainerRef: dropBoxRef,
62
- direction: direction
63
- }, props, {
61
+ direction: direction,
62
+ ...props,
64
63
  zIndexStyle: zIndexStyle
65
- }));
64
+ });
66
65
  return isModel && isActive ? /*#__PURE__*/React.createElement(Modal, {
67
66
  portalId: portalId
68
67
  }, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
@@ -10,7 +10,8 @@ export default class DropDown extends React.Component {
10
10
  let {
11
11
  children
12
12
  } = this.props;
13
- return /*#__PURE__*/React.createElement(PopOver, this.props, /*#__PURE__*/React.createElement(PopOverTarget, null, children[0]), /*#__PURE__*/React.createElement(PopOverContainer, null, children[1]));
13
+ return /*#__PURE__*/React.createElement(PopOver, { ...this.props
14
+ }, /*#__PURE__*/React.createElement(PopOverTarget, null, children[0]), /*#__PURE__*/React.createElement(PopOverContainer, null, children[1]));
14
15
  }
15
16
 
16
17
  }
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /**** Libraries ****/
4
2
  import React, { useCallback } from 'react';
5
3
  import { Container } from '../Layout';
@@ -73,7 +71,7 @@ const ListContainer = props => {
73
71
  options.tabindex = '0';
74
72
  }
75
73
 
76
- return /*#__PURE__*/React.createElement(Container, _extends({
74
+ return /*#__PURE__*/React.createElement(Container, {
77
75
  role: role,
78
76
  "data-a11y-inset-focus": insetFocus,
79
77
  "aria-selected": ariaSelected,
@@ -89,8 +87,11 @@ const ListContainer = props => {
89
87
  onMouseOver: onMouseOver,
90
88
  eleRef: eleRef,
91
89
  tagName: isLink ? 'a' : 'li',
92
- "data-title": isDisabled ? disableTitle : title
93
- }, options, customProps, a11yAttributes), children);
90
+ "data-title": isDisabled ? disableTitle : title,
91
+ ...options,
92
+ ...customProps,
93
+ ...a11yAttributes
94
+ }, children);
94
95
  };
95
96
 
96
97
  ListContainer.defaultProps = ListContainerDefaultProps;
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /**** Libraries ****/
4
2
  import React from 'react';
5
3
  import { Box } from '../Layout';
@@ -92,7 +90,7 @@ export default class ListItem extends React.Component {
92
90
  } = listA11y;
93
91
  let tickIconPalette = style[`${palette}Tick`] ? style[`${palette}Tick`] : '';
94
92
  let dataIdString = dataId ? dataId : value ? String(value).replace("'", '_') : 'listItem';
95
- return /*#__PURE__*/React.createElement(ListContainer, _extends({
93
+ return /*#__PURE__*/React.createElement(ListContainer, {
96
94
  a11y: listA11y,
97
95
  size: size,
98
96
  palette: palette,
@@ -113,8 +111,9 @@ export default class ListItem extends React.Component {
113
111
  onClick: this.handleClick,
114
112
  onMouseEnter: this.handleMouseEnter,
115
113
  eleRef: this.getRef,
116
- customProps: ListItemProps
117
- }, ContainerProps), value ? /*#__PURE__*/React.createElement(Box, {
114
+ customProps: ListItemProps,
115
+ ...ContainerProps
116
+ }, value ? /*#__PURE__*/React.createElement(Box, {
118
117
  shrink: true,
119
118
  adjust: true,
120
119
  className: needMultiLineText ? style.multiLineValue : style.value
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /**** Libraries ****/
4
2
  import React from 'react';
5
3
  import { Box } from '../Layout';
@@ -97,7 +95,7 @@ export default class ListItemWithAvatar extends React.PureComponent {
97
95
  } = listA11y;
98
96
  let isDarkPalette = palette === 'dark';
99
97
  let dataIdString = value ? value : dataId;
100
- return /*#__PURE__*/React.createElement(ListContainer, _extends({
98
+ return /*#__PURE__*/React.createElement(ListContainer, {
101
99
  a11y: listA11y,
102
100
  size: size,
103
101
  palette: palette,
@@ -115,8 +113,9 @@ export default class ListItemWithAvatar extends React.PureComponent {
115
113
  eleRef: this.getRef,
116
114
  disableTitle: disableTitle,
117
115
  title: null,
118
- customProps: ListItemProps
119
- }, ContainerProps), name || imgSrc ? /*#__PURE__*/React.createElement(Box, {
116
+ customProps: ListItemProps,
117
+ ...ContainerProps
118
+ }, name || imgSrc ? /*#__PURE__*/React.createElement(Box, {
120
119
  className: style.leftAvatar
121
120
  }, isTeam ? /*#__PURE__*/React.createElement(AvatarTeam, {
122
121
  name: name,
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import ListContainer from './ListContainer';
5
3
  import { ListItemWithCheckBoxDefaultProps } from './props/defaultProps';
@@ -76,7 +74,7 @@ export default class ListItemWithCheckBox extends React.Component {
76
74
  customCheckBox = '',
77
75
  customLabel = ''
78
76
  } = customClass;
79
- return /*#__PURE__*/React.createElement(ListContainer, _extends({
77
+ return /*#__PURE__*/React.createElement(ListContainer, {
80
78
  a11y: listA11y,
81
79
  size: size,
82
80
  palette: palette,
@@ -92,8 +90,9 @@ export default class ListItemWithCheckBox extends React.Component {
92
90
  eleRef: this.getRef,
93
91
  disableTitle: disableTitle,
94
92
  title: null,
95
- customProps: ListItemProps
96
- }, ContainerProps), /*#__PURE__*/React.createElement(Box, {
93
+ customProps: ListItemProps,
94
+ ...ContainerProps
95
+ }, /*#__PURE__*/React.createElement(Box, {
97
96
  className: style.iconBox
98
97
  }, /*#__PURE__*/React.createElement(CheckBox, {
99
98
  checked: checked,
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /**** Libraries ****/
4
2
  import React from 'react';
5
3
  import { Box } from '../Layout';
@@ -87,7 +85,7 @@ export default class ListItemWithIcon extends React.Component {
87
85
  ariaHidden
88
86
  } = listA11y;
89
87
  let dataIdString = dataId ? `${dataId.replace("'", '_')}` : value.toLowerCase().replace("'", '_');
90
- return /*#__PURE__*/React.createElement(ListContainer, _extends({
88
+ return /*#__PURE__*/React.createElement(ListContainer, {
91
89
  a11y: listA11y,
92
90
  size: size,
93
91
  palette: palette,
@@ -108,8 +106,9 @@ export default class ListItemWithIcon extends React.Component {
108
106
  eleRef: this.getRef,
109
107
  disableTitle: disableTitle,
110
108
  title: null,
111
- customProps: ListItemProps
112
- }, ContainerProps), iconName && /*#__PURE__*/React.createElement(Box, {
109
+ customProps: ListItemProps,
110
+ ...ContainerProps
111
+ }, iconName && /*#__PURE__*/React.createElement(Box, {
113
112
  "aria-hidden": true,
114
113
  className: style.iconBox,
115
114
  dataId: dataId ? `${dataId}_Icon` : `${value.toLowerCase().replace("'", '_')}_Icon`
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import Radio from '../Radio/Radio';
5
3
  import { Box } from '../Layout';
@@ -77,7 +75,7 @@ export default class ListItemWithRadio extends React.Component {
77
75
  customRadio = '',
78
76
  customRadioWrap = ''
79
77
  } = customClass;
80
- return /*#__PURE__*/React.createElement(ListContainer, _extends({
78
+ return /*#__PURE__*/React.createElement(ListContainer, {
81
79
  a11y: listA11y,
82
80
  size: size,
83
81
  palette: palette,
@@ -93,8 +91,9 @@ export default class ListItemWithRadio extends React.Component {
93
91
  eleRef: this.getRef,
94
92
  disableTitle: disableTitle,
95
93
  title: null,
96
- customProps: ListItemProps
97
- }, ContainerProps), /*#__PURE__*/React.createElement(Box, {
94
+ customProps: ListItemProps,
95
+ ...ContainerProps
96
+ }, /*#__PURE__*/React.createElement(Box, {
98
97
  className: style.iconBox
99
98
  }, /*#__PURE__*/React.createElement(Radio, {
100
99
  checked: checked,
package/es/Modal/Modal.js CHANGED
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /**** Libraries ****/
4
2
  import React from 'react';
5
3
  import ReactDOM from 'react-dom';
@@ -131,9 +129,10 @@ export default class Modal extends React.Component {
131
129
 
132
130
  if (isMounted) {
133
131
  if (Element) {
134
- return /*#__PURE__*/ReactDOM.createPortal( /*#__PURE__*/React.createElement(Element, _extends({
135
- ref: this.setRef
136
- }, elementProps)), this.portalDiv);
132
+ return /*#__PURE__*/ReactDOM.createPortal( /*#__PURE__*/React.createElement(Element, {
133
+ ref: this.setRef,
134
+ ...elementProps
135
+ }), this.portalDiv);
137
136
  }
138
137
 
139
138
  return null;