@testim/testim-cli 3.194.0 → 3.195.0
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/npm-shrinkwrap.json
CHANGED
|
@@ -2853,9 +2853,9 @@
|
|
|
2853
2853
|
"integrity": "sha512-GJCAeDBKfREgkBtgrYSf9hQy9kTb3helv0zGdzqhM7iAkW8FA/ZF97VQDbwFiwIT8MQLLOe5VlPZOEvZAqtUAQ=="
|
|
2854
2854
|
},
|
|
2855
2855
|
"electron-to-chromium": {
|
|
2856
|
-
"version": "1.3.
|
|
2857
|
-
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.
|
|
2858
|
-
"integrity": "sha512-
|
|
2856
|
+
"version": "1.3.880",
|
|
2857
|
+
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.3.880.tgz",
|
|
2858
|
+
"integrity": "sha512-iwIP/6WoeSimzUKJIQtjtpVDsK8Ir8qQCMXsUBwg+rxJR2Uh3wTNSbxoYRfs+3UWx/9MAnPIxVZCyWkm8MT0uw==",
|
|
2859
2859
|
"dev": true
|
|
2860
2860
|
},
|
|
2861
2861
|
"emoji-regex": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
module.exports = function dispatchFocus(targetElement, oldActiveElement) {
|
|
2
2
|
function createFocusEvent(eventName) {
|
|
3
|
-
var event = document.createEvent("
|
|
3
|
+
var event = document.createEvent("HTMLEvents");
|
|
4
4
|
// TODO we want to use new Event, but mootools (used by zuora which is used by jfrog)
|
|
5
5
|
// overrides window.Event and throws an error
|
|
6
6
|
event.initEvent(eventName, true, false);
|
|
@@ -16,10 +16,12 @@ module.exports = function dispatchFocus(targetElement, oldActiveElement) {
|
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
function setFocus(element, oldActiveElement) {
|
|
19
|
-
element.dispatchEvent(createFocusEvent('focusin'));
|
|
20
19
|
if (oldActiveElement) {
|
|
21
|
-
|
|
20
|
+
oldActiveElement.dispatchEvent(createFocusEvent('focusout'));
|
|
21
|
+
oldActiveElement.dispatchEvent(createFocusEvent('blur'));
|
|
22
22
|
}
|
|
23
|
+
element.dispatchEvent(createFocusEvent('focusin'));
|
|
24
|
+
element.dispatchEvent(createFocusEvent('focus'));
|
|
23
25
|
if (typeof element.focus === 'function') {
|
|
24
26
|
element.focus();
|
|
25
27
|
}
|