diff --git a/src/core/utils.js b/src/core/utils.js index 90f3cf22..3ea31662 100644 --- a/src/core/utils.js +++ b/src/core/utils.js @@ -453,13 +453,13 @@ export const propChecker = (props, nextProps, objectList=[], ignoreList=[]) => { } const validateNumber = ( val ) => { - if ( !/^\d+(.?\d+)?$/.test(val)) { + if ( !/^-?\d+(.?\d+)?$/.test(val)) { return "Value must be a number" } } const validateInteger = ( val ) => { - if ( !/^\d+$/.test(val)) { + if ( !/^-?\d+$/.test(val)) { return "Value must be integer" } }