@configuratorware/configurator-admingui 1.47.2 → 1.47.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/App/Data.js CHANGED
@@ -46,7 +46,7 @@ _validate.validate.validators.identifier = function (value, options) {
46
46
  return (0, _i18n.t)('customValidators.identifier');
47
47
  };
48
48
  _validate.validate.validators.decimalPoint = function (value, options) {
49
- if (options === true && (!value || !value.length || /^[\d]+\.?[\d]*$/.test(value))) {
49
+ if (options === true && (!value || !value.length || /^[-\d]+\.?[\d]*$/.test(value))) {
50
50
  return null;
51
51
  }
52
52
  return (0, _i18n.t)('customValidators.decimalPoint');
@@ -140,7 +140,7 @@ var AutoComplete = /*#__PURE__*/function (_React$Component) {
140
140
  var idx = sourceConfig ? _lodash["default"].findIndex(source, function (item) {
141
141
  return '' + item[sourceConfig.value] === '' + value;
142
142
  }) : false;
143
- searchText = sourceConfig ? idx > -1 ? source[idx][sourceConfig.text] : value : value || '';
143
+ searchText = sourceConfig ? idx > -1 ? _lodash["default"].isFunction(sourceConfig.text) ? sourceConfig.text(source[idx]) : source[idx][sourceConfig.text] : value : value || '';
144
144
  }
145
145
  this.setState({
146
146
  searchText: searchText
@@ -50,6 +50,9 @@ var LocalizedPriceTextField = exports.LocalizedPriceTextField = function Localiz
50
50
 
51
51
  // remove all separators but the first one
52
52
  localizedValue = (0, _Utils.removeDuplicateRegexMatchesExceptFirst)(localizedValue, new RegExp("\\".concat(defaultSeparator), 'g'));
53
+
54
+ // remove all "-" but the first one
55
+ localizedValue = (0, _Utils.removeDuplicateRegexMatchesExceptFirst)(localizedValue, new RegExp('\\-', 'g'));
53
56
  props.onChange(name, localizedValue);
54
57
  };
55
58
  var displayValue = localeSeparator === altSeparator ? "".concat(value || '').replace(defaultSeparator, localeSeparator) : localeSeparator === defaultSeparator ? "".concat(value || '').replace(altSeparator, localeSeparator) : value;
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@configuratorware/configurator-admingui",
3
- "version": "1.47.2",
3
+ "version": "1.47.4",
4
4
  "license": "UNLICENSED",
5
5
  "private": false,
6
6
  "dependencies": {
7
7
  "@babel/polyfill": "^7.12.1",
8
- "@configuratorware/scripts": "1.47.2",
8
+ "@configuratorware/scripts": "1.47.4",
9
9
  "@material-ui/core": "^3.9.4",
10
10
  "@material-ui/icons": "^3.0.2",
11
11
  "@tweenjs/tween.js": "^17.6.0",
@@ -28,7 +28,7 @@
28
28
  "react-redux-i18n": "^1.9.3",
29
29
  "react-router": "^3.2.6",
30
30
  "react-sortable-hoc": "^1.11.0",
31
- "redhotmagma-visualization": "1.47.2",
31
+ "redhotmagma-visualization": "1.47.4",
32
32
  "redux": "^4.1.0",
33
33
  "redux-logger": "^3.0.6",
34
34
  "redux-persist": "^5.10.0",