Skip to content

Commit

Permalink
Rebuild dist for latest release.
Browse files Browse the repository at this point in the history
  • Loading branch information
jlbooker committed Sep 25, 2017
1 parent bf9419b commit 6c39988
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 26 deletions.
7 changes: 3 additions & 4 deletions dist/bloodhound.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
/*!
* typeahead.js 1.1.1
* typeahead.js 1.2.0
* https://github.com/twitter/typeahead.js
* Copyright 2013-2017 Twitter, Inc. and other contributors; Licensed MIT
*/


(function(root, factory) {
if (typeof define === "function" && define.amd) {
define([ "jquery" ], function(a0) {
return root["Bloodhound"] = factory(a0);
});
} else if (typeof module === "object" && module.exports) {
} else if (typeof exports === "object") {
module.exports = factory(require("jquery"));
} else {
root["Bloodhound"] = factory(root["jQuery"]);
Expand Down Expand Up @@ -159,7 +158,7 @@
noop: function() {}
};
}();
var VERSION = "1.1.1";
var VERSION = "1.2.0";
var tokenizers = function() {
"use strict";
return {
Expand Down
5 changes: 2 additions & 3 deletions dist/bloodhound.min.js

Large diffs are not rendered by default.

27 changes: 20 additions & 7 deletions dist/typeahead.bundle.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
/*!
* typeahead.js 1.1.1
* typeahead.js 1.2.0
* https://github.com/twitter/typeahead.js
* Copyright 2013-2017 Twitter, Inc. and other contributors; Licensed MIT
*/


(function(root, factory) {
if (typeof define === "function" && define.amd) {
define([ "jquery" ], function(a0) {
return root["Bloodhound"] = factory(a0);
});
} else if (typeof module === "object" && module.exports) {
} else if (typeof exports === "object") {
module.exports = factory(require("jquery"));
} else {
root["Bloodhound"] = factory(root["jQuery"]);
Expand Down Expand Up @@ -159,7 +158,7 @@
noop: function() {}
};
}();
var VERSION = "1.1.1";
var VERSION = "1.2.0";
var tokenizers = function() {
"use strict";
return {
Expand Down Expand Up @@ -957,7 +956,7 @@
define([ "jquery" ], function(a0) {
return factory(a0);
});
} else if (typeof module === "object" && module.exports) {
} else if (typeof exports === "object") {
module.exports = factory(require("jquery"));
} else {
factory(root["jQuery"]);
Expand Down Expand Up @@ -2114,6 +2113,7 @@
this.input = o.input;
this.menu = o.menu;
this.enabled = true;
this.autoselect = !!o.autoselect;
this.active = false;
this.input.hasFocus() && this.activate();
this.dir = this.input.getLangDir();
Expand Down Expand Up @@ -2162,6 +2162,10 @@
},
_onDatasetRendered: function onDatasetRendered(type, suggestions, async, dataset) {
this._updateHint();
if (this.autoselect) {
var cursorClass = this.selectors.cursor.substr(1);
this.menu.$node.find(this.selectors.suggestion).first().addClass(cursorClass);
}
this.eventBus.trigger("render", suggestions, async, dataset);
},
_onAsyncRequested: function onAsyncRequested(type, dataset, query) {
Expand All @@ -2188,6 +2192,11 @@
$e.preventDefault();
$e.stopPropagation();
}
} else if (this.autoselect) {
if (this.select(this.menu.getTopSelectable())) {
$e.preventDefault();
$e.stopPropagation();
}
}
},
_onTabKeyed: function onTabKeyed(type, $e) {
Expand Down Expand Up @@ -2429,7 +2438,8 @@
input: input,
menu: menu,
eventBus: eventBus,
minLength: o.minLength
minLength: o.minLength,
autoselect: o.autoselect
}, www);
$input.data(keys.www, www);
$input.data(keys.typeahead, typeahead);
Expand Down Expand Up @@ -2553,7 +2563,10 @@
});
}
function buildHintFromInput($input, www) {
return $input.clone().addClass(www.classes.hint).removeData().css(www.css.hint).css(getBackgroundStyles($input)).prop("readonly", true).removeAttr("id name placeholder required").attr({
return $input.clone().addClass(www.classes.hint).removeData().css(www.css.hint).css(getBackgroundStyles($input)).prop({
readonly: true,
required: false
}).removeAttr("id name placeholder").removeClass("required").attr({
spellcheck: "false",
tabindex: -1
});
Expand Down
7 changes: 3 additions & 4 deletions dist/typeahead.bundle.min.js

Large diffs are not rendered by default.

23 changes: 18 additions & 5 deletions dist/typeahead.jquery.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
/*!
* typeahead.js 1.1.1
* typeahead.js 1.2.0
* https://github.com/twitter/typeahead.js
* Copyright 2013-2017 Twitter, Inc. and other contributors; Licensed MIT
*/


(function(root, factory) {
if (typeof define === "function" && define.amd) {
define([ "jquery" ], function(a0) {
return factory(a0);
});
} else if (typeof module === "object" && module.exports) {
} else if (typeof exports === "object") {
module.exports = factory(require("jquery"));
} else {
factory(root["jQuery"]);
Expand Down Expand Up @@ -1167,6 +1166,7 @@
this.input = o.input;
this.menu = o.menu;
this.enabled = true;
this.autoselect = !!o.autoselect;
this.active = false;
this.input.hasFocus() && this.activate();
this.dir = this.input.getLangDir();
Expand Down Expand Up @@ -1215,6 +1215,10 @@
},
_onDatasetRendered: function onDatasetRendered(type, suggestions, async, dataset) {
this._updateHint();
if (this.autoselect) {
var cursorClass = this.selectors.cursor.substr(1);
this.menu.$node.find(this.selectors.suggestion).first().addClass(cursorClass);
}
this.eventBus.trigger("render", suggestions, async, dataset);
},
_onAsyncRequested: function onAsyncRequested(type, dataset, query) {
Expand All @@ -1241,6 +1245,11 @@
$e.preventDefault();
$e.stopPropagation();
}
} else if (this.autoselect) {
if (this.select(this.menu.getTopSelectable())) {
$e.preventDefault();
$e.stopPropagation();
}
}
},
_onTabKeyed: function onTabKeyed(type, $e) {
Expand Down Expand Up @@ -1482,7 +1491,8 @@
input: input,
menu: menu,
eventBus: eventBus,
minLength: o.minLength
minLength: o.minLength,
autoselect: o.autoselect
}, www);
$input.data(keys.www, www);
$input.data(keys.typeahead, typeahead);
Expand Down Expand Up @@ -1606,7 +1616,10 @@
});
}
function buildHintFromInput($input, www) {
return $input.clone().addClass(www.classes.hint).removeData().css(www.css.hint).css(getBackgroundStyles($input)).prop("readonly", true).removeAttr("id name placeholder required").attr({
return $input.clone().addClass(www.classes.hint).removeData().css(www.css.hint).css(getBackgroundStyles($input)).prop({
readonly: true,
required: false
}).removeAttr("id name placeholder").removeClass("required").attr({
spellcheck: "false",
tabindex: -1
});
Expand Down
5 changes: 2 additions & 3 deletions dist/typeahead.jquery.min.js

Large diffs are not rendered by default.

0 comments on commit 6c39988

Please sign in to comment.