diff options
author | Emiliano Ciavatta | 2020-10-16 09:13:21 +0000 |
---|---|---|
committer | Emiliano Ciavatta | 2020-10-16 09:13:21 +0000 |
commit | 2fb8993008752063fa13f253784e9e92552e339d (patch) | |
tree | cf95bee27b217b993008939dd63b83609b0c9796 /frontend/src/components/fields/extensions/NumericField.js | |
parent | af087d327d065c92d454c4e6391a0040d8d527b9 (diff) |
Refactor js files
Diffstat (limited to 'frontend/src/components/fields/extensions/NumericField.js')
-rw-r--r-- | frontend/src/components/fields/extensions/NumericField.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/frontend/src/components/fields/extensions/NumericField.js b/frontend/src/components/fields/extensions/NumericField.js index d4d027d..a6cba26 100644 --- a/frontend/src/components/fields/extensions/NumericField.js +++ b/frontend/src/components/fields/extensions/NumericField.js @@ -15,7 +15,7 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -import React, {Component} from 'react'; +import React, {Component} from "react"; import InputField from "../InputField"; class NumericField extends Component { @@ -35,7 +35,7 @@ class NumericField extends Component { } onChange = (value) => { - value = value.toString().replace(/[^\d]/gi, ''); + value = value.toString().replace(/[^\d]/gi, ""); let intValue = 0; if (value !== "") { intValue = parseInt(value, 10); @@ -53,7 +53,7 @@ class NumericField extends Component { render() { return ( <InputField {...this.props} onChange={this.onChange} defaultValue={this.props.defaultValue || "0"} - invalid={this.state.invalid} /> + invalid={this.state.invalid}/> ); } |