diff --git a/components/autocomplete/Autocomplete.js b/components/autocomplete/Autocomplete.js index fae68208..10032445 100644 --- a/components/autocomplete/Autocomplete.js +++ b/components/autocomplete/Autocomplete.js @@ -91,9 +91,9 @@ const factory = (Chip, Input) => { ); }; - handleQueryBlur = () => { + handleQueryBlur = (event) => { if (this.state.focus) this.setState({focus: false}); - if (this.props.onBlur) this.props.onBlur(); + if (this.props.onBlur) this.props.onBlur(event); }; handleQueryChange = (value) => { diff --git a/lib/autocomplete/Autocomplete.js b/lib/autocomplete/Autocomplete.js index 5fa0e59e..11922c99 100644 --- a/lib/autocomplete/Autocomplete.js +++ b/lib/autocomplete/Autocomplete.js @@ -86,9 +86,9 @@ var factory = function factory(Chip, Input) { _this.setState({ focus: false, query: query, showAllSuggestions: _this.props.showSuggestionsWhenValueIsSet }, function () { _reactDom2.default.findDOMNode(_this).querySelector('input').blur(); }); - }, _this.handleQueryBlur = function () { + }, _this.handleQueryBlur = function (event) { if (_this.state.focus) _this.setState({ focus: false }); - if (_this.props.onBlur) _this.props.onBlur(); + if (_this.props.onBlur) _this.props.onBlur(event); }, _this.handleQueryChange = function (value) { _this.setState({ query: value, showAllSuggestions: false }); }, _this.handleQueryFocus = function () { diff --git a/lib/autocomplete/index.d.ts b/lib/autocomplete/index.d.ts index 2826c62d..b2c560d0 100644 --- a/lib/autocomplete/index.d.ts +++ b/lib/autocomplete/index.d.ts @@ -81,7 +81,7 @@ interface AutocompleteProps extends ReactToolbox.Props { * If true, the list of suggestions will not be filtered when a value is selected. * @default false */ - showSuggestionsWHenValueIsSet?: boolean; + showSuggestionsWhenValueIsSet?: boolean; /** * Object of key/values or array representing all items suggested. */