We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b9f8d59 commit 8da5b51Copy full SHA for 8da5b51
src/selectize.js
@@ -1123,10 +1123,12 @@ $.extend(Selectize.prototype, {
1123
$dropdown_content.html(html);
1124
1125
// highlight matching terms inline
1126
- if (self.settings.highlight && results.query.length && results.tokens.length) {
+ if (self.settings.highlight) {
1127
$dropdown_content.removeHighlight();
1128
- for (i = 0, n = results.tokens.length; i < n; i++) {
1129
- highlight($dropdown_content, results.tokens[i].regex);
+ if (results.query.length && results.tokens.length) {
+ for (i = 0, n = results.tokens.length; i < n; i++) {
1130
+ highlight($dropdown_content, results.tokens[i].regex);
1131
+ }
1132
}
1133
1134
0 commit comments