@configuratorware/configurator-admingui 1.56.2 → 1.57.1

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 (163) hide show
  1. package/App/Api.js +12 -8
  2. package/App/Config/app.js +3 -3
  3. package/App/Data.js +11 -9
  4. package/App/ErrorBoundary.js +9 -7
  5. package/App/Main.js +11 -9
  6. package/App/Reducers/Api/Actions.js +1 -0
  7. package/App/Reducers/Entity/Actions.js +4 -4
  8. package/App/Services/WindowCommunication.js +2 -1
  9. package/App/TestHelpers.js +13 -9
  10. package/App/i18n.js +3 -3
  11. package/App/index.js +8 -6
  12. package/App/initServices.js +4 -2
  13. package/Components/CallToActionField.js +30 -19
  14. package/Components/CopyPaste.js +10 -8
  15. package/Components/DefaultForm.js +8 -6
  16. package/Components/DefaultList.js +20 -17
  17. package/Components/DefaultScreen.js +9 -7
  18. package/Components/Form.js +15 -12
  19. package/Components/FormFragments/AttributeValueChip.js +17 -16
  20. package/Components/FormFragments/AutoComplete.js +18 -16
  21. package/Components/FormFragments/AutocompleteEntity.js +16 -14
  22. package/Components/FormFragments/Chip.js +15 -14
  23. package/Components/FormFragments/DynSourceInput.js +9 -7
  24. package/Components/FormFragments/File.js +4 -4
  25. package/Components/FormFragments/InlineAddButton.js +14 -12
  26. package/Components/FormFragments/InputArray.js +18 -16
  27. package/Components/FormFragments/IntlInput.js +17 -13
  28. package/Components/FormFragments/NestedDataComponent.js +15 -13
  29. package/Components/FormFragments/SetInput.js +10 -8
  30. package/Components/FormFragments/SimpleNestedData.js +8 -6
  31. package/Components/FormFragments/SimpleTable.js +13 -11
  32. package/Components/FormFragments/Tabs.js +15 -13
  33. package/Components/FormFragments/TwoSideSelect.js +17 -13
  34. package/Components/GeneralFragments/ConfigurationEditor.js +35 -24
  35. package/Components/GeneralFragments/ConfiguratorOverlay.js +8 -6
  36. package/Components/GeneralFragments/Image.js +10 -8
  37. package/Components/GeneralFragments/MiniPopup.js +11 -9
  38. package/Components/LicenseInfo.js +8 -6
  39. package/Components/List.js +17 -15
  40. package/Components/ListColumnFilter.js +15 -13
  41. package/Components/Menu.js +11 -9
  42. package/Components/ModalContainer.js +9 -7
  43. package/Components/OrderList.js +14 -12
  44. package/Components/Pagination.js +14 -12
  45. package/Components/SearchBar.js +11 -9
  46. package/Components/TranslateComponent.js +14 -11
  47. package/Screens/ApiKeys/Containers/Edit.js +26 -15
  48. package/Screens/Attribute/__tests/AttributeScreen.js +1 -1
  49. package/Screens/AttributeValue/__tests/AttributeValueScreen.js +1 -1
  50. package/Screens/Channel/__tests/ChannelScreen.js +1 -1
  51. package/Screens/ColorPalettes/Components/DefaultColorSwitch.js +9 -7
  52. package/Screens/ColorPalettes/Reducers/Reducer.js +1 -0
  53. package/Screens/ConfigurationTypeEditor/Screen.js +8 -6
  54. package/Screens/ConfigurationWorkflowStatus/Containers/List.js +14 -10
  55. package/Screens/ConfigurationWorkflowStatus/Screen.js +8 -6
  56. package/Screens/Creator/Components/BaseConfigurationEditor.js +15 -11
  57. package/Screens/Creator/Components/CheckData/ApiCalls.js +17 -6
  58. package/Screens/Creator/Components/CheckData/CheckData.js +39 -30
  59. package/Screens/Creator/Components/CheckData/Translations.js +5 -5
  60. package/Screens/Creator/Components/ComponentEditor.js +27 -19
  61. package/Screens/Creator/Components/OptionclassificationEditor.js +49 -39
  62. package/Screens/Creator/Components/Rules/Containers/Edit.js +17 -12
  63. package/Screens/Creator/Components/Rules/Containers/RuleForms/AdditionalOption.js +8 -6
  64. package/Screens/Creator/Components/Rules/Containers/RuleForms/AttributeValueGroupAutoSwitch.js +8 -6
  65. package/Screens/Creator/Components/Rules/Containers/RuleForms/DefaultOption.js +8 -6
  66. package/Screens/Creator/Components/Rules/Containers/RuleForms/ItemAttributeMatch.js +8 -6
  67. package/Screens/Creator/Components/Rules/Containers/RuleForms/ItemAttributeMaxSum.js +8 -6
  68. package/Screens/Creator/Components/Rules/Containers/RuleForms/OptionClassificationMaxAmount.js +8 -6
  69. package/Screens/Creator/Components/Rules/Containers/RuleForms/OptionClassificationMinAmount.js +8 -6
  70. package/Screens/Creator/Components/Rules/Containers/RuleForms/OptionDependency.js +8 -6
  71. package/Screens/Creator/Components/Rules/Containers/RuleForms/OptionExclusion.js +8 -6
  72. package/Screens/Creator/Components/Rules/Containers/RuleForms/OptionMaxAmount.js +8 -6
  73. package/Screens/Creator/Components/Rules/Containers/RuleForms/RuleForm.js +9 -7
  74. package/Screens/Creator/Components/Rules/index.js +8 -6
  75. package/Screens/Creator/Components/VisualizationAndMediaData/ApiCalls.js +18 -7
  76. package/Screens/Creator/Components/VisualizationAndMediaData/Components/ImageEditTools.js +75 -64
  77. package/Screens/Creator/Components/VisualizationAndMediaData/Components/PathStructure.js +1 -1
  78. package/Screens/Creator/Components/VisualizationAndMediaData/VisualizationAndMediaData.js +181 -164
  79. package/Screens/Creator/Containers/Edit.js +19 -15
  80. package/Screens/Creator/Reducers/ConfigurationActions.js +49 -39
  81. package/Screens/Demo/Screen.js +10 -8
  82. package/Screens/DesignProductionMethods/Reducers/DesignProductionMethodsReducer.js +2 -0
  83. package/Screens/Designer/Components/DesignDataTransfer.js +67 -54
  84. package/Screens/Designer/Components/TemplateDefaultList.js +27 -25
  85. package/Screens/Designer/Components/TemplateList.js +14 -12
  86. package/Screens/Designer/Containers/Edit.js +37 -26
  87. package/Screens/Designer/SubScreens/DesignAreas/Components/ColorPalettes.js +22 -18
  88. package/Screens/Designer/SubScreens/DesignAreas/Components/FormArray.js +15 -13
  89. package/Screens/Designer/SubScreens/DesignAreas/Components/MaskEditorField/MaskEditorCanvas.js +27 -19
  90. package/Screens/Designer/SubScreens/DesignAreas/Components/MaskEditorField/MaskEditorField.js +25 -17
  91. package/Screens/Designer/SubScreens/DesignAreas/Components/MaskEditorField/withFileUpload.js +27 -19
  92. package/Screens/Designer/SubScreens/DesignAreas/Containers/FormProductionMethods.js +20 -18
  93. package/Screens/Designer/SubScreens/DesignAreas/Utils/getMaskSrcByType.js +2 -1
  94. package/Screens/Designer/SubScreens/Designviews/Reducers/Actions.js +19 -8
  95. package/Screens/Designer/SubScreens/Visualization/ApiCalls.js +28 -14
  96. package/Screens/Designer/SubScreens/Visualization/Components/AdvancedShapeEditor.js +17 -4
  97. package/Screens/Designer/SubScreens/Visualization/Components/AreaEditor.js +58 -44
  98. package/Screens/Designer/SubScreens/Visualization/Components/DesignAreaDimensionsEditor.js +198 -0
  99. package/Screens/Designer/SubScreens/Visualization/Components/ExpansionContainer.js +9 -7
  100. package/Screens/Designer/SubScreens/Visualization/Components/Three2DEditor.js +88 -62
  101. package/Screens/Designer/SubScreens/Visualization/Components/VisualizationContainer.js +10 -8
  102. package/Screens/Designer/SubScreens/Visualization/Containers/Edit/DataLinks.js +5 -2
  103. package/Screens/Designer/SubScreens/Visualization/Containers/Edit/Edit.js +192 -126
  104. package/Screens/Designer/SubScreens/Visualization/Containers/Edit/VisualizationUtils.js +29 -21
  105. package/Screens/Designer/SubScreens/Visualization/Containers/List.js +21 -6
  106. package/Screens/Designer/SubScreens/Visualization/Translations.js +2 -0
  107. package/Screens/Finder/Reducers/Actions.js +22 -13
  108. package/Screens/Font/Reducers/Actions.js +4 -3
  109. package/Screens/ImageGallery/Containers/Edit.js +8 -6
  110. package/Screens/ImageGallery/Containers/List.js +36 -23
  111. package/Screens/ImageGallery/ImageTags/TagsEditorPopup.js +8 -6
  112. package/Screens/ImageGallery/Reducers/Actions.js +1 -0
  113. package/Screens/ImageGallery/Reducers/Reducer.js +2 -0
  114. package/Screens/Inspirations/Reducers/Actions.js +18 -7
  115. package/Screens/Item/ApiCalls.js +19 -8
  116. package/Screens/Item/Components/AttributeEditorPopup.js +8 -6
  117. package/Screens/Item/Components/CopyCreatorItemDialog.js +26 -15
  118. package/Screens/Item/Components/ExportCreatorItemDialog.js +28 -17
  119. package/Screens/Item/Components/Images/ItemImageUploadDialog.js +31 -22
  120. package/Screens/Item/Components/ImportItemDialog.js +31 -23
  121. package/Screens/Item/Components/ListItemStatusEditor.js +25 -14
  122. package/Screens/Item/Components/Variants/VariantsAutocomplete.js +64 -53
  123. package/Screens/Item/Components/Variants/VariantsEditor.js +28 -26
  124. package/Screens/Item/Components/Variants/VariantsEditorDialog.js +8 -6
  125. package/Screens/Item/Components/Variants/VariantsEditorPopup.js +24 -14
  126. package/Screens/Item/Components/Variants/VariantsSelection.js +13 -11
  127. package/Screens/Item/Components/Variants/VariantsSortFilter.js +18 -16
  128. package/Screens/Item/Containers/Edit.js +31 -21
  129. package/Screens/Item/DataStructures/Prices/ActionHelpers.js +20 -6
  130. package/Screens/Login/Screen.js +15 -12
  131. package/Screens/Login/__tests/LoginScreen.js +2 -2
  132. package/Screens/PriceTypes/Reducers/Reducer.js +2 -0
  133. package/Screens/ProductionView/Components/ConfigurationDataSheet.js +8 -6
  134. package/Screens/ProductionView/Containers/List.js +11 -8
  135. package/Screens/ReceiveOfferRequests/Components/ConfigurationDataSheet.js +8 -6
  136. package/Screens/ReceiveOfferRequests/Containers/List.js +8 -6
  137. package/Screens/Savedconfigurations/Components/ConfigurationDataSheet.js +8 -6
  138. package/Screens/Savedconfigurations/Containers/List.js +15 -10
  139. package/Screens/Setting/Containers/Edit.js +8 -6
  140. package/Screens/TranslationFileHandling/Containers/Edit.js +57 -45
  141. package/Screens/User/__tests/UserScreen.js +1 -1
  142. package/UIComponents/AutoComplete.js +12 -10
  143. package/UIComponents/ChipInput.js +14 -12
  144. package/UIComponents/IconMenu.js +12 -10
  145. package/UIComponents/InlineHelp/index.js +8 -6
  146. package/UIComponents/Pagination.js +12 -10
  147. package/UIComponents/SelectField.js +8 -6
  148. package/UIComponents/Table/Table.js +15 -13
  149. package/UIComponents/Table/TableBody.js +8 -6
  150. package/UIComponents/Table/TableHead.js +8 -6
  151. package/UIComponents/Table/TableRow.js +8 -6
  152. package/Utils/Async/Deferred.js +4 -2
  153. package/Utils/Async/newestRequest.js +23 -14
  154. package/Utils/Decorators/Observable.js +2 -1
  155. package/Utils/FunDraw/createMask.js +17 -7
  156. package/Utils/FunDraw/funDraw.js +71 -54
  157. package/Utils/FunDraw/movableObject.js +21 -12
  158. package/Utils/HOCs/AsyncProps.js +24 -16
  159. package/Utils/HOCs/LocalState.js +11 -9
  160. package/Utils/Request/lazyFetch.js +46 -38
  161. package/default.js +1 -1
  162. package/dev.js +1 -1
  163. package/package.json +3 -3
@@ -8,7 +8,7 @@ var _react = _interopRequireDefault(require("react"));
8
8
  var _lodash = _interopRequireDefault(require("lodash"));
9
9
  var _i18n = require("../../App/i18n");
10
10
  var _propTypes = _interopRequireDefault(require("prop-types"));
11
- var _AutoComplete2 = _interopRequireWildcard(require("../../UIComponents/AutoComplete"));
11
+ var _AutoComplete = _interopRequireWildcard(require("../../UIComponents/AutoComplete"));
12
12
  var _InlineAddButton = require("./InlineAddButton");
13
13
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, "default": e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
14
14
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
@@ -16,29 +16,31 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
16
16
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
17
17
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
18
18
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
19
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
19
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
20
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
21
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
20
22
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
21
23
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
22
24
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
23
25
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
24
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
25
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
26
26
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
27
27
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
28
28
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
29
29
  var AutoComplete = /*#__PURE__*/function (_React$Component) {
30
+ _inherits(AutoComplete, _React$Component);
31
+ var _super = _createSuper(AutoComplete);
30
32
  function AutoComplete() {
31
33
  var _this;
32
34
  _classCallCheck(this, AutoComplete);
33
35
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
34
36
  args[_key] = arguments[_key];
35
37
  }
36
- _this = _callSuper(this, AutoComplete, [].concat(args));
37
- _defineProperty(_this, "element", /*#__PURE__*/_react["default"].createRef());
38
- _defineProperty(_this, "state", {
38
+ _this = _super.call.apply(_super, [this].concat(args));
39
+ _defineProperty(_assertThisInitialized(_this), "element", /*#__PURE__*/_react["default"].createRef());
40
+ _defineProperty(_assertThisInitialized(_this), "state", {
39
41
  searchText: ''
40
42
  });
41
- _defineProperty(_this, "onUpdateInput", function (searchText) {
43
+ _defineProperty(_assertThisInitialized(_this), "onUpdateInput", function (searchText) {
42
44
  if (_lodash["default"].isString(searchText)) {
43
45
  _this.setState({
44
46
  searchText: searchText
@@ -75,7 +77,7 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
75
77
  }
76
78
  }
77
79
  });
78
- _defineProperty(_this, "onNewRequest", function (chosenRequest) {
80
+ _defineProperty(_assertThisInitialized(_this), "onNewRequest", function (chosenRequest) {
79
81
  var _this$props3 = _this.props,
80
82
  pick = _this$props3.pick,
81
83
  onChangePick = _this$props3.onChangePick,
@@ -87,7 +89,7 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
87
89
  onChange(name, _this.mapSelectedData(chosenRequest));
88
90
  }
89
91
  });
90
- _defineProperty(_this, "onBlur", function () {
92
+ _defineProperty(_assertThisInitialized(_this), "onBlur", function () {
91
93
  // when the text is removed, trigger the change event with null value
92
94
  if (!_this.state.searchText && _this.props.value) {
93
95
  var _this$props4 = _this.props,
@@ -98,14 +100,13 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
98
100
  var onBlur = _this.props.onBlur;
99
101
  onBlur && onBlur();
100
102
  });
101
- _defineProperty(_this, "onFocus", function () {
103
+ _defineProperty(_assertThisInitialized(_this), "onFocus", function () {
102
104
  var onFocus = _this.props.onFocus;
103
105
  onFocus && onFocus();
104
106
  });
105
107
  return _this;
106
108
  }
107
- _inherits(AutoComplete, _React$Component);
108
- return _createClass(AutoComplete, [{
109
+ _createClass(AutoComplete, [{
109
110
  key: "componentDidMount",
110
111
  value: function componentDidMount() {
111
112
  this.initSearchText(this.props.value);
@@ -204,7 +205,7 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
204
205
  error = _this$props7.error;
205
206
  var onBlur = this.onBlur,
206
207
  onFocus = this.onFocus;
207
- return /*#__PURE__*/_react["default"].createElement(_AutoComplete2["default"], {
208
+ return /*#__PURE__*/_react["default"].createElement(_AutoComplete["default"], {
208
209
  ref: this.element,
209
210
  floatingLabelText: label,
210
211
  dataSource: source,
@@ -217,15 +218,16 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
217
218
  maxSearchResults: maxSearchResults,
218
219
  onFocus: onFocus,
219
220
  onBlur: onBlur,
220
- filter: autoLoad === false ? _AutoComplete2.Filters.defaultFilter : _AutoComplete2.Filters.fuzzyFilter,
221
+ filter: autoLoad === false ? _AutoComplete.Filters.defaultFilter : _AutoComplete.Filters.fuzzyFilter,
221
222
  placeholder: placeholder && (0, _i18n.t)(placeholder),
222
223
  error: error
223
224
  });
224
225
  }
225
226
  }]);
227
+ return AutoComplete;
226
228
  }(_react["default"].Component);
227
229
  _defineProperty(AutoComplete, "propTypes", {
228
- sourceConfig: _AutoComplete2.propTypes.dataSourceConfig,
230
+ sourceConfig: _AutoComplete.propTypes.dataSourceConfig,
229
231
  value: _propTypes["default"].string,
230
232
  getSearchText: _propTypes["default"].func,
231
233
  source: _propTypes["default"].array,
@@ -18,25 +18,27 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
18
18
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
19
19
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
20
20
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
21
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
21
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
22
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
23
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
22
24
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
23
25
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
24
26
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
25
27
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
26
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
27
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
28
28
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
29
29
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
30
30
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
31
31
  var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
32
+ _inherits(AutocompleteEntity, _React$Component);
33
+ var _super = _createSuper(AutocompleteEntity);
32
34
  function AutocompleteEntity() {
33
35
  var _this;
34
36
  _classCallCheck(this, AutocompleteEntity);
35
37
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
36
38
  args[_key] = arguments[_key];
37
39
  }
38
- _this = _callSuper(this, AutocompleteEntity, [].concat(args));
39
- _defineProperty(_this, "state", {
40
+ _this = _super.call.apply(_super, [this].concat(args));
41
+ _defineProperty(_assertThisInitialized(_this), "state", {
40
42
  searchText: ''
41
43
  });
42
44
  /**
@@ -44,7 +46,7 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
44
46
  * @param chosenRequest
45
47
  * @param index
46
48
  */
47
- _defineProperty(_this, "onNewRequest", function (chosenRequest, index) {
49
+ _defineProperty(_assertThisInitialized(_this), "onNewRequest", function (chosenRequest, index) {
48
50
  if (chosenRequest !== null && index !== -1) {
49
51
  _this.props.loadEntity(chosenRequest);
50
52
  }
@@ -54,7 +56,7 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
54
56
  * otherwise acts like a text field and triggers the onChange event
55
57
  * @param searchText
56
58
  */
57
- _defineProperty(_this, "onUpdateInput", function (searchText) {
59
+ _defineProperty(_assertThisInitialized(_this), "onUpdateInput", function (searchText) {
58
60
  _this.loaded = false;
59
61
  if (_lodash["default"].isString(searchText)) {
60
62
  _this.setState({
@@ -77,7 +79,7 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
77
79
  onChange(name, searchText);
78
80
  }
79
81
  });
80
- _defineProperty(_this, "reloadSource", _lodash["default"].debounce(function (query) {
82
+ _defineProperty(_assertThisInitialized(_this), "reloadSource", _lodash["default"].debounce(function (query) {
81
83
  if (!_this.props.autoLoad) {
82
84
  var params = {
83
85
  query: query
@@ -88,7 +90,7 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
88
90
  _this.props.loadSource(params);
89
91
  }
90
92
  }, 300));
91
- _defineProperty(_this, "waitIfLoading", function (fn) {
93
+ _defineProperty(_assertThisInitialized(_this), "waitIfLoading", function (fn) {
92
94
  if (_this.props.loading) {
93
95
  _this.onListLoaded = fn;
94
96
  } else {
@@ -99,27 +101,26 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
99
101
  * Act like a text field, triggers the change event with the new value
100
102
  * @param e
101
103
  */
102
- _defineProperty(_this, "onBlur", function () {
104
+ _defineProperty(_assertThisInitialized(_this), "onBlur", function () {
103
105
  _this.waitIfLoading(function (props) {
104
106
  _this.handle(props);
105
107
  });
106
108
  });
107
- _defineProperty(_this, "onKeyDown", function (e) {
109
+ _defineProperty(_assertThisInitialized(_this), "onKeyDown", function (e) {
108
110
  if (e.keyCode === 9 || e.keyCode === 13) {
109
111
  _this.waitIfLoading(function (props) {
110
112
  _this.handle(props);
111
113
  });
112
114
  }
113
115
  });
114
- _defineProperty(_this, "onClose", function () {
116
+ _defineProperty(_assertThisInitialized(_this), "onClose", function () {
115
117
  _this.waitIfLoading(function (props) {
116
118
  _this.handle(props);
117
119
  });
118
120
  });
119
121
  return _this;
120
122
  }
121
- _inherits(AutocompleteEntity, _React$Component);
122
- return _createClass(AutocompleteEntity, [{
123
+ _createClass(AutocompleteEntity, [{
123
124
  key: "componentDidMount",
124
125
  value: function componentDidMount() {
125
126
  this.setState({
@@ -193,6 +194,7 @@ var AutocompleteEntity = /*#__PURE__*/function (_React$Component) {
193
194
  });
194
195
  }
195
196
  }]);
197
+ return AutocompleteEntity;
196
198
  }(_react["default"].Component);
197
199
  _defineProperty(AutocompleteEntity, "propTypes", {
198
200
  sourceConfig: _AutoComplete.propTypes.dataSourceConfig,
@@ -13,36 +13,37 @@ var _i18n = require("../../App/i18n");
13
13
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, "default": e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
14
14
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
15
15
  function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
16
- function _readOnlyError(r) { throw new TypeError('"' + r + '" is read-only'); }
17
16
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
18
17
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
19
18
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
20
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
19
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
20
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
21
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
21
22
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
22
23
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
23
24
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
24
25
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
25
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
26
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
27
26
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
28
27
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
29
28
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
30
29
  var Chip = /*#__PURE__*/function (_React$Component) {
30
+ _inherits(Chip, _React$Component);
31
+ var _super = _createSuper(Chip);
31
32
  function Chip() {
32
33
  var _this;
33
34
  _classCallCheck(this, Chip);
34
35
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
35
36
  args[_key] = arguments[_key];
36
37
  }
37
- _this = _callSuper(this, Chip, [].concat(args));
38
- _defineProperty(_this, "state", {
38
+ _this = _super.call.apply(_super, [this].concat(args));
39
+ _defineProperty(_assertThisInitialized(_this), "state", {
39
40
  placeholder: ''
40
41
  });
41
- _defineProperty(_this, "loadSourceDebounced", _lodash["default"].debounce(_this.loadSource, 300));
42
- _defineProperty(_this, "onUpdateInput", function (query) {
42
+ _defineProperty(_assertThisInitialized(_this), "loadSourceDebounced", _lodash["default"].debounce(_this.loadSource, 300));
43
+ _defineProperty(_assertThisInitialized(_this), "onUpdateInput", function (query) {
43
44
  _this.loadSourceDebounced(query);
44
45
  });
45
- _defineProperty(_this, "onRequestAdd", function (chip) {
46
+ _defineProperty(_assertThisInitialized(_this), "onRequestAdd", function (chip) {
46
47
  var _this$props = _this.props,
47
48
  name = _this$props.name,
48
49
  source = _this$props.source,
@@ -72,7 +73,7 @@ var Chip = /*#__PURE__*/function (_React$Component) {
72
73
  items.push(item);
73
74
  onChange(name, items);
74
75
  });
75
- _defineProperty(_this, "onRequestDelete", function (text, idx) {
76
+ _defineProperty(_assertThisInitialized(_this), "onRequestDelete", function (text, idx) {
76
77
  var _this$props2 = _this.props,
77
78
  name = _this$props2.name,
78
79
  onChange = _this$props2.onChange,
@@ -83,7 +84,7 @@ var Chip = /*#__PURE__*/function (_React$Component) {
83
84
  onChange(name, items);
84
85
  }
85
86
  });
86
- _defineProperty(_this, "onFocus", function (evt) {
87
+ _defineProperty(_assertThisInitialized(_this), "onFocus", function (evt) {
87
88
  _this.loadInitialSource();
88
89
  var _this$props3 = _this.props,
89
90
  onFocus = _this$props3.onFocus,
@@ -93,7 +94,7 @@ var Chip = /*#__PURE__*/function (_React$Component) {
93
94
  });
94
95
  onFocus && onFocus(evt);
95
96
  });
96
- _defineProperty(_this, "onBlur", function (evt) {
97
+ _defineProperty(_assertThisInitialized(_this), "onBlur", function (evt) {
97
98
  var _this$props4 = _this.props,
98
99
  placeholder = _this$props4.placeholder,
99
100
  onBlur = _this$props4.onBlur;
@@ -104,8 +105,7 @@ var Chip = /*#__PURE__*/function (_React$Component) {
104
105
  });
105
106
  return _this;
106
107
  }
107
- _inherits(Chip, _React$Component);
108
- return _createClass(Chip, [{
108
+ _createClass(Chip, [{
109
109
  key: "loadInitialSource",
110
110
  value: function loadInitialSource() {
111
111
  var _this$props5 = this.props,
@@ -183,6 +183,7 @@ var Chip = /*#__PURE__*/function (_React$Component) {
183
183
  });
184
184
  }
185
185
  }]);
186
+ return Chip;
186
187
  }(_react["default"].Component);
187
188
  _defineProperty(Chip, "propTypes", {
188
189
  sourceConfig: _ChipInput.propTypes.dataSourceConfig
@@ -18,26 +18,28 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
18
18
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
19
19
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
20
20
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
21
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
21
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
22
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
23
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
22
24
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
23
25
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
24
26
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
25
27
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
26
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
27
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
28
28
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
29
29
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
30
30
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
31
31
  var dynSourceInput = function dynSourceInput(InputComponent) {
32
32
  var DynSourceInput = /*#__PURE__*/function (_React$Component) {
33
+ _inherits(DynSourceInput, _React$Component);
34
+ var _super = _createSuper(DynSourceInput);
33
35
  function DynSourceInput() {
34
36
  var _this;
35
37
  _classCallCheck(this, DynSourceInput);
36
38
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
37
39
  args[_key] = arguments[_key];
38
40
  }
39
- _this = _callSuper(this, DynSourceInput, [].concat(args));
40
- _defineProperty(_this, "loadSource", function (params) {
41
+ _this = _super.call.apply(_super, [this].concat(args));
42
+ _defineProperty(_assertThisInitialized(_this), "loadSource", function (params) {
41
43
  var _this$props = _this.props,
42
44
  loadSource = _this$props.loadSource,
43
45
  locale = _this$props.locale,
@@ -54,8 +56,7 @@ var dynSourceInput = function dynSourceInput(InputComponent) {
54
56
  });
55
57
  return _this;
56
58
  }
57
- _inherits(DynSourceInput, _React$Component);
58
- return _createClass(DynSourceInput, [{
59
+ _createClass(DynSourceInput, [{
59
60
  key: "componentWillMount",
60
61
  value: function componentWillMount() {
61
62
  var dynSource = this.props.dynSource;
@@ -96,6 +97,7 @@ var dynSourceInput = function dynSourceInput(InputComponent) {
96
97
  })) : /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(InputComponent, props));
97
98
  }
98
99
  }]);
100
+ return DynSourceInput;
99
101
  }(_react["default"].Component);
100
102
  _defineProperty(DynSourceInput, "defaultProps", {
101
103
  listKey: '',
@@ -98,7 +98,7 @@ var getFilenameFromPath = function getFilenameFromPath(path) {
98
98
  var getPreviewImagePath = function getPreviewImagePath(path) {
99
99
  return path ? _network["default"].basePath.replace(/\/$/, '') + path : '';
100
100
  };
101
- var _File = function File(props) {
101
+ var File = function File(props) {
102
102
  var _props$isPreviewRequi = props.isPreviewRequired,
103
103
  isPreviewRequired = _props$isPreviewRequi === void 0 ? false : _props$isPreviewRequi,
104
104
  _props$deleteEnabled = props.deleteEnabled,
@@ -158,7 +158,7 @@ var _File = function File(props) {
158
158
  ref: dropZone
159
159
  }, /*#__PURE__*/_react["default"].createElement("div", {
160
160
  className: classes.uploader
161
- }, /*#__PURE__*/_react["default"].createElement("span", null, (0, _i18n.T)(props.dropZoneLabel), props.dropZoneLabel === _File.defaultProps.dropZoneLabel && props.accept), /*#__PURE__*/_react["default"].createElement(_RaisedButton["default"], {
161
+ }, /*#__PURE__*/_react["default"].createElement("span", null, (0, _i18n.T)(props.dropZoneLabel), props.dropZoneLabel === File.defaultProps.dropZoneLabel && props.accept), /*#__PURE__*/_react["default"].createElement(_RaisedButton["default"], {
162
162
  className: classes.button
163
163
  }, /*#__PURE__*/_react["default"].createElement("span", null, /*#__PURE__*/_react["default"].createElement(_FolderIcon["default"], {
164
164
  className: classes.folderIcon
@@ -200,7 +200,7 @@ var _File = function File(props) {
200
200
  className: classes.warningText
201
201
  }, props.warningMessage)));
202
202
  };
203
- _File.defaultProps = {
203
+ File.defaultProps = {
204
204
  onChange: function onChange() {},
205
205
  isPreviewRequired: false,
206
206
  deleteEnabled: false,
@@ -210,4 +210,4 @@ _File.defaultProps = {
210
210
  dropZoneLabel: 'dragDropFile',
211
211
  uploadButtonLabel: 'Upload file'
212
212
  };
213
- var _default = exports["default"] = (0, _styles.withStyles)(styles)(_File);
213
+ var _default = exports["default"] = (0, _styles.withStyles)(styles)(File);
@@ -19,13 +19,13 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
19
19
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
20
20
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
21
21
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
22
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
22
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
23
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
24
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
23
25
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
24
26
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
25
27
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
26
28
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
27
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
28
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
29
29
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
30
30
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
31
31
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
@@ -63,32 +63,34 @@ var withAddButton = exports.withAddButton = function withAddButton(Component) {
63
63
  // map dispatch to props
64
64
  function () {
65
65
  return {};
66
- })(/*#__PURE__*/function (_React$Component) {
66
+ })( /*#__PURE__*/function (_React$Component) {
67
+ _inherits(InlineAddWrapper, _React$Component);
68
+ var _super = _createSuper(InlineAddWrapper);
67
69
  function InlineAddWrapper() {
68
70
  var _this;
69
71
  _classCallCheck(this, InlineAddWrapper);
70
72
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
71
73
  args[_key] = arguments[_key];
72
74
  }
73
- _this = _callSuper(this, InlineAddWrapper, [].concat(args));
74
- _defineProperty(_this, "state", {
75
+ _this = _super.call.apply(_super, [this].concat(args));
76
+ _defineProperty(_assertThisInitialized(_this), "state", {
75
77
  showAddButton: false
76
78
  });
77
- _defineProperty(_this, "onFocus", function () {
79
+ _defineProperty(_assertThisInitialized(_this), "onFocus", function () {
78
80
  if (_this.props.addButton && (realEmpty(_this.props.value) || _this.props.addButton.multiple)) {
79
81
  _this.setState({
80
82
  showAddButton: true
81
83
  });
82
84
  }
83
85
  });
84
- _defineProperty(_this, "onBlur", function () {
86
+ _defineProperty(_assertThisInitialized(_this), "onBlur", function () {
85
87
  if (_this.state.showAddButton) {
86
88
  _this.setState({
87
89
  showAddButton: false
88
90
  });
89
91
  }
90
92
  });
91
- _defineProperty(_this, "onChange", function (name, value) {
93
+ _defineProperty(_assertThisInitialized(_this), "onChange", function (name, value) {
92
94
  var onChange = _this.props.onChange;
93
95
  onChange(name, value);
94
96
  if (_this.props.addButton && (realEmpty(value) || _this.props.addButton.multiple)) {
@@ -97,7 +99,7 @@ var withAddButton = exports.withAddButton = function withAddButton(Component) {
97
99
  });
98
100
  }
99
101
  });
100
- _defineProperty(_this, "onAddAction", function () {
102
+ _defineProperty(_assertThisInitialized(_this), "onAddAction", function () {
101
103
  var _this$props = _this.props,
102
104
  onAction = _this$props.onAction,
103
105
  addButton = _this$props.addButton;
@@ -112,8 +114,7 @@ var withAddButton = exports.withAddButton = function withAddButton(Component) {
112
114
  });
113
115
  return _this;
114
116
  }
115
- _inherits(InlineAddWrapper, _React$Component);
116
- return _createClass(InlineAddWrapper, [{
117
+ _createClass(InlineAddWrapper, [{
117
118
  key: "componentWillReceiveProps",
118
119
  value: function componentWillReceiveProps(props) {
119
120
  if (props.selectData && props.selectData.ready && props.selectData !== this.props.selectData) {
@@ -156,5 +157,6 @@ var withAddButton = exports.withAddButton = function withAddButton(Component) {
156
157
  }));
157
158
  }
158
159
  }]);
160
+ return InlineAddWrapper;
159
161
  }(_react["default"].Component));
160
162
  };
@@ -22,31 +22,33 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
22
22
  function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
23
23
  function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
24
24
  function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
25
- function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
25
+ function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
26
+ function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
27
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
26
28
  function _possibleConstructorReturn(t, e) { if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); return _assertThisInitialized(t); }
27
29
  function _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); return e; }
28
30
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
29
31
  function _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }
30
- function _inherits(t, e) { if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); }
31
- function _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }
32
32
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
33
33
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
34
34
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
35
35
  var InputArray = /*#__PURE__*/function (_Component) {
36
+ _inherits(InputArray, _Component);
37
+ var _super = _createSuper(InputArray);
36
38
  function InputArray(props) {
37
39
  var _this;
38
40
  _classCallCheck(this, InputArray);
39
- _this = _callSuper(this, InputArray, [props]);
40
- _defineProperty(_this, "validatorCallback", function () {
41
+ _this = _super.call(this, props);
42
+ _defineProperty(_assertThisInitialized(_this), "validatorCallback", function () {
41
43
  if (_this.state.showEditor) {
42
44
  return _this.setData();
43
45
  }
44
46
  return true;
45
47
  });
46
- _defineProperty(_this, "onRowSelection", function (rows) {
48
+ _defineProperty(_assertThisInitialized(_this), "onRowSelection", function (rows) {
47
49
  var schema = _this.props.schema;
48
50
  schema.reset({
49
- active: rows.length !== 0 && _this
51
+ active: rows.length !== 0 && _assertThisInitialized(_this)
50
52
  });
51
53
  if (rows.length !== 0) {
52
54
  var selectedRow = rows[0];
@@ -63,7 +65,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
63
65
  }
64
66
  }
65
67
  });
66
- _defineProperty(_this, "setData", function () {
68
+ _defineProperty(_assertThisInitialized(_this), "setData", function () {
67
69
  var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
68
70
  var _options$updateOnly = options.updateOnly,
69
71
  updateOnly = _options$updateOnly === void 0 ? false : _options$updateOnly;
@@ -116,7 +118,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
116
118
  }
117
119
  return false;
118
120
  });
119
- _defineProperty(_this, "onCancel", function () {
121
+ _defineProperty(_assertThisInitialized(_this), "onCancel", function () {
120
122
  var schema = _this.props.schema;
121
123
  schema.reset();
122
124
  _this.setState({
@@ -126,7 +128,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
126
128
  validationErrors: false
127
129
  });
128
130
  });
129
- _defineProperty(_this, "onDelete", function (row) {
131
+ _defineProperty(_assertThisInitialized(_this), "onDelete", function (row) {
130
132
  var _this$props2 = _this.props,
131
133
  name = _this$props2.name,
132
134
  value = _this$props2.value;
@@ -140,7 +142,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
140
142
  validationErrors: false
141
143
  });
142
144
  });
143
- _defineProperty(_this, "addNewItem", function () {
145
+ _defineProperty(_assertThisInitialized(_this), "addNewItem", function () {
144
146
  if (_this.state.showEditor) {
145
147
  if (!_this.setData()) {
146
148
  return;
@@ -148,7 +150,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
148
150
  }
149
151
  var schema = _this.props.schema;
150
152
  schema.reset({
151
- active: _this
153
+ active: _assertThisInitialized(_this)
152
154
  });
153
155
  _this.setState(function (state) {
154
156
  return {
@@ -158,7 +160,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
158
160
  };
159
161
  });
160
162
  });
161
- _defineProperty(_this, "renderAddButton", function () {
163
+ _defineProperty(_assertThisInitialized(_this), "renderAddButton", function () {
162
164
  var addButtonLabel = _this.props.array.addButtonLabel || 'Add';
163
165
  var label = _lodash["default"].isString(addButtonLabel) ? (0, _i18n.T)(addButtonLabel) : addButtonLabel;
164
166
  return !_this.isAddingDisabled() && /*#__PURE__*/_react["default"].createElement(_RaisedButton["default"], {
@@ -167,7 +169,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
167
169
  color: "secondary"
168
170
  }, /*#__PURE__*/_react["default"].createElement(_AddIcon["default"], null), label);
169
171
  });
170
- _defineProperty(_this, "renderCancelButton", function () {
172
+ _defineProperty(_assertThisInitialized(_this), "renderCancelButton", function () {
171
173
  var addMode = _this.state.selectedRow === false;
172
174
  if (addMode && _this.state.showEditor) {
173
175
  return /*#__PURE__*/_react["default"].createElement(_RaisedButton["default"], {
@@ -185,8 +187,7 @@ var InputArray = /*#__PURE__*/function (_Component) {
185
187
  };
186
188
  return _this;
187
189
  }
188
- _inherits(InputArray, _Component);
189
- return _createClass(InputArray, [{
190
+ _createClass(InputArray, [{
190
191
  key: "componentWillMount",
191
192
  value: function componentWillMount() {
192
193
  var _this2 = this;
@@ -291,5 +292,6 @@ var InputArray = /*#__PURE__*/function (_Component) {
291
292
  }, this.renderAddButton())));
292
293
  }
293
294
  }]);
295
+ return InputArray;
294
296
  }(_react.Component);
295
297
  var _default = exports["default"] = (0, _NestedDataComponent["default"])((0, _ValidatorCallbackProvider.withValidatorCallbackContext)(InputArray));