@zohodesk/components 1.0.0-temp-255 → 1.0.0-temp-252.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.
Files changed (52) hide show
  1. package/es/AppContainer/AppContainer.js +2 -0
  2. package/es/Avatar/Avatar.js +2 -1
  3. package/es/Button/css/cssJSLogic.js +5 -4
  4. package/es/DateTime/DateTime.js +6 -3
  5. package/es/DateTime/DateWidget.js +5 -2
  6. package/es/DateTime/YearView.js +6 -5
  7. package/es/DateTime/common.js +9 -2
  8. package/es/DateTime/dateFormatUtils/dateFormat.js +76 -55
  9. package/es/DateTime/dateFormatUtils/index.js +12 -7
  10. package/es/DateTime/dateFormatUtils/timeChange.js +4 -3
  11. package/es/DateTime/dateFormatUtils/yearChange.js +4 -3
  12. package/es/DropBox/DropBoxElement/css/cssJSLogic.js +6 -5
  13. package/es/Layout/utils.js +2 -1
  14. package/es/ListItem/ListContainer.js +5 -4
  15. package/es/Modal/Portal/Portal.js +5 -4
  16. package/es/MultiSelect/AdvancedGroupMultiSelect.js +103 -91
  17. package/es/MultiSelect/AdvancedMultiSelect.js +80 -74
  18. package/es/MultiSelect/MultiSelect.js +13 -4
  19. package/es/MultiSelect/Suggestions.js +17 -14
  20. package/es/Popup/Popup.js +4 -1
  21. package/es/Provider/IdProvider.js +5 -4
  22. package/es/Provider/LibraryContext.js +12 -11
  23. package/es/Provider/NumberGenerator/NumberGenerator.js +17 -15
  24. package/es/Provider/ZindexProvider.js +5 -4
  25. package/es/Responsive/CustomResponsive.js +11 -8
  26. package/es/Responsive/ResizeComponent.js +3 -1
  27. package/es/Responsive/Responsive.js +12 -9
  28. package/es/Responsive/sizeObservers.js +5 -1
  29. package/es/ResponsiveDropBox/ResponsiveDropBox.js +14 -10
  30. package/es/Select/GroupSelect.js +103 -98
  31. package/es/Select/Select.js +116 -108
  32. package/es/Select/SelectWithAvatar.js +95 -91
  33. package/es/Select/SelectWithIcon.js +109 -104
  34. package/es/Select/__tests__/Select.spec.js +9 -6
  35. package/es/Tab/Tab.js +30 -29
  36. package/es/Tab/TabContent.js +19 -16
  37. package/es/Tab/TabContentWrapper.js +22 -19
  38. package/es/Tab/TabWrapper.js +16 -15
  39. package/es/Tab/Tabs.js +87 -80
  40. package/es/Typography/css/cssJSLogic.js +5 -4
  41. package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +2 -1
  42. package/es/utils/Common.js +31 -10
  43. package/es/utils/datetime/common.js +6 -2
  44. package/es/utils/dropDownUtils.js +11 -7
  45. package/es/utils/getInitial.js +3 -1
  46. package/es/v1/Button/css/cssJSLogic.js +8 -4
  47. package/es/v1/Label/css/cssJSLogic.js +5 -4
  48. package/es/v1/Switch/css/cssJSLogic.js +5 -4
  49. package/es/v1/helpers/colorHelpers/colorHelper.js +39 -28
  50. package/lib/AppContainer/AppContainer.js +4 -0
  51. package/lib/Select/Select.js +3 -1
  52. package/package.json +2 -2
@@ -272,7 +272,9 @@ class AdvancedGroupMultiSelect extends React.Component {
272
272
  }) : this.togglePopup(e);
273
273
  }
274
274
 
275
- handleClickSelectedOption(id = '', e) {
275
+ handleClickSelectedOption() {
276
+ let id = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
277
+ let e = arguments.length > 1 ? arguments[1] : undefined;
276
278
  let {
277
279
  selectedOptionIds
278
280
  } = this.state;
@@ -544,7 +546,11 @@ class AdvancedGroupMultiSelect extends React.Component {
544
546
  });
545
547
  }
546
548
 
547
- handleFetchOptions(...args) {
549
+ handleFetchOptions() {
550
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
551
+ args[_key] = arguments[_key];
552
+ }
553
+
548
554
  let [APICall, searchStr] = args;
549
555
  let {
550
556
  isFetchingOptions
@@ -657,7 +663,9 @@ class AdvancedGroupMultiSelect extends React.Component {
657
663
  this.handleChange([]);
658
664
  }
659
665
 
660
- handleChange(selectedOptions = [], e) {
666
+ handleChange() {
667
+ let selectedOptions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
668
+ let e = arguments.length > 1 ? arguments[1] : undefined;
661
669
  let {
662
670
  onChange,
663
671
  needToCloseOnSelect,
@@ -829,9 +837,10 @@ class AdvancedGroupMultiSelect extends React.Component {
829
837
  }
830
838
  }
831
839
 
832
- responsiveFunc({
833
- mediaQueryOR
834
- }) {
840
+ responsiveFunc(_ref) {
841
+ let {
842
+ mediaQueryOR
843
+ } = _ref;
835
844
  return {
836
845
  tabletMode: mediaQueryOR([{
837
846
  maxWidth: 700
@@ -1002,94 +1011,97 @@ class AdvancedGroupMultiSelect extends React.Component {
1002
1011
  }))) : null))), !isReadOnly && !isDisabled && isPopupOpen ? /*#__PURE__*/React.createElement(ResponsiveReceiver, {
1003
1012
  query: this.responsiveFunc,
1004
1013
  responsiveId: "Helmet"
1005
- }, ({
1006
- tabletMode
1007
- }) => /*#__PURE__*/React.createElement(ResponsiveDropBox, {
1008
- animationStyle: animationStyle,
1009
- boxPosition: position || `${defaultDropBoxPosition}Center`,
1010
- getRef: getContainerRef,
1011
- isActive: isPopupReady,
1012
- isAnimate: true,
1013
- isArrow: false,
1014
- onClick: removeClose,
1015
- needResponsive: needResponsive,
1016
- isPadding: isPadding,
1017
- isBoxPaddingNeed: !needSelectAll,
1018
- isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
1019
- positionsOffset: positionsOffset,
1020
- targetOffset: targetOffset,
1021
- isRestrictScroll: isRestrictScroll,
1022
- htmlId: setAriaId,
1023
- a11y: {
1024
- role: 'listbox',
1025
- ariaMultiselectable: true
1026
- },
1027
- alignBox: "row",
1028
- dataId: `${dataId}_dropbox`
1029
- }, /*#__PURE__*/React.createElement(Box, {
1030
- flexible: true
1031
- }, /*#__PURE__*/React.createElement(Card, {
1032
- customClass: `${style.box} ${style[`${palette}Box`]}`,
1033
- onScroll: this.handleScroll
1034
- }, needSelectAll && !(limit >= 0) ? /*#__PURE__*/React.createElement(CardHeader, null, /*#__PURE__*/React.createElement(MultiSelectHeader, {
1035
- onSelect: this.handleSelectAll,
1036
- selectAllText: selectAllText,
1037
- suggestions: suggestionOptionIds,
1038
- dataId: dataId
1039
- })) : null, isDataLoaded ? /*#__PURE__*/React.createElement(CardContent, {
1040
- shrink: true,
1041
- customClass: !tabletMode && dropBoxSize ? style[dropBoxSize] : '',
1042
- eleRef: this.suggestionContainerRef
1043
- }, /*#__PURE__*/React.createElement(React.Fragment, {
1044
- key: 'SuggestonsParent'
1045
- }, suggestionGroups.length ? suggestionGroups.map(group => {
1014
+ }, _ref2 => {
1046
1015
  let {
1047
- options: suggestions = []
1048
- } = group;
1049
- let groupId = group.id;
1050
- let groupName = group.name;
1051
- let hoverId = suggestionOptionIds[hoverIndex];
1052
- return /*#__PURE__*/React.createElement(React.Fragment, {
1053
- key: groupId
1054
- }, groupName && /*#__PURE__*/React.createElement("div", {
1055
- className: style.groupTitle
1056
- }, /*#__PURE__*/React.createElement(DropDownHeading, {
1057
- text: groupName,
1058
- a11y: {
1059
- role: 'heading'
1060
- }
1061
- })), /*#__PURE__*/React.createElement(Suggestions, _extends({}, SuggestionsProps, {
1062
- suggestions: suggestions,
1063
- selectedOptions: selectedOptionIds,
1064
- getRef: this.suggestionItemRef,
1065
- hoverId: hoverId,
1066
- onClick: this.handleSelectOption,
1067
- onMouseEnter: this.handleMouseEnter,
1068
- needTick: true,
1069
- listItemSize: listItemSize,
1016
+ tabletMode
1017
+ } = _ref2;
1018
+ return /*#__PURE__*/React.createElement(ResponsiveDropBox, {
1019
+ animationStyle: animationStyle,
1020
+ boxPosition: position || `${defaultDropBoxPosition}Center`,
1021
+ getRef: getContainerRef,
1022
+ isActive: isPopupReady,
1023
+ isAnimate: true,
1024
+ isArrow: false,
1025
+ onClick: removeClose,
1026
+ needResponsive: needResponsive,
1027
+ isPadding: isPadding,
1028
+ isBoxPaddingNeed: !needSelectAll,
1029
+ isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
1030
+ positionsOffset: positionsOffset,
1031
+ targetOffset: targetOffset,
1032
+ isRestrictScroll: isRestrictScroll,
1033
+ htmlId: setAriaId,
1070
1034
  a11y: {
1071
- role: 'option'
1035
+ role: 'listbox',
1036
+ ariaMultiselectable: true
1072
1037
  },
1073
- limit: limit,
1074
- limitReachedMessage: limitReachedMessage,
1075
- dataId: `${dataId}_Options`
1076
- })));
1077
- }) : /*#__PURE__*/React.createElement(EmptyState, {
1078
- options: revampedGroups,
1079
- searchString: searchStr,
1080
- suggestions: suggestionGroups,
1081
- renderCustomEmptyState: renderCustomEmptyState,
1082
- dataId: dataId,
1083
- isLoading: isFetchingOptions,
1084
- i18nKeys: i18nKeys,
1085
- htmlId: ariaErrorId
1086
- }), isNextOptions && /*#__PURE__*/React.createElement("div", {
1087
- className: style.loader
1088
- }, /*#__PURE__*/React.createElement(Loader, null)))) : /*#__PURE__*/React.createElement("div", {
1089
- className: style.loader
1090
- }, /*#__PURE__*/React.createElement(Loader, null)), getFooter ? isDataLoaded ? /*#__PURE__*/React.createElement(CardFooter, null, getFooter()) : /*#__PURE__*/React.createElement("div", {
1091
- className: style.loader
1092
- }, /*#__PURE__*/React.createElement(Loader, null)) : null)))) : null);
1038
+ alignBox: "row",
1039
+ dataId: `${dataId}_dropbox`
1040
+ }, /*#__PURE__*/React.createElement(Box, {
1041
+ flexible: true
1042
+ }, /*#__PURE__*/React.createElement(Card, {
1043
+ customClass: `${style.box} ${style[`${palette}Box`]}`,
1044
+ onScroll: this.handleScroll
1045
+ }, needSelectAll && !(limit >= 0) ? /*#__PURE__*/React.createElement(CardHeader, null, /*#__PURE__*/React.createElement(MultiSelectHeader, {
1046
+ onSelect: this.handleSelectAll,
1047
+ selectAllText: selectAllText,
1048
+ suggestions: suggestionOptionIds,
1049
+ dataId: dataId
1050
+ })) : null, isDataLoaded ? /*#__PURE__*/React.createElement(CardContent, {
1051
+ shrink: true,
1052
+ customClass: !tabletMode && dropBoxSize ? style[dropBoxSize] : '',
1053
+ eleRef: this.suggestionContainerRef
1054
+ }, /*#__PURE__*/React.createElement(React.Fragment, {
1055
+ key: 'SuggestonsParent'
1056
+ }, suggestionGroups.length ? suggestionGroups.map(group => {
1057
+ let {
1058
+ options: suggestions = []
1059
+ } = group;
1060
+ let groupId = group.id;
1061
+ let groupName = group.name;
1062
+ let hoverId = suggestionOptionIds[hoverIndex];
1063
+ return /*#__PURE__*/React.createElement(React.Fragment, {
1064
+ key: groupId
1065
+ }, groupName && /*#__PURE__*/React.createElement("div", {
1066
+ className: style.groupTitle
1067
+ }, /*#__PURE__*/React.createElement(DropDownHeading, {
1068
+ text: groupName,
1069
+ a11y: {
1070
+ role: 'heading'
1071
+ }
1072
+ })), /*#__PURE__*/React.createElement(Suggestions, _extends({}, SuggestionsProps, {
1073
+ suggestions: suggestions,
1074
+ selectedOptions: selectedOptionIds,
1075
+ getRef: this.suggestionItemRef,
1076
+ hoverId: hoverId,
1077
+ onClick: this.handleSelectOption,
1078
+ onMouseEnter: this.handleMouseEnter,
1079
+ needTick: true,
1080
+ listItemSize: listItemSize,
1081
+ a11y: {
1082
+ role: 'option'
1083
+ },
1084
+ limit: limit,
1085
+ limitReachedMessage: limitReachedMessage,
1086
+ dataId: `${dataId}_Options`
1087
+ })));
1088
+ }) : /*#__PURE__*/React.createElement(EmptyState, {
1089
+ options: revampedGroups,
1090
+ searchString: searchStr,
1091
+ suggestions: suggestionGroups,
1092
+ renderCustomEmptyState: renderCustomEmptyState,
1093
+ dataId: dataId,
1094
+ isLoading: isFetchingOptions,
1095
+ i18nKeys: i18nKeys,
1096
+ htmlId: ariaErrorId
1097
+ }), isNextOptions && /*#__PURE__*/React.createElement("div", {
1098
+ className: style.loader
1099
+ }, /*#__PURE__*/React.createElement(Loader, null)))) : /*#__PURE__*/React.createElement("div", {
1100
+ className: style.loader
1101
+ }, /*#__PURE__*/React.createElement(Loader, null)), getFooter ? isDataLoaded ? /*#__PURE__*/React.createElement(CardFooter, null, getFooter()) : /*#__PURE__*/React.createElement("div", {
1102
+ className: style.loader
1103
+ }, /*#__PURE__*/React.createElement(Loader, null)) : null)));
1104
+ }) : null);
1093
1105
  }
1094
1106
 
1095
1107
  }
@@ -83,7 +83,9 @@ export class AdvancedMultiSelectComponent extends MultiSelectComponent {
83
83
  return suggestions;
84
84
  }
85
85
 
86
- handleChange(selectedOptions = [], e) {
86
+ handleChange() {
87
+ let selectedOptions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
88
+ let e = arguments.length > 1 ? arguments[1] : undefined;
87
89
  const {
88
90
  optionsNormalize,
89
91
  searchStr
@@ -331,9 +333,10 @@ export class AdvancedMultiSelectComponent extends MultiSelectComponent {
331
333
  });
332
334
  }
333
335
 
334
- responsiveFunc({
335
- mediaQueryOR
336
- }) {
336
+ responsiveFunc(_ref) {
337
+ let {
338
+ mediaQueryOR
339
+ } = _ref;
337
340
  return {
338
341
  tabletMode: mediaQueryOR([{
339
342
  maxWidth: 700
@@ -511,76 +514,79 @@ export class AdvancedMultiSelectComponent extends MultiSelectComponent {
511
514
  }))) : null))), !isReadOnly && !isDisabled && isPopupOpen ? /*#__PURE__*/React.createElement(ResponsiveReceiver, {
512
515
  query: this.responsiveFunc,
513
516
  responsiveId: "Helmet"
514
- }, ({
515
- tabletMode
516
- }) => /*#__PURE__*/React.createElement(ResponsiveDropBox, _extends({
517
- animationStyle: animationStyle,
518
- boxPosition: position || `${defaultDropBoxPosition}Center`,
519
- getRef: getContainerRef,
520
- isActive: isPopupReady,
521
- isAnimate: isAnimate,
522
- isArrow: false,
523
- onClick: removeClose,
524
- isPadding: false,
525
- isBoxPaddingNeed: isBoxPaddingNeed,
526
- htmlId: setAriaId,
527
- a11y: {
528
- role: 'listbox',
529
- ariaMultiselectable: true
530
- },
531
- dataId: `${dataIdMultiSelectComp}_dropbox`,
532
- isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
533
- positionsOffset: positionsOffset,
534
- targetOffset: targetOffset,
535
- isRestrictScroll: isRestrictScroll
536
- }, DropBoxProps, {
537
- alignBox: "row",
538
- isResponsivePadding: getFooter ? false : true
539
- }), isLoading ? /*#__PURE__*/React.createElement(Container, {
540
- align: "both",
541
- className: style.loader
542
- }, /*#__PURE__*/React.createElement(Loader, null)) : /*#__PURE__*/React.createElement(Box, {
543
- flexible: true
544
- }, /*#__PURE__*/React.createElement(Card, {
545
- customClass: style.box,
546
- onScroll: this.handleScroll
547
- }, needSelectAll && !(limit >= 0) ? /*#__PURE__*/React.createElement(CardHeader, null, /*#__PURE__*/React.createElement(MultiSelectHeader, {
548
- onSelect: this.handleSelectAll,
549
- selectAllText: selectAllText,
550
- suggestions: suggestions,
551
- dataId: dataIdSelectAllEle
552
- })) : null, /*#__PURE__*/React.createElement(CardContent, {
553
- shrink: true,
554
- customClass: !tabletMode && dropBoxSize ? style[dropBoxSize] : '',
555
- eleRef: this.suggestionContainerRef
556
- }, suggestions.length ? /*#__PURE__*/React.createElement(Suggestions, _extends({
557
- suggestions: suggestions,
558
- selectedOptions: allselectedOptionIds,
559
- getRef: this.suggestionItemRef,
560
- hoverOption: hoverOption,
561
- onClick: this.handleSelectOption,
562
- onMouseEnter: this.handleMouseEnter,
563
- needTick: true,
564
- listItemSize: listItemSize,
565
- a11y: {
566
- role: 'option'
567
- },
568
- dataId: `${dataIdMultiSelectComp}_Options`,
569
- limit: limit,
570
- limitReachedMessage: limitReachedMessage
571
- }, SuggestionsProps)) : /*#__PURE__*/React.createElement(EmptyState, {
572
- isLoading: isFetchingOptions,
573
- options: options,
574
- searchString: searchStr,
575
- suggestions: suggestions,
576
- renderCustomEmptyState: renderCustomEmptyState,
577
- dataId: dataIdLoading,
578
- i18nKeys: i18nKeys,
579
- htmlId: ariaErrorId
580
- }), isFetchingOptions && /*#__PURE__*/React.createElement(Container, {
581
- isCover: false,
582
- align: "both"
583
- }, /*#__PURE__*/React.createElement(Loader, null))), getFooter ? /*#__PURE__*/React.createElement(CardFooter, null, getFooter()) : null)))) : null);
517
+ }, _ref2 => {
518
+ let {
519
+ tabletMode
520
+ } = _ref2;
521
+ return /*#__PURE__*/React.createElement(ResponsiveDropBox, _extends({
522
+ animationStyle: animationStyle,
523
+ boxPosition: position || `${defaultDropBoxPosition}Center`,
524
+ getRef: getContainerRef,
525
+ isActive: isPopupReady,
526
+ isAnimate: isAnimate,
527
+ isArrow: false,
528
+ onClick: removeClose,
529
+ isPadding: false,
530
+ isBoxPaddingNeed: isBoxPaddingNeed,
531
+ htmlId: setAriaId,
532
+ a11y: {
533
+ role: 'listbox',
534
+ ariaMultiselectable: true
535
+ },
536
+ dataId: `${dataIdMultiSelectComp}_dropbox`,
537
+ isAbsolutePositioningNeeded: isAbsolutePositioningNeeded,
538
+ positionsOffset: positionsOffset,
539
+ targetOffset: targetOffset,
540
+ isRestrictScroll: isRestrictScroll
541
+ }, DropBoxProps, {
542
+ alignBox: "row",
543
+ isResponsivePadding: getFooter ? false : true
544
+ }), isLoading ? /*#__PURE__*/React.createElement(Container, {
545
+ align: "both",
546
+ className: style.loader
547
+ }, /*#__PURE__*/React.createElement(Loader, null)) : /*#__PURE__*/React.createElement(Box, {
548
+ flexible: true
549
+ }, /*#__PURE__*/React.createElement(Card, {
550
+ customClass: style.box,
551
+ onScroll: this.handleScroll
552
+ }, needSelectAll && !(limit >= 0) ? /*#__PURE__*/React.createElement(CardHeader, null, /*#__PURE__*/React.createElement(MultiSelectHeader, {
553
+ onSelect: this.handleSelectAll,
554
+ selectAllText: selectAllText,
555
+ suggestions: suggestions,
556
+ dataId: dataIdSelectAllEle
557
+ })) : null, /*#__PURE__*/React.createElement(CardContent, {
558
+ shrink: true,
559
+ customClass: !tabletMode && dropBoxSize ? style[dropBoxSize] : '',
560
+ eleRef: this.suggestionContainerRef
561
+ }, suggestions.length ? /*#__PURE__*/React.createElement(Suggestions, _extends({
562
+ suggestions: suggestions,
563
+ selectedOptions: allselectedOptionIds,
564
+ getRef: this.suggestionItemRef,
565
+ hoverOption: hoverOption,
566
+ onClick: this.handleSelectOption,
567
+ onMouseEnter: this.handleMouseEnter,
568
+ needTick: true,
569
+ listItemSize: listItemSize,
570
+ a11y: {
571
+ role: 'option'
572
+ },
573
+ dataId: `${dataIdMultiSelectComp}_Options`,
574
+ limit: limit,
575
+ limitReachedMessage: limitReachedMessage
576
+ }, SuggestionsProps)) : /*#__PURE__*/React.createElement(EmptyState, {
577
+ isLoading: isFetchingOptions,
578
+ options: options,
579
+ searchString: searchStr,
580
+ suggestions: suggestions,
581
+ renderCustomEmptyState: renderCustomEmptyState,
582
+ dataId: dataIdLoading,
583
+ i18nKeys: i18nKeys,
584
+ htmlId: ariaErrorId
585
+ }), isFetchingOptions && /*#__PURE__*/React.createElement(Container, {
586
+ isCover: false,
587
+ align: "both"
588
+ }, /*#__PURE__*/React.createElement(Loader, null))), getFooter ? /*#__PURE__*/React.createElement(CardFooter, null, getFooter()) : null)));
589
+ }) : null);
584
590
  }
585
591
 
586
592
  }
@@ -613,7 +613,11 @@ export class MultiSelectComponent extends React.Component {
613
613
  }
614
614
  }
615
615
 
616
- handleFetchOptions(...args) {
616
+ handleFetchOptions() {
617
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
618
+ args[_key] = arguments[_key];
619
+ }
620
+
617
621
  const [APICall, searchStr] = args;
618
622
  const {
619
623
  isFetchingOptions
@@ -679,7 +683,9 @@ export class MultiSelectComponent extends React.Component {
679
683
  });
680
684
  }
681
685
 
682
- handleClickSelectedOption(id = '', e) {
686
+ handleClickSelectedOption() {
687
+ let id = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
688
+ let e = arguments.length > 1 ? arguments[1] : undefined;
683
689
  const {
684
690
  selectedOptions
685
691
  } = this.props;
@@ -755,7 +761,9 @@ export class MultiSelectComponent extends React.Component {
755
761
  isNextOptions && getNextOptions && this.handleFetchOptions(getNextOptions, searchStr);
756
762
  }
757
763
 
758
- handleChange(selectedOptions = [], e) {
764
+ handleChange() {
765
+ let selectedOptions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
766
+ let e = arguments.length > 1 ? arguments[1] : undefined;
759
767
  const {
760
768
  optionsNormalize
761
769
  } = this.state;
@@ -904,7 +912,8 @@ export class MultiSelectComponent extends React.Component {
904
912
  this.suggestionContainer && refFunc(this.suggestionContainer);
905
913
  }
906
914
 
907
- getSelectionUI(isResponsive = false) {
915
+ getSelectionUI() {
916
+ let isResponsive = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
908
917
  let {
909
918
  size,
910
919
  needBorder,
@@ -14,11 +14,12 @@ import { Container, Box } from "../Layout";
14
14
  import { DUMMY_OBJECT, DUMMY_ARRAY } from "../utils/Common";
15
15
  import { renderNode } from '@zohodesk/utils';
16
16
 
17
- function SuggestionsVirtualizerContainer({
18
- eleRef,
19
- children,
20
- setVirtualizerContainerRefFunction
21
- }) {
17
+ function SuggestionsVirtualizerContainer(_ref) {
18
+ let {
19
+ eleRef,
20
+ children,
21
+ setVirtualizerContainerRefFunction
22
+ } = _ref;
22
23
  useMemo(() => {
23
24
  typeof setVirtualizerContainerRefFunction === 'function' && setVirtualizerContainerRefFunction(eleRef);
24
25
  }, [eleRef, setVirtualizerContainerRefFunction]);
@@ -32,11 +33,12 @@ export default class Suggestions extends React.PureComponent {
32
33
  this.renderVirtualizerSuggestionListItem = this.renderVirtualizerSuggestionListItem.bind(this);
33
34
  }
34
35
 
35
- renderSuggestionList({
36
- suggestion,
37
- index,
38
- ref
39
- }) {
36
+ renderSuggestionList(_ref2) {
37
+ let {
38
+ suggestion,
39
+ index,
40
+ ref
41
+ } = _ref2;
40
42
  const {
41
43
  getRef,
42
44
  hoverOption,
@@ -168,10 +170,11 @@ export default class Suggestions extends React.PureComponent {
168
170
  }));
169
171
  }
170
172
 
171
- renderVirtualizerSuggestionListItem({
172
- index,
173
- ref
174
- }) {
173
+ renderVirtualizerSuggestionListItem(_ref3) {
174
+ let {
175
+ index,
176
+ ref
177
+ } = _ref3;
175
178
  const {
176
179
  suggestions
177
180
  } = this.props;
package/es/Popup/Popup.js CHANGED
@@ -5,7 +5,10 @@ import { DUMMY_ARRAY, DUMMY_OBJECT } from "./../utils/Common.js";
5
5
  import Registry from '@zohodesk/dotkit/es/react/components/Popup/Registry.js';
6
6
  global.closeGroupPopups = Registry.closeAllPopupsInGroup;
7
7
 
8
- const Popup = (Component, group = 'global', needResizeHandling = true, options = DUMMY_OBJECT) => {
8
+ const Popup = function (Component) {
9
+ let group = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'global';
10
+ let needResizeHandling = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
11
+ let options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : DUMMY_OBJECT;
9
12
  const {
10
13
  isAbsolutePositioningNeeded = true,
11
14
  isArrow = false,
@@ -30,10 +30,11 @@ function getDeletedIndexes() {
30
30
  return deletedIndexes;
31
31
  }
32
32
 
33
- function callback({
34
- globalId,
35
- deletedIndexes
36
- }) {
33
+ function callback(_ref) {
34
+ let {
35
+ globalId,
36
+ deletedIndexes
37
+ } = _ref;
37
38
  setGlobalId(globalId);
38
39
  setDeletedIndexes(deletedIndexes);
39
40
  }
@@ -3,17 +3,18 @@ import PropTypes from 'prop-types';
3
3
  import LibraryContextInit from "./LibraryContextInit";
4
4
  import { getLibraryConfig } from "./Config";
5
5
 
6
- const LibraryContextProvider = ({
7
- isReducedMotion,
8
- direction,
9
- coloredTagVariant,
10
- hasTagColorInheritedToText,
11
- shouldIndicateSwitchState,
12
- shouldStrikeThroughDisabledButton,
13
- labelRequiredType,
14
- shouldHighlightRequiredLabel,
15
- children
16
- }) => {
6
+ const LibraryContextProvider = _ref => {
7
+ let {
8
+ isReducedMotion,
9
+ direction,
10
+ coloredTagVariant,
11
+ hasTagColorInheritedToText,
12
+ shouldIndicateSwitchState,
13
+ shouldStrikeThroughDisabledButton,
14
+ labelRequiredType,
15
+ shouldHighlightRequiredLabel,
16
+ children
17
+ } = _ref;
17
18
  const [value, setValue] = useState({
18
19
  isReducedMotion,
19
20
  direction,
@@ -50,13 +50,14 @@ export function decreaseGlobalIds(numbers, deletedIndexes, globalId) {
50
50
  deletedIndexes
51
51
  };
52
52
  }
53
- export function useNumberGenerator({
54
- getGlobalId,
55
- prefix,
56
- getGlobalPrefix,
57
- getDeletedIndexes,
58
- callback
59
- }) {
53
+ export function useNumberGenerator(_ref) {
54
+ let {
55
+ getGlobalId,
56
+ prefix,
57
+ getGlobalPrefix,
58
+ getDeletedIndexes,
59
+ callback
60
+ } = _ref;
60
61
  let presentValues = useRef([]),
61
62
  presentIndex = useRef(0);
62
63
  prefix = typeof prefix === 'undefined' ? '' : `${prefix}_`;
@@ -83,14 +84,15 @@ export function useNumberGenerator({
83
84
  presentIndex.current = -1;
84
85
  return getNextId;
85
86
  }
86
- export function getNumberGenerators({
87
- Component,
88
- prefix,
89
- getGlobalPrefix,
90
- getGlobalId,
91
- getDeletedIndexes,
92
- callback
93
- }) {
87
+ export function getNumberGenerators(_ref2) {
88
+ let {
89
+ Component,
90
+ prefix,
91
+ getGlobalPrefix,
92
+ getGlobalId,
93
+ getDeletedIndexes,
94
+ callback
95
+ } = _ref2;
94
96
  let presentIndex = 0,
95
97
  presentValues = [],
96
98
  {
@@ -27,10 +27,11 @@ function getDeletedIndexes() {
27
27
  return deletedIndexes;
28
28
  }
29
29
 
30
- function callback({
31
- globalId,
32
- deletedIndexes
33
- }) {
30
+ function callback(_ref) {
31
+ let {
32
+ globalId,
33
+ deletedIndexes
34
+ } = _ref;
34
35
  setInitialZIndex(globalId);
35
36
  setDeletedIndexes(deletedIndexes);
36
37
  }
@@ -94,7 +94,9 @@ ResponsiveSender.defaultProps = { ...CustomResponsiveSender_defaultProps,
94
94
  };
95
95
  ResponsiveSender.contextType = ResponsiveContext;
96
96
  ResponsiveSender.propTypes = CustomResponsiveSender_propTypes;
97
- export function useResponsiveReceiver(responsiveId = defaultResponsiveId, query) {
97
+ export function useResponsiveReceiver() {
98
+ let responsiveId = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaultResponsiveId;
99
+ let query = arguments.length > 1 ? arguments[1] : undefined;
98
100
  const [, forceUpdate] = useState();
99
101
  const totalContextData = useContext(ResponsiveContext);
100
102
  const validSizeContextData = totalContextData[validSizeResponsiveId];
@@ -172,13 +174,14 @@ export function useResponsiveReceiver(responsiveId = defaultResponsiveId, query)
172
174
  updateLatestData();
173
175
  return data.current;
174
176
  }
175
- export function ResponsiveReceiver({
176
- children,
177
- responsiveId,
178
- query,
179
- eleRef,
180
- domRefKey
181
- }) {
177
+ export function ResponsiveReceiver(_ref) {
178
+ let {
179
+ children,
180
+ responsiveId,
181
+ query,
182
+ eleRef,
183
+ domRefKey
184
+ } = _ref;
182
185
  const data = useResponsiveReceiver(responsiveId, query);
183
186
  const child = children(data);
184
187
  return eleRef ? /*#__PURE__*/React.createElement(DOMRefWrapper, {