@mablhq/mabl-cli 1.26.0 → 1.26.5
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/api/basicApiClient.js +1 -0
- package/api/entities/Browser.js +0 -1
- package/api/mablApiClientFactory.js +5 -4
- package/browserLauncher/playwrightBrowserLauncher/playwrightBrowserLauncher.js +1 -13
- package/commands/browserTypes.js +8 -19
- package/commands/config/config_cmds/configKeys.js +7 -1
- package/commands/config/config_cmds/set.js +6 -0
- package/commands/constants.js +5 -6
- package/commands/tests/testsUtil.js +43 -41
- package/commands/tests/tests_cmds/run-cloud.js +2 -2
- package/commands/tests/tests_cmds/run.js +0 -2
- package/domUtil/index.js +1 -1
- package/execution/index.js +1 -1
- package/mablscriptFind/index.js +1 -1
- package/package.json +4 -3
- package/providers/cliConfigProvider.js +6 -0
- package/resources/mablFind.js +1 -1
- package/util/httpUtil.js +32 -12
package/api/basicApiClient.js
CHANGED
|
@@ -58,6 +58,7 @@ class BasicApiClient {
|
|
|
58
58
|
const config = (0, httpUtil_1.axiosProxyConfig)({
|
|
59
59
|
sslVerify: (_a = options.sslVerify) !== null && _a !== void 0 ? _a : DEFAULT_SSL_VERIFY,
|
|
60
60
|
proxyHost: options.proxyUrl,
|
|
61
|
+
proxyType: options.proxyType,
|
|
61
62
|
});
|
|
62
63
|
if (!config.headers) {
|
|
63
64
|
config.headers = {};
|
package/api/entities/Browser.js
CHANGED
|
@@ -32,11 +32,11 @@ class MablApiClientFactory {
|
|
|
32
32
|
});
|
|
33
33
|
}
|
|
34
34
|
static async createApiClient(opts) {
|
|
35
|
-
const {
|
|
36
|
-
.mabl;
|
|
35
|
+
const { mabl } = (await cliConfigProvider_1.CliConfigProvider.getCliConfig()).http;
|
|
37
36
|
const optsFromCliHttpConfig = {
|
|
38
|
-
proxyUrl: proxyHost,
|
|
39
|
-
sslVerify,
|
|
37
|
+
proxyUrl: mabl.proxyHost,
|
|
38
|
+
sslVerify: mabl.sslVerify,
|
|
39
|
+
proxyType: mabl.proxyType,
|
|
40
40
|
};
|
|
41
41
|
if (opts) {
|
|
42
42
|
return new mablApiClient_1.MablApiClient({
|
|
@@ -68,6 +68,7 @@ class MablApiClientFactory {
|
|
|
68
68
|
token: accessToken,
|
|
69
69
|
proxyUrl: httpConfig.proxyHost,
|
|
70
70
|
sslVerify: httpConfig.sslVerify,
|
|
71
|
+
proxyType: httpConfig.proxyType,
|
|
71
72
|
});
|
|
72
73
|
}
|
|
73
74
|
static throwUserAuthTypeError() {
|
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.PlaywrightBrowserLauncher = void 0;
|
|
4
4
|
const test_1 = require("@playwright/test");
|
|
5
|
-
const browserTypes_1 = require("../../commands/browserTypes");
|
|
6
|
-
const loggingProvider_1 = require("../../providers/logging/loggingProvider");
|
|
7
5
|
const playwrightBrowser_1 = require("./playwrightBrowser");
|
|
8
6
|
const BROWSER_LAUNCH_TIMEOUT_MS = 60000;
|
|
9
7
|
class PlaywrightBrowserLauncher {
|
|
@@ -20,23 +18,13 @@ class PlaywrightBrowserLauncher {
|
|
|
20
18
|
}
|
|
21
19
|
:
|
|
22
20
|
null;
|
|
23
|
-
if (!options.userDataDir) {
|
|
24
|
-
loggingProvider_1.logger.error('User data directory is required to launch a persistent chromium context and was not provided with LaunchOptions [{}]', options);
|
|
25
|
-
throw new Error('User data directory is required to launch a persistent chromium context');
|
|
26
|
-
}
|
|
27
|
-
if (!options.downloadPath) {
|
|
28
|
-
loggingProvider_1.logger.error('Download path is required to launch a persistent chromium context and was not provided with LaunchOptions [{}]', options);
|
|
29
|
-
throw new Error('Download path is required to launch a persistent chromium context and was not provided with LaunchOptions');
|
|
30
|
-
}
|
|
31
21
|
const defaultContext = await test_1.chromium.launchPersistentContext(options.userDataDir, {
|
|
32
22
|
acceptDownloads: true,
|
|
33
23
|
args: options.args,
|
|
34
24
|
bypassCSP: options.bypassContentSecurityPolicy,
|
|
35
|
-
channel: browserTypes_1.SupportedBrowserTypeProperties[options.browserType]
|
|
36
|
-
.browserReleaseChannel,
|
|
37
25
|
deviceScaleFactor: (_a = options.defaultDeviceDescriptor) === null || _a === void 0 ? void 0 : _a.deviceScaleFactor,
|
|
38
26
|
downloadsPath: options.downloadPath,
|
|
39
|
-
executablePath: options.
|
|
27
|
+
executablePath: options.executablePath,
|
|
40
28
|
extraHTTPHeaders: options.extraHttpHeaders,
|
|
41
29
|
hasTouch: (_b = options.defaultDeviceDescriptor) === null || _b === void 0 ? void 0 : _b.hasTouch,
|
|
42
30
|
headless: options.headless,
|
package/commands/browserTypes.js
CHANGED
|
@@ -1,21 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
var
|
|
5
|
-
(function (
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
})(BrowserType = exports.BrowserType || (exports.BrowserType = {}));
|
|
12
|
-
exports.SupportedBrowserTypeProperties = {
|
|
13
|
-
chrome: { browserName: 'chrome', browserReleaseChannel: 'chrome' },
|
|
14
|
-
edge: { browserName: 'edge', browserReleaseChannel: 'msedge' },
|
|
15
|
-
firefox: { browserName: 'firefox', browserReleaseChannel: 'firefox' },
|
|
16
|
-
safari: {
|
|
17
|
-
browserName: 'safari',
|
|
18
|
-
browserReleaseChannel: 'webkit',
|
|
19
|
-
},
|
|
20
|
-
};
|
|
21
|
-
exports.DefaultBrowserProperties = exports.SupportedBrowserTypeProperties.chrome;
|
|
3
|
+
exports.BrowserTypes = void 0;
|
|
4
|
+
var BrowserTypes;
|
|
5
|
+
(function (BrowserTypes) {
|
|
6
|
+
BrowserTypes["Chrome"] = "chrome";
|
|
7
|
+
BrowserTypes["Firefox"] = "firefox";
|
|
8
|
+
BrowserTypes["InternetExplorer"] = "internet_explorer";
|
|
9
|
+
BrowserTypes["Safari"] = "safari";
|
|
10
|
+
})(BrowserTypes = exports.BrowserTypes || (exports.BrowserTypes = {}));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.isValidProxyMode = exports.proxyModes = exports.validConfigKeyChoices = exports.configKeys = void 0;
|
|
3
|
+
exports.isValidProxyType = exports.isValidProxyMode = exports.proxyTypes = exports.proxyModes = exports.validConfigKeyChoices = exports.configKeys = void 0;
|
|
4
4
|
exports.configKeys = Object.freeze({
|
|
5
5
|
browserPath: 'browser.path',
|
|
6
6
|
enableSourceControlMetadataCollection: 'alpha.scm_metadata.enable',
|
|
@@ -8,6 +8,7 @@ exports.configKeys = Object.freeze({
|
|
|
8
8
|
proxy: 'http.proxy',
|
|
9
9
|
sslVerify: 'http.sslVerify',
|
|
10
10
|
proxyMode: 'http.proxyMode',
|
|
11
|
+
proxyType: 'http.proxyType',
|
|
11
12
|
});
|
|
12
13
|
exports.validConfigKeyChoices = Object.values(exports.configKeys);
|
|
13
14
|
exports.proxyModes = [
|
|
@@ -16,7 +17,12 @@ exports.proxyModes = [
|
|
|
16
17
|
'all',
|
|
17
18
|
'none',
|
|
18
19
|
];
|
|
20
|
+
exports.proxyTypes = ['legacy', 'current'];
|
|
19
21
|
function isValidProxyMode(value) {
|
|
20
22
|
return exports.proxyModes.indexOf(value) !== -1;
|
|
21
23
|
}
|
|
22
24
|
exports.isValidProxyMode = isValidProxyMode;
|
|
25
|
+
function isValidProxyType(value) {
|
|
26
|
+
return exports.proxyTypes.indexOf(value) !== -1;
|
|
27
|
+
}
|
|
28
|
+
exports.isValidProxyType = isValidProxyType;
|
|
@@ -55,6 +55,12 @@ async function setConfig(parsed) {
|
|
|
55
55
|
}
|
|
56
56
|
await cliConfigProvider_1.CliConfigProvider.setConfigProperty(key, value);
|
|
57
57
|
break;
|
|
58
|
+
case configKeys_1.configKeys.proxyType:
|
|
59
|
+
if (!(0, configKeys_1.isValidProxyType)(value)) {
|
|
60
|
+
throw new Error(`Invalid proxy type. The value must be one of ${JSON.stringify(configKeys_1.proxyTypes)}`);
|
|
61
|
+
}
|
|
62
|
+
await cliConfigProvider_1.CliConfigProvider.setConfigProperty(key, value);
|
|
63
|
+
break;
|
|
58
64
|
default:
|
|
59
65
|
throw new Error(`<${exports.configKeyCommandArg}> value not one of supported types: ${JSON.stringify(configKeys_1.validConfigKeyChoices)}`);
|
|
60
66
|
}
|
package/commands/constants.js
CHANGED
|
@@ -107,11 +107,10 @@ exports.DefaultOutputFormatChoices = [
|
|
|
107
107
|
OutputFormats.Yaml,
|
|
108
108
|
];
|
|
109
109
|
exports.DefaultBranchName = 'master';
|
|
110
|
-
exports.DefaultBrowserType = browserTypes_1.
|
|
110
|
+
exports.DefaultBrowserType = browserTypes_1.BrowserTypes.Chrome;
|
|
111
111
|
exports.BrowserTypeSelections = [
|
|
112
|
-
browserTypes_1.
|
|
113
|
-
browserTypes_1.
|
|
114
|
-
browserTypes_1.
|
|
115
|
-
browserTypes_1.
|
|
116
|
-
browserTypes_1.BrowserType.Safari,
|
|
112
|
+
browserTypes_1.BrowserTypes.Chrome,
|
|
113
|
+
browserTypes_1.BrowserTypes.Firefox,
|
|
114
|
+
browserTypes_1.BrowserTypes.InternetExplorer,
|
|
115
|
+
browserTypes_1.BrowserTypes.Safari,
|
|
117
116
|
].map((browser) => browser.toString());
|
|
@@ -106,23 +106,39 @@ async function findChrome() {
|
|
|
106
106
|
return chromePath;
|
|
107
107
|
}
|
|
108
108
|
exports.findChrome = findChrome;
|
|
109
|
-
async function launchBrowserInstance(launchArgs, userDataDir, headless, credentials, options) {
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
109
|
+
async function launchBrowserInstance(chromePath, launchArgs, userDataDir, headless, credentials, options) {
|
|
110
|
+
var _a;
|
|
111
|
+
let browser;
|
|
112
|
+
const proxyServer = (_a = (await cliConfigProvider_1.CliConfigProvider.getCliConfig()).http.test
|
|
113
|
+
.proxyHost) === null || _a === void 0 ? void 0 : _a.href;
|
|
114
|
+
let optionsProxy;
|
|
115
|
+
if ((options === null || options === void 0 ? void 0 : options.proxy) !== undefined) {
|
|
116
|
+
optionsProxy = {
|
|
117
|
+
server: options.proxy.server,
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
else if (proxyServer !== undefined) {
|
|
121
|
+
optionsProxy = {
|
|
122
|
+
server: proxyServer,
|
|
115
123
|
};
|
|
116
124
|
}
|
|
117
|
-
let browser;
|
|
118
125
|
try {
|
|
119
|
-
browser = await maybeLaunchBrowser(launchArgs, userDataDir, headless, credentials,
|
|
126
|
+
browser = await maybeLaunchBrowser(chromePath, launchArgs, userDataDir, headless, credentials, {
|
|
127
|
+
...options,
|
|
128
|
+
proxy: optionsProxy,
|
|
129
|
+
});
|
|
120
130
|
}
|
|
121
131
|
catch (error) {
|
|
122
132
|
if (error.message.includes('Running as root without --no-sandbox is not supported')) {
|
|
123
133
|
launchArgs.push('--no-sandbox');
|
|
124
134
|
messaging_1.mablEventEmitter.log('Unable to initialize browser with standard settings, attempting to run with --no-sandbox setting', Date.now(), logLineMessaging_1.LogLineColor.yellow);
|
|
125
|
-
return maybeLaunchBrowser(launchArgs, userDataDir, headless, credentials,
|
|
135
|
+
return maybeLaunchBrowser(chromePath, launchArgs, userDataDir, headless, credentials, {
|
|
136
|
+
bypassContentSecurityPolicy: options === null || options === void 0 ? void 0 : options.bypassContentSecurityPolicy,
|
|
137
|
+
defaultDeviceDescriptor: options === null || options === void 0 ? void 0 : options.defaultDeviceDescriptor,
|
|
138
|
+
ignoreDefaultArgs: options === null || options === void 0 ? void 0 : options.ignoreDefaultArgs,
|
|
139
|
+
proxy: options === null || options === void 0 ? void 0 : options.proxy,
|
|
140
|
+
runnerType: options === null || options === void 0 ? void 0 : options.runnerType,
|
|
141
|
+
}).catch((error) => {
|
|
126
142
|
messaging_1.mablEventEmitter.log('Browser launch failed', Date.now(), logLineMessaging_1.LogLineColor.red);
|
|
127
143
|
messaging_1.mablEventEmitter.log(error.message);
|
|
128
144
|
});
|
|
@@ -132,26 +148,10 @@ async function launchBrowserInstance(launchArgs, userDataDir, headless, credenti
|
|
|
132
148
|
}
|
|
133
149
|
return browser;
|
|
134
150
|
}
|
|
135
|
-
|
|
136
|
-
var _a;
|
|
137
|
-
const proxyServer = (_a = (await cliConfigProvider_1.CliConfigProvider.getCliConfig()).http.test
|
|
138
|
-
.proxyHost) === null || _a === void 0 ? void 0 : _a.href;
|
|
139
|
-
let optionsProxy;
|
|
140
|
-
if (options === null || options === void 0 ? void 0 : options.proxy) {
|
|
141
|
-
optionsProxy = {
|
|
142
|
-
server: options.proxy.server,
|
|
143
|
-
};
|
|
144
|
-
}
|
|
145
|
-
else if (proxyServer) {
|
|
146
|
-
optionsProxy = {
|
|
147
|
-
server: proxyServer,
|
|
148
|
-
};
|
|
149
|
-
}
|
|
150
|
-
return optionsProxy;
|
|
151
|
-
}
|
|
152
|
-
function maybeLaunchBrowser(launchArgs, userDataDir, headless, credentials, options) {
|
|
151
|
+
function maybeLaunchBrowser(chromePath, launchArgs, userDataDir, headless, credentials, options) {
|
|
153
152
|
return browserLauncher_1.BrowserLauncherFactory.createRunner(options === null || options === void 0 ? void 0 : options.runnerType, options === null || options === void 0 ? void 0 : options.loggerFunc).launch({
|
|
154
153
|
...options,
|
|
154
|
+
executablePath: chromePath,
|
|
155
155
|
headless,
|
|
156
156
|
args: launchArgs,
|
|
157
157
|
userDataDir,
|
|
@@ -182,7 +182,12 @@ function removeTempBrowserPreferencesDirectory(tempDirPath) {
|
|
|
182
182
|
}
|
|
183
183
|
async function createBrowser(browserWidth, browserHeight, headless, containerTesting, tempBrowserPreferencesDirectory, options) {
|
|
184
184
|
var _a;
|
|
185
|
-
const { credentials, disableIsolation, ignoreCertificateErrors, emulationConfig, enableExtensions, resourcesDirectoryOverride, } = options || {};
|
|
185
|
+
const { credentials, browserPath, disableIsolation, ignoreCertificateErrors, emulationConfig, enableExtensions, resourcesDirectoryOverride, } = options || {};
|
|
186
|
+
const chromePath = browserPath !== null && browserPath !== void 0 ? browserPath : (await findChrome());
|
|
187
|
+
if (!chromePath.length) {
|
|
188
|
+
messaging_1.mablEventEmitter.log(chalk.yellow('Could not find a local install of Chrome to use, please ensure you have it installed and try again'));
|
|
189
|
+
throw new Error('Chrome not found error');
|
|
190
|
+
}
|
|
186
191
|
const disableFeaturesFlags = [];
|
|
187
192
|
const launchArgs = [];
|
|
188
193
|
if (containerTesting) {
|
|
@@ -203,7 +208,7 @@ async function createBrowser(browserWidth, browserHeight, headless, containerTes
|
|
|
203
208
|
if (enableExtensions) {
|
|
204
209
|
ignoreDefaultArgs = ['--disable-extensions'];
|
|
205
210
|
}
|
|
206
|
-
const maybeBrowser = await launchBrowserInstance(launchArgs, tempBrowserPreferencesDirectory, headless, credentials, {
|
|
211
|
+
const maybeBrowser = await launchBrowserInstance(chromePath, launchArgs, tempBrowserPreferencesDirectory, headless, credentials, {
|
|
207
212
|
...options,
|
|
208
213
|
defaultDeviceDescriptor,
|
|
209
214
|
ignoreDefaultArgs,
|
|
@@ -247,18 +252,15 @@ function addExecutionEngineLaunchArgs(browserWidth, browserHeight, proxyInfo, em
|
|
|
247
252
|
}
|
|
248
253
|
exports.addExecutionEngineLaunchArgs = addExecutionEngineLaunchArgs;
|
|
249
254
|
async function createBrowserForExecutionEngine(browserWidth, browserHeight, headless, tempBrowserPreferencesDirectory, proxyInfo, options) {
|
|
250
|
-
const { credentials,
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
options = { ...options, defaultDeviceDescriptor };
|
|
260
|
-
}
|
|
261
|
-
const maybeBrowser = await maybeLaunchBrowser(launchArgs, tempBrowserPreferencesDirectory, headless, credentials, options);
|
|
255
|
+
const { credentials, browserPath, emulationConfig, runnerType, loggerFunc } = options || {};
|
|
256
|
+
const chromePath = browserPath !== null && browserPath !== void 0 ? browserPath : (await findChrome());
|
|
257
|
+
const { launchArgs, defaultDeviceDescriptor } = addExecutionEngineLaunchArgs(browserWidth, browserHeight, proxyInfo, emulationConfig);
|
|
258
|
+
const maybeBrowser = await maybeLaunchBrowser(chromePath, launchArgs, tempBrowserPreferencesDirectory, headless, credentials, {
|
|
259
|
+
defaultDeviceDescriptor,
|
|
260
|
+
runnerType,
|
|
261
|
+
loggerFunc,
|
|
262
|
+
userAgent: emulationConfig === null || emulationConfig === void 0 ? void 0 : emulationConfig.device_config.user_agent,
|
|
263
|
+
});
|
|
262
264
|
if (!maybeBrowser) {
|
|
263
265
|
throw new Error('Unable to start Chrome session');
|
|
264
266
|
}
|
|
@@ -56,9 +56,9 @@ exports.builder = (yargs) => {
|
|
|
56
56
|
})
|
|
57
57
|
.option(constants_1.CommandArgBrowsers, {
|
|
58
58
|
alias: constants_1.CommandArgAliases.Browsers,
|
|
59
|
-
describe: 'Space delimited browsers to test against (e.g. "chrome
|
|
59
|
+
describe: 'Space delimited browsers to test against (e.g. "chrome firefox")',
|
|
60
60
|
type: 'array',
|
|
61
|
-
default: constants_1.DefaultBrowserType,
|
|
61
|
+
default: constants_1.DefaultBrowserType.toString(),
|
|
62
62
|
choices: constants_1.BrowserTypeSelections,
|
|
63
63
|
demand: 'Choose at least one browser to run on',
|
|
64
64
|
})
|
|
@@ -7,7 +7,6 @@ const constants_1 = require("../../constants");
|
|
|
7
7
|
const loggingProvider_1 = require("../../../providers/logging/loggingProvider");
|
|
8
8
|
const mablApi_1 = require("../../../mablApi");
|
|
9
9
|
const reporter_1 = require("../../../reporters/reporter");
|
|
10
|
-
const browserTypes_1 = require("../../browserTypes");
|
|
11
10
|
const chalk = require('chalk');
|
|
12
11
|
const execution = require('../../../execution/index');
|
|
13
12
|
exports.command = `run`;
|
|
@@ -189,7 +188,6 @@ async function run(parsed) {
|
|
|
189
188
|
_cliCreated: true,
|
|
190
189
|
basicAuthCredentialsId: parsed[constants_1.CommandArgBasicAuthCredentials],
|
|
191
190
|
branchName: parsed['mabl-branch'],
|
|
192
|
-
browserType: browserTypes_1.BrowserType.Chrome,
|
|
193
191
|
credentialsId: parsed['credentials-id'],
|
|
194
192
|
disableIsolation: parsed[constants_1.CommandArgBrowserDisableIsolation],
|
|
195
193
|
enableExtensions: parsed[constants_1.CommandArgBrowserEnableExtensions],
|
package/domUtil/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.domUtil=t():e.domUtil=t()}(global,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=4)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.containsMablTemplatePattern=t.isString=t.isNestableElement=t.LONE_VARIABLE_REGEXP=t.FAKER_FORMAT_IN_EXPRESSION_REGEX_CREATE=t.FAKER_EXPRESSION_REGEXP_CREATE=t.FAKER_EXPRESSION_NAMED_GROUP=t.FAKER_EXPRESSION=t.FAKE_NAMESPACE=t.FAKER_GROUP_NAME=t.RANDOM_FORMAT_IN_EXPRESSION_REGEXP_CREATE=t.RANDOM_FORMAT_REGEXP_CREATE=t.RANDOM_FORMAT=t.LENGTH_GROUP=t.LENGTH_GROUP_NAME=t.ALPHABET_GROUP=t.RANDOM_STRING_CHOICES=t.ALPHABET_GROUP_NAME=t.CURRENT_DATE_REGEXP_CREATE=t.CURRENT_DATE_NAME_GROUP=t.CURRENT_DATE_GROUP_NAME=t.VARIABLE_IN_EXPRESSION_REGEXP_CREATE=t.SINGLE_VARIABLE_REGEX_CREATE=t.VARIABLE_GROUP=t.VARIABLE_GROUP_NAME=t.EXCLUDED_USER_VARIABLE_NAMES=t.ALL_VARIABLE_REGEXP_CREATE=t.COMPOUND_VARIABLE_PATTERN=t.USER_VARIABLE_REGEXP_CREATE=t.VARIABLE_REGEXP=t.INDEX_EXPRESSION_REGEXP=t.DOUBLE_QUOTED_IDENTIFIER_REGEXP=t.SINGLE_QUOTED_IDENTIFIER_REGEXP=t.ARRAY_INDEX_REGEXP=t.IDENTIFIER_REGEXP=t.USER_NAMESPACE_REGEXP=t.PATTERN_REGEXP=t.patternRanges=void 0,t.patternRanges={alpha:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",alphaLower:"abcdefghijklmnopqrstuvwxyz",alphaUpper:"ABCDEFGHIJKLMNOPQRSTUVWXYZ",digit:"0123456789",alnum:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"},t.PATTERN_REGEXP=/{{([^{}]*)}}/gi,t.USER_NAMESPACE_REGEXP=/^user\./g,t.IDENTIFIER_REGEXP="[a-zA-Z_][a-zA-Z0-9_]*",t.ARRAY_INDEX_REGEXP="[0-9]+",t.SINGLE_QUOTED_IDENTIFIER_REGEXP=`'${t.IDENTIFIER_REGEXP}'`,t.DOUBLE_QUOTED_IDENTIFIER_REGEXP=`"${t.IDENTIFIER_REGEXP}"`,t.INDEX_EXPRESSION_REGEXP=`\\[(?:${t.ARRAY_INDEX_REGEXP}|${t.SINGLE_QUOTED_IDENTIFIER_REGEXP}|${t.DOUBLE_QUOTED_IDENTIFIER_REGEXP})\\]`,t.VARIABLE_REGEXP=`${t.IDENTIFIER_REGEXP}(?:${t.INDEX_EXPRESSION_REGEXP})*`;t.USER_VARIABLE_REGEXP_CREATE=()=>RegExp("^"+t.IDENTIFIER_REGEXP+"$"),t.COMPOUND_VARIABLE_PATTERN=`(${t.VARIABLE_REGEXP})(\\.(${t.VARIABLE_REGEXP}))*`;t.ALL_VARIABLE_REGEXP_CREATE=()=>RegExp("^"+t.COMPOUND_VARIABLE_PATTERN+"$"),t.EXCLUDED_USER_VARIABLE_NAMES=["user","web","mail","api"],t.VARIABLE_GROUP_NAME="variable",t.VARIABLE_GROUP="(?<"+t.VARIABLE_GROUP_NAME+">"+t.COMPOUND_VARIABLE_PATTERN+")";t.SINGLE_VARIABLE_REGEX_CREATE=()=>RegExp("{{@"+t.VARIABLE_GROUP+"}}");t.VARIABLE_IN_EXPRESSION_REGEXP_CREATE=()=>RegExp("@"+t.VARIABLE_GROUP,"g"),t.CURRENT_DATE_GROUP_NAME="date",t.CURRENT_DATE_NAME_GROUP="(?<"+t.CURRENT_DATE_GROUP_NAME+">date)";t.CURRENT_DATE_REGEXP_CREATE=()=>RegExp("{{"+t.CURRENT_DATE_NAME_GROUP+"(:iso)?}}"),t.ALPHABET_GROUP_NAME="alphabet",t.RANDOM_STRING_CHOICES=Object.keys(t.patternRanges).join("|"),t.ALPHABET_GROUP="(?<"+t.ALPHABET_GROUP_NAME+">"+t.RANDOM_STRING_CHOICES+")",t.LENGTH_GROUP_NAME="length",t.LENGTH_GROUP="(?<"+t.LENGTH_GROUP_NAME+">[\\d]+)",t.RANDOM_FORMAT=t.ALPHABET_GROUP+":"+t.LENGTH_GROUP;t.RANDOM_FORMAT_REGEXP_CREATE=()=>RegExp("{{"+t.RANDOM_FORMAT+"}}");t.RANDOM_FORMAT_IN_EXPRESSION_REGEXP_CREATE=()=>RegExp(t.RANDOM_FORMAT,"g"),t.FAKER_GROUP_NAME="faker",t.FAKE_NAMESPACE="fake.",t.FAKER_EXPRESSION=t.FAKE_NAMESPACE+"[a-zA-Z]+\\.[a-zA-Z]+(\\((\\d+)\\))?",t.FAKER_EXPRESSION_NAMED_GROUP="(?<"+t.FAKER_GROUP_NAME+">{{"+t.FAKER_EXPRESSION+"}})";t.FAKER_EXPRESSION_REGEXP_CREATE=()=>RegExp(t.FAKER_EXPRESSION_NAMED_GROUP);t.FAKER_FORMAT_IN_EXPRESSION_REGEX_CREATE=()=>RegExp("("+t.FAKER_EXPRESSION+")","g"),t.LONE_VARIABLE_REGEXP="^{{@"+t.VARIABLE_GROUP+"}}$",t.isNestableElement=function(e){return e instanceof Object||e instanceof Array},t.isString=function(e){return e&&e instanceof String||"string"==typeof e},t.containsMablTemplatePattern=function(e){return!!e&&e.search(t.PATTERN_REGEXP)>=0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ALL_ATTR_PROPS_OPTIONS=t.ALLOWED_ASSERTIBLE_ATTRS_PROPS=t.ASSERTIBLE_ATTRIBUTE_TYPES=void 0,t.ASSERTIBLE_ATTRIBUTE_TYPES=["string","number","boolean"],t.ALLOWED_ASSERTIBLE_ATTRS_PROPS=["accessKey","accessKeyLabel ","align","alt","aria-checked","aria-label","aria-labelledby","aria-disabled","autofocus","border","checked","class","className","clientHeight","clientLeft","clientTop","clientWidth","complete","computedName","computedRole","contentEditable","contextMenu","crossOrigin","currentSrc","dataset ","defaultChecked","defaultValue","dir","disabled","draggable","formEncType","formMethod","formNoValidate","formTarget","height","hidden","href","hspace","id","indeterminate","inert","innerText","isContentEditable ","isMap","itemId ","itemScope ","lang","length","localName","longDesc","lowSrc","maxLength","multiple","name","namespaceURI","naturalHeight","naturalWidth","noModule","offsetHeight ","offsetLeft","offsetTop","offsetWidth","prefix","referrerPolicy","required","selectedIndex","size","sizes","slot","src","srcset","tabIndex","tagName","title","translate","type","validationMessage","validity","value","vspace","width","willValidate"],t.ALL_ATTR_PROPS_OPTIONS={},t.ALLOWED_ASSERTIBLE_ATTRS_PROPS.forEach(e=>t.ALL_ATTR_PROPS_OPTIONS[e]="")},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.MablscriptUtils=t.replaceVariables=t.findVariables=t.b64DecodeUnicode=t.b64EncodeUnicode=t.buildStepArgumentString=t.isValidVariableName=t.isValidUserVariableName=t.getVariableNameFromLoneVariablePattern=t.isLoneVariablePattern=t.unescapeMablscriptString=t.escapeMablscriptString=void 0;const a=n(0);function l(e){return"string"==typeof e?e.replace(/\\/g,"\\\\").replace(/\n/g,"\\n").replace(/"/g,'\\"').replace(/\r/g,""):""}function c(e){return!!e&&RegExp(a.LONE_VARIABLE_REGEXP).test(e)}t.escapeMablscriptString=l,t.unescapeMablscriptString=function(e){return"string"==typeof e?e.replace(/\\"/g,'"').replace(/\\n/g,"\n").replace(/\\\\/g,"\\"):""},t.isLoneVariablePattern=c,t.getVariableNameFromLoneVariablePattern=function(e){var t,n;if(c(e)){const r=RegExp(a.LONE_VARIABLE_REGEXP);return null===(n=null===(t=e.match(r))||void 0===t?void 0:t.groups)||void 0===n?void 0:n[a.VARIABLE_GROUP_NAME]}},t.isValidUserVariableName=function(e){return!!e&&((0,a.USER_VARIABLE_REGEXP_CREATE)().test(e)&&-1===a.EXCLUDED_USER_VARIABLE_NAMES.indexOf(e))},t.isValidVariableName=function(e){return!!e&&(0,a.ALL_VARIABLE_REGEXP_CREATE)().test(e)},t.buildStepArgumentString=function e(t){switch(typeof t){case"string":return`"${l(t)}"`;case"boolean":case"number":return""+t;case"object":{if(t instanceof Array)return`[${t.map(e).join(",")}]`;const n=[];return Object.keys(t).forEach(r=>{const i=e(t[r]);"string"==typeof r&&r&&"string"==typeof i&&i&&n.push(`"${r}":${i}`)}),n.sort(),`{${n.join(",")}}`}default:return}},t.b64EncodeUnicode=function(e){return btoa(encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,(function(e,t){return String.fromCharCode(parseInt("0x"+t,16))})))},t.b64DecodeUnicode=function(e){try{return decodeURIComponent(atob(e).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))}catch(t){return atob(e)}},t.findVariables=function(e){const t=null==e?void 0:e.match(a.PATTERN_REGEXP);return(null==t?void 0:t.reduce((e,t)=>{const n=null==t?void 0:t.match((0,a.VARIABLE_IN_EXPRESSION_REGEXP_CREATE)());return null==n||n.forEach(t=>e.push(t.substring(1))),e},[]))||[]},t.replaceVariables=function(e,t){return null===e?null:null==e?void 0:e.replace(a.PATTERN_REGEXP,e=>e.replace((0,a.VARIABLE_IN_EXPRESSION_REGEXP_CREATE)(),t))},t.MablscriptUtils=o(n(2))},function(e,t,n){"use strict";function r(e){return void 0!==e.tag_name&&("input"===e.tag_name.toLowerCase()?!e.inputElementType||-1===["radio","button","submit","reset"].indexOf(e.inputElementType.toLowerCase()):-1===["button","option","li","param"].indexOf(e.tag_name.toLowerCase()))}function i(e){return e&&void 0!==e.uuid&&void 0!==e.xpath}Object.defineProperty(t,"__esModule",{value:!0}),t.areSelectorsEqual=t.stripLocatorContextFromSelector=t.isCompositeSelector=t.isStandardSelector=t.isCookieSelector=t.isEmailSelector=t.isTabSelector=t.isCssSelector=t.isXPathSelector=t.ignoreValueAttribute=t.SELECTOR_ATTRIBUTE_KEYS=t.SELECTOR_EQUIVALENCE_IGNORED_KEYS=t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP=t.isSimpleElementSelectorCommonKeys=void 0,t.isSimpleElementSelectorCommonKeys=function(e){return"string"==typeof e&&!["css_query","repeat_xpaths","selector_type","tag_name","uuid","xpath"].includes(e)},t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP={elementId:"id",name:"name",href:"href",inputElementType:"inputElementType",label:"label",placeholder:"placeholder",tagName:"tag_name",text:"text",slotText:"slot_text",url:"url",title:"title",uuid:"uuid",xPath:"xpath",cssQuery:"css_query",className:"class_name",src:"src",alt:"alt",form:"form",for:"for_attr",target:"target",inputValue:"value",dataTracking:"data_tracking",titleAttr:"title_attr",ariaLabel:"aria_label",labelAttr:"label_attr",dataAutomationId:"data_automation_id",dataTestId:"data_test_id",dataTestid:"data_testid",testId:"test_id",ngModel:"ng_model",ngShow:"ng_show",ariaOwns:"aria_owns",ariaLabelledby:"aria_labelledby",ngClass:"ng_class",ariaControls:"aria_controls",tabindex:"tabindex",role:"role",maxlength:"maxlength",autocomplete:"autocomplete",height:"height",width:"width",style:"style",boundingX:"bounding_x",boundingY:"bounding_y",boundingHeight:"bounding_height",boundingWidth:"bounding_width",visible:"visible",dataTarget:"data_target",dataValue:"data_value",dataId:"data_id",dataName:"data_name",dataProp:"data_prop",index:"index",item:"item"},t.SELECTOR_EQUIVALENCE_IGNORED_KEYS={aria_owns:()=>!0,bounding_x:()=>!0,bounding_y:()=>!0,bounding_height:()=>!0,bounding_width:()=>!0,class_name:()=>!0,style:()=>!0,title_attr:function(e){if(void 0===e.tag_name)return!1;return["input","textarea"].includes(e.tag_name.toLowerCase())},uuid:()=>!0,value:r},t.SELECTOR_ATTRIBUTE_KEYS=Object.keys(t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP).map(e=>t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP[e]),t.ignoreValueAttribute=r,t.isXPathSelector=function(e){return e&&void 0!==e.xpath},t.isCssSelector=function(e){return e&&void 0!==e.css_query},t.isTabSelector=function(e){return e&&"tab"===e.selector_type&&void 0!==e.url},t.isEmailSelector=function(e){return e&&"email"===e.selector_type},t.isCookieSelector=function(e){return e&&void 0!==e.name},t.isStandardSelector=i,t.isCompositeSelector=function(e){return e&&e.length>=1&&e.every(i)},t.stripLocatorContextFromSelector=function(e){const{currentContextNode:t,...n}=e;return n},t.areSelectorsEqual=function(e,t){if(void 0===e)return void 0===t;if(void 0===t)return!1;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const r of n)if(e[r]!==t[r])return!1;return!0}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),i(n(5),t)},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),i(n(6),t),i(n(7),t),i(n(1),t),i(n(2),t),i(n(9),t),i(n(3),t),i(n(10),t),i(n(0),t)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.adjustTarget=t.removeOverlayById=t.destroySelectionOverlay=t.highlightElements=t.highlightElement=t.positionSelectionHighlight=t.renderSelectionOverlay=t.xpathElement=t.createXpathFromPathArray=t.sanitizeXPath=t.getAncestorElements=t.isSelect=t.isFileInput=t.isTextField=t.isInputField=t.getInputTypeFromElement=t.getPlaceholderFromElement=t.getAnchorHrefFromElement=t.getInputLabelFromElement=t.getLabelForInput=t.normalizeText=t.truncateText=t.getSlotTextFromElement=t.getTextFromElement=t.compactWhitespace=t.createXPathFromElement=t.getIframesInfo=t.getAttributePropertyMap=t.getSelectedTextFromElement=t.getClassNameFromElement=t.getSelectedIndexFromElement=t.getElementValueFromElement=t.getNodeNameFromElement=t.getTagNameFromElement=t.getNameFromElement=t.getIdFromElement=t.createIgnoredDomElement=t.createBaseEventMessage=t.getAttributeFromElement=t.getPropertyFromElement=t.MAX_ATTRIBUTE_SIZE=t.MAX_SELECTOR_INNER_TEXT_LENGTH=t.MABL_INSERTED_ELEMENTS=t.MABL_SECONDARY_DRAGGABLE_DIV_ID=t.MABL_TERTIARY_IFRAME_ID=t.MABL_IGNORE_ELEMENT_CLASS=t.MABL_DRAGGABLE_DIV_ID=t.MABL_SECONDARY_IFRAME_ID=t.MABL_HIGHLIGHT_ID=t.MABL_OVERLAY_ID=void 0,t.isElementInShadowRoot=t.isExpectedToBeInvisible=t.isDisplayed=t.getInnerText=t.getElementByXpath=t.getAllElementsByXpath=t.getFirstElementBySelectors=t.getLastElementBySelectors=t.getAllElementBySelectors=t.destroyElement=t.getElementMatchingSelectionTarget=t.selectOption=void 0;const r=n(1);t.MABL_OVERLAY_ID="mabl-selection-overlay-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_HIGHLIGHT_ID="mabl-selection-highlight-22b76b1b-4c57-4644-98ab-6f2ff555d1cc";const i="mabl-selection-overlay-22b76b1b-4c57-4644-98ab-6f2ff555d1cc";var o;t.MABL_SECONDARY_IFRAME_ID="mabl-secondary-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_DRAGGABLE_DIV_ID="mabl-draggable-div-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_IGNORE_ELEMENT_CLASS="mabl-element-ignore-actions",t.MABL_TERTIARY_IFRAME_ID="mabl-tertiary-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_SECONDARY_DRAGGABLE_DIV_ID="mabl-secondary-draggable-div-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_INSERTED_ELEMENTS=[t.MABL_OVERLAY_ID,t.MABL_HIGHLIGHT_ID,i,"mabl-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc","mabl-iframe-draggable-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_SECONDARY_IFRAME_ID,t.MABL_DRAGGABLE_DIV_ID],function(e){e[e["accessibility-check"]=0]="accessibility-check",e[e["assert-cookie"]=1]="assert-cookie",e[e["assert-email"]=2]="assert-email",e[e["assert-variable"]=3]="assert-variable",e[e["await-tab"]=4]="await-tab",e[e["await-uploads"]=5]="await-uploads",e[e["clear-cookies"]=6]="clear-cookies",e[e.click=7]="click",e[e.click_hold=8]="click_hold",e[e.conditional_else=9]="conditional_else",e[e.conditional_end=10]="conditional_end",e[e["double-click"]=11]="double-click",e[e.download=12]="download",e[e["download-pdf"]=13]="download-pdf",e[e.echo=14]="echo",e[e["end-flow"]=15]="end-flow",e[e["evaluate-js-snippet"]=16]="evaluate-js-snippet",e[e.hover=17]="hover",e[e.input=18]="input",e[e.keypress=19]="keypress",e[e.location=20]="location",e[e["mouse-select"]=21]="mouse-select",e[e.navigation=22]="navigation",e[e["open-email"]=23]="open-email",e[e.release=24]="release",e[e["remove-cookie"]=25]="remove-cookie",e[e["send-http-request"]=26]="send-http-request",e[e["set-cookie"]=27]="set-cookie",e[e["set-files"]=28]="set-files",e[e["set-variable"]=29]="set-variable",e[e["start-flow"]=30]="start-flow",e[e["switch-context-to"]=31]="switch-context-to",e[e["synthetic-click"]=32]="synthetic-click",e[e.url=33]="url",e[e["visit-url"]=34]="visit-url",e[e.viewport=35]="viewport",e[e.wait=36]="wait"}(o||(o={}));const a=["button","checkbox","file","radio","reset","submit"];function l(e,t){return _(e[t])}function c(e,t){return _(e.getAttribute(t))}t.MAX_SELECTOR_INNER_TEXT_LENGTH=300,t.MAX_ATTRIBUTE_SIZE=5e3,t.getPropertyFromElement=l,t.getAttributeFromElement=c;const u=[{name:"src",attribute:"src",handler:l},{name:"elementId",attribute:"id",handler:E},{name:"tagName",handler:f},{name:"text",handler:h},{name:"slotText",handler:T},{name:"label",handler:O},{name:"href",attribute:"href",handler:S},{name:"placeholder",attribute:"placeholder",handler:N},{name:"inputElementType",attribute:"type",handler:P},{name:"inputValue",attribute:"value",handler:m},{name:"className",attribute:"class",handler:R},{name:"visible",handler:function(e){return j(e).toString()}},...[{name:"alt",attribute:"alt"},{name:"form",attribute:"form"},{name:"for",attribute:"for"},{name:"target",attribute:"target"},{name:"name",attribute:"name"},{name:"target",attribute:"target"},{name:"name",attribute:"name"},{name:"dataTracking",attribute:"data-tracking"},{name:"titleAttr",attribute:"title"},{name:"ariaLabel",attribute:"aria-label"},{name:"labelAttr",attribute:"label"},{name:"dataAutomationId",attribute:"data-automation-id"},{name:"dataTestId",attribute:"data-test-id"},{name:"dataTestid",attribute:"data-testid"},{name:"testId",attribute:"test-id"},{name:"ngModel",attribute:"ng-model"},{name:"ngShow",attribute:"ng-show"},{name:"ngClass",attribute:"ng-class"},{name:"ariaOwns",attribute:"aria-owns"},{name:"ariaLabelledby",attribute:"aria-labelledby"},{name:"ariaControls",attribute:"aria-controls"},{name:"tabindex",attribute:"tabindex"},{name:"role",attribute:"role"},{name:"maxlength",attribute:"maxlength"},{name:"autocomplete",attribute:"autocomplete"},{name:"height",attribute:"height"},{name:"width",attribute:"width"},{name:"style",attribute:"style"},{name:"dataTarget",attribute:"data-target"},{name:"dataValue",attribute:"data-value"},{name:"dataId",attribute:"data-id"},{name:"dataName",attribute:"data-name"},{name:"dataProp",attribute:"data-prop"},{name:"index",attribute:"index"},{name:"item",attribute:"item"}].map(e=>({...e,handler:c}))],s=[{propertyName:"slotText",extractor:T}];function d(e,t,n,r,i){const o={action:t,listener:n,xPath:r,context:i};return u.forEach(t=>{const n=t.handler(e,t.attribute||t.name);o[t.name]=n}),o}function E(e){return _(e.id)}function _(e){var n;return("string"!=typeof e||e.length<t.MAX_ATTRIBUTE_SIZE)&&null!==(n=e)&&void 0!==n?n:void 0}function f(e){var t;return null===(t=null==e?void 0:e.tagName)||void 0===t?void 0:t.toLowerCase()}function p(e){var t;return _(null===(t=null==e?void 0:e.nodeName)||void 0===t?void 0:t.toLowerCase())}function m(e){return _(e.value)}function R(e){return _(e.className)}function A(e){return function e(t,n){const r=null==t?void 0:t.parentElement;if(r){const i=M(t,r);return e(r,`/${i}${n}`)}if(H(t)){return D(`//${M(t,t.getRootNode())}${n}`)}return D("//html[1]"+n)}(e,"")}function b(e){var t;return null===(t=null==e?void 0:e.replace(/[ \t\xA0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\n\x0B\f\r\x85\u2028\u2029]+/g," "))||void 0===t?void 0:t.trim()}function g(e){return b(e).substring(0,t.MAX_SELECTOR_INNER_TEXT_LENGTH).replace(/"/g,'\\"')}function h(e){return g(e.innerText||"")}function T(e){const t=e.querySelectorAll("slot");if(1!==t.length)return;const n=t.item(0).assignedNodes().find(e=>e.nodeType===Node.TEXT_NODE);return n?g(n.data):void 0}function v(e,t){var n;return null!==(n=null==e?void 0:e.substring(0,t))&&void 0!==n?n:e}function y(e,n=!0){const r=b(e);return r&&n?v(r,t.MAX_SELECTOR_INNER_TEXT_LENGTH):r}function I(e){if(!e||!L(e))return;const t=e.closest("label");if(t)return t;if(e.id){const t=(""+(e.id||"")).replace(/'/g,"\\'"),n=document.querySelector(`label[for='${t}']`);if(n)return n}const n=w("(./preceding-sibling::*//descendant-or-self::*[self::input|self::label])[last()]",e);if(n.length>0){const e=n[0];if("label"===f(e)&&!e.getAttribute("for"))return e}const r=w("(../preceding-sibling::*//descendant-or-self::*[self::input|self::label])[last()]",e);if(r.length>0){const e=r[0];if("label"===f(e)&&!e.getAttribute("for"))return e}}function O(e){const t=I(e);if(t)return h(t)}function S(e){if("a"===f(e))return _(e.href)}function N(e){if(L(e))return _(e.placeholder)}function P(e){if(L(e))return e.type||"text"}function L(e){const t=f(e);return"input"===t||"textarea"===t}function D(e){return(e=e.replace("*[local-name()='#document-fragment']/shadow[1]/body","body[1]")).replace(/#document-fragment\[0]\/shadow\[1]\/body\[0]/,"body[1]")}function M(e,t){let n;const r=p(e);n=r?e instanceof HTMLElement&&!(null==r?void 0:r.includes(":"))?r:`*[local-name()='${r}']`:"*";const i=function(e,t){let n=-1;const r=p(e);if(!r)return n;for(const i in t)if(null==t?void 0:t.hasOwnProperty(i)){const o=t[i];if(p(o)===r&&(n+=1,o===e))return n}return n}(e,t.children)+1;return i?`${n}[${i}]`:""+n}function x(){const e=document.createElement("div");return e.id=t.MABL_HIGHLIGHT_ID,e.classList.add(i),e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.width="0",e.style.height="0",e.style.borderStyle="solid",e.style.borderWidth="2px",e.style.borderColor="black",e}function F(e,n,r){const i=e.getBoundingClientRect(),o=x();o.id=`${t.MABL_HIGHLIGHT_ID}-${n}`,o.style.left=C(i.x),o.style.top=C(i.y),o.style.width=C(i.width),o.style.height=C(i.height),r.appendChild(o)}function C(e){return Math.round(e)+"px"}function G(e){const t=document.getElementById(e);if(t)try{document.body.removeChild(t)}catch(e){document.documentElement.removeChild(t)}}function B(e){var t;null===(t=null==e?void 0:e.parentNode)||void 0===t||t.removeChild(e)}function U(e){return e.css_query?function(e){const t=document.querySelectorAll(e);return t.item(t.length-1)}(e.value||e.css_query):e.xpath?(t=e.value||e.xpath,null===(r=w(t,n))||void 0===r?void 0:r.pop()):void 0;var t,n,r}function X(e){return e.css_query?document.querySelector(e.value||e.css_query):e.xpath?V(e.value||e.xpath):void 0}function w(e,t=document,n=!0){t=void 0!==t?t:document;const r=[];let i;try{i=document.evaluate(e,t,null,XPathResult.ORDERED_NODE_SNAPSHOT_TYPE,null)}catch(e){if(n&&e instanceof DOMException)return console.log(e),[];throw e}for(let e=0,t=i.snapshotLength;e<t;++e)r.push(i.snapshotItem(e));return r}function V(e,t=document,n=!0){t=void 0!==t?t:document;try{return document.evaluate(e,t,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue}catch(e){if(n&&e instanceof DOMException)return console.log(e),null;throw e}}function j(e){var t;if("input"===f(e)&&"hidden"===(null===(t=e.type)||void 0===t?void 0:t.toLowerCase()))return!1;if(!(e.offsetWidth||e.offsetHeight||e.getClientRects().length))return!1;const n=window.getComputedStyle(e);return(!n||"0"!==n.opacity)&&(n&&"none"!==n.display&&"collapse"!==n.visibility&&"hidden"!==n.visibility)}function H(e){return"#document-fragment"===e.getRootNode().nodeName}t.createBaseEventMessage=d,t.createIgnoredDomElement=function(e){const n=document.createElement(e);return n.className=t.MABL_IGNORE_ELEMENT_CLASS,n},t.getIdFromElement=E,t.getNameFromElement=function(e){return _(e.name)},t.getTagNameFromElement=f,t.getNodeNameFromElement=p,t.getElementValueFromElement=m,t.getSelectedIndexFromElement=function(e){return e.selectedIndex},t.getClassNameFromElement=R,t.getSelectedTextFromElement=function(e){var t;if("select"===f(e)&&(null==e?void 0:e.selectedOptions)&&!((null===(t=null==e?void 0:e.selectedOptions)||void 0===t?void 0:t.length)<1))return e.selectedOptions[0].innerText},t.getAttributePropertyMap=function(e){const t={};for(const n in e)try{const i=e[n],o=typeof i;if(r.ALLOWED_ASSERTIBLE_ATTRS_PROPS.includes(n)&&r.ASSERTIBLE_ATTRIBUTE_TYPES.includes(o)){if(null==i||"string"===o&&!i.length&&"value"!==n)continue;t[n]=y(i.toString(),!1)}}catch(e){console.error("Could not process an attribute/property for element",e)}return e.getAttributeNames().forEach(n=>{if(!(null==t?void 0:t.hasOwnProperty(n))){const r=e.getAttribute(n);t[n]=y(r||"",!1)}}),s.forEach(n=>{const r=n.extractor(e);r&&(t[n.propertyName]=r)}),t},t.getIframesInfo=function(){const e=[];return[].forEach.call(document.getElementsByTagName("iframe"),n=>{if(!t.MABL_INSERTED_ELEMENTS.includes(n.id)){const t=d(n,"record","switch-context-to",A(n));t.absoluteSrc=n.src,e.push(t)}}),e},t.createXPathFromElement=A,t.compactWhitespace=b,t.getTextFromElement=h,t.getSlotTextFromElement=T,t.truncateText=v,t.normalizeText=y,t.getLabelForInput=I,t.getInputLabelFromElement=O,t.getAnchorHrefFromElement=S,t.getPlaceholderFromElement=N,t.getInputTypeFromElement=P,t.isInputField=L,t.isTextField=function(e){const t=f(e),n=e.type;return"input"===t&&!a.includes(n)||"textarea"===t},t.isFileInput=function(e){const t=f(e),n=(e.type||"").toLowerCase();return"input"===t&&"file"===n},t.isSelect=function(e){return"select"===f(e)},t.getAncestorElements=function(e,t=0,n=[]){const r=[],i=n.map(e=>e.toLowerCase());let o=null==e?void 0:e.parentElement;for(;o&&(t<=0||r.length<t);)i.includes(f(o))||r.push(o),o=o.parentElement;return r},t.sanitizeXPath=D,t.createXpathFromPathArray=function(e){return D("//"+e.map((e,t,n)=>{const r=p(e);if(!r)return"";const i=n[t+1];return"#document"!==r&&i&&i?M(e,i):""}).reduce((e,t)=>""===t?e:`${t}/${e}`))},t.xpathElement=M,t.renderSelectionOverlay=function(e){const n=document.createElement("div");n.id=t.MABL_OVERLAY_ID,n.classList.add(i),n.setAttribute("style","\n position: fixed;\n display: none;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: rgba(24,197,207,0.25);\n z-index: 2147483646;\n cursor: pointer;\n display:block;");const r=document.createElement("div");r.classList.add(i),r.innerText=e,r.setAttribute("style","\n position: absolute;\n top: 50%;\n left: 50%;\n font-size: 50px;\n color: white;\n transform: translate(-50%,-50%);\n -ms-transform: translate(-50%,-50%);"),n.appendChild(r);const o=x();n.appendChild(o);try{document.body.appendChild(n)}catch(e){document.documentElement.appendChild(n)}},t.positionSelectionHighlight=function(e){const n=document.elementsFromPoint(e.clientX,e.clientY).find(e=>!e.classList.contains(i));if(!n)return;const r=n.getBoundingClientRect(),o=document.getElementById(t.MABL_HIGHLIGHT_ID);o&&(o.style.left=C(r.x),o.style.top=C(r.y),o.style.width=C(r.width),o.style.height=C(r.height))},t.highlightElement=F,t.highlightElements=function(e){const n=t.MABL_HIGHLIGHT_ID+"-parent";let r=document.getElementById(n);r&&B(r),r=document.createElement("div"),r.id=n,e.length>0&&e.forEach((e,t)=>{F(e,t,r)});const o=document.getElementById(t.MABL_OVERLAY_ID),a=document.createElement("div");a.classList.add(i),a.innerText=e.length+" elements found",a.setAttribute("style","\n position: absolute;\n top: 60%;\n left: 50%;\n font-size: 40px;\n color: white;\n transform: translate(-50%,-50%);\n -ms-transform: translate(-50%,-50%);"),r.appendChild(a),o.appendChild(r)},t.destroySelectionOverlay=function(){G(t.MABL_OVERLAY_ID)},t.removeOverlayById=G,t.adjustTarget=function(e,t){let n=e,r=null==t?void 0:t.slice();for(;n&&!(n instanceof HTMLElement);)n=n.parentElement,null==r||r.pop();const i=function(e,t){const n=f(e);if("button"!==n&&"input"!==n){let e;t.forEach((t,n)=>{var r;const i=null!==(r=f(t))&&void 0!==r?r:"";e||"button"!==i&&"input"!==i||(e=n)}),e&&(t=t.slice(e))}return t}(e,r);return i!==r&&(n=i[0],r=i),function(e){return"html"===f(e)}(n)&&(n=void 0,r=void 0),{path:r,target:n}},t.selectOption=function(e,t,n){e.focus(),"any"===t?e.options.length>1&&0===e.selectedIndex?e.selectedIndex=1:e.selectedIndex=0:e.selectedIndex=[...e.options].findIndex(e=>e.innerText===n),e.dispatchEvent(new Event("change")),e.blur();const r=new InputEvent("input");e.dispatchEvent(r)},t.getElementMatchingSelectionTarget=function(e){return"primarySelectors"in e.find?"find_last"===e.find.type?U(e.find.primarySelectors):X(e.find.primarySelectors):e.xPath?V(e.xPath):void 0},t.destroyElement=B,t.getAllElementBySelectors=function(e){try{if(e.css_query)return document.querySelectorAll(e.value||e.css_query);if(e.xpath)return w(e.value||e.xpath)}catch(e){}return[]},t.getLastElementBySelectors=U,t.getFirstElementBySelectors=X,t.getAllElementsByXpath=w,t.getElementByXpath=V,t.getInnerText=function e(t){const n=f(t)||"";return"select"!==n&&"option"!==n&&"optgroup"!==n?t.innerText||"":j(t)?[("option"===n?t.innerText||t.text:t.innerText)||"",Array.from(t.childNodes||[]).map(e).filter(e=>e).join(" ")].filter(e=>e).join(" "):""},t.isDisplayed=j,t.isExpectedToBeInvisible=function(e){var t;return"input"===f(e)&&"file"===(null===(t=null==e?void 0:e.type)||void 0===t?void 0:t.toLowerCase())},t.isElementInShadowRoot=H},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.isVariable=t.namespace=t.extractVariableObjectByName=t.resolveVariableValue=t.VariableSource=t.VariableType=void 0;const i=r(n(8)),o=n(0);function a(e,t){try{return e[t]||e["user."+t]}catch(e){return}}function l(e,t){const n=e.indexOf(t);return n<0?[e,void 0]:[e.substr(0,n),e.substr(n+1)]}function c(e){return!!e&&"object"==typeof e}!function(e){e.INPUT="input",e.MABL_MAILBOX="mablMailbox",e.JAVASCRIPT="javascript",e.GENERATED="generated",e.ELEMENT_PROPERTY="elementProperty",e.ELEMENT_COUNT="elementCount"}(t.VariableType||(t.VariableType={})),function(e){e.PLAN="Plan",e.JOURNEY_VAR="Default value",e.RUNTIME="Runtime",e.DDT="DataTable",e.ENV="Environment",e.MABL_MAIL="mabl Mailbox",e.JAVASCRIPT="JavaScript",e.ELEMENT_PROP="Element property",e.API="API step",e.ELEMENT_COUNT="Element count",e.FLOW_PARAMETER="Flow parameter",e.TEST_RUN="Test run",e.TEMPLATE="String template"}(t.VariableSource||(t.VariableSource={})),t.resolveVariableValue=function(e,t,n=(e=>null==e?void 0:e.value)){let r,l=a(t,e);if(!l&&(e.includes(".")||e.includes("["))){const n=[e.indexOf("["),e.indexOf(".")].filter(e=>e>=0).reduce((e,t)=>Math.min(e,t));if(l=a(t,e.slice(0,n)),l){const t="."===e[n]?1:0;r=e.slice(n+t,e.length)}}let c=n(l);return c&&r&&(0,o.isNestableElement)(c)&&(c=(0,i.default)(c,r)),c},t.extractVariableObjectByName=a,t.namespace=function e(t={}){return new Proxy(t,{get(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?c(e[n])?e[n][r]:void 0:e[n]}return Reflect.get(e,t)},set(t,n,r){if("string"==typeof n){const[i,o]=l(n,".");return o?((null==t?void 0:t.hasOwnProperty(i))||(t[i]=e()),t[i][o]=r,!0):(t[i]=r,!0)}return Reflect.set(t,n,r),!0},deleteProperty(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?!c(e[n])||delete e[n][r]:((null==e?void 0:e.hasOwnProperty(n))&&delete e[n],!0)}return Reflect.deleteProperty(e,t)},has(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?n in e&&c(e[n])&&r in e[n]:n in e}return Reflect.has(e,t)}})},t.isVariable=function(e){return void 0!==e.variableType&&void 0!==e.name}},function(e,t){var n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/,i=/^\./,o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,l=/^\[object .+?Constructor\]$/,c="object"==typeof global&&global&&global.Object===Object&&global,u="object"==typeof self&&self&&self.Object===Object&&self,s=c||u||Function("return this")();var d,E=Array.prototype,_=Function.prototype,f=Object.prototype,p=s["__core-js_shared__"],m=(d=/[^.]+$/.exec(p&&p.keys&&p.keys.IE_PROTO||""))?"Symbol(src)_1."+d:"",R=_.toString,A=f.hasOwnProperty,b=f.toString,g=RegExp("^"+R.call(A).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),h=s.Symbol,T=E.splice,v=F(s,"Map"),y=F(Object,"create"),I=h?h.prototype:void 0,O=I?I.toString:void 0;function S(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function N(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function P(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function L(e,t){for(var n,r,i=e.length;i--;)if((n=e[i][0])===(r=t)||n!=n&&r!=r)return i;return-1}function D(e,t){for(var i,o=0,a=(t=function(e,t){if(U(e))return!1;var i=typeof e;if("number"==i||"symbol"==i||"boolean"==i||null==e||w(e))return!0;return r.test(e)||!n.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:U(i=t)?i:C(i)).length;null!=e&&o<a;)e=e[G(t[o++])];return o&&o==a?e:void 0}function M(e){return!(!X(e)||(t=e,m&&m in t))&&(function(e){var t=X(e)?b.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?g:l).test(function(e){if(null!=e){try{return R.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function x(e,t){var n,r,i=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof t?"string":"hash"]:i.map}function F(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return M(n)?n:void 0}S.prototype.clear=function(){this.__data__=y?y(null):{}},S.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},S.prototype.get=function(e){var t=this.__data__;if(y){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return A.call(t,e)?t[e]:void 0},S.prototype.has=function(e){var t=this.__data__;return y?void 0!==t[e]:A.call(t,e)},S.prototype.set=function(e,t){return this.__data__[e]=y&&void 0===t?"__lodash_hash_undefined__":t,this},N.prototype.clear=function(){this.__data__=[]},N.prototype.delete=function(e){var t=this.__data__,n=L(t,e);return!(n<0)&&(n==t.length-1?t.pop():T.call(t,n,1),!0)},N.prototype.get=function(e){var t=this.__data__,n=L(t,e);return n<0?void 0:t[n][1]},N.prototype.has=function(e){return L(this.__data__,e)>-1},N.prototype.set=function(e,t){var n=this.__data__,r=L(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},P.prototype.clear=function(){this.__data__={hash:new S,map:new(v||N),string:new S}},P.prototype.delete=function(e){return x(this,e).delete(e)},P.prototype.get=function(e){return x(this,e).get(e)},P.prototype.has=function(e){return x(this,e).has(e)},P.prototype.set=function(e,t){return x(this,e).set(e,t),this};var C=B((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(w(e))return O?O.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return i.test(e)&&n.push(""),e.replace(o,(function(e,t,r,i){n.push(r?i.replace(a,"$1"):t||e)})),n}));function G(e){if("string"==typeof e||w(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function B(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a),a};return n.cache=new(B.Cache||P),n}B.Cache=P;var U=Array.isArray;function X(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function w(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==b.call(e)}e.exports=function(e,t,n){var r=null==e?void 0:D(e,t);return void 0===r?n:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNormalizedFindDescriptor=t.mapHintsToFindDescriptor=t.mapWaitUntilToPropertyPreferences=t.getAncestorDescriptor=t.isAncestor=t.matchesAncestorXpath=t.computeRelativeXpath=t.isRelativeXpath=t.findIsWaitUntil=t.descriptorHasIntendedProperties=t.descriptorHasWaitTimeout=t.findIsRepeatedElements=t.descriptorHasOrdinalPreference=t.getWaitUntilTimeoutMs=t.compareStrings=t.getEffectiveSelectorValue=t.getComparator=t.isFindCustomDescriptor=t.ConfidenceLevel=t.PropertyComparator=t.isFindElementType=t.isFindType=t.FindType=t.isFindElementDescriptor=t.isFindOptions=t.ElementExpectation=void 0;const r=n(3);var i,o;function a(e){return[i.FIND_ANY,i.FIND_FIRST,i.FIND_LAST,i.FIND_ONE,i.FIND_ALL].some(t=>t===e)}function l(e){var t,n;return void 0!==(null===(n=null===(t=e.configuration)||void 0===t?void 0:t.ordinalPreference)||void 0===n?void 0:n.position)}function c(e){var t,n;return void 0!==(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)||void 0===n?void 0:n.timeoutSeconds)}function u(e){var t,n,r,i;return Object.values((null===(t=e.configuration)||void 0===t?void 0:t.propertyPreferences)||{}).some(e=>null==e?void 0:e.intended)||((null===(i=null===(r=null===(n=e.findOptions)||void 0===n?void 0:n.waitUntil)||void 0===r?void 0:r.properties)||void 0===i?void 0:i[e.selector.uuid])||[]).length>0}function s(e,t,n){return t+n.substring(1)===e}function d(e,t){return!!(e.selector.relative_xpath&&e.selector.xpath&&t.selector.xpath&&s(e.selector.xpath,t.selector.xpath,e.selector.relative_xpath))}function E(e,t){return!!(e.selector.relative_xpath&&!e.selector.findable_ancestor_uuid||e.selector.findable_ancestor_uuid===t.selector.uuid||d(e,t))}function _(e,t={}){const n={...t};for(const i of e)if((0,r.isSimpleElementSelectorCommonKeys)(i)){const e={...t[i]||{},intended:!0};n[i]=e}return n}function f(e,t){var n;const r=(null==t?void 0:t[e.selector.uuid])||[],i=null===(n=e.configuration)||void 0===n?void 0:n.propertyPreferences;return{...e,configuration:{...e.configuration,propertyPreferences:_(r,i)}}}!function(e){e.MISSING="missing",e.PRESENT="present"}(t.ElementExpectation||(t.ElementExpectation={})),t.isFindOptions=function(e){return e&&(void 0===e.waitUntil||function(e){return e&&void 0!==e.timeoutSeconds&&void 0!==e.properties}(e.waitUntil))},t.isFindElementDescriptor=function(e){return e&&a(e.findType)},function(e){e.FIND_ALL="find_all",e.FIND_ANY="find_any",e.FIND_COOKIE="find_cookie",e.FIND_EMAIL="find_email",e.FIND_FIRST="find_first",e.FIND_LAST="find_last",e.FIND_ONE="find_one",e.FIND_TAB="find_tab"}(i=t.FindType||(t.FindType={})),function(e){e.fromString=function(t){const n=t;if(!Object.values(e).includes(n))throw new Error("No FindType match found for value: "+t);return n}}(i=t.FindType||(t.FindType={})),t.isFindType=function(e){return!!Object.values(i).find(t=>t===e)},t.isFindElementType=a,function(e){e.EQUALS="equals",e.CONTAINS="contains"}(o=t.PropertyComparator||(t.PropertyComparator={})),function(e){e.LOW="low",e.MEDIUM="medium",e.HIGH="high",e.UNKNOWN="unknown"}(t.ConfidenceLevel||(t.ConfidenceLevel={})),t.isFindCustomDescriptor=function(e){return e&&"object"==typeof e&&"string"==typeof e.findType&&[i.FIND_ALL,i.FIND_FIRST,i.FIND_LAST,i.FIND_ANY,i.FIND_ALL].includes(e.findType)},t.getComparator=function(e,t){var n;return(null===(n=null==t?void 0:t[e])||void 0===n?void 0:n.comparator)||o.EQUALS},t.getEffectiveSelectorValue=function(e,t,n){const r=null==n?void 0:n[e],i=(null==r?void 0:r.intended)&&(null==r?void 0:r.value)?null==r?void 0:r.value:t[e];return"string"==typeof i?i:void 0},t.compareStrings=function(e,t,n){return!(!e||!t)&&(n&&n!==o.EQUALS?n===o.CONTAINS&&t.includes(e):e===t)},t.getWaitUntilTimeoutMs=function(e){var t,n,r,i;return(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)||void 0===n?void 0:n.timeoutSeconds)?1e3*(null===(i=null===(r=e.findOptions)||void 0===r?void 0:r.waitUntil)||void 0===i?void 0:i.timeoutSeconds):void 0},t.descriptorHasOrdinalPreference=l,t.findIsRepeatedElements=function(e){return l(e)||(e.auxiliaryDescriptors||[]).some(l)},t.descriptorHasWaitTimeout=c,t.descriptorHasIntendedProperties=u,t.findIsWaitUntil=function(e){return c(e)&&(u(e)||((null==e?void 0:e.auxiliaryDescriptors)||[]).some(u))},t.isRelativeXpath=s,t.computeRelativeXpath=function(e,t){if(e.startsWith(t)&&e.length>t.length)return"."+e.substring(t.length)},t.matchesAncestorXpath=d,t.isAncestor=E,t.getAncestorDescriptor=function(e){if(e.auxiliaryDescriptors&&e.auxiliaryDescriptors.length>0){const t=e.auxiliaryDescriptors.filter(t=>E(e,t));if(t.length>0){const n=t[0],r=(e.auxiliaryDescriptors||[]).filter(e=>e!==n);return{...e.type?{type:e.type}:{},...e.findOptions?{findOptions:e.findOptions}:{},...n,auxiliaryDescriptors:r}}}},t.mapWaitUntilToPropertyPreferences=function(e){var t;return(null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)&&Object.keys(e.findOptions.waitUntil.properties).length?function(e,t){const n=f(e,t),r=(e.auxiliaryDescriptors||[]).map(e=>f(e,t));return r.length&&(n.auxiliaryDescriptors=r),n}(e,e.findOptions.waitUntil.properties):e},t.mapHintsToFindDescriptor=function(e){var t,n;if(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.hints)||void 0===n?void 0:n.selectorSubstitutions){const t=e.findOptions.hints.selectorSubstitutions[e.selector.uuid];if(t&&(e.selector={...e.selector,...t},e.overrides))for(const n of e.overrides)n.selector={...n.selector,...t}}return e},t.isNormalizedFindDescriptor=function(e){return"object"==typeof e&&(null==e?void 0:e.selector)&&(0,r.isStandardSelector)(e.selector)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isCustomFindDescriptor=t.isFindOneDescriptor=void 0,t.isFindOneDescriptor=function(e){return e&&!e.foundElementSelectors&&!!e.selector},t.isCustomFindDescriptor=function(e){return!!(null==e?void 0:e.primarySelectors)}}])}));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.domUtil=t():e.domUtil=t()}(global,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=4)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.containsMablTemplatePattern=t.isString=t.isNestableElement=t.LONE_VARIABLE_REGEXP=t.FAKER_FORMAT_IN_EXPRESSION_REGEX_CREATE=t.FAKER_EXPRESSION_REGEXP_CREATE=t.FAKER_EXPRESSION_NAMED_GROUP=t.FAKER_EXPRESSION=t.FAKE_NAMESPACE=t.FAKER_GROUP_NAME=t.RANDOM_FORMAT_IN_EXPRESSION_REGEXP_CREATE=t.RANDOM_FORMAT_REGEXP_CREATE=t.RANDOM_FORMAT=t.LENGTH_GROUP=t.LENGTH_GROUP_NAME=t.ALPHABET_GROUP=t.RANDOM_STRING_CHOICES=t.ALPHABET_GROUP_NAME=t.CURRENT_DATE_REGEXP_CREATE=t.CURRENT_DATE_NAME_GROUP=t.CURRENT_DATE_GROUP_NAME=t.VARIABLE_IN_EXPRESSION_REGEXP_CREATE=t.SINGLE_VARIABLE_REGEX_CREATE=t.VARIABLE_GROUP=t.VARIABLE_GROUP_NAME=t.EXCLUDED_USER_VARIABLE_NAMES=t.ALL_VARIABLE_REGEXP_CREATE=t.COMPOUND_VARIABLE_PATTERN=t.USER_VARIABLE_REGEXP_CREATE=t.VARIABLE_REGEXP=t.INDEX_EXPRESSION_REGEXP=t.DOUBLE_QUOTED_IDENTIFIER_REGEXP=t.SINGLE_QUOTED_IDENTIFIER_REGEXP=t.ARRAY_INDEX_REGEXP=t.IDENTIFIER_REGEXP=t.USER_NAMESPACE_REGEXP=t.PATTERN_REGEXP=t.patternRanges=void 0,t.patternRanges={alpha:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",alphaLower:"abcdefghijklmnopqrstuvwxyz",alphaUpper:"ABCDEFGHIJKLMNOPQRSTUVWXYZ",digit:"0123456789",alnum:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"},t.PATTERN_REGEXP=/{{([^{}]*)}}/gi,t.USER_NAMESPACE_REGEXP=/^user\./g,t.IDENTIFIER_REGEXP="[a-zA-Z_][a-zA-Z0-9_]*",t.ARRAY_INDEX_REGEXP="[0-9]+",t.SINGLE_QUOTED_IDENTIFIER_REGEXP=`'${t.IDENTIFIER_REGEXP}'`,t.DOUBLE_QUOTED_IDENTIFIER_REGEXP=`"${t.IDENTIFIER_REGEXP}"`,t.INDEX_EXPRESSION_REGEXP=`\\[(?:${t.ARRAY_INDEX_REGEXP}|${t.SINGLE_QUOTED_IDENTIFIER_REGEXP}|${t.DOUBLE_QUOTED_IDENTIFIER_REGEXP})\\]`,t.VARIABLE_REGEXP=`${t.IDENTIFIER_REGEXP}(?:${t.INDEX_EXPRESSION_REGEXP})*`;t.USER_VARIABLE_REGEXP_CREATE=()=>RegExp("^"+t.IDENTIFIER_REGEXP+"$"),t.COMPOUND_VARIABLE_PATTERN=`(${t.VARIABLE_REGEXP})(\\.(${t.VARIABLE_REGEXP}))*`;t.ALL_VARIABLE_REGEXP_CREATE=()=>RegExp("^"+t.COMPOUND_VARIABLE_PATTERN+"$"),t.EXCLUDED_USER_VARIABLE_NAMES=["user","web","mail","api"],t.VARIABLE_GROUP_NAME="variable",t.VARIABLE_GROUP="(?<"+t.VARIABLE_GROUP_NAME+">"+t.COMPOUND_VARIABLE_PATTERN+")";t.SINGLE_VARIABLE_REGEX_CREATE=()=>RegExp("{{@"+t.VARIABLE_GROUP+"}}");t.VARIABLE_IN_EXPRESSION_REGEXP_CREATE=()=>RegExp("@"+t.VARIABLE_GROUP,"g"),t.CURRENT_DATE_GROUP_NAME="date",t.CURRENT_DATE_NAME_GROUP="(?<"+t.CURRENT_DATE_GROUP_NAME+">date)";t.CURRENT_DATE_REGEXP_CREATE=()=>RegExp("{{"+t.CURRENT_DATE_NAME_GROUP+"(:iso)?}}"),t.ALPHABET_GROUP_NAME="alphabet",t.RANDOM_STRING_CHOICES=Object.keys(t.patternRanges).join("|"),t.ALPHABET_GROUP="(?<"+t.ALPHABET_GROUP_NAME+">"+t.RANDOM_STRING_CHOICES+")",t.LENGTH_GROUP_NAME="length",t.LENGTH_GROUP="(?<"+t.LENGTH_GROUP_NAME+">[\\d]+)",t.RANDOM_FORMAT=t.ALPHABET_GROUP+":"+t.LENGTH_GROUP;t.RANDOM_FORMAT_REGEXP_CREATE=()=>RegExp("{{"+t.RANDOM_FORMAT+"}}");t.RANDOM_FORMAT_IN_EXPRESSION_REGEXP_CREATE=()=>RegExp(t.RANDOM_FORMAT,"g"),t.FAKER_GROUP_NAME="faker",t.FAKE_NAMESPACE="fake.",t.FAKER_EXPRESSION=t.FAKE_NAMESPACE+"[a-zA-Z]+\\.[a-zA-Z]+(\\((\\d+)\\))?",t.FAKER_EXPRESSION_NAMED_GROUP="(?<"+t.FAKER_GROUP_NAME+">{{"+t.FAKER_EXPRESSION+"}})";t.FAKER_EXPRESSION_REGEXP_CREATE=()=>RegExp(t.FAKER_EXPRESSION_NAMED_GROUP);t.FAKER_FORMAT_IN_EXPRESSION_REGEX_CREATE=()=>RegExp("("+t.FAKER_EXPRESSION+")","g"),t.LONE_VARIABLE_REGEXP="^{{@"+t.VARIABLE_GROUP+"}}$",t.isNestableElement=function(e){return e instanceof Object||e instanceof Array},t.isString=function(e){return e&&e instanceof String||"string"==typeof e},t.containsMablTemplatePattern=function(e){return!!e&&e.search(t.PATTERN_REGEXP)>=0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ALL_ATTR_PROPS_OPTIONS=t.ALLOWED_ASSERTIBLE_ATTRS_PROPS=t.ASSERTIBLE_ATTRIBUTE_TYPES=void 0,t.ASSERTIBLE_ATTRIBUTE_TYPES=["string","number","boolean"],t.ALLOWED_ASSERTIBLE_ATTRS_PROPS=["accessKey","accessKeyLabel ","align","alt","aria-checked","aria-label","aria-labelledby","aria-disabled","autofocus","border","checked","class","className","clientHeight","clientLeft","clientTop","clientWidth","complete","computedName","computedRole","contentEditable","contextMenu","crossOrigin","currentSrc","dataset ","defaultChecked","defaultValue","dir","disabled","draggable","formEncType","formMethod","formNoValidate","formTarget","height","hidden","href","hspace","id","indeterminate","inert","innerText","isContentEditable ","isMap","itemId ","itemScope ","lang","length","localName","longDesc","lowSrc","maxLength","multiple","name","namespaceURI","naturalHeight","naturalWidth","noModule","offsetHeight ","offsetLeft","offsetTop","offsetWidth","prefix","referrerPolicy","required","selectedIndex","size","sizes","slot","src","srcset","tabIndex","tagName","title","translate","type","validationMessage","validity","value","vspace","width","willValidate"],t.ALL_ATTR_PROPS_OPTIONS={},t.ALLOWED_ASSERTIBLE_ATTRS_PROPS.forEach(e=>t.ALL_ATTR_PROPS_OPTIONS[e]="")},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.MablscriptUtils=t.replaceVariables=t.findVariables=t.b64DecodeUnicode=t.b64EncodeUnicode=t.buildStepArgumentString=t.isValidVariableName=t.isValidUserVariableName=t.getVariableNameFromLoneVariablePattern=t.isLoneVariablePattern=t.unescapeMablscriptString=t.escapeMablscriptString=void 0;const a=n(0);function l(e){return"string"==typeof e?e.replace(/\\/g,"\\\\").replace(/\n/g,"\\n").replace(/"/g,'\\"').replace(/\r/g,""):""}function c(e){return!!e&&RegExp(a.LONE_VARIABLE_REGEXP).test(e)}t.escapeMablscriptString=l,t.unescapeMablscriptString=function(e){return"string"==typeof e?e.replace(/\\"/g,'"').replace(/\\n/g,"\n").replace(/\\\\/g,"\\"):""},t.isLoneVariablePattern=c,t.getVariableNameFromLoneVariablePattern=function(e){var t,n;if(c(e)){const r=RegExp(a.LONE_VARIABLE_REGEXP);return null===(n=null===(t=e.match(r))||void 0===t?void 0:t.groups)||void 0===n?void 0:n[a.VARIABLE_GROUP_NAME]}},t.isValidUserVariableName=function(e){return!!e&&((0,a.USER_VARIABLE_REGEXP_CREATE)().test(e)&&-1===a.EXCLUDED_USER_VARIABLE_NAMES.indexOf(e))},t.isValidVariableName=function(e){return!!e&&(0,a.ALL_VARIABLE_REGEXP_CREATE)().test(e)},t.buildStepArgumentString=function e(t){switch(typeof t){case"string":return`"${l(t)}"`;case"boolean":case"number":return""+t;case"object":{if(t instanceof Array)return`[${t.map(e).join(",")}]`;const n=[];return Object.keys(t).forEach(r=>{const i=e(t[r]);"string"==typeof r&&r&&"string"==typeof i&&i&&n.push(`"${r}":${i}`)}),n.sort(),`{${n.join(",")}}`}default:return}},t.b64EncodeUnicode=function(e){return btoa(encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,(function(e,t){return String.fromCharCode(parseInt("0x"+t,16))})))},t.b64DecodeUnicode=function(e){try{return decodeURIComponent(atob(e).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))}catch(t){return atob(e)}},t.findVariables=function(e){const t=null==e?void 0:e.match(a.PATTERN_REGEXP);return(null==t?void 0:t.reduce((e,t)=>{const n=null==t?void 0:t.match((0,a.VARIABLE_IN_EXPRESSION_REGEXP_CREATE)());return null==n||n.forEach(t=>e.push(t.substring(1))),e},[]))||[]},t.replaceVariables=function(e,t){return null===e?null:null==e?void 0:e.replace(a.PATTERN_REGEXP,e=>e.replace((0,a.VARIABLE_IN_EXPRESSION_REGEXP_CREATE)(),t))},t.MablscriptUtils=o(n(2))},function(e,t,n){"use strict";function r(e){return void 0!==e.tag_name&&("input"===e.tag_name.toLowerCase()?!e.inputElementType||-1===["radio","button","submit","reset"].indexOf(e.inputElementType.toLowerCase()):-1===["button","option","li","param"].indexOf(e.tag_name.toLowerCase()))}function i(e){return e&&void 0!==e.uuid&&void 0!==e.xpath}Object.defineProperty(t,"__esModule",{value:!0}),t.areSelectorsEqual=t.stripLocatorContextFromSelector=t.isCompositeSelector=t.isStandardSelector=t.isCookieSelector=t.isEmailSelector=t.isTabSelector=t.isCssSelector=t.isXPathSelector=t.ignoreValueAttribute=t.SELECTOR_ATTRIBUTE_KEYS=t.SELECTOR_EQUIVALENCE_IGNORED_KEYS=t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP=t.isSimpleElementSelectorCommonKeys=void 0,t.isSimpleElementSelectorCommonKeys=function(e){return"string"==typeof e&&!["css_query","repeat_xpaths","selector_type","tag_name","uuid","xpath"].includes(e)},t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP={elementId:"id",name:"name",href:"href",inputElementType:"inputElementType",label:"label",placeholder:"placeholder",tagName:"tag_name",text:"text",slotText:"slot_text",url:"url",title:"title",uuid:"uuid",xPath:"xpath",cssQuery:"css_query",className:"class_name",src:"src",alt:"alt",form:"form",for:"for_attr",target:"target",inputValue:"value",dataTracking:"data_tracking",titleAttr:"title_attr",ariaLabel:"aria_label",labelAttr:"label_attr",dataAutomationId:"data_automation_id",dataTestId:"data_test_id",dataTestid:"data_testid",testId:"test_id",ngModel:"ng_model",ngShow:"ng_show",ariaOwns:"aria_owns",ariaLabelledby:"aria_labelledby",ngClass:"ng_class",ariaControls:"aria_controls",tabindex:"tabindex",role:"role",maxlength:"maxlength",autocomplete:"autocomplete",height:"height",width:"width",style:"style",boundingX:"bounding_x",boundingY:"bounding_y",boundingHeight:"bounding_height",boundingWidth:"bounding_width",visible:"visible",dataTarget:"data_target",dataValue:"data_value",dataId:"data_id",dataName:"data_name",dataProp:"data_prop",index:"index",item:"item"},t.SELECTOR_EQUIVALENCE_IGNORED_KEYS={aria_owns:()=>!0,bounding_x:()=>!0,bounding_y:()=>!0,bounding_height:()=>!0,bounding_width:()=>!0,class_name:()=>!0,style:()=>!0,title_attr:function(e){if(void 0===e.tag_name)return!1;return["input","textarea"].includes(e.tag_name.toLowerCase())},uuid:()=>!0,value:r},t.SELECTOR_ATTRIBUTE_KEYS=Object.keys(t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP).map(e=>t.PROTOTYPE_TO_SELECTOR_ATTRIBUTE_MAP[e]),t.ignoreValueAttribute=r,t.isXPathSelector=function(e){return e&&void 0!==e.xpath},t.isCssSelector=function(e){return e&&void 0!==e.css_query},t.isTabSelector=function(e){return e&&"tab"===e.selector_type&&void 0!==e.url},t.isEmailSelector=function(e){return e&&"email"===e.selector_type},t.isCookieSelector=function(e){return e&&void 0!==e.name},t.isStandardSelector=i,t.isCompositeSelector=function(e){return e&&e.length>=1&&e.every(i)},t.stripLocatorContextFromSelector=function(e){const{currentContextNode:t,...n}=e;return n},t.areSelectorsEqual=function(e,t){if(void 0===e)return void 0===t;if(void 0===t)return!1;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const r of n)if(e[r]!==t[r])return!1;return!0}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),i(n(5),t)},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),i(n(6),t),i(n(7),t),i(n(1),t),i(n(2),t),i(n(9),t),i(n(3),t),i(n(10),t),i(n(0),t)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.adjustTarget=t.removeOverlayById=t.destroySelectionOverlay=t.highlightElements=t.highlightElement=t.positionSelectionHighlight=t.renderSelectionOverlay=t.xpathElement=t.createXpathFromPathArray=t.sanitizeXPath=t.getAncestorElements=t.isSelect=t.isFileInput=t.isTextField=t.isInputField=t.getInputTypeFromElement=t.getPlaceholderFromElement=t.getAnchorHrefFromElement=t.getInputLabelFromElement=t.getLabelForInput=t.normalizeText=t.truncateText=t.getSlotTextFromElement=t.getTextFromElement=t.compactWhitespace=t.createXPathFromElement=t.getIframesInfo=t.getAttributePropertyMap=t.getSelectedTextFromElement=t.getClassNameFromElement=t.getSelectedIndexFromElement=t.getElementValueFromElement=t.getNodeNameFromElement=t.getTagNameFromElement=t.getNameFromElement=t.getIdFromElement=t.createIgnoredDomElement=t.createBaseEventMessage=t.getAttributeFromElement=t.getPropertyFromElement=t.MAX_ATTRIBUTE_SIZE=t.MAX_SELECTOR_INNER_TEXT_LENGTH=t.MABL_INSERTED_ELEMENTS=t.MABL_SECONDARY_DRAGGABLE_DIV_ID=t.MABL_TERTIARY_IFRAME_ID=t.MABL_IGNORE_ELEMENT_CLASS=t.MABL_DRAGGABLE_DIV_ID=t.MABL_SECONDARY_IFRAME_ID=t.MABL_HIGHLIGHT_ID=t.MABL_OVERLAY_ID=void 0,t.isElementInShadowRoot=t.isExpectedToBeInvisible=t.isDisplayed=t.getInnerText=t.getElementByXpath=t.getAllElementsByXpath=t.getFirstElementBySelectors=t.getLastElementBySelectors=t.getAllElementBySelectors=t.destroyElement=t.getElementMatchingSelectionTarget=t.selectOption=void 0;const r=n(1);t.MABL_OVERLAY_ID="mabl-selection-overlay-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_HIGHLIGHT_ID="mabl-selection-highlight-22b76b1b-4c57-4644-98ab-6f2ff555d1cc";const i="mabl-selection-overlay-22b76b1b-4c57-4644-98ab-6f2ff555d1cc";var o;t.MABL_SECONDARY_IFRAME_ID="mabl-secondary-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_DRAGGABLE_DIV_ID="mabl-draggable-div-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_IGNORE_ELEMENT_CLASS="mabl-element-ignore-actions",t.MABL_TERTIARY_IFRAME_ID="mabl-tertiary-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_SECONDARY_DRAGGABLE_DIV_ID="mabl-secondary-draggable-div-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_INSERTED_ELEMENTS=[t.MABL_OVERLAY_ID,t.MABL_HIGHLIGHT_ID,i,"mabl-iframe-22b76b1b-4c57-4644-98ab-6f2ff555d1cc","mabl-iframe-draggable-22b76b1b-4c57-4644-98ab-6f2ff555d1cc",t.MABL_SECONDARY_IFRAME_ID,t.MABL_DRAGGABLE_DIV_ID],function(e){e[e["accessibility-check"]=0]="accessibility-check",e[e["assert-cookie"]=1]="assert-cookie",e[e["assert-email"]=2]="assert-email",e[e["assert-variable"]=3]="assert-variable",e[e["await-tab"]=4]="await-tab",e[e["await-uploads"]=5]="await-uploads",e[e["clear-cookies"]=6]="clear-cookies",e[e.click=7]="click",e[e.click_hold=8]="click_hold",e[e.conditional_else=9]="conditional_else",e[e.conditional_end=10]="conditional_end",e[e["double-click"]=11]="double-click",e[e.download=12]="download",e[e["download-pdf"]=13]="download-pdf",e[e.echo=14]="echo",e[e["end-flow"]=15]="end-flow",e[e["evaluate-js-snippet"]=16]="evaluate-js-snippet",e[e.hover=17]="hover",e[e.input=18]="input",e[e.keypress=19]="keypress",e[e.location=20]="location",e[e["mouse-select"]=21]="mouse-select",e[e.navigation=22]="navigation",e[e["open-email"]=23]="open-email",e[e.release=24]="release",e[e["remove-cookie"]=25]="remove-cookie",e[e["send-http-request"]=26]="send-http-request",e[e["set-cookie"]=27]="set-cookie",e[e["set-files"]=28]="set-files",e[e["set-variable"]=29]="set-variable",e[e["start-flow"]=30]="start-flow",e[e["switch-context-to"]=31]="switch-context-to",e[e["synthetic-click"]=32]="synthetic-click",e[e.url=33]="url",e[e["visit-url"]=34]="visit-url",e[e.viewport=35]="viewport",e[e.wait=36]="wait"}(o||(o={}));const a=["button","checkbox","file","radio","reset","submit"];function l(e,t){return _(e[t])}function c(e,t){return _(e.getAttribute(t))}t.MAX_SELECTOR_INNER_TEXT_LENGTH=300,t.MAX_ATTRIBUTE_SIZE=5e3,t.getPropertyFromElement=l,t.getAttributeFromElement=c;const u=[{name:"src",attribute:"src",handler:l},{name:"elementId",attribute:"id",handler:E},{name:"tagName",handler:f},{name:"text",handler:h},{name:"slotText",handler:T},{name:"label",handler:O},{name:"href",attribute:"href",handler:S},{name:"placeholder",attribute:"placeholder",handler:N},{name:"inputElementType",attribute:"type",handler:P},{name:"inputValue",attribute:"value",handler:m},{name:"className",attribute:"class",handler:R},{name:"visible",handler:function(e){return j(e).toString()}},...[{name:"alt",attribute:"alt"},{name:"form",attribute:"form"},{name:"for",attribute:"for"},{name:"target",attribute:"target"},{name:"name",attribute:"name"},{name:"target",attribute:"target"},{name:"name",attribute:"name"},{name:"dataTracking",attribute:"data-tracking"},{name:"titleAttr",attribute:"title"},{name:"ariaLabel",attribute:"aria-label"},{name:"labelAttr",attribute:"label"},{name:"dataAutomationId",attribute:"data-automation-id"},{name:"dataTestId",attribute:"data-test-id"},{name:"dataTestid",attribute:"data-testid"},{name:"testId",attribute:"test-id"},{name:"ngModel",attribute:"ng-model"},{name:"ngShow",attribute:"ng-show"},{name:"ngClass",attribute:"ng-class"},{name:"ariaOwns",attribute:"aria-owns"},{name:"ariaLabelledby",attribute:"aria-labelledby"},{name:"ariaControls",attribute:"aria-controls"},{name:"tabindex",attribute:"tabindex"},{name:"role",attribute:"role"},{name:"maxlength",attribute:"maxlength"},{name:"autocomplete",attribute:"autocomplete"},{name:"height",attribute:"height"},{name:"width",attribute:"width"},{name:"style",attribute:"style"},{name:"dataTarget",attribute:"data-target"},{name:"dataValue",attribute:"data-value"},{name:"dataId",attribute:"data-id"},{name:"dataName",attribute:"data-name"},{name:"dataProp",attribute:"data-prop"},{name:"index",attribute:"index"},{name:"item",attribute:"item"}].map(e=>({...e,handler:c}))],s=[{propertyName:"slotText",extractor:T}];function d(e,t,n,r,i){const o={action:t,listener:n,xPath:r,context:i};return u.forEach(t=>{const n=t.handler(e,t.attribute||t.name);o[t.name]=n}),o}function E(e){return _(e.id)}function _(e){var n;return("string"!=typeof e||e.length<t.MAX_ATTRIBUTE_SIZE)&&null!==(n=e)&&void 0!==n?n:void 0}function f(e){var t;return null===(t=null==e?void 0:e.tagName)||void 0===t?void 0:t.toLowerCase()}function p(e){var t;return _(null===(t=null==e?void 0:e.nodeName)||void 0===t?void 0:t.toLowerCase())}function m(e){return _(e.value)}function R(e){return _(e.className)}function A(e){return function e(t,n){const r=null==t?void 0:t.parentElement;if(r){const i=M(t,r);return e(r,`/${i}${n}`)}if(H(t)){return D(`//${M(t,t.getRootNode())}${n}`)}return D("//html[1]"+n)}(e,"")}function b(e){var t;return null===(t=null==e?void 0:e.replace(/[ \t\xA0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\n\x0B\f\r\x85\u2028\u2029]+/g," "))||void 0===t?void 0:t.trim()}function g(e){return b(e).substring(0,t.MAX_SELECTOR_INNER_TEXT_LENGTH).replace(/"/g,'\\"')}function h(e){return g(e.innerText||"")}function T(e){const t=e.querySelectorAll("slot");if(1!==t.length)return;const n=t.item(0).assignedNodes().find(e=>e.nodeType===Node.TEXT_NODE);return n?g(n.data):void 0}function v(e,t){var n;return null!==(n=null==e?void 0:e.substring(0,t))&&void 0!==n?n:e}function y(e,n=!0){const r=b(e);return r&&n?v(r,t.MAX_SELECTOR_INNER_TEXT_LENGTH):r}function I(e){if(!e||!L(e))return;const t=e.closest("label");if(t)return t;if(e.id){const t=(""+(e.id||"")).replace(/'/g,"\\'"),n=document.querySelector(`label[for='${t}']`);if(n)return n}const n=w("(./preceding-sibling::*//descendant-or-self::*[self::input|self::label])[last()]",e);if(n.length>0){const e=n[0];if("label"===f(e)&&!e.getAttribute("for"))return e}const r=w("(../preceding-sibling::*//descendant-or-self::*[self::input|self::label])[last()]",e);if(r.length>0){const e=r[0];if("label"===f(e)&&!e.getAttribute("for"))return e}}function O(e){const t=I(e);if(t)return h(t)}function S(e){if("a"===f(e))return _(e.href)}function N(e){if(L(e))return _(e.placeholder)}function P(e){if(L(e))return e.type||"text"}function L(e){const t=f(e);return"input"===t||"textarea"===t}function D(e){return(e=e.replace("*[local-name()='#document-fragment']/shadow[1]/body","body[1]")).replace(/#document-fragment\[0]\/shadow\[1]\/body\[0]/,"body[1]")}function M(e,t){let n;const r=p(e);n=r?e instanceof HTMLElement&&!(null==r?void 0:r.includes(":"))?r:`*[local-name()='${r}']`:"*";const i=function(e,t){let n=-1;const r=p(e);if(!r)return n;for(const i in t)if(null==t?void 0:t.hasOwnProperty(i)){const o=t[i];if(p(o)===r&&(n+=1,o===e))return n}return n}(e,t.children)+1;return i?`${n}[${i}]`:""+n}function x(){const e=document.createElement("div");return e.id=t.MABL_HIGHLIGHT_ID,e.classList.add(i),e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.width="0",e.style.height="0",e.style.borderStyle="solid",e.style.borderWidth="2px",e.style.borderColor="black",e}function F(e,n,r){const i=e.getBoundingClientRect(),o=x();o.id=`${t.MABL_HIGHLIGHT_ID}-${n}`,o.style.left=C(i.x),o.style.top=C(i.y),o.style.width=C(i.width),o.style.height=C(i.height),r.appendChild(o)}function C(e){return Math.round(e)+"px"}function G(e){const t=document.getElementById(e);if(t)try{document.body.removeChild(t)}catch(e){document.documentElement.removeChild(t)}}function B(e){var t;null===(t=null==e?void 0:e.parentNode)||void 0===t||t.removeChild(e)}function U(e){return e.css_query?function(e){const t=document.querySelectorAll(e);return t.item(t.length-1)}(e.value||e.css_query):e.xpath?(t=e.value||e.xpath,null===(r=w(t,n))||void 0===r?void 0:r.pop()):void 0;var t,n,r}function X(e){return e.css_query?document.querySelector(e.value||e.css_query):e.xpath?V(e.value||e.xpath):void 0}function w(e,t=document,n=!0){t=void 0!==t?t:document;const r=[];let i;try{i=document.evaluate(e,t,null,XPathResult.ORDERED_NODE_SNAPSHOT_TYPE,null)}catch(e){if(n&&e instanceof DOMException)return console.log(e),[];throw e}for(let e=0,t=i.snapshotLength;e<t;++e)r.push(i.snapshotItem(e));return r}function V(e,t=document,n=!0){t=void 0!==t?t:document;try{return document.evaluate(e,t,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null).singleNodeValue}catch(e){if(n&&e instanceof DOMException)return console.log(e),null;throw e}}function j(e){var t;if("input"===f(e)&&"hidden"===(null===(t=e.type)||void 0===t?void 0:t.toLowerCase()))return!1;if(!(e.offsetWidth||e.offsetHeight||e.getClientRects().length))return!1;const n=window.getComputedStyle(e);return(!n||"0"!==n.opacity)&&(n&&"none"!==n.display&&"collapse"!==n.visibility&&"hidden"!==n.visibility)}function H(e){return"#document-fragment"===e.getRootNode().nodeName}t.createBaseEventMessage=d,t.createIgnoredDomElement=function(e){const n=document.createElement(e);return n.className=t.MABL_IGNORE_ELEMENT_CLASS,n},t.getIdFromElement=E,t.getNameFromElement=function(e){return _(e.name)},t.getTagNameFromElement=f,t.getNodeNameFromElement=p,t.getElementValueFromElement=m,t.getSelectedIndexFromElement=function(e){return e.selectedIndex},t.getClassNameFromElement=R,t.getSelectedTextFromElement=function(e){var t;if("select"===f(e)&&(null==e?void 0:e.selectedOptions)&&!((null===(t=null==e?void 0:e.selectedOptions)||void 0===t?void 0:t.length)<1))return e.selectedOptions[0].innerText},t.getAttributePropertyMap=function(e){const t={};for(const n in e)try{const i=e[n],o=typeof i;if(r.ALLOWED_ASSERTIBLE_ATTRS_PROPS.includes(n)&&r.ASSERTIBLE_ATTRIBUTE_TYPES.includes(o)){if(null==i||"string"===o&&!i.length&&"value"!==n)continue;t[n]=y(i.toString(),!1)}}catch(e){console.error("Could not process an attribute/property for element",e)}return e.getAttributeNames().forEach(n=>{if(!(null==t?void 0:t.hasOwnProperty(n))){const r=e.getAttribute(n);t[n]=y(r||"",!1)}}),s.forEach(n=>{const r=n.extractor(e);r&&(t[n.propertyName]=r)}),t},t.getIframesInfo=function(){const e=[];return[].forEach.call(document.getElementsByTagName("iframe"),n=>{if(!t.MABL_INSERTED_ELEMENTS.includes(n.id)){const t=d(n,"record","switch-context-to",A(n));t.absoluteSrc=n.src,e.push(t)}}),e},t.createXPathFromElement=A,t.compactWhitespace=b,t.getTextFromElement=h,t.getSlotTextFromElement=T,t.truncateText=v,t.normalizeText=y,t.getLabelForInput=I,t.getInputLabelFromElement=O,t.getAnchorHrefFromElement=S,t.getPlaceholderFromElement=N,t.getInputTypeFromElement=P,t.isInputField=L,t.isTextField=function(e){const t=f(e),n=e.type;return"input"===t&&!a.includes(n)||"textarea"===t},t.isFileInput=function(e){const t=f(e),n=(e.type||"").toLowerCase();return"input"===t&&"file"===n},t.isSelect=function(e){return"select"===f(e)},t.getAncestorElements=function(e,t=0,n=[]){const r=[],i=n.map(e=>e.toLowerCase());let o=null==e?void 0:e.parentElement;for(;o&&(t<=0||r.length<t);)i.includes(f(o))||r.push(o),o=o.parentElement;return r},t.sanitizeXPath=D,t.createXpathFromPathArray=function(e){return D("//"+e.map((e,t,n)=>{const r=p(e);if(!r)return"";const i=n[t+1];return"#document"!==r&&i&&i?M(e,i):""}).reduce((e,t)=>""===t?e:`${t}/${e}`))},t.xpathElement=M,t.renderSelectionOverlay=function(e){const n=document.createElement("div");n.id=t.MABL_OVERLAY_ID,n.classList.add(i),n.setAttribute("style","\n position: fixed;\n display: none;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-color: rgba(24,197,207,0.25);\n z-index: 2147483646;\n cursor: pointer;\n display:block;");const r=document.createElement("div");r.classList.add(i),r.innerText=e,r.setAttribute("style","\n position: absolute;\n top: 50%;\n left: 50%;\n font-size: 50px;\n color: white;\n transform: translate(-50%,-50%);\n -ms-transform: translate(-50%,-50%);"),n.appendChild(r);const o=x();n.appendChild(o);try{document.body.appendChild(n)}catch(e){document.documentElement.appendChild(n)}},t.positionSelectionHighlight=function(e){const n=document.elementsFromPoint(e.clientX,e.clientY).find(e=>!e.classList.contains(i));if(!n)return;const r=n.getBoundingClientRect(),o=document.getElementById(t.MABL_HIGHLIGHT_ID);o&&(o.style.left=C(r.x),o.style.top=C(r.y),o.style.width=C(r.width),o.style.height=C(r.height))},t.highlightElement=F,t.highlightElements=function(e){const n=t.MABL_HIGHLIGHT_ID+"-parent";let r=document.getElementById(n);r&&B(r),r=document.createElement("div"),r.id=n,e.length>0&&e.forEach((e,t)=>{F(e,t,r)});const o=document.getElementById(t.MABL_OVERLAY_ID),a=document.createElement("div");a.classList.add(i),a.innerText=e.length+" elements found",a.setAttribute("style","\n position: absolute;\n top: 60%;\n left: 50%;\n font-size: 40px;\n color: white;\n transform: translate(-50%,-50%);\n -ms-transform: translate(-50%,-50%);"),r.appendChild(a),o.appendChild(r)},t.destroySelectionOverlay=function(){G(t.MABL_OVERLAY_ID)},t.removeOverlayById=G,t.adjustTarget=function(e,t){let n=e,r=null==t?void 0:t.slice();for(;n&&!(n instanceof HTMLElement);)n=n.parentElement,null==r||r.pop();const i=function(e,t){const n=f(e);if("button"!==n&&"input"!==n){let e;t.forEach((t,n)=>{var r;const i=null!==(r=f(t))&&void 0!==r?r:"";e||"button"!==i&&"input"!==i||(e=n)}),e&&(t=t.slice(e))}return t}(e,r);return i!==r&&(n=i[0],r=i),function(e){return"html"===f(e)}(n)&&(n=void 0,r=void 0),{path:r,target:n}},t.selectOption=function(e,t,n){e.focus(),"any"===t?e.options.length>1&&0===e.selectedIndex?e.selectedIndex=1:e.selectedIndex=0:e.selectedIndex=[...e.options].findIndex(e=>e.innerText===n),e.dispatchEvent(new Event("change")),e.blur();const r=new InputEvent("input");e.dispatchEvent(r)},t.getElementMatchingSelectionTarget=function(e){return"primarySelectors"in e.find?"find_last"===e.find.type?U(e.find.primarySelectors):X(e.find.primarySelectors):e.xPath?V(e.xPath):void 0},t.destroyElement=B,t.getAllElementBySelectors=function(e){try{if(e.css_query)return document.querySelectorAll(e.value||e.css_query);if(e.xpath)return w(e.value||e.xpath)}catch(e){}return[]},t.getLastElementBySelectors=U,t.getFirstElementBySelectors=X,t.getAllElementsByXpath=w,t.getElementByXpath=V,t.getInnerText=function e(t){const n=f(t)||"";return"select"!==n&&"option"!==n&&"optgroup"!==n?t.innerText||"":j(t)?[("option"===n?t.innerText||t.text:t.innerText)||"",Array.from(t.childNodes||[]).map(e).filter(e=>e).join(" ")].filter(e=>e).join(" "):""},t.isDisplayed=j,t.isExpectedToBeInvisible=function(e){var t;return"input"===f(e)&&"file"===(null===(t=null==e?void 0:e.type)||void 0===t?void 0:t.toLowerCase())},t.isElementInShadowRoot=H},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.isVariable=t.namespace=t.extractVariableObjectByName=t.resolveVariableValue=t.VariableSource=t.VariableType=void 0;const i=r(n(8)),o=n(0);function a(e,t){try{return e[t]||e["user."+t]}catch(e){return}}function l(e,t){const n=e.indexOf(t);return n<0?[e,void 0]:[e.substr(0,n),e.substr(n+1)]}function c(e){return!!e&&"object"==typeof e}!function(e){e.INPUT="input",e.MABL_MAILBOX="mablMailbox",e.JAVASCRIPT="javascript",e.GENERATED="generated",e.ELEMENT_PROPERTY="elementProperty",e.ELEMENT_COUNT="elementCount"}(t.VariableType||(t.VariableType={})),function(e){e.PLAN="Plan",e.JOURNEY_VAR="Default value",e.RUNTIME="Runtime",e.DDT="DataTable",e.ENV="Environment",e.MABL_MAIL="mabl Mailbox",e.JAVASCRIPT="JavaScript",e.ELEMENT_PROP="Element property",e.API="API step",e.ELEMENT_COUNT="Element count",e.FLOW_PARAMETER="Flow parameter",e.TEST_RUN="Test run",e.TEMPLATE="String template"}(t.VariableSource||(t.VariableSource={})),t.resolveVariableValue=function(e,t,n=(e=>null==e?void 0:e.value)){let r,l=a(t,e);if(!l&&(e.includes(".")||e.includes("["))){const n=[e.indexOf("["),e.indexOf(".")].filter(e=>e>=0).reduce((e,t)=>Math.min(e,t));if(l=a(t,e.slice(0,n)),l){const t="."===e[n]?1:0;r=e.slice(n+t,e.length)}}let c=n(l);return c&&r&&(0,o.isNestableElement)(c)&&(c=(0,i.default)(c,r)),c},t.extractVariableObjectByName=a,t.namespace=function e(t={}){return new Proxy(t,{get(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?c(e[n])?e[n][r]:void 0:e[n]}return Reflect.get(e,t)},set(t,n,r){if("string"==typeof n){const[i,o]=l(n,".");return o?((null==t?void 0:t.hasOwnProperty(i))||(t[i]=e()),t[i][o]=r,!0):(t[i]=r,!0)}return Reflect.set(t,n,r),!0},deleteProperty(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?!c(e[n])||delete e[n][r]:((null==e?void 0:e.hasOwnProperty(n))&&delete e[n],!0)}return Reflect.deleteProperty(e,t)},has(e,t){if("string"==typeof t){const[n,r]=l(t,".");return r?n in e&&c(e[n])&&r in e[n]:n in e}return Reflect.has(e,t)}})},t.isVariable=function(e){return void 0!==e.variableType&&void 0!==e.name}},function(e,t){var n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/,i=/^\./,o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,l=/^\[object .+?Constructor\]$/,c="object"==typeof global&&global&&global.Object===Object&&global,u="object"==typeof self&&self&&self.Object===Object&&self,s=c||u||Function("return this")();var d,E=Array.prototype,_=Function.prototype,f=Object.prototype,p=s["__core-js_shared__"],m=(d=/[^.]+$/.exec(p&&p.keys&&p.keys.IE_PROTO||""))?"Symbol(src)_1."+d:"",R=_.toString,A=f.hasOwnProperty,b=f.toString,g=RegExp("^"+R.call(A).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),h=s.Symbol,T=E.splice,v=F(s,"Map"),y=F(Object,"create"),I=h?h.prototype:void 0,O=I?I.toString:void 0;function S(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function N(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function P(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function L(e,t){for(var n,r,i=e.length;i--;)if((n=e[i][0])===(r=t)||n!=n&&r!=r)return i;return-1}function D(e,t){for(var i,o=0,a=(t=function(e,t){if(U(e))return!1;var i=typeof e;if("number"==i||"symbol"==i||"boolean"==i||null==e||w(e))return!0;return r.test(e)||!n.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:U(i=t)?i:C(i)).length;null!=e&&o<a;)e=e[G(t[o++])];return o&&o==a?e:void 0}function M(e){return!(!X(e)||(t=e,m&&m in t))&&(function(e){var t=X(e)?b.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?g:l).test(function(e){if(null!=e){try{return R.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function x(e,t){var n,r,i=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof t?"string":"hash"]:i.map}function F(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return M(n)?n:void 0}S.prototype.clear=function(){this.__data__=y?y(null):{}},S.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},S.prototype.get=function(e){var t=this.__data__;if(y){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return A.call(t,e)?t[e]:void 0},S.prototype.has=function(e){var t=this.__data__;return y?void 0!==t[e]:A.call(t,e)},S.prototype.set=function(e,t){return this.__data__[e]=y&&void 0===t?"__lodash_hash_undefined__":t,this},N.prototype.clear=function(){this.__data__=[]},N.prototype.delete=function(e){var t=this.__data__,n=L(t,e);return!(n<0)&&(n==t.length-1?t.pop():T.call(t,n,1),!0)},N.prototype.get=function(e){var t=this.__data__,n=L(t,e);return n<0?void 0:t[n][1]},N.prototype.has=function(e){return L(this.__data__,e)>-1},N.prototype.set=function(e,t){var n=this.__data__,r=L(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},P.prototype.clear=function(){this.__data__={hash:new S,map:new(v||N),string:new S}},P.prototype.delete=function(e){return x(this,e).delete(e)},P.prototype.get=function(e){return x(this,e).get(e)},P.prototype.has=function(e){return x(this,e).has(e)},P.prototype.set=function(e,t){return x(this,e).set(e,t),this};var C=B((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(w(e))return O?O.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return i.test(e)&&n.push(""),e.replace(o,(function(e,t,r,i){n.push(r?i.replace(a,"$1"):t||e)})),n}));function G(e){if("string"==typeof e||w(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function B(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a),a};return n.cache=new(B.Cache||P),n}B.Cache=P;var U=Array.isArray;function X(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function w(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==b.call(e)}e.exports=function(e,t,n){var r=null==e?void 0:D(e,t);return void 0===r?n:r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isNormalizedFindDescriptor=t.mapHintsToFindDescriptor=t.mapWaitUntilToPropertyPreferences=t.getAncestorDescriptor=t.isAncestor=t.matchesAncestorXpath=t.computeRelativeXpath=t.isRelativeXpath=t.findIsWaitUntil=t.descriptorHasIntendedProperties=t.descriptorHasWaitTimeout=t.findIsRepeatedElements=t.descriptorHasOrdinalPreference=t.getWaitUntilTimeoutMs=t.compareStrings=t.getEffectiveSelectorValue=t.getComparator=t.isFindCustomDescriptor=t.ConfidenceLevel=t.PropertyComparator=t.isFindElementType=t.isFindType=t.FindType=t.isFindElementDescriptor=t.isFindOptions=t.ElementExpectation=void 0;const r=n(3);var i,o;function a(e){return[i.FIND_ANY,i.FIND_FIRST,i.FIND_LAST,i.FIND_ONE,i.FIND_ALL].some(t=>t===e)}function l(e){var t,n;return void 0!==(null===(n=null===(t=e.configuration)||void 0===t?void 0:t.ordinalPreference)||void 0===n?void 0:n.position)}function c(e){var t,n;return void 0!==(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)||void 0===n?void 0:n.timeoutSeconds)}function u(e){var t,n,r,i;return Object.values((null===(t=e.configuration)||void 0===t?void 0:t.propertyPreferences)||{}).some(e=>null==e?void 0:e.intended)||((null===(i=null===(r=null===(n=e.findOptions)||void 0===n?void 0:n.waitUntil)||void 0===r?void 0:r.properties)||void 0===i?void 0:i[e.selector.uuid])||[]).length>0}function s(e,t,n){return t+n.substring(1)===e}function d(e,t){return!!(e.selector.relative_xpath&&e.selector.xpath&&t.selector.xpath&&s(e.selector.xpath,t.selector.xpath,e.selector.relative_xpath))}function E(e,t){return!!(e.selector.relative_xpath&&!e.selector.findable_ancestor_uuid||e.selector.findable_ancestor_uuid===t.selector.uuid||d(e,t))}function _(e,t={}){const n={...t};for(const i of e)if((0,r.isSimpleElementSelectorCommonKeys)(i)){const e={...t[i]||{},intended:!0};n[i]=e}return n}function f(e,t){var n;const r=(null==t?void 0:t[e.selector.uuid])||[],i=null===(n=e.configuration)||void 0===n?void 0:n.propertyPreferences;return{...e,configuration:{...e.configuration,propertyPreferences:_(r,i)}}}!function(e){e.MISSING="missing",e.PRESENT="present"}(t.ElementExpectation||(t.ElementExpectation={})),t.isFindOptions=function(e){return e&&(void 0===e.waitUntil||function(e){return e&&void 0!==e.timeoutSeconds&&void 0!==e.properties}(e.waitUntil))},t.isFindElementDescriptor=function(e){return e&&a(e.findType)},function(e){e.FIND_ALL="find_all",e.FIND_ANY="find_any",e.FIND_COOKIE="find_cookie",e.FIND_EMAIL="find_email",e.FIND_FIRST="find_first",e.FIND_LAST="find_last",e.FIND_ONE="find_one",e.FIND_TAB="find_tab"}(i=t.FindType||(t.FindType={})),function(e){e.fromString=function(t){const n=t;if(!Object.values(e).includes(n))throw new Error("No FindType match found for value: "+t);return n}}(i=t.FindType||(t.FindType={})),t.isFindType=function(e){return!!Object.values(i).find(t=>t===e)},t.isFindElementType=a,function(e){e.EQUALS="equals",e.CONTAINS="contains"}(o=t.PropertyComparator||(t.PropertyComparator={})),function(e){e.LOW="low",e.MEDIUM="medium",e.HIGH="high",e.UNKNOWN="unknown"}(t.ConfidenceLevel||(t.ConfidenceLevel={})),t.isFindCustomDescriptor=function(e){return e&&"object"==typeof e&&"string"==typeof e.findType&&[i.FIND_ALL,i.FIND_FIRST,i.FIND_LAST,i.FIND_ANY,i.FIND_ALL].includes(e.findType)},t.getComparator=function(e,t){var n;return(null===(n=null==t?void 0:t[e])||void 0===n?void 0:n.comparator)||o.EQUALS},t.getEffectiveSelectorValue=function(e,t,n){const r=null==n?void 0:n[e],i=(null==r?void 0:r.intended)&&(null==r?void 0:r.value)?null==r?void 0:r.value:t[e];return"string"==typeof i?i:void 0},t.compareStrings=function(e,t,n){return!(!e||!t)&&(n&&n!==o.EQUALS?n===o.CONTAINS&&t.includes(e):e===t)},t.getWaitUntilTimeoutMs=function(e){var t,n,r,i;return(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)||void 0===n?void 0:n.timeoutSeconds)?1e3*(null===(i=null===(r=e.findOptions)||void 0===r?void 0:r.waitUntil)||void 0===i?void 0:i.timeoutSeconds):void 0},t.descriptorHasOrdinalPreference=l,t.findIsRepeatedElements=function(e){return l(e)||(e.auxiliaryDescriptors||[]).some(l)},t.descriptorHasWaitTimeout=c,t.descriptorHasIntendedProperties=u,t.findIsWaitUntil=function(e){return c(e)&&(u(e)||((null==e?void 0:e.auxiliaryDescriptors)||[]).some(u))},t.isRelativeXpath=s,t.computeRelativeXpath=function(e,t){if(e.startsWith(t)&&e.length>t.length)return"."+e.substring(t.length)},t.matchesAncestorXpath=d,t.isAncestor=E,t.getAncestorDescriptor=function(e){var t;if(e.auxiliaryDescriptors&&e.auxiliaryDescriptors.length>0){const n=e.auxiliaryDescriptors.filter(t=>E(e,t));if(n.length>0){const r=n[0],i=(e.auxiliaryDescriptors||[]).filter(e=>e!==r),o={...r},a=e.selector;return"#document-fragment"===(null===(t=a.currentContextNode)||void 0===t?void 0:t.nodeName)&&(o.selector.currentContextNode=a.currentContextNode),{...e.type?{type:e.type}:{},...e.findOptions?{findOptions:e.findOptions}:{},...o,auxiliaryDescriptors:i}}}},t.mapWaitUntilToPropertyPreferences=function(e){var t;return(null===(t=e.findOptions)||void 0===t?void 0:t.waitUntil)&&Object.keys(e.findOptions.waitUntil.properties).length?function(e,t){const n=f(e,t),r=(e.auxiliaryDescriptors||[]).map(e=>f(e,t));return r.length&&(n.auxiliaryDescriptors=r),n}(e,e.findOptions.waitUntil.properties):e},t.mapHintsToFindDescriptor=function(e){var t,n;if(null===(n=null===(t=e.findOptions)||void 0===t?void 0:t.hints)||void 0===n?void 0:n.selectorSubstitutions){const t=e.findOptions.hints.selectorSubstitutions[e.selector.uuid];if(t&&(e.selector={...e.selector,...t},e.overrides))for(const n of e.overrides)n.selector={...n.selector,...t}}return e},t.isNormalizedFindDescriptor=function(e){return"object"==typeof e&&(null==e?void 0:e.selector)&&(0,r.isStandardSelector)(e.selector)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isCustomFindDescriptor=t.isFindOneDescriptor=void 0,t.isFindOneDescriptor=function(e){return e&&!e.foundElementSelectors&&!!e.selector},t.isCustomFindDescriptor=function(e){return!!(null==e?void 0:e.primarySelectors)}}])}));
|