Browse Source

Update base.js

Pedro Felipe de Azevedo Furtado 6 năm trước cách đây
mục cha
commit
933189b92e
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      src/js/select2/selection/base.js

+ 3 - 1
src/js/select2/selection/base.js

@@ -81,7 +81,9 @@ define([
       self.$selection.removeAttr('aria-activedescendant');
       self.$selection.removeAttr('aria-owns');
 
-      self.$selection.focus();
+      window.setTimeout(function () {
+        self.$selection.focus();
+      }, 0);
     
       self._detachCloseHandler(container);
     });