jsuites 5.5.0 → 5.5.1

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/changelog.md CHANGED
@@ -1,3 +1,7 @@
1
+ # 5.5.1
2
+
3
+ - Add tracking.state to a second jsuites instance.
4
+
1
5
  # 5.5.0
2
6
 
3
7
  - Added a new event for dropdowns: onbeforeinput.
package/dist/jsuites.js CHANGED
@@ -12780,7 +12780,7 @@ var jSuites = {
12780
12780
  ...dictionary,
12781
12781
  ...helpers,
12782
12782
  /** Current version */
12783
- version: '5.5.0',
12783
+ version: '5.5.1',
12784
12784
  /** Bind new extensions to Jsuites */
12785
12785
  setExtensions: function(o) {
12786
12786
  if (typeof(o) == 'object') {
@@ -12842,6 +12842,12 @@ const Events = function() {
12842
12842
 
12843
12843
  tracking.state = [];
12844
12844
 
12845
+ // Block event to run twice
12846
+ if (window['jSuitesEvents'] === true) {
12847
+ return;
12848
+ }
12849
+ window['jSuitesEvents'] = true;
12850
+
12845
12851
  const find = function(DOMElement, component) {
12846
12852
  if (DOMElement[component.type] && DOMElement[component.type] == component) {
12847
12853
  return true;
@@ -13288,15 +13294,10 @@ const Events = function() {
13288
13294
  document.addEventListener('keydown', keyDown);
13289
13295
  document.addEventListener('contextmenu', contextMenu);
13290
13296
  document.addEventListener('input', input);
13291
-
13292
- // Block same events twice
13293
- window['jSuitesEvents'] = true;
13294
13297
  }
13295
13298
 
13296
13299
  if (typeof(document) !== "undefined" && ! tracking.state) {
13297
- if (typeof(window['jSuitesEvents']) === "undefined") {
13298
- Events();
13299
- }
13300
+ Events();
13300
13301
  }
13301
13302
 
13302
13303
  /* harmony default export */ var jsuites = (jSuites);
package/package.json CHANGED
@@ -26,7 +26,7 @@
26
26
  },
27
27
  "main": "dist/jsuites.js",
28
28
  "types": "dist/jsuites.d.ts",
29
- "version": "5.5.0",
29
+ "version": "5.5.1",
30
30
  "bugs": "https://github.com/jsuites/jsuites/issues",
31
31
  "homepage": "https://github.com/jsuites/jsuites",
32
32
  "docs": "https://jsuites.net",