Update prop types on RangeArgInput (#31654) (#31722)

* Added string as value prop type in range arg input

* Added string as value prop type in range arg input
This commit is contained in:
Catherine Liu 2019-02-21 11:55:55 -07:00 committed by GitHub
parent bab832593c
commit 49d2008cb9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -23,7 +23,7 @@ const RangeArgInput = ({ typeInstance, onValueChange, argValue }) => {
step={step}
showLabels
showInput
value={`${argValue}`}
value={argValue}
onChange={handleChange}
/>
);
@ -31,7 +31,7 @@ const RangeArgInput = ({ typeInstance, onValueChange, argValue }) => {
RangeArgInput.propTypes = {
onValueChange: PropTypes.func.isRequired,
argValue: PropTypes.number.isRequired,
argValue: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired,
typeInstance: PropTypes.shape({
options: PropTypes.shape({
min: PropTypes.number.isRequired,