@zohodesk/components 1.0.0-temp-109 → 1.0.0-temp-111
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.
- package/README.md +18 -1
- package/assets/Appearance/dark/themes/blue/blueDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/dark/themes/green/greenDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/dark/themes/orange/orangeDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/dark/themes/red/redDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/dark/themes/yellow/yellowDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/default/themes/blue/blueDefaultComponentTheme.module.css +3 -0
- package/assets/Appearance/default/themes/green/greenDefaultComponentTheme.module.css +3 -0
- package/assets/Appearance/default/themes/orange/orangeDefaultComponentTheme.module.css +3 -0
- package/assets/Appearance/default/themes/red/redDefaultComponentTheme.module.css +3 -0
- package/assets/Appearance/default/themes/yellow/yellowDefaultComponentTheme.module.css +3 -0
- package/assets/Appearance/pureDark/themes/blue/bluePureDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/pureDark/themes/green/greenPureDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/pureDark/themes/orange/orangePureDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/pureDark/themes/red/redPureDarkComponentTheme.module.css +3 -0
- package/assets/Appearance/pureDark/themes/yellow/yellowPureDarkComponentTheme.module.css +3 -0
- package/es/AppContainer/AppContainer.js +1 -0
- package/es/Button/Button.js +5 -3
- package/es/DateTime/CalendarView.js +25 -14
- package/es/DateTime/DateTime.js +6 -4
- package/es/DateTime/DateTime.module.css +10 -8
- package/es/DateTime/DateWidget.js +18 -2
- package/es/DateTime/props/defaultProps.js +2 -1
- package/es/DropBox/DropBox.js +24 -4
- package/es/DropBox/props/defaultProps.js +2 -1
- package/es/DropBox/props/propTypes.js +1 -0
- package/es/ListItem/ListContainer.js +1 -0
- package/es/MultiSelect/MultiSelect.js +15 -7
- package/es/MultiSelect/MultiSelect.module.css +4 -0
- package/es/MultiSelect/props/defaultProps.js +2 -1
- package/es/MultiSelect/props/propTypes.js +2 -1
- package/es/Select/Select.js +13 -5
- package/es/Switch/Switch.js +7 -5
- package/es/Tab/Tab.js +1 -1
- package/es/Tab/TabContent.js +1 -1
- package/es/Tab/Tabs.js +4 -4
- package/es/common/a11y.module.css +4 -0
- package/es/semantic/Button/Button.js +1 -0
- package/lib/Accordion/Accordion.js +3 -1
- package/lib/Accordion/AccordionItem.js +3 -1
- package/lib/Animation/Animation.js +3 -1
- package/lib/AppContainer/AppContainer.js +4 -1
- package/lib/Avatar/Avatar.js +3 -1
- package/lib/AvatarTeam/AvatarTeam.js +3 -1
- package/lib/Button/Button.js +8 -4
- package/lib/Buttongroup/Buttongroup.js +5 -2
- package/lib/Card/Card.js +3 -1
- package/lib/CheckBox/CheckBox.js +3 -1
- package/lib/DateTime/CalendarView.js +30 -16
- package/lib/DateTime/DateTime.js +10 -6
- package/lib/DateTime/DateTime.module.css +10 -8
- package/lib/DateTime/DateTimePopupFooter.js +3 -1
- package/lib/DateTime/DateTimePopupHeader.js +3 -1
- package/lib/DateTime/DateWidget.js +108 -89
- package/lib/DateTime/DaysRow.js +3 -1
- package/lib/DateTime/Time.js +3 -1
- package/lib/DateTime/YearView.js +3 -1
- package/lib/DateTime/dateFormatUtils/timeChange.js +1 -1
- package/lib/DateTime/props/defaultProps.js +2 -1
- package/lib/DropBox/DropBox.js +27 -5
- package/lib/DropBox/props/defaultProps.js +2 -1
- package/lib/DropBox/props/propTypes.js +1 -0
- package/lib/DropDown/DropDown.js +5 -2
- package/lib/DropDown/DropDownHeading.js +3 -1
- package/lib/DropDown/DropDownItem.js +3 -1
- package/lib/DropDown/DropDownSearch.js +5 -2
- package/lib/DropDown/DropDownSeparator.js +3 -1
- package/lib/DropDown/props/propTypes.js +4 -1
- package/lib/Heading/Heading.js +4 -2
- package/lib/Label/Label.js +3 -1
- package/lib/ListItem/ListContainer.js +1 -0
- package/lib/ListItem/ListItem.js +3 -1
- package/lib/ListItem/ListItemWithAvatar.js +3 -1
- package/lib/ListItem/ListItemWithCheckBox.js +3 -1
- package/lib/ListItem/ListItemWithIcon.js +3 -1
- package/lib/ListItem/ListItemWithRadio.js +3 -1
- package/lib/ListItem/props/propTypes.js +4 -1
- package/lib/Modal/Modal.js +3 -1
- package/lib/MultiSelect/AdvancedGroupMultiSelect.js +5 -3
- package/lib/MultiSelect/AdvancedMultiSelect.js +3 -1
- package/lib/MultiSelect/EmptyState.js +3 -1
- package/lib/MultiSelect/MultiSelect.js +17 -9
- package/lib/MultiSelect/MultiSelect.module.css +4 -0
- package/lib/MultiSelect/MultiSelectHeader.js +3 -1
- package/lib/MultiSelect/MultiSelectWithAvatar.js +3 -1
- package/lib/MultiSelect/SelectedOptions.js +5 -2
- package/lib/MultiSelect/Suggestions.js +4 -2
- package/lib/MultiSelect/props/defaultProps.js +2 -1
- package/lib/MultiSelect/props/propTypes.js +2 -1
- package/lib/PopOver/PopOver.js +3 -1
- package/lib/Popup/Popup.js +3 -1
- package/lib/Popup/__tests__/Popup.spec.js +3 -1
- package/lib/Provider/LibraryContext.js +4 -2
- package/lib/Radio/Radio.js +3 -1
- package/lib/Responsive/CustomResponsive.js +5 -3
- package/lib/Responsive/RefWrapper.js +4 -2
- package/lib/Responsive/ResizeComponent.js +3 -1
- package/lib/Responsive/ResizeObserver.js +4 -1
- package/lib/Responsive/Responsive.js +5 -3
- package/lib/Responsive/sizeObservers.js +4 -2
- package/lib/ResponsiveDropBox/ResponsiveDropBox.js +3 -1
- package/lib/Ribbon/Ribbon.js +3 -1
- package/lib/Select/GroupSelect.js +4 -2
- package/lib/Select/Select.js +14 -6
- package/lib/Select/SelectWithAvatar.js +3 -1
- package/lib/Select/SelectWithIcon.js +3 -1
- package/lib/Select/__tests__/Select.spec.js +1 -1
- package/lib/Select/props/defaultProps.js +4 -1
- package/lib/Stencils/Stencils.js +3 -1
- package/lib/Switch/Switch.js +10 -6
- package/lib/Tab/Tab.js +1 -1
- package/lib/Tab/TabContent.js +1 -1
- package/lib/Tab/TabWrapper.js +1 -1
- package/lib/Tab/Tabs.js +8 -6
- package/lib/Tag/Tag.js +3 -1
- package/lib/TextBox/TextBox.js +3 -1
- package/lib/TextBox/props/propTypes.js +4 -1
- package/lib/TextBoxIcon/TextBoxIcon.js +5 -2
- package/lib/Textarea/Textarea.js +3 -1
- package/lib/Tooltip/Tooltip.js +3 -1
- package/lib/Tooltip/__tests__/Tooltip.spec.js +3 -1
- package/lib/VelocityAnimation/VelocityAnimation/VelocityAnimation.js +3 -1
- package/lib/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +4 -2
- package/lib/common/a11y.module.css +4 -0
- package/lib/deprecated/PortalLayer/PortalLayer.js +3 -1
- package/lib/semantic/Button/Button.js +4 -1
- package/lib/utils/constructFullName.js +1 -1
- package/lib/utils/dropDownUtils.js +4 -2
- package/package.json +5 -3
|
@@ -14,8 +14,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
14
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
15
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
16
16
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
17
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
17
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
18
18
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
19
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
20
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
19
21
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
20
22
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
21
23
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -27,8 +27,10 @@ var _Common = require("../utils/Common");
|
|
|
27
27
|
var _constants = require("./constants");
|
|
28
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
29
29
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
30
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
30
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
31
31
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
32
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
33
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
32
34
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
33
35
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
34
36
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -64,6 +66,7 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
64
66
|
_this.handleDateIconClick = _this.handleDateIconClick.bind(_assertThisInitialized(_this));
|
|
65
67
|
_this.handleSelectionRangeDetails = _this.handleSelectionRangeDetails.bind(_assertThisInitialized(_this));
|
|
66
68
|
_this.handleBlurSelectionRange = _this.handleBlurSelectionRange.bind(_assertThisInitialized(_this));
|
|
69
|
+
_this.handleExposePopupHandlers = _this.handleExposePopupHandlers.bind(_assertThisInitialized(_this));
|
|
67
70
|
_this.state = {
|
|
68
71
|
selected: '',
|
|
69
72
|
displayText: '',
|
|
@@ -103,6 +106,7 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
103
106
|
selected: newSelected
|
|
104
107
|
});
|
|
105
108
|
this.handleSelectionRangeDetails(this.props);
|
|
109
|
+
this.handleExposePopupHandlers();
|
|
106
110
|
}
|
|
107
111
|
}, {
|
|
108
112
|
key: "componentDidUpdate",
|
|
@@ -221,15 +225,28 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
221
225
|
}
|
|
222
226
|
}
|
|
223
227
|
}, {
|
|
224
|
-
key: "
|
|
225
|
-
value: function
|
|
228
|
+
key: "handleExposePopupHandlers",
|
|
229
|
+
value: function handleExposePopupHandlers() {
|
|
226
230
|
var _this$props3 = this.props,
|
|
231
|
+
removeClose = _this$props3.removeClose,
|
|
227
232
|
togglePopup = _this$props3.togglePopup,
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
+
getPopupHandlers = _this$props3.getPopupHandlers;
|
|
234
|
+
var methods = {
|
|
235
|
+
removeClose: removeClose,
|
|
236
|
+
togglePopup: this.handleTogglePopup
|
|
237
|
+
};
|
|
238
|
+
getPopupHandlers && getPopupHandlers(methods);
|
|
239
|
+
}
|
|
240
|
+
}, {
|
|
241
|
+
key: "handleTogglePopup",
|
|
242
|
+
value: function handleTogglePopup(e, isOpenOnly) {
|
|
243
|
+
var _this$props4 = this.props,
|
|
244
|
+
togglePopup = _this$props4.togglePopup,
|
|
245
|
+
_this$props4$defaultP = _this$props4.defaultPosition,
|
|
246
|
+
defaultPosition = _this$props4$defaultP === void 0 ? 'bottom' : _this$props4$defaultP,
|
|
247
|
+
openPopupOnly = _this$props4.openPopupOnly,
|
|
248
|
+
isPopupOpen = _this$props4.isPopupOpen,
|
|
249
|
+
removeClose = _this$props4.removeClose;
|
|
233
250
|
if (isOpenOnly) {
|
|
234
251
|
if (!isPopupOpen) {
|
|
235
252
|
togglePopup(e, "".concat(defaultPosition, "Right"));
|
|
@@ -321,12 +338,12 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
321
338
|
key: "handleKeyDown",
|
|
322
339
|
value: function handleKeyDown(e) {
|
|
323
340
|
var keyCode = e.keyCode;
|
|
324
|
-
var _this$
|
|
325
|
-
isPopupOpen = _this$
|
|
326
|
-
isPopupOpenOnEnter = _this$
|
|
327
|
-
onKeyDown = _this$
|
|
328
|
-
closePopupOnly = _this$
|
|
329
|
-
cantEditOnPopupOpen = _this$
|
|
341
|
+
var _this$props5 = this.props,
|
|
342
|
+
isPopupOpen = _this$props5.isPopupOpen,
|
|
343
|
+
isPopupOpenOnEnter = _this$props5.isPopupOpenOnEnter,
|
|
344
|
+
onKeyDown = _this$props5.onKeyDown,
|
|
345
|
+
closePopupOnly = _this$props5.closePopupOnly,
|
|
346
|
+
cantEditOnPopupOpen = _this$props5.cantEditOnPopupOpen;
|
|
330
347
|
var isAllowedDateType = this.handleGetAllowedType();
|
|
331
348
|
if (isPopupOpen) {
|
|
332
349
|
if (keyCode === 9 && !isAllowedDateType) {
|
|
@@ -423,19 +440,19 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
423
440
|
if ((0, _dateFormatUtils.getIsSupportedKey)(e)) {
|
|
424
441
|
e.preventDefault();
|
|
425
442
|
}
|
|
426
|
-
var _this$
|
|
427
|
-
isDateTime = _this$
|
|
428
|
-
timeZone = _this$
|
|
429
|
-
value = _this$
|
|
430
|
-
onSelect = _this$
|
|
431
|
-
id = _this$
|
|
432
|
-
min = _this$
|
|
433
|
-
max = _this$
|
|
434
|
-
minErrorText = _this$
|
|
435
|
-
maxErrorText = _this$
|
|
436
|
-
onError = _this$
|
|
437
|
-
closePopupOnly = _this$
|
|
438
|
-
is24Hour = _this$
|
|
443
|
+
var _this$props6 = this.props,
|
|
444
|
+
isDateTime = _this$props6.isDateTime,
|
|
445
|
+
timeZone = _this$props6.timeZone,
|
|
446
|
+
value = _this$props6.value,
|
|
447
|
+
onSelect = _this$props6.onSelect,
|
|
448
|
+
id = _this$props6.id,
|
|
449
|
+
min = _this$props6.min,
|
|
450
|
+
max = _this$props6.max,
|
|
451
|
+
minErrorText = _this$props6.minErrorText,
|
|
452
|
+
maxErrorText = _this$props6.maxErrorText,
|
|
453
|
+
onError = _this$props6.onError,
|
|
454
|
+
closePopupOnly = _this$props6.closePopupOnly,
|
|
455
|
+
is24Hour = _this$props6.is24Hour;
|
|
439
456
|
var _this$state3 = this.state,
|
|
440
457
|
dateFormatSelection = _this$state3.dateFormatSelection,
|
|
441
458
|
day = _this$state3.day,
|
|
@@ -694,17 +711,17 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
694
711
|
if (!isAllowedDateType) {
|
|
695
712
|
this.handleTogglePopup(e);
|
|
696
713
|
} else {
|
|
697
|
-
var _this$
|
|
698
|
-
isPopupOpenOnClick = _this$
|
|
699
|
-
isReadOnly = _this$
|
|
700
|
-
isDisabled = _this$
|
|
714
|
+
var _this$props7 = this.props,
|
|
715
|
+
isPopupOpenOnClick = _this$props7.isPopupOpenOnClick,
|
|
716
|
+
isReadOnly = _this$props7.isReadOnly,
|
|
717
|
+
isDisabled = _this$props7.isDisabled;
|
|
701
718
|
if (isPopupOpenOnClick && (!isReadOnly || !isDisabled)) {
|
|
702
719
|
this.handleTogglePopup(e, true);
|
|
703
720
|
}
|
|
704
|
-
var _this$
|
|
705
|
-
isPopupCloseOnClick = _this$
|
|
706
|
-
isPopupOpen = _this$
|
|
707
|
-
closePopupOnly = _this$
|
|
721
|
+
var _this$props8 = this.props,
|
|
722
|
+
isPopupCloseOnClick = _this$props8.isPopupCloseOnClick,
|
|
723
|
+
isPopupOpen = _this$props8.isPopupOpen,
|
|
724
|
+
closePopupOnly = _this$props8.closePopupOnly;
|
|
708
725
|
if (isPopupCloseOnClick && !isPopupOpen) {
|
|
709
726
|
closePopupOnly && closePopupOnly(e);
|
|
710
727
|
}
|
|
@@ -731,12 +748,12 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
731
748
|
isDateEdited = _this$state4.isDateEdited,
|
|
732
749
|
isFocused = _this$state4.isFocused,
|
|
733
750
|
selected = _this$state4.selected;
|
|
734
|
-
var _this$
|
|
735
|
-
isDateTime = _this$
|
|
736
|
-
is24Hour = _this$
|
|
737
|
-
isPopupReady = _this$
|
|
738
|
-
timeZone = _this$
|
|
739
|
-
isPopupOpen = _this$
|
|
751
|
+
var _this$props9 = this.props,
|
|
752
|
+
isDateTime = _this$props9.isDateTime,
|
|
753
|
+
is24Hour = _this$props9.is24Hour,
|
|
754
|
+
isPopupReady = _this$props9.isPopupReady,
|
|
755
|
+
timeZone = _this$props9.timeZone,
|
|
756
|
+
isPopupOpen = _this$props9.isPopupOpen;
|
|
740
757
|
if (isDateEdited || isFocused || isPopupReady || isPopupOpen) {
|
|
741
758
|
var _getDateDetails2 = (0, _dateFormat.getDateDetails)(selected, {
|
|
742
759
|
day: day,
|
|
@@ -783,10 +800,10 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
783
800
|
}, {
|
|
784
801
|
key: "handleGetAllowedType",
|
|
785
802
|
value: function handleGetAllowedType() {
|
|
786
|
-
var _this$
|
|
787
|
-
isReadOnly = _this$
|
|
788
|
-
isDisabled = _this$
|
|
789
|
-
isEditable = _this$
|
|
803
|
+
var _this$props10 = this.props,
|
|
804
|
+
isReadOnly = _this$props10.isReadOnly,
|
|
805
|
+
isDisabled = _this$props10.isDisabled,
|
|
806
|
+
isEditable = _this$props10.isEditable;
|
|
790
807
|
if (isEditable) {
|
|
791
808
|
if (isReadOnly || isDisabled) {
|
|
792
809
|
return false;
|
|
@@ -798,10 +815,10 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
798
815
|
}, {
|
|
799
816
|
key: "handleDateClear",
|
|
800
817
|
value: function handleDateClear() {
|
|
801
|
-
var _this$
|
|
802
|
-
id = _this$
|
|
803
|
-
onSelect = _this$
|
|
804
|
-
value = _this$
|
|
818
|
+
var _this$props11 = this.props,
|
|
819
|
+
id = _this$props11.id,
|
|
820
|
+
onSelect = _this$props11.onSelect,
|
|
821
|
+
value = _this$props11.value;
|
|
805
822
|
this.setState({
|
|
806
823
|
day: '',
|
|
807
824
|
month: '',
|
|
@@ -869,44 +886,45 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
869
886
|
}, {
|
|
870
887
|
key: "render",
|
|
871
888
|
value: function render() {
|
|
872
|
-
var _this$
|
|
873
|
-
removeClose = _this$
|
|
874
|
-
minErrorText = _this$
|
|
875
|
-
maxErrorText = _this$
|
|
876
|
-
min = _this$
|
|
877
|
-
max = _this$
|
|
878
|
-
placeholder = _this$
|
|
879
|
-
isPopupOpen = _this$
|
|
880
|
-
isPopupReady = _this$
|
|
881
|
-
isDateTime = _this$
|
|
882
|
-
position = _this$
|
|
883
|
-
textBoxVariant = _this$
|
|
884
|
-
textBoxSize = _this$
|
|
885
|
-
_this$
|
|
886
|
-
children = _this$
|
|
887
|
-
isDisabled = _this$
|
|
888
|
-
getContainerRef = _this$
|
|
889
|
-
getTargetRef = _this$
|
|
890
|
-
timeZone = _this$
|
|
891
|
-
isReadOnly = _this$
|
|
892
|
-
dataId = _this$
|
|
893
|
-
needResponsive = _this$
|
|
894
|
-
className = _this$
|
|
895
|
-
needBorder = _this$
|
|
896
|
-
defaultTime = _this$
|
|
897
|
-
needDefaultTime = _this$
|
|
898
|
-
borderColor = _this$
|
|
899
|
-
i18nKeys = _this$
|
|
900
|
-
needErrorOnBlur = _this$
|
|
901
|
-
htmlId = _this$
|
|
902
|
-
iconOnHover = _this$
|
|
903
|
-
is24Hour = _this$
|
|
904
|
-
isAbsolutePositioningNeeded = _this$
|
|
905
|
-
positionsOffset = _this$
|
|
906
|
-
targetOffset = _this$
|
|
907
|
-
isRestrictScroll = _this$
|
|
908
|
-
dropBoxPortalId = _this$
|
|
909
|
-
|
|
889
|
+
var _this$props12 = this.props,
|
|
890
|
+
removeClose = _this$props12.removeClose,
|
|
891
|
+
minErrorText = _this$props12.minErrorText,
|
|
892
|
+
maxErrorText = _this$props12.maxErrorText,
|
|
893
|
+
min = _this$props12.min,
|
|
894
|
+
max = _this$props12.max,
|
|
895
|
+
placeholder = _this$props12.placeholder,
|
|
896
|
+
isPopupOpen = _this$props12.isPopupOpen,
|
|
897
|
+
isPopupReady = _this$props12.isPopupReady,
|
|
898
|
+
isDateTime = _this$props12.isDateTime,
|
|
899
|
+
position = _this$props12.position,
|
|
900
|
+
textBoxVariant = _this$props12.textBoxVariant,
|
|
901
|
+
textBoxSize = _this$props12.textBoxSize,
|
|
902
|
+
_this$props12$childre = _this$props12.children,
|
|
903
|
+
children = _this$props12$childre === void 0 ? null : _this$props12$childre,
|
|
904
|
+
isDisabled = _this$props12.isDisabled,
|
|
905
|
+
getContainerRef = _this$props12.getContainerRef,
|
|
906
|
+
getTargetRef = _this$props12.getTargetRef,
|
|
907
|
+
timeZone = _this$props12.timeZone,
|
|
908
|
+
isReadOnly = _this$props12.isReadOnly,
|
|
909
|
+
dataId = _this$props12.dataId,
|
|
910
|
+
needResponsive = _this$props12.needResponsive,
|
|
911
|
+
className = _this$props12.className,
|
|
912
|
+
needBorder = _this$props12.needBorder,
|
|
913
|
+
defaultTime = _this$props12.defaultTime,
|
|
914
|
+
needDefaultTime = _this$props12.needDefaultTime,
|
|
915
|
+
borderColor = _this$props12.borderColor,
|
|
916
|
+
i18nKeys = _this$props12.i18nKeys,
|
|
917
|
+
needErrorOnBlur = _this$props12.needErrorOnBlur,
|
|
918
|
+
htmlId = _this$props12.htmlId,
|
|
919
|
+
iconOnHover = _this$props12.iconOnHover,
|
|
920
|
+
is24Hour = _this$props12.is24Hour,
|
|
921
|
+
isAbsolutePositioningNeeded = _this$props12.isAbsolutePositioningNeeded,
|
|
922
|
+
positionsOffset = _this$props12.positionsOffset,
|
|
923
|
+
targetOffset = _this$props12.targetOffset,
|
|
924
|
+
isRestrictScroll = _this$props12.isRestrictScroll,
|
|
925
|
+
dropBoxPortalId = _this$props12.dropBoxPortalId,
|
|
926
|
+
highlightPosition = _this$props12.highlightPosition,
|
|
927
|
+
a11y = _this$props12.a11y;
|
|
910
928
|
var _this$state5 = this.state,
|
|
911
929
|
_this$state5$selected = _this$state5.selected,
|
|
912
930
|
value = _this$state5$selected === void 0 ? '' : _this$state5$selected,
|
|
@@ -918,7 +936,7 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
918
936
|
var showClear = !(isDisabled || isReadOnly) && (isDateEdited || value) ? true : false;
|
|
919
937
|
var showError = needErrorOnBlur ? isError && !isFocused && !isPopupOpen : isError;
|
|
920
938
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
921
|
-
className: "".concat(_DateWidgetModule["default"].container)
|
|
939
|
+
className: "".concat(!highlightPosition ? _DateWidgetModule["default"].container : '')
|
|
922
940
|
}, children ? /*#__PURE__*/_react["default"].createElement("div", {
|
|
923
941
|
"data-id": "".concat(isDisabled ? "".concat(dataId, "_disabled") : isReadOnly ? "".concat(dataId, "_readOnly") : "".concat(dataId, "_widget")),
|
|
924
942
|
onClick: isDisabled || isReadOnly ? null : this.handleTogglePopup,
|
|
@@ -991,7 +1009,8 @@ var DateWidgetComponent = /*#__PURE__*/function (_React$Component) {
|
|
|
991
1009
|
positionsOffset: positionsOffset,
|
|
992
1010
|
targetOffset: targetOffset,
|
|
993
1011
|
isRestrictScroll: isRestrictScroll,
|
|
994
|
-
dropBoxPortalId: dropBoxPortalId
|
|
1012
|
+
dropBoxPortalId: dropBoxPortalId,
|
|
1013
|
+
isPadding: highlightPosition ? true : false
|
|
995
1014
|
}));
|
|
996
1015
|
}
|
|
997
1016
|
}]);
|
package/lib/DateTime/DaysRow.js
CHANGED
|
@@ -12,8 +12,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
14
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
15
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
15
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
16
16
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
17
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
18
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
17
19
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
18
20
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
19
21
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
package/lib/DateTime/Time.js
CHANGED
|
@@ -13,8 +13,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
13
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
15
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
16
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
16
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
17
17
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
18
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
19
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
18
20
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
19
21
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
20
22
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
package/lib/DateTime/YearView.js
CHANGED
|
@@ -16,8 +16,10 @@ var _YearViewModule = _interopRequireDefault(require("./YearView.module.css"));
|
|
|
16
16
|
var _dateFormatUtils = require("./dateFormatUtils");
|
|
17
17
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
18
18
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
19
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
19
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
20
20
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
21
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
22
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
21
23
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
22
24
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
23
25
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -12,7 +12,7 @@ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArra
|
|
|
12
12
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
13
13
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
14
14
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
15
|
-
function _iterableToArrayLimit(arr, i) { var _i =
|
|
15
|
+
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0) { ; } } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
16
16
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
17
17
|
function getChangedHour(values, event, focusOrders, keyActions) {
|
|
18
18
|
var _ref = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {},
|
|
@@ -51,7 +51,8 @@ var DateWidget_defaultProps = {
|
|
|
51
51
|
needErrorOnBlur: false,
|
|
52
52
|
isEditable: false,
|
|
53
53
|
iconOnHover: false,
|
|
54
|
-
is24Hour: false
|
|
54
|
+
is24Hour: false,
|
|
55
|
+
highlightPosition: false
|
|
55
56
|
};
|
|
56
57
|
exports.DateWidget_defaultProps = DateWidget_defaultProps;
|
|
57
58
|
var YearView_defaultProps = {
|
package/lib/DropBox/DropBox.js
CHANGED
|
@@ -15,13 +15,16 @@ var _DropBoxPositionMapping = require("./DropBoxPositionMapping.json");
|
|
|
15
15
|
var _ZindexProvider = require("../Provider/ZindexProvider");
|
|
16
16
|
var _Config = require("../Provider/Config");
|
|
17
17
|
var _LibraryContextInit = _interopRequireDefault(require("../Provider/LibraryContextInit"));
|
|
18
|
+
var _FocusScope = _interopRequireDefault(require("@zohodesk/a11y/es/FocusScope/FocusScope"));
|
|
18
19
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
19
20
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
20
21
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
22
|
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); }
|
|
22
23
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
23
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
24
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
24
25
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
26
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
27
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
25
28
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
26
29
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
27
30
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -87,7 +90,8 @@ var DropBoxElement = /*#__PURE__*/function (_React$Component) {
|
|
|
87
90
|
positionsOffset = _this$props2.positionsOffset,
|
|
88
91
|
targetOffset = _this$props2.targetOffset,
|
|
89
92
|
zIndexStyle = _this$props2.zIndexStyle,
|
|
90
|
-
customStyle = _this$props2.customStyle
|
|
93
|
+
customStyle = _this$props2.customStyle,
|
|
94
|
+
subContainerRef = _this$props2.subContainerRef;
|
|
91
95
|
var _ref = this.context || {},
|
|
92
96
|
isReducedMotion = _ref.isReducedMotion;
|
|
93
97
|
if (!isAbsolutePositioningNeeded && size === 'default' && !isActive) {
|
|
@@ -172,9 +176,11 @@ var DropBoxElement = /*#__PURE__*/function (_React$Component) {
|
|
|
172
176
|
"aria-labelledby": ariaLabelledby,
|
|
173
177
|
tabIndex: tabIndex
|
|
174
178
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
179
|
+
tabIndex: "-1",
|
|
175
180
|
className: "".concat(subContainerClass, " ").concat(_DropBoxModule["default"]["".concat(palette, "Palette")]),
|
|
176
181
|
onClick: onClick,
|
|
177
|
-
"data-id": "".concat(dataId, "_subcontainer")
|
|
182
|
+
"data-id": "".concat(dataId, "_subcontainer"),
|
|
183
|
+
ref: subContainerRef
|
|
178
184
|
}, isModel ? /*#__PURE__*/_react["default"].createElement("div", {
|
|
179
185
|
className: _DropBoxModule["default"].closeBar
|
|
180
186
|
}) : null, isArrow && !isModel && /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -198,6 +204,7 @@ var DropBox = /*#__PURE__*/function (_React$Component2) {
|
|
|
198
204
|
_this2 = _super2.call(this, props);
|
|
199
205
|
_this2.getNextIndex = (0, _ZindexProvider.getZIndex)(_assertThisInitialized(_this2));
|
|
200
206
|
_this2.onFreezeClick = _this2.onFreezeClick.bind(_assertThisInitialized(_this2));
|
|
207
|
+
_this2.createRef = /*#__PURE__*/_react["default"].createRef();
|
|
201
208
|
return _this2;
|
|
202
209
|
}
|
|
203
210
|
_createClass(DropBox, [{
|
|
@@ -214,7 +221,9 @@ var DropBox = /*#__PURE__*/function (_React$Component2) {
|
|
|
214
221
|
isActive = _this$props3.isActive,
|
|
215
222
|
isAbsolutePositioningNeeded = _this$props3.isAbsolutePositioningNeeded,
|
|
216
223
|
needAutoZindex = _this$props3.needAutoZindex,
|
|
217
|
-
isRestrictScroll = _this$props3.isRestrictScroll
|
|
224
|
+
isRestrictScroll = _this$props3.isRestrictScroll,
|
|
225
|
+
needFocusScope = _this$props3.needFocusScope,
|
|
226
|
+
onClose = _this$props3.onClose;
|
|
218
227
|
var windowWidth,
|
|
219
228
|
mobileWidth = (0, _Config.getLibraryConfig)('mobileWidth'),
|
|
220
229
|
isModel = false;
|
|
@@ -229,7 +238,20 @@ var DropBox = /*#__PURE__*/function (_React$Component2) {
|
|
|
229
238
|
} : {};
|
|
230
239
|
var _ref2 = this.context || {},
|
|
231
240
|
direction = _ref2.direction;
|
|
232
|
-
var dropBoxEle = /*#__PURE__*/_react["default"].createElement(
|
|
241
|
+
var dropBoxEle = needFocusScope ? /*#__PURE__*/_react["default"].createElement(_FocusScope["default"], {
|
|
242
|
+
focusClose: onClose,
|
|
243
|
+
elementRef: this.createRef,
|
|
244
|
+
autoFocus: true,
|
|
245
|
+
restoreFocus: true,
|
|
246
|
+
focusArrowLoop: true,
|
|
247
|
+
enableEnterAction: true
|
|
248
|
+
}, /*#__PURE__*/_react["default"].createElement(DropBoxElement, _extends({
|
|
249
|
+
isModel: isModel,
|
|
250
|
+
direction: direction
|
|
251
|
+
}, this.props, {
|
|
252
|
+
zIndexStyle: zIndexStyle,
|
|
253
|
+
subContainerRef: this.createRef
|
|
254
|
+
}))) : /*#__PURE__*/_react["default"].createElement(DropBoxElement, _extends({
|
|
233
255
|
isModel: isModel,
|
|
234
256
|
direction: direction
|
|
235
257
|
}, this.props, {
|
|
@@ -29,6 +29,7 @@ var propTypes = {
|
|
|
29
29
|
left: _propTypes["default"].number,
|
|
30
30
|
needResponsive: _propTypes["default"].bool,
|
|
31
31
|
onClick: _propTypes["default"].func,
|
|
32
|
+
needFocusScope: _propTypes["default"].bool,
|
|
32
33
|
right: _propTypes["default"].number,
|
|
33
34
|
size: _propTypes["default"].oneOf(['mini', 'xmini', 'xsmall', 'small', 'medium', 'large', 'mlarge', 'xlarge', 'xxlarge', 'default']),
|
|
34
35
|
top: _propTypes["default"].number,
|
package/lib/DropDown/DropDown.js
CHANGED
|
@@ -14,8 +14,10 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
14
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
15
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
16
16
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
17
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
17
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
18
18
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
19
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
20
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
19
21
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
20
22
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
21
23
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -23,7 +25,8 @@ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) ===
|
|
|
23
25
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
24
26
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
25
27
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
26
|
-
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['dropdown', 'shadow', 'target', 'menu', 'header', 'headertext', 'list', 'padding', 'listHover', 'active', 'children', 'user', 'footer', 'separator', 'small', 'search', 'medium', 'heading'] }] */
|
|
28
|
+
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['dropdown', 'shadow', 'target', 'menu', 'header', 'headertext', 'list', 'padding', 'listHover', 'active', 'children', 'user', 'footer', 'separator', 'small', 'search', 'medium', 'heading'] }] */
|
|
29
|
+
var DropDown = /*#__PURE__*/function (_React$Component) {
|
|
27
30
|
_inherits(DropDown, _React$Component);
|
|
28
31
|
var _super = _createSuper(DropDown);
|
|
29
32
|
function DropDown() {
|
|
@@ -11,8 +11,10 @@ var _defaultProps = require("./props/defaultProps");
|
|
|
11
11
|
var _DropDownHeadingModule = _interopRequireDefault(require("./DropDownHeading.module.css"));
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
13
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
14
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
14
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
15
15
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
16
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
17
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
16
18
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
17
19
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
18
20
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -11,8 +11,10 @@ var _defaultProps = require("./props/defaultProps");
|
|
|
11
11
|
var _DropDownItemModule = _interopRequireDefault(require("./DropDownItem.module.css"));
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
13
13
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
14
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
14
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
15
15
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
16
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
17
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
16
18
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
17
19
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
18
20
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -12,8 +12,10 @@ var _TextBox = _interopRequireDefault(require("../TextBox/TextBox"));
|
|
|
12
12
|
var _DropDownSearchModule = _interopRequireDefault(require("./DropDownSearch.module.css"));
|
|
13
13
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
14
14
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
15
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
15
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
16
16
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
17
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
18
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
17
19
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
18
20
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
19
21
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -21,7 +23,8 @@ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) ===
|
|
|
21
23
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
22
24
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
23
25
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
24
|
-
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['dropdown', 'menu', 'shadow', 'target', 'header', 'headertext', 'list', 'padding', 'listHover', 'active', 'children', 'user', 'footer', separator, 'small', 'search', 'medium', 'heading', 'listGroup'] }] */
|
|
26
|
+
/* eslint css-modules/no-unused-class: [2, { markAsUsed: ['dropdown', 'menu', 'shadow', 'target', 'header', 'headertext', 'list', 'padding', 'listHover', 'active', 'children', 'user', 'footer', separator, 'small', 'search', 'medium', 'heading', 'listGroup'] }] */
|
|
27
|
+
var DropDownSearch = /*#__PURE__*/function (_React$Component) {
|
|
25
28
|
_inherits(DropDownSearch, _React$Component);
|
|
26
29
|
var _super = _createSuper(DropDownSearch);
|
|
27
30
|
function DropDownSearch(props) {
|
|
@@ -10,8 +10,10 @@ var _propTypes = require("./props/propTypes");
|
|
|
10
10
|
var _DropDownSeparatorModule = _interopRequireDefault(require("./DropDownSeparator.module.css"));
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
12
12
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
13
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
13
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
14
14
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
15
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
16
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
15
17
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
16
18
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
17
19
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|