@signalplus/params-about 0.1.42 → 0.1.45

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 (2) hide show
  1. package/lib/es/index.js +7 -7
  2. package/package.json +1 -1
package/lib/es/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Bundle of @signalplus/params-about
3
- * Generated: 2022-04-19
4
- * Version: 0.1.42
3
+ * Generated: 2022-04-24
4
+ * Version: 0.1.45
5
5
  * License: MIT
6
6
  * Author: 2631541504@qq.com
7
7
  */
@@ -467,7 +467,7 @@ var NumCvt = /*#__PURE__*/function () {
467
467
  }, {
468
468
  key: "emit",
469
469
  value: function emit(val, isPercentage) {
470
- if (!val) return undefined;
470
+ if (!val || val === '-') return undefined;
471
471
  if (!isPercentage) return +val;
472
472
  return +Big(val).div(100);
473
473
  }
@@ -514,7 +514,7 @@ var Num = /*#__PURE__*/function (_PureComponent) {
514
514
  }, function () {
515
515
  var _this$props$onChange, _this$props;
516
516
 
517
- if ($val !== '-' && value !== _this.props.value) (_this$props$onChange = (_this$props = _this.props).onChange) === null || _this$props$onChange === void 0 ? void 0 : _this$props$onChange.call(_this$props, value);
517
+ if (value !== _this.props.value) (_this$props$onChange = (_this$props = _this.props).onChange) === null || _this$props$onChange === void 0 ? void 0 : _this$props$onChange.call(_this$props, value);
518
518
  });
519
519
  });
520
520
 
@@ -554,7 +554,7 @@ var Num = /*#__PURE__*/function (_PureComponent) {
554
554
  }], [{
555
555
  key: "getDerivedStateFromProps",
556
556
  value: function getDerivedStateFromProps(props, state) {
557
- if (props.value !== state.preProps.value && parseFloat(state.tempValue) !== props.value) {
557
+ if (props.value !== state.preProps.value && NumCvt.emit(state.tempValue, props.isPercentage) !== props.value) {
558
558
  state.tempValue = NumCvt.show(props.value, props.isPercentage);
559
559
  }
560
560
 
@@ -810,7 +810,7 @@ var Expiries = /*#__PURE__*/function (_PureComponent) {
810
810
 
811
811
  var placeholder = /*#__PURE__*/React.createElement("span", {
812
812
  className: "param-expiries-placeholder"
813
- }, "Choose an expiry");
813
+ }, "Choose");
814
814
 
815
815
  if (this.props.multiple === false) {
816
816
  var _this$props$value2;
@@ -1193,7 +1193,7 @@ var ParamTypeConfig = (_ParamTypeConfig = {}, _defineProperty(_ParamTypeConfig,
1193
1193
  Comp: Expiries,
1194
1194
  validator: expiriesValidator
1195
1195
  }), _defineProperty(_ParamTypeConfig, ParamType.Phone, {
1196
- name: '联系人电话',
1196
+ name: '文本列表',
1197
1197
  key: 'list',
1198
1198
  Comp: TextArray,
1199
1199
  validator: function validator($val) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@signalplus/params-about",
3
- "version": "0.1.42",
3
+ "version": "0.1.45",
4
4
  "description": "A description for the module",
5
5
  "main": "./lib/umd/index.js",
6
6
  "module": "./lib/es/index.js",