diff --git a/awesomplete.js b/awesomplete.js index 1f1f752f..c9954cd9 100644 --- a/awesomplete.js +++ b/awesomplete.js @@ -38,6 +38,7 @@ var _ = function (input, o) { container: _.CONTAINER, item: _.ITEM, replace: _.REPLACE, + suggestion: Suggestion, tabSelect: false }, o); @@ -305,7 +306,7 @@ _.prototype = { this.suggestions = this._list .map(function(item) { - return new Suggestion(me.data(item, value)); + return new me.suggestion(me.data(item, value)); }) .filter(function(item) { return me.filter(item, value); diff --git a/index.html b/index.html index b386bf5d..81c8852e 100644 --- a/index.html +++ b/index.html @@ -283,6 +283,12 @@
Awesomplete.DATA
: Identity function which just returns the original list item.suggestion
label
, value
, and length
properties and the toString
and valueOf
methods.Suggestion
: A basic class, protoyped from String
, which provides the requisite functionality.