@danielgindi/selectbox 2.0.49 → 2.0.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/lib.umd.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @danielgindi/selectbox 2.0.49
2
+ * @danielgindi/selectbox 2.0.50
3
3
  * git://github.com/danielgindi/selectbox.git
4
4
  */
5
5
  (function (global, factory) {
@@ -11285,6 +11285,7 @@
11285
11285
 
11286
11286
  this._trigger('open:before', { list: p.dropList });
11287
11287
 
11288
+ if (document.activeElement !== p.input)
11288
11289
  p.lastActiveElement = document.activeElement === document.body ? null : getFocusState(document.activeElement);
11289
11290
 
11290
11291
  // Propagate direction to droplist
@@ -11322,6 +11323,7 @@
11322
11323
  p.dropList.hide();
11323
11324
 
11324
11325
  if (p.lastActiveElement) {
11326
+ if (!p.multi && !p.searchable)
11325
11327
  restoreFocusState(p.lastActiveElement);
11326
11328
  p.lastActiveElement = null;
11327
11329
  }