Lines Matching defs:input

592      * Default tokenizer. This function uses breaks the input on substring match of any string from the
596 * @param input text user has typed so far or pasted into the search field
600 * @return undefined/null to leave the current input unchanged, or a string to change the input to the returned value
602 function defaultTokenizer(input, selection, selectCallback, opts) {
603 var original = input, // store the original so we can compare and know if we need to tell the search to update its text
617 index = input.indexOf(separator);
621 if (index < 0) break; // did not find any token separator in the input string, bail
623 token = input.substring(0, index);
624 input = input.substring(index + separator.length);
641 if (original!==input) return input;
726 this.search = search = this.container.find("input.select2-input");
747 $(this.container).on("change", ".select2-input", function(e) {e.stopPropagation();});
748 $(this.dropdown).on("change", ".select2-input", function(e) {e.stopPropagation();});
765 search.on("keyup-change input paste", this.bind(this.updateResults));
1411 * Opens control, sets input value, and updates results.
1615 input,
1685 // give the tokenizer a chance to pre-process the input
1686 input = this.tokenize();
1687 if (input != undefined && input != null) {
1688 search.val(input);
1846 // when attached to input type=hidden or elements hidden via css
1882 "<input class='select2-focusser select2-offscreen' type='text' aria-haspopup='true' role='button' />",
1886 " <input type='text' autocomplete='off' autocorrect='off' autocapitalize='off' spellcheck='false' class='select2-input' role='combobox' aria-expanded='true'",
2112 this.focusser.on("keyup-change input", this.bind(function(e) {
2242 // install default initSelection when applied to hidden input and data is local
2483 " <input type='text' autocomplete='off' autocorrect='off' autocapitalize='off' spellcheck='false' class='select2-input'>",
2512 // install default initSelection when applied to hidden input and data is local
2599 this.search.on("input paste", this.bind(function() {
2867 var input = this.search.val();
2868 input = this.opts.tokenizer.call(this, input, this.data(), this.bind(this.onSelect), this.opts);
2869 if (input != null && input != undefined) {
2870 this.search.val(input);
2871 if (input.length > 0) {
3203 throw new Error("Sorting of elements is not supported when attached to <select>. Attach to <input type='hidden'/> instead.");
3336 formatInputTooShort: function (input, min) { var n = min - input.length; return "Please enter " + n + " or more character" + (n == 1? "" : "s"); },
3337 formatInputTooLong: function (input, max) { var n = input.length - max; return "Please delete " + n + " character" + (n == 1? "" : "s"); },
3361 // Never focus the input if search is disabled