Skip to content

Commit

Permalink
chore(release): version 2.13.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ro-ka committed Jun 19, 2020
1 parent 103a363 commit 03e647b
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 15 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
### 2.13.1 (2020-06-19)


#### Bug Fixes

* use secure URLs (#465) ([86ec9227](https://github.com/ubilabs/react-geosuggest/commit/86ec922751c841293540e5396ce6f201b6149112))
* use a not random id for the list (#464) ([68da464e](https://github.com/ubilabs/react-geosuggest/commit/68da464e26db7af24a742973df523b4909a1ef10))


## 2.13.0 (2020-05-08)


Expand Down
23 changes: 11 additions & 12 deletions dist/react-geosuggest.js
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,6 @@ var Geosuggest = (function (React) {
'formNoValidate',
'formTarget',
'height',
'id',
'inputMode',
'maxLength',
'name',
Expand Down Expand Up @@ -674,13 +673,16 @@ var Geosuggest = (function (React) {
var _this = this;
var attributes = filterInputAttributes(this.props);
var classes = classnames('geosuggest__input', this.props.className);
var shouldRenderLabel = this.props.label && this.props.id;
if (!attributes.tabIndex) {
attributes.tabIndex = 0;
}
return (React.createElement("input", __assign({ className: classes, ref: function (i) { return (_this.input = i); }, type: "text" }, attributes, { value: this.props.value, style: this.props.style, onKeyDown: this.onInputKeyDown, onChange: this.onChange, onKeyPress: this.props.onKeyPress, onFocus: this.props.onFocus, onBlur: this.props.onBlur, role: "combobox", "aria-expanded": !this.props.isSuggestsHidden, "aria-activedescendant": this.props.activeSuggest
? this.props.activeSuggest.placeId
: // eslint-disable-next-line no-undefined
undefined, "aria-owns": this.props.listId })));
return (React.createElement(React.Fragment, null,
shouldRenderLabel && (React.createElement("label", { className: "geosuggest__label", htmlFor: this.props.id }, this.props.label)),
React.createElement("input", __assign({ className: classes, id: "geosuggest__input" + (this.props.id ? "--" + this.props.id : ''), ref: function (i) { return (_this.input = i); }, type: "text" }, attributes, { value: this.props.value, style: this.props.style, onKeyDown: this.onInputKeyDown, onChange: this.onChange, onKeyPress: this.props.onKeyPress, onFocus: this.props.onFocus, onBlur: this.props.onBlur, role: "combobox", "aria-expanded": !this.props.isSuggestsHidden, "aria-activedescendant": this.props.activeSuggest
? this.props.activeSuggest.placeId
: // eslint-disable-next-line no-undefined
undefined, "aria-owns": this.props.listId }))));
};
/* eslint-disable @typescript-eslint/no-empty-function */
/**
Expand Down Expand Up @@ -920,7 +922,7 @@ var Geosuggest = (function (React) {
_this.onSuggestNoResults = _this.onSuggestNoResults.bind(_this);
_this.hideSuggests = _this.hideSuggests.bind(_this);
_this.selectSuggest = _this.selectSuggest.bind(_this);
_this.listId = "geosuggest__list_" + Math.random().toString(16).slice(2);
_this.listId = "geosuggest__list" + (props.id ? "--" + props.id : '');
if (props.queryDelay) {
_this.onAfterInputChange = lodash_debounce(_this.onAfterInputChange, props.queryDelay);
}
Expand Down Expand Up @@ -1327,13 +1329,10 @@ var Geosuggest = (function (React) {
var classes = classnames('geosuggest', this.props.className, {
'geosuggest--loading': this.state.isLoading
});
var shouldRenderLabel = this.props.label && attributes.id;
var input = (React.createElement(Input, __assign({ className: this.props.inputClassName, ref: function (i) { return (_this.input = i); }, value: this.state.userInput, doNotSubmitOnEnter: !this.state.isSuggestsHidden, ignoreTab: this.props.ignoreTab, ignoreEnter: this.props.ignoreEnter, style: this.props.style && this.props.style.input, onChange: this.onInputChange, onFocus: this.onInputFocus, onBlur: this.onInputBlur, onKeyDown: this.props.onKeyDown, onKeyPress: this.props.onKeyPress, onNext: this.onNext, onPrev: this.onPrev, onSelect: this.onSelect, onEscape: this.hideSuggests, isSuggestsHidden: this.state.isSuggestsHidden, activeSuggest: this.state.activeSuggest, listId: this.listId }, attributes)));
var input = (React.createElement(Input, __assign({ className: this.props.inputClassName, ref: function (i) { return (_this.input = i); }, value: this.state.userInput, doNotSubmitOnEnter: !this.state.isSuggestsHidden, ignoreTab: this.props.ignoreTab, ignoreEnter: this.props.ignoreEnter, style: this.props.style && this.props.style.input, onChange: this.onInputChange, onFocus: this.onInputFocus, onBlur: this.onInputBlur, onKeyDown: this.props.onKeyDown, onKeyPress: this.props.onKeyPress, onNext: this.onNext, onPrev: this.onPrev, onSelect: this.onSelect, onEscape: this.hideSuggests, isSuggestsHidden: this.state.isSuggestsHidden, activeSuggest: this.state.activeSuggest, label: this.props.label, id: this.props.id, listId: this.listId }, attributes)));
var suggestionsList = (React.createElement(default_1$1, { isHidden: this.state.isSuggestsHidden, style: this.props.style && this.props.style.suggests, suggestItemStyle: this.props.style && this.props.style.suggestItem, userInput: this.state.userInput, isHighlightMatch: Boolean(this.props.highlightMatch), suggestsClassName: this.props.suggestsClassName, suggestItemClassName: this.props.suggestItemClassName, suggests: this.state.suggests, hiddenClassName: this.props.suggestsHiddenClassName, suggestItemActiveClassName: this.props.suggestItemActiveClassName, activeSuggest: this.state.activeSuggest, onSuggestNoResults: this.onSuggestNoResults, onSuggestMouseDown: this.onSuggestMouseDown, onSuggestMouseOut: this.onSuggestMouseOut, onSuggestSelect: this.selectSuggest, renderSuggestItem: this.props.renderSuggestItem, listId: this.listId }));
return (React.createElement("div", { className: classes },
React.createElement("div", { className: "geosuggest__input-wrapper" },
shouldRenderLabel && (React.createElement("label", { className: "geosuggest__label", htmlFor: attributes.id }, this.props.label)),
input),
return (React.createElement("div", { className: classes, id: this.props.id },
React.createElement("div", { className: "geosuggest__input-wrapper" }, input),
React.createElement("div", { className: "geosuggest__suggests-wrapper" }, suggestionsList)));
};
/**
Expand Down
Loading

0 comments on commit 03e647b

Please sign in to comment.