restrict characters in input field react