Fix handleFilterSuggestions return type (#29912)

This commit is contained in:
ksnil
2018-10-23 00:15:51 +08:00
committed by Sheetal Nandi
parent 91bbf4c1b2
commit cbcc683dee
2 changed files with 2 additions and 2 deletions

View File

@@ -19,7 +19,7 @@ export interface ReactTagsProps {
handleDelete: ((i: number) => void);
handleDrag?: ((tag: { id: string; text: string; }, currPos: number, newPos: number) => void);
handleInputChange?: ((value: string) => void);
handleFilterSuggestions?: ((textInputValue: string, possibleSuggestionsArray: Array<{ id: string, text: string }>) => boolean);
handleFilterSuggestions?: ((textInputValue: string, possibleSuggestionsArray: Array<{ id: string, text: string }>) => Array<{ id: string, text: string }>);
handleInputBlur?: ((textInputValue: string) => void);
autofocus?: boolean;

View File

@@ -18,7 +18,7 @@ ReactDOM.render(
handleDelete={(i: number) => console.log("Delete: " + i)}
handleDrag={(tag: { id: string; text: string; }, currPos: number, newPos: number) => console.log("Drag: " + tag.text)}
handleInputChange={(value: string) => console.log("Changed to: ", value)}
handleFilterSuggestions={(textInputValue: string, possibleSuggestionsArray: Array<{ id: string, text: string }>) => true}
handleFilterSuggestions={(textInputValue: string, possibleSuggestionsArray: Array<{ id: string, text: string }>) => suggestions}
handleInputBlur={() => console.log("Blured")}
autofocus={false}