Skip to content

Commit

Permalink
Possible fix for #201
Browse files Browse the repository at this point in the history
  • Loading branch information
oyejorge committed Sep 10, 2021
1 parent 26f3fda commit 4bc4104
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/tom-select.ts
Expand Up @@ -1226,7 +1226,12 @@ export default class TomSelect extends MicroPlugin(MicroEvent){
if (self.isDisabled) return;

self.ignoreFocus = true;
self.focus_node.focus();

if( self.control_input.offsetWidth ){
self.control_input.focus();
}else{
self.focus_node.focus();
}

setTimeout(() => {
self.ignoreFocus = false;
Expand Down

0 comments on commit 4bc4104

Please sign in to comment.