From d6537c1b23e55497025ab8cc4b07e724e789dfe0 Mon Sep 17 00:00:00 2001 From: Mathias Vestergaard Date: Sat, 18 Jan 2020 21:36:49 +0100 Subject: [PATCH] Add missing 'clear' reason to useAutocomplete.onInputChange typing --- .../src/useAutocomplete/useAutocomplete.d.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/material-ui-lab/src/useAutocomplete/useAutocomplete.d.ts b/packages/material-ui-lab/src/useAutocomplete/useAutocomplete.d.ts index bbec125ba98470..18aae9a3b929e3 100644 --- a/packages/material-ui-lab/src/useAutocomplete/useAutocomplete.d.ts +++ b/packages/material-ui-lab/src/useAutocomplete/useAutocomplete.d.ts @@ -137,7 +137,11 @@ export interface UseAutocompleteCommonProps { * @param {string} value The new value of the text input. * @param {string} reason Can be: "input" (user input), "reset" (programmatic change), `"clear"`. */ - onInputChange?: (event: React.ChangeEvent<{}>, value: string, reason: 'input' | 'reset') => void; + onInputChange?: ( + event: React.ChangeEvent<{}>, + value: string, + reason: 'input' | 'reset' | 'clear', + ) => void; /** * Callback fired when the popup requests to be opened. * Use in controlled mode (see open).