Merge pull request #3957 from jasongitmail/step-any-fix

Fix input number step
This commit is contained in:
Alexandre BODIN 2019-09-20 09:44:25 +02:00 committed by GitHub
commit 234c20a73d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -28,7 +28,7 @@ function InputNumber(props) {
onFocus={props.onFocus}
placeholder={message}
ref={props.inputRef}
step={!Number.isNaN(Number(props.step)) ? Number(props.step) : 1}
step={props.step}
style={props.style}
tabIndex={props.tabIndex}
type="number"
@ -49,7 +49,7 @@ InputNumber.defaultProps = {
onBlur: () => {},
onFocus: () => {},
placeholder: 'app.utils.placeholder.defaultMessage',
step: 1,
step: 'any',
style: {},
tabIndex: '0',
};

View File

@ -165,7 +165,7 @@ InputNumberWithErrors.defaultProps = {
labelStyle: {},
noErrorsDescription: false,
placeholder: 'app.utils.placeholder.defaultMessage',
step: 1,
step: 'any',
style: {},
tabIndex: '0',
validations: {},