Skip to content

Commit a188359

Browse files
authored
Merge pull request #1353 from topaxi/fix-ff-focus
Fix FF and IE tabbing/blur issues.
2 parents 32ee80a + e650940 commit a188359

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/selectize.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1772,9 +1772,13 @@ $.extend(Selectize.prototype, {
17721772

17731773
if (self.settings.mode === 'single' && self.items.length) {
17741774
self.hideInput();
1775-
setTimeout(function() {
1775+
1776+
// Do not trigger blur while inside a blur event,
1777+
// this fixes some weird tabbing behavior in FF and IE.
1778+
// See #1164
1779+
if (self.ignoreFocus) {
17761780
self.$control_input.blur(); // close keyboard on iOS
1777-
});
1781+
}
17781782
}
17791783

17801784
self.isOpen = false;

0 commit comments

Comments
 (0)