Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions chosen/chosen.jquery.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ Copyright (c) 2011 by Harvest
this.allow_single_deselect = (this.options.allow_single_deselect != null) && (this.form_field.options[0] != null) && this.form_field.options[0].text === "" ? this.options.allow_single_deselect : false;
this.disable_search_threshold = this.options.disable_search_threshold || 0;
this.disable_search = this.options.disable_search || false;
this.search_split_words = !(this.options.disable_search_split_words || false);
this.enable_split_word_search = this.options.enable_split_word_search != null ? this.options.enable_split_word_search : true;
this.search_contains = this.options.search_contains || false;
this.choices = 0;
this.single_backstroke_delete = this.options.single_backstroke_delete || false;
Expand Down Expand Up @@ -854,7 +854,7 @@ Copyright (c) 2011 by Harvest
if (regex.test(option.html)) {
found = true;
results += 1;
} else if (this.search_split_words && (option.html.indexOf(" ") >= 0 || option.html.indexOf("[") === 0)) {
} else if (this.enable_split_word_search && (option.html.indexOf(" ") >= 0 || option.html.indexOf("[") === 0)) {
parts = option.html.replace(/\[|\]/g, "").split(" ");
if (parts.length) {
for (_j = 0, _len1 = parts.length; _j < _len1; _j++) {
Expand Down
2 changes: 1 addition & 1 deletion chosen/chosen.jquery.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions chosen/chosen.proto.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ Copyright (c) 2011 by Harvest
this.allow_single_deselect = (this.options.allow_single_deselect != null) && (this.form_field.options[0] != null) && this.form_field.options[0].text === "" ? this.options.allow_single_deselect : false;
this.disable_search_threshold = this.options.disable_search_threshold || 0;
this.disable_search = this.options.disable_search || false;
this.search_split_words = !(this.options.disable_search_split_words || false);
this.enable_split_word_search = this.options.enable_split_word_search != null ? this.options.enable_split_word_search : true;
this.search_contains = this.options.search_contains || false;
this.choices = 0;
this.single_backstroke_delete = this.options.single_backstroke_delete || false;
Expand Down Expand Up @@ -847,7 +847,7 @@ Copyright (c) 2011 by Harvest
if (regex.test(option.html)) {
found = true;
results += 1;
} else if (this.search_split_words && (option.html.indexOf(" ") >= 0 || option.html.indexOf("[") === 0)) {
} else if (this.enable_split_word_search && (option.html.indexOf(" ") >= 0 || option.html.indexOf("[") === 0)) {
parts = option.html.replace(/\[|\]/g, "").split(" ");
if (parts.length) {
for (_j = 0, _len1 = parts.length; _j < _len1; _j++) {
Expand Down
2 changes: 1 addition & 1 deletion chosen/chosen.proto.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion coffee/chosen.jquery.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ class Chosen extends AbstractChosen
if regex.test option.html
found = true
results += 1
else if @search_split_words and (option.html.indexOf(" ") >= 0 or option.html.indexOf("[") == 0)
else if @enable_split_word_search and (option.html.indexOf(" ") >= 0 or option.html.indexOf("[") == 0)
#TODO: replace this substitution of /\[\]/ with a list of characters to skip.
parts = option.html.replace(/\[|\]/g, "").split(" ")
if parts.length
Expand Down
2 changes: 1 addition & 1 deletion coffee/chosen.proto.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ class Chosen extends AbstractChosen
if regex.test option.html
found = true
results += 1
else if @search_split_words and (option.html.indexOf(" ") >= 0 or option.html.indexOf("[") == 0)
else if @enable_split_word_search and (option.html.indexOf(" ") >= 0 or option.html.indexOf("[") == 0)
#TODO: replace this substitution of /\[\]/ with a list of characters to skip.
parts = option.html.replace(/\[|\]/g, "").split(" ")
if parts.length
Expand Down
2 changes: 1 addition & 1 deletion coffee/lib/abstract-chosen.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class AbstractChosen
@allow_single_deselect = if @options.allow_single_deselect? and @form_field.options[0]? and @form_field.options[0].text is "" then @options.allow_single_deselect else false
@disable_search_threshold = @options.disable_search_threshold || 0
@disable_search = @options.disable_search || false
@search_split_words = not (@options.disable_search_split_words || false)
@enable_split_word_search = if @options.enable_split_word_search? then @options.enable_split_word_search else true
@search_contains = @options.search_contains || false
@choices = 0
@single_backstroke_delete = @options.single_backstroke_delete || false
Expand Down