browsertime 19.3.1 → 21.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (225) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/README.md +9 -8
  3. package/bin/browsertime.js +9 -3
  4. package/browserscripts/pageinfo/interactionToNextPaintInfo.js +170 -143
  5. package/browserscripts/timings/interactionToNextPaint.js +49 -137
  6. package/lib/chrome/webdriver/setupChromiumOptions.js +0 -9
  7. package/lib/core/engine/collector.js +11 -0
  8. package/lib/core/engine/command/actions.js +52 -0
  9. package/lib/core/engine/command/addText.js +48 -30
  10. package/lib/core/engine/command/android.js +43 -4
  11. package/lib/core/engine/command/cache.js +39 -2
  12. package/lib/core/engine/command/chromeDevToolsProtocol.js +51 -1
  13. package/lib/core/engine/command/chromeTrace.js +34 -0
  14. package/lib/core/engine/command/click.js +102 -52
  15. package/lib/core/engine/command/debug.js +19 -2
  16. package/lib/core/engine/command/element.js +66 -0
  17. package/lib/core/engine/command/geckoProfiler.js +41 -1
  18. package/lib/core/engine/command/javaScript.js +43 -20
  19. package/lib/core/engine/command/measure.js +151 -19
  20. package/lib/core/engine/command/meta.js +17 -0
  21. package/lib/core/engine/command/mouse/clickAndHold.js +56 -29
  22. package/lib/core/engine/command/mouse/contextClick.js +30 -11
  23. package/lib/core/engine/command/mouse/doubleClick.js +35 -11
  24. package/lib/core/engine/command/mouse/mouseMove.js +38 -16
  25. package/lib/core/engine/command/mouse/singleClick.js +187 -12
  26. package/lib/core/engine/command/navigation.js +31 -3
  27. package/lib/core/engine/command/screenshot.js +33 -0
  28. package/lib/core/engine/command/scroll.js +35 -13
  29. package/lib/core/engine/command/select.js +55 -36
  30. package/lib/core/engine/command/set.js +51 -36
  31. package/lib/core/engine/command/stopWatch.js +30 -9
  32. package/lib/core/engine/command/switch.js +49 -11
  33. package/lib/core/engine/command/wait.js +50 -25
  34. package/lib/core/engine/commands.js +267 -0
  35. package/lib/core/engine/context.js +81 -0
  36. package/lib/core/engine/index.js +6 -2
  37. package/lib/core/engine/iteration.js +20 -102
  38. package/lib/firefox/geckoProfiler.js +49 -1
  39. package/lib/firefox/webdriver/builder.js +35 -12
  40. package/lib/firefox/webdriver/firefox.js +1 -1
  41. package/lib/support/cli.js +35 -15
  42. package/lib/support/engineUtils.js +13 -1
  43. package/lib/support/statistics.js +11 -1
  44. package/lib/support/userTiming.js +2 -2
  45. package/package.json +17 -8
  46. package/types/android/index.d.ts +70 -0
  47. package/types/android/index.d.ts.map +1 -0
  48. package/types/chrome/parseCpuTrace.d.ts +21 -0
  49. package/types/chrome/parseCpuTrace.d.ts.map +1 -0
  50. package/types/chrome/traceCategoriesParser.d.ts +2 -0
  51. package/types/chrome/traceCategoriesParser.d.ts.map +1 -0
  52. package/types/chrome/webdriver/traceUtilities.d.ts +8 -0
  53. package/types/chrome/webdriver/traceUtilities.d.ts.map +1 -0
  54. package/types/core/engine/command/action.d.ts +73 -0
  55. package/types/core/engine/command/action.d.ts.map +1 -0
  56. package/types/core/engine/command/actions.d.ts +38 -0
  57. package/types/core/engine/command/actions.d.ts.map +1 -0
  58. package/types/core/engine/command/addText.d.ts +68 -0
  59. package/types/core/engine/command/addText.d.ts.map +1 -0
  60. package/types/core/engine/command/android.d.ts +39 -0
  61. package/types/core/engine/command/android.d.ts.map +1 -0
  62. package/types/core/engine/command/cache.d.ts +53 -0
  63. package/types/core/engine/command/cache.d.ts.map +1 -0
  64. package/types/core/engine/command/chromeDevToolsProtocol.d.ts +61 -0
  65. package/types/core/engine/command/chromeDevToolsProtocol.d.ts.map +1 -0
  66. package/types/core/engine/command/chromeTrace.d.ts +45 -0
  67. package/types/core/engine/command/chromeTrace.d.ts.map +1 -0
  68. package/types/core/engine/command/click.d.ts +151 -0
  69. package/types/core/engine/command/click.d.ts.map +1 -0
  70. package/types/core/engine/command/debug.d.ts +28 -0
  71. package/types/core/engine/command/debug.d.ts.map +1 -0
  72. package/types/core/engine/command/element.d.ts +49 -0
  73. package/types/core/engine/command/element.d.ts.map +1 -0
  74. package/types/core/engine/command/geckoProfiler.d.ts +46 -0
  75. package/types/core/engine/command/geckoProfiler.d.ts.map +1 -0
  76. package/types/core/engine/command/javaScript.d.ts +63 -0
  77. package/types/core/engine/command/javaScript.d.ts.map +1 -0
  78. package/types/core/engine/command/measure.d.ts +194 -0
  79. package/types/core/engine/command/measure.d.ts.map +1 -0
  80. package/types/core/engine/command/meta.d.ts +23 -0
  81. package/types/core/engine/command/meta.d.ts.map +1 -0
  82. package/types/core/engine/command/mouse/clickAndHold.d.ts +82 -0
  83. package/types/core/engine/command/mouse/clickAndHold.d.ts.map +1 -0
  84. package/types/core/engine/command/mouse/contextClick.d.ts +44 -0
  85. package/types/core/engine/command/mouse/contextClick.d.ts.map +1 -0
  86. package/types/core/engine/command/mouse/doubleClick.d.ts +51 -0
  87. package/types/core/engine/command/mouse/doubleClick.d.ts.map +1 -0
  88. package/types/core/engine/command/mouse/index.d.ts +6 -0
  89. package/types/core/engine/command/mouse/index.d.ts.map +1 -0
  90. package/types/core/engine/command/mouse/mouseMove.d.ts +56 -0
  91. package/types/core/engine/command/mouse/mouseMove.d.ts.map +1 -0
  92. package/types/core/engine/command/mouse/singleClick.d.ts +115 -0
  93. package/types/core/engine/command/mouse/singleClick.d.ts.map +1 -0
  94. package/types/core/engine/command/navigation.d.ts +45 -0
  95. package/types/core/engine/command/navigation.d.ts.map +1 -0
  96. package/types/core/engine/command/screenshot.d.ts +33 -0
  97. package/types/core/engine/command/screenshot.d.ts.map +1 -0
  98. package/types/core/engine/command/scroll.d.ts +52 -0
  99. package/types/core/engine/command/scroll.d.ts.map +1 -0
  100. package/types/core/engine/command/select.d.ts +81 -0
  101. package/types/core/engine/command/select.d.ts.map +1 -0
  102. package/types/core/engine/command/set.d.ts +74 -0
  103. package/types/core/engine/command/set.d.ts.map +1 -0
  104. package/types/core/engine/command/stopWatch.d.ts +49 -0
  105. package/types/core/engine/command/stopWatch.d.ts.map +1 -0
  106. package/types/core/engine/command/switch.d.ts +77 -0
  107. package/types/core/engine/command/switch.d.ts.map +1 -0
  108. package/types/core/engine/command/util/lcpHighlightScript.d.ts +2 -0
  109. package/types/core/engine/command/util/lcpHighlightScript.d.ts.map +1 -0
  110. package/types/core/engine/command/util/lsHighlightScript.d.ts +2 -0
  111. package/types/core/engine/command/util/lsHighlightScript.d.ts.map +1 -0
  112. package/types/core/engine/command/wait.d.ts +74 -0
  113. package/types/core/engine/command/wait.d.ts.map +1 -0
  114. package/types/core/engine/commands.d.ts +161 -0
  115. package/types/core/engine/commands.d.ts.map +1 -0
  116. package/types/core/engine/context.d.ts +87 -0
  117. package/types/core/engine/context.d.ts.map +1 -0
  118. package/types/firefox/geckoProfiler.d.ts +11 -0
  119. package/types/firefox/geckoProfiler.d.ts.map +1 -0
  120. package/types/firefox/settings/geckoProfilerDefaults.d.ts +8 -0
  121. package/types/firefox/settings/geckoProfilerDefaults.d.ts.map +1 -0
  122. package/types/scripting.d.ts +2 -0
  123. package/types/support/engineUtils.d.ts +5 -0
  124. package/types/support/engineUtils.d.ts.map +1 -0
  125. package/types/support/errors.d.ts +15 -0
  126. package/types/support/errors.d.ts.map +1 -0
  127. package/types/support/fileUtil.d.ts +10 -0
  128. package/types/support/fileUtil.d.ts.map +1 -0
  129. package/types/support/filters.d.ts +7 -0
  130. package/types/support/filters.d.ts.map +1 -0
  131. package/types/support/getViewPort.d.ts +2 -0
  132. package/types/support/getViewPort.d.ts.map +1 -0
  133. package/types/support/pathToFolder.d.ts +2 -0
  134. package/types/support/pathToFolder.d.ts.map +1 -0
  135. package/types/support/storageManager.d.ts +17 -0
  136. package/types/support/storageManager.d.ts.map +1 -0
  137. package/types/support/tcpdump.d.ts +10 -0
  138. package/types/support/tcpdump.d.ts.map +1 -0
  139. package/types/support/userTiming.d.ts +2 -0
  140. package/types/support/userTiming.d.ts.map +1 -0
  141. package/types/support/util.d.ts +6 -0
  142. package/types/support/util.d.ts.map +1 -0
  143. package/types/video/defaults.d.ts +7 -0
  144. package/types/video/defaults.d.ts.map +1 -0
  145. package/types/video/postprocessing/finetune/addTextToVideo.d.ts +2 -0
  146. package/types/video/postprocessing/finetune/addTextToVideo.d.ts.map +1 -0
  147. package/types/video/postprocessing/finetune/convertFps.d.ts +2 -0
  148. package/types/video/postprocessing/finetune/convertFps.d.ts.map +1 -0
  149. package/types/video/postprocessing/finetune/getFont.d.ts +2 -0
  150. package/types/video/postprocessing/finetune/getFont.d.ts.map +1 -0
  151. package/types/video/postprocessing/finetune/getTimingMetrics.d.ts +2 -0
  152. package/types/video/postprocessing/finetune/getTimingMetrics.d.ts.map +1 -0
  153. package/types/video/postprocessing/finetune/index.d.ts +2 -0
  154. package/types/video/postprocessing/finetune/index.d.ts.map +1 -0
  155. package/types/video/postprocessing/finetune/removeOrange.d.ts +2 -0
  156. package/types/video/postprocessing/finetune/removeOrange.d.ts.map +1 -0
  157. package/types/video/postprocessing/visualmetrics/extraMetrics.d.ts +5 -0
  158. package/types/video/postprocessing/visualmetrics/extraMetrics.d.ts.map +1 -0
  159. package/types/video/postprocessing/visualmetrics/getVideoMetrics.d.ts +5 -0
  160. package/types/video/postprocessing/visualmetrics/getVideoMetrics.d.ts.map +1 -0
  161. package/types/video/postprocessing/visualmetrics/visualMetrics.d.ts +3 -0
  162. package/types/video/postprocessing/visualmetrics/visualMetrics.d.ts.map +1 -0
  163. package/types/video/screenRecording/android/recorder.d.ts +11 -0
  164. package/types/video/screenRecording/android/recorder.d.ts.map +1 -0
  165. package/types/video/screenRecording/desktop/convert.d.ts +2 -0
  166. package/types/video/screenRecording/desktop/convert.d.ts.map +1 -0
  167. package/types/video/screenRecording/desktop/desktopRecorder.d.ts +28 -0
  168. package/types/video/screenRecording/desktop/desktopRecorder.d.ts.map +1 -0
  169. package/types/video/screenRecording/desktop/ffmpegRecorder.d.ts +17 -0
  170. package/types/video/screenRecording/desktop/ffmpegRecorder.d.ts.map +1 -0
  171. package/types/video/screenRecording/desktop/osx/getSPDisplaysDataType.d.ts +2 -0
  172. package/types/video/screenRecording/desktop/osx/getSPDisplaysDataType.d.ts.map +1 -0
  173. package/types/video/screenRecording/desktop/osx/getScreen.d.ts +2 -0
  174. package/types/video/screenRecording/desktop/osx/getScreen.d.ts.map +1 -0
  175. package/types/video/screenRecording/firefox/firefoxWindowRecorder.d.ts +13 -0
  176. package/types/video/screenRecording/firefox/firefoxWindowRecorder.d.ts.map +1 -0
  177. package/types/video/screenRecording/ios/convertToMp4.d.ts +2 -0
  178. package/types/video/screenRecording/ios/convertToMp4.d.ts.map +1 -0
  179. package/types/video/screenRecording/ios/iosRecorder.d.ts +14 -0
  180. package/types/video/screenRecording/ios/iosRecorder.d.ts.map +1 -0
  181. package/types/video/screenRecording/iosSimulator/convertToMp4.d.ts +2 -0
  182. package/types/video/screenRecording/iosSimulator/convertToMp4.d.ts.map +1 -0
  183. package/types/video/screenRecording/iosSimulator/recorder.d.ts +9 -0
  184. package/types/video/screenRecording/iosSimulator/recorder.d.ts.map +1 -0
  185. package/types/video/screenRecording/recorder.d.ts +7 -0
  186. package/types/video/screenRecording/recorder.d.ts.map +1 -0
  187. package/types/video/screenRecording/setOrangeBackground.d.ts +2 -0
  188. package/types/video/screenRecording/setOrangeBackground.d.ts.map +1 -0
  189. package/types/video/video.d.ts +41 -0
  190. package/types/video/video.d.ts.map +1 -0
  191. package/CONTRIBUTING.md +0 -24
  192. package/browsersupport/firefox-profile/cert9.db +0 -0
  193. package/browsersupport/firefox-profile/chrome/userChrome.css +0 -4
  194. package/browsersupport/firefox-profile/key4.db +0 -0
  195. package/docs/examples/README.md +0 -9
  196. package/docs/examples/advance.md +0 -12
  197. package/docs/examples/android.md +0 -54
  198. package/docs/examples/basic.md +0 -36
  199. package/docs/examples/chrome.md +0 -28
  200. package/docs/examples/firefox.md +0 -10
  201. package/docs/issues.md +0 -18
  202. package/docs/new-style-script-objects.md +0 -38
  203. package/docs/sequence-diagrams/loadAndWait.wsd +0 -24
  204. package/docs/sequence-diagrams/run.wsd +0 -24
  205. package/vendor/mac/x86/qvh +0 -0
  206. package/visualmetrics/__init__.py +0 -1
  207. package/visualmetrics/test_data/ms_000000.png +0 -0
  208. package/visualmetrics/test_data/ms_000920.png +0 -0
  209. package/visualmetrics/test_data/ms_001000.png +0 -0
  210. package/visualmetrics/test_data/ms_001080.png +0 -0
  211. package/visualmetrics/test_data/ms_001200.png +0 -0
  212. package/visualmetrics/test_data/ms_001240.png +0 -0
  213. package/visualmetrics/test_data/ms_001280.png +0 -0
  214. package/visualmetrics/test_data/ms_001360.png +0 -0
  215. package/visualmetrics/test_data/ms_001400.png +0 -0
  216. package/visualmetrics/test_data/ms_001520.png +0 -0
  217. package/visualmetrics/test_data/ms_002040.png +0 -0
  218. package/visualmetrics/test_data/ms_002600.png +0 -0
  219. package/visualmetrics/test_data/ms_003160.png +0 -0
  220. package/visualmetrics/test_data/ms_003720.png +0 -0
  221. package/visualmetrics/test_data/ms_004280.png +0 -0
  222. package/visualmetrics/test_data/ms_004880.png +0 -0
  223. package/visualmetrics/test_data/ms_005440.png +0 -0
  224. package/visualmetrics/test_data/ms_006000.png +0 -0
  225. package/visualmetrics/test_visualmetrics.py +0 -34
@@ -0,0 +1,53 @@
1
+ /**
2
+ * Manage the browser cache.
3
+ * This class provides methods to clear the cache and cookies in different browsers.
4
+ *
5
+ * @class
6
+ * @hideconstructor
7
+ */
8
+ export class Cache {
9
+ constructor(browser: any, browserName: any, extensionServer: any, cdp: any);
10
+ /**
11
+ * @private
12
+ */
13
+ private browser;
14
+ /**
15
+ * @private
16
+ */
17
+ private browserName;
18
+ /**
19
+ * @private
20
+ */
21
+ private extensionServer;
22
+ /**
23
+ * @private
24
+ */
25
+ private cdp;
26
+ /**
27
+ * Clears the browser cache. This includes both cache and cookies.
28
+ *
29
+ * For Firefox, it uses the extensionServer setup with specific options.
30
+ * For Chrome and Edge, it uses the Chrome DevTools Protocol (CDP) commands.
31
+ * If the browser is not supported, logs an error message.
32
+ *
33
+ * @async
34
+ * @example await commands.cache.clear();
35
+ * @throws Will throw an error if the browser is not supported.
36
+ * @returns {Promise<void>} A promise that resolves when the cache and cookies are cleared.
37
+ */
38
+ clear(): Promise<void>;
39
+ /**
40
+ * Clears the browser cache while keeping the cookies.
41
+ *
42
+ * For Firefox, it uses the extensionServer setup with specific options.
43
+ * For Chrome and Edge, it uses the Chrome DevTools Protocol (CDP) command to clear the cache.
44
+ * If the browser is not supported, logs an error message.
45
+ *
46
+ * @async
47
+ * @example await commands.cache.clearKeepCookies();
48
+ * @throws Will throw an error if the browser is not supported.
49
+ * @returns {Promise<void>} A promise that resolves when the cache is cleared but cookies are kept.
50
+ */
51
+ clearKeepCookies(): Promise<void>;
52
+ }
53
+ //# sourceMappingURL=cache.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cache.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/cache.js"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH;IACE,4EAiBC;IAhBC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,oBAA8B;IAC9B;;OAEG;IACH,wBAAsC;IACtC;;OAEG;IACH,YAAc;IAGhB;;;;;;;;;;;OAWG;IACH,SAFa,QAAQ,IAAI,CAAC,CAgBzB;IAED;;;;;;;;;;;OAWG;IACH,oBAFa,QAAQ,IAAI,CAAC,CAezB;CACF"}
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Manages interactions with the Chrome DevTools Protocol for Chrome and Edge browsers.
3
+ * Allows sending commands and setting up event listeners via the protocol.
4
+ *
5
+ * @class
6
+ * @hideconstructor
7
+ * @see https://chromedevtools.github.io/devtools-protocol/
8
+ */
9
+ export class ChromeDevelopmentToolsProtocol {
10
+ constructor(engineDelegate: any, browserName: any);
11
+ /**
12
+ * @private
13
+ */
14
+ private engineDelegate;
15
+ /**
16
+ * @private
17
+ */
18
+ private browserName;
19
+ /**
20
+ * Sets up an event listener for a specific DevTools Protocol event.
21
+ *
22
+ * @async
23
+ * @param {string} event - The name of the event to listen for.
24
+ * @param {Function} f - The callback function to execute when the event is triggered.
25
+ * @throws {Error} Throws an error if the browser is not supported or if setting the listener fails.
26
+ */
27
+ on(event: string, f: Function): Promise<void>;
28
+ /**
29
+ * Sends a command to the DevTools Protocol and returns the result.
30
+ *
31
+ * @async
32
+ * @example const domCounters = await commands.cdp.sendAndGet('Memory.getDOMCounters');
33
+ * @see https://chromedevtools.github.io/devtools-protocol/
34
+ * @param {string} command - The DevTools Protocol command to send.
35
+ * @param {Object} arguments_ - The arguments for the command.
36
+ * @throws {Error} Throws an error if the browser is not supported or if the command fails.
37
+ * @returns {Promise<Object>} The result of the command execution.
38
+ */
39
+ sendAndGet(command: string, arguments_: any): Promise<any>;
40
+ /**
41
+ * Retrieves the raw client for the DevTools Protocol.
42
+ * @example const cdpClient = commands.cdp.getRawClient();
43
+ * @returns {Object} The raw DevTools Protocol client.
44
+ * @throws {Error} Throws an error if the browser is not supported.
45
+ * @see https://github.com/cyrus-and/chrome-remote-interface
46
+ */
47
+ getRawClient(): any;
48
+ /**
49
+ * Sends a command to the DevTools Protocol.
50
+ *
51
+ * @async
52
+ * @example await commands.cdp.send('');
53
+ * @see https://chromedevtools.github.io/devtools-protocol/
54
+ * @param {string} command - The DevTools Protocol command to send.
55
+ * @param {Object} arguments_ - The arguments for the command.
56
+ * @throws {Error} Throws an error if the browser is not supported or if the command fails.
57
+ * @returns {Promise<void>} A promise that resolves when the command has been sent.
58
+ */
59
+ send(command: string, arguments_: any): Promise<void>;
60
+ }
61
+ //# sourceMappingURL=chromeDevToolsProtocol.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chromeDevToolsProtocol.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/chromeDevToolsProtocol.js"],"names":[],"mappings":"AAGA;;;;;;;GAOG;AACH;IACE,mDASC;IARC;;OAEG;IACH,uBAAoC;IACpC;;OAEG;IACH,oBAA8B;IAGhC;;;;;;;OAOG;IACH,UAJW,MAAM,8BAuBhB;IAED;;;;;;;;;;OAUG;IACH,oBALW,MAAM,oBAGJ,YAAe,CAsB3B;IAED;;;;;;OAMG;IACH,oBAMC;IAED;;;;;;;;;;OAUG;IACH,cALW,MAAM,oBAGJ,QAAQ,IAAI,CAAC,CAmBzB;CACF"}
@@ -0,0 +1,45 @@
1
+ /**
2
+ * Manages Chrome trace functionality, enabling custom profiling and trace collection in Chrome.
3
+ *
4
+ * @class
5
+ * @hideconstructor
6
+ */
7
+ export class ChromeTrace {
8
+ constructor(engineDelegate: any, index: any, options: any, result: any);
9
+ /**
10
+ * @private
11
+ */
12
+ private engineDelegate;
13
+ /**
14
+ * @private
15
+ */
16
+ private options;
17
+ /**
18
+ * @private
19
+ */
20
+ private result;
21
+ /**
22
+ * @private
23
+ */
24
+ private index;
25
+ /**
26
+ * Starts the Chrome trace collection.
27
+ *
28
+ * @async
29
+ * @example await commands.trace.start();
30
+ * @returns {Promise<void>} A promise that resolves when tracing is started.
31
+ * @throws {Error} Throws an error if not running Chrome or if configuration is not set for custom tracing.
32
+ */
33
+ start(): Promise<void>;
34
+ /**
35
+ * Stops the Chrome trace collection, processes the collected data, and attaches it to the result object.
36
+ *
37
+ * @async
38
+ * @example await commands.trace.stop();
39
+ * @returns {Promise<void>} A promise that resolves when tracing is stopped and data is processed.
40
+ * @throws {Error} Throws an error if not running Chrome or if custom tracing was not started.
41
+ */
42
+ stop(): Promise<void>;
43
+ events: any;
44
+ }
45
+ //# sourceMappingURL=chromeTrace.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chromeTrace.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/chromeTrace.js"],"names":[],"mappings":"AAMA;;;;;GAKG;AACH;IACE,wEAiBC;IAhBC;;OAEG;IACH,uBAAoC;IACpC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,eAAoB;IACpB;;OAEG;IACH,cAAkB;IAGpB;;;;;;;OAOG;IACH,SAHa,QAAQ,IAAI,CAAC,CAezB;IAED;;;;;;;OAOG;IACH,QAHa,QAAQ,IAAI,CAAC,CAuCzB;IA/BK,YAAgB;CAgCvB"}
@@ -0,0 +1,151 @@
1
+ /**
2
+ * Provides functionality to perform click actions on elements in a web page using various selectors.
3
+ *
4
+ * @class
5
+ * @hideconstructor
6
+ */
7
+ export class Click {
8
+ constructor(browser: any, pageCompleteCheck: any);
9
+ /**
10
+ * @private
11
+ */
12
+ private browser;
13
+ /**
14
+ * @private
15
+ */
16
+ private pageCompleteCheck;
17
+ /**
18
+ * Clicks on an element identified by its class name.
19
+ *
20
+ * @async
21
+ * @param {string} className - The class name of the element to click.
22
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
23
+ * @throws {Error} Throws an error if the element is not found.
24
+ */
25
+ byClassName(className: string): Promise<void>;
26
+ /**
27
+ * Clicks on an element identified by its class name and waits for the page complete check to finish.
28
+ *
29
+ * @async
30
+ * @param {string} className - The class name of the element to click.
31
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
32
+ * @throws {Error} Throws an error if the element is not found.
33
+ */
34
+ byClassNameAndWait(className: string): Promise<void>;
35
+ /**
36
+ * Clicks on a link whose visible text matches the given string.
37
+ *
38
+ * @async
39
+ * @param {string} text - The visible text of the link to click.
40
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
41
+ * @throws {Error} Throws an error if the link is not found.
42
+ */
43
+ byLinkText(text: string): Promise<void>;
44
+ /**
45
+ * Clicks on a link whose visible text matches the given string and waits for the page complete check to finish.
46
+ *
47
+ * @async
48
+ * @param {string} text - The visible text of the link to click.
49
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
50
+ * @throws {Error} Throws an error if the link is not found.
51
+ */
52
+ byLinkTextAndWait(text: string): Promise<void>;
53
+ /**
54
+ * Clicks on a link whose visible text contains the given substring.
55
+ *
56
+ * @async
57
+ * @param {string} text - The substring of the visible text of the link to click.
58
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
59
+ * @throws {Error} Throws an error if the link is not found.
60
+ */
61
+ byPartialLinkText(text: string): Promise<void>;
62
+ /**
63
+ * Clicks on a link whose visible text contains the given substring and waits for the page complete check to finish.
64
+ *
65
+ * @async
66
+ * @param {string} text - The substring of the visible text of the link to click.
67
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
68
+ * @throws {Error} Throws an error if the link is not found.
69
+ */
70
+ byPartialLinkTextAndWait(text: string): Promise<void>;
71
+ /**
72
+ * Clicks on an element that matches a given XPath selector.
73
+ *
74
+ * @async
75
+ * @param {string} xpath - The XPath selector of the element to click.
76
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
77
+ * @throws {Error} Throws an error if the element is not found.
78
+ */
79
+ byXpath(xpath: string): Promise<void>;
80
+ /**
81
+ * Clicks on an element that matches a given XPath selector and waits for the page complete check to finish.
82
+ *
83
+ * @async
84
+ * @param {string} xpath - The XPath selector of the element to click.
85
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
86
+ * @throws {Error} Throws an error if the element is not found.
87
+ */
88
+ byXpathAndWait(xpath: string): Promise<void>;
89
+ /**
90
+ * Clicks on an element located by evaluating a JavaScript expression.
91
+ *
92
+ * @async
93
+ * @param {string} js - The JavaScript expression that evaluates to an element or list of elements.
94
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
95
+ * @throws {Error} Throws an error if the element is not found.
96
+ */
97
+ byJs(js: string): Promise<void>;
98
+ /**
99
+ * Clicks on an element located by evaluating a JavaScript expression and waits for the page complete check to finish.
100
+ *
101
+ * @async
102
+ * @param {string} js - The JavaScript expression that evaluates to an element or list of elements.
103
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
104
+ * @throws {Error} Throws an error if the element is not found.
105
+ */
106
+ byJsAndWait(js: string): Promise<void>;
107
+ /**
108
+ * Clicks on an element located by its ID.
109
+ *
110
+ * @async
111
+ * @param {string} id - The ID of the element to click.
112
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
113
+ * @throws {Error} Throws an error if the element is not found.
114
+ */
115
+ byId(id: string): Promise<void>;
116
+ /**
117
+ * Clicks on an element located by its name attribute.
118
+ *
119
+ * @async
120
+ * @param {string} name - The name attribute of the element to click.
121
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
122
+ * @throws {Error} Throws an error if the element is not found.
123
+ */
124
+ byName(name: string): Promise<void>;
125
+ /**
126
+ * Click on link located by the ID attribute. Uses document.getElementById() to find the element. And wait for page complete check to finish.
127
+ * @param {string} id
128
+ * @returns {Promise<void>} Promise object represents when the element has been clicked and the pageCompleteCheck has finished.
129
+ * @throws Will throw an error if the element is not found
130
+ */
131
+ byIdAndWait(id: string): Promise<void>;
132
+ /**
133
+ * Clicks on an element located by its CSS selector.
134
+ *
135
+ * @async
136
+ * @param {string} selector - The CSS selector of the element to click.
137
+ * @returns {Promise<void>} A promise that resolves when the click action is performed.
138
+ * @throws {Error} Throws an error if the element is not found.
139
+ */
140
+ bySelector(selector: string): Promise<void>;
141
+ /**
142
+ * Clicks on an element located by its CSS selector and waits for the page complete check to finish.
143
+ *
144
+ * @async
145
+ * @param {string} selector - The CSS selector of the element to click.
146
+ * @returns {Promise<void>} A promise that resolves when the click action and page complete check are finished.
147
+ * @throws {Error} Throws an error if the element is not found.
148
+ */
149
+ bySelectorAndWait(selector: string): Promise<void>;
150
+ }
151
+ //# sourceMappingURL=click.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"click.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/click.js"],"names":[],"mappings":"AAYA;;;;;GAKG;AACH;IACE,kDASC;IARC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,0BAA0C;IAG5C;;;;;;;OAOG;IACH,uBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,8BAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAazB;IAED;;;;;;;OAOG;IACH,iBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,wBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,wBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,+BAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,eAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAczB;IACD;;;;;;;OAOG;IACH,sBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAezB;IAED;;;;;;;OAOG;IACH,SAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,gBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAazB;IAED;;;;;;;OAOG;IACH,SAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,aAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;OAKG;IACH,gBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAazB;IAED;;;;;;;OAOG;IACH,qBAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAYzB;IAED;;;;;;;OAOG;IACH,4BAJW,MAAM,GACJ,QAAQ,IAAI,CAAC,CAazB;CACF"}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Provides debugging capabilities within a browser automation script.
3
+ * It allows setting breakpoints to pause script execution and inspect the current state.
4
+ *
5
+ * @class
6
+ * @hideconstructor
7
+ */
8
+ export class Debug {
9
+ constructor(browser: any, options: any);
10
+ /**
11
+ * @private
12
+ */
13
+ private browser;
14
+ /**
15
+ * @private
16
+ */
17
+ private options;
18
+ /**
19
+ * Adds a breakpoint to the script. The browser will pause at the breakpoint, waiting for user input to continue.
20
+ * This is useful for debugging and inspecting the browser state at a specific point in the script.
21
+ *
22
+ * @async
23
+ * @param {string} [name] - An optional name for the breakpoint for logging purposes.
24
+ * @returns {Promise<void>} A promise that resolves when the user chooses to continue from the breakpoint.
25
+ */
26
+ breakpoint(name?: string): Promise<void>;
27
+ }
28
+ //# sourceMappingURL=debug.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/debug.js"],"names":[],"mappings":"AAIA;;;;;;GAMG;AACH;IACE,wCASC;IARC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,gBAAsB;IAGxB;;;;;;;OAOG;IACH,kBAHW,MAAM,GACJ,QAAQ,IAAI,CAAC,CA+BzB;CACF"}
@@ -0,0 +1,49 @@
1
+ /**
2
+ * This class provides a way to get hokld of Seleniums WebElements.
3
+ * @class
4
+ * @hideconstructor
5
+ */
6
+ export class Element {
7
+ constructor(browser: any);
8
+ /**
9
+ * @private
10
+ */
11
+ private driver;
12
+ /**
13
+ * Finds an element by its CSS selector.
14
+ *
15
+ * @param {string} name - The CSS selector of the element.
16
+ * @returns {Promise<WebElement>} A promise that resolves to the WebElement found.
17
+ */
18
+ getByCss(name: string): Promise<WebElement>;
19
+ /**
20
+ * Finds an element by its ID.
21
+ *
22
+ * @param {string} id - The ID of the element.
23
+ * @returns {Promise<WebElement>} A promise that resolves to the WebElement found.
24
+ */
25
+ getById(id: string): Promise<WebElement>;
26
+ /**
27
+ * Finds an element by its XPath.
28
+ *
29
+ * @param {string} xpath - The XPath query of the element.
30
+ * @returns {Promise<WebElement>} A promise that resolves to the WebElement found.
31
+ */
32
+ getByXpath(xpath: string): Promise<WebElement>;
33
+ /**
34
+ * Finds an element by its class name.
35
+ *
36
+ * @param {string} className - The class name of the element.
37
+ * @returns {Promise<WebElement>} A promise that resolves to the WebElement found.
38
+ */
39
+ getByClassName(className: string): Promise<WebElement>;
40
+ /**
41
+ * Finds an element by its name attribute.
42
+ *
43
+ * @param {string} name - The name attribute of the element.
44
+ * @returns {Promise<WebElement>} A promise that resolves to the WebElement found.
45
+ */
46
+ getByName(name: string): Promise<WebElement>;
47
+ }
48
+ import { WebElement } from 'selenium-webdriver';
49
+ //# sourceMappingURL=element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"element.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/element.js"],"names":[],"mappings":"AAGA;;;;GAIG;AACH;IACE,0BAKC;IAJC;;OAEG;IACH,eAAiC;IAGnC;;;;;OAKG;IACH,eAHW,MAAM,GACJ,QAAQ,UAAU,CAAC,CAI/B;IAED;;;;;OAKG;IACH,YAHW,MAAM,GACJ,QAAQ,UAAU,CAAC,CAI/B;IAED;;;;;OAKG;IACH,kBAHW,MAAM,GACJ,QAAQ,UAAU,CAAC,CAI/B;IAED;;;;;OAKG;IACH,0BAHW,MAAM,GACJ,QAAQ,UAAU,CAAC,CAI/B;IAED;;;;;OAKG;IACH,gBAHW,MAAM,GACJ,QAAQ,UAAU,CAAC,CAI/B;CACF;2BA/D8B,oBAAoB"}
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Manages the Gecko Profiler for profiling Firefox performance.
3
+ *
4
+ * @class
5
+ * @hideconstructor
6
+ */
7
+ export class GeckoProfiler {
8
+ constructor(GeckoProfiler: any, browser: any, index: any, options: any, result: any);
9
+ /**
10
+ * @private
11
+ */
12
+ private GeckoProfiler;
13
+ /**
14
+ * @private
15
+ */
16
+ private browser;
17
+ /**
18
+ * @private
19
+ */
20
+ private index;
21
+ /**
22
+ * @private
23
+ */
24
+ private options;
25
+ /**
26
+ * @private
27
+ */
28
+ private result;
29
+ /**
30
+ * Starts the Gecko Profiler.
31
+ *
32
+ * @async
33
+ * @returns {Promise<void>} A promise that resolves when the profiler is started.
34
+ * @throws {Error} Throws an error if not running Firefox or if the configuration is not set for custom profiling.
35
+ */
36
+ start(): Promise<void>;
37
+ /**
38
+ * Stops the Gecko Profiler and processes the collected data.
39
+ *
40
+ * @async
41
+ * @returns {Promise<void>} A promise that resolves when the profiler is stopped and the data is processed.
42
+ * @throws {Error} Throws an error if not running Firefox or if custom profiling was not started.
43
+ */
44
+ stop(): Promise<void>;
45
+ }
46
+ //# sourceMappingURL=geckoProfiler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"geckoProfiler.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/geckoProfiler.js"],"names":[],"mappings":"AAEA;;;;;GAKG;AAEH;IACE,qFAqBC;IApBC;;OAEG;IACH,sBAAkC;IAClC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,cAAkB;IAClB;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,eAAoB;IAGtB;;;;;;OAMG;IACH,SAHa,QAAQ,IAAI,CAAC,CAezB;IAED;;;;;;OAMG;IACH,QAHa,QAAQ,IAAI,CAAC,CAezB;CACF"}
@@ -0,0 +1,63 @@
1
+ /**
2
+ * Provides functionality to execute JavaScript code in the context of the current page.
3
+ *
4
+ * @class
5
+ * @hideconstructor
6
+ */
7
+ export class JavaScript {
8
+ constructor(browser: any, pageCompleteCheck: any);
9
+ /**
10
+ * @private
11
+ */
12
+ private browser;
13
+ /**
14
+ * @private
15
+ */
16
+ private pageCompleteCheck;
17
+ /**
18
+ * Executes a JavaScript script.
19
+ *
20
+ * @async
21
+ * @param {string} js - The JavaScript code to execute.
22
+ * @returns {Promise<*>} A promise that resolves with the result of the executed script.
23
+ * @throws {Error} Throws an error if the JavaScript cannot be executed.
24
+ */
25
+ run(js: string): Promise<any>;
26
+ /**
27
+ * Executes a JavaScript script and waits for the page complete check to finish.
28
+ *
29
+ * @async
30
+ * @param {string} js - The JavaScript code to execute.
31
+ * @returns {Promise<*>} A promise that resolves with the result of the executed script and the completion of the page load.
32
+ * @throws {Error} Throws an error if the JavaScript cannot be executed.
33
+ */
34
+ runAndWait(js: string): Promise<any>;
35
+ /**
36
+ * Executes synchronous privileged JavaScript.
37
+ *
38
+ * @async
39
+ * @param {string} js - The privileged JavaScript code to execute.
40
+ * @returns {Promise<*>} A promise that resolves with the result of the executed privileged script.
41
+ * @throws {Error} Throws an error if the privileged JavaScript cannot be executed.
42
+ */
43
+ runPrivileged(js: string): Promise<any>;
44
+ /**
45
+ * Executes synchronous privileged JavaScript and waits for the page complete check to finish.
46
+ *
47
+ * @async
48
+ * @param {string} js - The privileged JavaScript code to execute.
49
+ * @returns {Promise<*>} A promise that resolves with the result of the executed privileged script and the completion of the page load.
50
+ * @throws {Error} Throws an error if the privileged JavaScript cannot be executed.
51
+ */
52
+ runPrivilegedAndWait(js: string): Promise<any>;
53
+ /**
54
+ * Executes asynchronous privileged JavaScript.
55
+ *
56
+ * @async
57
+ * @param {string} js - The asynchronous privileged JavaScript code to execute.
58
+ * @returns {Promise<*>} A promise that resolves with the result of the executed asynchronous privileged script.
59
+ * @throws {Error} Throws an error if the asynchronous privileged JavaScript cannot be executed.
60
+ */
61
+ runPrivilegedAsync(js: string): Promise<any>;
62
+ }
63
+ //# sourceMappingURL=javaScript.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"javaScript.d.ts","sourceRoot":"","sources":["../../../../lib/core/engine/command/javaScript.js"],"names":[],"mappings":"AAEA;;;;;GAKG;AAEH;IACE,kDASC;IARC;;OAEG;IACH,gBAAsB;IACtB;;OAEG;IACH,0BAA0C;IAG5C;;;;;;;OAOG;IACH,QAJW,MAAM,GACJ,YAAU,CAYtB;IAED;;;;;;;OAOG;IACH,eAJW,MAAM,GACJ,YAAU,CAYtB;IAED;;;;;;;OAOG;IACH,kBAJW,MAAM,GACJ,YAAU,CAetB;IAED;;;;;;;OAOG;IACH,yBAJW,MAAM,GACJ,YAAU,CAYtB;IAED;;;;;;;OAOG;IACH,uBAJW,MAAM,GACJ,YAAU,CAetB;CACF"}