Skip to content

Commit 662ee46

Browse files
committed
Bump version number to 1.3.0. Update changelog and regenerate dist files.
1 parent c55b62f commit 662ee46

8 files changed

+38
-18
lines changed

changelog.md

+9-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
# Changelog
22

3-
### 1.2.0 September 25, 2017
3+
### 1.3.0 November 16, 2019
4+
* Fix autoselect on tab [#199](https://github.com/corejavascript/typeahead.js/pull/199)
5+
* On up/down arrow, set the input only if data.val is a string [#184](https://github.com/corejavascript/typeahead.js/pull/184)
6+
* Apply accessibility attributes to suggestion template [#185](https://github.com/corejavascript/typeahead.js/pull/185)
7+
8+
9+
### 1.2.1 September 25, 2017
410
* Fix various typos [#137](https://github.com/corejavascript/typeahead.js/pull/137)
511
* Add jQuery 3 support [#102](https://github.com/corejavascript/typeahead.js/pull/102)
612
* Remove 'required' class from cloned input field [#125](https://github.com/corejavascript/typeahead.js/pull/125)
@@ -9,6 +15,8 @@
915
* Fix link in bloodhound docs [#134](https://github.com/corejavascript/typeahead.js/pull/134)
1016
* Minor change to docs to log object instead of assuming it's a string [#157](https://github.com/corejavascript/typeahead.js/pull/157)
1117

18+
### 1.2.0 September 25, 2017
19+
(Skipped)
1220

1321
### 1.1.1 January 12, 2017
1422
* Fix hiding of .visuallyhidden style (introduced in #104) [#107](https://github.com/corejavascript/typeahead.js/pull/107)

dist/bloodhound.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* typeahead.js 1.2.1
2+
* typeahead.js 1.3.0
33
* https://github.com/corejavascript/typeahead.js
44
* Copyright 2013-2019 Twitter, Inc. and other contributors; Licensed MIT
55
*/
@@ -159,7 +159,7 @@
159159
noop: function() {}
160160
};
161161
}();
162-
var VERSION = "1.2.1";
162+
var VERSION = "1.3.0";
163163
var tokenizers = function() {
164164
"use strict";
165165
return {

dist/bloodhound.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/typeahead.bundle.js

+10-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* typeahead.js 1.2.1
2+
* typeahead.js 1.3.0
33
* https://github.com/corejavascript/typeahead.js
44
* Copyright 2013-2019 Twitter, Inc. and other contributors; Licensed MIT
55
*/
@@ -159,7 +159,7 @@
159159
noop: function() {}
160160
};
161161
}();
162-
var VERSION = "1.2.1";
162+
var VERSION = "1.3.0";
163163
var tokenizers = function() {
164164
"use strict";
165165
return {
@@ -1844,8 +1844,12 @@
18441844
pending: templates.pending && _.templatify(templates.pending),
18451845
header: templates.header && _.templatify(templates.header),
18461846
footer: templates.footer && _.templatify(templates.footer),
1847-
suggestion: templates.suggestion || suggestionTemplate
1847+
suggestion: templates.suggestion ? userSuggestionTemplate : suggestionTemplate
18481848
};
1849+
function userSuggestionTemplate(context) {
1850+
var template = templates.suggestion;
1851+
return $(template(context)).attr("id", _.guid());
1852+
}
18491853
function suggestionTemplate(context) {
18501854
return $('<div role="option">').attr("id", _.guid()).text(displayFn(context));
18511855
}
@@ -2359,7 +2363,9 @@
23592363
if (!cancelMove && !this.eventBus.before("cursorchange", suggestion, datasetName)) {
23602364
this.menu.setCursor($candidate);
23612365
if (data) {
2362-
this.input.setInputValue(data.val);
2366+
if (typeof data.val === "string") {
2367+
this.input.setInputValue(data.val);
2368+
}
23632369
} else {
23642370
this.input.resetInputValue();
23652371
this._updateHint();

dist/typeahead.bundle.min.js

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/typeahead.jquery.js

+9-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* typeahead.js 1.2.1
2+
* typeahead.js 1.3.0
33
* https://github.com/corejavascript/typeahead.js
44
* Copyright 2013-2019 Twitter, Inc. and other contributors; Licensed MIT
55
*/
@@ -897,8 +897,12 @@
897897
pending: templates.pending && _.templatify(templates.pending),
898898
header: templates.header && _.templatify(templates.header),
899899
footer: templates.footer && _.templatify(templates.footer),
900-
suggestion: templates.suggestion || suggestionTemplate
900+
suggestion: templates.suggestion ? userSuggestionTemplate : suggestionTemplate
901901
};
902+
function userSuggestionTemplate(context) {
903+
var template = templates.suggestion;
904+
return $(template(context)).attr("id", _.guid());
905+
}
902906
function suggestionTemplate(context) {
903907
return $('<div role="option">').attr("id", _.guid()).text(displayFn(context));
904908
}
@@ -1412,7 +1416,9 @@
14121416
if (!cancelMove && !this.eventBus.before("cursorchange", suggestion, datasetName)) {
14131417
this.menu.setCursor($candidate);
14141418
if (data) {
1415-
this.input.setInputValue(data.val);
1419+
if (typeof data.val === "string") {
1420+
this.input.setInputValue(data.val);
1421+
}
14161422
} else {
14171423
this.input.resetInputValue();
14181424
this._updateHint();

dist/typeahead.jquery.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,6 @@
7171
"scripts": {
7272
"test": "bower install && node ./node_modules/karma/bin/karma start --single-run --browsers PhantomJS"
7373
},
74-
"version": "1.2.1",
74+
"version": "1.3.0",
7575
"main": "dist/typeahead.bundle.js"
7676
}

0 commit comments

Comments
 (0)