(event: SyntheticEvent<T, InputEvent>)
| 56 | }, [inputRef]); |
| 57 | |
| 58 | const onInput = (event: SyntheticEvent<T, InputEvent>): void => { |
| 59 | clearIdleTimeout(); |
| 60 | baseOnInput(event); |
| 61 | if (valueChanged) { |
| 62 | valueChanged(event.currentTarget.value); |
| 63 | } |
| 64 | const len = event.currentTarget.value.length; |
| 65 | setInputLength(len); |
| 66 | const inputValidity = inputRef.current?.checkValidity(); |
| 67 | |
| 68 | if (inputValidity) { |
| 69 | setValidInput(true); |
| 70 | } else { |
| 71 | idleTimeout(); |
| 72 | } |
| 73 | }; |
| 74 | |
| 75 | useEffect(() => { |
| 76 | if (validInput !== undefined) { |
nothing calls this directly
no outgoing calls
no test coverage detected