react-currency-input
Advanced tools
Comparing version 1.0.4 to 1.0.5
@@ -34,3 +34,4 @@ 'use strict'; | ||
thousandSeparator: _react.PropTypes.string, | ||
precision: _react.PropTypes.oneOfType([_react.PropTypes.number, _react.PropTypes.string]) | ||
precision: _react.PropTypes.oneOfType([_react.PropTypes.number, _react.PropTypes.string]), | ||
inputType: _react.PropTypes.string | ||
}, | ||
@@ -52,3 +53,4 @@ | ||
thousandSeparator: ",", | ||
precision: "2" | ||
precision: "2", | ||
inputType: "text" | ||
}; | ||
@@ -72,2 +74,3 @@ }, | ||
delete customProps.precision; | ||
delete customProps.inputType; | ||
return { | ||
@@ -94,2 +97,3 @@ maskedValue: (0, _mask2.default)(this.props.value, this.props.precision, this.props.decimalSeparator, this.props.thousandSeparator), | ||
delete customProps.precision; | ||
delete customProps.inputType; | ||
this.setState({ | ||
@@ -130,3 +134,3 @@ maskedValue: (0, _mask2.default)(nextProps.value, nextProps.precision, nextProps.decimalSeparator, nextProps.thousandSeparator), | ||
return _react2.default.createElement('input', _extends({ | ||
type: 'text', | ||
type: this.props.inputType, | ||
value: this.state.maskedValue, | ||
@@ -133,0 +137,0 @@ onChange: this.handleChange |
{ | ||
"name": "react-currency-input", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "React component for inputing currency amounts", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -103,3 +103,4 @@ # react-currency-input | ||
| thousandSeparator | ',' | The thousand separator | | ||
| inputType | "text" | Input field tag type. You may want to use `number` or `tel` | | ||
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12371
161
106